Documentation Index
Fetch the complete documentation index at: https://www.dynamic.xyz/docs/llms.txt
Use this file to discover all available pages before exploring further.
Overview
DynamicSvmWalletClient::sponsorTransaction is the lower-level primitive behind sponsored transactions. It takes the serialized message of an unsigned transaction and returns the sponsor-signed wire envelope — the sponsor’s signature is pre-filled in slot 0, the user signature slots are zeroed, and the original message is appended.
Most apps don’t need this directly — use sendTransaction(...).sponsor(true) for the one-shot sign + sponsor + broadcast flow. Reach for sponsorTransaction when you want to:
- Have the user sign the sponsor-prepped envelope on a separate path (client-side wallet, hardware wallet)
- Inspect or audit the sponsor signature before adding the user signature
- Batch sponsorship outside Dynamic’s broadcast path
Gas sponsorship must be enabled for your environment in the Dynamic dashboard before calls succeed.
Prerequisites
- Created an SVM wallet
- Gas sponsorship enabled in the Dashboard
Sponsor a Message
sponsoredWire layout:
Filling in the User Signature
If your wallet’s account index isidx (typically 1 for a single user signer after the sponsor), overwrite that 64-byte slot with the user’s Ed25519 signature, then push to RPC:
idx:
Pairing with the MPC Signer
The most common pattern: sponsor first (no MPC needed), then runsignTransaction over the same messageBytes to get the user’s Ed25519 signature, then splice it into the sponsored envelope:
sendTransaction with sponsor=true.
Next Steps
- Send transactions — sign + sponsor + broadcast in one call
- Sign transactions
- Sign messages
- Delegated access