v1

latestOpenAPI 3.0.1Apache 2.02026-07-2647148658.0 KB
Token Management

Create/Update Token Details

Create/Update a token using the OnlinePay Tokenisation Service.

If a token exists for the card already, it is updated with the information in the request. Otherwise, a new token is created for the given card.

put/api/v2/card

Request body

token_scopestring uuid required

The token scope under which this token was created.

encrypted_cardstring required

The cardholder data encrypted using the OnlinePay provided public key. This can be obtained using either Verifone.JS solution or OnlinePay Checkout in capture mode.

The data to encrypt is a JSON with possible tags being cardNumber, sequenceNumber, cardholderName, startMonth, startYear, expiryMonth, expiryYear, cvv. This should be a single JSON line and should not contain any spaces. Read <a target="_blank" style="color:blue;" href="https://verifone.cloud/docs/online-payments/secure-card-capture-key">Secure card capture key</a> for details.

Additionally, a tag called captureTime must be presenting indicating the time the card was captured in UTC in format RFC 3339, section 5.6. eg. 2019-08-24T14:15:22Z. Encrypted card is valid for only 15 minutes.

card_brandstring

Represents a Card type or brand. It should correspond to a consistent name, the list of standard names is as follows:

ValueDescription
AMEXAmerican Express
JCBJapan Credit Bureau
MASTERCARDMasterCard
VISAVisa
token_type'REUSE' | 'ANALYTICS' | 'REUSE_AND_ANALYTICS'

Token type

reuse_token_type'INTERNAL'

The type of Reuse Token. This indicates if the reuse token is an internal OnlinePay type or an external Third-Party type.

token_expiry_datestring date

When this Token will expire.

public_key_aliasstring required

Example request

{
  "token_scope": "0e48425a-f1bc-431a-b7d8-f866de8ba276",
  "encrypted_card": "U3dhZ2dlciByb2Nrcw=="
}

Response

Token result

reuse_tokenstring

The identifier used to represent the Cardholder data.

analytics_tokenstring

A token that cannot be reversed to Card Holder data. This is included in a Payment for auditing and tracking purposes.

binstring

The Bank Identification Number (also called IIN - Issuer Identification Number) of this card.

expiry_monthinteger

A 2 digit value as shown on card. ISO8583 - DE 14

expiry_yearinteger

A 4 digit value as shown on card.

last_fourstring

The last 4 digits of the card number.

card_holder_namestring

The Card holder name as it appears on the card.

updated_atstring date

The last date token was updated.

created_atstring date

The last date token was created.

token_expiry_datestring date

When this Token will expire.

reuse_token_type'INTERNAL'

The type of Reuse Token. This indicates if the reuse token is an internal OnlinePay type or an external Third-Party type.

token_scopestring uuid

The token scope under which this token was created.

token_status'DELETED' | 'ACTIVE' | 'SUSPENDED'

The status of the Token.

currency'AUD'

Three-letter ISO 4217 alphabetical currency code. Supported values are: AUD

