Sha256: e173fe7c689b54300a39c5af9df967de46bc8ec63f56c0b4a3b794a1f4b00771

Contents?: true

Size: 1000 Bytes

Versions: 1

Compression:

Stored size: 1000 Bytes

Contents

# frozen_string_literal: true

module Harmony
  module Api
    module V1
      module Staking
        module Transaction
          def send_raw_staking_transaction(hash)
            response(post('sendRawStakingTransaction', params: [hash]))
          end

          def get_staking_transaction_by_hash(hash)
            response(post('getStakingTransactionByHash', params: [hash]))
          end

          def get_staking_transaction_by_block_number_and_index(block_number, index)
            params = [Harmony::Api::Utilities.int_to_hex(block_number), Harmony::Api::Utilities.int_to_hex(index)]
            response(post('getStakingTransactionByBlockNumberAndIndex', params: params))
          end

          def get_staking_transaction_by_block_hash_and_index(hash, index)
            params = [hash, Harmony::Api::Utilities.int_to_hex(index)]
            response(post('getStakingTransactionByBlockHashAndIndex', params: params))
          end
          
        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
harmony-api-0.1.4 lib/harmony/api/v1/staking/transaction.rb