Hurdles when managing ENS ABI records

I’ve not found any UIs or utilities to help manage ABI records.
Perhaps I didn’t dig enough?
Are there any?
If there aren’t any, does anyone know why ensjs doesn’t include support?

I added a number of ABI records for my project and I had to write a couple of scripts to help me along. These tasks seem rote. Surely others who’ve added ABI records have jumped through similar hoops? Standardizing this process would be a dream, of sorts.

2 Likes

ABIs haven’t seen widespread usage in ENS, so there isn’t yet a lot of tooling for them. If you’d like to build any, it would be warmly received!

3 Likes

I was looking over the content-hash library, as a possible starting point for ABI.
Should the ABI implementation focus on using CID, if the entries already define the data stored on chain?

The ABI spec defines several ways to encode the data. I don’t think CID is a good format - we need a structured format like JSON or CBOR.

Right, the spec specifies JSON, zlib JSON, CBOR, and URI

Are you saying you would like to see each of those four records encoded in a matching structured format, which would be hexlified on chain?

JSON

{
  "type": "json",
  "data": "{...JSON ABI...}"
}

zlib JSON

{
  "type": "zlibJson",
  "data": "BASE64 ZLIB BUFFER"
}

CBOR

{
  "type": "cbor",
  "data": "CBOR_STRING"
}

URI

{
  "type": "uri",
  "data": "ipfs://...|https://...|..."
}

I’m not sure what you mean? The spec describes how each of those formats can be stored onchain.

In order to make the ABI usable at scale in Dapps, it is necessary to be able to call ideally a subgraph, so that it loads quickly. I need to look into it to see how feasible it is to create a subgraph with The Graph, that can host ABI data.

Etherscan supports this as a centralized service, here is some info.

we need a structured format like JSON or CBOR

When I read “we need a structured format”, my interpretation was, “ABI records should all be structured the same”. Therefore I posited a structured record which would wrap ABI types 1, 2, 4, or 8 in the same JSON.

All four types can be decoded to the canonical JSON format for ABIs already.