Do open web app receipt checking #10

jrburke opened this Issue May 11, 2012 · 1 comment


None yet
2 participants

jrburke commented May 11, 2012

Do open web app receipt checking. The getSelf() call for the mozApps, in the onsuccess, there will be a request.result._receipts array with receipts that can be checked for validity.

This document describes the format of each request:

There should be a call to the "verify" url in each receipt to make sure it is still valid, and if the user is offline, the result of the check should be cached for offline use.

Some things to consider:

  • How to store the offline cached verification. _receipts is an array, but it can change over time, so try to find some other id to use for caching.
  • What UI action to take if a receipt is not valid? Maybe for now just show a twitter bootstrap alert? But it seems like an invalid receipt means the app should not run at all. Redirect to a "receipt not valid, here is what to do next" page? Ask the apps folks for guidance.

To see code with a receipt:

Go to:

install it, then go to this page to see a receipt dump:

ianb commented May 18, 2012

I'm doing some work on this here:
It'll probably be moved over to this file later:

It'll be UI-neutral.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment