Creating an Organization
POST /v2/organizations/
Request
Route
POST /v2/organizations
Body
Name |
Description |
Default |
Valid Values |
Example Values |
name
|
The name of the organization
|
|
|
|
status
|
Status of the organization
|
|
|
|
quota_definition_guid
|
The guid of quota to associate with this organization
|
|
|
|
billing_enabled
|
If billing is enabled for this organization
|
|
|
|
{
"name": "my-org-name",
"quota_definition_guid": "96a487a8-3d64-4a19-a8aa-9367705d9bfc"
}
Headers
cURL
curl "https://api.[your-domain.com]/v2/organizations" -d '{
"name": "my-org-name",
"quota_definition_guid": "96a487a8-3d64-4a19-a8aa-9367705d9bfc"
}' -X POST \
-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTExNSIsImVtYWlsIjoiZW1haWwtMTEzQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDcxMTY4Mzd9.JSmTIcBneS_qbZYSlMD5oN4Bsng15nobmi_r-JXam8M" \
-H "Host: example.org" \
-H "Content-Type: application/x-www-form-urlencoded" \
-H "Cookie: "
Response
Status
201 Created
Body
{
"metadata": {
"guid": "ce658e54-76cd-4ff8-8b30-1dc7fcd2f629",
"url": "/v2/organizations/ce658e54-76cd-4ff8-8b30-1dc7fcd2f629",
"created_at": "2015-11-03T00:53:57Z",
"updated_at": null
},
"entity": {
"name": "my-org-name",
"billing_enabled": false,
"quota_definition_guid": "96a487a8-3d64-4a19-a8aa-9367705d9bfc",
"status": "active",
"quota_definition_url": "/v2/quota_definitions/96a487a8-3d64-4a19-a8aa-9367705d9bfc",
"spaces_url": "/v2/organizations/ce658e54-76cd-4ff8-8b30-1dc7fcd2f629/spaces",
"domains_url": "/v2/organizations/ce658e54-76cd-4ff8-8b30-1dc7fcd2f629/domains",
"private_domains_url": "/v2/organizations/ce658e54-76cd-4ff8-8b30-1dc7fcd2f629/private_domains",
"users_url": "/v2/organizations/ce658e54-76cd-4ff8-8b30-1dc7fcd2f629/users",
"managers_url": "/v2/organizations/ce658e54-76cd-4ff8-8b30-1dc7fcd2f629/managers",
"billing_managers_url": "/v2/organizations/ce658e54-76cd-4ff8-8b30-1dc7fcd2f629/billing_managers",
"auditors_url": "/v2/organizations/ce658e54-76cd-4ff8-8b30-1dc7fcd2f629/auditors",
"app_events_url": "/v2/organizations/ce658e54-76cd-4ff8-8b30-1dc7fcd2f629/app_events",
"space_quota_definitions_url": "/v2/organizations/ce658e54-76cd-4ff8-8b30-1dc7fcd2f629/space_quota_definitions"
}
}
Headers