Found this content helpful? Log in or sign up to leave a like!
Unable to Generate Access Token for Student via Admin Access Token
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Canvas Community,
We are working on an integration using the Canvas LMS API, and are attempting to generate an access token for a student using the endpoint:
POST /api/v1/users/:user_id/tokens
https://www.canvas.instructure.com/doc/api/access_tokens.html
We are using an admin-level access token
However, we are experiencing issues:
-
The token is not returned, or is returned in a
"pending"
state with no"token"
value. -
There appears to be no way to activate the pending token programmatically or via impersonation.
-
We could not find clear documentation or UI references on how a specific user (e.g., the student) can manually activate a pending token created by an admin
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @brandon42,
May I ask why you're attempting to create individual user access tokens? I think that is going to be a very frowned upon practice overall.
The more common route would be to use a Developer Key / oAuth2 flow to be able to do API calls on behalf of users.
-Chris