diff --git a/swagger.yaml b/swagger.yaml index b4a8129..3ebeb99 100644 --- a/swagger.yaml +++ b/swagger.yaml @@ -872,6 +872,12 @@ components: description: The number of videos in the playlist. SearchItem: type: object + discriminator: + propertyName: type + mapping: + stream: "#/components/schemas/StreamItem" + channel: "#/components/schemas/ChannelItem" + playlist: "#/components/schemas/PlaylistItem" oneOf: - $ref: "#/components/schemas/StreamItem" - $ref: "#/components/schemas/ChannelItem"