Purchase With Token

Info

This endpoint allows merchants to process transactions using a tokenized card created with the add card endpoints (direct, redirect). The token represents the securely stored payment information of the associated customer.

Endpoint

https://ccapi.iotpaycloud.com/v3/cc_purchasewithtoken

Method

POST

Content-Type: application/json;charset=UTF-8

Request
namerequiredtypesampledescription
mchIdyString(30)10000701assigned by IOTPay
loginNameyString(12)jack123merchant's login name
currencyyString(3)CADfor now only CAD supported
mchOrderNoyString(30)1234567890abcassigned by merchant
cardIdyString(30)604567999assigned by merchant
amountyInt1500in cents
subjectnString(64)
bodynString(250)
clientIpnString(50)192.77.33.56consumer's ip address, for better transaction trace
signyString(32)C380BEC2BFD727A4B6845133519F3AD6Sign algorithm
Response
namerequiredtypesampledescription
retCodeyStringSUCCESS or FAIL
retMsgyStringif failed, message will contain the reason
retDatayJSONif retCode=SUCCESS, card info returned
retData contains order information:
namerequiredtypesampledescription
payOrderIdyStringPC20240101195511712374441010generated by IOTPay
mchIdyString10000701assigned by IOTPay
mchOrderNoyString1234567890abcassigned by merchant
originalOrderIdyStringoriginal pay order id if payType=refund
amountyInt1500in cents
currencyyStringCADfor now only CAD supported
payTypeyStringpay or refund
refundableyInt1500in cents
statusyInt22 or 3 means success
paySuccTimeyString2021-04-07 19:44:51time stamp for the moment when the payment succeeded
cardNumyString432567******2266card number associated with the token
expiryDateyStringexpiry date of the card associated with the token
invoiceNumyString
authNumyString
transNumyString
channelyStringPF_CCPF_CC or UPI_EX
Last Updated: