{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/miro/json-schema/miro-upload-file-from-device-schema.json",
  "title": "UploadFileFromDevice",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/miro-documents-api-openapi.yml#/components/schemas/UploadFileFromDevice",
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "title": {
          "type": "string",
          "description": "Title for the document."
        },
        "altText": {
          "type": "string",
          "description": "A description (alt-text) to help people understand what is depicted here."
        },
        "position": {
          "$ref": "#/$defs/PositionChange"
        },
        "geometry": {
          "$ref": "#/$defs/FixedRatioGeometry"
        },
        "parent": {
          "$ref": "#/$defs/Parent"
        }
      }
    },
    "resource": {
      "type": "string",
      "format": "binary",
      "description": "Select a file to upload. Maximum file size is 6 MB."
    }
  },
  "required": [
    "resource"
  ],
  "$defs": {
    "FixedRatioGeometry": {
      "type": "object",
      "description": "Contains geometrical information about the item, such as its width or rotation. You can set either the width or height, you cannot set both the width and height at the same time.",
      "properties": {
        "height": {
          "type": "number",
          "format": "double",
          "description": "Height of the item, in pixels."
        },
        "width": {
          "type": "number",
          "format": "double",
          "description": "Width of the item, in pixels."
        },
        "rotation": {
          "type": "number",
          "format": "double",
          "description": "Rotation angle of an item, in degrees, relative to the board. You can rotate items clockwise (right) and counterclockwise (left) by specifying positive and negative values, respectively."
        }
      }
    },
    "Parent": {
      "type": "object",
      "description": "Contains information about the parent frame for the item.",
      "properties": {
        "id": {
          "type": "string",
          "format": "int64",
          "description": "Unique identifier (ID) of the parent frame for the item."
        }
      }
    },
    "PositionChange": {
      "type": "object",
      "description": "Contains information about the item's position on the board, such as its `x` coordinate, `y` coordinate, and the origin of the `x` and `y` coordinates.",
      "properties": {
        "x": {
          "type": "number",
          "format": "double",
          "description": "X-axis coordinate of the location of the item on the board.\nBy default, all items have absolute positioning to the board, not the current viewport. Default: `0`.\nThe center point of the board has `x: 0` and `y: 0` coordinates.",
          "default": 0
        },
        "y": {
          "type": "number",
          "format": "double",
          "description": "Y-axis coordinate of the location of the item on the board.\nBy default, all items have absolute positioning to the board, not the current viewport. Default: `0`.\nThe center point of the board has `x: 0` and `y: 0` coordinates.",
          "default": 0
        }
      }
    }
  }
}