Search code examples
google-cloud-platformgoogle-indexing-api

Using Postman to access Google Indexing APIs


I would like to test Google Indexing API with Postman. I have already configured the api correctly on https://console.cloud.google.com/ for using it on a wordpress site with the plugin Instant indexing and everything works ok. Now I simply want to do a POST call with Postman, in particular I did not found anything clear about the type of authentication (Oauth 2) to use for the call.

{
    "error": {
        "code": 401,
        "message": "Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.",
        "status": "UNAUTHENTICATED",
        "details": [
            {
                "@type": "type.googleapis.com/google.rpc.ErrorInfo",
                "reason": "CREDENTIALS_MISSING",
                "domain": "googleapis.com",
                "metadata": {
                    "method": "google.indexing.v3.UrlService.PublishUrlNotification",
                    "service": "indexing.googleapis.com"
                }
            }
        ]
    }
}

Anyone can provide me an example? Thank you.


Solution

  • For anyone interested I managed to make it work by following these steps: