Taquito TypeDocs
    Preparing search index...

    Class RpcClientCache

    RpcClientCache acts as a decorator over the RpcClient instance by caching responses for the period defined by the ttl.

    Implements

    Index

    Constructors

    Methods

    • Parameters

      • address: string

        address from which we want to retrieve balance and frozen bonds

      • options: RPCOptions = defaultRPCOptions

        contains generic configuration for rpc calls to specified block (default to head) The sum (in mutez) of the spendable balance and frozen bonds of a contract. Corresponds to the contract's full balance from which staked funds and unstake requests have been excluded. Identical to the 'spendable_and_frozen_bonds' RPC.

      Returns Promise<BigNumber>

    • Parameters

      • address: string

        address from which we want to retrieve the balance

      • options: RPCOptions = defaultRPCOptions

        contains generic configuration for rpc calls to specified block (default to head) The spendable balance of a contract (in mutez), also known as liquid balance. Corresponds to tez owned by the contract that are neither staked, nor in unstaked requests, nor in frozen bonds. Identical to the 'balance' RPC.

      Returns Promise<BigNumber>

    • Parameters

      • address: string

        address from which we want to retrieve spendable and frozen bonds

      • options: RPCOptions = defaultRPCOptions

        contains generic configuration for rpc calls to specified block (default to head) The sum (in mutez) of the spendable balance and frozen bonds of a contract. Corresponds to the contract's full balance from which staked funds and unstake requests have been excluded. Identical to the 'balance_and_frozen_bonds' RPC.

      Returns Promise<BigNumber>

    • Parameters

      • data: PackDataParams

        Data to pack

      • options: RPCOptions = defaultRPCOptions

        contains generic configuration for rpc calls to specified block (default to head) Computes the serialized version of a data expression using the same algorithm as script instruction PACK Note: You should always verify the packed bytes before signing or requesting that they be signed when using the RPC to pack. This precaution helps protect you and your applications users from RPC nodes that have been compromised. A node that is operated by a bad actor, or compromised by a bad actor could return a fully formed operation that does not correspond to the input provided to the RPC endpoint. A safer solution to pack and sign data would be to use the packDataBytes function available in the @taquito/michel-codec package.

      Returns Promise<{ gas: BigNumber | "unaccounted" | undefined; packed: string }>

      packData({ data: { string: "test" }, type: { prim: "string" } })