Skip to main content

Initiate a Payment [v2]

This API helps you initiate a payment for the order that you have created. You need to call this API after your customer has chosen their payment mode and has provided all the information required to initiate the payment with that mode.

Request Body required
    oneOf

    payment_mode string required

    Possible values: [Credit Card, Debit Card, Prepaid Card]

    This is the payment mode chosen by the customer to pay for your order

    card_no string

    This is the card number typically between 15-19 digits, you should only pass this from your server if you are PCI-DSS certified

    cvv string

    This is a 3 or 4 digit number provided at the back of the card, you should only pass this from your server if you are PCI-DSS certified

    card_holder_name string

    Possible values: non-empty

    This is the name of the card holder, you should only pass this from your server if you are PCI-DSS certified

    expiry mm/yy

    This expiry date of the card, it should be of the current month or future. You should only pass this from your server if you are PCI-DSS certified

    card_details string

    If you don't have PCI-DSS, you can always encrypt the card details on your client and send us the encrypted string in this key.

    Steps for encryption

    1. Get the Nimbbl Public key for encryption. To get the Nimbbl public key reach out to us at help@nimbbl.biz.
    2. Format the Card details in the format : {"card_no":"4111111111111111","cvv":"123","card_holder_name":"test","expiry":"11/22"}
    3. Encrypt the above card details using the RSA encryption.
    order_id string required

    The order_id for which the payment is being made

    callback_url string

    This is the URL to which the status of the transaction and the control will be redirected. The URL should be https. The URL is mandatory for certain payment modes such as Cards, Net Banking, Wallets, Payment Apps.

Responses

When the payment initiation is successful, the response will be as below


Schema
    status_code integer required

    This is the http status code

    order_id string required

    This is the order passed in the request

    transaction_id string required

    This is the unique transaction id generated by Nimbbl for this payment

    status string required

    Possible values: [success]

    This is the status of the request

    message string required

    This a message explaining the status of the payment

    completion_time integer required

    The time in seconds it took for the transaction to be completed

    extra_info object required

    This object provides information regarding how to redirect the customer

    attempts integer

    The payment attempts that have been used against this order (duplicate key returned for some PSPs)

    data object required
    attempts integer

    The payment attempts that have been used against this order

    redirectUrl uri

    This is the url to which the customer should be redirected to complete the payment (duplicate key returned for some PSPs)

    redirect_url uri required

    This is the url to which the customer should be redirected to complete the payment

    payment_partner string

    This is the payment partner through which the payment will be processed

    action string

    This always comes as redirect_url

    info object required

    The info object provides information on the next api call

    url string

    Possible values: [/api/v2/transaction-enquiry]

    Mainly provides the enquiry url

    request_args object

    This contains the request params for the next api call

    order_id string

    This is the order passed in the request

    transaction_id string

    This is the unique transaction id generated by Nimbbl for this payment

    payment_mode string

    This is the payment mode chosen by the customer to pay for this order

Loading...