Загрузка данных
uploadExportedFile.yaml
asyncapi: 3.0.0
info:
title: API Gateway Websockets API for upload exported files
version: '1.0.0'
description: WebSockets API for API-GW
servers:
prod:
host: localhost
pathname: "/"
protocol: https
description: |
Public server available without authorization.
Once the socket is open you can get to a public channel by sending
a get request message.
develop:
host: "192.168.1.1"
pathname: "/"
protocol: wss
description: |
Public server available without authorization.
Once the socket is open you can get to a public channel by sending
a get request message.
channels:
ldsMain:
address: "/hub"
messages:
uploadExportedFileRequest:
$ref: '#/components/messages/uploadExportedFileRequest'
uploadExportedFileReply:
$ref: '#/components/messages/uploadExportedFileReply'
operations:
uploadExportedFile:
title: uploadExportedFile
description: >
Метод позволяет скачать (выгрузить) сформированный файл.
action: send
channel:
$ref: '#/channels/ldsMain'
messages:
- $ref: '#/channels/ldsMain/messages/uploadExportedFileRequest'
reply:
messages:
- $ref: '#/channels/ldsMain/messages/uploadExportedFileReply'
components:
messages:
uploadExportedFileRequest:
title: uploadExportedFileRequest
summary: Запрос позволяет скачать (выгрузить) сформированный файл.
payload:
$ref: '#/components/schemas/uploadExportedFileRequest'
x-response:
$ref: '#/components/schemas/uploadExportedFileReply'
uploadExportedFileReply:
title: uploadExportedFileReply
summary: Ответ на запрос uploadExportedFileRequest
payload:
$ref: '#/components/schemas/uploadExportedFileReply'
schemas:
uploadExportedFileRequest:
title: uploadExportedFileRequest
description: Метод позволяет скачать (выгрузить) сформированный файл.
type: object
properties:
file:
title: file
description: Информация о файле
type: object
items:
$ref: '#/components/schemas/file'
required: [file]
uploadExportedFileReply:
title: uploadExportedFileReply
description: Ответ на запрос uploadExportedFileRequest
type: object
properties:
replyStatus:
$ref: '#/components/schemas/replyStatus'
replyErrors:
$ref: '#/components/schemas/replyErrors'
required: [replyStatus]
file:
title: file
description: Информация о файле
type: object
properties:
id:
title: id
description: Идентификатор файла
type: integer
name:
title: name
description: Наименование файла
type: string
replyStatus:
title: replyStatus
type: integer
format: int32
enum:
- 200
- 400
- 401
- 403
- 404
- 408
- 409
- 412
- 416
- 429
- 500
- 501
- 503
- 504
- 520
x-enumNames:
"200": OK
"400": Bad request
"401": Unauthorized
"403": Permission denied
"404": Not found
"408": Request timeout
"409": Conflict
"412": Precondition failed
"416": Range not satisfiable
"429": Too many requests
"500": Internal server error
"501": Not implemented
"503": Service unavailable
"504": Gateway timeout
"520": Unknown error
replyErrors:
title: replyErrors
type: array
items:
description: Информация об ошибке
type: object
properties:
errorType:
title: errorType
description: Тип ошибки
type: string
examples: [ INVALID_ARGUMENT ]
reason:
title: reason
description: Причина ошибки
type: string
examples: [ Значение должно лежать в пределах от 0 до 200 ]
location:
title: location
description: Место возникновения ошибки
type: string
examples: [ maxVolume ]
required: [reason]