Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

what's the likely max length of apple ios purchase receipt-data?

Tags:

Before beginning to test the iOS autorenewing purchases I need to prepare my server database. My question is simple. I just wanna know what size I should make the varchar field in my database.

like image 906
3advance Avatar asked Mar 28 '11 18:03

3advance


People also ask

How long does an Apple receipt take?

The billing is handled by Apple on iOS, so you would get a receipt from them. Often it can take 3-5 days to arrive (assuming you have not turned off email notifications from them).

How do I validate my Apple receipt?

Use the production URL https://buy.itunes.apple.com/verifyReceipt when your app is live in the App Store. For more information on these endpoints, see verifyReceipt. Verify your receipt first with the production URL; then verify with the sandbox URL if you receive a 21007 status code.

What is receipt validation in-app purchase?

Receipt validation is a way to protect against fraudulent in-app purchases made in the iOS and Android app stores, and is used to ensure transactions occurred as reported.

Does Apple send receipts for in-app purchases?

Anything purchased from the iTunes, App, or iBook stores automatically generates an email receipt, sent to your AppleID email address.


1 Answers

I was using a varchar (4096) to store my base64 encoded receipts.

But to be honest, I couldn't find anything regarding receipt length on the official documentation (or anywhere else). The only thing I did find on Apple's docs was that the receipt content/format is subject to change:

The contents and format of the store receipt is private and subject to change. Your application should not attempt to parse the receipt data directly. Use the mechanism described here to validate the receipt and retrieve the information stored inside it.

So probably going for text instead of varchar really is the best option.

like image 63
André Morujão Avatar answered Sep 18 '22 21:09

André Morujão