-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathswagger.yml
111 lines (110 loc) · 3.16 KB
/
swagger.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
openapi: 3.0.3
info:
title: FFMPEG Microservice
description: |-
FFMPEG file conversion microservice API documentation
contact:
email: [email protected]
license:
name: MIT
url: https://opensource.org/license/mit/
version: 0.1.0
servers:
- url: https:///api/v3
paths:
/convert:
post:
summary: Convert a media file (video or audio) and get response as stream
description: Convert a media file and return as stream
operationId: covert
parameters:
- name: input_options
in: query
required: false
schema:
type: string
- name: output_options
in: query
required: true
example: -f mp3
schema:
type: string
- name: buffer_size
in: query
required: false
example: 524288
schema:
type: integer
requestBody:
description: File to upload for conversion
content:
form/multipart-data:
schema:
type: object
properties:
file:
type: string
format: binary
encoding: # The same level as schema
file: # Property name (see above)
contentType: audio/*, video/*
required: true
responses:
'200':
description: Successful operation
content:
application/octet-stream:
schema:
type: string
format: binary
'413':
description: file to convert is larger than upload size limit
'422':
description: Unprocessable entity when either file in body or action in query parameters is not available
/convert-file:
post:
summary: Convert a media file (video or audio) and get response as file
description: Convert a media file and return as file
operationId: covert_file
parameters:
- name: input_options
in: query
required: false
schema:
type: string
- name: output_options
in: query
required: true
example: -f mp3
schema:
type: string
requestBody:
description: File to upload for conversion
content:
form/multipart-data:
schema:
type: object
properties:
file:
type: string
format: binary
encoding: # The same level as schema
file: # Property name (see above)
contentType: audio/*, video/*
required: true
responses:
'200':
description: Successful operation
content:
audio/*:
schema:
type: string
format: binary
video/*:
schema:
type: string
format: binary
'413':
description: file to convert is larger than upload size limit
'422':
description: Unprocessable entity when either file in body or action in query parameters is not available