Document Lexicon

The site.standard.document lexicon provides metadata for documents published on the web.

Overview

Documents may be standalone or associated with a publication. This lexicon can be used to store a document's content and its associated metadata.

Schema

Required Properties

PropertyTypeDescription
sitestringPoints to a publication record at:// or a publication url https:// for loose documents. Avoid trailing slashes.
titlestringTitle of the document. maxLength: 5000 maxGraphemes: 500
publishedAtdatetimeTimestamp of the documents publish time.

Optional Properties

PropertyTypeDescription
pathstringCombine with site or publication url to construct a canonical URL to the document. A slash should be included at the beginning of this value.
descriptionstringA brief description or excerpt from the document. maxLength: 30000 maxGraphemes: 3000
coverImageblobImage to used for thumbnail or cover image. Less than 1MB is size.
contentunionOpen union used to define the record's content. Each entry must specify a $type
textContentstringPlaintext representation of the documents contents. Should not contain markdown or other formatting.
bskyPostRefrefStrong reference to a Bluesky post. Useful to keep track of comments off-platform.
tagsarrayArray of strings used to tag or categorize the document. Avoid prepending tags with hashtags. maxLength: 1280 maxGraphemes: 128
updatedAtdatetimeTimestamp of the documents last edit.

Example

{
  "$type": "site.standard.document",
  "site": "at://did:plc:abc123/site.standard.publication/3lwafzkjqm25s",
  "path": "/blog/getting-started",
  "title": "Getting Started with Standard.site",
  "description": "Learn how to use Standard.site lexicons in your project",
  "coverImage": {
    "$type": "blob",
    "ref": {
      "$link": "bafkreiexample123456789"
    },
    "mimeType": "image/jpeg",
    "size": 245678
  },
  "textContent": "Full text of the article...",
  "tags": ["tutorial", "atproto"],
  "publishedAt": "2024-01-20T14:30:00.000Z"
}

Content Format

The content property is an open union, allowing for extensibility. Each entry must specify a $type and may be extended with other lexicons to support additional content formats like Markdown, blocks, or other rich text.

View the Lexicon

Best Practices

  • While we encourage avoid trailing slashes, some may not implement this in practice. If you are validating records, you should trim trailing slashes for site in your codebase.
Standard.site© 2026
Built by the communityDesigned for the ATmosphere