Request by sending an email to developer@vatom.com
The Vatom Loyalty Program allows each business to define its own currency and issue tokens of this denomination. When users collect and hold these tokens in their wallets, a separate balance will be maintained for the denominations issued by each business participating in the Vatom Loyalty Program.
A business team member with the Business Admin role may enable the Loyalty Program from the business settings page shown below. To reach this page, go to Vatom Studio, locate the Account Dropdowns in the upper right, select a business from the Business Dropdown, then select 'Settings' from the User Dropdown.
Once the program is enabled, define a coin denomination for the business currency and determine how many tokens should initially be held in the treasury. You can also upload an image representing the denomination of your currency.
When the treasury runs low, you can always come back here to restock it or you can do so programmatically using the REST APIs documented in the pages that follow.
You can query basic information about the loyalty program of any participating
business if you know its Business ID.
The Get Business Info REST API
takes a business ID as a path parameter and responds with a JSON object that will
contain a "coin"
object with an "enabled":true
property if that business has
the Loyalty Program enabled. Other properties such as the denomination of the
currency are also included in the "coin"
object.
An example is given below:
"coin": {
"enabled": true,
"name": "gem",
"plural_name": "gems",
"symbol": null,
"logo": "https://resources.vatom.com/iFrQOne7un/84c8fce0-f432-11ed-92a5-bd2118fc7b44.png",
"type": null
}
The Loyalty REST APIs come in two categories:
The User focussed APIs all require a user ID to be included as a path paramenter. They allow you query that user's token balances and transaction history across all business currencies and transfer any of the tokens held to other users.
The Business focussed APIs all require a business ID to be included as a path paramenter. They allow you to fund or check the treasury balance for that business, query a user's balance or transaction history relevant to the currency of that business, or exchange this currency between this business and a user.
Note that the :businessID
placeholder value specified in path parameters will be
automatically filled with the default
Business ID for that user when The Lab
panel is opened. It is necessary to manually edit it if you wish to specify a
different value. The :userID
placeholder value is not automatically filled in.
You must manually insert it when using The Lab panel.