Constructors

Properties

client: Client

Methods

  • Convenience for calling database_api.

    Parameters

    • method: string
    • Optionalparams: any[] | {
          [key: string]: any;
      }

    Returns Promise<any>

  • Return a list of accounts.

    Parameters

    • start: string | string[]

      String or array for pagination

    • limit: number

      Number of results, max 1000

    • order: "by_name" | "by_proxy" | "by_next_vesting_withdrawal"

      by_next_vesting_withdrawal: in this case start is a date eg: ["1970-01-01T00:00:00", ""]

    • delayed_votes_active: boolean = true

      Default true (optional)

    Returns Promise<{
        accounts: Account[];
    }>

  • Returns a list of witness votes.

    Parameters

    • start: [null | string, null | string]

      Depends on order (see below)

    • limit: number

      Number of results, max 1000

    • order: "by_account_witness" | "by_witness_account"

      by_account_witness: start is an array of two values: account, witness | by_witness_account: start is an array of two values: witness, account

    Returns Promise<{
        votes: WitnessVotes[];
    }>

    Voters of a witness

    const accounts = await client.database.getListWitnessVotes(['nalexadre', null], 10, 'by_witness_account')