mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2026-07-11 20:01:38 +00:00
ABOVE NOT TESTED - Added sync endpoint
This commit is contained in:
parent
5e63efd810
commit
811893f0fe
3 changed files with 57 additions and 0 deletions
55
docs/controllers/SessionController.yaml
Normal file
55
docs/controllers/SessionController.yaml
Normal file
|
|
@ -0,0 +1,55 @@
|
||||||
|
paths:
|
||||||
|
/api/session/{id}/sync:
|
||||||
|
post:
|
||||||
|
operationId: syncOpenSession
|
||||||
|
summary: Sync an open session.
|
||||||
|
description: Sync an open session.
|
||||||
|
tags:
|
||||||
|
- Session
|
||||||
|
parameters:
|
||||||
|
- name: id
|
||||||
|
in: path
|
||||||
|
description: The ID of the session.
|
||||||
|
required: true
|
||||||
|
schema:
|
||||||
|
$ref: '../objects/entities/PlaybackSession.yaml#/components/schemas/playbackSessionId'
|
||||||
|
- name: currentTime
|
||||||
|
in: query
|
||||||
|
description: The current time of the session.
|
||||||
|
required: true
|
||||||
|
schema:
|
||||||
|
$ref: '../schemas.yaml#/components/schemas/durationSec'
|
||||||
|
- name: timeListened
|
||||||
|
in: query
|
||||||
|
description: The time listened to the session.
|
||||||
|
required: true
|
||||||
|
schema:
|
||||||
|
$ref: '../schemas.yaml#/components/schemas/durationSec'
|
||||||
|
- name: duration
|
||||||
|
in: query
|
||||||
|
description: The duration of the session.
|
||||||
|
required: true
|
||||||
|
schema:
|
||||||
|
$ref: '../schemas.yaml#/components/schemas/durationSec'
|
||||||
|
responses:
|
||||||
|
'200':
|
||||||
|
description: OK
|
||||||
|
content:
|
||||||
|
html/text:
|
||||||
|
schema:
|
||||||
|
type: string
|
||||||
|
example: OK
|
||||||
|
'404':
|
||||||
|
description: No listening session with the provided ID is open, or the session belongs to another user.
|
||||||
|
content:
|
||||||
|
html/text:
|
||||||
|
schema:
|
||||||
|
type: string
|
||||||
|
example: Not Found
|
||||||
|
'500':
|
||||||
|
description: There was an error syncing the session.
|
||||||
|
content:
|
||||||
|
html/text:
|
||||||
|
schema:
|
||||||
|
type: string
|
||||||
|
example: Internal Server Error
|
||||||
Binary file not shown.
|
|
@ -91,6 +91,8 @@ paths:
|
||||||
$ref: './controllers/MeController.yaml#/paths/~1api~1me~1progress~1{libraryItemId}~1{episodeId}'
|
$ref: './controllers/MeController.yaml#/paths/~1api~1me~1progress~1{libraryItemId}~1{episodeId}'
|
||||||
/api/me/progress/{mediaId}:
|
/api/me/progress/{mediaId}:
|
||||||
$ref: './controllers/MeController.yaml#/paths/~1api~1me~1progress~1{mediaId}'
|
$ref: './controllers/MeController.yaml#/paths/~1api~1me~1progress~1{mediaId}'
|
||||||
|
/api/session/{id}/sync:
|
||||||
|
$ref: './controllers/SessionController.yaml#/paths/~1api~1session~1{id}~1sync'
|
||||||
tags:
|
tags:
|
||||||
- name: Authors
|
- name: Authors
|
||||||
description: Author endpoints
|
description: Author endpoints
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue