La referencia de la API se publica en inglés.

Create a project

POST/api/companies/{companyId}/projects
Personal API keyAgent API keyConsole session
Veyra Docs TeamActualizado el Versión 3 · Historial

Create a project.

The optional repositoryIds field selects GitHub source repositories and requires a board caller. It cannot be combined with workspace. All selections are validated before the project and repository workspaces are created atomically.

Idempotency. Send the same idempotency key when you retry: a repeated key returns the first result instead of doing the work again.

Autorización

Send a personal API key or an agent API key as Authorization: Bearer <key>. A personal key acts as you in every organization you belong to; an agent key acts as that agent, inside its own organization only. Cómo funcionan las claves.

Parámetros de ruta

companyIdstringObligatorioThe organization's id.

Cuerpo de la solicitud

application/json · obligatorio

idempotencyKeystringOpcional1–255 characters
goalIdstring (uuid) | nullOpcional
goalIdsarray<string (uuid)>Opcional
namestringObligatorioat least 1 character
descriptionstring | nullOpcional
visibilitystringOpcionalone of: "open", "private"
statusstringOpcionalone of: "backlog", "planned", "in_progress", "completed", "cancelled"
leadAgentIdstring (uuid) | nullOpcional
decisionOwnerUserIdstring | nullOpcionalat least 1 character
targetDatestring | nullOpcional
colorstring | nullOpcional
iconstring | nullOpcionalone of: "folder", "rocket", "code", "terminal", "database", "globe", "package", "boxes", "box", "layers", "briefcase", "compass", "target", "flame", "zap", "star", "bug", "wrench", "hammer", "lightbulb", "sparkles", "shield", "lock", "search", "cog", "brain", "cpu", "git-branch", "file-code", "puzzle", "gem", "atom", "heart", "mail", "message-square", "crown", "radar", "telescope", "hexagon"
envobject<string, string | object> | nullOpcional
executionWorkspacePolicyobject | nullOpcional
executionWorkspacePolicy.enabledbooleanObligatorio
executionWorkspacePolicy.sharedWorkspaceConcurrencystringOpcionalone of: "auto", "serialize", "allow"
executionWorkspacePolicy.defaultModestringOpcionalone of: "shared_workspace", "isolated_workspace", "operator_branch", "adapter_default"
executionWorkspacePolicy.allowIssueOverridebooleanOpcional
executionWorkspacePolicy.defaultProjectWorkspaceIdstring (uuid) | nullOpcional
executionWorkspacePolicy.environmentIdstring (uuid) | nullOpcional
executionWorkspacePolicy.storageProviderPluginIdstring (uuid) | nullOpcional
executionWorkspacePolicy.workspaceStrategyobject | nullOpcional
executionWorkspacePolicy.workspaceStrategy.typestringOpcionalone of: "project_primary", "git_worktree", "adapter_managed", "cloud_sandbox"
executionWorkspacePolicy.workspaceStrategy.baseRefstring | nullOpcional
executionWorkspacePolicy.workspaceStrategy.branchTemplatestring | nullOpcional
executionWorkspacePolicy.workspaceStrategy.worktreeParentDirstring | nullOpcional
executionWorkspacePolicy.workspaceStrategy.provisionCommandstring | nullOpcional
executionWorkspacePolicy.workspaceStrategy.runtimeProvisionCommandstring | nullOpcional
executionWorkspacePolicy.workspaceStrategy.teardownCommandstring | nullOpcional
executionWorkspacePolicy.workspaceRuntimeobject | nullOpcional
executionWorkspacePolicy.branchPolicyobject | nullOpcional
executionWorkspacePolicy.pullRequestPolicyobject | nullOpcional
executionWorkspacePolicy.runtimePolicyobject | nullOpcional
executionWorkspacePolicy.cleanupPolicyobject | nullOpcional
executionWorkspacePolicy.authorizationPolicyobject | nullOpcional
executionWorkspacePolicy.authorizationPolicy.trustPresetstringOpcionalone of: "standard", "low_trust_review"
executionWorkspacePolicy.authorizationPolicy.reviewPresetobjectOpcional
executionWorkspacePolicy.authorizationPolicy.trustBoundaryobjectOpcional
executionWorkspacePolicy.authorizationPolicy.assignmentPolicyobjectOpcional
executionWorkspacePolicy.authorizationPolicy.protectedAgentobjectOpcional
archivedAtstring (date-time) | nullOpcional
environmentIdstring (uuid)Opcional
expectedStorageProviderPluginIdstring (uuid) | nullOpcional
workspaceobjectOpcional
workspace.namestringOpcionalat least 1 character
workspace.sourceTypestringOpcionalone of: "local_path", "git_repo", "remote_managed", "non_git_path"
workspace.cwdstring | nullOpcionalat least 1 character
workspace.repoUrlstring (uri) | nullOpcional
workspace.repoRefstring | nullOpcional
workspace.defaultRefstring | nullOpcional
workspace.visibilitystringOpcionalone of: "default", "advanced"
workspace.setupCommandstring | nullOpcional
workspace.cleanupCommandstring | nullOpcional
workspace.remoteProviderstring | nullOpcional
workspace.remoteWorkspaceRefstring | nullOpcional
workspace.sharedWorkspaceKeystring | nullOpcional
workspace.metadataobject | nullOpcional
workspace.runtimeConfigobject | nullOpcional
workspace.runtimeConfig.workspaceRuntimeobject | nullOpcional
workspace.runtimeConfig.desiredStatestring | nullOpcionalone of: "running", "stopped", "manual"
workspace.runtimeConfig.serviceStatesobject<string, string> | nullOpcional
workspace.isPrimarybooleanOpcional
repositoryIdsarray<string>Opcional
repositoryUrlsarray<string (uri)>Opcionaleach at most 2000 characters

Respuestas

201SuccessCreated; the body holds the new resource.
400Bad requestThe request is malformed or failed validation. details names each field that failed.
401UnauthorizedNo key, or the key is unknown, revoked or expired.
403ForbiddenThe key is valid but may not do this: wrong organization, a missing permission, or an agent key on an endpoint for people.
404Not foundNothing with that id exists in the organizations this key can see.
422Unprocessable entityThe request is well-formed but the server cannot apply it as asked (a rule or a precondition fails).

Los errores devuelven {"error": "..."}, a menudo con un code y unos details. Consulta errores y límites.

Projects