The Emarsys Loyalty Wallet is a full solution to a Loyalty program embedded in your website with very minimal
When the Wallet initializes correctly, you will see the Wallet Status or Join button in their configured location in the online shop. If not, you should see an error message which you can send us to start troubleshooting.
In order to install the Loyalty SDK, you need to embed the following code in the shop code footer so that it is included in ALL pages in the online store (at least all that should show the Wallet).
This example is in PHP, and includes your
secret. Upon request, the code is available in other languages (Java, Go, Ruby, etc), too.
Please keep these settings safe, and in any case they are disclosed let us know as soon as possible, so that we can change them.
For each shop visitor please set their
customerId) in the
$contactId variable (set to firstname.lastname@example.org in the example). If the user is not logged in and there is no unique identifier yet, then pass an empty string.
We have generated 3 sample users for testing:
You should register these users in your shop as customers, and then try the example code above for them to see that you don’t get any errors and that you see their points status.
On pages where you do not want the Loyalty Wallet to appear, simply do not include the above code. While this may seem obvious, you may need additional code for this logic, depending on your site structure.
If you do not see the Wallet after installation, take a look in the browser console logs for any errors and let us know.
For more information on the Loyalty API, see https://emarsys-loyalty-specs.api-docs.io/v0.1.0/contacts.