allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hei...@apache.org
Subject [4/6] allura git commit: Make search term required, and provide example (API returns no results if no q param)
Date Tue, 01 Sep 2015 15:11:28 GMT
Make search term required, and provide example (API returns no results if no q param)


Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/9622f7ba
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/9622f7ba
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/9622f7ba

Branch: refs/heads/master
Commit: 9622f7ba13a77a4d71e28ce005584ee89124f41f
Parents: 1baf0ea
Author: Dave Brondsema <dbrondsema@slashdotmedia.com>
Authored: Thu Aug 27 18:03:32 2015 +0000
Committer: Dave Brondsema <dbrondsema@slashdotmedia.com>
Committed: Thu Aug 27 18:03:32 2015 +0000

----------------------------------------------------------------------
 Allura/docs/api-rest/api.raml           | 8 +++++---
 Allura/docs/api-rest/resourceTypes.yaml | 2 ++
 2 files changed, 7 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/9622f7ba/Allura/docs/api-rest/api.raml
----------------------------------------------------------------------
diff --git a/Allura/docs/api-rest/api.raml b/Allura/docs/api-rest/api.raml
index 5248f7d..244c5db 100755
--- a/Allura/docs/api-rest/api.raml
+++ b/Allura/docs/api-rest/api.raml
@@ -228,9 +228,11 @@ documentation:
         /search:
           type: {
             searchableCollection: {
-            queryParamName: q,
-            schema: !include schemas/searchedTickets.json,
-            example: !include examples/searchedTickets.json
+              queryParamName: q,
+              queryParamExample: 'example',
+              queryRequired: true,
+              schema: !include schemas/searchedTickets.json,
+              example: !include examples/searchedTickets.json
             }
           }
           is: [ pageable]

http://git-wip-us.apache.org/repos/asf/allura/blob/9622f7ba/Allura/docs/api-rest/resourceTypes.yaml
----------------------------------------------------------------------
diff --git a/Allura/docs/api-rest/resourceTypes.yaml b/Allura/docs/api-rest/resourceTypes.yaml
index 31ef72e..f6324de 100755
--- a/Allura/docs/api-rest/resourceTypes.yaml
+++ b/Allura/docs/api-rest/resourceTypes.yaml
@@ -72,6 +72,8 @@
       queryParameters:
         <<queryParamName>>:
           description: Return <<resourcePathName>> that have their <<queryParamName>>
matching the given value
+          example: <<queryParamExample>>
+          required: <<queryRequired>>
       responses:
         200:
           body:


Mime
View raw message