Home
Version 3
Spaces API

Spaces API

Associate Security Group with the Space

PUT /v2/spaces/:guid/security_groups/:security_group_guid

Request

Route

PUT /v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d/security_groups/5b9c3efc-633f-4bd9-a2ae-910a5e3d9f7d

Parameters

Name Description Valid Values Example Values
guid The guid of the Space

Body

Name Description Default Valid Values Example Values

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTg4IiwiZW1haWwiOiJlbWFpbC02OUBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDI5MDM4NzAxfQ.n-rgM0j706SXv5-XQjPY8Gehq02capUdPG5P7MPnYwk
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d/security_groups/5b9c3efc-633f-4bd9-a2ae-910a5e3d9f7d" -d '' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTg4IiwiZW1haWwiOiJlbWFpbC02OUBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDI5MDM4NzAxfQ.n-rgM0j706SXv5-XQjPY8Gehq02capUdPG5P7MPnYwk" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "bf59975e-01d7-4d78-aeda-ec6be528db3d",
    "url": "/v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d",
    "created_at": "2015-04-07T19:11:41Z",
    "updated_at": null
  },
  "entity": {
    "name": "name-268",
    "organization_guid": "65e3931a-01c6-45f0-9b2d-7047b08d6e4b",
    "space_quota_definition_guid": null,
    "organization_url": "/v2/organizations/65e3931a-01c6-45f0-9b2d-7047b08d6e4b",
    "developers_url": "/v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d/developers",
    "managers_url": "/v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d/managers",
    "auditors_url": "/v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d/auditors",
    "apps_url": "/v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d/apps",
    "routes_url": "/v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d/routes",
    "domains_url": "/v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d/domains",
    "service_instances_url": "/v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d/service_instances",
    "app_events_url": "/v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d/app_events",
    "events_url": "/v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d/events",
    "security_groups_url": "/v2/spaces/bf59975e-01d7-4d78-aeda-ec6be528db3d/security_groups"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 586c6498-3849-4521-b285-78c97b00887a
Content-Length: 1254
X-Content-Type-Options: nosniff