immich/open-api/immich-openapi-specs.json

1092 lines
No EOL
24 KiB
JSON

{
"openapi": "3.0.0",
"paths": {
"/admin/maintenance": {
"get": {
"operationId": "getMaintenanceMode",
"parameters": [],
"responses": {
"200": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/MaintenanceModeResponseDto"
}
}
},
"description": ""
}
},
"tags": [
"Maintenance (admin)"
]
}
},
"/admin/maintenance/end": {
"post": {
"operationId": "endMaintenance",
"parameters": [],
"responses": {
"201": {
"description": ""
}
},
"security": [
{
"bearer": []
},
{
"cookie": []
},
{
"api_key": []
}
],
"tags": [
"Maintenance (admin)"
],
"x-immich-admin-only": true,
"x-immich-permission": "systemMetadata.update",
"description": "This endpoint is an admin-only route, and requires the `systemMetadata.update` permission."
}
},
"/admin/maintenance/start": {
"post": {
"operationId": "startMaintenance",
"parameters": [],
"responses": {
"201": {
"description": ""
}
},
"security": [
{
"bearer": []
},
{
"cookie": []
},
{
"api_key": []
}
],
"tags": [
"Maintenance (admin)"
],
"x-immich-admin-only": true,
"x-immich-permission": "systemMetadata.update",
"description": "This endpoint is an admin-only route, and requires the `systemMetadata.update` permission."
}
}
},
"info": {
"title": "Immich",
"description": "Immich API",
"version": "2.2.0",
"contact": {}
},
"tags": [],
"servers": [
{
"url": "/api"
}
],
"components": {
"securitySchemes": {
"bearer": {
"scheme": "Bearer",
"bearerFormat": "JWT",
"type": "http",
"in": "header"
},
"cookie": {
"type": "apiKey",
"in": "cookie",
"name": "immich_access_token"
},
"api_key": {
"type": "apiKey",
"in": "header",
"name": "x-api-key"
}
},
"schemas": {
"AlbumUserRole": {
"enum": [
"editor",
"viewer"
],
"type": "string"
},
"AssetMetadataKey": {
"enum": [
"mobile-app"
],
"type": "string"
},
"AssetOrder": {
"enum": [
"asc",
"desc"
],
"type": "string"
},
"AssetTypeEnum": {
"enum": [
"IMAGE",
"VIDEO",
"AUDIO",
"OTHER"
],
"type": "string"
},
"AssetVisibility": {
"enum": [
"archive",
"timeline",
"hidden",
"locked"
],
"type": "string"
},
"MaintenanceModeResponseDto": {
"properties": {
"isMaintenanceMode": {
"type": "boolean"
}
},
"required": [
"isMaintenanceMode"
],
"type": "object"
},
"MemoryType": {
"enum": [
"on_this_day"
],
"type": "string"
},
"SyncAckV1": {
"properties": {},
"type": "object"
},
"SyncAlbumDeleteV1": {
"properties": {
"albumId": {
"type": "string"
}
},
"required": [
"albumId"
],
"type": "object"
},
"SyncAlbumToAssetDeleteV1": {
"properties": {
"albumId": {
"type": "string"
},
"assetId": {
"type": "string"
}
},
"required": [
"albumId",
"assetId"
],
"type": "object"
},
"SyncAlbumToAssetV1": {
"properties": {
"albumId": {
"type": "string"
},
"assetId": {
"type": "string"
}
},
"required": [
"albumId",
"assetId"
],
"type": "object"
},
"SyncAlbumUserDeleteV1": {
"properties": {
"albumId": {
"type": "string"
},
"userId": {
"type": "string"
}
},
"required": [
"albumId",
"userId"
],
"type": "object"
},
"SyncAlbumUserV1": {
"properties": {
"albumId": {
"type": "string"
},
"role": {
"allOf": [
{
"$ref": "#/components/schemas/AlbumUserRole"
}
]
},
"userId": {
"type": "string"
}
},
"required": [
"albumId",
"role",
"userId"
],
"type": "object"
},
"SyncAlbumV1": {
"properties": {
"createdAt": {
"format": "date-time",
"type": "string"
},
"description": {
"type": "string"
},
"id": {
"type": "string"
},
"isActivityEnabled": {
"type": "boolean"
},
"name": {
"type": "string"
},
"order": {
"allOf": [
{
"$ref": "#/components/schemas/AssetOrder"
}
]
},
"ownerId": {
"type": "string"
},
"thumbnailAssetId": {
"nullable": true,
"type": "string"
},
"updatedAt": {
"format": "date-time",
"type": "string"
}
},
"required": [
"createdAt",
"description",
"id",
"isActivityEnabled",
"name",
"order",
"ownerId",
"thumbnailAssetId",
"updatedAt"
],
"type": "object"
},
"SyncAssetDeleteV1": {
"properties": {
"assetId": {
"type": "string"
}
},
"required": [
"assetId"
],
"type": "object"
},
"SyncAssetExifV1": {
"properties": {
"assetId": {
"type": "string"
},
"city": {
"nullable": true,
"type": "string"
},
"country": {
"nullable": true,
"type": "string"
},
"dateTimeOriginal": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"description": {
"nullable": true,
"type": "string"
},
"exifImageHeight": {
"nullable": true,
"type": "integer"
},
"exifImageWidth": {
"nullable": true,
"type": "integer"
},
"exposureTime": {
"nullable": true,
"type": "string"
},
"fNumber": {
"format": "double",
"nullable": true,
"type": "number"
},
"fileSizeInByte": {
"nullable": true,
"type": "integer"
},
"focalLength": {
"format": "double",
"nullable": true,
"type": "number"
},
"fps": {
"format": "double",
"nullable": true,
"type": "number"
},
"iso": {
"nullable": true,
"type": "integer"
},
"latitude": {
"format": "double",
"nullable": true,
"type": "number"
},
"lensModel": {
"nullable": true,
"type": "string"
},
"longitude": {
"format": "double",
"nullable": true,
"type": "number"
},
"make": {
"nullable": true,
"type": "string"
},
"model": {
"nullable": true,
"type": "string"
},
"modifyDate": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"orientation": {
"nullable": true,
"type": "string"
},
"profileDescription": {
"nullable": true,
"type": "string"
},
"projectionType": {
"nullable": true,
"type": "string"
},
"rating": {
"nullable": true,
"type": "integer"
},
"state": {
"nullable": true,
"type": "string"
},
"timeZone": {
"nullable": true,
"type": "string"
}
},
"required": [
"assetId",
"city",
"country",
"dateTimeOriginal",
"description",
"exifImageHeight",
"exifImageWidth",
"exposureTime",
"fNumber",
"fileSizeInByte",
"focalLength",
"fps",
"iso",
"latitude",
"lensModel",
"longitude",
"make",
"model",
"modifyDate",
"orientation",
"profileDescription",
"projectionType",
"rating",
"state",
"timeZone"
],
"type": "object"
},
"SyncAssetFaceDeleteV1": {
"properties": {
"assetFaceId": {
"type": "string"
}
},
"required": [
"assetFaceId"
],
"type": "object"
},
"SyncAssetFaceV1": {
"properties": {
"assetId": {
"type": "string"
},
"boundingBoxX1": {
"type": "integer"
},
"boundingBoxX2": {
"type": "integer"
},
"boundingBoxY1": {
"type": "integer"
},
"boundingBoxY2": {
"type": "integer"
},
"id": {
"type": "string"
},
"imageHeight": {
"type": "integer"
},
"imageWidth": {
"type": "integer"
},
"personId": {
"nullable": true,
"type": "string"
},
"sourceType": {
"type": "string"
}
},
"required": [
"assetId",
"boundingBoxX1",
"boundingBoxX2",
"boundingBoxY1",
"boundingBoxY2",
"id",
"imageHeight",
"imageWidth",
"personId",
"sourceType"
],
"type": "object"
},
"SyncAssetMetadataDeleteV1": {
"properties": {
"assetId": {
"type": "string"
},
"key": {
"allOf": [
{
"$ref": "#/components/schemas/AssetMetadataKey"
}
]
}
},
"required": [
"assetId",
"key"
],
"type": "object"
},
"SyncAssetMetadataV1": {
"properties": {
"assetId": {
"type": "string"
},
"key": {
"allOf": [
{
"$ref": "#/components/schemas/AssetMetadataKey"
}
]
},
"value": {
"type": "object"
}
},
"required": [
"assetId",
"key",
"value"
],
"type": "object"
},
"SyncAssetV1": {
"properties": {
"checksum": {
"type": "string"
},
"deletedAt": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"duration": {
"nullable": true,
"type": "string"
},
"fileCreatedAt": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"fileModifiedAt": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"id": {
"type": "string"
},
"isFavorite": {
"type": "boolean"
},
"libraryId": {
"nullable": true,
"type": "string"
},
"livePhotoVideoId": {
"nullable": true,
"type": "string"
},
"localDateTime": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"originalFileName": {
"type": "string"
},
"ownerId": {
"type": "string"
},
"stackId": {
"nullable": true,
"type": "string"
},
"thumbhash": {
"nullable": true,
"type": "string"
},
"type": {
"allOf": [
{
"$ref": "#/components/schemas/AssetTypeEnum"
}
]
},
"visibility": {
"allOf": [
{
"$ref": "#/components/schemas/AssetVisibility"
}
]
}
},
"required": [
"checksum",
"deletedAt",
"duration",
"fileCreatedAt",
"fileModifiedAt",
"id",
"isFavorite",
"libraryId",
"livePhotoVideoId",
"localDateTime",
"originalFileName",
"ownerId",
"stackId",
"thumbhash",
"type",
"visibility"
],
"type": "object"
},
"SyncAuthUserV1": {
"properties": {
"avatarColor": {
"allOf": [
{
"$ref": "#/components/schemas/UserAvatarColor"
}
],
"nullable": true
},
"deletedAt": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"email": {
"type": "string"
},
"hasProfileImage": {
"type": "boolean"
},
"id": {
"type": "string"
},
"isAdmin": {
"type": "boolean"
},
"name": {
"type": "string"
},
"oauthId": {
"type": "string"
},
"pinCode": {
"nullable": true,
"type": "string"
},
"profileChangedAt": {
"format": "date-time",
"type": "string"
},
"quotaSizeInBytes": {
"nullable": true,
"type": "integer"
},
"quotaUsageInBytes": {
"type": "integer"
},
"storageLabel": {
"nullable": true,
"type": "string"
}
},
"required": [
"avatarColor",
"deletedAt",
"email",
"hasProfileImage",
"id",
"isAdmin",
"name",
"oauthId",
"pinCode",
"profileChangedAt",
"quotaSizeInBytes",
"quotaUsageInBytes",
"storageLabel"
],
"type": "object"
},
"SyncCompleteV1": {
"properties": {},
"type": "object"
},
"SyncMemoryAssetDeleteV1": {
"properties": {
"assetId": {
"type": "string"
},
"memoryId": {
"type": "string"
}
},
"required": [
"assetId",
"memoryId"
],
"type": "object"
},
"SyncMemoryAssetV1": {
"properties": {
"assetId": {
"type": "string"
},
"memoryId": {
"type": "string"
}
},
"required": [
"assetId",
"memoryId"
],
"type": "object"
},
"SyncMemoryDeleteV1": {
"properties": {
"memoryId": {
"type": "string"
}
},
"required": [
"memoryId"
],
"type": "object"
},
"SyncMemoryV1": {
"properties": {
"createdAt": {
"format": "date-time",
"type": "string"
},
"data": {
"type": "object"
},
"deletedAt": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"hideAt": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"id": {
"type": "string"
},
"isSaved": {
"type": "boolean"
},
"memoryAt": {
"format": "date-time",
"type": "string"
},
"ownerId": {
"type": "string"
},
"seenAt": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"showAt": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"type": {
"allOf": [
{
"$ref": "#/components/schemas/MemoryType"
}
]
},
"updatedAt": {
"format": "date-time",
"type": "string"
}
},
"required": [
"createdAt",
"data",
"deletedAt",
"hideAt",
"id",
"isSaved",
"memoryAt",
"ownerId",
"seenAt",
"showAt",
"type",
"updatedAt"
],
"type": "object"
},
"SyncPartnerDeleteV1": {
"properties": {
"sharedById": {
"type": "string"
},
"sharedWithId": {
"type": "string"
}
},
"required": [
"sharedById",
"sharedWithId"
],
"type": "object"
},
"SyncPartnerV1": {
"properties": {
"inTimeline": {
"type": "boolean"
},
"sharedById": {
"type": "string"
},
"sharedWithId": {
"type": "string"
}
},
"required": [
"inTimeline",
"sharedById",
"sharedWithId"
],
"type": "object"
},
"SyncPersonDeleteV1": {
"properties": {
"personId": {
"type": "string"
}
},
"required": [
"personId"
],
"type": "object"
},
"SyncPersonV1": {
"properties": {
"birthDate": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"color": {
"nullable": true,
"type": "string"
},
"createdAt": {
"format": "date-time",
"type": "string"
},
"faceAssetId": {
"nullable": true,
"type": "string"
},
"id": {
"type": "string"
},
"isFavorite": {
"type": "boolean"
},
"isHidden": {
"type": "boolean"
},
"name": {
"type": "string"
},
"ownerId": {
"type": "string"
},
"updatedAt": {
"format": "date-time",
"type": "string"
}
},
"required": [
"birthDate",
"color",
"createdAt",
"faceAssetId",
"id",
"isFavorite",
"isHidden",
"name",
"ownerId",
"updatedAt"
],
"type": "object"
},
"SyncResetV1": {
"properties": {},
"type": "object"
},
"SyncStackDeleteV1": {
"properties": {
"stackId": {
"type": "string"
}
},
"required": [
"stackId"
],
"type": "object"
},
"SyncStackV1": {
"properties": {
"createdAt": {
"format": "date-time",
"type": "string"
},
"id": {
"type": "string"
},
"ownerId": {
"type": "string"
},
"primaryAssetId": {
"type": "string"
},
"updatedAt": {
"format": "date-time",
"type": "string"
}
},
"required": [
"createdAt",
"id",
"ownerId",
"primaryAssetId",
"updatedAt"
],
"type": "object"
},
"SyncUserDeleteV1": {
"properties": {
"userId": {
"type": "string"
}
},
"required": [
"userId"
],
"type": "object"
},
"SyncUserMetadataDeleteV1": {
"properties": {
"key": {
"allOf": [
{
"$ref": "#/components/schemas/UserMetadataKey"
}
]
},
"userId": {
"type": "string"
}
},
"required": [
"key",
"userId"
],
"type": "object"
},
"SyncUserMetadataV1": {
"properties": {
"key": {
"allOf": [
{
"$ref": "#/components/schemas/UserMetadataKey"
}
]
},
"userId": {
"type": "string"
},
"value": {
"type": "object"
}
},
"required": [
"key",
"userId",
"value"
],
"type": "object"
},
"SyncUserV1": {
"properties": {
"avatarColor": {
"allOf": [
{
"$ref": "#/components/schemas/UserAvatarColor"
}
],
"nullable": true
},
"deletedAt": {
"format": "date-time",
"nullable": true,
"type": "string"
},
"email": {
"type": "string"
},
"hasProfileImage": {
"type": "boolean"
},
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"profileChangedAt": {
"format": "date-time",
"type": "string"
}
},
"required": [
"avatarColor",
"deletedAt",
"email",
"hasProfileImage",
"id",
"name",
"profileChangedAt"
],
"type": "object"
},
"UserAvatarColor": {
"enum": [
"primary",
"pink",
"red",
"yellow",
"blue",
"green",
"purple",
"orange",
"gray",
"amber"
],
"type": "string"
},
"UserMetadataKey": {
"enum": [
"preferences",
"license",
"onboarding"
],
"type": "string"
}
}
}
}