Skip to main content
The First Step
Jan 15, 2024 2:28 AM UTC
Question

jwt

Hi,

I previously used the password for auth flow of my app.

Now the password is no longer allowed. I switched to json web token, and followed the instructions and the example for python. I obtained the jwt, entered into my code, but:


I am also getting

Unauthorized for this grant type

    7 replies

    PhongVu
    Community Manager
    Community Manager
    Jan 15, 2024 3:43 PM UTC

    Did you login the RingCentral developer portal and change the auth type for your app? And what is the app client id?

    jigarThe First StepAuthor
    The First Step
    Jan 18, 2024 2:32 PM UTC

    Hi Mr. Phong,

    my clinet ID: kAZYBRDmQFWLcRLeKyZTgw

    as for auth type, i see this in App settings:

    1705588331923.png

    PhongVu
    Community Manager
    Community Manager
    Jan 18, 2024 3:55 PM UTC

    So your app is a native Windows desktop app or a Web app? Right now the platform type app is Desktop/Windows. And the app grant type is Authorization code and Password flow.

    I disabled the password flow and enabled the JWT token flow for your app so you should be able to use JWT token now.

    If your app is truly a Windows desktop app, you should think about the way you will deploy your app and how the users can be authenticated. You may find authorization code flow would be more suitable for your app.

    jigarThe First StepAuthor
    The First Step
    Jan 19, 2024 12:29 AM UTC

    My app is a Windows desktop app.

    How long does it take for the change to JWT token flow to take effect?


    Thank you

    jigarThe First StepAuthor
    The First Step
    Jan 19, 2024 2:26 PM UTC

    The JWT auth works now, and my app is working again!

    Thank you for all your help!

    New Participant
    Feb 7, 2024 6:53 PM UTC

    @Phong Vu I am seeing the same error, is there a delay before jwt becomes enabled?

    PhongVu
    Community Manager
    Community Manager
    Feb 8, 2024 4:26 PM UTC

    Should be quick and within an hour. Does the problem still exist? If so, what is the app client id?