eos.getActions()
is actually a wrapper of /history/get_actions
RPC API which is provided by the history_api_plugin
of nodeos
. For this API endpoint, account_name
is the name of the account who signed and sent this transaction.
https://developers.eos.io/eosio-nodeos/reference#get_actions-1
In your case, you are recommended to utilize mongodb for query purposes. You can checkout the mongo_db_plugin
for nodeos. (https://developers.eos.io/eosio-nodeos/docs/mongo_db_plugin)
With mongo_db_plugin
, you can save all the action data into your mongodb instance and query anyway you like in mongodb. E.g. actions are saved in the action_traces
mongo collection.
db.action_traces.find({'act.account': 'newdexpocket', 'act.authorization.actor': 'newdexpocket'})
For better query performance, please add index for 'act.account' and 'act.authorization.actor'.
db.action_traces.createIndexes([{'act.authorization.actor': 1}, {'act.account': 1}], {background: true})
Btw, history_api_plugin
is deprecated since eosio v1.2.0 and may be removed in the future. You should consider starting your migration before it's too late.