Hi, GAVINL.
The information that you are looking for is included in the XADK documentation. You need to find the following document: App Developer Instructions Ecommerce Supplement_v1_5.docx
You'll want to find the example titled: Tracking eCommerce Usage for cloud based apps.
This example gives you a sample request showing where the appID and deviceId are used (see section AppID and DeviceID in the document to determine how to retrieve these IDs) and also includes examples of how to report usage from the Cloud to App Gallery.
Please let me know if you have additional questions.
Thanks you,
XAS Moderator
Thank you for your clarification.
What i am confused is that since our app is a cloud based app, we have to count and report the usage from our cloud side. The TrackUsage() call is only taking usage unit and usage amout, and how do we use the trackUsage to do the tracking from our cloud? How does App gallery know which machine and which app should this number be counted to?
Hi, GAVINL.
Apologies. I think that I referenced an incorrect call.
There should be a TrackUsage () function in the Entitilement API. You should be able to report app usage via the TrackUsage function.
I hope that this helps, but please let me know if you have trouble with that call.
Thank you,
XAS Moderator
I didn't find any TrackEntitlement call here? Instead, I found a EntitlementsPayload function, is that the call you mean?
Hi, GAVINL.
Thank you for the message.
Your app will need to report usage to App Gallery via the Entitlement API. There are two calls: getUsage and trackEntitlement. If you wanted to get the usage data, use the getUsage call. If you are reporting app usage, use the trackEntitlement call. The API is available in the XADK documentation.
So yes, you seem to have it correct. You app will need to send the usage used by each user to the App Gallery. The App Gallery will use that data to check if the app has enough entitlement left to run the upcoming job. If not, the App Gallery will notify the user by posting a message at the device.
I hope that this information is helpful, but please let me know if there are additional question.
Thank you,
XAS Moderator
If we submit an app and set it to be usage-subsciption? Do we have to make the app count and check the number of pages used (usage) inside the app or the e-commerce of app gallery is going to count it for us? Basically, I mean inside our app, does the app have to keep track of the usage used by each user and send the usage number back to App Gallery so that app gallery can check the entitlement of the app? If so, where do we have to send the track information?
Solved! Go to Solution.