In eosjs@16.0.9 I have a Eos.modules.format.encodeName()

Is there something like that in eosjs@20.0.0 or what can I use to replace it?


This module is often used in conjunction with get_table_rows(). If this is the case, you no longer need to encode names when making requests to this method. Simply pass the key as part of the lower_bound parameter.

For example you may make a request like this:

const resp = await rpc.get_table_rows({
  json: true,              // Get the response as json
  code: 'eosio',     // Contract that we target
  scope: 'eosio',         // Account that owns the data
  table: 'deposits',        // Table name
  lower_bound: 'ACCOUNT_NAME_HERE',   
  limit: 1               // Maximum number of rows 
  • 1
    I still need to fetch all the entries for an account name of secondary index, so this doesn't help. Aug 14 '19 at 14:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.