The Payment method filtering for orders feature allows merchants to define which payment methods are eligible for a specific order. This enables fine-grained control over the payment options presented to customers during checkout. This feature is configured when creating an order by using the order_meta.payment_methods_filters object in the Create Order API.

Use cases for Payment method filtering

This feature is widely used for “Cards” Payment Method. Within “Cards”, the feature is supported across all of the below card-types, i.e.
  • Credit Cards
  • Debit Cards
  • Prepaid Cards
  • Credit Card EMI (CC EMI)
  • Debit Card EMI (DC EMI)
If order_meta.payment_methods_filters is not defined, enabled payment methods will be made available to the user by default.

Defining Payment method filtering for orders

To define this feature, include the payment_methods_filters object while creating an order. Refer to the below defined sample payment_methods_filters object which exhaustively covers all possible filters possible. As per merchant’s need, they can define required filters at an order level.
JSON
{
  "payment_methods_filters": {
    "methods": {
      "action": "ALLOW",
      "values": [
        "credit_card",
        "debit_card",
        "prepaid_card",
        "credit_card_emi",
        "debit_card_emi"
      ]
    },
    "filters": {
      "card_schemes": {
        "action": "ALLOW",
        "values": [
          "VISA"
        ]
      },
      "card_suffix": {
        "action": "ALLOW",
        "values": [
          "1936"
        ]
      },
      "card_issuing_bank": {
        "action": "ALLOW",
        "values": [
          "AXIS"
        ]
      },
      "card_bins": {
        "action": "ALLOW",
        "values": [
          "451457"
        ]
      },
      "card_emi_schemes": {
        "action": "ALLOW",
        "values": [
          "VISA",
          "MASTERCARD"
        ]
      },
      "card_emi_suffix": {
        "action": "ALLOW",
        "values": [
          "1936"
        ]
      },
      "card_emi_issuing_bank": {
        "action": "ALLOW",
        "values": [
          "AXIS"
        ]
      },
      "card_emi_tenure": {
        "action": "ALLOW",
        "values": [
          3
        ]
      },
      "card_emi_bins": {
        "action": "ALLOW",
        "values": [
          "451457"
        ]
      }
    }
  }
}

Additional instructions to be followed by merchants when using the feature

  • The action field must be “ALLOW” (in uppercase).
  • Values under card_schemes must be uppercase (e.g., “VISA”, “RUPAY”).
  • For card_issuing_bank, use exact values provided by Cashfree.
  • card_bins and card_emi_bins should contain valid BINs. Only cards with these BINs will be eligible.
  • card_suffix must be the last 4 digits of the card number.
  • To allow only one specific card, use both card_bins and card_suffix mandatorily.
  • EMI filters (e.g., card_emi_schemes, card_emi_issuing_bank) must be used only if you include credit_card_emi or debit_card_emi in methods.values.
  • Filters can be declared in any order.
  • Valid values for card_emi_tenure range from 3 to 36 months.
  • Supported values for card_schemes:
    • RUPAY
    • VISA
    • DINERS
    • MASTERCARD
    • AMEX
  • List of all values that we support in card_issuing_bank are provided in the following document. Merchants can refer to the above documentation and directly use these values to define card_issuing_bank object.

Example Use Cases

Use CaseConfiguration
Allow only credit and debit cardsSet "methods.values" to ["credit_card", "debit_card"]
Allow only cards from Axis BankUse the card_issuing_bank filter with value "AXIS"
Allow only specific card BINsUse the card_bins filter with values like "451457"
Allow only a single cardUse both card_bins and card_suffix filters
Allow only VISA credit card EMI for 3 monthsUse "methods.values" with "credit_card_emi", set card_emi_schemes to "VISA", and card_emi_tenure to 3

Troubleshooting

  • Ensure all string values are in the correct case (e.g., “ALLOW”, “VISA”).
  • Do not define EMI filters unless EMI methods are included.
  • Avoid including filters that don’t match any available payment methods—this will result in no options being shown to the customer.

Contact Support

For additional help or to get the latest list of supported filters, contact your Cashfree account manager or submit a support ticket.