AT URI
AT URI is the addressing scheme used in the AT Protocol to reference repositories, collections, and individual records. Using the at://
scheme, these URIs provide a consistent way to identify and locate content within the ATmosphere.
AT URIs serve several functions within the AT Protocol. They are used to identify users accross the network, provide references during repository syncing, and standardized linking to AT Protocol content.
Applications typically display handle-based URIs for readability, but may use DID-based URIs internally for stability.
Structure[edit | edit source]
AT URIs follow a simple hierarchical structure:
at://{authority}/{collection}/{record-key}
Where:
authority
is either a handle (e.g.alice.bsky.social
) or a Decentralized Identifier (e.g.did:plc:z72i7hdynmk6r22z27h6tvur
)collection
is a Namespaced Identifier (NSID) specifying the type of content (e.g.app.bsky.feed.post
)record-key
is a record key that uniquely identifies a record within the collection.
For example, these two URIs reference the same post:
at://alice.bsky.social/app.bsky.feed.post/3jzfcijpj2z2a
at://did:plc:z72i7hdynmk6r22z27h6tvur/app.bsky.feed.post/3jzfcijpj2z2a
URI Types[edit | edit source]
AT URIs can reference different levels of specificity.
Repository URIs reference an entire user repository:
at://alice.bsky.social
Collection URIs reference all records of a specific type in a repository:
at://alice.bsky.social/app.bsky.feed.post
Record URIs reference a specific individual record:
at://alice.bsky.social/app.bsky.feed.post/3jzfcijpj2z2a
Technical Characteristics[edit | edit source]
AT URIs comply with the general URI specification (RFC 3986). However, they contain some specific constraints. AT URIs must have:
- A maximum length of 8 kilobytes
- No userinfo component (like username:password@)
- No port specifications
AT URI record keys are case-sensitive, while authorities and collections are case-insensitive and normalized to lowercase.
Implementation Considerations[edit | edit source]
Usage of handles or DIDs in URIs depends on context. Handle-based URIs (at://alice.bsky.social/...
) are human-readable but are not permanent. DID-based URIs (at://did:plc:z72i7hdynmk6r22z27h6tvur/...
) are less readable, but provide stable, permanent references. For critical references, using DID-based URIs is recommended to ensure long-term stability.