...
You did it! Make some queries with your sweet new authenticated self!
Querying on Stage and Prod
To become authenticated on stage and prod, a couple more steps are needed. First things first, a lot of these links require you to be logged in on OneLogin and/or on the VPN.
Logged in as the user you want credentials for, request api access here for prod or here for stage
Logged in as an admin/staff user (ex the
edx
user), approve the request on Django Admin (stage and prod)Logged back in as the user you want credentials for, go back to the page from step one and put in the application name (redirect uris you can leave blank unless you need them)
Your new
client_id
andclient_secret
should now be available after you submit!To generate a new JWT Auth token for API use, go to postman and make a POST query to
https://api.edx.org/oauth2/v1/access_token?
withgrant_type=client_credentials&client_id={{api_id_prod}}&client_secret={{api_secret_prod}}&token_type=jwt
as the body after setting those variables in postmanMake sure your headers has Content-Type set to
application/x-www-form-urlencoded
After obtaining the access token, keep in mind it expires after 1 hour