Hey! These docs are for version 3.2, which is no longer officially supported. Click here for the latest version, 1.0!

Mandate Registration API

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)
Note:
This is the same as the Payment Status Object returned for Payments API requests (with three extra parameters: "txn_uuid, payment.sdk_params":{...}, and offer_details:{....}.
In the redirect response, webhook, and check status API, mandate data will be passed additionally from the current parameters.
ParameterTypeDescription
order_idStringUnique Identifier for the order.
txn_idStringTransaction ID for the payment attempt.
txn_uuidStringTransaction UUID
statusStringStatus of the transaction. See Appendix below for status mapping. PENDING_VBV indicates that the transaction requires authentication to complete.
payment:wwiw
    {{...},{...}}
ObjectContains authentication object:
{method, url, params}
(also sdk_params object for UPI Intent)
 Parameters for the payment object:
     {click to open)
authentication:
    {method, url, params}
ObjectAuthentication parametersww
  Parameters for the authentication object:
      (click to open)
ParameterTypeDescription
methodStringHTTP Method for authentication. Can be one of GET or POST. (For redirection instructions, see the "Handling the Redirection Method" section.)
urlStringURL to which the user has to be taken to for completing the authentication
paramsStringPresent 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: {{...},...}ObjectSDK parameterswwwwww
(Used only for UPI Intent)
  Parameters the sdk_params object:
      (click to open)
schemeStringShould be "mandate"
uri_params:
    {param1, param2,...}
ObjectURI parameterswwwwtwww
  Parameters for the uri_params object:
      (click to open)
ParameterTypeExample
validitystartString"eulcEPzPd244hfrGShFpH"
validityendString"24082037"
trString"PAYTMSUBS202206203480824046791145"
tnString"Amount%20to%20be%20paid%20now%20is%20Rs%201.00"
tidString"PYTM20220620937257791803424"
recurString"ASPRESENTED"
purposeString"14"
pnString"test"
paString"[email protected]"
orgidString"00000"
modeString"00"
mnString"Subscription%20for%20testaccount"
mcString"5811"
cuString"INR"
amruleString"MAX"
amString"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).
   APPENDIX   - Transaction status codes and meaning:
StatusIDMeaning
NEW10Newly created order
PENDING_VBV23Authentication is in progress
CHARGED21Successful transaction
AUTHENTICATION_FAILED26User did not complete authentication
AUTHORIZATION_FAILED27User completed authentication, but bank refused the transaction
JUSPAY_DECLINED22User input is not accepted by the underlying PG
AUTHORIZING28Transaction status is pending from bank
Payment Gateways and Supported Payment Methods:   (click to view)
PG - PMTCardNetbankingWalletUPI IntentUPI CollectAadhar
AXIS_BIZNoNoNoYesYesNo
BILLDESKYesNoNoNoYesNo
CAMSPAYNoNoNoNoYesNo
PAYUYesYesNoNoYesNo
PAYTM_V2YesNoYesYesYesNo
PHONEPENoNoNoYesNoNo
RAZORPAYYesYesNoNoYesYes
TPSLNoYesNoNoNoYes
YES_BIZNoNoNoYesYesNo
The request for the Mandate Registration API consists of the following Parameter Groups:         (click to open tables):
  Payment Method Parameters:
    Note:
test
These are the same Payment Method Parameters used in the Payments API requests.
FieldTypeDescription
order_id*StringUnique Identifier for the order.
merchant_id*StringID of the merchant_account that you hold with us.
payment_method_type*StringPayment 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*StringPayment 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*BooleanWe 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*StringIf 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.
* = Required
  Bank Details Parameters:
FieldTypeDescription
bank_nameStringName of bank that is holding the account
bank_account_number*StringBank account number. Required for emandate/e-NACH, or when mandate_type= EMANDATE.
bank_beneficiary_nameStringAccount holder name. Should contain alphabetical characters only. Required for emandate/e-NACH, or when mandate_type= EMANDATE.
bank_ifscStringBank IFSC. Required for emandate/e-NACH, or when mandate_type= EMANDATE.
  Card Data Parameters:
    Note:
test
These are the same Card Data Parameters used in the Payments API requests.
FieldTypeDescription
card_token*stringA 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_numberStringA valid credit/debit card number. Required when mandate_type= MANDATE for a new card transaction.
card_exp_yearStringRepresent the expiry year of the card as YY (two digits only). Required when mandate_type= MANDATE for a new card transaction.
card_exp_monthStringRepresent the expiry month of the card as MM (two digits only). Required when mandate_type= MANDATE for a new card transaction.
card_security_codeStringCVV of the card. Usually three digits. Required when mandate_type= MANDATE for a new card transaction.
name_on_cardStringCard holder name. Should contain alphabetical characters only. Required when mandate_type= MANDATE for a new card transaction.
save_to_lockerStringThis 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.
Other Parameters sent by API, but not included in a Parameter Group:
FieldTypeDescription
upi_vpaStringVPA to which the collect request must
be sent.
mandate_type*StringEMANDATE in case of UPI/NB/Wallet.
MANDATE in case of card.
should_create_mandateBooleanThis is a customer’s consent flag. This
should be always TRUE in case of a
mandate transaction.
  * = Required
  Test Cards:     (click to view)
  Please use the below test cards for testing mandates

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


RAZORPAY

Card Number: 4022757915248950,
Expiry Month: 01,
Expiry Year: 2022,
Name on Card: Test,
CVV: 123


PAYU

Card Number: 5123456789012346,
Expiry Month: 01,
Expiry Year: 2024,
Name on Card: Test,
CVV: 123

OTP is 123456


Language
Authentication
Basic
base64
:
Click Try It! to start a request and see the response here!