The /organisation
endpoint of the Disguise Cloud API returns information about the authenticated user’s organisation
that the token is scoped to.
The responses from all /organisation
endpoints includes the following fields:
Field | Type | Description |
---|---|---|
id | string | The unique identifier of the organisation. |
name | string | The name of the organisation. |
owner_id | string | The unique identifier of the owner. |
user_role_on_org | string | The role of your user within the organisation. |
current_plan | string | The current subscription plan of the organisation, usually Starter, Pro, or Studio. |
trial_ends_at | string | The end date of the trial period if applicable. |
members_count | integer | The number of members in the organisation. |
used_seats_count | integer | The number of seats currently used out of the organisation’s seat total. |
seats_total | integer | The total number of seats available, regardless of used status. |
seats_available_on_plan | integer | The number of seats available on the current plan, regardless of the organisation’s total seats. Example: Studio allows up to 25 seats, but you may have only purchased 10 of those. In that case, this field will be 25 and the seats_total field will be 10. |
drive_count | integer | The number of drives in the organisation. |
drive_limit | integer | The maximum number of drives allowed on the organisation, usually determined by the plan. |
available_drives | integer | The number of available drives, calculated based on used drives minus the drive limit. |
entitlement_domain | string | The entitlement domain of the organisation (example: disguise.cloud). |
entitlement_enabled | boolean | Whether entitlement is enabled for the organisation, when enabled anyone with an email from the same domain as above will be allowed to request to join this organisation. |
curl -X GET https://api.disguise.cloud/v1/organisation \
-H "Authorization: Token YOUR_API_TOKEN"
A successful response will return a 200 OK
status code and the following JSON:
Please note this example excludes the pagination wrapper around the response. Please refer to the pagination documentation for more information.
[
{
"id": "5ab6448f-72e2-4fd7-8929-2e9c94bff342",
"name": "Disguise Inc.",
"owner_id": "1a2b3c4d-5e6f-7g8h-9i0j-1k2l3m4n5o6p",
"user_role_on_org": "admin",
"current_plan": "Pro",
"trial_ends_at": "2024-12-31T23:59:59.000000Z",
"members_count": 5,
"used_seats_count": 5,
"seats_total": 5,
"seats_available_on_plan": 10,
"drive_count": 2,
"drive_limit": 10,
"available_drives": 8,
"entitlement_domain": "disguise.cloud",
"entitlement_enabled": true
}
]
If the organisation is not found, the API will return a 404 Not Found
status code and the following JSON:
{
"error": {
"message": "Organisation not found",
"details": "Organisation not found"
}
}
The following parameters can be used with the /organisation
endpoint for PATCH requests:
Parameter | Type | Description |
---|---|---|
name | string | The name of the organisation. |
entitlement_enabled | boolean | Whether entitlements are enabled for the organisation. true: When enabling, entitlements will be created for every existing user in the system that matches the organisation’s domain. false: When disabling, entitlements (including pending) will be removed for all users in the organisation. |
Below is an example of making a PATCH request to the /organisation
endpoint to update the organisation’s name and enable entitlement.
curl -X PATCH https://api.disguise.cloud/v1/organisation/YOUR_ORG_ID \
-H "Authorization: Token YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "Disguise Inc.",
"entitlement_enabled": true
}'