All of my other POST calls to a production EOS BP are succeeding no problem. However, when I use push_transactions via ScatterJS I get a 500 CORs error.
const networkJson = {
blockchain:'eos',
host:'api1.eosasia.one',
port:443,
protocol:'https',
chainId:'aca376f206b8fc25a6ed44dbdc66547c36c6c33e3a119ffbeaef943642f0e906'
};
const network = ScatterJS.Network.fromJson(networkJson);
const rpc = new eosjs2.Rpc.JsonRpc("https://api1.eosasia.one:443", { fetch });
const api = ScatterJS.eos(network, Api, {rpc})
async function takeScatterAction(action, dataValue, account) {
const id = await ScatterJS.login();
if (!id) {
alert(`not logged in`)
}
// error is in while executing this api.transact call.
const resultWithConfig = await api.transact(
{
actions: [
{
account: CONTRACT_NAME,
name: action,
authorization: [
{
actor: account.name,
permission: account.authority
}
],
data: dataValue
}
]
}
,
{
blocksBehind: 3,
expireSeconds: 30
}
);
console.log(resultWithConfig);
debugger;
return resultWithConfig;
}
By calls to get chain info succeed no problem: /get_block, /get_required_keys, get_info, get_table_rows.
Curious what I may be doing incorrectly? Thanks for your input!