Card Validation.

API Explorer
loading...
POST

The getHostedPaymentPage API allows merchants to validate the card to use it for further transactions like tokenized Sale & Recurring Payments. In the request payload, if transactionType is set to 2, and the amount value is set to 0, iPOS-HPP API will validate the card input entered by the customer on the payment page form.

Header Parameters

token*string

Authentication token generated using the API Key and Secret Key. Required for all API requests.

Request Body

application/json

Response Body

application/json

application/json

curl -X POST "https://example.com/card-validation" \  -H "token: string" \  -H "Content-Type: application/json" \  -d '{    "merchantAuthentication": {      "merchantId": "567025324141",      "transactionReferenceId": "TXNId00111223334571666"    },    "transactionRequest": {      "transactionType": 2,      "amount": "0",      "calculateFee": true,      "calculateTax": true,      "tipsInputPrompt": true,      "expiry": 7,      "feeRemoved": false,      "invoiceTxn": true,      "requestCardToken": true    },    "personalization": {      "logoUrl": "",      "description": "",      "themeColor": "#9a17ff",      "disclaimer": ""    },    "notificationOption": {      "postAPI": "https://example.com/post-notification-endpoint",      "failureUrl": "https://example.com/payment-failure",      "returnUrl": "https://example.com/payment-return",      "notifyByRedirect": true,      "notifyBySMS": false,      "notifyByPOST": true,      "authHeader": "",      "cancelUrl": "",      "mobileNumber": ""    },    "preferences": {      "eReceipt": true,      "avsVerification": true,      "integrationType": 1,      "customerName": "",      "customerMobile": "+14242424243",      "customerEmail": "",      "sendPaymentLink": true,      "integrationVersion": "v2",      "requestCardToken": true    }  }'

{
  "message": "Url generated successfully",
  "information": "https://payment.ipospays.tech/api/v1/externalPay?t=<token-value>"
}

{
  "errors": [
    {
      "field": "merchantAuthentication.merchantId",
      "message": "Invalid Merchant Id"
    },
    {
      "field": "transactionRequest.transactionType",
      "message": "Invalid Transaction Type"
    }
  ]
}