Organizations API

Associate Manager with the Organization by Username

PUT v2/organizations/:guid/managers

Request

Route

PUT v2/organizations/9f123a87-a3aa-483a-91a5-fd21e17a92cc/managers

Parameters

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

Body

Name Description Default Valid Values Example Values
username The user's name
origin The UAA origin that the user is registered with
  • ldap
{
  "username": "[email protected]"
}

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTIxMiIsImVtYWlsIjoiZW1haWwtMTU5QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NjYwMDg4OTR9.KbvFAkEoxgv85Sz0MNTun4pLR9kgLuflRg-0OkjdtaM
Host: example.org
Content-Type: application/json
Cookie: 

cURL

curl "https://api.[your-domain.com]v2/organizations/9f123a87-a3aa-483a-91a5-fd21e17a92cc/managers" -d '{
  "username": "[email protected]"
}' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTIxMiIsImVtYWlsIjoiZW1haWwtMTU5QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NjYwMDg4OTR9.KbvFAkEoxgv85Sz0MNTun4pLR9kgLuflRg-0OkjdtaM" \
	-H "Host: example.org" \
	-H "Content-Type: application/json" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "9f123a87-a3aa-483a-91a5-fd21e17a92cc",
    "url": "/v2/organizations/9f123a87-a3aa-483a-91a5-fd21e17a92cc",
    "created_at": "2016-06-08T16:41:34Z",
    "updated_at": "2016-06-08T16:41:26Z"
  },
  "entity": {
    "name": "name-1729",
    "billing_enabled": false,
    "quota_definition_guid": "c242bf0b-b1bb-4515-b116-d6d0c9462c69",
    "status": "active",
    "quota_definition_url": "/v2/quota_definitions/c242bf0b-b1bb-4515-b116-d6d0c9462c69",
    "spaces_url": "/v2/organizations/9f123a87-a3aa-483a-91a5-fd21e17a92cc/spaces",
    "domains_url": "/v2/organizations/9f123a87-a3aa-483a-91a5-fd21e17a92cc/domains",
    "private_domains_url": "/v2/organizations/9f123a87-a3aa-483a-91a5-fd21e17a92cc/private_domains",
    "users_url": "/v2/organizations/9f123a87-a3aa-483a-91a5-fd21e17a92cc/users",
    "managers_url": "/v2/organizations/9f123a87-a3aa-483a-91a5-fd21e17a92cc/managers",
    "billing_managers_url": "/v2/organizations/9f123a87-a3aa-483a-91a5-fd21e17a92cc/billing_managers",
    "auditors_url": "/v2/organizations/9f123a87-a3aa-483a-91a5-fd21e17a92cc/auditors",
    "app_events_url": "/v2/organizations/9f123a87-a3aa-483a-91a5-fd21e17a92cc/app_events",
    "space_quota_definitions_url": "/v2/organizations/9f123a87-a3aa-483a-91a5-fd21e17a92cc/space_quota_definitions"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: e42d9742-197b-4fdc-abc5-0c09abc7638f
Content-Length: 1300
X-Content-Type-Options: nosniff