voltrue2 / in-app-purchase

A Node.js module for in-App-Purchase for iOS, Android, Amazon and Windows.
http://iap.gracenode.org
Other
1.05k stars 289 forks source link

Project id not linked Google Validation #324

Open rogerkerse opened 4 years ago

rogerkerse commented 4 years ago
{
   error: {
      code: 403,
      message: "The project id used to call the Google Play Developer API has not been linked in the Google Play Developer Console.",
      errors: [
         {
            message: "The project id used to call the Google Play Developer API has not been linked in the Google Play Developer Console.",
            domain: "androidpublisher",
            reason: "projectNotLinked",
         }
      ],
   }
}

I have Firebase project (under account A) linked with Play Store Publish (under account B). In config function I use googleServiceAccount properties from Firebase Service account.

Whenever I try to validate receipt I get the error 403 What am I doing wrong?

KochMario commented 3 years ago

Did you create your purchases / subscriptions BEFORE linking your project? If so, try creating new purchases / subscriptions or edit the existing ones (update their description, etc.).

I had the same issue and for me it was becasue I created my subscription before linking the project to Google Developer API. Besides that you should check that you've proper Google Service Accounts setup and allowed access for them in your Google Console (under API).