Instantpay's Add Payment Details API is a secure, efficient tool. It helps businesses improve their payment management. Our API lets you add new payment details—like credit cards and bank accounts—directly into your system. It ensures that transactions stay smooth and error-free.
The Add Payment Details API aims to create a reliable, easy payment process. It helps businesses build trust and satisfaction with customers. This API will simplify payment management. Your team can then focus on providing customers with a seamless financial experience.
Request Parameters
Name | Type | Requirement | Description |
---|---|---|---|
gcId | String | Mandatory | Contact Id(You will get from Add Contact Response) |
accountType | String | Mandatory | It will be VPA,WALLET or Account |
upiId | String | Optional(Mandatory If accountType is VPA) | UPI ID |
accountNumber | String | Optional(Mandatory If accountType is ACCOUNT) | Bank Account Number |
accountIfsc | String | Optional(Mandatory If accountType is ACCOUNT) | Bank IFS Code |
beneficiaryName | String | Optional(Mandatory If accountType is ACCOUNT) | Name of the Beneficiary |
isVerificationOn | boolean | Optional | It will be true or false |
phoneNumber | String | Optional(Mandatory If accountType is WALLET) | Wallet Phone Number |
externalRef | String | Optional (Mandatory If isVerificationOn is true) | Unique Transaction Id |
latitude | String | Optional (Mandatory If isVerificationOn is true) | Current Location Latitude |
longitude | String | Optional (Mandatory If isVerificationOn is true) | Current Location Longitude |
Sample Request
curl --location 'http://api.localhost/contacts/payment' \
--header 'X-Ipay-Auth-Code: {{authCode}}' \
--header 'X-Ipay-Client-Id: {{clientId}}' \
--header 'X-Ipay-Client-Secret: {{clientSecret}}' \
--header 'X-Ipay-Endpoint-Ip: {{endPointIP}}' \
--header 'X-Ipay-Request-Hash: 123456789|123456789|123456789|123456789|123456789|123456789|1234' \
--header 'X-Ipay-Request-Timestamp: 1683697803000' \
--header 'X-Ipay-Hash-Check: OFF' \
--header 'User-Agent: InstantPayAPITest/1.0.0' \
--header 'Content-Type: application/json' \
--data-raw '{
"gcId" : "6447f86b1a1767723d055989",
"accountType" : "VPA",
"upiId" : "7428585742@ybl",
"accountNumber": "",
"accountIfsc" : "",
"beneficiaryName" : "",
"isVerificationOn" : true,
"phoneNumber" : "",
"latitude" : "",
"longitude" : "",
"externalRef": ""
}'
POST /contacts/payment HTTP/1.1
Host: api.localhost
X-Ipay-Auth-Code: {{authCode}}
X-Ipay-Client-Id: {{clientId}}
X-Ipay-Client-Secret: {{clientSecret}}
X-Ipay-Endpoint-Ip: {{endPointIP}}
X-Ipay-Request-Hash: 123456789|123456789|123456789|123456789|123456789|123456789|1234
X-Ipay-Request-Timestamp: 1683697816000
X-Ipay-Hash-Check: OFF
User-Agent: InstantPayAPITest/1.0.0
Content-Type: application/json
Content-Length: 301
{
"gcId" : "6447f86b1a1767723d055989",
"accountType" : "VPA",
"upiId" : "7428585742@ybl",
"accountNumber": "",
"accountIfsc" : "",
"beneficiaryName" : "",
"isVerificationOn" : true,
"phoneNumber" : "",
"latitude" : "",
"longitude" : "",
"externalRef": ""
}
Note
If isVerificationOn is true then Account or VPA will be Verified and then details were added and if isVerificationOn is false then it will add the details without verifying.
If the details were not verified then you can verify it later with Verify Payment API.
Response Parameter
Name | Type | Description |
---|---|---|
statuscode | String | Instantpay status code |
actcode | String | Action code |
status | String | status message |
data | Array | Response data(if Present) |
timestamp | String | Response time (YYYY-MM-DD HH:II:SS) |
ipay_uuid | String | Request reference number |
orderid | String | Transaction Id ( If transaction otherwise it is null ) |
enviroment | String | Live/Sandbox |
{
"statuscode": "TXN",
"actcode": null,
"status": "Payment Method Added Successfully",
"data": {
"gcId": "645383ba4acec95a32089822",
"accountType": "VPA",
"isPrimary": false,
"isVerified": false,
"accountNumber": "7428585742@ybl",
"accountIfsc": "",
"beneficiaryName": "Instantpay India Ltd.",
"updated_at": "2023-05-04T11:56:11.027000Z",
"created_at": "2023-05-04T11:56:11.027000Z",
"_id": "64539d5be8c166242100ce72"
},
"timestamp": "2023-05-04 17:26:11",
"ipay_uuid": "h068991615f9-fdf9-4b61-8ce9-0df4ecd1c891",
"orderid": null,
"environment": "LIVE",
"internalCode": null
}