Sample - Slack Web API
POST/files.comments.delete

Delete a file comment

Deletes an existing comment from a file. Provide file to identify the file and id to identify the comment you want to remove.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

1 parameter · 2 body fields
tokenstringoptional
Authentication token with the `files:write:user` scope.

File comment deletion data containing the file and comment identifiers.

filestringoptional
File to delete a comment from.
idstringoptional
The comment to delete.

2 status codes
200Returns `ok: true` after the file comment has been deleted.
okbooleanrequired
Allowed:true
defaultReturned when the comment cannot be deleted or found, or when authentication, permissions, account status, argument names, or request encoding is invalid.
callstackstringoptional
Note: PHP callstack is only visible in dev/qa
errorstringrequired
Allowed:cant_deletecomment_not_foundnot_authedinvalid_authaccount_inactiveno_permissioninvalid_arg_nameinvalid_array_arginvalid_charsetinvalid_form_datainvalid_post_typemissing_post_type
okbooleanrequired
Allowed:false

Error handling

token must provide authentication with the files:write:user scope. Supply both file and id so the API can identify the file comment to delete.