Skip to content

Names and addresses

Kujira address lookups

Description

Use this query instead of the more generic name lookup if you know you're resolving a Kujira address.

Response

This query will fail if no reverse record exists for the address.

{"name": "mintthemoon.kuji"}

Examples: CLI

kujirad query wasm state smart <registry_addr> '{"kujira_addr": {"addr": "kujira..."}'

Examples: JS

registrar.kujiraAddr({ addr: "kujira..." })

Name lookups

Description

Use a name lookup to get the name associated with an address. In addition to a Kujira address, you can use any interchain address with a compatible derivation path and it will resolve if a reverse record exists for the equivalent Kujira address.

Response

The query will fail if no reverse record exists for the address.

{"name": "mintthemoon.kuji"}

Examples: CLI

kujirad query wasm state smart <registry_addr> '{"name": {"addr": "kujira..."}'
kujirad query wasm state smart <registry_addr> '{"name": {"addr": "osmo..."}'

Examples: JS

registrar.name({ addr: "kujira..." })
registrar.name({ addr: "stars..." })

Address lookups

Description

Use an address lookup to get the address associated with a domain. By default this will return a Kujira address, but you can pass the prefix parameter to resolve any interchain address with a compatible derivation path.

Response

The query will fail if no record exists for the domain or if the record kind is not KujiraAddr.

{"addr": "kujira..."}
{"addr": "cosmos..."}

Examples: CLI

kujirad query wasm state smart <registry_addr> '{"addr": {"name": "mintthemoon.kuji"}'
kujirad query wasm state smart <registry_addr> '{"addr": {"name": "mintthemoon.kuji", "prefix": "osmo"}'

Examples: JS

registrar.addr({ name: "mintthemoon.kuji" })
registrar.addr({ name: "mintthemoon.kuji", prefix: "secret" })