oauth scopes google classroom API

倖福魔咒の 提交于 2019-12-02 21:26:18

问题


I am trying to get round a problem with my code which states

"403 when requesting https://classroom.googleapis.com/v1/courses/582805726/students?alt=json returned "Request had insufficient authentication scopes."

So I have been looking into adding the right scopes for my python project.

I did this for GAM and I thought I would do it in this screen:

Manage API client access (thats in the admin panel).

So I have created a project, enabled the google classroom API, created an OAuth 2.0 client ID and copied this along with the following scopes:

https://www.googleapis.com/auth/classroom.rosters,
https://www.googleapis.com/auth/classroom.profile.emails,
https://www.googleapis.com/auth/classroom.profile.photos,
https://www.googleapis.com/auth/classroom.courses

but still no joy.

Could anyone point me in the right direction?


回答1:


I have in fact solved my own puzzle by adding in the scopes into my python file with spaces and it works well!



来源:https://stackoverflow.com/questions/34753178/oauth-scopes-google-classroom-api

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!