Report a Node

You can use this API request to report a node that has violated your AnswerHub site's terms of agreement. The reported node will show up in Content > Manage > Reported in the admin dashboard.

/services/v2/node/[nodeId]/report.json?prompt=[data]

You can use the following parameters in your report a node request:

Specific: prompt
Other options: wrap

🚧

Permissions & Notes:

  • You must have the Report any question/answer/comment permission under Other Standard Roles in the Advanced Editor.

  • Use the mandatory request parameter prompt to specify the reason why the node is being reported.

  • You must use with data in the URL path as: ?prompt=[data].

  • A node that is in the reported state may still have some of its attributes visible on a GUI, such as the author name and post date, but will have the content hidden.

  • A node is usually reported when the meaning taken from its human-readable content violates the terms and agreements setup for a AnswerHub site.

    • The site administrators or moderators determine the exact terms and agreements for each AnswerHub site, rather than by any logic in the server.
    • A moderator may ask users that post a reported node to review and edit the node, in order to comply with site policies.
      • A reported node reviewed in this way may subsequently have its content re-published.
  • We added this request in version 1.6.3.

Sample Request

A PUT report a node request to report a node (nodeId: 828) sent to https://apidocs.cloud.answerhub.com using a human-readable Username/Password (answerhub/test123), for a specific reason ("This violates our terms") would look like this:

curl 
-u answerhub:test123 
-H "Accept: application/json" 
-H "Content-type: application/json" 
-X PUT "https://apidocs.cloud.answerhub.com/services/v2/node/828/report.json?prompt=This%20violates%20our%20terms." -v

Expected Response

Successful Response:

  • HTTP Status 200 - OK
{
    "success": true,
    "result": {
        "reportCount": 1,
        "reportAction": {
            "id": 1065,
            "ip": "172.20.0.3",
            "user": {
                "id": 108,
                "username": "admin",
                "avatarUrl": "https://secure.gravatar.com/avatar/4e955c70eeff0abe1974c9be300a8887?d=identicon&r=PG"
            },
            "actionDate": "Tue Feb 05 14:56:54 UTC 2019",
            "canceled": false,
            "extra": "This violates our terms.",
            "private": false,
            "verb": "reported",
            "node": {
                "id": 828,
                "type": "kbentry"
            }
        }
    }
}
Language
Credentials
Basic
base64
:
Click Try It! to start a request and see the response here!