Home
Version 3
Organizations API

Organizations API

Associate Manager with the Organization by Username (experimental)

PUT v2/organizations/:guid/managers

Request

Route

PUT v2/organizations/cd05c8ca-f425-4f61-afc8-4b15de2952c5/managers

Parameters

Name Description Valid Values Example Values
guid The guid of the Organization
manager_guid The guid of the user to associate as a manager
{
  "username": "user@example.com"
}

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTExNCIsImVtYWlsIjoiZW1haWwtNjlAc29tZWRvbWFpbi5jb20iLCJzY29wZSI6WyJjbG91ZF9jb250cm9sbGVyLmFkbWluIl0sImF1ZCI6WyJjbG91ZF9jb250cm9sbGVyIl0sImV4cCI6MTQ0MjYwMTUyOX0.2VTpPhASp0fsGg3wMfBTo8hnTx44jYR9eROXvPehcAw
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]v2/organizations/cd05c8ca-f425-4f61-afc8-4b15de2952c5/managers" -d '{
  "username": "user@example.com"
}' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTExNCIsImVtYWlsIjoiZW1haWwtNjlAc29tZWRvbWFpbi5jb20iLCJzY29wZSI6WyJjbG91ZF9jb250cm9sbGVyLmFkbWluIl0sImF1ZCI6WyJjbG91ZF9jb250cm9sbGVyIl0sImV4cCI6MTQ0MjYwMTUyOX0.2VTpPhASp0fsGg3wMfBTo8hnTx44jYR9eROXvPehcAw" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "cd05c8ca-f425-4f61-afc8-4b15de2952c5",
    "url": "/v2/organizations/cd05c8ca-f425-4f61-afc8-4b15de2952c5",
    "created_at": "2015-09-11T18:38:49Z",
    "updated_at": null
  },
  "entity": {
    "name": "name-284",
    "billing_enabled": false,
    "quota_definition_guid": "f0de6a26-396b-4826-8a76-8321aee3aa38",
    "status": "active",
    "quota_definition_url": "/v2/quota_definitions/f0de6a26-396b-4826-8a76-8321aee3aa38",
    "spaces_url": "/v2/organizations/cd05c8ca-f425-4f61-afc8-4b15de2952c5/spaces",
    "domains_url": "/v2/organizations/cd05c8ca-f425-4f61-afc8-4b15de2952c5/domains",
    "private_domains_url": "/v2/organizations/cd05c8ca-f425-4f61-afc8-4b15de2952c5/private_domains",
    "users_url": "/v2/organizations/cd05c8ca-f425-4f61-afc8-4b15de2952c5/users",
    "managers_url": "/v2/organizations/cd05c8ca-f425-4f61-afc8-4b15de2952c5/managers",
    "billing_managers_url": "/v2/organizations/cd05c8ca-f425-4f61-afc8-4b15de2952c5/billing_managers",
    "auditors_url": "/v2/organizations/cd05c8ca-f425-4f61-afc8-4b15de2952c5/auditors",
    "app_events_url": "/v2/organizations/cd05c8ca-f425-4f61-afc8-4b15de2952c5/app_events",
    "space_quota_definitions_url": "/v2/organizations/cd05c8ca-f425-4f61-afc8-4b15de2952c5/space_quota_definitions"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: f3ff40fb-d86b-434e-ba8d-3a5b33294802
Content-Length: 1299
X-Content-Type-Options: nosniff