Closed danimesq closed 2 years ago
@wealdtech @mcdee
From the help output:
--abi string ABI, or path to ABI, for the contract
--json string JSON, or path to JSON, for the contract as output by solc --combined-json=bin,abi
So you want to use --abi
not --json
.
@mcdee
So you want to use --abi not --json.
Many thanks for pointing out. Have tried it:
ethereal contract send --contract=0xfa28eC7198028438514b49a3CF353BcA5541ce1d --abi=Peepeth.json --call='post(ipfs-hash)' --from=0xDDfC2e10702d8A781727A34D83B3bb3CA94a3E91
Output:
line 1:5 mismatched input 'ipfs' expecting ')' Failed to convert arguments: argument count mismatch: got 0 for 1
How to format it so it can work like in https://justsmartcontracts.dev/#/?
Example:
How to format the --call='post(ipfs-hash)'
so it can support post
>_ipfsHash
(string)?
As the ABI says, it is a string so needs to be quoted. Something like:
ethereal contract send --contract=0xfa28eC7198028438514b49a3CF353BcA5541ce1d --abi=Peepeth.json --call='post("hashgoeshere")' --from=0xDDfC2e10702d8A781727A34D83B3bb3CA94a3E91
Is
ethereal contract send --contract=0xfa28eC7198028438514b49a3CF353BcA5541ce1d --json=Peepeth.json --call='post(ipfs-hash)' --from=0xDDfC2e10702d8A781727A34D83B3bb3CA94a3E91
correct?Using the Peepeth ABI on justsmartcontracts:
How to properly pass to the "send" command that the call is
post
and_ipfsHash
(string
)?Peepeth.json:
References: https://github.com/wealdtech/ethereal#send, https://justsmartcontracts.dev/#/