Enneo

Conversation

Reply to a ticket thread

POST /ticket/{ticketId}/conversation/reply

POST /ticket/{ticketId}/conversation/reply

Create a new conversation by replying to a ticket thread. This actually sends out an email (for email tickets), triggers sending of a letter (for letter tickets) or a message (for chat tickets). Can also create drafts that require supervisor approval before sending.

Path parameters

ticketIdintegerpathrequired

The ID of the ticket to reply to

Query parameters

includeInWorklogbooleanquery

Whether to include the reply in time tracking, and thus worklog. Useful when a spam ticket should be closed, but it should not show up in the average handling time statistics, e.g. for spam emails

includeQuotedHistorybooleanquery

Whether to append the quoted history block to outgoing emails — the chat transcript ("Chat-Verlauf") for chat tickets, or the quoted previous message for email tickets. Set to false for automated template emails (e.g. welcome / mandate letters sent from a chat ticket) so the customer does not receive the whole conversation log. Defaults to true (unchanged behavior). May also be supplied in the request body.

Request body

contentobjectbody

The content of the reply

typeenumbodyDefault: text

The type of content Options: text, html

directionenumbodyDefault: out

The direction of the conversation Options: in, out, internal

privatebooleanbody

Whether this is a private note

isDraftbooleanbodyDefault: false

Whether this is a draft message that requires supervisor approval before sending

subjectstringbody

Optional subject for the reply

tostring[]body

Recipients email addresses

ccstring[]body

CC email addresses

bccstring[]body

BCC email addresses

intentIdsinteger[]body

Array of intent IDs

attachmentsobject[]body

File attachments

channelIdstringbody

Channel ID for chat tickets

subchannelIdintegerbody

Subchannel ID

Request Example

{
  "content": {
    "message": "string"
  },
  "type": "text",
  "direction": "out",
  "private": true,
  "isDraft": false,
  "subject": "string",
  "to": [
    "string"
  ],
  "cc": [
    "string"
  ],
  "bcc": [
    "string"
  ],
  "intentIds": [
    1
  ],
  "attachments": [
    null
  ],
  "channelId": "string",
  "subchannelId": 1
}

Responses

200 — Successful operation

Response Example

{
  "success": true,
  "id": 1,
  "conversation": {
    "id": 123,
    "ticketId": 123,
    "type": "html",
    "direction": "out",
    "private": false,
    "isDraft": false,
    "fromEmail": "service@enneo.ai",
    "fromEmailName": "Enneo Admin",
    "agentId": 1,
    "sender": {
      "id": 1,
      "name": "Enneo Admin",
      "email": "example@enneo.ai",
      "subchannelId": 1
    },
    "toEmail": [
      "to@gmail.com"
    ],
    "to": [
      "service@enneo.ai"
    ],
    "ccEmails": [
      "cc@gmail.com"
    ],
    "bccEmails": [
      "bcc@gmail.com"
    ],
    "channelId": "msg-123-abc",
    "content": {
      "message": "Thank you for your message, we can inform you that..."
    },
    "intentIds": [
      "ai_agent_meter_reading"
    ],
    "cortexRequestId": 123,
    "externalConversationId": "abc-123",
    "isRead": false,
    "attachments": [
      {
        "id": "103013960646,",
        "url": "https://storage.googleapis.com/enneo-attachments-public/a1/103013960646-4b1aa775/IMG_20230301_192712.jpg",
        "name": "IMG_20230301_192712.jpg",
        "size": 2292952,
        "width": 3120,
        "height": 4160,
        "inline": false,
        "fileEnding": "jpg",
        "contentType": "image/jpeg",
        "originalUrl": "https://storage.example.com/attachments/IMG_20230301_192712.jpg",
        "extractedData": null,
        "extractionStatus": "success",
        "extractionData": {
          "confidence": 0.815,
          "meterValue": 87870.5
        }
      }
    ],
    "interface": [],
    "createdAt": 1657056276,
    "modifiedAt": 1672756198
  },
  "surveyCode": "string",
  "webhookResponse": "string"
}

400 — Bad request - Invalid input

403 — Unauthorized

404 — Ticket not found

500 — Internal error