1. Getting started
This is for commenting on a post.
2. General use
API Path |
/API/post/comment.php |
Request |
POST |
requires login |
true |
needs database |
true |
needs config |
true |
output |
JSON |
3. Input
Takes 2 POST inputs:
post |
uuid for the post |
comment |
comment to post on |
4. Output
4.1. Default
If everything worked, the server will reply with:
{
"comment": true
}
4.2. Error
4.2.1. User permission
This response will be sent, when the user does not have any permission to comment.
{
"error": "No permission to comment"
}
4.2.2. Post does not exist
This response will be sent if the post does not exist
{
"error": "Post does not exist"
}
4.2.3. Else
All other errors will be sent in the following format:
{
"error": (1)
}
ErrorMessage