PodcastBase schema update

This commit is contained in:
Nicholas Wallace 2024-02-27 01:36:00 +00:00
parent 211b42221e
commit 0b95c856b5

View file

@ -8,26 +8,15 @@ const { filePathToPOSIX } = require('../../utils/fileUtils')
* @openapi * @openapi
* components: * components:
* schemas: * schemas:
* podcast: * podcastBase:
* type: object * type: object
* properties: * properties:
* libraryItemId:
* description: The ID of the library item that contains the podcast.
* type: string
* example: li_bufnnmp4y5o2gbbxfm
* metadata:
* $ref: '#/components/schemas/podcastMetadata'
* coverPath: * coverPath:
* description: The absolute path on the server of the cover file. Will be null if there is no cover. * description: The absolute path on the server of the cover file. Will be null if there is no cover.
* type: [string, 'null'] * type: [string, 'null']
* example: /podcasts/Welcome to Night Vale/cover.jpg * example: /podcasts/Welcome to Night Vale/cover.jpg
* tags: * tags:
* $ref: '#/components/schemas/tags' * $ref: '#/components/schemas/tags'
* episodes:
* description: The downloaded episodes of the podcast.
* type: array
* items:
* $ref: '#/components/schemas/podcastEpisode'
* autoDownloadEpisodes: * autoDownloadEpisodes:
* description: Whether the server will automatically download podcast episodes according to the schedule. * description: Whether the server will automatically download podcast episodes according to the schedule.
* type: boolean * type: boolean
@ -48,15 +37,27 @@ const { filePathToPOSIX } = require('../../utils/fileUtils')
* description: The maximum number of podcast episodes to download when automatically downloading new episodes. If 0, all episodes will be downloaded. * description: The maximum number of podcast episodes to download when automatically downloading new episodes. If 0, all episodes will be downloaded.
* type: integer * type: integer
* example: 3 * example: 3
* podcast:
* type: object
* description: A podcast on the server
* allOf:
* - $ref: '#/components/schemas/podcastBase'
* - type: object
* properties:
* libraryItemId:
* $ref: '#/components/schemas/libraryItemId'
* metadata:
* $ref: '#/components/schemas/podcastMetadata'
* episodes:
* description: The downloaded episodes of the podcast.
* type: array
* items:
* $ref: '#/components/schemas/podcastEpisode'
* podcastMinified: * podcastMinified:
* type: object * type: object
* properties: * properties:
* libraryItemId:
* description: The ID of the library item that contains the podcast.
* type: string
* example: li_bufnnmp4y5o2gbbxfm
* metadata: * metadata:
* $ref: '#/components/schemas/podcastMetadata' * $ref: '#/components/schemas/podcastMetadataMinified'
* coverPath: * coverPath:
* description: The absolute path on the server of the cover file. Will be null if there is no cover. * description: The absolute path on the server of the cover file. Will be null if there is no cover.
* type: [string, 'null'] * type: [string, 'null']