Skip to content
by Unity Nodes
Development

Smart contract panicked: Parameter id with type String is required but missing

7 posts332 views11 likesLast activity Jul 2025

  1. Kaz-T-entreOP 3

    Hi I’m new to NEAR, working on this tutorial Dacade

    In this case how can I define a function in this app?
    In chapter AssemblyScript 7.3, when I try to add “near call〜”
    an error occurred like this;

    type: ‘FunctionCallError’,
    context: undefined,
    index: 0,
    kind: {
    ExecutionError: ‘Smart contract panicked: Parameter id with type String is required but missing, filename: “~lib/near-sdk-bindgen/index.ts” line: 33 col: 3’
    },
    transaction_outcome: {
    block_hash: ‘2xJWPRkEuVaZcG1YHEHbqCFhaB97jMQ15yaS2hAs5mfn’,
    id: ‘HdtPvLVxAFNSG63yMRKJb9pFKNrNkm5u3CNKX5qibo8j’,
    outcome: {
    executor_id: ‘dragonrapper.testnet’,
    gas_burnt: 2428428557018,
    logs: [],
    metadata: [Object],
    receipt_ids: [Array],
    status: [Object],
    tokens_burnt: ‘242842855701800000000’
    },
    proof: [ [Object], [Object] ]
    }
    }

  2. chi.ha 2

    Hi there, I would recommend you to head to Near Discord server ( near.chat ) . There is a dev support channel and office hours there that can assist you in details.
    All the best!

  3. Kaz-T-entre 1

    Hi chi.ha
    Thank you for your reply.
    I also asked this in NEAR Discord but still not responding :frowning:

  4. chi.ha 1

    Thank you for your patience! Since the dev team is working on schedule for office hours so I believe they will get to you. You can also look at the schedule of the live office hours here to attend: Developer Office Hours - Help, Q&A, and more

  5. cloudmex-alan 2

    Can you share the function you are calling?

  6. Kaz-T-entre 1

    near call dragonrapper.dragonrapper.testnet setProduct ‘{“product”: {“id”: “0”, “name”: “BBQ”, “description”: “Grilled chicken and beef served with vegetables and chips.”, “location”: “Berlin, Germany”, “price”: “1000000000000000000000000”, “image”: “https://i.imgur.com/yPreV19.png”}}’ --accountId=dragonrapper.testnet

  7. tonni6030 1

    Hi, I had a similar issue when I was learning on Dacade. The error you’re seeing usually means that the function you’re calling expects a parameter called id, but it’s missing in your near call command. Make sure you’re passing it like this: near call <contract-name> <method-name> '{"id": "your_value"}' --accountId <your-account.testnet>. Also, double-check that your function in the smart contract is actually set to receive id as a string. That fixed it for me. Hope it helps!