Optionaloptions: Partial<SRC20BuilderOptions>ReadonlydustReadonlyenableReadonlyenableReadonlyfeeReadonlymaxReadonlynetworkAdd change output if needed
Add inputs to transaction (with validation)
Add outputs to transaction (with validation)
Build a DEPLOY transaction for creating a new SRC-20 token
Build complete transaction from UTXOs
Optionaloptions: Partial<BuildOptions>Build a MINT transaction for minting SRC-20 tokens
Build a token deploy transaction
Build a token mint transaction
Build a token transfer transaction
Build a TRANSFER transaction for sending SRC-20 tokens
Calculate fee based on size and fee rate Simply: size * feeRate
Calculate optimal change for stamp transactions
Calculate fee for stamp transaction using SRC-20 calculator
Create a new transaction
Estimate optimal fee for different input/output combinations
Estimate transaction size in bytes Basic formula: ~180 bytes per input + ~34 bytes per output + ~10 bytes overhead
OptionalhasWitness: booleanEstimate transaction size with different input/output types
Estimate total cost of stamp transaction including stamp value
ProtectedestimateEstimate transaction size for fee calculation
Finalize and extract transaction (with validation)
Get dynamic dust thresholds for different output types
OptionalfeeRate: numberGet network type string from bitcoin.Network Return 'mainnet', 'testnet', or 'regtest' based on network
Optionalnetwork: NetworkGet SRC-20 dust value - instance method
Get SRC-20 minimum value (500,000 satoshis)
Get stamp fee rates for different transaction types
Check if change amount is above dust threshold
ProtectedselectSign transaction
Validate amount string
Validate tick symbol - SRC-20 protocol enforces 5 character maximum
StaticgetGet SRC-20 dust value - static method
High-level builder for creating SRC-20 token transactions
Remarks
SRC20TokenBuilder simplifies the creation of SRC-20 token transactions by handling:
Features:
Example