GET /api/alerts/{AlertID}/comments

Returns the comments associated with the specified alert.

Authorization Roles/Permissions: Must have visibility of the specified alert.

This topic includes the following sections:

HTTP Method

GET

URL

https://{hostname}/api/alerts/{AlertID}/comments

Sample Request

The example below shows a request for the comments for the specified alert.

Sample Request URL

https://{hostname}/api/alerts/alert11639.acmepaymentscorp/comments

Sample request headers

Accept: application/json

Sample request body

Not applicable.

Request Headers

For general information on request header values, refer to HTTP Request Headers.

Header Description
Accept application/json, application/vnd.soa.v71+json, application/vnd.soa.v72+json

Request Parameters

Parameter Parm Type Data Type Required Description
AlertID Path string Required The unique ID for a specific alert.
start Query integer Optional An index number indicating the starting point for the results to be returned. If not specified, results start at position 0, the first result.
count Query integer Optional The number of results to be returned, from the specified starting point. If not specified, 100 matching results are returned.

Response

If successful, this operation returns HTTP status code 200, with comments on the specified alert, if there are any.

Sample Response

The sample response below shows successful completion of this operation.

Sample response headers: application/json

Status Code: 200 OK
Content-Type: application/json
Expires: Tue, 12 May 2015 20:00:00 GMT

Sample response body: application/json

{
  "totalResults" : 3,
  "startIndex" : 0,
  "Comment" : [ {
    "CommentID" : "1039801c-27fc-45cf-ae80-09990fc321f9.acmepaymentscorp",
    "CommentSubjectID" : "alert11639.acmepaymentscorp",
    "Content" : "**Sunday morning is a good time.**",
    "Created" : "2015-05-13T01:06:41Z",
    "Marks" : 0,
    "IsMarked" : false,
    "UserID" : "f778a368-f060-43af-b75f-99d4fb3905ac.acmepaymentscorp",
    "UserName" : "JonathanSwiftacmepaymentscorp
    "AvatarURL" : "http://{hostname}/api/users/f778a368-f060-43af-b75f-99d4fb3905ac.acmepaymentscorp/avatar",
    "Published" : true
    "MediaType" : "text/plain",
    "BoardItemArtifacts" : {
        "BoardItemArtifact" : [ ]
      }
    } ]
  }, {
    "CommentID" : "4513c498-5055-411d-aa92-79c0f416047c.acmepaymentscorp",
    "CommentSubjectID" : "alert11639.acmepaymentscorp",
    "Content" : "Thanks for letting us know!!",
    "Created" : "2015-05-13T01:05:14Z",
    "Marks" : 1,
    "IsMarked" : true,
    "UserID" : "f778a368-f060-43af-b75f-99d4fb3905ac.acmepaymentscorp",
    "UserName" : "JonathanSwift",
    "AvatarURL" : "http://{hostname}/api/users/f778a368-f060-43af-b75f-99d4fb3905ac.acmepaymentscorp/avatar",
    "Published" : true
  }, {
    "CommentID" : "da1df33e-6b0e-4846-9445-3530402dbc81.acmepaymentscorp",
    "CommentSubjectID" : "alert11639.acmepaymentscorp",
    "Content" : "Appreciate the advance notice!",
    "Created" : "2015-05-13T00:48:44Z",
    "Marks" : 1,
    "IsMarked" : true,
    "UserID" : "d4c9e7bc-adf4-4612-8b68-fbcaa06f679f.acmepaymentscorp",
    "UserName" : "JaneMead",
    "AvatarURL" : "http://{hostname}/api/users/d4c9e7bc-adf4-4612-8b68-fbcaa06f679f.acmepaymentscorp/avatar",
    "Published" : true
    "MediaType" : "text/plain",
    "BoardItemArtifacts" : {
      "BoardItemArtifact" : [ ]
    }
  } ]
}

Response Headers

For general information on response header values, refer to HTTP Response Headers.

Header Description
Content-Type application/json, application/vnd.soa.v71+json, application/vnd.soa.v72+json

Response Body

Name Type Description
Comments Comments Contains information about one or more comments on a Board item.

Error Codes/Messages

If the call is unsuccessful an error code/message is returned. One or more examples of possible errors for this operation are shown below.

Item Value
204 No content. You would get this response if there are no comments on the specified ticket.
401 Unauthorized. For example, you would get this response if you didn't include the custom X-Csrf-Token_{fedmemberID} header in the request, when it was required by the platform settings; or if you included an invalid or expired value for this header. You would also get this response for any operation that requires login (almost all) if the login cookie was missing.
500 An error occurred processing the call.

More information about Akana API Platform API error messages.