These docs are for v1.3.0. Click to read the latest docs for v1.6.

Naming Conventions

Standard Account Names

  • Can only contain the characters .abcdefghijklmnopqrstuvwxyz12345. a-z (lowercase), 1-5 and . (period)
  • Must start with a letter
  • Must be 12 characters

Table Names, Structs, Functions, Classes

  • Can only contain up to 12 alpha characters

Symbols

  • Must be capitalized alpha characters between A and Z
  • Must be 7 characters or less

Principle

2140

Macro & functions related naming

Encode argument into EOSIO name. (base32)
Used for fixed name

📘

If you want to convert into EOSIO name from variable, you should use eosio::string_to_name()

Tips

  1. To encode a script into EOSIO name, see eosio::string_to_name

  2. To decode from base32 and restore to string form, use eosio::to_string() (an alias of std::string)

auto user_name_obj = eosio::name{user}; // account_name user
std::string user_name = user_name_obj.to_string();