fix video playlistId/videoId for video playlists in openapi spec

closes #4081
This commit is contained in:
Rigel Kent 2021-05-12 14:33:04 +02:00
parent 16c016e8b1
commit c00100b607
No known key found for this signature in database
GPG Key ID: 5E53E96A494E452F

View File

@ -1976,10 +1976,12 @@ paths:
- $ref: '#/components/schemas/Video/properties/id'
startAt:
type: integer
format: seconds
description: Timestamp in the video that marks the beginning of the report
minimum: 0
endAt:
type: integer
format: seconds
description: Timestamp in the video that marks the ending of the report
minimum: 0
comment:
@ -2564,13 +2566,13 @@ paths:
thumbnailfile:
contentType: image/jpeg
/video-playlists/{id}:
/video-playlists/{playlistId}:
get:
summary: Get a video playlist
tags:
- Video Playlists
parameters:
- $ref: '#/components/parameters/idOrUUID'
- $ref: '#/components/parameters/playlistId'
responses:
'200':
description: successful operation
@ -2589,7 +2591,7 @@ paths:
'204':
description: successful operation
parameters:
- $ref: '#/components/parameters/idOrUUID'
- $ref: '#/components/parameters/playlistId'
requestBody:
content:
multipart/form-data:
@ -2624,19 +2626,19 @@ paths:
tags:
- Video Playlists
parameters:
- $ref: '#/components/parameters/idOrUUID'
- $ref: '#/components/parameters/playlistId'
responses:
'204':
description: successful operation
/video-playlists/{id}/videos:
/video-playlists/{playlistId}/videos:
get:
summary: 'List videos of a playlist'
tags:
- Videos
- Video Playlists
parameters:
- $ref: '#/components/parameters/idOrUUID'
- $ref: '#/components/parameters/playlistId'
responses:
'200':
description: successful operation
@ -2645,14 +2647,14 @@ paths:
schema:
$ref: '#/components/schemas/VideoListResponse'
post:
summary: 'Add a video in a playlist'
summary: Add a video in a playlist
security:
- OAuth2: []
tags:
- Videos
- Video Playlists
parameters:
- $ref: '#/components/parameters/idOrUUID'
- $ref: '#/components/parameters/playlistId'
responses:
'200':
description: successful operation
@ -2666,6 +2668,7 @@ paths:
properties:
id:
type: integer
example: 2
requestBody:
content:
application/json:
@ -2673,19 +2676,22 @@ paths:
type: object
properties:
videoId:
allOf:
oneOf:
- $ref: '#/components/schemas/Video/properties/uuid'
- $ref: '#/components/schemas/Video/properties/id'
description: Video to add in the playlist
startTimestamp:
type: integer
description: Start the video at this specific timestamp (in seconds)
format: seconds
description: Start the video at this specific timestamp
stopTimestamp:
type: integer
description: Stop the video at this specific timestamp (in seconds)
format: seconds
description: Stop the video at this specific timestamp
required:
- videoId
/video-playlists/{id}/videos/reorder:
/video-playlists/{playlistId}/videos/reorder:
post:
summary: 'Reorder a playlist'
security:
@ -2693,7 +2699,7 @@ paths:
tags:
- Video Playlists
parameters:
- $ref: '#/components/parameters/idOrUUID'
- $ref: '#/components/parameters/playlistId'
responses:
'204':
description: successful operation
@ -2719,15 +2725,15 @@ paths:
- startPosition
- insertAfterPosition
/video-playlists/{id}/videos/{playlistElementId}:
/video-playlists/{playlistId}/videos/{playlistElementId}:
put:
summary: 'Update a playlist element'
summary: Update a playlist element
security:
- OAuth2: []
tags:
- Video Playlists
parameters:
- $ref: '#/components/parameters/idOrUUID'
- $ref: '#/components/parameters/playlistId'
- $ref: '#/components/parameters/playlistElementId'
responses:
'204':
@ -2740,18 +2746,20 @@ paths:
properties:
startTimestamp:
type: integer
description: 'Start the video at this specific timestamp (in seconds)'
format: seconds
description: Start the video at this specific timestamp
stopTimestamp:
type: integer
description: 'Stop the video at this specific timestamp (in seconds)'
format: seconds
description: Stop the video at this specific timestamp
delete:
summary: 'Delete an element from a playlist'
summary: Delete an element from a playlist
security:
- OAuth2: []
tags:
- Video Playlists
parameters:
- $ref: '#/components/parameters/idOrUUID'
- $ref: '#/components/parameters/playlistId'
- $ref: '#/components/parameters/playlistElementId'
responses:
'204':
@ -2759,7 +2767,7 @@ paths:
'/users/me/video-playlists/videos-exist':
get:
summary: 'Check video exists in my playlists'
summary: Check video exists in my playlists
security:
- OAuth2: []
tags:
@ -2792,8 +2800,10 @@ paths:
type: integer
startTimestamp:
type: integer
format: seconds
stopTimestamp:
type: integer
format: seconds
'/accounts/{name}/video-channels':
get:
@ -3984,6 +3994,13 @@ components:
oneOf:
- $ref: '#/components/schemas/id'
- $ref: '#/components/schemas/UUIDv4'
playlistId:
name: playlistId
in: path
required: true
description: Playlist id
schema:
$ref: '#/components/schemas/VideoPlaylist/properties/id'
playlistElementId:
name: playlistElementId
in: path
@ -4447,8 +4464,10 @@ components:
type: integer
startTimestamp:
type: integer
format: seconds
stopTimestamp:
type: integer
format: seconds
video:
nullable: true
allOf:
@ -4597,6 +4616,7 @@ components:
duration:
type: integer
example: 1419
format: seconds
description: duration of the video in seconds
isLocal:
type: boolean
@ -5091,6 +5111,7 @@ components:
properties:
currentTime:
type: integer
format: seconds
description: timestamp within the video, in seconds
example: 5
ServerConfig: