From b874e9251e00961f295e4c409e1b34da89fab4ed Mon Sep 17 00:00:00 2001 From: Vyr Cossont Date: Sat, 29 Jul 2023 03:49:14 -0700 Subject: [feature] Implement markers API (#1989) * Implement markers API Fixes #1856 * Correct import grouping in markers files * Regenerate Swagger for markers API * Shorten names for readability * Cache markers for 6 hours * Update DB ref * Update envparsing.sh --- docs/api/swagger.yaml | 66 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) (limited to 'docs/api') diff --git a/docs/api/swagger.yaml b/docs/api/swagger.yaml index db1d136b8..eb708219e 100644 --- a/docs/api/swagger.yaml +++ b/docs/api/swagger.yaml @@ -4988,6 +4988,72 @@ paths: summary: Add one or more accounts to the given list. tags: - lists + /api/v1/markers: + get: + description: Get timeline markers by name + operationId: markersGet + parameters: + - description: Timelines to retrieve. + in: query + items: + enum: + - home + - notifications + type: string + name: timeline + type: array + produces: + - application/json + responses: + "200": + description: Requested markers + schema: + $ref: '#/definitions/markers' + "400": + description: bad request + "401": + description: unauthorized + "500": + description: internal server error + security: + - OAuth2 Bearer: + - read:statuses + tags: + - markers + post: + consumes: + - multipart/form-data + description: Update timeline markers by name + operationId: markersPost + parameters: + - description: Last status ID read on the home timeline. + in: formData + name: home[last_read_id] + type: string + - description: Last notification ID read on the notifications timeline. + in: formData + name: notifications[last_read_id] + type: string + produces: + - application/json + responses: + "200": + description: Requested markers + schema: + $ref: '#/definitions/markers' + "400": + description: bad request + "401": + description: unauthorized + "409": + description: conflict (when two clients try to update the same timeline at the same time) + "500": + description: internal server error + security: + - OAuth2 Bearer: + - write:statuses + tags: + - markers /api/v1/media/{id}: get: operationId: mediaGet -- cgit v1.2.3