issuer_country'ZZZ' | 'ABW' | 'AFG' | 'AGO' | 'AIA' | 'ALA' | 'ALB' | 'AND' | 'ARE' | 'ARG' | 'ARM' | 'ASM' | 'ATA' | 'ATF' | 'ATG' | 'AUS' | 'AUT' | 'AZE' | 'BDI' | 'BEL' | 'BEN' | 'BES' | 'BFA' | 'BGD' | 'BGR' | 'BHR' | 'BHS' | 'BIH' | 'BLM' | 'BLR' | 'BLZ' | 'BMU' | 'BOL' | 'BRA' | 'BRB' | 'BSB' | 'BRN' | 'BTN' | 'BVT' | 'BWA' | 'CAF' | 'CAN' | 'CCK' | 'CHE' | 'CHL' | 'CHN' | 'CIV' | 'CMR' | 'COD' | 'COG' | 'COK' | 'COL' | 'COM' | 'CPV' | 'CRI' | 'CUB' | 'CUW' | 'CXR' | 'CYM' | 'CYP' | 'CZE' | 'DEU' | 'DJI' | 'DMA' | 'DNK' | 'DOM' | 'DZA' | 'ECU' | 'EGY' | 'ERI' | 'ESH' | 'ESP' | 'EST' | 'ETH' | 'FIN' | 'FJI' | 'FLK' | 'FRA' | 'FRO' | 'FSM' | 'GAB' | 'GBR' | 'GEO' | 'GGY' | 'GHA' | 'GIB' | 'GIN' | 'GLP' | 'GMB' | 'GNB' | 'GNQ' | 'GRC' | 'GRD' | 'GRL' | 'GTM' | 'GUF' | 'GUM' | 'GUY' | 'HKG' | 'HMD' | 'HND' | 'HRV' | 'HTI' | 'HUN' | 'IDN' | 'IMN' | 'IND' | 'IOT' | 'IRL' | 'IRN' | 'IRQ' | 'ISL' | 'ISR' | 'ITA' | 'JAM' | 'JEY' | 'JOR' | 'JPN' | 'KAZ' | 'KEN' | 'KGZ' | 'KHM' | 'KIR' | 'KNA' | 'KOR' | 'KWT' | 'LAO' | 'LBN' | 'LBR' | 'LBY' | 'LCA' | 'LIE' | 'LKA' | 'LSO' | 'LTU' | 'LUX' | 'LVA' | 'MAC' | 'MAF' | 'MAR' | 'MCO' | 'MDA' | 'MDG' | 'MDV' | 'MEX' | 'MHL' | 'MKD' | 'MLI' | 'MLT' | 'MMR' | 'MNE' | 'MNG' | 'MNP' | 'MOZ' | 'MRT' | 'MSR' | 'MTQ' | 'MUS' | 'MWI' | 'MYS' | 'MYT' | 'NAM' | 'NCL' | 'NER' | 'NFK' | 'NGA' | 'NIC' | 'NIU' | 'NLD' | 'NOR' | 'NPL' | 'NRU' | 'NZL' | 'OMN' | 'PAK' | 'PAN' | 'PCN' | 'PER' | 'PHL' | 'PLW' | 'PNG' | 'POL' | 'PRI' | 'PRK' | 'PRT' | 'PRY' | 'PSE' | 'PYF' | 'QAT' | 'REU' | 'ROU' | 'RUS' | 'RWA' | 'SAU' | 'SDN' | 'SEN' | 'SGC' | 'SGP' | 'SHN' | 'SJM' | 'SLB' | 'SLE' | 'SLV' | 'SMR' | 'SOM' | 'SPM' | 'SRB' | 'SSD' | 'STP' | 'SUR' | 'SVK' | 'SVN' | 'SWE' | 'SWZ' | 'SXM' | 'SYC' | 'SYR' | 'TCA' | 'TCD' | 'TGO' | 'THA' | 'TJK' | 'TKL' | 'TKM' | 'TLS' | 'TON' | 'TTO' | 'TUN' | 'TUR' | 'TUV' | 'TWN' | 'TZA' | 'UGA' | 'UKR' | 'UMI' | 'URY' | 'USA' | 'UZB' | 'VAT' | 'VCT' | 'VEN' | 'VGB' | 'VIR' | 'VNM' | 'VUT' | 'WLF' | 'WSM' | 'YEM' | 'ZAF' | 'ZMB' | 'ZWE'

The ISO 3166-1 alpha-3 country code.<blockquote><strong>Note:</strong> The country code for Great Britain is <code>GB</code> and not <code>UK</code> as is used in that country's top-level domain names.</blockquote>.

Example response

{
  "bin": "492912",
  "expiry_month": 12,
  "expiry_year": 2021,
  "last_four": "3127",
  "card_holder_name": "MR J HOLDER",
  "bin_details": {
    "bin": "492912",
    "brand": "VISA",
    "issuer_name": "HSBC",
    "last_four": "3127",
    "type": "CREDIT",
    "variant": "NEW_WORLD"
  },
  "token_status": "ACTIVE"
}