···33 ***********************************************************************/
4455// Resolve a handle (e.g., "dame.bsky.social") into a DID using the atproto resolveHandle endpoint.
66-async function resolveHandleToDid(inputHandle) {
66+export async function resolveHandleToDid(inputHandle) {
77 const url = `${publicServiceEndpoint}/xrpc/com.atproto.identity.resolveHandle?handle=${encodeURIComponent(inputHandle)}`;
88 const data = await getJSON(url);
99 if (!data.did) {
···1313}
14141515// Get the service endpoint for the DID by querying either the PLC directory or (for did:web identities) the well-known DID document.
1616-async function getServiceEndpointForDid(resolvedDid) {
1616+export async function getServiceEndpointForDid(resolvedDid) {
1717 let url;
18181919 if (resolvedDid.startsWith("did:web:")) {