Create from YAML
- POST
- /workspaces
- /:workspace
- /environments
- /yaml
Add environment from YAML
Request
REQUIRED SCOPES
ENVIRONMENT_WRITE
URL PARAMETERS
workspacerequiredstring
The human-readable ID of the workspaceExample: "my-company"
GET PARAMETERS
project_namestring
Project name to filter project-scoped environmentsExample: "my-project"
BODY PARAMETERS
yamlstring
The Base64-encoded YAML definition of the environmentResponse
RESPONSE BODY
urlread-onlystring
API endpoint to GET this objecthtml_urlread-onlystring
Web URL to view this object in Buddy.worksidstring
The ID of the environmentnamerequiredstring
The name of the environmentidentifierstring
A human-readable ID of the environment. Alphanumeric characters, underscores, and hyphens (hyphens cannot appear at the start or end).tagsstring[]
The list of tags associated with the environmentConstraints: Unique items required
iconstring
The icon of the environmentpublic_urlstring
The public URL of the environmentpipelines_access_levelstring enum
Indicates if all pipelines can inherit to this environmentAllowed enum:
DENIED,READ_ONLY,USE_ONLY,BLIND,RUN_ONLY,READ_WRITE,MANAGE,DEFAULT,ALLOWED,STAGE,COMMITenvironments_access_levelstring enum
Indicates if all pipelines can use this environmentAllowed enum:
DENIED,READ_ONLY,USE_ONLY,BLIND,RUN_ONLY,READ_WRITE,MANAGE,DEFAULT,ALLOWED,STAGE,COMMITallowed_pipelinesAllowedPipelineView[]
The List of pipelines that can use this environment (specified by project slug and pipeline slug)allowed_environmentsAllowedEnvironmentView[]
The List of environments that can inherit this environment (specified by project slug and environment slug)create_datestring
The creation date of the environmentprojectShortProjectView
Short representation of a projectpermissionsPermissionsView
Access permissions configurationbase_environmentsstring[]
The list of environments that is used as a base for this environment (specified by project slug and environment slug)targetsTargetView[]
The list of targets associated with the environmentbase_onlyboolean
Indicates if this environment can only be used as a base for other environmentsscopestring enum
The scope of the environmentAllowed enum:
PROJECT,WORKSPACEnotestring
Note for this resourceagent_notestring
YAML note for AI agents operating on this resourceLast modified on Sep 15, 2026
Request example
curl -X POST "https://api.buddy.works/workspaces/:workspace/environments/yaml" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "Content-Type: application/json" \
-d '{
"yaml": "LSBlbnZpcm9ubWVudDo..."
}'