OAuth 2.0 (legacy)

Reference for the legacy OAuth 2.0 flow with non-expiring access tokens.

This page documents the legacy OAuth 2.0 flow, which issues access tokens that don't expire and has no refresh tokens. It's only available to apps created before OAuth 2.1 became the default, and only for app versions that don't have OAuth 2.1 turned on.

🚧

Legacy tokens stop working in API version 2027-04

Starting with API version 2027-04, the monday API accepts only OAuth 2.1 tokens. Requests that use OAuth 2.0 tokens with 2027-04 or later return 401 Unauthorized with the OAUTH21_TOKEN_REQUIRED error code. Migrate to OAuth 2.1 to keep using newer API versions.

How the flow works

  1. Your app redirects the user to https://auth.monday.com/oauth2/authorize with your client_id.
  2. The user reviews the requested scopes and approves them.
  3. monday.com redirects the user to your redirect_uri with a temporary authorization code.
  4. Your backend exchanges the code for an access token at https://auth.monday.com/oauth2/token. The token is valid until the user uninstalls your app.

Authorization request

Redirect the user to the authorization endpoint:

GET https://auth.monday.com/oauth2/authorize?client_id=YOUR_CLIENT_ID

ParameterDescriptionDefault valueRequired
client_idYour app's client ID, from the App credentials tab in General settings.Yes
redirect_uriThe URL to redirect back to after approval or denial. Must exactly match one of your app's redirect URLs.Your only redirect URL, if you configured exactly oneYes, if more than one redirect URL is configured
scopeA space-separated list of the scopes your app requests. Every scope must be configured in your app.The scopes configured in your appNo
stateA random value returned to your redirect_uri unchanged. Use a unique value per request and verify it in the callback to prevent forgery attacks.Recommended
app_version_idThe ID of the app version to authorize, found in your app's URL after app_versions. Lets app collaborators test a draft version. Doesn't work for deprecated versions or for users who aren't collaborators.The live version, or the latest version if there's no live versionNo
force_install_if_neededSet to true to send users to the app installation page if your app isn't installed on their account yet. After an admin installs the app, the user returns to the authorization flow.No
subdomainForces authorization for a specific account. See OAuth flow for users with multiple accounts.No

Redirect

After the user approves the request, monday.com redirects them to your redirect_uri with these query parameters:

ParameterDescription
codeThe authorization code. It's single-use and valid for 10 minutes.
scopeThe scopes the user granted.
stateThe state value you sent in the authorization request.
regionThe monday.com region that hosts the user's account (for example, use1 or euc1).

If the user denies the request, the redirect contains error=access_denied, an error_description, and state instead of a code.

Token request and response

Exchange the authorization code for an access token from your backend within 10 minutes. After that, the code expires and the user has to authorize again.

POST https://auth.monday.com/oauth2/token

ParameterDescriptionRequired
client_idYour app's client ID.Yes
client_secretYour app's client secret.Yes
codeThe authorization code from the redirect.Yes
redirect_uriUsed for validation only; there's no redirect. Must match the redirect_uri from the authorization request.Yes, if you sent it in the authorization request
grant_typeauthorization_code.No

Response

On success, the response status is 200 OK and the body contains:

KeyDescription
access_tokenThe token for calling the monday API. It doesn't expire and is valid until the user uninstalls your app. The legacy flow doesn't support refresh tokens.
token_typeAlways bearer.
scopeA comma-separated list of the scopes granted to the token.
{
  "access_token": "NgeFeX...FEmEka",
  "token_type": "bearer",
  "scope": "boards:write,boards:read"
}

Error codes

Most errors in the authorization request are returned as a JSON response with an HTTP status code. When the user denies access, monday.com redirects them to your redirect_uri with error=access_denied.

StatusError codeDescription
400invalid_requestA required parameter is missing or invalid (for example, an unknown client_id, an unregistered redirect_uri, or a wrong client_secret).
400invalid_scopeA requested scope isn't configured in your app.
400unsupported_response_typeThe response_type isn't supported.
400unsupported_grant_typeThe grant_type isn't authorization_code.
401invalid_grantThe authorization code is invalid or expired, or the client_id or redirect_uri doesn't match the authorization request.
403access_deniedThe user denied the request, or API access is disabled for the user.
500server_errorAn unexpected server error.
📘

Join our developer community!

We've created a community specifically for our devs where you can search through previous topics to find solutions, ask new questions, hear about new features and updates, and learn tips and tricks from other devs. Come join in on the fun! 😎


Did this page help you?