From 3520d38515f5e83320ef4e54cb837b3b91fedf90 Mon Sep 17 00:00:00 2001 From: Arman Date: Thu, 26 Nov 2020 02:57:59 +0330 Subject: add My History API to openapi (#3363) Co-authored-by: Rigel Kent Co-authored-by: Rigel Kent --- support/doc/api/openapi.yaml | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) (limited to 'support/doc/api') diff --git a/support/doc/api/openapi.yaml b/support/doc/api/openapi.yaml index 4feca5d99..6dd51ec7c 100644 --- a/support/doc/api/openapi.yaml +++ b/support/doc/api/openapi.yaml @@ -70,6 +70,9 @@ tags: description: > Operations related to your subscriptions to video channels, their new videos, and how to keep up to date with their latest publications! + - name: My History + description: > + Operations related to your watch history. - name: My Notifications description: > Notifications following new videos, follows or reports. They allow you @@ -150,6 +153,7 @@ x-tagGroups: - My User - My Subscriptions - My Notifications + - My History - name: Videos tags: - Video @@ -917,6 +921,43 @@ paths: responses: '204': description: successful operation + /users/me/history/videos: + get: + summary: List watched videos history + security: + - OAuth2: [] + tags: + - My History + parameters: + - $ref: '#/components/parameters/start' + - $ref: '#/components/parameters/count' + responses: + '200': + description: successful operation + content: + application/json: + schema: + $ref: '#/components/schemas/VideoListResponse' + /users/me/history/videos/remove: + post: + summary: Clear video history + security: + - OAuth2: [] + tags: + - My History + requestBody: + content: + multipart/form-data: + schema: + type: object + properties: + beforeDate: + description: history before this date will be deleted + type: string + format: date-time + responses: + '204': + description: successful operation /users/me/avatar/pick: post: summary: Update my user avatar -- cgit v1.2.3