Start a conversation

Ghost Edit Answers

Overview


Information

/answer/{answer_id}.json?ghostEdit=true

Permissions & Notes:

  • You must have the new permission called Hide moderator edit under Moderation Roles in the Advanced Editor, to grant moderators the opportunity to see the checkbox to hide their edits in the community UI.

Sample Request

This sample request changes the body of the answer (ID: 981) for the question (ID: 980).

  • cURL
-u answerhub:test123 -H "Accept: application/json" -H "Content-type: application/json" -X PUT -d '{"body":"this answer has been changed via API"}'"https://apidocs.cloud.answerhub.com/services/v2/answer/981.json?ghostEdit=true" -v
-u answerhub:test123
-H "Accept: application/json"
-H "Content-type: application/json"
-X PUT -d '{"body":"this answer has been changed via API"}'"https://apidocs.cloud.answerhub.com/services/v2/answer/981.json?ghostEdit=true" -v

Sample Response

Successful Request will result in a 204 - No Content HTTP status and the system will not return a JSON Object in the response body. You can see the changes in the community UI. The body of the answer has changed from "answering to ghost edit the answer via the API" to "this answer has been changed via API." You can see the change in the revisions list.

Choose files or drag and drop files
Was this article helpful?
Yes
No
  1. Priyanka Bhotika

  2. Posted

Comments