{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "aspectRatio": {
      "properties": {
        "height": {
          "minimum": 1,
          "type": "integer"
        },
        "width": {
          "minimum": 1,
          "type": "integer"
        }
      },
      "required": [
        "width",
        "height"
      ],
      "type": "object"
    },
    "image": {
      "properties": {
        "alt": {
          "maxGraphemes": 300,
          "maxLength": 3000,
          "type": "string"
        },
        "aspectRatio": {
          "ref": "#aspectRatio",
          "type": "ref"
        },
        "image": {
          "accept": [
            "image/jpeg"
          ],
          "maxSize": 1000000,
          "type": "blob"
        }
      },
      "required": [
        "image"
      ],
      "type": "object"
    },
    "main": {
      "description": "One note per person and bookcase, updated in place. Record key as in de.libranoir.schrank: first letter of the OSM element type plus the OSM id, e.g. n123456. At least text or image should be present.",
      "key": "any",
      "record": {
        "properties": {
          "createdAt": {
            "format": "datetime",
            "type": "string"
          },
          "image": {
            "ref": "#image",
            "type": "ref"
          },
          "osm": {
            "description": "OpenStreetMap element, e.g. node/123456 (type/id).",
            "maxLength": 40,
            "type": "string"
          },
          "text": {
            "description": "The note, e.g. how well stocked or kept the bookcase is.",
            "maxGraphemes": 1000,
            "maxLength": 10000,
            "type": "string"
          },
          "updatedAt": {
            "format": "datetime",
            "type": "string"
          }
        },
        "required": [
          "osm",
          "createdAt"
        ],
        "type": "object"
      },
      "type": "record"
    }
  },
  "description": "A note and/or photo about a public bookcase (OpenStreetMap amenity=public_bookcase), written on LibraNoir.",
  "id": "de.libranoir.schrankNotiz",
  "lexicon": 1
}
