CreateTicketComment
Creates a new comment on the specified ticket.
Stored Procedure Specific Information
Create a comment on a ticket with optional attachments.
Example of attaching only one file with the comment:
EXECUTE CreateTicketComment @Id='23', @Body='Comment text body.', @Public=true, @Attachments='C:/Example/profilephoto.png'
Example of attaching all files within the first level of a directory. Directories nested within the specified directory are ignored:
EXECUTE CreateTicketComment @Id='23', @Body='Comment text body.', @Public=true, @Attachments='C:/Example/MyDirectory/'
Example of attach a combination of multiple files and folders with the comment using a temp table:
INSERT INTO attach#TEMP (Attachments) VALUES ('C:/Example/MyDirectory/') INSERT INTO attach#TEMP (Attachments) VALUES ('C:/Example/Desktop/data.csv') EXECUTE CreateTicketComment @Id='23', @Body='Comment text body.', @Public=true, @Attachments=attach#TEMP
Input
Name | Type | Required | Description |
Id | String | False | The ID of the ticket to create the comment on. |
Body | String | False | The text body of the comment. |
Public | String | False | Whether or not the comment is public, the default is true. |
Attachments | String | False | The attachment file path, or temp table of file paths, to include with the comment. |
FileStream | String | False | The content as InputStream to be uploaded when AttachmentPath is not specified. |
FileName | String | False | Name of the file. Only used if FileStream is not empty. |
Result Set Columns
Name | Type | Description |
Success | String | The current status of the job. |
CommentId | String | The ID of the created comment. |