v12

latestOpenAPI 3.1.0AGPL-3.0raw.githubusercontent.com2026-08-0464108237.1 KB
Routing Rules

Hybrid routing evaluation

Evaluate hybrid routing using the active routing rule plus runtime payment context.

post/routing/hybrid

Request body

Example request

{
  "static_routing_request": {
    "created_by": "merchant_demo",
    "payment_id": "rule_decision_001",
    "fallback_output": [
      {
        "gateway_name": "stripe",
        "gateway_id": "mca_111"
      }
    ],
    "parameters": {
      "payment_method_type": {
        "type": "enum_variant",
        "value": "credit"
      },
      "amount": {
        "type": "number",
        "value": 1000
      }
    }
  },
  "dynamic_routing_request": {
    "merchantId": "test_merchant",
    "paymentInfo": {
      "paymentId": "pay_001",
      "amount": 1000,
      "currency": "USD",
      "paymentType": "ORDER_PAYMENT",
      "paymentMethodType": "CARD",
      "paymentMethod": "CREDIT",
      "country": "US",
      "customerId": "cust_123",
      "authType": "THREE_DS",
      "cardIsin": "411111",
      "cardType": "CREDIT"
    },
    "eligibleGatewayList": [
      "stripe",
      "paypal",
      "adyen"
    ],
    "rankingAlgorithm": "SR_BASED_ROUTING"
  }
}

Response

OK

dynamic_routingobject nullable

Decision-gateway result, wrapped as {status, decision, fallback_connectors}.

Example response

{
  "static_routing": {
    "status": "success",
    "evaluated_output": [
      {
        "gateway_name": "stripe",
        "gateway_id": "mca_111"
      }
    ],
    "eligible_connectors": [
      {
        "gateway_name": "stripe",
        "gateway_id": "mca_111"
      }
    ]
  },
  "evaluated_connectors": [
    {
      "gateway_name": "stripe",
      "gateway_id": "mca_111"
    }
  ]
}