Skip to content

Commit

Permalink
added openapi documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
KesterTan committed Sep 24, 2024
1 parent 95c1bd5 commit 653c107
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 1 deletion.
4 changes: 3 additions & 1 deletion public/openapi/write.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,8 @@ paths:
$ref: 'write/posts/pid/upvoters.yaml'
/posts/{pid}/bookmark:
$ref: 'write/posts/pid/bookmark.yaml'
/posts/{pid}/verify:
$ref: 'write/posts/pid/verify.yaml'
/posts/{pid}/diffs:
$ref: 'write/posts/pid/diffs.yaml'
/posts/{pid}/diffs/{since}:
Expand Down Expand Up @@ -261,4 +263,4 @@ paths:
/files/:
$ref: 'write/files.yaml'
/files/folder:
$ref: 'write/files/folder.yaml'
$ref: 'write/files/folder.yaml'
26 changes: 26 additions & 0 deletions public/openapi/write/posts/pid/verify.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
put:
tags:
- posts
summary: verifies a post
description: This operation verifies a post.
parameters:
- in: path
name: pid
schema:
type: string
required: true
description: a valid post id
example: 2
responses:
'200':
description: Post successfully verified
content:
application/json:
schema:
type: object
properties:
status:
$ref: ../../../components/schemas/Status.yaml#/Status
response:
type: object
properties: {}

0 comments on commit 653c107

Please sign in to comment.