Can't add password grant type from Management API

Steps to reproduce

  1. Allow password grant from the Management API (node-auth0 library is used below).
await managementClient.updateClient(
    {
      client_id: clientId,
    },
    {
      grant_types: [
        "password",
      ],
    }
  );
  1. Retrieve token from /oauth/token endpoint

Actual behaviour

Step 2 returns {"error":"access_denied","error_description":"Unauthorized"}

Expected behaviour

Step 2 returns the access token

Workaround

I have to go into the management console UI, uncheck password grant, save, check password grant, save

1 Like

Hello, Welcome to Auth0 Community!

Could you please elaborate on what the problem you are facing is?

Could you please explain the reason to uncheck password grant, if it is already checked on the first place?

Thanks!

The problem is described in the original post on step 2. What I’m trying to do is to enable password grant type for an application via Management API. This didn’t work, which is why I have to uncheck and check it back in the console, otherwise I’ll be getting the access denied error despite the grant type being checked in the console.

Hello @wisen.tanasa !

Could you please give us an example of what you are sending on step two?

Thanks in advance!