UNPKG

@taquito/taquito

Version:

High level functionality that builds upon the other packages in the Tezos Typescript Library Suite.

33 lines (32 loc) 1.78 kB
import { DelegateParams, IncreasePaidStorageParams, OriginateParams, TransferParams } from '../operations/types'; export declare type WalletDefinedFields = 'source'; export declare type WalletTransferParams = Omit<TransferParams, WalletDefinedFields>; export declare type WalletOriginateParams<TStorage = any> = Omit<OriginateParams<TStorage>, WalletDefinedFields>; export declare type WalletDelegateParams = Omit<DelegateParams, WalletDefinedFields>; export declare type WalletIncreasePaidStorageParams = Omit<IncreasePaidStorageParams, WalletDefinedFields>; export interface WalletProvider { /** * @description Request the public key hash from the wallet */ getPKH: () => Promise<string>; /** * @description Transform WalletTransferParams into a format compliant with the underlying wallet */ mapTransferParamsToWalletParams: (params: () => Promise<WalletTransferParams>) => Promise<any>; /** * @description Transform WalletOriginateParams into a format compliant with the underlying wallet */ mapOriginateParamsToWalletParams: (params: () => Promise<WalletOriginateParams>) => Promise<any>; /** * @description Transform WalletDelegateParams into a format compliant with the underlying wallet */ mapDelegateParamsToWalletParams: (params: () => Promise<WalletDelegateParams>) => Promise<any>; /** * @description Transform WalletIncreasePaidStorageParams into a format compliant with the underlying wallet */ mapIncreasePaidStorageWalletParams: (params: () => Promise<WalletIncreasePaidStorageParams>) => Promise<any>; /** * @description Request the wallet to send an operation batch */ sendOperations: (params: any[]) => Promise<string>; }