HttpIdentityResolver class final

Default HTTP-based IdentityResolver: handle→DID via com.atproto.identity.resolveHandle, DID document via the PLC directory (did:plc) or well-known/path location (did:web), then the #atproto_pds service endpoint. When starting from a handle, verifies the DID document claims the handle back through alsoKnownAs.

Implemented types

Constructors

HttpIdentityResolver({String handleResolver = 'https://public.api.bsky.app', String plcDirectory = 'https://plc.directory', Client? httpClient, Set<String>? allowedHosts, bool allowPrivateNetwork = false, Duration timeout = const Duration(seconds: 10), int maxResponseBytes = 512 * 1024})

Properties

allowedHosts Set<String>?
Optional allowlist of did:web hostnames (lowercase, no port). When non-null, only these hosts may be contacted for did:web resolution; any other did:web issuer is rejected with an IdentityException before a request is issued.
final
allowPrivateNetwork bool
Whether did:web resolution may target private-network hosts.
final
handleResolver String
final
hashCode int
The hash code for this object.
no setterinherited
maxResponseBytes int
Maximum response body size in bytes; larger responses are rejected with an IdentityException before JSON decoding.
final
plcDirectory String
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
timeout Duration
Per-request timeout applied to every fetch (connection and body read).
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
resolve(String identity) Future<ResolvedIdentity>
Resolves a handle (alice.example, optionally @/at:// prefixed) or a DID (did:plc: / did:web:) to its atproto identity.
override
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited