Set Primary Payment

Improve your payment processes with Instantpay's Set Primary Payment API. It lets businesses easily set a primary payment method. This API prioritizes payment options. It ensures smooth handling of recurring transactions, like subscription renewals.

Integrating the Set Primary Payment API can streamline payment workflows. It gives users a simple way to manage their primary payment preferences. This feature is vital for those seeking to improve payment reliability. It will enhance user satisfaction by making payment management more intuitive and seamless.

Request Parameters

NameTypeRequirementDescription
gcIdStringMandatoryContact Id(You will get from Add Contact Response)
paymentIdStringMandatoryPayment Unique Id

Sample Request

curl --location 'https://api.instantpay.in/contacts/payment/primary' \
--header 'Content-Type: application/json' \
--header 'X-Ipay-Auth-Code: {{authCode}}' \
--header 'X-Ipay-Client-Id: {{clientId}}' \
--header 'X-Ipay-Client-Secret: {{clientSecret}}' \
--header 'X-Ipay-Endpoint-Ip: {{endPointIP}}' \
--data '{
    "gcId" : "645383ba4acec95a32089822",
    "paymentId" : "64539d55f60d424cb90b89a2"

}'
POST /contacts/payment/primary HTTP/1.1
Host: api.instantpay.in
Content-Type: application/json
X-Ipay-Auth-Code: {{authCode}}
X-Ipay-Client-Id: {{clientId}}
X-Ipay-Client-Secret: {{clientSecret}}
X-Ipay-Endpoint-Ip: {{endPointIP}}
Content-Length: 90

{
    "gcId" : "645383ba4acec95a32089822",
    "paymentId" : "64539d55f60d424cb90b89a2"

}

Response Parameter

NameTypeDescription
statuscodeStringInstantpay status code
actcodeStringAction code
statusStringStatus message
dataArrayResponse data(if Present)
timestampStringResponse time (YYYY-MM-DD HH:II:SS)
ipay_uuidStringRequest reference number
orderidStringTransaction Id ( If transaction otherwise it is null )
environmentStringLive/Sandbox
internalCodeStringIt will be null
{
    "statuscode": "TXN",
    "actcode": null,
    "status": "Primary Account Set Successfully",
    "data": null,
    "timestamp": "2023-05-04 17:26:53",
    "ipay_uuid": "h0069916163a-4348-4424-8efb-313bb38886a7",
    "orderid": null,
    "environment": "LIVE",
    "internalCode": null
}
Language
Click Try It! to start a request and see the response here!