scaledockhq/scaledock-skills/did
Claude Code and agent skill by scaledockhq/scaledock-skills
- community
Checking that the SKILL.md file is still in the repository.
W3C DID 1.0 Decentralized Identifiers: parse DIDs and DID URLs, build and validate DID documents, resolve and dereference them, and evaluate DID methods. Use when working with did:<method>:<id> identifiers, DID URLs with path, query or fragment and the service, serviceType, relativeRef, versionId, versionTime or hl parameters, DID documents (id, controller, alsoKnownAs, verificationMethod with publicKeyJwk or publicKeyMultibase, Multikey, JsonWebKey, authentication, assertionMethod, keyAgreement, capabilityInvocation, capabilityDelegation, service, serviceEndpoint), JSON and JSON-LD representations and the application/did, did+json and did+ld+json media types, DID resolvers (resolve, dereference, metadata, deactivated, INVALID_DID, NOT_FOUND, the HTTP(S) binding), DID method specifications, the DID Extensions notes, the DID Method Rubric, or did:web. Targets DID 1.0 (Recommendation), previews DID 1.1 (Candidate Recommendation, posture build), and covers DID Resolution 1.0 (Candidate Recommendation Draft).
Install
npx vskill@latest install scaledockhq/scaledock-skills/didSKILL.md
The same SKILL.md was published earlier as scaledockhq/scaledock-skills/did.
DID (Decentralized Identifiers)
Decentralized Identifiers are W3C URIs of the form did:<method>:<method-specific-id>. Each one resolves, through its DID method, to a DID document holding verification methods and services. With this skill an agent produces conforming DIDs, DID URLs and DID documents, implements resolvers and dereferencers, and reviews DID method specifications.
Follow the workflow below step by step. Every rule here comes from a source in Sources, with the section it cites. When a rule and the pinned source disagree, the source wins; when the source has a newer revision than the pin, follow the refresh steps.
Inputs (fill in, or ask before starting)
- Role: {{ROLE}}. One of: DID controller or document producer; consumer or verifier; resolver or dereferencer implementer; resolver client; DID method author; method evaluator.
- Target version: DID 1.0 (default, Recommendation). DID 1.1 is a preview (posture: build): implement it only behind a version switch for named peers, and never make it the default. Resolution follows DID Resolution 1.0, a Candidate Recommendation Draft (posture: build), whose sections 5, 6, 8 and 10 are at risk. See `references/versions.md`.
- Revision: the pinned revision in Sources, unless the user names another.
- Sources: when refreshing this skill or when a rule looks out of date, re-read every URL in Sources first, check the W3C history pages for
did-1.1anddid-resolution-1.0for a newer revision or a Recommendation, and update the pins. - DID methods: {{METHODS}}. The methods to support, each with a link to its specification.
- Representation: {{REPRESENTATION}}. JSON or JSON-LD, and the media type peers expect.
- Resolver binding: {{BINDING}}. A local library, or a remote HTTP(S) resolver and who runs it.
Invariants
DID 1.0 is the default; a "DID 1.1" cite applies only on that line. "Resolution" means DID Resolution 1.0; "CID" means Controlled Identifiers v1.0.
- DIDs match the ABNF (DID 1.0 § 3.1, DID 1.1 § 3.1). The form is
did:plus a method name of[a-z0-9]+plus:plus a non-empty method-specific id ofALPHA / DIGIT / . - _ / pct-encodedcharacters and colons, not ending in a colon. Do not normalize the method-specific id generically; its case rules belong to the method (DID 1.0 § 8.1). - DID URLs are `did path-abempty [ "?" query ] [ "#" fragment ]` (DID 1.0 § 3.2). Relative DID URLs resolve with RFC 3986 § 5, using the DID as the base (DID 1.0 § 3.2.2). The semicolon is reserved.
- The document `id` is the DID (DID 1.0 § 5.1.1). The top-level
idMUST be a DID in the root map, and the resolved document'sidMUST equal the resolved DID (Resolution § 4). The subjectidandcontrollervalues carry no query or fragment (DID 1.1 § 5.1.3). - Verification methods have `id`, `type`, `controller` and one form of key material (DID 1.0 § 5.2, § 5.2.1).
publicKeyJwkMUST NOT containdor other private members. A method MUST NOT have two material properties for the same key. - A key is valid only in its relationship (DID 1.0 § 5.3). Before accepting a proof, check that the verification method is in the relationship the proof claims:
authentication,assertionMethod,keyAgreement,capabilityInvocationorcapabilityDelegation. Retrieve the method with the CID § 3.3 checks. A method absent from the latest document is invalid or revoked. - Services have `id`, `type` and `serviceEndpoint`, and ids are unique (DID 1.0 § 5.4). A producer MUST NOT emit duplicate service
ids, and a consumer MUST raise an error on them. - The representation matches the line (DID 1.0 § 6.2, § 6.3; DID 1.1 § 6.2).
- DID 1.0:
application/did+json, orapplication/did+ld+jsonwith@contextfirst itemhttps://www.w3.org/ns/did/v1. - DID 1.1:
application/didwithhttps://www.w3.org/ns/did/v1.1. - The root MUST be a JSON object.
- Producers and consumers conform (DID 1.0 § 6.1). Producers MUST NOT produce non-conforming DIDs or documents. Consumers MUST choose the representation from the media type and MUST produce errors on non-conforming input.
- Resolution results follow the contract (Resolution § 4, § 4.4).
- On error: an
errorin the resolution metadata, and an empty document and document metadata. - Deactivated DIDs:
deactivated: truein the document metadata. - Errors are RFC 9457 objects with
https://www.w3.org/ns/did#type URLs (Resolution § 11).
- DID parameter values are ASCII strings (DID 1.0 § 3.2.1, Resolution § 3).
versionTimeis a UTC XML datetime without sub-seconds.relativeRefis percent-encoded.versionIdandversionTimeare mutually exclusive (Resolution § 13.4).
- Metadata is a JSON-serializable map (DID 1.0 § 7.3, Resolution § 7).
- A DID method specification covers syntax, the four operations, security and privacy (DID 1.0 § 8.1 to § 8.4). The operations are Create, Resolve with authenticity verification, Update and Deactivate, each specified or stated as impossible. Security follows RFC 3552 and privacy follows RFC 6973 § 5.
Workflow
- Pick the version. Use DID 1.0 unless a named peer needs DID 1.1, and use DID Resolution 1.0 for resolvers.
-> `references/versions.md` ✓ The target DID line and resolution line are recorded, and DID 1.1 is used only behind a switch.
- Parse and build DIDs and DID URLs. Validate against the ABNF, split off path, query and fragment, and percent-encode caller-supplied parameter values.
-> `references/syntax-and-urls.md` ✓ Invalid DIDs are rejected, relative DID URLs expand per RFC 3986 § 5, and duplicate or injected parameters are rejected.
- Author or validate the DID document. Write
id,controllerandalsoKnownAs, then the verification methods, relationships and services.
-> `references/did-documents.md` ✓ The document passes the validation checklist there, with no private key members and unique service ids.
- Serialize and consume. Choose the representation and media type for the line, and pin JSON-LD contexts.
-> `references/did-documents.md` ✓ The @context and media type match the line, and a non-object root or non-conforming document produces an error.
- Resolve and dereference. Implement or call
resolve()anddereference()with the options, metadata, errors and HTTP binding.
-> `references/resolution.md` ✓ An invalid DID, an unsupported method, a missing DID and a deactivated DID each give the specified result and HTTP status.
- Verify proofs through the relationship. Resolve the signer's DID, retrieve the verification method with the CID § 3.3 checks, and check its relationship and expiry.
-> `references/did-documents.md`, `references/security-and-privacy.md` ✓ A key that is in verificationMethod but not in the required relationship is rejected.
- Choose or write a DID method. Check the method against the DID 1.0 § 8 requirements, evaluate it with the rubric for your use, and follow its read steps, for example
did:web.
-> `references/methods.md` ✓ Every supported method has a specification with all four operations, and its security and privacy sections have been read.
- Review security and privacy.
-> `references/security-and-privacy.md` ✓ The review checklist there passes: no personal data in public documents, a written rotation and revocation path, and trusted or local resolution.
- Upgrade (only when asked). Upgrade DID 1.0 documents to DID 1.1 behind a switch, or a DID 1.0 § 7 resolver to DID Resolution 1.0.
-> `references/versions.md` ✓ The upgraded artifact validates against the target version and behaves the same.
Verify before done
- [ ] Every DID and DID URL produced matches the DID 1.0 § 3.1 and § 3.2 ABNF.
- [ ] Every DID document has a top-level
idequal to the DID, and the@contextand media type of its line. - [ ] Every verification method has
id,type,controllerand exactly one form of public key material, with no private members. - [ ] Every proof is accepted only from a verification method in the required relationship of the resolved document.
- [ ] Service ids are unique, and service endpoints are valid URIs (DID 1.0) or URLs (DID 1.1).
- [ ] Resolver errors use the Resolution § 11 type URLs, with the § 12.1 HTTP statuses when served over HTTP.
- [ ] Nothing DID 1.1-specific (the
v1.1context,application/did) is emitted to peers that have not opted in. - [ ] No personal data or human-meaningful identifiers appear in public DID documents.
Reference index
- `references/versions.md`: DID 1.0, DID 1.1 and DID Resolution 1.0 with their status, which to use, what changed, upgrade steps and the preview. Load for steps 1 and 9.
- `references/syntax-and-urls.md`: the DID and DID URL ABNF, identifier restrictions, relative DID URLs, the DID parameters and query normalization. Load for step 2.
- `references/did-documents.md`: core properties, verification methods and material, verification relationships, the CID § 3.3 retrieval checks, services, JSON and JSON-LD, media types and examples. Load for steps 3, 4 and 6.
- `references/resolution.md`:
resolve()anddereference(), options, metadata, the algorithm, errors, the HTTP(S) binding, architectures and resolver security. Load for step 5. - `references/methods.md`: method specification requirements, the DID Extensions notes and registration, the DID Method Rubric, and
did:web. Load for step 7. - `references/security-and-privacy.md`: proving control, expiry, rotation, revocation, recovery, integrity, equivalence and privacy. Load for steps 6 and 8.
Related skills
Install related spec skills by name:
vc-data-model: Verifiable Credentials, the mechanism DID 1.0 § 9.2 and § 10.1 point to for binding a DID to a real-world identity and carrying personal data.npx skills add ScaleDockHQ/scaledock-skills --skill vc-data-modelopenid4vc: OpenID for Verifiable Credential Issuance and Verifiable Presentations.npx skills add ScaleDockHQ/scaledock-skills --skill openid4vceudi-wallet: the EU Digital Identity Wallet architecture.npx skills add ScaleDockHQ/scaledock-skills --skill eudi-walletjwt: JSON Web Tokens and JWK, used withpublicKeyJwk.npx skills add ScaleDockHQ/scaledock-skills --skill jwt
Sources
Status uses the publishing body's own maturity term. Checked is the date the source was last read.
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/did/SKILL.md
Popularity
- 7-day trend score
- 5
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/scaledockhq/scaledock-skills/did)