-
Notifications
You must be signed in to change notification settings - Fork 7
Endpoints
Victor edited this page Apr 27, 2019
·
5 revisions
old | new | new method |
---|---|---|
/login | /login | post |
/createaccount | /user | post |
/topicposts | /topic/:hash | get |
/post | /post/:hash | get |
/postcontent | /post/:hash/content | get |
/topics | /topics | get |
/squashedits | /post/:hash/squash | put |
/search | /search | TBD |
/submitpost | /post | post |
/editpost | /post/:hash | put |
/forceeditpost | /post/:hash/forcesave | put |
/editcontent | /post/:hash/editcontent | get |
/submittopic | /topic | post |
/allusers | /user | get |
/unverifiedposts | /post/unverified | get |
/wipposts | /post/wip | get |
TBD |
---|
/verifytoken |
/verifyemail |
/forgotpassword |
/forgotpasswordemail |
/dashboard |
/changepassword |
/changeavatar |
/postsettings |
/profile |
Endpoint to get a list of topics.
With an optional header topicVersion
with which the local version can be specified and if the version does not differ on the server the server returns 304
- 200: with the topics
- 304 Not modified: if topicVersion matches server
Gets a list of postHashes pertaining to that specific topic
- 200: with the postHashes of the topic
- 404: If the topic does not exist
Endpoint to create a new topic.
- 201 Created: If created succesfully
- 401 Unauthorized: If user is not logged in.
- 403 Forbidden: If user is not a admin
- 409 Conflict: If it conflicts
Create a new post
- 201 Created: If created succesfully
- 401 Unauthorized: If user is not logged in.
- 409 Conflict: If it conflicts
Gets the data (info) of all wip posts
- 200: With the info
Gets the data (info) of all unverified post
- 200: With the info
Gets the data (info) of a post
- 200: With the info
- 404: If post does not exist (or is hidden for the user)
Saves a post
- 200: Post has been succesfully saved
- 401 Unauthorized: If user is not logged in.
- 403 Forbidden: If user is not a admin
- 404: If post does not exist
Gets the content of a post
- 200: With the content
- 404: If post does not exist (or is hidden for the user)
Gets the editcontent of a post
- 200: With the editcontent
- 404: If post does not exist (or is hidden for the user)
Squashes given edits of the specific post
- 200: If succesful
Forcefully saves the given post
- 200: If succesful
Login with given credentials, sets a cookie with the jwt token
- 200: on Success
- 401 Unauthorized: Wrong password/username
Create a new user
- 200: on success
- 409: User already exists
//TODO complete
//TODO