List

  • GET
  • /workspaces
  • /:workspace
  • /variables

Returns the list of defined environment variables. If no query params are set, returns only workspace-scoped variables

Request

REQUIRED SCOPES
VARIABLE_INFO
URL PARAMETERS
workspacerequiredstring
The human-readable ID of the workspace

Example: "my-company"

GET PARAMETERS
project_namestring
The name of the project

Example: "my-project"

pipeline_idinteger
The ID of the pipeline

Example: 456

environment_idinteger
The ID of the environment

Example: 789

action_idinteger
The ID of the action

Example: 101

sandbox_idstring
The ID of the sandbox

Example: "u3ep173pzbjez"

Response

RESPONSE BODY
urlread-onlystring
API endpoint to GET this object
html_urlread-onlystring
Web URL to view this object in Buddy.works
variablesVariableView[]

Last modified on Jan 26, 2026

Request example

CURL
curl -X GET "https://api.buddy.works/workspaces/:workspace/variables" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "Content-Type: application/json"
EXAMPLE RESPONSE
{ "url": "https://api.buddy.works/workspaces/my-company/variables", "html_url": "https://buddy.works/my-company/-/environment-variables", "variables": [ { "url": "https://api.buddy.works/workspaces/my-company/variables/123", "html_url": "https://buddy.works/my-company/-/environment-variables/edit/123", "id": 123, "key": "API_TOKEN", "type": "VAR", "value": "secret-token-value", "encrypted": true, "description": "API token for external service", "settable": true, "run_only_settable": false }, { "url": "https://api.buddy.works/workspaces/my-company/variables/124", "html_url": "https://buddy.works/my-company/-/environment-variables/edit/124", "id": 124, "key": "SSH_KEY", "type": "SSH_KEY", "value": "!encrypted SmFXMKglBP8n...", "encrypted": true, "description": "SSH key for deployment", "settable": false, "file_path": "~/.ssh/id_deploy", "file_chmod": "600", "file_place": "CONTAINER" } ] }
STATUS
200 OK