{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "item": {
      "description": "An item in a collection, with an identifier and optional weight.",
      "properties": {
        "itemIdentifier": {
          "description": "Strong reference to an item in this collection. Items can be activities (org.hypercerts.claim.activity), features (org.hypercerts.entity.feature), and/or other collections (org.hypercerts.collection).",
          "ref": "com.atproto.repo.strongRef",
          "type": "ref"
        },
        "itemWeight": {
          "description": "Optional weight for this item (positive numeric value stored as string). Weights do not need to sum to a specific total; normalization can be performed by the consuming application as needed.",
          "maxLength": 100,
          "type": "string"
        }
      },
      "required": [
        "itemIdentifier"
      ],
      "type": "object"
    },
    "main": {
      "description": "A collection/group of items (activities and/or other collections). Collections support recursive nesting.",
      "key": "tid",
      "record": {
        "properties": {
          "avatar": {
            "description": "The collection's avatar/profile image as a URI or image blob.",
            "refs": [
              "org.hypercerts.defs#uri",
              "org.hypercerts.defs#smallImage"
            ],
            "type": "union"
          },
          "banner": {
            "description": "Larger horizontal image to display behind the collection view.",
            "refs": [
              "org.hypercerts.defs#uri",
              "org.hypercerts.defs#largeImage"
            ],
            "type": "union"
          },
          "createdAt": {
            "description": "Client-declared timestamp when this record was originally created",
            "format": "datetime",
            "type": "string"
          },
          "description": {
            "description": "Long-form description of the collection. An inline string for plain text or markdown, a Leaflet linear document for rich-text content, or a strong reference to an external description record.",
            "refs": [
              "org.hypercerts.defs#descriptionString",
              "pub.leaflet.pages.linearDocument",
              "com.atproto.repo.strongRef"
            ],
            "type": "union"
          },
          "items": {
            "description": "Array of items in this collection with optional weights.",
            "items": {
              "ref": "#item",
              "type": "ref"
            },
            "maxLength": 1000,
            "type": "array"
          },
          "langs": {
            "description": "Human language(s) of this record's text fields, as BCP-47 language tags (e.g. 'es', 'pt-BR'); up to three for mixed-language text. Set by the writing app from the text the author wrote, with the author able to correct it; never from the interface language or a profile preference alone. A hint for readers, not a guarantee: consumers must not hide a record because it lacks this field.",
            "items": {
              "format": "language",
              "type": "string"
            },
            "maxLength": 3,
            "type": "array"
          },
          "location": {
            "description": "A strong reference to the location where this collection's activities were performed. The record referenced must conform with the lexicon app.certified.location.",
            "ref": "com.atproto.repo.strongRef",
            "type": "ref"
          },
          "shortDescription": {
            "description": "Short summary of this collection, suitable for previews and list views. Rich text annotations may be provided via `shortDescriptionFacets`.",
            "maxGraphemes": 300,
            "maxLength": 3000,
            "type": "string"
          },
          "shortDescriptionFacets": {
            "description": "Rich text annotations for `shortDescription` (mentions, URLs, hashtags, etc).",
            "items": {
              "ref": "app.bsky.richtext.facet",
              "type": "ref"
            },
            "type": "array"
          },
          "signatures": {
            "description": "Optional cryptographic signatures attesting to this record's content.",
            "ref": "app.certified.signature.defs#list",
            "type": "ref"
          },
          "tags": {
            "description": "References to org.hypercerts.vocab.tag records classifying this record. All listed tags apply simultaneously (logical AND); the array carries no ordering, weighting, negation, inheritance, or rule logic, and never will — any future expression logic must arrive as a new field and must never reinterpret this one.",
            "items": {
              "ref": "com.atproto.repo.strongRef",
              "type": "ref"
            },
            "maxLength": 20,
            "type": "array"
          },
          "title": {
            "description": "Display name for this collection (e.g. 'Q1 2025 Impact Projects')",
            "maxGraphemes": 80,
            "maxLength": 800,
            "type": "string"
          },
          "type": {
            "description": "The type of this collection. Values beyond the known set are permitted.",
            "knownValues": [
              "favorites",
              "project",
              "portfolio",
              "program"
            ],
            "maxLength": 64,
            "type": "string"
          }
        },
        "required": [
          "title",
          "createdAt"
        ],
        "type": "object"
      },
      "type": "record"
    }
  },
  "id": "org.hypercerts.collection",
  "lexicon": 1
}
