Google+ Domains API v1. Error 403 “Access not configured”

孤者浪人 提交于 2019-12-22 18:18:23

问题


I am starting to use the google+ API, but I am getting problems authenticating, even in the Google Playground.

I want to do a very easy thing, which is get the circled people of my user, so, I use the scopes:

/auth/plus.circles.read /auth/plus.me

And I request with:

https://www.googleapis.com/plusDomains/v1/people/me/circles

In both Google PlayGround, and in the API page https://developers.google.com/+/domains/api/circles/list which allows you to test it, both of them give me the response:

{
 "error": {
  "errors": [
   {
    "domain": "usageLimits",
    "reason": "accessNotConfigured",
    "message": "Access Not Configured"
   }
  ],
  "code": 403,
  "message": "Access Not Configured"
 }
}

It is strange, because it says that I my access is not configured, but it should be. I even try adding all the scopes of google+ domain API...

Thanks in advance


回答1:


Kind of what Akash said - check the API is enabled. The Google+ domains API is different than the main Google+ API, so you'll need to ensure both are enabled:

Also make sure that the user you're testing with is a member of the domain, and you have appropriate permissions. This isn't an API for general functionality - its specifically for managing the Google+ accounts for users within a Google Apps for Business domain, so you might have trouble if you're testing it with a @gmail.com user or similar.




回答2:


As Ian said, you need to enable the Google+ Domains API in the API Console. However, to user the Google+ Domains API, you do not need the Google+ API enabled, as well. These are two distinct services.

Furthermore, to make a request, the request must be authenticated. This means that you either need to make the requests using OAuth 2.0 or through domain-wide delegation of authority. For the Google Playground, you should be able to use OAuth within the playground.

Also, as Ian said, the Google+ Domains API only works for a domain, so make sure that you are testing against a domain that you have access to for OAuth calls, or admin rights to for delegation calls.



来源:https://stackoverflow.com/questions/19352669/google-domains-api-v1-error-403-access-not-configured

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