Markdown

Timeout Void

Cap how long the gateway waits on a processor response and auto-void ghost approvals that arrive after the timeout.

The Timeout Void feature allows you to set a maximum duration for the gateway to wait for a processor's response on CCAUTHORIZE or CCAUTHCAP requests. If the gateway does not receive an end-state response within your specified window, it will return a decline to your system.

Automated Resolution

Because the transaction may still be in-flight with the processor when the gateway times out, Inovio protects you from "ghost" approvals. If the processor eventually approves the transaction after the timeout period, the gateway will automatically submit a void request to ensure the cardholder is not charged for an abandoned transaction.

Field Name Description Value Guideline
REQUEST_MAX_WAIT Enables or disables the timeout functionality. 1 (Enable) or 0 (Disable).
REQUEST_MAX_WAIT_TIMER The number of seconds to wait before abandoning the request. Required if enabled. Must be between 30 and 600 seconds.
Global Portal Setting

Merchants can also set a global Timeout Void preference at the account level within the Inovio Portal. Any parameters sent within an individual API request will override the global portal settings.

use Inovio\Gateway\{Credentials, InovioClient};
use Inovio\Gateway\Errors\GatewayTimeoutException;
use Inovio\Gateway\Model\{LineItem, Money, PaymentMethods};
use Inovio\Gateway\Refs\Refs;
use Inovio\Gateway\Request\TransactionRequest;

$client = new InovioClient(new Credentials('api_user', 'P@ssw0rd!', '12345'), 'SANDBOX');

$req = (new TransactionRequest(
    PaymentMethods::card('4111111111111111', '122026', '123'),
    [new LineItem('SKU-1', 1, Money::of('100.00', 'USD'))]
))->withIdempotency('ORDER-555');

try {
    $client->sale($req);
} catch (GatewayTimeoutException $e) {
    // The state is UNKNOWN, not failed — resolve it, don't retry blindly.
    $actual = $client->status(Refs::xtlOrder($e->xtlOrderId()));
    echo $actual->transactions === [] ? 'safe to retry' : 'already happened', "\n";
}