Grant type 'refresh_token' not allowed for the client

I am seeing the below error for the post request:

curl --location --request POST ‘https://xyxyx-cloud-account.auth0.com/oauth/token’ \

–header ‘Content-Type: application/json’ \

–data-raw '{

“grant_type”: “refresh_token”,

“refresh_token”: “”,

“client_id”: “”

}

Response:

{

“error”: “unauthorized_client”,

“error_description”: “Grant type ‘refresh_token’ not allowed for the client.”,

“error_uri”: Application Grant Types

}

Hi @tilaka,

Thanks for posting! Welcome to the Auth0 Community.

It’s possible that this issue is occurring because the Client Credentials Grant Type isn’t enabled. You can enable the client Credentials Grant Type by going to the application’s setting Tab, scrolling to the bottom of the page, toggling Advanced Settings, choosing the Grant Types tab, and checking the box for the Client Credentials Grant Type. Make sure to Save the Changes.

Once you’ve made that change, try again and see if everything works as expected. If not, feel free to send me your tenant name via DM, and I’ll take a closer look for you.

Thanks!
Valerian