Execute a contract invocation in read-only mode.
The wallet will return the direct response from the RPC node.
neolineN3.invokeReadMulti({
invokeReadArgs: [
{
scriptHash: "d2a4cff31913016155e38e474a2c06d08be276cf",
operation: "balanceOf",
args: [
{
type: "Address",
value: "NaUjKgf5vMuFt7Ffgfffcpc41uH3adx1jq",
}
]
},
{
scriptHash: "d2a4cff31913016155e38e474a2c06d08be276cf",
operation: "balanceOf",
args: [
{
type: "Address",
value: "NaUjKgf5vMuFt7Ffgfffcpc41uH3adx1jq",
}
]
}
],
signers: [
{
account: "2cab903ff032ac693f8514581665be534beac39f",
scopes: 1
}
]
}).then(result => {
console.log('Read invocation result: ' + JSON.stringify(result));
})
.catch((error) => {
const {type, description, data} = error;
switch(type) {
case 'NO_PROVIDER':
console.log('No provider available.');
break;
case 'CONNECTION_REFUSED':
console.log('Connection dApp not connected. Please call the "connect" function.');
break;
case 'RPC_ERROR':
console.log('There was an error when broadcasting this transaction to the network.');
break;
default:
// Not an expected error object. Just write the error to the console.
console.error(error);
break;
}
});
[
{
"script": "DBRHsV1d1v6Pnc51X7CYvP4eBbMIAxHAHwwJYmFsYW5jZU9mDBTPduKL0AYsSkeO41VhARMZ88+k0kFifVtS",
"state": "HALT",
"stack": [
{
"type": "Integer",
"value": "5293314113"
}
]
},
{
"script": "DBRHsV1d1v6Pnc51X7CYvP4eBbMIAxHAHwwJYmFsYW5jZU9mDBTPduKL0AYsSkeO41VhARMZ88+k0kFifVtS",
"state": "HALT",
"stack": [
{
"type": "Integer",
"value": "5293314113"
}
]
}
]