HypeTutorials / google-api-python-client

Automatically exported from code.google.com/p/google-api-python-client
Other
0 stars 0 forks source link

getting 403 accessing discovery api with and without developersKey on appengine #55

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
using appengine - works with the devserver

# by using the following code from the google-plus-api-starter
DISCOVERY_DOCUMENT = "https://www.googleapis.com/discovery/v1/apis/plus/v1/rest"

decorator = OAuth2Decorator(
    client_id=settings.CLIENT_ID,
    client_secret=settings.CLIENT_SECRET,
    scope = 'https://www.googleapis.com/auth/plus.me' )

# happens with and without memcache
http = httplib2.Http()
httpUnauth = httplib2.Http()

# Get discovery document
ul = urllib.urlopen(settings.DISCOVERY_DOCUMENT)
discovery_doc = ul.read()
ul.close()

# service = build("plus", "v1", http=http, developerKey=settings.API_KEY)
service = build("plus", "v1", http=http, developerKey=settings.API_KEY)

# getting the following error message

URL being requested: https://www.googleapis.com/discovery/v1/apis/plus/v1/rest
<class 'apiclient.errors.HttpError'>: <HttpError 403 when requesting 
https://www.googleapis.com/discovery/v1/apis/plus/v1/rest returned "User Rate 
Limit Exceeded">
Traceback (most recent call last):
  File "/base/data/home/apps/<appid>/1.353303244737168895/main.py", line 58, in <module>
    service = build("plus", "v1", http=http)
  File "/base/data/home/apps/<appid>/1.353303244737168895/apiclient/discovery.py", line 138, in build

Original issue reported on code.google.com by siegfrie...@gmail.com on 16 Sep 2011 at 9:45

GoogleCodeExporter commented 8 years ago

Original comment by jcgregorio@google.com on 16 Sep 2011 at 12:49