Search Loyalty Account
GET/client/partners/:partner_id/accounts/links
Returns the loyalty account id and link status based on an email address or loyaltyId or partnerLinkIds passed in. Up to 25 individual emails and/or loyaltyIds or partnerLinkIds can be searched at once.
Note that "linkStatus": "CAN_LINK" is dependent on "status": true in the partner configuration; likewise, the "balance" object and its attributes being displayed depends on "balance": true in the partner configuration.
X-Identifier-Type
Possible Values
-
LOYALTY_ID (Default if not provided)
-
PARTNER_LINK_ID
-
EMAIL
Request
Path Parameters
- PartnerId - {{partner_id}}
Query Parameters
-
Email address - {{email_id}}
-
Card # - {{loyalty_id}}
-
partner link ID - {{partnerLinkId}}
Response
| Attribute | Definition | Format | Notes |
|---|---|---|---|
| searchResults | Array of search results. | Array | |
| requestParameter | The original search parameter that was matched to this result. | String | This is the loyalty_id, the unique identifier on the account. Note that this is returned only if the linkStatus is "CAN_LINK" or "GHOST". |
| accountId | Return unique identifier of account | String | |
| accountStatus | Returns status of account | Enum: "ACTIVE" or "INVALID" | ACTIVE = active or unregistered INVALID = everything else |
| loyaltyId | Returns unique loyalty identification number | Number | |
| linkStatus | The current status of whether the account can be found and linked. | Enum: "INVALID", "CAN_LINK", or "GHOST" | INVALID = not found or cannot be linked CAN_LINK = found and can be linked GHOST = account exists but cannot be linked due to account status |
| balance | Shows account balance information. | Object | Only shown if enabled in the partner configuration. Includes points and dollar balance information and min/max redemption limits. Includes from pointsBalance to userMaxRedeemDollars below. |
| pointsBalance | The member's current point balance. | Number | |
| dollarBalance | The member's current dollar balance. | Number | |
| availablePointBalance | The current number of points available to the member for redemption. | Number | |
| availableDollarBalance | The current number of dollars available to the member for redemption. | Number | |
| userMinRedeemPoints | The minimum number of points the member can redeem. | Number | |
| userMinRedeemDollars | The minimum number of dollars the member can redeem. | Number | |
| userMaxRedeemPoints | The maximum number of points the member can redeem. | Number | |
| userMaxRedeemDollars | The maximum number of dollars the member can redeem. | Number | |
| household | Contains data about household related to loyalty account. | Object | Contains objects and attributes below from id to balance |
| id | Unique identifier for the household. | String | |
| role | Role of the member within the household. | Enum: "PRIMARY" or "SECONDARY" | First member who sent household invitations is "PRIMARY", all others are "SECONDARY" |
| balance | Object containing all relevant household balance data. | Object | Contains attributes below from totalPointBalance to maxRedeemDollars |
| totalPointBalance | Total point balance for the household. | Number | |
| totalDollarBalance | Total dollar balance for the household. | Number | |
| totalAvailablePointBalance | Total balance of available points. | Number | |
| totalAvailableDollarBalance | Total balance of available dollars. | Number | |
| totalRedeemablePointBalance | Total balance of redeemable points. | Number | |
| totalRedeemableDollarBalance | Total balance of redeemable dollars. | Number | |
| minRedeemPoints | Minimum number of points that can be redeemed. | Number | |
| maxRedeemPoints | Maximum number of points that can be redeemed. | Number | |
| minRedeemDollars | Minimum number of dollars that can be redeemed. | Number | |
| maxRedeemDollars | Maximum number of dollars that can be redeemed. | Number |
Error Responses
| statusCode | errorMessage | errorCode | Definition |
|---|---|---|---|
| 404 Not Found | Partner {{partner_id}} cannot be found. | INVALID_PARTNER_ID | The partner_id does not have a valid value. |
Request
Responses
- 200
- 404
- default
200 - Searched by loyaltyId (Can Link)
404 - Invalid Base URL/Partner ID
200 - Success Result Account with Household