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-321/billing_managed_organizations/7fef152f-1bec-4cb4-a5c9-02c73a312982

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.eyJ1c2VyX2lkIjoidWFhLWlkLTMyMiIsImVtYWlsIjoiZW1haWwtMTk1QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDgwMzg5NjF9.6npmVI0GFh7-6ZIfv2uyqWmq6djJpVCEvKuHs_z2I6U
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v2/users/uaa-id-321/billing_managed_organizations/7fef152f-1bec-4cb4-a5c9-02c73a312982" -d '' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTMyMiIsImVtYWlsIjoiZW1haWwtMTk1QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDgwMzg5NjF9.6npmVI0GFh7-6ZIfv2uyqWmq6djJpVCEvKuHs_z2I6U" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "uaa-id-321",
    "url": "/v2/users/uaa-id-321",
    "created_at": "2015-11-13T17:02:41Z",
    "updated_at": null
  },
  "entity": {
    "admin": false,
    "active": false,
    "default_space_guid": "5346a1a1-8816-45ef-9d07-0ae47c6530ef",
    "default_space_url": "/v2/spaces/5346a1a1-8816-45ef-9d07-0ae47c6530ef",
    "spaces_url": "/v2/users/uaa-id-321/spaces",
    "organizations_url": "/v2/users/uaa-id-321/organizations",
    "managed_organizations_url": "/v2/users/uaa-id-321/managed_organizations",
    "billing_managed_organizations_url": "/v2/users/uaa-id-321/billing_managed_organizations",
    "audited_organizations_url": "/v2/users/uaa-id-321/audited_organizations",
    "managed_spaces_url": "/v2/users/uaa-id-321/managed_spaces",
    "audited_spaces_url": "/v2/users/uaa-id-321/audited_spaces"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 
Content-Length: 845
X-Content-Type-Options: nosniff