The base interface shared by all transaction operation parameters.
ITweakedTransactionData
Overview
The full source code is available on GitHub at ITransactionParameters.ts.
Import
import { ITweakedTransactionData } from '@btc-vision/transaction';Types
SupportedTransactionVersion = 1 | 2 | 3;Interface
Signature
interface ITweakedTransactionData {
readonly mldsaSigner: QuantumBIP32Interface | null;
readonly signer: Signer | UniversalSigner;
readonly network: Network;
readonly chainId?: ChainId;
readonly nonWitnessUtxo?: Uint8Array;
readonly noSignatures?: boolean;
readonly unlockScript?: Uint8Array[];
readonly txVersion?: SupportedTransactionVersion;
readonly addressRotation?: AddressRotationConfigBase;
readonly parallelSigning?: SigningPoolLike | WorkerPoolConfig;
readonly useP2MR?: boolean;
readonly subtractExtraUTXOFromAmountRequired?: boolean;
}Description
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| mldsaSigner | QuantumBIP32Interface | null | Yes | ML-DSA quantum signer, or null if none. |
| signer | Signer | UniversalSigner | Yes | The signing key for the transaction. |
| network | Network | Yes | Bitcoin network (networks.bitcoin, networks.testnet, etc.) |
| chainId | ChainId | No | The chain id. |
| nonWitnessUtxo | Uint8Array | No | |
| noSignatures | boolean | Yes | |
| unlockScript | Uint8Array[] | No | |
| txVersion | SupportedTransactionVersion | No | |
| addressRotation | AddressRotationConfigBase | No | Address rotation configuration for per-UTXO signing. When enabled, each UTXO can be signed by a different signer. |
| parallelSigning | SigningPoolLike | WorkerPoolConfig | No | Parallel signing configuration using worker threads. Pass a WorkerSigningPool instance (recommended for reuse) or a WorkerPoolConfig. When provided, key-path taproot inputs are signed in parallel. Falls back to sequential for address rotation, browser, or non-taproot inputs. |
| useP2MR | boolean | No | When true, use P2MR (Pay-to-Merkle-Root, BIP 360) instead of P2TR for outputs. P2MR commits directly to a Merkle root without a key-path spend, eliminating the quantum-vulnerable internal pubkey. Output: OP_2 <32-byte merkle_root>. |
| subtractExtraUTXOFromAmountRequired | boolean | No | When true, the total value of optionalInputs is subtracted from the funding amount the factory needs to produce. This prevents the funding transaction from over-provisioning when extra inputs already cover part of the interaction cost (e.g. a token UTXO that passes through as-is). |