Skip to main content

Revert Reasons

UniswapX reactors revert with typed Solidity errors, which can be difficult to decode from a raw transaction receipt. Before submitting a fill transaction, fillers should use the OrderQuoter contract (or the UniswapX SDK wrapper) to simulate the fill and decode the revert reason — this avoids wasted gas and helps attribute failures to the right party.

Order Validation States

The OrderValidation enum in the SDK captures every meaningful validation outcome. The table below describes each state and who is responsible for resolving it.

StateMeaningWho's Responsible
OKOrder is valid and fillable.
ExpiredOrder deadline has passed.Filler (timing)
NonceUsedOrder nonce already consumed — order was filled or cancelled.Protocol / Filler
InsufficientFundsSwapper wallet lacks sufficient token balance or approval.Swapper (surface to user)
InvalidSignatureOrder signature is invalid or doesn't match the swapper.Protocol
InvalidOrderFieldsOne or more order fields are malformed (bad decay times, amounts, reactor address, etc.).Protocol / Filler
ValidationFailedExternal validation contract rejected the order (often exclusivity).Filler
ExclusivityPeriodOrder is in its exclusivity window and the caller is not the exclusive filler.Filler (timing / routing)
OrderNotFillableYetOrder's start time hasn't been reached (Priority orders).Filler (timing)
InvalidGasPriceGas price doesn't meet the order's requirements (Priority orders).Filler
InvalidCosignatureCosigner signature is missing or invalid (Cosigned orders).Protocol / Filler
UnknownErrorUnrecognized revert — check raw revert data.

Error Selector Reference

The table below maps 4-byte error selectors to their corresponding OrderValidation state. Use this as a lookup when decoding raw revert data from the reactor.

SelectorStateSource
8baa579fInvalidSignature
815e1d64InvalidSignature
756688feNonceUsed
302e5b7cInvalidOrderFieldsInvalid dutch decay time
773a6187InvalidOrderFieldsInvalid dutch decay time
4ddf4a64InvalidOrderFieldsInvalid reactor address
d303758bInvalidOrderFieldsBoth input and output decay
7c1f8113InvalidOrderFieldsIncorrect amounts
43133453InvalidOrderFieldsInvalid dutch decay time
48fee69cInvalidOrderFields
70f65caaExpired
ee3b3d4bNonceUsed
0a0b0d79ValidationFailed / ExclusivityPeriodExclusive filler check — maps to ExclusivityPeriod when additionalValidationData encodes an exclusive filler
b9ec1e96ExclusivityPeriod
062dec56ExclusivityPeriod
75c1bb14ExclusivityPeriod
a305df82InvalidOrderFieldsInvalid cosigner output
ac9143e7InvalidOrderFieldsInvalid cosigner input
fff08303InvalidOrderFieldsDuplicate fee output
d7815be1InvalidCosignatureInvalidCosignature()
TRANSFER_FROM_FAILEDInsufficientFundsERC-20 transfer failure
d856fc5aInvalidOrderFieldsInvalid fee escalation amounts
cd21db4fExpiredSignature expired
769d11e4ExpiredPriorityOrderReactor: InvalidDeadline()
c6035520OrderNotFillableYetPriorityOrderReactor: OrderNotFillable()
a6b844f5InvalidOrderFieldsPriorityOrderReactor: InputOutputScaling()
f3eb44e5InvalidGasPricePriorityOrderReactor: InvalidGasPrice()

Using the SDK to Pre-flight Orders

The UniswapX SDK's OrderQuoter class wraps the on-chain quoter contract and decodes the revert reason into the OrderValidation enum. Call it before sending your fill transaction to avoid wasted gas:

import { OrderQuoter, OrderValidation } from '@uniswap/uniswapx-sdk';

const quoter = new OrderQuoter(provider, chainId);
const { validation } = await quoter.validate({ order, signature });

if (validation !== OrderValidation.OK) {
console.error('Order invalid:', OrderValidation[validation]);
}

Running this simulation before submission lets you skip unwinnable fills, surface InsufficientFunds errors to your UI, and distinguish timing issues (e.g. ExclusivityPeriod) from permanent failures (e.g. InvalidSignature).


For broader context on building a fill bot — including order polling, execution flow, and webhook registration — see the Filler Integration Guide.