1

I am trying to verify an in-app purchase using the Android Publisher API, but I'm encountering an "Invalid Value" error. I have constructed the following curl command:

curl --location 'https://androidpublisher.googleapis.com/androidpublisher/v3/applications/cz.sduhe/purchases/products/credit200/tokens/GPA.3384-7483-3665-46780' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer XXX'

However, when I execute this command, I receive the following error response:

{
    "error": {
        "code": 400,
        "message": "Invalid Value",
        "errors": [
            {
                "message": "Invalid Value",
                "domain": "global",
                "reason": "invalid"
            }
        ]
    }
}

I have double-checked that the Authorization header contains a valid access token. Are there any other potential causes for this error? How can I troubleshoot and resolve this issue?

Any guidance or insights would be greatly appreciated. Thank you!

RitchyCZE
  • 44
  • 2
  • 13
  • 1
    Most likely your "token" is incorrect. According to [this answer](https://stackoverflow.com/a/59838049/150978) you have used the orderId not the token. – Robert May 16 '23 at 14:46

0 Answers0