Class GrpcProvider

GrpcProvider implements the Provider interface using gRPC for Massa blockchain interactions

Hierarchy (view full)

Implements

Constructors

Properties

url: string

The gRPC endpoint URL

Accessors

Methods

  • Retrieves the balance of the associated account

    Parameters

    • final: boolean = true

    Returns Promise<bigint>

  • Retrieves storage keys for a smart contract with optional filtering and pagination

    Parameters

    • address: string
    • Optional filter: string | Uint8Array
    • Optional final: boolean

    Returns Promise<Uint8Array[]>

  • Streams new blocks

    Parameters

    • Optional addresses: string[]

      Optional list of addresses to filter by

    • Optional blockIds: string[]

      Optional list of block IDs to filter by

    • Optional slotRange: SlotRange

      Optional slot range to filter by

    Returns ClientReadableStream<NewBlocksServerResponse>

    A stream of new blocks

  • Streams new endorsements

    Parameters

    • Optional addresses: string[]

      Optional list of addresses to filter by

    • Optional endorsementIds: string[]

      Optional list of endorsement IDs to filter by

    • Optional blockIds: string[]

      Optional list of block IDs to filter by

    Returns ClientReadableStream<NewEndorsementsServerResponse>

    A stream of new endorsements

  • Streams new filled blocks

    Parameters

    • Optional addresses: string[]

      Optional list of addresses to filter by

    • Optional blockIds: string[]

      Optional list of block IDs to filter by

    • Optional slotRange: SlotRange

      Optional slot range to filter by

    Returns ClientReadableStream<NewFilledBlocksServerResponse>

    A stream of new filled blocks

  • Streams new operations

    Parameters

    • Optional addresses: string[]

      Optional list of addresses to filter by

    • Optional operationIds: string[]

      Optional list of operation IDs to filter by

    • Optional types: OpType[]

      Optional list of operation types to filter by

    Returns ClientReadableStream<NewOperationsServerResponse>

    A stream of new operations

  • Reads storage values for specified keys in a smart contract

    Parameters

    • address: string
    • keys: string[] | Uint8Array[]
    • final: boolean = true

    Returns Promise<(null | Uint8Array)[]>