DID:Web resolution.
DID:Web is a W3C standard that resolves DIDs via HTTPS.
The DID Document is fetched from https://<domain>/.well-known/did.json.
Examples
iex> Exosphere.ATProto.Identity.DID.Web.resolve("did:web:example.com")
{:ok, %Document{...}}Notes
- Only hostname-level DIDs are supported (no paths)
- Port numbers are only allowed for localhost in development
Summary
Functions
Resolve a did:web to its DID Document.
Types
@type resolve_opts() :: [timeout: pos_integer(), http_client: module()]
Functions
@spec resolve(String.t(), resolve_opts()) :: {:ok, Exosphere.ATProto.Identity.Document.t()} | {:error, term()}
Resolve a did:web to its DID Document.
Options
:timeout- HTTP request timeout in milliseconds (default: 10_000):http_client- HTTP client module implementingHTTP.Behaviour(default:Exosphere.ATProto.HTTP; useful for testing)