Skip to content

Quickstart

Showing steps for

Create a workspace API token, then call GET /v1/offices to list your offices. It takes about five minutes.

Who can do this: Account Admins create the token. Anyone with the token can then call the API.

Slack

  1. In Officely, on the Home tab, open Go to… > All settings > Account & Billing.
  2. Under API token, select Create token.
  3. Enter a Token name and select Create.
  4. Copy the token from API token created.

Microsoft Teams

  1. In the Officely tab, select Settings > Account & Billing. It isn’t shown on mobile.
  2. Under API tokens, enter a Token name and select Create token.
  3. Select Copy token, then Done.

You only see the token once. A workspace can have one active token, so revoke any existing one first. Anything using the old token stops working. More in API access.

Keep the token in a password manager or your integration’s secret store. If you lose it, revoke it and create a new one.

For the commands below, put it in an environment variable. read -s keeps it out of your shell history:

Terminal window
read -s OFFICELY_API_TOKEN # paste the token, then press Enter
export OFFICELY_API_TOKEN
Terminal window
curl https://api.officelycrew.com/v1/offices \
-H "Authorization: Bearer $OFFICELY_API_TOKEN"

You get your workspace’s offices. The id is what other endpoints take in officeIds.

{
"data": [
{
"id": "k7Qe2vXbN9pL4tRw8sYcZ",
"name": "London HQ",
"emoji": "🏢",
"timezone": "Europe/London",
"country": "United Kingdom"
}
]
}

Got 401 UNAUTHORIZED? The token is missing, mistyped or revoked. Check the header is Authorization: Bearer <token>.

Did this answer your question?

Still need help? Chat to our support team.

Contact support