List
- GET
- /workspaces
- /:workspace
- /variables
Returns the list of defined environment variables. If no query params are set, returns only workspace-scoped variables
Request example
CURLcurl -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" } ] }
STATUS200 OK