Cleaned up libraryId schema definition

This commit is contained in:
Nicholas Wallace 2024-02-19 21:39:26 +00:00
parent 9bb264ac43
commit 4fff661834

View file

@ -2,14 +2,26 @@
* @openapi * @openapi
* components: * components:
* schemas: * schemas:
* oldLibraryId:
* type: string
* description: The ID of the libraries created on server version 2.2.23 and before.
* format: "lib_[a-z0-9]{18}"
* examples:
* - lib_o78uaoeuh78h6aoeif
* - lib_74obqytfms9o8oeumg
* libraryId:
* type: string
* description: The library ID for any libraries after 2.3.0.
* format: uuid
* example:
* - e4bb1afb-4a4f-4dd6-8be0-e615d233185b
* library: * library:
* type: object * type: object
* properties: * properties:
* id: * id:
* type: string * oneOf:
* description: The ID of the library. (Read Only) * - $ref: '#/components/schemas/oldLibraryId'
* example: * - $ref: '#/components/schemas/libraryId'
* - lib_c1u6t4p45c35rf0nzd
* name: * name:
* type: string * type: string
* description: The name of the library. * description: The name of the library.
@ -138,10 +150,9 @@
* example: * example:
* - /podcasts * - /podcasts
* libraryId: * libraryId:
* description: The ID of the library the folder belongs to. (Read Only) * oneOf:
* type: string * - $ref: '#/components/schemas/oldLibraryId'
* example: * - $ref: '#/components/schemas/libraryId'
* - lib_c1u6t4p45c35rf0nzd
* addedAt: * addedAt:
* description: The time (in ms since POSIX epoch) when the folder was added. (Read Only) * description: The time (in ms since POSIX epoch) when the folder was added. (Read Only)
* type: integer * type: integer
@ -157,8 +168,9 @@
* description: The inode of the library item. * description: The inode of the library item.
* type: string * type: string
* libraryId: * libraryId:
* description: The ID of the library the item belongs to. * oneOf:
* type: string * - $ref: '#/components/schemas/oldLibraryId'
* - $ref: '#/components/schemas/libraryId'
* folderId: * folderId:
* description: The ID of the folder the library item is in. * description: The ID of the folder the library item is in.
* type: string * type: string
@ -225,10 +237,9 @@
* example: * example:
* - '649641337522215266' * - '649641337522215266'
* libraryId: * libraryId:
* description: The ID of the library the item belongs to. * oneOf:
* type: string * - $ref: '#/components/schemas/oldLibraryId'
* example: * - $ref: '#/components/schemas/libraryId'
* - lib_c1u6t4p45c35rf0nzd
* folderId: * folderId:
* description: The ID of the folder the library item is in. * description: The ID of the folder the library item is in.
* type: string * type: string
@ -320,10 +331,9 @@
* example: * example:
* - '649641337522215266' * - '649641337522215266'
* libraryId: * libraryId:
* description: The ID of the library the item belongs to. * oneOf:
* type: string * - $ref: '#/components/schemas/oldLibraryId'
* example: * - $ref: '#/components/schemas/libraryId'
* - lib_c1u6t4p45c35rf0nzd
* folderId: * folderId:
* description: The ID of the folder the library item is in. * description: The ID of the folder the library item is in.
* type: string * type: string
@ -1510,10 +1520,9 @@
* example: * example:
* - li_bufnnmp4y5o2gbbxfm * - li_bufnnmp4y5o2gbbxfm
* libraryId: * libraryId:
* description: The ID of the library the episode's podcast belongs to. * oneOf:
* type: string * - $ref: '#/components/schemas/oldLibraryId'
* example: * - $ref: '#/components/schemas/libraryId'
* - lib_p9wkw2i85qy9oltijt
* isFinished: * isFinished:
* description: Whether the episode has finished downloading. * description: Whether the episode has finished downloading.
* type: boolean * type: boolean
@ -2285,10 +2294,9 @@
* example: * example:
* - pl_qbwet64998s5ra6dcu * - pl_qbwet64998s5ra6dcu
* libraryId: * libraryId:
* description: The ID of the library the playlist belongs to. * oneOf:
* type: string * - $ref: '#/components/schemas/oldLibraryId'
* example: * - $ref: '#/components/schemas/libraryId'
* - lib_c1u6t4p45c35rf0nzd
* userId: * userId:
* description: The ID of the user the playlist belongs to. * description: The ID of the user the playlist belongs to.
* type: string * type: string
@ -2329,10 +2337,9 @@
* example: * example:
* - pl_qbwet64998s5ra6dcu * - pl_qbwet64998s5ra6dcu
* libraryId: * libraryId:
* description: The ID of the library the playlist belongs to. * oneOf:
* type: string * - $ref: '#/components/schemas/oldLibraryId'
* example: * - $ref: '#/components/schemas/libraryId'
* - lib_c1u6t4p45c35rf0nzd
* userId: * userId:
* description: The ID of the user the playlist belongs to. * description: The ID of the user the playlist belongs to.
* type: string * type: string
@ -2530,10 +2537,9 @@
* example: * example:
* - root * - root
* libraryId: * libraryId:
* description: The ID of the library that contains the library item. * oneOf:
* type: string * - $ref: '#/components/schemas/oldLibraryId'
* example: * - $ref: '#/components/schemas/libraryId'
* - lib_p9wkw2i85qy9oltijt
* libraryItemId: * libraryItemId:
* description: The ID of the library item. * description: The ID of the library item.
* type: string * type: string
@ -2648,10 +2654,9 @@
* example: * example:
* - root * - root
* libraryId: * libraryId:
* description: The ID of the library that contains the library item. * oneOf:
* type: string * - $ref: '#/components/schemas/oldLibraryId'
* example: * - $ref: '#/components/schemas/libraryId'
* - lib_p9wkw2i85qy9oltijt
* libraryItemId: * libraryItemId:
* description: The ID of the library item. * description: The ID of the library item.
* type: string * type: string