Add support for new API
Hey @joshcarty,
Google announced a new API for GSC: https://developers.google.com/search/blog/2022/01/url-inspection-api. Do you want to extend your package to support it or do you rather stick to performance reporting only?
Just asking before starting to work on it, because the structure is pretty different :)
Thanks!
Hey @joshcarty:
I don't know if you are interested in the new functionality I've mentioned some months ago or if you have time at the moment. I think it could enhance your library, though.
I've started to look into the logic, and with a simple new class , we could extract the information we need:
class IndexInspect:
def get(self,urls):
results = []
for url in urls:
request = {
'siteUrl': domain,
'inspectionUrl': url
}
results.append(account.service.urlInspection().index().inspect(body=request).execute())
return results
In its current state, the code would output the following, but the idea is obviously to add a to_dataframe() method, as you did for the query class.

Should I make a PR adding this new class (and other relevant code) to allow you library to handle this new API functionality?
Thanks for this @antoineeripret - I'll review your PR this week!
It sounds like this was never implemented?
Taking a chance to "promote" the integration into my library. https://github.com/andreamoro/GSC-Wrapper/tree/URL-Inspection-Integration
The query part is major refactoring from Josh's original work.
@antoineeripret happy to hear your comments.
Hi @andreamoro, I'll have a look if I have a moment this week (two bank holidays in Spain). Thanks for the heads-up!