GET/stacks/:stack_id/settings/:id
Get Stack Settingpublic
Required Parameters
stack_id
stringThe stack UID
id
stringThe setting item ID
Get information of a single setting item.
Related Models:Stack Setting
Request
GET
/stacks/:stack_id/settings/:idcurl -X GET \
"https://app.cloud66.com/api/3/stacks/:stack_id/settings/:id" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json"
Response
{
"response": {
"key": "git.branch",
"value": "master"
}
}
GET/stacks/:stack_id/settings
List Stack Settingsadmin
Required Parameters
stack_id
stringThe stack UID
Get list of all settings for a stack.
Request
GET
/stacks/:stack_id/settingscurl -X GET \
"https://app.cloud66.com/api/3/stacks/:stack_id/settings" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json"
Response
{
"response": [
{
"id": 1,
"key": "stack.timezone",
"value": "UTC",
"readonly": false,
"created_at": "2014-08-29T17:21:25Z",
"updated_at": "2014-08-29T17:21:25Z"
}
],
"count": 1,
"pagination": {
"previous": null,
"next": null,
"current": 1,
"per_page": 30,
"count": 1,
"pages": 1
}
}
PUT/stacks/:stack_id/settings/:id
Update Stack Settingadmin
Required Parameters
stack_id
stringThe stack UID
id
integerThe setting item ID
value
stringThe setting item new value
Update value of a setting item.
Related Models:Stack Setting
Request
PUT
/stacks/:stack_id/settings/:idcurl -X PUT \
"https://app.cloud66.com/api/3/stacks/:stack_id/settings/:id" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"stack_id": "5999b763474b0eafa5fafb64bff0ba80",
"id": "git-branch",
"value": "staging"
}'
Response
{
"response": {
"id": 7,
"user": "test@cloud66.com",
"resource_type": "stack",
"action": "stack-set: git.branch",
"resource_id": "280",
"started_via": "api",
"started_at": "2014-09-01T12:47:24Z",
"finished_at": null,
"finished_success": null,
"finished_message": null
}
}