How to use the web3-core-helpers.formatters.outputTransactionReceiptFormatter function in web3-core-helpers

To help you get started, we’ve selected a few web3-core-helpers examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github ninabreznik / voting-ethereum-contract / node_modules / web3-core-method / src / index.js View on Github external
intervalId = null,
        gasProvided = (_.isObject(payload.params[0]) && payload.params[0].gas) ? payload.params[0].gas : null,
        isContractDeployment = _.isObject(payload.params[0]) &&
            payload.params[0].data &&
            payload.params[0].from &&
            !payload.params[0].to;


    // add custom send Methods
    var _ethereumCalls = [
        new Method({
            name: 'getTransactionReceipt',
            call: 'eth_getTransactionReceipt',
            params: 1,
            inputFormatter: [null],
            outputFormatter: formatters.outputTransactionReceiptFormatter
        }),
        new Method({
            name: 'getCode',
            call: 'eth_getCode',
            params: 2,
            inputFormatter: [formatters.inputAddressFormatter, formatters.inputDefaultBlockNumberFormatter]
        }),
        new Subscriptions({
            name: 'subscribe',
            type: 'eth',
            subscriptions: {
                'newBlockHeaders': {
                    subscriptionName: 'newHeads', // replace subscription with this name
                    params: 0,
                    outputFormatter: formatters.outputBlockFormatter
                }
github citahub / cita-sdk-js / packages / cita-sdk / src / base / rpc.ts View on Github external
export const getAbi = {
  name: 'getAbi',
  call: 'getAbi',
  params: 2,
  inputFormatter: [
    formatters.inputAddressFormatter,
    formatters.inputDefaultBlockNumberFormatter
  ],
  outputFormatter: outputFormatter.outputAbiFormatter
}

export const getTransactionReceipt = {
  name: 'getTransactionReceipt',
  call: 'getTransactionReceipt',
  params: 1,
  outputFormatter: formatters.outputTransactionReceiptFormatter
}

export const getCode = {
  name: 'getCode',
  call: 'getCode',
  params: 2,
  inputFormatter: [
    formatters.inputAddressFormatter,
    formatters.inputDefaultBlockNumberFormatter
  ]
}

export const getAccounts = {
  name: 'getAccounts',
  call: 'accounts',
  params: 0,
github citahub / cita-sdk-js / packages / cita-sdk / lib / base / rpc.js View on Github external
};
exports.getAbi = {
    name: 'getAbi',
    call: 'getAbi',
    params: 2,
    inputFormatter: [
        formatters.inputAddressFormatter,
        formatters.inputDefaultBlockNumberFormatter
    ],
    outputFormatter: outputFormatter.outputAbiFormatter
};
exports.getTransactionReceipt = {
    name: 'getTransactionReceipt',
    call: 'getTransactionReceipt',
    params: 1,
    outputFormatter: formatters.outputTransactionReceiptFormatter
};
exports.getCode = {
    name: 'getCode',
    call: 'getCode',
    params: 2,
    inputFormatter: [
        formatters.inputAddressFormatter,
        formatters.inputDefaultBlockNumberFormatter
    ]
};
exports.getAccounts = {
    name: 'getAccounts',
    call: 'accounts',
    params: 0,
    outputFormatter: utils.toChecksumAddress
};