I am confused how to properly deal with the non-renewing subscription validation backend. My validation flow roughly like this: First, when user choose IAP item and click the
Buy
button, it will send a POST
request to our backend for generating a order which will contain info like product_id
. And then return the order_id
to the ios. Secondly, the ios end call our receipt verify API which should be passed through some args including receipt_data
, order_id
, product_id
, transaction_id
. Thirdly, when above args passed, we query db with transaction_id
for avoid delivering dulplicate goods with same receipt. Then, sending a POST request to the App Store endpoint /verifyReceipt
. We parse the resp considering different style of receipt, get the status
field first to judge if its value equels to 0
, then travesing the in_app
field to find if there is one which transaction_id
matches the one passed from ios. Then, we compare the product_id
with the matched one. Is there something else that i should pay attention to or there are some logic bugs?