How to find out when a user bought an application / installed it for the first time (perhaps without a UDID?)

I would like to know when the user first bought my application ... until I found a clean path, and the UDID seemed to be the only option.

Ideally there will be a receipt that I can get through StoreKit, but still .. nada

Did I miss something? Anyone have an idea?




The situation is that I have a subscription and the problem is FIRST (it should be free from the moment of purchasing the application). If I reinstall later ... I should always get the original problem)

Example: I buy an application on 10.2010 I install and launch it and get a subscription from 10.2010 for free (without a purchase in the application) Now I delete the application I install it on 1.2013, and I get a subscription from 10.2010 for free! NOT New

+5
ios storekit
May 03 '13 at 8:48
source share
2 answers

You can just save the flag in the keychain. The contents of the keychain are stored in applications for reuse.

To get the first installation time of your application, check when the application binary was first written to disk:

if (flag_in_keychain_not_present()) { // installed for the first time set_flag_in_keychain(); struct stat st; stat([NSBundle mainBundle].executablePath.UTF8String, &st); time_t installed = st.st_mtime; } 
+5
May 03 '13 at 9:04 am
source share

I haven't used the Store Kit yet, but tell me if I'm wrong,

1) this requires a server at one point or another

2) when we use it for a purchase (and not a subscription or consumables), we can receive this purchase on all devices using the same iTunes account

My point, create an in-app free purchase item when it passes through your server for the first time, storing it in the database, and the next time it is called with the same account, "resolve" the problem corresponding to the first free purchase

+1
May 03 '13 at 9:08
source share



All Articles