Send Comments API Documentation


Introduction


Use this API to send ticket comments from your ticketing system to IrisAgent to allow us to do AI processing of ticket data.

API Guide


Below is a curl command to call this API:

curl -X POST --location "https://api1.irisagent.com/v1/send-comments" \
    -H "Content-Type: application/json" \
    -H "Authorization: Bearer Replace_me_business_id" \
    -d '{
        "data":[
          {"conversationId": "12345",
          "subject": "Application will not access Flight Log",
          "description": "When clicking on Flight Log the application keeps producing an ERROR message and will not allow access or Flight Log updating. ",
          "status": "open",
          "comments":[
              {
                  "commentId": 123e4567-e89b-12d3-a456-426655440000,
                  "comment": "Please help to fix this ASAP.",
                  "commenter": "Customer",
                  "isPublic": true,
                  "timeOfCreation": "1743772260"
              },
              {
                  "commentId": f47ac10b-58cc-4372-a567-0e02b2c3d479,
                  "comment": "Thank you for the information. I have forwarded this issue with all the details to our engineering team for further investigation. I will let you know as soon as any new information becomes available. John Doe | Technical Support Specialist | Acme Systems International, Inc.",
                  "commenter": "Agent",
                  "isPublic": true,
                  "timeOfCreation": "1743772261"
              },
                {
                    "commentId": 550e8400-e29b-41d4-a716-446655440000,
                    "comment": "Billy - Please let the customer know that this issue has been fixed.",
                    "commenter": "Agent",
                    "isPublic": false,
                    "timeOfCreation": "1743772263"
                },
                {
                    "commentId": f81d4fae-7dec-11d0-a765-00a0c91e6bf6,
                    "comment": "I have updated and closed this issue as resolved. While I'm confident we've addressed your issues, if you have any other questions, comments or concerns feel free to create a new ticket. I'm here to help.Please do NOT reply to this email unless you would like us to reopen it. Thank you 
 John Doe | Technical Support Specialist O: _ • TF: _
Acme Systems International, Inc.",
                    "commenter": "Agent",
                    "isPublic": true,
                    "timeOfCreation": "1743772280"
                }
          ]},
      ]
        }'
          

The API inputs are as follows,

FieldDescription
conversationId[Required] Unique ticket or chat id
subject[Required] Initial query by the customer. This could be the subject of the email or the first query by the customer in a chat conversation.
status[Required] The latest status of the ticket. It can accept any value, example values include "open", "closed", etc.
description[Optional] Details on the initial query by the customer. This could be the description of the initial email by the customer. Leave empty for a chat conversation.
comments[Optional] Array of messages between the customer and the agent. Each message should have the following fields:
  • commentId: [Required] UUID of the comment to uniquely identify the comment
  • comment: [Required] Message content
  • commenter: [Required] Author of the message: Either "Customer" or "Agent"
  • isPublic: [Optional] Default value is true. Set as false for private comments.
  • timeOfCreation: [Required] Epoc time when the comment was created
Replace_me_business_idThis is the ID provided by the IrisAgent team


A sample output of the API:

{
  "result": "success"
}


How to send ticket updates using this API:

  • If only ticket status updated -> Pass Subject, Description and Latest Status.
  • If only comment(s) updated -> Pass Subject, Description, Current Status and the updated comment data.
  • If both status and comments are updated -> Similar to second point above.

© Copyright Iris Agent Inc.All Rights Reserved