Skip to main content

Invitations

POST Accepts invitation

https://api.track.toggl.com/api/v9/organizations/invitations/{invitation_code}/accept

User connected with invitation is marked as joined, email is sent to the inviter.

curl -X POST https://api.track.toggl.com/api/v9/organizations/invitations/{invitation_code}/accept \
-H "Content-Type: application/json"

Parameters

Path

nametyperequireddescription
inviutation_codestringtrueInvitation code

Response

200

OK

403

Forbidden

404

Invalid invitation code

POST Rejects invitation

https://api.track.toggl.com/api/v9/organizations/invitations/{invitation_code}/reject

User connected with invitation is marked as deleted.

curl -X POST https://api.track.toggl.com/api/v9/organizations/invitations/{invitation_code}/reject \
-H "Content-Type: application/json"

Parameters

Path

nametyperequireddescription
inviutation_codestringtrueInvitation code

Response

200

OK

403

Forbidden

404

Invalid invitation code

POST Creates a new invitation for the user

https://api.track.toggl.com/api/v9/organizations/{organization_id}/invitations

Creates a new invitation for the user.

curl -X POST https://api.track.toggl.com/api/v9/organizations/{organization_id}/invitations \
-H "Content-Type: application/json" \
-d '{"emails":["string"],"workspaces":[{"admin":"boolean","role":"string","workspace_id":"integer"}]}' \
-u <email>:<password>

Parameters

Path

nametyperequireddescription
organization_idintegertrueNumeric ID of the organization.

Body

nametypedescription
emailsArray of string-
workspacesArray of
nametypedescription
adminboolean-
rolestring-
workspace_idinteger-
-

Response

200

Created user invitations
nametypedescription
dataArray of
nametypedescription
emailstring-
invitation_idinteger-
invite_urlstring-
organization_idinteger-
recipient_idinteger-
sender_idinteger-
-
messagesArray of string-

400

Possible error messages:

* Invalid JSON input
* Invalid organization id
* at least one email is required
* at least one workspace is required
* Missing e-mail
* Invalid e-mail: '...'
* invalid workspace ID
* Active user limit is 5. Upgrade to add more active users
* Invitation limit reached (please try again later; or upgrade)
* User with e-mail '...' is already an inactive member of the organization

403

Forbidden

PUT Resends user their invitation

https://api.track.toggl.com/api/v9/organizations/{organization_id}/invitations/{invitation_code}/resend

Resend invitation email to user.

curl -X PUT https://api.track.toggl.com/api/v9/organizations/{organization_id}/invitations/{invitation_code}/resend \
-H "Content-Type: application/json"

Parameters

Path

nametyperequireddescription
organization_idintegertrueOrganization ID
invitation_codestringtrueInvitation code

Response

200

OK

400

Organization ID and invitation organization ID mismatch

404

Invitation code not found
© 2024 Toggl. All rights reserved.