Indexer

Rules

Primarily, the indexing guidelines are pertinent to users who intend to independently index INJRC-20 state data. Nevertheless, individuals encountering challenges may find this information useful for troubleshooting. The content herein has largely been provided by the INJS team. These directives will form the foundation for future INJRC-20 projects, the reference implementation client, and all ensuing updates to the protocol.

  • Inscription must be a valid JSON (not JSON5). Trailing commas invalidate the function.

  • Leading or trailing spaces/tabs/newlines are allowed (and stripped/trimmed).

  • JSON must have "p", "op", "tick" fields where "p"="injrc-20", "op" in ["deploy", "mint", "transfer"]

  • If op is deploy, JSON must have a "max" field and "lim" fields are optional. If "lim" is not set it will be equal to "max".

  • If op is mint or transfer, JSON must have an "amt" field.

  • All op and field names must be in lower case.

  • ALL NECESSARY JSON FIELDS MUST BE STRINGS. Numbers at max, lim, amt etc. are not accepted. Extra fields which haven't been discussed here can be of any type.

  • Numeric fields are not stripped/trimmed. Numeric fields must be integer.

  • Empty string for numeric field is invalid.

  • 0 for numeric fields is invalid.

  • Max value of any numeric field is uint64_max.

  • "tick'' must be 4 bytes wide (UTF-8 is accepted). "tick '' is case insensitive, we use lowercase letters to track tickers (convert tick to lowercase before processing).

  • If a deploy, mint or transfer is sent as fee to miner while inscribing, it must be ignored

  • If a mint has been deployed with more amt than lim, it will be ignored.

  • If a transfer has been deployed with more amt than the available balance of that wallet, it will be ignored.

  • First a deploy inscription is inscribed. This will set the rules for this injrc-20 ticker. If the same ticker (case insensitive) has already been deployed, the second deployment will be invalid.

  • Then anyone can inscribe mint inscriptions with the limits set in deploy inscription until the minted balance reaches to "max" set in deploy inscription.

  • When a wallet mints a injrc-20 token (inscribes a mint inscription to its address), its balance will increase.

  • When this transfer inscription is transferred the original wallet's balance will decrease. The receiver's balance will increase.

  • Deploy inscriptions will not change anyone's balance.

  • All Operations are encoded in base64 in the "memo" field.

  • We only accept msgs[0] from a transaction, all the rest will be ignored.

  • The 'type' of the msg is only accepted as /cosmos.bank.v1beta1.MsgSend

Last updated