Skip to main content

Authentication

POST Enable/Disable OAuth

https://api.track.toggl.com/api/v9/me/enable_oauth/{provider}

Enable/Disable login using user's provider account to existing Toggl account.

curl -X POST https://api.track.toggl.com/api/v9/me/enable_oauth/{provider} \
-H "Content-Type: application/json" \
-d '{"code":"Pointers are used to distinguish between missing fields and zero values","enabled":"boolean","token":"string"}' \
-u <email>:<password>

Parameters

Query

nametyperequireddescription
errorstringfalseError

Body

nametyperequireddescription
codestringfalsePointers are used to distinguish between missing fields and zero values
enabledbooleanfalse-
tokenstringfalse-

Response

Successful operation.

POST ResetToken

https://api.track.toggl.com/api/v9/me/reset_token

Resets API token for the current user.

curl -X POST https://api.track.toggl.com/api/v9/me/reset_token \
-H "Content-Type: application/json" \
-u <email>:<password>

Response

Successful operation.

POST Create session

https://api.track.toggl.com/api/v9/me/sessions

Creates a session and sets a cookie in the response header which can be used for authentication in API requests

curl -X POST https://api.track.toggl.com/api/v9/me/sessions \
-H "Content-Type: application/json" \
-d '{"remember_me":"boolean"}' \

Parameters

Body

nametyperequireddescription
remember_mebooleanfalse-

Response

{"api_token":{"description":"will be omitted if empty","type":"string"},"email":{"type":"string","format":"email"},"fullname":{"type":"string"},"id":{"type":"integer"},"timezone":{"type":"string"}}

DELETE Delete session

https://api.track.toggl.com/api/v9/me/sessions

Deletes a session used for authenticating the current request

curl -X DELETE https://api.track.toggl.com/api/v9/me/sessions \
-H "Content-Type: application/json" \

Response

OK

POST Signup

https://api.track.toggl.com/api/v9/signup

Sign up as a new user.

curl -X POST https://api.track.toggl.com/api/v9/signup \
-H "Content-Type: application/json" \
-d '{"code":"required if signing up via OAuth","country_id":"integer","created_with":"string","email":"string","full_name":"string","google_access_token":"Deprecated","invitation_code":"string","password":"string","provider":"required if signing up via OAuth","timezone":"string","token":"required if signing up via OAuth","tos_accepted":"boolean"}' \

Parameters

Body

nametyperequireddescription
codestringfalserequired if signing up via OAuth
country_idintegerfalse-
created_withstringfalse-
emailstringtrue-
full_namestringfalse-
google_access_tokenstringfalseDeprecated
invitation_codestringfalse-
passwordstringtrue-
providerstringfalserequired if signing up via OAuth
timezonestringfalse-
tokenstringfalserequired if signing up via OAuth
tos_acceptedbooleantrue-
workspaceundefinedfalse-

Response

{"api_token":{"description":"will be omitted if empty","type":"string"},"at":{"type":"string","format":"date-time"},"beginning_of_week":{"type":"integer"},"country_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"default_workspace_id":{"type":"integer"},"email":{"type":"string","format":"email"},"fullname":{"type":"string"},"id":{"type":"integer"},"image_url":{"type":"string","example":"http://example.com"},"intercom_hash":{"description":"will be omitted if empty","type":"string"},"openid_email":{"type":"string","format":"email"},"openid_enabled":{"type":"boolean"},"options":{"additionalProperties":"object"},"timezone":{"type":"string"},"updated_at":{"type":"string","format":"date-time"}}
© 2022 Toggl. All rights reserved.