Skip to main content

Flow Definitions

Input Variables

As a Salesforce administrator, it is crucial to understand the significance of the variables and constants included in the flow. These elements play a vital role in the successful execution of the flow's logic and contribute to the Smart Payment Routing overall functionality. Below, are the essential input variables that must be present in the flow you build for Smart Payment Routing:

API NameDefinition
billingCountryCaptures the billing country information.
billingStateCaptures the billing state information.
billingZipHolds the billing zip code information.
billingCityCaptures the billing city information.
amountThe payment amount associated with the transaction.
cardTypeCaptures the type of credit card used for the transaction.
cardExpMonthStores the expiration month of the credit card.
cardExpYearStores the expiration year of the credit card.
bankAccountTypeCaptures the type of bank account used.
bankNameHolds the name of the bank associated with the transaction.
orderGatewayIdCaptures the ID associated with the order, providing crucial contextual information for transaction processing.
orderIdCaptures the ID associated with the gateway, providing contextual information for transaction processing.

All these input variables are already present in the flow template provided by Chargent. Since you are being provided with the orderId, you are able to query any Chargent Order field and any related object field you might need for the logic you plan to implement in the Smart Payment Routing flow.

Note: Ensure you do not modify the existing input variables as they are referenced in the flow's Apex code.

Output Variable

API NameDefinition
routingGatewayThe gatewayId to be used in the operation.

Smart Payment Routing is a functionality that allows you built the logic to automatically choose the gateway for every Chargent transaction. In that sense, no other output variable can be created in the flow.


API NameDefinition
gateway1IdRepresents the ID of one of the payment gateways configured in the flow.
gateway2IdRepresents the ID of another payment gateway configured in the flow.

If you wish to implement a more sophisticated logic with additional gateways, you have the flexibility to create a new constant, such as 'gateway3Id', following the same format as the existing constants.

Including these variables and constants in your Autolaunched Flow is essential to ensure the flow's proper functionality. Configure the flow according to your needs and deliver a seamless payment processing experience to your customers.