Update a Space
PUT /v2/spaces/:guid
Request
Route
PUT /v2/spaces/d801a3d7-adbe-42d8-91fc-03649f8c9631
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-9c8f4cd2-75c8-4d50-8e26-5f3c9a8971f2
|
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/d801a3d7-adbe-42d8-91fc-03649f8c9631" -d '{
"name": "New Space Name"
}' -X PUT \
-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTEyMiIsImVtYWlsIjoiZW1haWwtMTIxQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MzIzMTM2MTR9.V2lHHDhTFLMup31axBJ8oYB-l8yMfB-FKiyrPv31YWs" \
-H "Host: example.org" \
-H "Content-Type: application/x-www-form-urlencoded" \
-H "Cookie: "
Response
Status
201 Created
Body
{
"metadata": {
"guid": "d801a3d7-adbe-42d8-91fc-03649f8c9631",
"url": "/v2/spaces/d801a3d7-adbe-42d8-91fc-03649f8c9631",
"created_at": "2015-05-15T16:53:34Z",
"updated_at": "2015-05-15T16:53:34Z"
},
"entity": {
"name": "New Space Name",
"organization_guid": "5376ed95-c304-4626-be49-a8698c7d8a0d",
"space_quota_definition_guid": null,
"allow_ssh": true,
"organization_url": "/v2/organizations/5376ed95-c304-4626-be49-a8698c7d8a0d",
"developers_url": "/v2/spaces/d801a3d7-adbe-42d8-91fc-03649f8c9631/developers",
"managers_url": "/v2/spaces/d801a3d7-adbe-42d8-91fc-03649f8c9631/managers",
"auditors_url": "/v2/spaces/d801a3d7-adbe-42d8-91fc-03649f8c9631/auditors",
"apps_url": "/v2/spaces/d801a3d7-adbe-42d8-91fc-03649f8c9631/apps",
"routes_url": "/v2/spaces/d801a3d7-adbe-42d8-91fc-03649f8c9631/routes",
"domains_url": "/v2/spaces/d801a3d7-adbe-42d8-91fc-03649f8c9631/domains",
"service_instances_url": "/v2/spaces/d801a3d7-adbe-42d8-91fc-03649f8c9631/service_instances",
"app_events_url": "/v2/spaces/d801a3d7-adbe-42d8-91fc-03649f8c9631/app_events",
"events_url": "/v2/spaces/d801a3d7-adbe-42d8-91fc-03649f8c9631/events",
"security_groups_url": "/v2/spaces/d801a3d7-adbe-42d8-91fc-03649f8c9631/security_groups"
}
}
Headers
Audit Records Created By The Request
Audit Record: audit.space.update
Attribute Name |
Value |
id
|
8
|
guid
|
669463f4-8388-4b2c-be84-4d62273b59b4
|
created_at
|
2015-05-15 16:53:34 UTC
|
updated_at
|
|
timestamp
|
2015-05-15 16:53:34 UTC
|
type
|
audit.space.update
|
actor
|
uaa-id-122
|
actor_type
|
user
|
actee
|
d801a3d7-adbe-42d8-91fc-03649f8c9631
|
actee_type
|
space
|
metadata
|
{
"request": {
"name": "New Space Name"
}
}
|
space_id
|
1
|
organization_guid
|
5376ed95-c304-4626-be49-a8698c7d8a0d
|
space_guid
|
d801a3d7-adbe-42d8-91fc-03649f8c9631
|
actor_name
|
email-121@somedomain.com
|
actee_name
|
New Space Name
|