Interface: PackInstructionsOptions
Options for packInstructions.
Properties
| Property | Type | Description |
|---|---|---|
computeUnits? | (instruction) => number | Optional per-instruction compute-unit estimator. When provided, a bucket is also split whenever its cumulative estimated compute units would exceed PackInstructionsOptions.maxComputeUnits. When omitted, compute units are not considered and only transaction size bounds the packing. |
feePayer? | Address | The fee payer address for the resulting transactions. Provided so that size measurement accounts for account deduplication accurately (the fee payer is shared across every instruction). Defaults to a placeholder address, which is slightly conservative. |
maxComputeUnits? | number | Maximum compute units per transaction. Only enforced when PackInstructionsOptions.computeUnits is provided. Defaults to MAX_COMPUTE_UNITS (1,400,000). |
maxTransactionSize? | number | Maximum serialized transaction size in bytes. Defaults to TRANSACTION_SIZE_LIMIT (1232). |
reservedInstructions? | Instruction<string, readonly (AccountLookupMeta<string, string> | AccountMeta<string>)[]>[] | Instructions that will be prepended to every transaction at send time (for example compute-budget or priority-fee instructions). They are charged against the size budget of each bucket but are NOT included in the returned buckets — the transaction builder adds the real ones when sending. |