sendSponsoredTransaction bundles signing, relaying, and waiting into one call. When you need more control — pre-signing an intent to send later, relaying without blocking, or driving your own progress UI — split those steps with the functions below.
The full flow is: sign → relay (get a requestId) → poll status until the relay reports a transaction hash.
signSponsoredTransaction
Signs an EIP-712 intent for a batch of calls without sending it. Returns a serializable payload you can hand tosendSponsoredTransaction or relaySponsoredTransaction later.
Parameters
Returns
Promise<SignedSponsoredTransaction>:
Custom validity window
relaySponsoredTransaction
Relays an intent to the sponsorship backend and returns arequestId without waiting for on-chain inclusion. Accepts either unsigned calls (it signs them for you) or a pre-signed signedTransaction.
requestId — not a transaction hash — is the stable identifier for a sponsored transaction, because the relay may retry the on-chain submission. Use it to track status below.
Parameters
Same assignSponsoredTransaction (unsigned form), or { signedTransaction }.
Returns
Promise<{ requestId: string }>.
Tracking status
getEVMSponsoredTransactionStatus
Fetches the current relay state for arequestId. Use it as the building block for custom polling — for example, a progress indicator.
Promise<SponsoredTransactionStatusResult>:
The
status lifecycle:
waitForSponsoredTransaction
For the common “wait until done” case,waitForSponsoredTransaction polls getEVMSponsoredTransactionStatus every 2 seconds and resolves as soon as the relay reports a transaction hash. It throws a SponsorTransactionError on a terminal failure or after a 60-second timeout.
Promise<{ transactionHash: Hex }>.
Reusing a nonce
By default each signed intent gets a fresh single-use bitmap nonce. Passnonce (a bigint, matching the nonce on the signed result) to reuse one across intents — sign several intents with the same nonce so at most one can ever land on-chain (cancel-replace). The value is used as-is, with no on-chain validation:
nonce works the same way on relaySponsoredTransaction and sendSponsoredTransaction.
Related functions
- sendSponsoredTransaction — sign, relay, and wait in one call
- EVM Gas Sponsorship overview — setup and the common path
- Managing EIP-7702 delegation — control the one-time delegation step