Create organization
Create a new organization for a user. Sub-organization creation availability depends on
the organization’s capabilities. The optional profile object accepts partial profile
details; its individual fields are not required. Organization names are limited to 65
UTF-8 bytes. Each profile field is limited to 1,000 UTF-8 bytes, and a non-empty business
email must be valid. At least one of business name, address, phone, or email must be
non-empty to persist a profile.
Security
API Token
The preferred authorization scheme for interacting with the Cloudflare API. Create a token.
API Email + API Key
The previous authorization scheme for interacting with the Cloudflare API, used in conjunction with a Global API key.
The previous authorization scheme for interacting with the Cloudflare API. When possible, use API tokens instead of Global API keys.
Accepted Permissions (at least one required)
Create organization
curl https://api.cloudflare.com/client/v4/organizations \
-H 'Content-Type: application/json' \
-H "Authorization: Bearer $CLOUDFLARE_API_TOKEN" \
-d '{
"name": "x"
}'{
"errors": [],
"messages": [
{
"code": 1000,
"message": "message",
"documentation_url": "documentation_url",
"source": {
"pointer": "pointer"
}
}
],
"result": {
"id": "a7b9c3d2e8f4a1b5c6d0e9f2a3b7c4d8",
"create_time": "2019-12-27T18:11:19.117Z",
"meta": {
"are_child_accounts_accessible_by_org_members": true,
"hierarchy_tags": [
"string"
],
"managed_by": "managed_by",
"tenant_flags": {
"account_creation": "account_creation",
"account_creation_applies_tenant_defaults": "account_creation_applies_tenant_defaults",
"account_deletion": "account_deletion",
"account_migration": "account_migration",
"account_mobility": "account_mobility",
"enterprise_capability": "enterprise_capability",
"member_management": "member_management",
"sub_org_creation": "sub_org_creation"
},
"tenant_type": "tenant_type"
},
"name": "name",
"parent": {
"id": "a7b9c3d2e8f4a1b5c6d0e9f2a3b7c4d8",
"name": "name"
},
"profile": {
"business_address": "business_address",
"business_email": "business_email",
"business_name": "business_name",
"business_phone": "business_phone",
"external_metadata": "external_metadata"
}
},
"success": true
}Returns Examples
{
"errors": [],
"messages": [
{
"code": 1000,
"message": "message",
"documentation_url": "documentation_url",
"source": {
"pointer": "pointer"
}
}
],
"result": {
"id": "a7b9c3d2e8f4a1b5c6d0e9f2a3b7c4d8",
"create_time": "2019-12-27T18:11:19.117Z",
"meta": {
"are_child_accounts_accessible_by_org_members": true,
"hierarchy_tags": [
"string"
],
"managed_by": "managed_by",
"tenant_flags": {
"account_creation": "account_creation",
"account_creation_applies_tenant_defaults": "account_creation_applies_tenant_defaults",
"account_deletion": "account_deletion",
"account_migration": "account_migration",
"account_mobility": "account_mobility",
"enterprise_capability": "enterprise_capability",
"member_management": "member_management",
"sub_org_creation": "sub_org_creation"
},
"tenant_type": "tenant_type"
},
"name": "name",
"parent": {
"id": "a7b9c3d2e8f4a1b5c6d0e9f2a3b7c4d8",
"name": "name"
},
"profile": {
"business_address": "business_address",
"business_email": "business_email",
"business_name": "business_name",
"business_phone": "business_phone",
"external_metadata": "external_metadata"
}
},
"success": true
}