Home
Version 3
Spaces API

Spaces API

Associate Security Group with the Space

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

Fields

Name Description Default Valid Values Example Values

Parameters

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

Request

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI5MyIsImVtYWlsIjoiZW1haWwtMjI2QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjIzMjM1NTF9.l-7sHb4pk0Ru0TcW6flpAuWEp8tX1Qnbw8SMfnQXx5g
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

Route

PUT /v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352/security_groups/5dfaee52-2e32-4297-bef9-f2093b5fa3b9

cURL

curl "https://api.[your-domain.com]/v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352/security_groups/5dfaee52-2e32-4297-bef9-f2093b5fa3b9" -d '' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI5MyIsImVtYWlsIjoiZW1haWwtMjI2QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjIzMjM1NTF9.l-7sHb4pk0Ru0TcW6flpAuWEp8tX1Qnbw8SMfnQXx5g" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: b9782506-422c-4a5f-8080-43546726aed2
Content-Length: 1260
X-Content-Type-Options: nosniff

Status

201 Created

Body

{
  "metadata": {
    "guid": "14bc68b6-7cd2-4196-803b-c590edf64352",
    "url": "/v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352",
    "created_at": "2015-01-20T01:52:31+00:00",
    "updated_at": null
  },
  "entity": {
    "name": "name-1862",
    "organization_guid": "41115ad6-b58e-4c88-8f0a-6100d421ddab",
    "space_quota_definition_guid": null,
    "organization_url": "/v2/organizations/41115ad6-b58e-4c88-8f0a-6100d421ddab",
    "developers_url": "/v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352/developers",
    "managers_url": "/v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352/managers",
    "auditors_url": "/v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352/auditors",
    "apps_url": "/v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352/apps",
    "routes_url": "/v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352/routes",
    "domains_url": "/v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352/domains",
    "service_instances_url": "/v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352/service_instances",
    "app_events_url": "/v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352/app_events",
    "events_url": "/v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352/events",
    "security_groups_url": "/v2/spaces/14bc68b6-7cd2-4196-803b-c590edf64352/security_groups"
  }
}