Skip to content

Add project

POST
/api/v1/projects

Registers a host directory as a Warden project. Optionally creates a container in the same request by including a “container” field. If container creation fails, the project is cleaned up automatically.

Project details (with optional container config)

One of:
object

Created

object
container

Container holds the container result when a container was created. Nil when the request did not include container configuration.

object
agentType

AgentType is the agent type for this container.

string
containerId

ContainerID is the Docker container ID.

string
name

Name is the container name.

string
projectId

ProjectID is the deterministic project identifier.

string
recreated

Recreated is true when the container was fully recreated (not just settings updated).

boolean
project

Project holds the registered project result.

object
agentType

AgentType is the agent type for this project (e.g. “claude-code”, “codex”).

string
containerId

ContainerID is the Docker container ID, when available.

string
name

Name is the user-chosen project display name.

string
projectId

ProjectID is the deterministic project identifier.

string

Bad Request

object
code
string
Allowed values: INVALID_BODY INVALID_CONTAINER_ID INVALID_CONTAINER_NAME INVALID_WORKTREE_ID INVALID_WORKTREE_NAME REQUIRED_FIELD INVALID_PATH INVALID_NETWORK_CONFIG NOT_A_DIRECTORY NOT_FOUND NAME_TAKEN NOT_CONFIGURED STALE_MOUNTS BUDGET_EXCEEDED PROXY_ERROR INTERNAL
error
string

Container name already in use

object
code
string
Allowed values: INVALID_BODY INVALID_CONTAINER_ID INVALID_CONTAINER_NAME INVALID_WORKTREE_ID INVALID_WORKTREE_NAME REQUIRED_FIELD INVALID_PATH INVALID_NETWORK_CONFIG NOT_A_DIRECTORY NOT_FOUND NAME_TAKEN NOT_CONFIGURED STALE_MOUNTS BUDGET_EXCEEDED PROXY_ERROR INTERNAL
error
string

Internal Server Error

object
code
string
Allowed values: INVALID_BODY INVALID_CONTAINER_ID INVALID_CONTAINER_NAME INVALID_WORKTREE_ID INVALID_WORKTREE_NAME REQUIRED_FIELD INVALID_PATH INVALID_NETWORK_CONFIG NOT_A_DIRECTORY NOT_FOUND NAME_TAKEN NOT_CONFIGURED STALE_MOUNTS BUDGET_EXCEEDED PROXY_ERROR INTERNAL
error
string