RazorpayX - Payouts to Cards
With RazorpayX, you can make payouts directly to a credit card. The process of making a payout to a credit card is the same as normal payouts.
Step 1: Create a contact.
Step 2: Create a fund account with the contact's credit card details.
The API endpoint to create a fund account with the contact's credit card details is different for PCI DSS Compliant and PCI DSS non-compliant merchants. Ensure you use the correct endpoint.
Step 3: Create a payout to the fund account linked to the contact's credit card.
Feature Available on Request:
This feature is not available by default. To enable this feature, raise a request using the support form on the RazorpayX Dashboard.
Create a Contactđź”—
Use the below endpoint to create a contact.
Note:
- A new contact is created if any combination of the following details is unique:
name
,email
,contact
,type
andreference_id
. - If all the above details match the details of an existing contact, the API returns details of the existing contact.
- Use the Update Contact API if you want to make changes to an existing contact.
Request Parametersđź”—
name
mandatorystring
The contact's name. This field is case sensitive. Minimum 3 characters. Maximum 50 characters. Supported characters:a-z
,A-Z
,0-9
,space
,’
,-
,_
,/
,(
,)
and ,.
. For example,Gaurav Kumar
.email
optionalstring
The contact's email address. For example,gaurav.kumar@example.com
.contact
optionalstring
The contact's phone number. For example,9123456789
.type
optionalstring
Maximum 40 characters. Classification for the contact being created. For example,employee
. The following classifications are available by default:vendor
customer
employee
self
Additional classifications:
Additional classifications can be created via the Dashboard and then used in APIs. It is not possible to create new classifications via the API.
reference_id
optionalstring
Maximum 40 characters. A user-entered reference for the contact. For example,Acme Contact ID 12345
.notes
optionalobject
Key-value pair that can be used to store additional information about the entity. Maximum 15 key-value pairs, 256 characters (maximum) each. For example,"note_key": "Beam me up Scotty”
.
Response Parametersđź”—
id
string
The unique identifier linked to the contact. For example,cont_00000000000001
.entity
string
The entity being created. Here, it will becontact
.name
string
The contact's name. For example,Gaurav Kumar
.contact
string
The contact's phone number. For example,9123456789
.email
string
The contact's email address. For example,gaurav.kumar@example.com
.type
string
A classification for the contact being created. For example,employee
.reference_id
string
A user-entered reference for the contact. For example,Acme Contact ID 12345
.batch_id
string
This parameter is populated if the contact was created as part of a bulk upload. For example,batch_00000000000001
.active
boolean
Possible values:true
(default) = activefalse
= inactive
notes
object
Key-value pair that can be used to store additional information about the entity. Maximum 15 key-value pairs, 256 characters (maximum) each. For example,"note_key": "Beam me up Scotty”
.created_at
integer
Timestamp, in Unix, when the contact was created. For example,1545320320
.
Create a Fund Account for a Contact's Cardđź”—
PCI DSS Compliant Merchantsđź”—
If you are PCI DSS compliant, use the below API endpoint to create a fund account for the contact's card.
Note:
- A new fund account is created if any combination of the following details is unique:
contact_id
,card.name
andcard.number
. - If all the above details match the details of an existing fund account, the API returns details of the existing fund account.
- You cannot edit the details of a fund account.
Request Parameters
contact_id
mandatory-
string
This is the unique identifier linked to a contact. For example,cont_00000000000001
. account_type
mandatory-
string
The fund account type you want to link to the contact id. Here it iscard
. card
-
Details of the credit card.
number
mandatorystring
The 16 digit beneficiary credit card number. For example,765432123456789
.name
mandatorystring
Credit card holder's name. Maximum 100 characters. Supported characters:a-z
,A-Z
,0-9
,space
,-
,.
and'
. The credit card holder's name. For example,Gaurav Kumar
.
Request Parameters
id
-
string
The unique identifier linked to the fund account. For example,fa_00000000000001
. entity
-
string
Here, it will befund_account
. contact_id
-
string
The unique identifier linked to the contact. For example,cont_00000000000001
. account_type
-
string
The fund account type being created. Here, it will becard
. card
-
Details of the credit card used to create the fund account.
name
string
The credit card holder's name. For example,Gaurav Kumar
.last4
string
The last four digits of the credit card. For example,0001
.network
string
The credit card issuing network. Possible values are:
Visa
Mastercard
American Express
Diners Club
type
string
The card type. Currently, this can only becredit
.issuer
string
The name of bank that issued the card. For example,HDFC
. Refer to the Supported Banks and Payout Modes section for more details.
active
-
boolean
The status of the fund account. Possible values:true
(default) = activefalse
= inactive
batch_id
-
string
This parameter is populated if you created this contact as part of a bulk upload. For example,batch_00000000000001
. created_at
-
integer
Timestamp, in Unix, when the contact was created. For example,1545320320
.
PCI DSS Non-Compliant Merchantsđź”—
If you are not PCI DSS compliant:
- You cannot save a contact's card details on your server.
- You cannot make a private API call to create a fund account for the contact's card. You have to make a public API call.
Important:
Since this is a public API, ensure you store the fund_account_id
returned by Razorpay in your database and make payouts only to fund account IDs you recognize. Refer to our Security Risk document for more information.
If you are not PCI DSS compliant, use the below API endpoint to create a fund account for the contact's credit card.
Note:
- A new fund account is created if any combination of the following details is unique:
contact_id
,card.name
andcard.number
. - If all the above details match the details of an existing fund account, the API returns details of the existing fund account.
- You cannot edit the details of a fund account.
Request Parameters
contact_id
mandatory-
string
This is the unique identifier linked to a contact. For example,cont_00000000000001
. account_type
mandatory-
string
The fund account type you want to link to the contact id. Here it iscard
. card
-
Details of the credit card.
number
mandatorystring
The 16 digit beneficiary credit card number. For example,765432123456789
.name
mandatorystring
Credit card holder's name. Maximum 100 characters. Supported characters:a-z
,A-Z
,0-9
,space
,-
,.
and'
. The credit card holder's name. For example,Gaurav Kumar
.
Response Parameters
id
-
string
The unique identifier linked to the fund account. For example,fa_00000000000001
. entity
-
string
Here it will befund_account
. contact_id
-
string
The unique identifier linked to the contact. For example,cont_00000000000001
. account_type
-
string
The fund account type being created. Here, it will becard
. card
-
Details of the credit card that is being used to create the fund account.
name
string
The credit card holder's name. For example,Gaurav Kumar
.last4
string
The last four digits of the credit card. For example,0001
.network
string
The credit card issuing network. Possible values are:
Visa
Mastercard
American Express
Diners Club
type
string
The card type. Currently, this can only becredit
.issuer
string
The name of bank that issued the credit card. For example,HDFC
. Refer to the Supported Banks and Payout Modes section for more details.
active
-
boolean
The status of the fund account. Possible values:true
(default) = activefalse
= inactive
batch_id
-
string
This parameter is populated if you created this contact as part of a bulk upload. For example,batch_00000000000001
. created_at
-
integer
Timestamp, in Unix, when the contact was created. For example,1545320320
.
Create a Payoutđź”—
Use the below endpoint to create a payout.
Request Parametersđź”—
account_number
mandatorystring
The account from which you want to make the payout.
Account details can be found on the RazorpayX Dashboard. For example,7878780080316316
.- Pass your virtual account number if you want money to be deducted from your virtual account.
- Pass your current account number if you want money to be deducted from your current account.
Note:
This is NOT your contact's bank account number.
fund_account_id
mandatorystring
The unique identifier linked to a fund account. For example,fa_00000000000001
.amount
mandatoryinteger
The payout amount, in paise. For example, if you want to transfer ₹10000, pass1000000
. Minimum value100
.Note:
The value passed here does not include fees and tax. Fees and tax, if any, are deducted from your account balance.currency
mandatorystring
The payout currency. Here, it isINR
.mode
mandatorystring
The mode to be used to create the payout. Available modes:NEFT
RTGS
IMPS
UPI
Payout Modes are Case Sensitive:
The payout modes are case sensitive. When creating payouts using APIs, ensure payout modes are entered in upper case.
purpose
mandatorystring
The purpose of the payout that is being created. The following classifications are available in the system by default:refund
cashback
payout
salary
utility bill
vendor bill
Note:
Additional purposes for payouts can be created via the Dashboard and then used in the API. However, it is not possible to create a new purpose for the payout via the API.
queue_if_low_balance
optionalboolean
Possible values:true
- The payout is queued when your business account does not have sufficient balance to process the payout.false
(default) - The payout is never queued. The payout fails if your business account does not have sufficient balance to process the payout.
reference_id
optionalstring
Maximum length 40 characters. A user-generated reference given to the payout. For example,Acme Transaction ID 12345
. You can use this field to store your own transaction ID, if any.narration
optionalstring
Maximum length 30 characters. Allowed characters: a-z, A-Z, 0-9 and space. This is a custom note that also appears on the bank statement.Note:
â—Ź If no value is passed for this parameter, it defaults to the Merchant Billing Label.
â—Ź Ensure that the most important text forms the first 9 characters as banks may truncate the rest as per their standards.notes
optionalobject
Key-value pair that can be used to store additional information about the entity. Maximum 15 key-value pairs, 256 characters (maximum) each. For example,"note_key": "Beam me up Scotty”
.
Response Parametersđź”—
id
string
The unique identifier linked to the payout. For example,pout_00000000000001
.entity
string
The entity being created. Here, it will bepayout
.fund_account_id
string
The unique identifier linked to the fund account. For example,fa_00000000000001
.amount
integer
The payout amount, in paise. For example, if you want to transfer ₹10000, pass1000000
. Minimum value100
.Note:
The value passed here does not include fees and tax. Fees and tax, if any, are deducted from your account balance.currency
string
The payout currency. Here, it isINR
.notes
object
Key-value pair that can be used to store additional information about the entity. Maximum 15 key-value pairs, 256 characters (maximum) each. For example,"note_key": "Beam me up Scotty”
.fees
integer
The fees for the payout. This field is populated only when the payout moves to theprocessing
state. For example,5
.tax
integer
The tax that is applicable for the fee being charged. This field is populated only when the payout moves to theprocessing
state. For example,1
.status
string
The status of the payout. Possible payout states:queued
pending
(if you have Approval Workflow enabled)rejected
(if you have Approval Workflow enabled)processing
processed
cancelled
reversed
utr
string
The unique transaction number linked to a payout. For example,HDFCN00000000001
.mode
string
The mode used to make the payout. Available modes:NEFT
RTGS
IMPS
UPI
Payout Modes are Case Sensitive:
The payout modes are case sensitive.
purpose
string
The purpose of the payout that is being created. The following classifications are available in the system by default:refund
cashback
payout
salary
utility bill
vendor bill
Note:
Additional purposes for payouts can be created via the Dashboard and then used in the API. However, it is not possible to create a new purpose for the payout via the API.
reference_id
string
Maximum length 40 characters. A user-generated reference given to the payout. For example,Acme Transaction ID 12345
. You can use this field to store your own transaction ID, if any.narration
string
Maximum length 30 characters. Allowed characters: a-z, A-Z, 0-9 and space. This is a custom note that also appears on the bank statement.Note:
â—Ź If no value is passed for this parameter, it defaults to the Merchant Billing Label.
â—Ź Ensure that the most important text forms the first 9 characters as banks may truncate the rest as per their standards.batch_id
string
This parameter is populated if the contact was created as part of a bulk upload. For example,batch_00000000000001
.failure_reason
string
The reason for the payout failing.created_at
integer
Timestamp, in Unix, when the contact was created. For example,1545320320
.