Get credential types
Credential types refers to the type of reward credentials such as URLs, card numbers, PINs, etc. that are being loaded. It shows you every single type of credentials each reward uses in the catalog, including what's returned in the credentialList.
We categorize credential types based on internal factors of the Tango system. You can see all possible credentialTypes
using the GET {URI}/credentiallist
endpoint. The GET {URI}/catalogs
returns the credential types information for each item in the catalog. Note that many of the definitions found in the GET {URI}/credentialtypes
are similar or identical.
Get a list of credential types
The GET {URI}/credentialTypes
call returns the list of what credential types you might encounter and the GET {URI}/catalogs
call returns the credential types information for each item in the catalog. There is no parameters for this endpoint.
Endpoint | Purpose |
---|---|
GET {URI}/credentialtypes | Get a List of credential types |
The following payload shows a list of credential types in a Tango platform using GET {URI}/credentialTypes
endpoint:
[
{
"credentialType": "barcodeNumber",
"description": "A numeric or alphanumeric string that provides a human readable version of the information embedded in a barcode. This is typically used in conjunction with the barcodeUrl credential."
},
{
"credentialType": "barcodeUrl",
"description": "A URL for a barcode image. This is typically used in conjunction with the barcodeNumber credential."
},
{
"credentialType": "bypassUrl",
"description": "A landing page URL that includes secondary credential information. This removes the need for the recipient to input secondary credentials on the landing page."
},
{
"credentialType": "cardCode",
"description": "A numeric or alphanumeric string."
},
{
"credentialType": "cardNumber",
"description": "A numeric or alphanumeric string."
},
{
"credentialType": "cvc2",
"description": "A 3-digit numeric code used as a secondary credential for financial products."
},
{
"credentialType": "eventNumber",
"description": "A secondary credential that is numeric or alphanumeric string."
},
{
"credentialType": "expirationDate",
"description": "A date after which the issued reward will no longer be redeemable."
},
{
"credentialType": "pin",
"description": "Personal Identification Number. A secondary credential that is a numeric or alphanumeric string."
},
{
"credentialType": "redemptionUrl",
"description": "A landing page URL where reward credentials and redemption information are typically presented. The landing page may or may not require the recipient to enter one or more secondary credentials to complete the reward redemption process."
},
{
"credentialType": "secretCode",
"description": "A secondary credential that is numeric or alphanumeric string."
}
]
Reward types and credential types
Tango returns the following reward types and credential types. If your integration requires displaying reward data in app or creating custom reward emails, you may need to add logic to parse the returned reward data correctly.
Reward type | Description | Credential type | Integration example |
---|---|---|---|
text | Plain text | cardNumber, PIN, securityCode, claimCode, etc. | Wrap in a <span> tag |
URL | URL to a reward landing page | redemptionUrl, securityUrl | Wrap in an <a> tag |
barcode | URL for a barcode image | barcode | Add an <img> tag |
date | ISO datedtime | expirationDate | Display in localized date format based on locale of reward according to RFC 3339, such as 2016-01-01T00:00:00Z |
Credential type key
For better parsing and display of reward data, we have added the credentialType
key to the credentialList
object in the Order response.
The following payload shows the credential types
such as redemptionUrl
or expirationDate
as part of the credentialList
object in the order response when performing the GET {URI}/orders/{referenceOrderID}
call:
"credentialList": [
{
"label": "Redemption Link",
"value": "https://sandbox.rewardlink.io/r/1/_KBqZ9x056xOCrp34qxM74R2KQqYJlHoaJKZAXbwkSQ",
"type": "url",
"credentialType": "redemptionUrl"
},
{
"label": "Expiration",
"value": "",
"type": "date",
"credentialType": "expirationDate"
}
Note:
We are continuously expanding our catalog and it is likely that new reward types will arise over time. For this reason we recommend a fallback/default to handle unspecified types as text.
The possible response codes for this endpoint is:
- 200 OK
- 400 Bad Request
- 401 Unauthorized
- 403 Forbidden
Updated 7 days ago