403 Forbidden When Accessing Grades Endpoints via API
Hello everyone!
I’m new here and working on an integration to fetch grades through the Brightspace API. I have a service account with a custom role (cloned from the standard service account role) where I granted the permission “See user grade values (API Only).” My registered application is requesting the scopes core:*:* grades:*:*.
However, whenever I try to call any of the Grades endpoints, for example:
GET /d2l/api/le/(version)/(orgUnitId)/grades/
GET /d2l/api/le/(version)/(orgUnitId)/grades/final/values/(userId)
I receive a 403 Forbidden error. My goal is simply to read grades via the API.
Has anyone run into this issue or have suggestions on how to grant the right permissions or configure the role so these endpoints will allow access?
Thanks in advance for your help!
PS: I did find and followed this article, but not able to get past the 403: https://community.d2l.com/brightspace/discussion/5462/grades-api-forbidden
Answers
-
Just to update the thread. I was able to figure this out. The issue was figuring out the correct scope and role permissions. For scope I ended up with: "core:: grades:gradecategories:read grades:gradeobjects:read" and for role permissions if you filter on 'security' and 'grades' - you will see some options, just need to select ones relevant to the data you need. Hopefully this will help someone down the road.