# w3up cheatsheet ## Packages * `@web3-storage/w3up-client` * `@web3-storage/w3cli` * `@ipld/dag-ucan/did` * `@ucanto/core` ## Tips ### DIDs What is a DID? (tl;dr 'decentralized identifier') > Decentralized identifiers (DIDs) are a new type of identifier that enables verifiable, decentralized digital identity. A DID refers to any subject (e.g., a person, organization, thing, data model, abstract entity, etc.) as determined by the controller of the DID. > In contrast to typical, federated identifiers, DIDs have been designed so that they may be decoupled from centralized registries, identity providers, and certificate authorities. > Specifically, while other parties might be used to help enable the discovery of information related to a DID, the design enables the controller of a DID to prove control over it without requiring permission from any other party. > DIDs are URIs that associate a DID subject with a DID document allowing trustable interactions associated with that subject. <cite>[w3.org did-core](https://www.w3.org/TR/did-core/)</cite> #### DIDs and node.js You can read and parse a DID from stdin like so: import fs from 'node:fs' import * as DID from '@ipld/dag-ucan/did' const data = fs.readFileSync(process.stdin.fd, 'utf-8') const principal = DID.parse(data)