Home
Version 3
Users API

Users API

Remove Space from the User

DELETE /v2/users/:guid/spaces/:space_guid

Request

Route

DELETE /v2/users/uaa-id-276/spaces/10b5e3d0-2b39-4b8b-b5ab-4b29b7586f37

Parameters

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

Body

Name Description Default Valid Values Example Values

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI3NyIsImVtYWlsIjoiZW1haWwtMTkxQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjU5NDg2NzB9.4pAJI6DEE-MtYhBhkak--UG4fB-obVNGxgaYCMhM4dQ
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v2/users/uaa-id-276/spaces/10b5e3d0-2b39-4b8b-b5ab-4b29b7586f37" -d '' -X DELETE \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI3NyIsImVtYWlsIjoiZW1haWwtMTkxQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjU5NDg2NzB9.4pAJI6DEE-MtYhBhkak--UG4fB-obVNGxgaYCMhM4dQ" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "uaa-id-276",
    "url": "/v2/users/uaa-id-276",
    "created_at": "2015-03-03T00:51:10Z",
    "updated_at": null
  },
  "entity": {
    "admin": false,
    "active": false,
    "default_space_guid": "87cb4614-ff83-4956-93b3-020291f8312e",
    "default_space_url": "/v2/spaces/87cb4614-ff83-4956-93b3-020291f8312e",
    "spaces_url": "/v2/users/uaa-id-276/spaces",
    "organizations_url": "/v2/users/uaa-id-276/organizations",
    "managed_organizations_url": "/v2/users/uaa-id-276/managed_organizations",
    "billing_managed_organizations_url": "/v2/users/uaa-id-276/billing_managed_organizations",
    "audited_organizations_url": "/v2/users/uaa-id-276/audited_organizations",
    "managed_spaces_url": "/v2/users/uaa-id-276/managed_spaces",
    "audited_spaces_url": "/v2/users/uaa-id-276/audited_spaces"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: c6771cba-74bf-4b2a-9266-85ba1312a307
Content-Length: 845
X-Content-Type-Options: nosniff