Feature Request: resolve name from address
Is it possible to resolve an ENS name from an ETH address? If not, that would be an amazing feature so I could use ENSKit to fetch both an ENS name and avatar from an address (happy to fetch serially).
@stdc105 let me know if I missed something!
Hi Elise,
Currently, ENSKit can turn ENS names into addresses. To make it possible to do the reverse, from addresses to ENS names, we're working on adding that feature. We'll let you know as soon as it's ready.
In the meantime, you can check out this API, it can handle both types of queries:
https://api.ensideas.com/ens/resolve/vitalik.eth https://api.ensideas.com/ens/resolve/0xd8da6bf26964af9d7eed9e03e53415d37aa96045
When we first started ENSKit, our main focus was on the content hash field for dWebsites, as there wasn't a public API for that yet.
Thanks!
Thank you so much for the explanation @livid ! I'll take a look at the API 👀
Hi @elisealix22
We have added support for reverse resolver. You can use it like this:
let enskit = ENSKit()
if let name = try await enskit.name(addr: "0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045") {
// 0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045 would resolve to vitalik.eth
}