List teams
Overview
Lists teams owned by the account, with the default team first and the rest ordered by name. active_team_id identifies the team assigned to your API key. permission_catalog lists available role permissions. held_resources counts resources that prevent team deletion; zero counts are omitted.
Permissions
Requires the account permission teams.read (View teams).
Authorization
Your API key, sent as a bearer token. Create one in the control panel under API Keys, give it only the permissions the integration needs, and copy it when it is created. It cannot be shown again. Each key is restricted to one owned team. The key determines the team for every request.
Send it as Bearer <token>.
Response 200
application/jsonThe record, as a JSON object. There is no envelope.
The teams, each described as the reader sees it.
Show child attributesHide child attributes
The id ID.
The value of uuid_short.
The name shown to customers.
Whether the resource is owner.
Where a resource lands when nothing has said otherwise, and the team a session falls back to. Exactly one of an account's teams carries it, which the database enforces rather than trusts.
Which team the browser is currently working in, compared against the id the resolver settled on rather than against the raw session key. An account may own several teams, so "the one you own" stopped being an answer the moment the session key was empty - every one of them would have read as active at once.
Whether the team pays up front or by the hour on a monthly invoice. Chosen at creation and never changed.
One of: prepaid, postpaid
The value of owner.
Show child attributesHide child attributes
The name shown to customers.
The email address.
The value of gravatar_url.
The value of role.
Show child attributesHide child attributes
The id ID.
The value of uuid_short.
The name shown to customers.
Whether the resource is system.
The value of permissions.
Only the owner may leave nothing behind; an owner cannot leave their own account, which is why this is not simply ! is_owner.
The number of members count.
What is still inside the team, so the listing can say it before a deletion is attempted rather than only in the refusal that comes back from one. Both are read from the same method deliberately: a preview that disagreed with the refusal would send somebody looking for a server that is not where they were told it was.
Written out with an explicit format rather than left to the date serialiser, because that is what the transformer this replaces published: seconds and an offset, not microseconds and a Z.
The id of the team this request is working in, or null when the request named none.
All permissions available when creating or editing a team role.
Show child attributesHide child attributes
The key a route is mapped to, and what a role stores.
The name shown to customers.
A sentence saying what holding it lets a member do, shown under the name in the role editor.
Which section of the role editor shows it.
The permissions this one is useless without.
The handful that destroy data, hand over the guest entirely, or spend the account's money, so the editor can say so on the row.
Errors
- 401
- The key was missing, malformed, revoked, or belongs to an account that no longer exists.
- 403
- Access denied. Check the key's team, permissions and allowed IP addresses. Some actions, such as managing API keys, require a browser session. The response message explains the reason.
- 429
- Too many requests. The
Retry-Afterheader says how many seconds to wait. Limits are per account, so several keys on one account share them.
Still stuck? Contact our team
View as Markdown