Use this API to choose the preferred mode of payment for the mandate. Supported Payment Method types include UPI, NetBanking, Card, Wallet, eNACH with Card/NB/Aadhaar authentication, and eMandate (Direct Bank NB Mandate). The same API will also validate the payment method specific data like UPI VPA etc.
Share the URL that you get in the response body with your end customer, for whom this mandate is being initiated. They will have to run the same to authorize the collect request from their UPI App.
This API is not required for the merchants using Juspay's Payment Page product.
Response Parameters for the Mandate Registration API: (click to view)
Parameter | Type | Description |
---|---|---|
order_id | String | Unique Identifier for the order. |
txn_id | String | Transaction ID for the payment attempt. |
txn_uuid | String | Transaction UUID |
status | String | Status of the transaction. See Appendix below for status mapping. PENDING_VBV indicates that the transaction requires authentication to complete. |
payment:wwiw {{...},{...}} | Object | Contains authentication object:{ method, url, params }(also sdk_params object for UPI Intent) |
Parameters for the payment
object:
{click to open)
authentication: {method, url, params} | Object | Authentication parametersww |
Parameters for the authentication
object:
(click to open)
Parameter | Type | Description |
---|---|---|
method | String | HTTP Method for authentication. Can be one of GET or POST. (For redirection instructions, see the "Handling the Redirection Method" section.) |
url | String | URL to which the user has to be taken to for completing the authentication |
params | String | Present only when the method is POST. Parameter map that has to be sent along with the URL for authentication. Do not hardcode the params in your client * Never assume that you will receive param “x” or param “y”. This is completely dynamic and will vary on a case by case basis. |
sdk_params: {{...},...} | Object | SDK parameterswwwwww (Used only for UPI Intent) |
Parameters the sdk_params
object:
(click to open)
scheme | String | Should be "mandate" | |
uri_params: {param1, param2,...} | Object | URI parameterswwwwtwww |
Parameters for the uri_params
object:
(click to open)
Parameter | Type | Example | |
---|---|---|---|
validitystart | String | "eulcEPzPd244hfrGShFpH" | |
validityend | String | "24082037" | |
tr | String | "PAYTMSUBS202206203480824046791145" | |
tn | String | "Amount%20to%20be%20paid%20now%20is%20Rs%201.00" | |
tid | String | "PYTM20220620937257791803424" | |
recur | String | "ASPRESENTED" | |
purpose | String | "14" | |
pn | String | "test" | |
pa | String | "[email protected]" | |
orgid | String | "00000" | |
mode | String | "00" | |
mn | String | "Subscription%20for%20testaccount" | |
mc | String | "5811" | |
cu | String | "INR" | |
amrule | String | "MAX" | |
am | String | "1000.00" |
offer_details:wi { offers: [...]} | Array in Object | The mechanism of running offers is the responsibility of merchants in collaboration with PG/Banks (used only for UPI Intent). |
Status | ID | Meaning |
---|---|---|
NEW | 10 | Newly created order |
PENDING_VBV | 23 | Authentication is in progress |
CHARGED | 21 | Successful transaction |
AUTHENTICATION_FAILED | 26 | User did not complete authentication |
AUTHORIZATION_FAILED | 27 | User completed authentication, but bank refused the transaction |
JUSPAY_DECLINED | 22 | User input is not accepted by the underlying PG |
AUTHORIZING | 28 | Transaction status is pending from bank |
Payment Gateways and Supported Payment Methods: (click to view)
PG - PMT | Card | Netbanking | Wallet | UPI Intent | UPI Collect | Aadhar |
---|---|---|---|---|---|---|
AXIS_BIZ | No | No | No | Yes | Yes | No |
BILLDESK | Yes | No | No | No | Yes | No |
CAMSPAY | No | No | No | No | Yes | No |
PAYU | Yes | Yes | No | No | Yes | No |
PAYTM_V2 | Yes | No | Yes | Yes | Yes | No |
PHONEPE | No | No | No | Yes | No | No |
RAZORPAY | Yes | Yes | No | No | Yes | Yes |
TPSL | No | Yes | No | No | No | Yes |
YES_BIZ | No | No | No | Yes | Yes | No |
⭣The request for the Mandate Registration API consists of the following Parameter Groups: (click to open tables):
Payment Method Parameters:
test
Field | Type | Description | |
---|---|---|---|
order_id | * | String | Unique Identifier for the order. |
merchant_id | * | String | ID of the merchant_account that you hold with us. |
payment_method_type | * | String | Payment method type of transaction. Possible values: UPI / NB / CARD / WALLET / AADHAAR For eNACH, authentication verification can be done via CARD, NB & AADHAAR (Note: NB eMandate supports only NB login authentication. Banks live with NB eMandate are HDFC (Register + Debit), ICICI (Register + Debit), SBI (Register only) and Axis (Register only)) Banks live with eNACH for NB, CARD and AADHAAR authentication https://www.npci.org.in/PDF/nach/live-members-e-mandates/Live-Banks-in-API-E-Mandate.pdf |
payment_method | * | String | Payment method of transaction. COLLECT - For UPI Collect transaction. PAY - For UPI_PAY transaction. For card mandate - One of VISA/MASTERCARD/MAESTRO/AMEX/RUPAY. This is usually inferred from the card number itself and we will take care of this if you are unable to provide this from your end. Please refer to /paymentmethods API https://developer.juspay.in/reference/payment-methods for EMANDATE payment_method values. |
redirect_after_payment | * | Boolean | We recommend that you set this to true and use the redirection flow.If set to true , then the user is redirected to the return_url configured for the order.If set to false , then the user will be stopped at the response page from the gateway.Your client should be able to read the page/title to infer that the user has completed the transaction. |
format | * | String | If it is set to JSON, then the response will be HTTP 200 with a JSON formatted text. Otherwise, the response is HTTP 302 with the Location attribute having the destination URL. |
Bank Details Parameters:
Field | Type | Description | |
---|---|---|---|
bank_name | String | Name of bank that is holding the account | |
bank_account_number | * | String | Bank account number. Required for emandate/e-NACH, or when mandate_type = EMANDATE. |
bank_beneficiary_name | String | Account holder name. Should contain alphabetical characters only. Required for emandate/e-NACH, or when mandate_type = EMANDATE. | |
bank_ifsc | String | Bank IFSC. Required for emandate/e-NACH, or when mandate_type = EMANDATE. |
Card Data Parameters:
test
Field | Type | Description | |
---|---|---|---|
card_token | * | string | A valid card token obtained using /card/list API. If you send this parameter, then card_number, name_on_card, card_exp_year, and card_exp_month fields are not required.If the token is generated using the /card/tokenize API, card_number, name_on_card, card_exp_year, card_exp_month, and card_security_code fields are not required. Can only be used when mandate_type = MANDATE for a stored card. |
card_number | String | A valid credit/debit card number. Required when mandate_type = MANDATE for a new card transaction. | |
card_exp_year | String | Represent the expiry year of the card as YY (two digits only). Required when mandate_type = MANDATE for a new card transaction. | |
card_exp_month | String | Represent the expiry month of the card as MM (two digits only). Required when mandate_type = MANDATE for a new card transaction. | |
card_security_code | String | CVV of the card. Usually three digits. Required when mandate_type = MANDATE for a new card transaction. | |
name_on_card | String | Card holder name. Should contain alphabetical characters only. Required when mandate_type = MANDATE for a new card transaction. | |
save_to_locker | String | This is a boolean variable and accepts true/false. If set to true, then the card will be saved in locker when the transaction is successful. Else, the card will not be saved. |
Field | Type | Description | |
---|---|---|---|
upi_vpa | String | VPA to which the collect request must be sent. | |
mandate_type | * | String | EMANDATE in case of UPI/NB/Wallet. MANDATE in case of card. |
should_create_mandate | Boolean | This is a customer’s consent flag. This should be always TRUE in case of a mandate transaction. |
Test Cards: (click to view)
Billdesk:
VISA
Card Number: 4591500000000055,
Expiry Month: 12,
Expiry Year: 2029,
Name on Card: Test,
CVV: 123
OTP is 123456
Note: For this card, Transaction status will be successful
and Mandate status will be active
MASTERCARD
Card Number: 5252521111111117,
Expiry Month: 12,
Expiry Year: 2029,
Name on Card: Test,
CVV: 123
OTP is 123456
Note: For this card, Transaction status will be successful
and Mandate status will be failure
Card Number: 4022757915248950,
Expiry Month: 01,
Expiry Year: 2022,
Name on Card: Test,
CVV: 123
Card Number: 5123456789012346,
Expiry Month: 01,
Expiry Year: 2024,
Name on Card: Test,
CVV: 123
OTP is 123456