From f88a2eae9777e0be612647bc17227c1ca13616ba Mon Sep 17 00:00:00 2001 From: 6543 <6543@obermui.de> Date: Mon, 23 Nov 2020 21:49:36 +0100 Subject: [API] Add more filters to issues search (#13514) * Add time filter for issue search * Add limit option for paggination * Add Filter for: Created by User, Assigned to User, Mentioning User * update swagger * Add Tests for limit, before & since --- templates/swagger/v1_json.tmpl | 40 +++++++++++++++++++++++++++++++++++++++- 1 file changed, 39 insertions(+), 1 deletion(-) (limited to 'templates/swagger') diff --git a/templates/swagger/v1_json.tmpl b/templates/swagger/v1_json.tmpl index 9d775da7d6..8bcfc43d73 100644 --- a/templates/swagger/v1_json.tmpl +++ b/templates/swagger/v1_json.tmpl @@ -1879,11 +1879,49 @@ "name": "type", "in": "query" }, + { + "type": "string", + "format": "date-time", + "description": "Only show notifications updated after the given time. This is a timestamp in RFC 3339 format", + "name": "since", + "in": "query" + }, + { + "type": "string", + "format": "date-time", + "description": "Only show notifications updated before the given time. This is a timestamp in RFC 3339 format", + "name": "before", + "in": "query" + }, + { + "type": "boolean", + "description": "filter (issues / pulls) assigned to you, default is false", + "name": "assigned", + "in": "query" + }, + { + "type": "boolean", + "description": "filter (issues / pulls) created by you, default is false", + "name": "created", + "in": "query" + }, + { + "type": "boolean", + "description": "filter (issues / pulls) mentioning you, default is false", + "name": "mentioned", + "in": "query" + }, { "type": "integer", - "description": "page number of requested issues", + "description": "page number of results to return (1-based)", "name": "page", "in": "query" + }, + { + "type": "integer", + "description": "page size of results", + "name": "limit", + "in": "query" } ], "responses": { -- cgit v1.2.3