PHP WebShell

Текущая директория: /opt/BitGoJS/modules/utxo-staking/dist/src/babylon

Просмотр файла: delegationMessage.d.ts

import * as vendor from '@bitgo/babylonlabs-io-btc-staking-ts';
import * as babylonProtobuf from '@babylonlabs-io/babylon-proto-ts';
import * as bitcoinjslib from 'bitcoinjs-lib';
import * as utxolib from '@bitgo/utxo-lib';
import { Descriptor } from '@bitgo/wasm-miniscript';
import { BabylonDescriptorBuilder } from './descriptor';
import { BabylonNetworkLike } from './network';
export type ValueWithTypeUrl<T> = {
    typeUrl: string;
    value: T;
};
export declare function getSignedPsbt(psbt: bitcoinjslib.Psbt, descriptor: Descriptor, signers: utxolib.ECPairInterface[], { finalize }: {
    finalize?: boolean | undefined;
}): bitcoinjslib.Psbt;
/**
 * Utility method to work around a bug in btc-staking-ts
 * https://github.com/babylonlabs-io/btc-staking-ts/issues/71
 * @param v
 * @param network
 */
export declare function forceFinalizePsbt(v: Buffer | utxolib.Psbt | bitcoinjslib.Psbt, network: BabylonNetworkLike): bitcoinjslib.Psbt;
export declare function getBtcProviderForECKey(descriptorBuilder: BabylonDescriptorBuilder, stakerKey: utxolib.ECPairInterface): vendor.BtcProvider;
type Result = {
    unsignedDelegationMsg: ValueWithTypeUrl<babylonProtobuf.btcstakingtx.MsgCreateBTCDelegation>;
    stakingTx: bitcoinjslib.Transaction;
};
/**
 * @param stakingKey - this is the single-sig key that is used for co-signing the staking output
 * @param changeAddress - this is unrelated to the staking key and is used for the change output
 */
export declare function toStakerInfo(stakingKey: utxolib.ECPairInterface | Buffer | string, changeAddress: string): vendor.StakerInfo;
export declare function createStaking(network: BabylonNetworkLike, blockHeight: number, stakerBtcInfo: vendor.StakerInfo, stakingInput: vendor.StakingInputs, versionedParams?: vendor.VersionedStakingParams[]): vendor.Staking;
type TransactionLike = bitcoinjslib.Psbt | bitcoinjslib.Transaction | utxolib.Transaction | utxolib.bitgo.UtxoTransaction<bigint | number> | utxolib.Psbt | utxolib.bitgo.UtxoPsbt;
export declare function toStakingTransaction(tx: TransactionLike): bitcoinjslib.Transaction;
export declare function createDelegationMessageWithTransaction(manager: vendor.BabylonBtcStakingManager, staking: vendor.Staking, stakingAmountSat: number, transaction: TransactionLike, babylonAddress: string): Promise<ValueWithTypeUrl<babylonProtobuf.btcstakingtx.MsgCreateBTCDelegation>>;
export declare function createUnsignedPreStakeRegistrationBabylonTransactionWithBtcProvider(btcProvider: vendor.BtcProvider, network: bitcoinjslib.Network, stakerBtcInfo: vendor.StakerInfo, stakingInput: vendor.StakingInputs, babylonBtcTipHeight: number, inputUTXOs: vendor.UTXO[], feeRateSatB: number, babylonAddress: string, stakingParams?: vendor.VersionedStakingParams[]): Promise<Result>;
export {};
//# sourceMappingURL=delegationMessage.d.ts.map

Выполнить команду


Для локальной разработки. Не используйте в интернете!