Class TablesService

Hierarchy

  • TablesService

Constructors

Properties

Methods

Constructors

Properties

httpRequest: BaseHttpRequest

Methods

  • Get raw table item Get a table item at a specific ledger version from the table identified by {table_handle} in the path and the "key" (RawTableItemRequest) provided in the request body.

    The get_raw_table_item requires only a serialized key comparing to the full move type information comparing to the get_table_item api, and can only return the query in the bcs format.

    The Aptos nodes prune account state history, via a configurable time window. If the requested ledger version has been pruned, the server responds with a 410.

    Returns

    MoveValue

    Throws

    ApiError

    Parameters

    • tableHandle: string

      Table handle hex encoded 32-byte string

    • requestBody: RawTableItemRequest
    • Optional ledgerVersion: string

      Ledger version to get state of account

      If not provided, it will be the latest version

    Returns CancelablePromise<MoveValue>

  • Get table item Get a table item at a specific ledger version from the table identified by {table_handle} in the path and the "key" (TableItemRequest) provided in the request body.

    This is a POST endpoint because the "key" for requesting a specific table item (TableItemRequest) could be quite complex, as each of its fields could themselves be composed of other structs. This makes it impractical to express using query params, meaning GET isn't an option.

    The Aptos nodes prune account state history, via a configurable time window. If the requested ledger version has been pruned, the server responds with a 410.

    Returns

    MoveValue

    Throws

    ApiError

    Parameters

    • tableHandle: string

      Table handle hex encoded 32-byte string

    • requestBody: TableItemRequest
    • Optional ledgerVersion: string

      Ledger version to get state of account

      If not provided, it will be the latest version

    Returns CancelablePromise<MoveValue>

Generated using TypeDoc