Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
346 changes: 346 additions & 0 deletions openapi/schemas/asset.openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,186 @@
}
}
},
"/asset/batch-upload/{batchUploadId}/abort": {
"post": {
"tags": [
"BatchUpload"
],
"summary": "Aborts the specified batch upload.",
"parameters": [
{
"name": "batchUploadId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"204": {
"description": "No Content"
},
"400": {
"description": "Bad Request",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ValidationProblemDetails"
}
}
}
},
"401": {
"description": "Unauthenticated"
},
"403": {
"description": "Forbidden"
}
}
}
},
"/asset/batch-upload": {
"post": {
"tags": [
"BatchUpload"
],
"summary": "Creates a batch upload and queues processing for each URL.",
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CreateBatchUploadEndpoint_Input"
}
}
},
"required": true
},
"responses": {
"200": {
"description": "OK",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CreateBatchUploadEndpoint_Output"
}
}
}
},
"400": {
"description": "Bad Request",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ValidationProblemDetails"
}
}
}
},
"401": {
"description": "Unauthenticated"
},
"403": {
"description": "Forbidden"
}
}
}
},
"/asset/batch-upload/{batchUploadId}": {
"get": {
"tags": [
"BatchUpload"
],
"summary": "Gets the full result of a batch upload including all items.",
"parameters": [
{
"name": "batchUploadId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/GetBatchUploadResultEndpoint_Output"
}
}
}
},
"400": {
"description": "Bad Request",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ValidationProblemDetails"
}
}
}
},
"401": {
"description": "Unauthenticated"
},
"403": {
"description": "Forbidden"
}
}
}
},
"/asset/batch-upload/status": {
"get": {
"tags": [
"BatchUpload"
],
"summary": "Gets aggregated status (counts) for the specified batch uploads.",
"parameters": [
{
"name": "batchUploadIds",
"in": "query",
"required": true,
"schema": {
"type": "array",
"items": {
"type": "string"
}
}
}
],
"responses": {
"200": {
"description": "OK",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/GetBatchUploadStatusEndpoint_Output"
}
}
}
},
"400": {
"description": "Bad Request",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ValidationProblemDetails"
}
}
}
},
"401": {
"description": "Unauthenticated"
},
"403": {
"description": "Forbidden"
}
}
}
},
"/asset/file": {
"post": {
"tags": [
Expand Down Expand Up @@ -236,12 +416,48 @@
},
"components": {
"schemas": {
"BatchUploadStatus": {
"enum": [
"Processing",
"Completed",
"Aborted"
]
},
"BatchUploadUrlStatus": {
"enum": [
"Pending",
"Completed",
"Failed"
]
},
"CompressionLibrary": {
"enum": [
"ImageSharp",
"NetVips"
]
},
"CreateBatchUploadEndpoint_Input": {
"required": [
"urls"
],
"type": "object",
"properties": {
"urls": {
"$ref": "#/components/schemas/ListOfUri"
}
}
},
"CreateBatchUploadEndpoint_Output": {
"required": [
"batchUploadId"
],
"type": "object",
"properties": {
"batchUploadId": {
"type": "string"
}
}
},
"FileType": {
"enum": [
"Unknown",
Expand All @@ -250,6 +466,89 @@
"Audio"
]
},
"GetBatchUploadResultEndpoint_Output": {
"required": [
"batchUploadId",
"status",
"totalCount",
"completedCount",
"failedCount",
"items"
],
"type": "object",
"properties": {
"batchUploadId": {
"type": "string"
},
"status": {
"$ref": "#/components/schemas/BatchUploadStatus"
},
"totalCount": {
"type": "integer",
"format": "int32"
},
"completedCount": {
"type": "integer",
"format": "int32"
},
"failedCount": {
"type": "integer",
"format": "int32"
},
"items": {
"$ref": "#/components/schemas/ListOfGetBatchUploadResultEndpoint_UrlOutput"
}
}
},
"GetBatchUploadResultEndpoint_UrlOutput": {
"required": [
"url",
"status"
],
"type": "object",
"properties": {
"url": {
"type": "string"
},
"fileName": {
"type": "string",
"nullable": true
},
"status": {
"$ref": "#/components/schemas/BatchUploadUrlStatus"
},
"errorMessage": {
"type": "string",
"nullable": true
}
}
},
"GetBatchUploadStatusEndpoint_Output": {
"required": [
"status",
"totalCount",
"completedCount",
"failedCount"
],
"type": "object",
"properties": {
"status": {
"$ref": "#/components/schemas/BatchUploadStatus"
},
"totalCount": {
"type": "integer",
"format": "int32"
},
"completedCount": {
"type": "integer",
"format": "int32"
},
"failedCount": {
"type": "integer",
"format": "int32"
}
}
},
"GetFileMetadataResult": {
"required": [
"metadata"
Expand Down Expand Up @@ -536,6 +835,19 @@
}
}
},
"ListOfGetBatchUploadResultEndpoint_UrlOutput": {
"type": "array",
"items": {
"$ref": "#/components/schemas/GetBatchUploadResultEndpoint_UrlOutput"
}
},
"ListOfUri": {
"type": "array",
"items": {
"type": "string",
"format": "uri"
}
},
"MetadataCollection": {
"type": "object",
"additionalProperties": {
Expand Down Expand Up @@ -608,6 +920,40 @@
"format": "int64"
}
}
},
"ValidationProblemDetails": {
"type": "object",
"properties": {
"type": {
"type": "string",
"nullable": true
},
"title": {
"type": "string",
"nullable": true
},
"status": {
"type": "integer",
"format": "int32"
},
"detail": {
"type": "string",
"nullable": true
},
"instance": {
"type": "string",
"nullable": true
},
"errors": {
"type": "object",
"additionalProperties": {
"type": "array",
"items": {
"type": "string"
}
}
}
}
}
},
"securitySchemes": {
Expand Down
Loading