Home
Version 3
Users API

Users API

Associate Billing Managed Organization with the User

PUT /v2/users/:guid/billing_managed_organizations/:billing_managed_organization_guid

Request

Route

PUT /v2/users/uaa-id-36/billing_managed_organizations/45ad95b6-cd54-44de-b8f6-05c22070fce3

Parameters

Name Description Valid Values Example Values
guid The guid of the User
billing_managed_organization_guid The guid of the billing managed organization

Headers

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

cURL

curl "https://api.[your-domain.com]/v2/users/uaa-id-36/billing_managed_organizations/45ad95b6-cd54-44de-b8f6-05c22070fce3" -d '' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTM3IiwiZW1haWwiOiJlbWFpbC0xN0Bzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDQxNjYyNTk0fQ.iZ0_F2vBGl3Q1vs90s8PE5PGDzLbczV6QPVFkZOLAec" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "uaa-id-36",
    "url": "/v2/users/uaa-id-36",
    "created_at": "2015-08-31T21:49:54Z",
    "updated_at": null
  },
  "entity": {
    "admin": false,
    "active": false,
    "default_space_guid": "e8f0535c-0b07-4f3b-883a-bb606c7b53d3",
    "default_space_url": "/v2/spaces/e8f0535c-0b07-4f3b-883a-bb606c7b53d3",
    "spaces_url": "/v2/users/uaa-id-36/spaces",
    "organizations_url": "/v2/users/uaa-id-36/organizations",
    "managed_organizations_url": "/v2/users/uaa-id-36/managed_organizations",
    "billing_managed_organizations_url": "/v2/users/uaa-id-36/billing_managed_organizations",
    "audited_organizations_url": "/v2/users/uaa-id-36/audited_organizations",
    "managed_spaces_url": "/v2/users/uaa-id-36/managed_spaces",
    "audited_spaces_url": "/v2/users/uaa-id-36/audited_spaces"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 105d99a2-f401-4bb4-b693-b413134691b2
Content-Length: 836
X-Content-Type-Options: nosniff