allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hei...@apache.org
Subject [06/13] allura git commit: [#6797] fix incorrect includes. Combine forum & discussion endpoints into one and fix up
Date Fri, 14 Aug 2015 16:11:16 GMT
[#6797] fix incorrect includes.  Combine forum & discussion endpoints into one and fix
up


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

Branch: refs/heads/hs/6797
Commit: 92717482b51ac334eac349aa4ab32b7905b818dd
Parents: 7af8677
Author: Dave Brondsema <dave@brondsema.net>
Authored: Mon Aug 10 18:30:01 2015 -0400
Committer: Heith Seewald <hseewald@hsmb.local>
Committed: Fri Aug 14 09:35:28 2015 -0400

----------------------------------------------------------------------
 Allura/docs/api-rest/api.raml | 105 ++++++++++++++++---------------------
 1 file changed, 45 insertions(+), 60 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/92717482/Allura/docs/api-rest/api.raml
----------------------------------------------------------------------
diff --git a/Allura/docs/api-rest/api.raml b/Allura/docs/api-rest/api.raml
index b123871..78402a2 100755
--- a/Allura/docs/api-rest/api.raml
+++ b/Allura/docs/api-rest/api.raml
@@ -115,12 +115,6 @@ baseUriParameters:
         get:
           description: |
             Returns a list of posts, including title and API url.
-          responses:
-            200:
-              body:
-                application/json:
-                  schema: !include schemas/blog.json
-                  example: !include examples/blog.json
         post:
           description: |
             Creates a new blog post.
@@ -208,74 +202,37 @@ baseUriParameters:
                 default: read
                 enum: [admin, configure, moderate, post, unmoderated_post, read, write]
 
-      /{forum}:
-        description: |
-          A list of forums
-        type: {
-            tool: {
-            example: !include examples/page.json,
-            schema: !include schemas/page.json
-            }
-          }
-
-        displayName: forum
-        uriParameters:
-         forum:
-           displayName: Forum Name
-           type: string
-           example: general
-           description: |
-             Returns a list of forums, including name, description, num_posts, API URL, and
last_post details
-
-             To view more than 100 threads, or 100 posts in a thread, use the pagination
support of the API by adding ?page=1 etc. to the URL.
-
-        /forum:
-          description: |
-            returns a limited list of topics in the forum, with fields for subject, num_replies,
API URL, and last_post
-          get:
-          /{slug}:
-            description: |
-              returns a limited list of posts in the thread, with fields for author, text,
and timestamp. Nested posts (i.e. a reply to a post) can be determined by the slug structure.
For example, "slug": "0a0b/9f00" is a reply to the post with "slug": "0a0b"
-            get:
-
-        /has_access:
-          type: permission
-          get:
-            queryParameters:
-              perm:
-                displayName: Permission
-                required: true
-                type: string
-                example: post
-                default: read
-                enum: [admin, configure, moderate, post, unmoderated_post, read]
-
       /{discussion}:
         description: |
           Represents the **Discussion Tool**.
         type: {
-            tool: {
+          tool: {
             schema: !include schemas/discussion.json,
             example: !include examples/discussion.json
-
             }
           }
 
         displayName: Discussion
         uriParameters:
          discussion:
-           displayName: Discussion Name
+           displayName: Discussion Tool Name
            type: string
            example: "discussion"
+        get:
+          description: |
+            Returns a list of forums, including name, description, num_topics, and last_post
details
+          is: [pageable]
 
         /{forum}:
+          description: |
+            Represents a forum within a Discussion tool.
           type: {
-              tool: {
-                example: !include examples/page.json,
-                schema: !include schemas/page.json
-              }
+            tool: {
+              # FIXME
+              example: !include examples/page.json,
+              schema: !include schemas/page.json
             }
-
+          }
           displayName: forum
           uriParameters:
            forum:
@@ -283,8 +240,31 @@ baseUriParameters:
              type: string
              example: general
 
+          get:
+            is: [pageable]
+            description: |
+              returns a limited list of topics in the forum, with fields for subject, num_replies,
API URL, and last_post
+              To view more than 100 threads, or 100 posts in a thread, use the pagination
support of the API by adding ?page=1 etc. to the URL.
+
+          /thread/{thread}:
+            description: |
+              Represents a thread of posts.
+            get:
+              is: [pageable]
+              description: |
+                returns a list of posts in the thread, with fields for author, text, and
timestamp. Nested posts (i.e. a reply to a post) can be determined by the slug structure.
For example, "slug": "0a0b/9f00" is a reply to the post with "slug": "0a0b"
+
         /has_access:
           type: permission
+          get:
+            queryParameters:
+              perm:
+                displayName: Permission
+                required: true
+                type: string
+                example: post
+                default: read
+                enum: [admin, configure, moderate, post, unmoderated_post, read]
 
       /{wiki}:
         description: |
@@ -355,7 +335,7 @@ baseUriParameters:
         type: {
             tool: {
             example: !include examples/tickets.json,
-            schema: !include schemas/ticket.json
+            schema: !include schemas/tickets.json
             }
           }
         is: [pageable]
@@ -470,7 +450,6 @@ baseUriParameters:
             tool: {
             example: !include examples/ticket.json,
             schema: !include schemas/ticket.json
-
             }
           }
           displayName: Ticket Number
@@ -557,7 +536,7 @@ baseUriParameters:
             type: {
               typedCollection: {
               example: !include examples/webhooks.json,
-              schema: !include schemas/webhook.json
+              schema: !include schemas/webhooks.json
               }
             }
             description: |
@@ -585,6 +564,12 @@ baseUriParameters:
                         required: true
                         type: string
               /{id}:
+                type: {
+                  tool: {
+                  example: !include examples/webhook.json,
+                  schema: !include schemas/webhook.json
+                  }
+                }
                 uriParameters:
                   id:
                     type: string
@@ -634,7 +619,7 @@ baseUriParameters:
                     type: string
                   mount_point:
                     description: |
-                      The section of the url relitive to your project. For example: /p/your_project/{mount_point}
+                      The section of the url relative to your project. For example: /p/your_project/{mount_point}
                     example: git
                     type: string
                     required: true


Mime
View raw message