List Variables
- GET
- /workspaces
- /:workspace
- /variables
Returns the list of defined environment variables. If no query params are set, returns only workspace-scoped variables
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://app.buddy.works/my-company/-/environment-variables",
"variables": [
{
"url": "https://api.buddy.works/workspaces/my-company/variables/123",
"html_url": "https://app.buddy.works/my-company/-/environment-variables/edit/123",
"id": 123,
"key": "API_TOKEN",
"type": "VAR",
"value": "secret-token-value",
"encrypted": true,
"settable": true,
"run_only_settable": false
},
{
"url": "https://api.buddy.works/workspaces/my-company/variables/124",
"html_url": "https://app.buddy.works/my-company/-/environment-variables/edit/124",
"id": 124,
"key": "SSH_KEY",
"type": "SSH_KEY",
"value": "!encrypted SmFXMKglBP8n...",
"encrypted": true,
"settable": false,
"file_path": "~/.ssh/id_deploy",
"file_chmod": "600",
"file_place": "CONTAINER"
},
{
"url": "https://api.buddy.works/workspaces/my-company/variables/125",
"html_url": "https://app.buddy.works/my-company/-/environment-variables/edit/125",
"id": 125,
"key": "config_json",
"type": "FILE",
"value": "eyJhcGlfa2V5IjogIjEyMzQ1Njc4OTAifQ==",
"settable": false,
"file_path": "/buddy-variables/config_json",
"file_chmod": "644",
"file_place": "CONTAINER",
"binary": false,
"checksum": "a1b2c3d4e5f6"
},
{
"url": "https://api.buddy.works/workspaces/my-company/variables/126",
"html_url": "https://app.buddy.works/my-company/-/environment-variables/edit/126",
"id": 126,
"key": "dist_certificate",
"type": "IOS_KEYCHAIN",
"value": "!encrypted MIIKYgIBAzCCCh4...",
"encrypted": true,
"settable": false,
"key_identifier": "Apple Distribution: My Company (XXXXXXXXXX)",
"checksum": "b2c3d4e5f6a1"
},
{
"url": "https://api.buddy.works/workspaces/my-company/variables/127",
"html_url": "https://app.buddy.works/my-company/-/environment-variables/edit/127",
"id": 127,
"key": "app_store_profile",
"type": "IOS_PROVISION_PROFILES",
"value": "!encrypted MIId3gYJKoZIhvc...",
"encrypted": true,
"settable": false,
"key_identifier": "App Store Profile",
"checksum": "c3d4e5f6a1b2"
}
]
}STATUS
200 OK