PATCH
/
api
/
v1
/
loyalty
/
{id}
curl --request PATCH \
  --url https://api.passentry.com/api/v1/loyalty/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "balance": 10
}'
{
  "data": {
    "id": "2258d9ed-05bc-47cd-be65-83b9bb5e0273",
    "type": "pass",
    "attributes": {
      "downloadUrl": "https://www.example.com?pass=2258d9ed-05bc-47cd-be65-83b9bb5e0273",
      "passType": "storeCard",
      "deviceType": "android",
      "createdAt": "2022-01-01T00:00:00Z",
      "status": "active",
      "extId": "4e9ab9e571bbc8ff64e7",
      "passTemplateUuid": "b7f3372d08eddd76f28926ff",
      "passTemplateName": "PassEntry Store",
      "nfc": "941c35348d16187199a6b41047f0b7862b2dcb67",
      "barcode": null,
      "passContent": {
        "description": "Template Description",
        "centralTitle": "Template Central Title",
        "fullName": "Robert Smith",
        "labelTwo": "11",
        "points": "17",
        "terms": "Your use of the Google Wallet is subject to Google's terms and conditions of use, which PassEntry are not responsible for."
      }
    }
  },
  "meta": {
    "loyalty": {
      "balance": 17
    }
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string
required

Pass UUID or External ID

Query Parameters

includePassDesign
boolean

If true, includes the pass design in the response

includeLocations
boolean

If true, includes the locations in the response if any are present

includeBeacons
boolean

If true, includes the beacons in the response if any are present

Body

application/json
balance
integer

If integer is positive, balance is added. If negative, balance is subtracted. Cannot be used with overrideBalance key

Example:

-10

overrideBalance
integer

Override the balance and set it to this value. Cannot be used with balance key

Example:

0

message
string

Push Notification message to display. Only used if pass is active. Use alongside balance or overrideBalance keys

Response

200 - application/json
successful
data
object
meta
object

Was this page helpful?