Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add sandbox agnostic receipt verification #1228

Merged
merged 1 commit into from
Jan 26, 2021

Conversation

ninjaboy
Copy link
Contributor

@ninjaboy ninjaboy commented Jan 9, 2021

As per Apple receipt verification best practices:

As a best practice, always call the production URL for verifyReceipt first, and proceed to verify with the sandbox URL if you receive a 21007 status code.

In case if isTest parameter is undefined or defined as null (basically means that developer prefers to perform environment agnostic check:

  1. Query production verification endpoint
  2. In case if 20017 error is returned - query sandbox receipt verification endpoint

For the cases when isTest parameter is explicitly defined as true or false - run the old logic

@hyochan
Copy link
Member

hyochan commented Jan 21, 2021

@iaphub Could you kindly review this? Looks like this is somehow related to what you are working on.

Copy link
Member

@hyochan hyochan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've just gone through this and this is what Apple wanted. Thanks for your contribution 💯

@hyochan hyochan merged commit f73a491 into dooboolab-community:master Jan 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🍗 enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants