0

I've been trying to add a note to an existing ticket with the rest api

endpoint: cw.mycompany.com/v4_6_release/apis/3.0/service/tickets/1327224/notes

request body:

{
    "text":"Test message"
}

However, I get the following response:

{
    "code": "InvalidObject",
    "message": "serviceNote object is invalid",
    "errors": [
        {
            "code": "ServiceNote",
            "message": "Please choose where to display the notes in order to save this record.",
            "resource": "serviceNote",
            "field": "detailDescriptionFlag, internalAnalysisFlag, resolutionFlag"
        }
    ]

}

What do I need to add to my request to add the note to my ticket? I don't see anything in the ServiceNote Object that looks like a "display location" or something to that effect anywhere.

Thanks,

~Josh

Relequestual
  • 11,631
  • 6
  • 47
  • 83
Josh Bowdish
  • 91
  • 1
  • 15
  • You're asking a question about a specific API, but you haven't included a link to the documentation. It looks like the documentation might not be openly avilable, and as such it's unlikely anyone here can help you. You should consider in stead submitting a support request to the associated company. – Relequestual Apr 04 '19 at 08:02
  • Good point, sorry: https://developer.connectwise.com/products/manage/rest?a=Service&e=TicketNotes&o=CREATE Unfortunately, it isn't openly available and my attempts at support on their forums and direct contact have been unsuccessful, hence my asking here. :( – Josh Bowdish Apr 04 '19 at 18:04
  • I appreciate this is difficult. You've kinda said "I'm trying to fix my car, can you help? But I can't show you the manual" - Have you tried their live chat? https://www.connectwise.com/services/support – Relequestual Apr 04 '19 at 18:52
  • Also true, heh. I have tried their live chat but that's more for usage of their actual applications. They directed me to send an email to the team at 'platform@connectwise.com' but that hasn't panned out either. I want to leave this here just in case someone else is going through the same thing, and maybe so Connectwise can pick up on the difficulties we're having and address them. – Josh Bowdish Apr 05 '19 at 21:54

1 Answers1

1

Provide one of the "field" values listed in the error as a boolean; either detailDescriptionFlag, internalAnalysisFlag, or resolutionFlag.

Most likely you'll be using detailDescriptionFlag. An example payload for this would be:

{
      'text'                  : 'Hello World',
      'detailDescriptionFlag' : true
}

None of this is covered in their REST documentation for Create Service Note.

Mike
  • 2,035
  • 1
  • 16
  • 16
  • Thanks! That worked perfectly. I would have never made the connection between "Where to display" and "detailDescriptionFlag". I hope I can use this same method to decipher future errors. – Josh Bowdish Apr 05 '19 at 21:49