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

Implements

Constructors

Methods

  • Parameters

    • data: PackDataParams

      Data to pack

    • options: RPCOptions = defaultRPCOptions

      contains generic configuration for rpc calls to specified block (default to head)

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

    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.

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

    https://gitlab.com/tezos/tezos/-/blob/master/docs/api/paris-openapi-rc.json