MultiversX icon

MultiversX

MultiversX blockchain operations: Execute smart contracts, check balances, transfer tokens, query accounts, get transactions, and access network data. Can inspect ABI functions and contract details. ALWAYS validate ABI functions before execution. Automatically provides contract context to AI including address and available functions.

Overview

This node enables interaction with the MultiversX blockchain, focusing on inspecting smart contracts in the "Inspect Contract" operation. It allows users to:

  • List all functions defined in a contract's ABI.
  • Retrieve basic contract details such as address, name, build info, and types.
  • Get detailed information about a specific function within the contract.

This is particularly useful for developers or integrators who want to explore and understand a smart contract's interface before executing or querying its functions. For example, you can verify available read-only and mutable functions, check input/output parameters, or confirm if a function requires ownership or token payments.

Practical scenarios include:

  • Auditing a deployed contract’s capabilities.
  • Preparing to call or query contract functions by understanding their signatures.
  • Debugging or documenting smart contract interfaces.

Properties

Name Meaning
Contract Address The address of the smart contract to inspect (e.g., erd1qqqqqqqqqqqqqpgq...).
Contract ABI The JSON-formatted ABI of the contract, required to parse and validate functions and parameter types.
Inspection Type The type of inspection to perform:
• List All Functions — Show all functions in the ABI.
• Contract Details — Show basic contract info.
• Function Details — Show detailed info about a specific function.
Function Name (Shown only when Inspection Type is "Function Details") The name of the function to inspect in detail.

Output

The output JSON structure varies depending on the selected inspection type:

  • List All Functions
    Returns an object containing:

    • contractAddress: The inspected contract address.
    • totalFunctions: Number of functions in the ABI.
    • functions: Array of function objects with properties: name, mutability ("readonly" or "mutable"), inputs, outputs, and description.
    • readOnlyFunctions: Array of names of read-only (view) functions.
    • mutableFunctions: Array of names of functions that modify state.
  • Contract Details
    Returns an object with:

    • contractAddress: The contract address.
    • contractName: Name from ABI or "Unknown".
    • buildInfo: Build metadata from ABI if available.
    • totalEndpoints: Number of functions/endpoints.
    • hasConstructor: Boolean indicating if constructor exists.
    • types: Object keys representing custom types defined in the ABI.
  • Function Details
    Returns detailed info about the specified function:

    • contractAddress: Contract address.
    • functionName: Name of the function.
    • mutability: "readonly" or "mutable".
    • inputs: Array describing input parameters.
    • outputs: Array describing output parameters.
    • description: Documentation string if present.
    • payableInTokens: Array of tokens accepted as payment (if any).
    • onlyOwner: Boolean indicating if function is restricted to owner.

No binary data output is produced by this operation.

Dependencies

  • Requires a valid API key credential for MultiversX wallet access to determine network environment (mainnet, testnet, devnet).
  • Uses the MultiversX SDK libraries for ABI parsing and contract interaction.
  • The contract ABI JSON must be provided and correctly formatted.
  • Network endpoints are automatically selected based on the configured environment.

Troubleshooting

  • Invalid ABI format error:
    Occurs if the provided ABI JSON is malformed or cannot be parsed.
    Resolution: Validate the ABI JSON syntax before inputting it.

  • Function not found error:
    When requesting details for a function name not present in the ABI.
    Resolution: Use "List All Functions" inspection first to verify available function names.

  • Missing Contract ABI:
    The node throws an error if no ABI is provided for inspection operations.
    Resolution: Always supply the correct ABI JSON for the target contract.

  • Unsupported inspection type:
    If an invalid inspection type is selected, an error is thrown.
    Resolution: Choose one of the supported inspection types: listFunctions, contractDetails, or functionDetails.

Links and References

Discussion