Interface ContractProvider

interface ContractProvider {
    at<T>(address: string, contractAbstractionComposer?: ((abs: ContractAbstraction<ContractProvider, DefaultMethods<ContractProvider>, DefaultMethodsObject<ContractProvider>, DefaultViews, DefaultContractViews, unknown>, context: Context) => T)): Promise<T>;
    ballot(params: BallotParams): Promise<BallotOperation>;
    batch(params?: ParamsWithKind[]): OperationBatch;
    drainDelegate(params: DrainDelegateParams): Promise<DrainDelegateOperation>;
    failingNoop(params: FailingNoopParams): Promise<FailingNoopOperation>;
    finalizeUnstake(params: FinalizeUnstakeParams): Promise<TransactionOperation>;
    getBigMapKey<T>(contract: string, key: string, schema?: unknown): Promise<T>;
    getBigMapKeyByID<T>(id: string, keyToEncode: BigMapKeyType, schema: Schema, block?: number): Promise<T>;
    getBigMapKeysByID<T>(id: string, keysToEncode: BigMapKeyType[], schema: Schema, block?: number, batchSize?: number): Promise<MichelsonMap<MichelsonMapKey, undefined | T>>;
    getSaplingDiffByID(id: string, block?: number): Promise<SaplingDiffResponse>;
    getStorage<T>(contract: string, schema?: unknown): Promise<T>;
    increasePaidStorage(params: IncreasePaidStorageParams): Promise<IncreasePaidStorageOperation>;
    originate<TContract>(contract: OriginateParams<ContractStorageType<TContract>>): Promise<OriginationOperation<TContract>>;
    proposals(params: ProposalsParams): Promise<ProposalsOperation>;
    registerDelegate(params: RegisterDelegateParams): Promise<DelegateOperation>;
    registerGlobalConstant(params: RegisterGlobalConstantParams): Promise<RegisterGlobalConstantOperation>;
    reveal(params: RevealParams): Promise<RevealOperation>;
    setDelegate(params: DelegateParams): Promise<DelegateOperation>;
    smartRollupAddMessages(params: SmartRollupAddMessagesParams): Promise<SmartRollupAddMessagesOperation>;
    smartRollupExecuteOutboxMessage(params: SmartRollupExecuteOutboxMessageParams): Promise<SmartRollupExecuteOutboxMessageOperation>;
    smartRollupOriginate(params: SmartRollupOriginateParams): Promise<SmartRollupOriginateOperation>;
    stake(params: StakeParams): Promise<TransactionOperation>;
    transfer(params: TransferParams): Promise<TransactionOperation>;
    transferTicket(params: TransferTicketParams): Promise<TransferTicketOperation>;
    unstake(params: UnstakeParams): Promise<TransactionOperation>;
    updateConsensusKey(params: UpdateConsensusKeyParams): Promise<UpdateConsensusKeyOperation>;
}

Hierarchy (view full)

Methods

  • Parameters

    Returns Promise<FailingNoopOperation>

    An operation handle with the result from the rpc node

    Send arbitrary data inside a failing_noop operation that's guaranteed to fail.

  • Type Parameters

    • T

    Parameters

    • id: string

      Big Map ID

    • keysToEncode: BigMapKeyType[]

      Array of keys to query (will be encoded properly according to the schema)

    • schema: Schema

      Big Map schema (can be determined using your contract type)

    • Optionalblock: number

      optional block level to fetch the values from

    • OptionalbatchSize: number

      optional batch size representing the number of requests to execute in parallel

    Returns Promise<MichelsonMap<MichelsonMapKey, undefined | T>>

    An object containing the keys queried in the big map and their value in a well-formatted JSON object format

    Fetch multiple values in a big map