Skip to main content

Overview

Creates a new project in Dokploy with the specified name, optional description, and optional environment variables.

Annotations

destructiveHint
boolean
default:"false"
This operation creates a new resource and is non-destructive.
idempotentHint
boolean
default:"false"
This operation is not idempotent - calling it multiple times will create multiple projects.
openWorldHint
boolean
default:"true"
This operation interacts with the external Dokploy API.

Input Schema

name
string
required
The name of the project. Must be at least 1 character long.
description
string | null
An optional description for the project. Helps document the purpose and scope of the project.
env
string
Optional environment variables for the project. Should be in KEY=VALUE format, with multiple variables separated by newlines.

Response Schema

Returns the newly created project object:
projectId
string
Unique identifier for the newly created project
name
string
Name of the project
description
string | null
Description of the project
createdAt
string
ISO 8601 timestamp of when the project was created
organizationId
string
ID of the organization that owns this project
env
string
Environment variables for the project

Usage Example

// Create a new project with minimal configuration
const result = await mcp.useTool("project-create", {
  name: "My New Project"
});

// Create a project with description and environment variables
const resultWithEnv = await mcp.useTool("project-create", {
  name: "Production Environment",
  description: "Main production environment for our application",
  env: "NODE_ENV=production\nAPI_URL=https://api.example.com\nDEBUG=false"
});

console.log(resultWithEnv);
// Output:
// {
//   "message": "Project \"Production Environment\" created successfully",
//   "data": {
//     "projectId": "proj_xyz789",
//     "name": "Production Environment",
//     "description": "Main production environment for our application",
//     "createdAt": "2024-03-04T15:30:00Z",
//     "organizationId": "org_abc123",
//     "env": "NODE_ENV=production\nAPI_URL=https://api.example.com\nDEBUG=false"
//   }
// }

Error Handling

If the project creation fails, an error response will be returned with details about the failure:
{
  "error": "Failed to create project",
  "details": "Project name already exists"
}

Notes

  • The name field is required and must be unique within your organization
  • Environment variables are optional and can be added or modified after project creation
  • The project will be associated with your current organization automatically
  • After creating a project, you can add applications, databases, and other services to it

Build docs developers (and LLMs) love