sensible-sdk
Version:
Sensible-SDK
35 lines (34 loc) • 828 B
TypeScript
import { DustCalculator } from "./DustCalculator";
declare enum OutputType {
P2PKH = 0,
OP_RETURN = 1,
OTHER = 2
}
declare type Output = {
size: number;
type: OutputType;
};
declare enum InputType {
P2PKH = 0,
OTHER = 1
}
declare type Input = {
size: number;
type: InputType;
satothis?: number;
};
export declare class SizeTransaction {
feeRate: number;
dustCalculator: DustCalculator;
inputs: Input[];
outputs: Output[];
constructor(feeRate: number, dustCalculator: DustCalculator);
addInput(unlockingScriptSize: number, satothis: number): void;
addP2PKHInput(): void;
addOutput(lockingScriptSize: number): void;
addOpReturnOutput(lockingScriptSize: number): void;
addP2PKHOutput(): void;
getSize(): number;
getFee(): number;
}
export {};