{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/sudomock-com/json-schema/sudomock-com-photo-mockup-list-schema.json",
  "title": "PhotoMockupList",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/sudomock-com-photo-mockups-api-openapi.yml#/components/schemas/PhotoMockupList",
  "properties": {
    "data": {
      "items": {
        "$ref": "#/$defs/PhotoMockup"
      },
      "type": "array",
      "description": "The mockups on this page, newest first."
    },
    "total": {
      "type": "integer",
      "description": "Total number of mockups matching the query."
    },
    "limit": {
      "type": "integer",
      "description": "Results per page."
    },
    "offset": {
      "type": "integer",
      "description": "Number of mockups skipped before this page."
    },
    "success": {
      "type": "boolean",
      "const": true,
      "description": "Always true on a successful response.",
      "default": true
    }
  },
  "type": "object",
  "required": [
    "data",
    "total",
    "limit",
    "offset"
  ],
  "$defs": {
    "PhotoMockup": {
      "properties": {
        "mockup_id": {
          "type": "string",
          "description": "Unique identifier for the mockup."
        },
        "name": {
          "type": "string",
          "description": "Display name of the mockup."
        },
        "status": {
          "type": "string",
          "description": "Preparation state of the mockup: draft, processing, ready or error."
        },
        "customizable": {
          "type": "boolean",
          "description": "Whether the mockup is ready to accept artwork."
        },
        "thumbnail_url": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "description": "URL of the mockup's thumbnail image."
        },
        "source_width": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "description": "Width of the source image in pixels."
        },
        "source_height": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "description": "Height of the source image in pixels."
        },
        "print_areas": {
          "items": {
            "$ref": "#/$defs/PhotoMockupPrintArea"
          },
          "type": "array",
          "description": "Printable areas saved on this mockup."
        },
        "version": {
          "type": "integer",
          "description": "Version of this mockup's saved definition.",
          "default": 1
        },
        "created_at": {
          "type": "string",
          "format": "date-time",
          "description": "When the mockup was created."
        },
        "updated_at": {
          "type": "string",
          "format": "date-time",
          "description": "When the mockup was last updated."
        }
      },
      "type": "object",
      "required": [
        "mockup_id",
        "name",
        "status",
        "customizable",
        "created_at",
        "updated_at"
      ],
      "title": "PhotoMockup"
    },
    "PhotoMockupPrintArea": {
      "properties": {
        "print_area_id": {
          "type": "string",
          "description": "Unique identifier for the print area."
        },
        "points": {
          "anyOf": [
            {
              "items": {
                "items": {
                  "type": "number"
                },
                "type": "array"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "description": "The area's four [x, y] corner points in source image pixels."
        },
        "name": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "description": "Label for the print area, such as 'Front'."
        },
        "sort_order": {
          "type": "integer",
          "description": "Position of this print area in the mockup's own order, starting at 0.",
          "default": 0
        }
      },
      "type": "object",
      "required": [
        "print_area_id"
      ],
      "title": "PhotoMockupPrintArea"
    }
  }
}