1

A few days back, The Notion access_token suddenly stopped working for many accounts at our Integration (React + Node JS) and returning below error response in Notion REST API:

data: {
    object: 'error',
    status: 401,
    code: 'unauthorized',
    message: 'API token is invalid.'
   }

Also couldn’t found the way to refresh the access tokens through Notion Developer Docs.

Below is the response for POST request to Notion's Token:

{
    access_token: 'xyz',
    token_type: 'bearer',
    bot_id: 'abc',
    workspace_name: "My Workspace",
    workspace_icon: 'https://lh3.googleusercontent.com/a-/AOh14GjvWyUFxUVIZLm11iFFeVEGgyMSVA3hkAXlXgaj=s100',
    workspace_id: 'xyz',
    owner: { type: 'user', user: [Object] },
    duplicated_template_id: null
}

In Notion Developer Docs, found a few details about the refresh token but the explanation isn't helpful enough to implement it for our integration.

Can anyone share the endpoint or any docs link to create a refresh token. An example for refresh token generation and generate access token from it would be really helpful though.

Thanks in Advance

0 Answers0