Testing API access permission scopes with curl


We’re complete newbies to auth0.

We’ve worked through the sample from Securing ASP.NET Minimal Web APIs with Auth0 but we can only get it to work when testing with curl if we use .RequireAuthorization() instead of .RequireAuthorization(“todo:read-write”)

Is there a way to test with curl using the read-write scope?

We may be missing something obvious!

Hi @graham.lock,

Welcome to the Auth0 Community!

I understand that you have encountered issues trying to get an Access Token for your Web API.

In this situation, have you confirmed that your TODO API has the ‘todo:read-write’ Permissions assigned to it?

And could you please confirm if you have also switched on the Enable RBAC and the Add Permissions in the Access Token toggle buttons on your API settings?

Once you have confirmed these settings, you can copy and use the cURL request found on your Auth0 Dashboard > Applications > APIs > YOUR_API > Test tab to request an Access Token against this API.

I hope this helps!

Please reach out if you have any further questions.

Thank you.