Closed navcsdev closed 6 years ago
What do you mean "push account authenticate
?
If you already deployed your version of the contract then I see two things to consider:
In the ABI all structs are private until you point to them in the "actions" array (usually at the bottom of the ABI; should be at the top though because that may have prevented confusion here).
Also, make sure your using either eos.transaction with the action "account" pointing your smart contract or you use eos.contract("account", .. Those are the two ways eosjs knows how to query for your ABI file so it knows how to serialize the transaction.
Compared to the hello world example, the eosio namespace is on the parent contract not the user's smart contract:
class hello : public eosio::contract {
EOSIO_ABI( hello, (hi) )
reopen if this is still an issue
I am getting this error too when I try to add actions to the standard eosio.token contract and access using eosjs. Note: it only happens incase of eosio.token.
TypeError: Unknown struct 'approve' for contract 'eosio.token', locate this struct or provide serialized action.data action.data ...
@surabhil possibly related: https://github.com/EOSIO/eosjs/issues/271#issuecomment-408606525
When I add one action to
eosio.token
:eosio.token.abi
eosio.token.hpp
eosio.token.cpp
When I use eosjs to push account
authenticate
. I got an errorThank you !