Update a Space
PUT /v2/spaces/:guid
Request
Route
PUT /v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e
Parameters
Name |
Description |
Valid Values |
Example Values |
guid
|
The guid of the Space
|
|
|
Body
Name |
Description |
Default |
Valid Values |
Example Values |
name
|
The name of the space
|
|
|
- development
- demo
- production
|
organization_guid
|
The guid of the associated organization
|
|
|
- guid-3d360cf0-76fd-467c-a184-ae6e50e4a335
|
developer_guids
|
The list of the associated developers
|
|
|
|
manager_guids
|
The list of the associated managers
|
|
|
|
auditor_guids
|
The list of the associated auditors
|
|
|
|
domain_guids
|
The list of the associated domains
|
|
|
|
security_group_guids
|
The list of the associated security groups
|
|
|
|
allow_ssh
|
Whether or not Space Developers can enable ssh on apps in the space
|
|
|
|
{
"name": "New Space Name"
}
Headers
cURL
curl "https://api.[your-domain.com]/v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e" -d '{
"name": "New Space Name"
}' -X PUT \
-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI1OSIsImVtYWlsIjoiZW1haWwtMTk1QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NTM4MzcyNzV9.Tl6wHoUV2KQGcIy71eIoFuI6JsRipxqxp7QIpUpjXqE" \
-H "Host: example.org" \
-H "Content-Type: application/x-www-form-urlencoded" \
-H "Cookie: "
Response
Status
201 Created
Body
{
"metadata": {
"guid": "02354a20-174e-42f4-9225-aa4cd96a8b6e",
"url": "/v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e",
"created_at": "2016-01-19T19:41:15Z",
"updated_at": "2016-01-19T19:41:15Z"
},
"entity": {
"name": "New Space Name",
"organization_guid": "0a49dc96-e509-4815-aa4d-806794ef900f",
"space_quota_definition_guid": null,
"allow_ssh": true,
"organization_url": "/v2/organizations/0a49dc96-e509-4815-aa4d-806794ef900f",
"developers_url": "/v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e/developers",
"managers_url": "/v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e/managers",
"auditors_url": "/v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e/auditors",
"apps_url": "/v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e/apps",
"routes_url": "/v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e/routes",
"domains_url": "/v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e/domains",
"service_instances_url": "/v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e/service_instances",
"app_events_url": "/v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e/app_events",
"events_url": "/v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e/events",
"security_groups_url": "/v2/spaces/02354a20-174e-42f4-9225-aa4cd96a8b6e/security_groups"
}
}
Headers
Audit Records Created By The Request
Audit Record: audit.space.update
Attribute Name |
Value |
id
|
183
|
guid
|
c99a7f65-c13f-499a-a988-19b869012ac1
|
created_at
|
2016-01-19 19:41:15 UTC
|
updated_at
|
|
timestamp
|
2016-01-19 19:41:15 UTC
|
type
|
audit.space.update
|
actor
|
uaa-id-259
|
actor_type
|
user
|
actee
|
02354a20-174e-42f4-9225-aa4cd96a8b6e
|
actee_type
|
space
|
metadata
|
{
"request": {
"name": "New Space Name"
}
}
|
space_id
|
|
organization_guid
|
0a49dc96-e509-4815-aa4d-806794ef900f
|
space_guid
|
02354a20-174e-42f4-9225-aa4cd96a8b6e
|
actor_name
|
email-195@somedomain.com
|
actee_name
|
New Space Name
|