URI Resolver
Resolves SRC47 compliant URIs via Signums Alias system to URLs
const resolver = new URIResolver(ledger); const resolvedURL = await resolver.resolve("signum://arts.johndoe");
with TLD
const resolver = new URIResolver(ledger); const resolvedURL = await resolver.resolve("signum://arts.johndoe:crypto");
Or get the account Id (if set)
const resolver = new URIResolver(ledger); const accountId = await resolver.resolve("signum://arts.johndoe/ac");
Tries to resolve the URI
Error if
A compliant URI
The URL or internal path, iff exists.
Parses the URI. This method can be used to check SRC47 URI compliance
Error if URI is not compliant
The parsed URI components
URI Resolver
Resolves SRC47 compliant URIs via Signums Alias system to URLs
const resolver = new URIResolver(ledger); const resolvedURL = await resolver.resolve("signum://arts.johndoe");
with TLD
const resolver = new URIResolver(ledger); const resolvedURL = await resolver.resolve("signum://arts.johndoe:crypto");
Or get the account Id (if set)
const resolver = new URIResolver(ledger); const accountId = await resolver.resolve("signum://arts.johndoe/ac");