Show examples in:
JavascriptHTTP
Endpoint info
Available examples
Dashboard API > Organization

Retrieve an organization

Warning: Experimental API

Please note that the Dashboard API is an experimental, prerelease API. This API method is considered unstable, and should be avoided in production environments and automations. Changes may occur at any time without warning.

Query parameters

includestring

Comma-separated list of relationship paths. A relationship path is a dot-separated list of relationship names. Allowed relationship paths: item_types, item_types.fields, item_types.fieldsets, item_types.singleton_item, account.

Example:"billing_profile,active_subscription,active_subscription.plan"

Returns

Returns a resource object of type organization.

Examples

GET https://site-api.datocms.com/organizations/:field_id_or_api_key HTTP/1.1
Authorization: Bearer YOUR-API-TOKEN
Accept: application/json
X-Api-Version: 3
Terminal window
curl -g 'https://site-api.datocms.com/organizations/:field_id_or_api_key' \
\
-H "Authorization: Bearer YOUR-API-TOKEN" \
-H "Accept: application/json" \
-H "X-Api-Version: 3"
await fetch("https://site-api.datocms.com/organizations/:field_id_or_api_key", {
headers: {
Authorization: "Bearer YOUR-API-TOKEN",
Accept: "application/json",
"X-Api-Version": "3",
},
});
HTTP/1.1 200 OK
Content-Type: application/json
Cache-Control: cache-control: max-age=0, private, must-revalidate
X-RateLimit-Limit: 30
X-RateLimit-Remaining: 28
{
"data": {
"type": "organization",
"id": "124",
"attributes": {
"name": ""
},
"meta": {
"discount_on_public_plans": 20,
"agency_partner": null
},
"relationships": {
"active_subscription": {
"data": {
"type": "per_owner_pricing_subscription",
"id": "124"
}
},
"billing_profile": {
"data": null
}
}
}
}