REST API Support
Smart Payment Routing is compatible with the following REST API requests:
- Create Payment Method
- Create Payment Method Headless
- Create Payment Method Multiple Gateway Tokenization
- Create Payment Method Multiple Gateway Tokenization Headless
- Create Authorization
- Create Sale
- Create Sale Headless
Prerequisites
- Smart Payment Routing feature must be enabled and configured using the Payment Routing Wizard.
- Include
Chargent-PaymentRouting=true
in the HTTP request header.
HTTP Header
HTTP Header | Value |
---|---|
Chargent-PaymentRouting | true |
When the Chargent-PaymentRouting
header is not present or it has false
as it's value, Smart Payment Routing logic will be ignored. Only when the header is present with true
as it's value and the Smart Payment Routing feature is active and configured will the flow be invoked and dynamic routing logic applied.
Note: When Smart Payment Routing is activated and the Chargent-PaymentRouting
header is included with the request, Create Payment Method Multiple Gateway Tokenization will be overridden and behave as Create Payment Method. In this scenario, with more than one gateway in the request body, the payment method that is being created will only be tokenized with the gateway that Smart Payment Routing logic determines.