PUT /api/v2/chat_file_redactions/{ticket_id}

Permanently removes one or more chat attachments from a chat ticket.

Note: This does not work on active chats. For chat tickets that predate March 2020, consider using Redact Ticket Comment In Agent Workspace.

Allowed For

Agent Workspace must enabled for the account. Deleting tickets must be enabled for agents.

Request Body Properties

NameTypeRequiredDescription
chat_idstringtrueThe chat_id in the ChatStartedEvent event in the ticket audit. See Ticket Audits
chat_indexesarrayfalseThe array of chat_index in the ChatFileAttachment event in the ticket audit. See Ticket Audits. Mandatory if message_ids is not used
message_idsarrayfalseThe array of message_id in the ChatFileAttachment event in the ticket audit that is part of a ChatStartedEvent history. Used when redacting a ChatFileAttachment that is part of a conversation history. Mandatory if chat_indexes is not used

To get the required body properties, make a request to the Ticket Audits endpoint. Example response:

Status 200 OK
{
  "audits": [
    "events": [
      {
        "id": 1932802680168,
        "type": "ChatStartedEvent",
        "value": {
          "visitor_id": "10502823-16EkM3T6VNq7KMd",
          "chat_id": "2109.10502823.Sjuj2YrBpXwei",
          "history": [
            {
              "chat_index": 0,
              "type": "ChatFileAttachment",
              "filename": "image1.jpg"
            },
            {
              "chat_index": 1,
              "type": "ChatFileAttachment",
              "filename": "image2.jpg"
            }
          ]
        }
      }
    ]
  ]
}

Servers

Path parameters

Name Type Required Description
ticket_id Integer Yes

The ID of the ticket

How to start integrating

  1. Add HTTP Task to your workflow definition.
  2. Search for the API you want to integrate with and click on the name.
    • This loads the API reference documentation and prepares the Http request settings.
  3. Click Test request to test run your request to the API and see the API's response.