Credit Card

Payment by credit or debit card with VISA, MasterCard, JCB, or Amex logo. We support both local and international banks.

Steps to integrate :

  1. Send the charge API request to Midtrans.
  2. Redirect your customer back to your page by configuring Finish URL in Midtrans's Dashboard > Snap Preferences or via [API Request] (/docs/snap-advanced-feature#custom-finish-url).
  3. Handle notifications.

Note: Please also refer to the Two Clicks, One Click, and Pre-Authorization section

Sample JSON Request Body

  "transaction_details": {
    "order_id": "ORDER-101",
    "gross_amount": 10000
  "item_details": [{
    "id": "ITEM1",
    "price": 10000,
    "quantity": 1,
    "name": "Midtrans Bear",
    "brand": "Midtrans",
    "category": "Toys",
    "merchant_name": "Midtrans"
  "customer_details": {
    "first_name": "TEST",
    "last_name": "MIDTRANSER",
    "email": "[email protected]",
    "phone": "+628123456"
  "enabled_payments": ["credit_card"],
  "credit_card": {
    "save_card": true,
    "secure": true,
    "channel": "migs",
    "bank": "maybank",
    "installment": {
      "required": false,
      "terms": {
        "bni": [3, 6, 12],
        "mandiri": [3, 6, 12],
        "cimb": [3],
        "bca": [3, 6, 12],
        "offline": [6, 12]
    "whitelist_bins": [
    "dynamic_descriptor": {
      "merchant_name" : "Fuji Apple Inc",
      "city_name": "Jakarta",
      "country_code": "ID"
Transaction Details Object (required)
Unique transaction ID
Item Details Object (optional)
Shopping item details will be paid by customer
Customer Details Object (optional)
Details of the customer
Array (optional)
Set what payment method to show in Snap's payment list. Value: credit_card
CreditCard (optional)
Credit card payment options

Note: For a full list of request body parameters please refer to the Request Body (JSON Parameter) section.


Card number autofill pop-up on Google Chrome iOS

When customer access card payment flow via Google Chrome on iOS device, a pop-up will appear, informing that iOS is not allowing card number autofill to protect user’s privacy.
Nevertheless, this is a form of risk prevention mechanism coming from the iOS device itself. To continue with the payment, customer can tap on the “OK” button and complete the remaining payment steps as usual. Payment security will still be guaranteed by Midtrans as per usual.