Delete System Comments
This process outlines the steps to add system comments as well as child system comments through the API.
Delete the entire comment annotation
To add an entire comment annotation via the API, send a POST request to https://api.velt.dev/deletesystemcomment
with the following body data.
Body:
{
"data": {
"apiKey": "YOUR_API_KEY",
"authToken": "YOUR_AUTH_TOKEN",
"annotationId": "COMMENT_ANNOTATION_ID",
"documentId": "your_document_id_here"
}
}
Success Response:
{
"result": {
"status": "success",
"message": "System Comment thread deleted successfully.",
"data": {
"annotationId": "COMMENT_ANNOTATION_ID",
"commentIds": [856787]
}
}
}
Failure Response:
{
"error": {
"message": "Invalid Api key!",
"status": "UNAUTHENTICATED"
}
}
Not sure where find your Auth Token? You can follow these steps to generate your Auth Token.
Delete child comment
To delete a specific child comment, you can use the same endpoint except you need to modify your data body to include an commentId
field. The annotationId
field will contain the parent annotation ID that the child will be removed from.
This will delete the specific child comment inside parent annotation. If there are no more comments available inside comment annotation, then comment annotation will also be deleted.
Body:
{
"data": {
"apiKey": "YOUR_API_KEY",
"authToken": "YOUR_AUTH_TOKEN",
"annotationId": "COMMENT_ANNOTATION_ID",
"documentId": "your_document_id_here",
"commentId": 123456 // child comment id to delete - can only delete 1 at a time
}
}
Success Response:
{
"result": {
"status": "success",
"message": "System Comment thread deleted successfully.",
"data": {
"annotationId": "COMMENT_ANNOTATION_ID",
"commentIds": [856787] // remaining comment ids
}
}
}
Failure Response:
{
"error": {
"message": "Invalid Api key!",
"status": "UNAUTHENTICATED"
}
}
Response result
Status for the response
Status message for the response
Contains annotationId and commentIds
This is the parent comment annotation id
An array with all child comment ids
Was this page helpful?