Home
Version 3
Users API

Users API

Remove Space from the User

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

Fields

Name Description Default Valid Values Example Values

Parameters

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

Request

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTg4IiwiZW1haWwiOiJlbWFpbC02M0Bzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDI0MTM3MzY1fQ.gQRaDMSrWTnO5cqEyHE02q5EmaCrX8G8VQvNY8nYH_4
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

Route

DELETE /v2/users/uaa-id-87/spaces/c0b384d1-09d2-48c5-a5ca-54dd71ba6ee0

cURL

curl "https://api.[your-domain.com]/v2/users/uaa-id-87/spaces/c0b384d1-09d2-48c5-a5ca-54dd71ba6ee0" -d '' -X DELETE \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTg4IiwiZW1haWwiOiJlbWFpbC02M0Bzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDI0MTM3MzY1fQ.gQRaDMSrWTnO5cqEyHE02q5EmaCrX8G8VQvNY8nYH_4" \
	-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: e2820d1b-0df6-4264-a55b-8a152c035e90
Content-Length: 836
X-Content-Type-Options: nosniff

Status

201 Created

Body

{
  "metadata": {
    "guid": "uaa-id-87",
    "url": "/v2/users/uaa-id-87",
    "created_at": "2015-02-10T01:42:44Z",
    "updated_at": null
  },
  "entity": {
    "admin": false,
    "active": false,
    "default_space_guid": "ae1fc5bb-25f5-4c95-8be8-08db99489ba5",
    "default_space_url": "/v2/spaces/ae1fc5bb-25f5-4c95-8be8-08db99489ba5",
    "spaces_url": "/v2/users/uaa-id-87/spaces",
    "organizations_url": "/v2/users/uaa-id-87/organizations",
    "managed_organizations_url": "/v2/users/uaa-id-87/managed_organizations",
    "billing_managed_organizations_url": "/v2/users/uaa-id-87/billing_managed_organizations",
    "audited_organizations_url": "/v2/users/uaa-id-87/audited_organizations",
    "managed_spaces_url": "/v2/users/uaa-id-87/managed_spaces",
    "audited_spaces_url": "/v2/users/uaa-id-87/audited_spaces"
  }
}