Available Methods
The paymaster client provides several methods for working with transactions:| Method | Classic | Kit | Description |
|---|---|---|---|
| Create legacy tx | createLegacyTransaction() | N/A | Legacy transaction (no lookup tables) |
| Create versioned tx | createTransaction() | createTransaction() | Versioned v0 transaction |
| Sign only | sign() | sign() | Sign without sending |
| Sign + validate | N/A | fullySign() | Sign and assert fully signed |
| Sign + send | signAndSend() | signAndSend() | Sign and submit to network |
Creating Transactions
Legacy Transactions (Classic Only)
Legacy transactions are simpler but don’t support address lookup tables:Versioned Transactions
Versioned transactions (v0) support address lookup tables for more efficient transactions:- Classic (web3.js 1.x)
- Kit (web3.js 2.0)
Signing Transactions
Sign and Send (Recommended)
The simplest approach - sign and submit in one call:- Classic (web3.js 1.x)
- Kit (web3.js 2.0)
Sign Only (For Inspection)
Sign without sending - useful for inspecting the transaction before submission:- Classic (web3.js 1.x)
- Kit (web3.js 2.0)
Full Signature Validation (Kit Only)
The Kit SDK providesfullySign() which validates that all required signatures are present:
Complete Examples
SOL Transfer with Memo
- Classic (web3.js 1.x)
- Kit (web3.js 2.0)
Multiple Signers
When a transaction requires multiple user signatures:- Classic (web3.js 1.x)
- Kit (web3.js 2.0)
Best Practices
Test on Devnet First
Always test your integration on devnet before deploying to mainnet. Create a separate devnet paymaster for testing.
Handle Errors Gracefully
Wrap paymaster calls in try-catch and handle errors appropriately. See Advanced Usage for error handling patterns.
Monitor Your Balance
Keep your paymaster funded. Set up alerts in the Developer Portal to avoid running out of SOL.
Use Retry Options
Configure retry options for production to handle transient network issues automatically.
Next Steps
- Advanced Usage - Error handling, retries, versioned transactions
- Manage Paymasters - Monitor and manage your paymaster
- Transaction History - View sponsored transactions

