Extends · open
| name The document or space title. | optional | ||||
| summary A short description shown in previews and cards. | optional | ||||
| icon A square document or space image, as an `ipfs://` URL. | optional | ||||
| thumbnail Deprecated image field kept for old documents; use `icon` or `cover`. | optional | ||||
| cover A wide cover image shown in headers and cards, as an `ipfs://` URL. | optional | ||||
| siteUrl The web address a space is published at; set on the home document when a site is registered. | optional | ||||
| agentServerUrl The agents server that hosts the agent this document mounts (an http(s) origin); set with `type: hm://hyper.media/agent`. | optional | ||||
| attributesSchema The attributes schema THIS document conforms to: the hm:// URL of a schema document (or ipfs://<cid> of a schema blob) whose struct describes the document's attributes. | optional | ||||
| childAttributesSchema The attributes schema this document's direct CHILDREN conform to (hm:// URL or ipfs://<cid>). A child may declare its own `attributesSchema` instead. | optional | ||||
| schemaDefinition This document DEFINES a schema: ipfs://<cid> of the schema blob it describes. Its target is the meta-schema, so an editor creates and validates the blob as a Hypermedia schema (the struct form, rooted at Struct by default). Other documents reference this document's URL as their `attributesSchema`/`childAttributesSchema`. | optional | ||||
| layout Legacy space header layout: `Seed/Experimental/Newspaper` or empty. | one of Seed/Experimental/Newspaper | | optional | |||
| seedExperimentalLogo Space header logo image. | optional | ||||
| seedExperimentalHomeOrder Legacy ordering of a space home listing. | one of UpdatedFirst | CreatedFirst | optional | |||
| displayPublishTime Publication date shown to readers when it differs from the change history. | optional | ||||
| displayAuthor Author byline shown to readers. | optional | ||||
| showOutline Whether to show the document outline. | optional | ||||
| showActivity Whether to show the document's activity and tools. | optional | ||||
| showConversations Whether readers may start and join conversations on the space's documents. Set on a space home document; absent means they may. | optional | ||||
| showDocumentBrowser Whether the sidebar with the space's document browser starts open when readers arrive; when false it starts collapsed and readers can still open it. Set on a space home document; absent means it starts open. | optional | ||||
| showCollectionControls Whether collections offer readers search, filter, sort and view controls. Set on a space home document; absent means they do. | optional | ||||
| contentWidth Width of the content column: `S`, `M` or `L`. | one of S | M | L | optional | |||
| childrenType Layout of the document's root-level blocks, a block children type. | optional | ||||
| theme Visual settings for a space. | optional | ||||
| |||||
| importCategories Comma-separated categories kept from an external import (e.g. WordPress). | optional | ||||
| importTags Comma-separated tags kept from an external import (e.g. WordPress). | optional | ||||
| type Resource type, for example hm://hyper.media/page for a custom HTML page. | optional | ||||
A document's metadata is the map of attributes its Changes set with SetAttributes, merged last-writer-wins per key path. The map is open. Beside the keys listed here a document may carry any custom attribute, and a typed document binds a schema that describes those custom keys. Values are the four scalar values or nested maps of them.
Any other key is allowed; its value is a value.
A value that names an account or a document is a link. A bare account id (z6Mk…), an account's home URL (hm://<uid>), a :profile URL or any other hm:// document URL set as an attribute, such as owner, is indexed as a citation of type metadata/Link whose anchor is the attribute key, attributed to the document that set it. It appears among the target's citations like a link in the body, and when the target is an account it counts as a mention of that account: the notification server emails them and a user-mention trigger fires. A URL whose authority is not an account, such as the type key's hm://hyper.media/page, is not a link.
The keys Seed understands
key | type | meaning |
|---|---|---|
| string | the document or space title |
| string | a short description shown in previews and cards |
|
| a square document or space image |
|
| a wide cover image shown in headers and cards |
|
| deprecated image field kept for older documents; use |
| URL | the web address a space is published at; set on the home document when a site is registered, see Sites |
| URL | the agents server that hosts the agent this document mounts (an http(s) origin), set together with |
| URL | the resource type; custom HTML pages declare hm://hyper.media/page, apps |
| URL | a published HM struct defining a custom HTML page's URL input (see Page input) or what an app tool takes |
| URL | a published HM struct defining what an app tool returns |
|
| an app tool's code: a UnixFS folder whose |
| URL | the hm:// URL of one of an app's own pages, which its Home tab shows |
|
| a custom HTML page: a UnixFS folder whose |
| string | the publication date shown to readers, when it differs from the change history |
| string | an author byline shown to readers |
| boolean | whether to show the document outline |
| boolean | whether to show the document's activity and tools |
| boolean | whether readers may start and join conversations on the space's documents; set on a space home document, absent means they may |
| boolean | whether the sidebar with the space's document browser starts open when readers arrive; when false it starts collapsed and readers can still open it; set on a space home document, absent means it starts open |
| boolean | whether collections offer readers search, filter, sort and view controls; set on a space home document, absent means they do |
|
| the width of the content column |
| string | the layout of the root-level blocks, a children type |
|
| a legacy space header layout |
| map | visual settings for a space; |
|
| a logo shown in the space header |
|
| a legacy ordering of a space's home listing |
| string | comma-separated categories kept from an external import such as WordPress |
| string | comma-separated tags kept from the same import |
Three keys bind a document to Hypermedia Schemas. Typed documents explains them in full.
key | on which document | meaning |
|---|---|---|
| a type's home page | this document defines a schema: |
| an instance | the attributes schema this document conforms to: the type page's |
| a folder | the attributes schema this document's children conform to |
Older documents may still carry title (now name), and old profiles alias and description (now summary). Readers map them. The daemon also keeps internal keys prefixed $db. (the redirect, visibility and derived fields) and strips them from the metadata it serves. A site's navigation menu lives in a detached block, outside the metadata; see navigation item.
Working with metadata
In the Seed app the Attributes tab edits every key, with the required fields of a bound schema pinned at the top. The CLI sets keys with document create --metadata and with the frontmatter of a markdown file, which lists every key in a fixed order. The SDK's HMDocumentMetadataSchema parses the known keys and passes the rest through. The Seed API's ResourceMetadata request returns only the metadata, and QueryDocuments filters documents by any key. Agents read hm://…/:attributes and write options.metadata. See the query grammar.
See also
document: the read model metadata belongs to.
SetAttributes: the op that writes metadata.
key-value: one key path and value.
Typed documents: the schema-binding keys.
navigation item: the site menu.
Seed API: ResourceMetadata returns metadata.
Do you like what you are reading? Subscribe to receive updates.
Unsubscribe anytime