Options
All
  • Public
  • Public/Protected
  • All
Menu

Class BroadcastAPI

Hierarchy

  • BroadcastAPI

Index

Constructors

constructor

Properties

client

client: Client

expireTime

expireTime: number = 60 * 1000

How many milliseconds in the future to set the expiry time to when broadcasting a transaction, defaults to 1 minute.

Methods

call

  • call(method: string, params?: any[]): Promise<any>
  • Convenience for calling condenser_api.

    Parameters

    • method: string
    • Optional params: any[]

    Returns Promise<any>

comment

  • Broadcast a comment, also used to create a new top level post.

    Parameters

    • comment: CommentOperation[1]

      The comment/post.

    • key: PrivateKey

      Private posting key of comment author.

    Returns Promise<TransactionConfirmation>

commentWithOptions

  • Broadcast a comment and set the options.

    Parameters

    • comment: CommentOperation[1]

      The comment/post.

    • options: CommentOptionsOperation[1]

      The comment/post options.

    • key: PrivateKey

      Private posting key of comment author.

    Returns Promise<TransactionConfirmation>

createTestAccount

delegateVestingShares

  • Delegate vesting shares from one account to the other. The vesting shares are still owned by the original account, but content voting rights and bandwidth allocation are transferred to the receiving account. This sets the delegation to vesting_shares, increasing it or decreasing it as needed. (i.e. a delegation of 0 removes the delegation)

    When a delegation is removed the shares are placed in limbo for a week to prevent a satoshi of VESTS from voting on the same content twice.

    Parameters

    • options: DelegateVestingSharesOperation[1]

      Delegation options.

    • key: PrivateKey

      Private active key of the delegator.

    Returns Promise<TransactionConfirmation>

json

  • Broadcast custom JSON.

    Parameters

    • data: CustomJsonOperation[1]

      The custom_json operation payload.

    • key: PrivateKey

      Private posting or active key.

    Returns Promise<TransactionConfirmation>

send

sendOperations

  • Sign and broadcast transaction with operations to the network. Throws if the transaction expires.

    Parameters

    Returns Promise<TransactionConfirmation>

sign

transfer

  • Broadcast a transfer.

    Parameters

    • data: TransferOperation[1]

      The transfer operation payload.

    • key: PrivateKey

      Private active key of sender.

    Returns Promise<TransactionConfirmation>

updateAccount

  • Update account.

    Parameters

    • data: AccountUpdateOperation[1]

      The account_update payload.

    • key: PrivateKey

      The private key of the account affected, should be the corresponding key level or higher for updating account authorities.

    Returns Promise<TransactionConfirmation>

vote

  • Broadcast a vote.

    Parameters

    • vote: VoteOperation[1]

      The vote to send.

    • key: PrivateKey

      Private posting key of the voter.

    Returns Promise<TransactionConfirmation>

Generated using TypeDoc