{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "Upload one photo or video to the home's album. multipart/form-data with parts homeId, file, caption?, takenAt?. The original and its derivatives (thumb, display when larger than 1600 px, video poster) go to the uploader's PDN; a mediaItem record is created in the uploader's repo in the family sphere.",
      "errors": [
        {
          "name": "UnsupportedMedia"
        },
        {
          "name": "MediaTooLarge"
        },
        {
          "name": "UploadThrottled"
        },
        {
          "name": "ScopeMissing"
        },
        {
          "name": "NotAllowed"
        },
        {
          "name": "PdsUnavailable"
        }
      ],
      "input": {
        "encoding": "multipart/form-data"
      },
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "item": {
              "ref": "ai.newnal.illi.media.defs#itemView",
              "type": "ref"
            }
          },
          "required": [
            "item"
          ],
          "type": "object"
        }
      },
      "type": "procedure"
    }
  },
  "id": "ai.newnal.illi.media.uploadItem",
  "lexicon": 1
}
