Home
Version 3
Users API

Users API

Remove Managed Space from the User

DELETE /v2/users/:guid/managed_spaces/:managed_space_guid

Request

Route

DELETE /v2/users/uaa-id-422/managed_spaces/82cdc69d-761d-4aca-85f9-30533ddfa1bf

Parameters

Name Description Valid Values Example Values
guid The guid of the User
managed_space_guid The guid of the managed space

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTQyMyIsImVtYWlsIjoiZW1haWwtMjkzQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDI2MDE1NTB9._kDG-MnXfpDsZBr3HVBvi1VErY87V96Plj2IZmiK_3w
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v2/users/uaa-id-422/managed_spaces/82cdc69d-761d-4aca-85f9-30533ddfa1bf" -d '' -X DELETE \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTQyMyIsImVtYWlsIjoiZW1haWwtMjkzQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDI2MDE1NTB9._kDG-MnXfpDsZBr3HVBvi1VErY87V96Plj2IZmiK_3w" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "uaa-id-422",
    "url": "/v2/users/uaa-id-422",
    "created_at": "2015-09-11T18:39:10Z",
    "updated_at": null
  },
  "entity": {
    "admin": false,
    "active": false,
    "default_space_guid": "6ddc55a7-61a7-45ea-a7b3-f55fe1a44279",
    "default_space_url": "/v2/spaces/6ddc55a7-61a7-45ea-a7b3-f55fe1a44279",
    "spaces_url": "/v2/users/uaa-id-422/spaces",
    "organizations_url": "/v2/users/uaa-id-422/organizations",
    "managed_organizations_url": "/v2/users/uaa-id-422/managed_organizations",
    "billing_managed_organizations_url": "/v2/users/uaa-id-422/billing_managed_organizations",
    "audited_organizations_url": "/v2/users/uaa-id-422/audited_organizations",
    "managed_spaces_url": "/v2/users/uaa-id-422/managed_spaces",
    "audited_spaces_url": "/v2/users/uaa-id-422/audited_spaces"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 3c1828e7-aea9-47a7-b8b6-d19265a4f4f7
Content-Length: 845
X-Content-Type-Options: nosniff