{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "aspectRatio": {
      "description": "The width:height ratio of the image, in pixels.",
      "properties": {
        "height": {
          "minimum": 1,
          "type": "integer"
        },
        "width": {
          "minimum": 1,
          "type": "integer"
        }
      },
      "required": [
        "width",
        "height"
      ],
      "type": "object"
    },
    "effectStep": {
      "description": "One effect in the recipe: its key and the parameters it was applied with.",
      "properties": {
        "params": {
          "description": "The effect's parameters, JSON-encoded. A string rather than an object because the atproto data model has no float type and effect parameters are fractional. Records saved before v4 carry a plain object here instead.",
          "maxLength": 10000,
          "type": "string"
        },
        "type": {
          "description": "The effect key.",
          "maxLength": 128,
          "type": "string"
        }
      },
      "required": [
        "type"
      ],
      "type": "object"
    },
    "main": {
      "description": "An image edited in Luminframe, saved to the author's repo, together with the effect recipe used to produce it.",
      "key": "tid",
      "record": {
        "properties": {
          "alt": {
            "description": "Accessibility description of the image.",
            "maxGraphemes": 2000,
            "maxLength": 10000,
            "type": "string"
          },
          "aspectRatio": {
            "description": "Pixel dimensions of the render, so a viewer can lay it out without decoding.",
            "ref": "#aspectRatio",
            "type": "ref"
          },
          "createdAt": {
            "description": "When the record was created.",
            "format": "datetime",
            "type": "string"
          },
          "effects": {
            "description": "The effect keys applied, in order. Kept for lightweight display and backward compatibility; the executable form is `recipe`.",
            "items": {
              "maxLength": 128,
              "type": "string"
            },
            "maxLength": 64,
            "type": "array"
          },
          "image": {
            "accept": [
              "image/*"
            ],
            "description": "The rendered image. When `video` is present, this is its poster frame.",
            "maxSize": 1000000,
            "type": "blob"
          },
          "recipe": {
            "description": "The ordered effect stack with parameters — the executable edit, so the look can be reconstructed or applied elsewhere.",
            "items": {
              "ref": "#effectStep",
              "type": "ref"
            },
            "maxLength": 64,
            "type": "array"
          },
          "remixOf": {
            "description": "The record this image was remixed from, if any — its lineage.",
            "ref": "com.atproto.repo.strongRef",
            "type": "ref"
          },
          "title": {
            "description": "Short caption or label.",
            "maxGraphemes": 300,
            "maxLength": 3000,
            "type": "string"
          },
          "video": {
            "accept": [
              "video/mp4"
            ],
            "description": "A short looping clip of the edit, present when the recipe animates. The still `image` remains required as the poster, so viewers that only know stills keep working.",
            "maxSize": 5000000,
            "type": "blob"
          }
        },
        "required": [
          "image",
          "aspectRatio",
          "createdAt"
        ],
        "type": "object"
      },
      "type": "record"
    }
  },
  "id": "com.luminframe.image",
  "lexicon": 1
}
