Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

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.

  1. Logged in as the user you want credentials for, request api access here for prod or here for stage

  2. Logged in as an admin/staff user (ex the edx user), approve the request on Django Admin (stage and prod)

  3. 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)

  4. Your new client_id and client_secret should now be available after you submit!

  5. 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? with grant_type=client_credentials&client_id={{api_id_prod}}&client_secret={{api_secret_prod}}&token_type=jwt as the body after setting those variables in postman

    1. Make sure your headers has Content-Type set to application/x-www-form-urlencoded

  6. After obtaining the access token, keep in mind it expires after 1 hour