Skip to content

decoding abi #85

@GildedHonour

Description

@GildedHonour

In README:

Need to pass the ABI's manually to the library in order to be able to decode params later

//Add ABI's

const testABI = [{"inputs": [{"type": ....}];
abiDecoder.addABI(testABI);

//Decode Tx data

const testData = "0x53d9d910000........0000a6d9c5f7d4de3cef51ad3b7235d79ccc95114daa";
const decodedData = abiDecoder.decodeMethod(testData);
  1. What's testData? Is it transaction.input? Or what is it?

  2. abiDecoder.addABI(testABI); - does this mean that once I've added some abi (abi1), the method decodeMethod will ONLY be able to decode methods using once specified abi1? What if I have multiple abi-s and multiple methods to decode? In other words, how can I decode a specifi method with a specific abi?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions