Getting an error when I attempt to retrieve a list of Blogger posts through the Google API.
Am using python requests module to make requests via plain GET urls. (Not using the Google Python Client).
>>> posts = requests.get( "https://www.googleapis.com/blogger/v3/blogs/MY-BLOG-ID/posts?key=MY-API-KEY" )
>>> posts
<Response [404]>
The same API does report successfully on a private status request, using the same blog ID and same API key:
>>> r = requests.get( "https://www.googleapis.com/blogger/v3/blogs/MY-BLOG-ID?key=MY-API-KEY" )
>>> r
<Response [200]>
The response shows the blog has posts:
>>> r.json()['posts']['totalItems']
8
I can get a list of posts using the test url provided by the Blogger API documentation, using the same API key again:
>>> tP = requests.get( "https://www.googleapis.com/blogger/v3/blogs/2399953/posts?key=MY-API-KEY" )
>>> tP.json()['items'].__len__()
10
But my own blog gives a 404 when asked for posts using the same credentials that worked fine with these other requests. The same error is reported when the request url is placed in a browser.
MY-API-KEY is the api key obtained from a project created in Google Cloud Console, within which the Blogger API is activated.
What could be going wrong here?