Dereferences a DID (Decentralized Identifier) URL to a corresponding DID resource.
This method interprets the DID URL's components, which include the DID method, method-specific identifier, path, query, and fragment, and retrieves the related resource as per the DID Core specifications.
The DID URL string to dereference.
Optional
options: DidDereferencingOptionsInput options to the dereference function. Optional.
Represents the interface for dereferencing a DID URL to a specific resource within a DID document.
The
DidUrlDereferencer
interface defines a single method,dereference
, which takes a DID URL as input and returns aPromise
that resolves to aDidDereferencingResult
. This result includes the dereferenced resource (if found) and metadata about the dereferencing process.Dereferencing a DID URL involves parsing the URL to identify the specific part of the DID document being referenced, which could be a verification method, a service endpoint, or the entire document itself.
Implementations of this interface must adhere to the dereferencing mechanisms defined in the DID Core specifications, handling various components of the DID URL including the DID itself, path, query, and fragment.
More information on DID URL dereferencing can be found in the DID Core specification.
Example