dsteem
    Preparing search index...

    Class BroadcastAPI

    Index

    Constructors

    Properties

    client: Client
    expireTime: number = ...

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

    Methods

    • Convenience for calling condenser_api.

      Parameters

      • method: string
      • Optionalparams: any[]

      Returns Promise<any>

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

      Parameters

      • comment: {
            author: string;
            body: string;
            json_metadata: string;
            parent_author: string;
            parent_permlink: string;
            permlink: string;
            title: string;
        }

        The comment/post.

      • key: PrivateKey

        Private posting key of comment author.

      Returns Promise<TransactionConfirmation>

    • Broadcast a comment and set the options.

      Parameters

      • comment: {
            author: string;
            body: string;
            json_metadata: string;
            parent_author: string;
            parent_permlink: string;
            permlink: string;
            title: string;
        }

        The comment/post.

      • options: {
            allow_curation_rewards: boolean;
            allow_votes: boolean;
            author: string;
            extensions: [0, { beneficiaries: BeneficiaryRoute[] }][];
            max_accepted_payout: string | Asset;
            percent_steem_dollars: number;
            permlink: string;
        }

        The comment/post options.

        • allow_curation_rewards: boolean

          Whether to allow post to recieve curation rewards.

        • allow_votes: boolean

          Whether to allow post to receive votes.

        • author: string
        • extensions: [0, { beneficiaries: BeneficiaryRoute[] }][]
        • max_accepted_payout: string | Asset

          SBD value of the maximum payout this post will receive.

        • percent_steem_dollars: number

          The percent of Steem Dollars to key, unkept amounts will be received as Steem Power.

        • permlink: string
      • key: PrivateKey

        Private posting key of comment author.

      Returns Promise<TransactionConfirmation>

    • 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: { delegatee: string; delegator: string; vesting_shares: string | Asset }

        Delegation options.

        • delegatee: string

          The account receiving vesting shares.

        • delegator: string

          The account delegating vesting shares.

        • vesting_shares: string | Asset

          The amount of vesting shares delegated.

      • key: PrivateKey

        Private active key of the delegator.

      Returns Promise<TransactionConfirmation>

    • Broadcast custom JSON.

      Parameters

      • data: {
            id: string;
            json: string;
            required_auths: string[];
            required_posting_auths: string[];
        }

        The custom_json operation payload.

        • id: string

          ID string, must be less than 32 characters long.

        • json: string

          JSON encoded string, must be valid JSON.

        • required_auths: string[]
        • required_posting_auths: string[]
      • key: PrivateKey

        Private posting or active key.

      Returns Promise<TransactionConfirmation>

    • Broadcast a transfer.

      Parameters

      • data: { amount: string | Asset; from: string; memo: string; to: string }

        The transfer operation payload.

        • amount: string | Asset

          Amount of STEEM or SBD to send.

        • from: string

          Sending account name.

        • memo: string

          Plain-text note attached to transaction.

        • to: string

          Receiving account name.

      • key: PrivateKey

        Private active key of sender.

      Returns Promise<TransactionConfirmation>

    • Broadcast a vote.

      Parameters

      • vote: { author: string; permlink: string; voter: string; weight: number }

        The vote to send.

        • author: string
        • permlink: string
        • voter: string
        • weight: number

          Voting weight, 100% = 10000 (STEEMIT_100_PERCENT).

      • key: PrivateKey

        Private posting key of the voter.

      Returns Promise<TransactionConfirmation>