0
votes

How to correctly configure Postman to obtain the Oauth2 access token for testing the Google Pay for Passes REST API?

I followed the getting started guide carefully, but, after setting the Postman Oauth2 dialog (with callbackurl, auth url, access token url, client id, client secret and scope) and choosing the right account, I occur in a page with this error:

Error 400: invalid_scope Some requested scopes cannot be shown: [https://www.googleapis.com/auth/wallet_object.issuer] Request details response_type=code client_id=[REMOVED] redirect_uri=https://www.getpostman.com/o/oauth2/callback access_type=online display=page scope=https://www.googleapis.com/auth/wallet_object.issuer

The same error occurs with the Google API Playground.

1

1 Answers

0
votes

You have to use the service account credential as per https://developers.google.com/identity/protocols/OAuth2ServiceAccount#Overview. There you will see libraries used and samples to handle the authentication and that is the recommended way.