Home
Version 3
Users API

Users API

Remove Organization from the User

DELETE /v2/users/:guid/organizations/:organization_guid

Request

Route

DELETE /v2/users/uaa-id-16/organizations/54828aa6-7f45-4cb6-88f3-bef291e361fd

Parameters

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

Headers

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

cURL

curl "https://api.[your-domain.com]/v2/users/uaa-id-16/organizations/54828aa6-7f45-4cb6-88f3-bef291e361fd" -d '' -X DELETE \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTE3IiwiZW1haWwiOiJlbWFpbC03QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDU1NTc5Mjd9.V5j7iwIOT62HcHmFgCrYZoLHzAm1WcmGHR8uVZ0NzD4" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "uaa-id-16",
    "url": "/v2/users/uaa-id-16",
    "created_at": "2015-10-15T23:52:07Z",
    "updated_at": null
  },
  "entity": {
    "admin": false,
    "active": false,
    "default_space_guid": "fc460785-ec42-4236-b8ad-775187ac6c02",
    "default_space_url": "/v2/spaces/fc460785-ec42-4236-b8ad-775187ac6c02",
    "spaces_url": "/v2/users/uaa-id-16/spaces",
    "organizations_url": "/v2/users/uaa-id-16/organizations",
    "managed_organizations_url": "/v2/users/uaa-id-16/managed_organizations",
    "billing_managed_organizations_url": "/v2/users/uaa-id-16/billing_managed_organizations",
    "audited_organizations_url": "/v2/users/uaa-id-16/audited_organizations",
    "managed_spaces_url": "/v2/users/uaa-id-16/managed_spaces",
    "audited_spaces_url": "/v2/users/uaa-id-16/audited_spaces"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 8746da71-6ef7-42e2-9d69-cf99a68eb21d
Content-Length: 836
X-Content-Type-Options: nosniff