Action Items
Creating an Action Item
HTTP Request
Method: POST
URL: api/v1/issues/<issue_guid>/action_items
Headers: Content-Type application/json AND Accept application/json AND Authorization Bearer <token>
Body Content:
{ "name": "Created Issue", "detail": "This is a detail.", "status": "Open", "assignee_id": 9 }
Parameters
Route Parameter Name | Description | Required / Optional |
---|---|---|
name | Name of Action Item | Required |
description | Description of Action Item | Required |
status | "Open" or "Closed". Defaults to "Open" | Optional |
assignee_id | Id of person getting assigned the Action Item | Required |
HTTP Response
Response Type: application/json
Response Data:
A successful API response will contain a 200 response code and a JSON formatted response body corresponding to the newly created Action.
Example Response:
{"id": 222, "issue_id": 376, "name": "Created Issue", "detail": "This is a detail.", "created_at": "2015-04-01T15:20:18.105-05:00", "updated_at": "2015-04-01T15:20:18.105-05:00", "status": "Open", "deleted_at": null, "guid": "0141181e-43be-4ea6-a7f3-f37ee59ef5d7", "assignee": { "id": 9, "email": "unus.gaffoor@kineticdata.com", "name": "Unus Gaffoor" }, "creator": { "id": 71, "email": "dillon.hodapp@kineticdata.com", "name": "Dillon Hodapp Admin" }}
A failed API response will contain either a 400 or a 500 series response code based on the exception type, and a JSON formatted response body containing the exception message. See the table below for the types of responses that may be encountered with this API web method.
Example of a failed request:
Response Code: 422
Response Body:
{ "message": "Unprocessable attributes", "reasons": [ "Detail can't be blank" ] }
Response Codes
Response Code | Reason |
---|---|
200 | Successful request. |
401 | The auth. token is invalid and needs to be refreshed. |
404 | If the provided URL was not found on this server. |
422 | A required field was left out. |
500 | If there was an unexpected server error. |
Editing an Action Item
HTTP Request
Method: PUT
URL: /api/v1/issues/<issue_guid>/action_items/<action_item_guid>
Headers: Content-Type application/json AND Accept application/json AND Authorization Bearer <token>
Body Content:
{ "name": "Edited Name", "detail": "Edited Detail", "assignee_id": 11, "status": "Closed" }
HTTP Response
Response Type: application/json
Response Data:
A successful API response will contain a 200 response code and a JSON formatted response body corresponding to the updated Action Item.
Example Response:
{ "id": 222, "issue_id": 376, "name": "New Name", "detail": "Here are the details...Again", "created_at": "2015-04-01T15:20:18.105-05:00", "updated_at": "2015-04-01T15:40:53.821-05:00", "status": "Open", "deleted_at": null, "guid": "0141181e-43be-4ea6-a7f3-f37ee59ef5d7", "assignee": { "id": 9, "email": "unus.gaffoor@kineticdata.com", "name": "Unus Gaffoor" }, "creator": { "id": 71, "email": "dillon.hodapp@kineticdata.com", "name": "Dillon Hodapp Admin" } }
A failed API response will contain either a 400 or a 500 series response code based on the exception type, and a JSON formatted response body containing the exception message. See the table below for the types of responses that may be encountered with this API web method.
Response Codes
Response Code | Reason |
---|---|
200 | Successful request. |
400 | Bad Request. Json might have a field named incorrectly. |
401 | The auth. token is invalid and needs to be refreshed. |
404 | If the provided URL was not found on this server. |
500 | If there was an unexpected server error. |
Deleting an Action Item
HTTP Response
Response Type: application/json
Response Data:
A successful API response will contain a 200 response code.
A failed API response will contain either a 400 or a 500 series response code based on the exception type, and a JSON formatted response body containing the exception message. See the table below for the types of responses that may be encountered with this API web method.
Fetching Action Items
A list of Action Items can be fetched for a particular issue.
HTTP Request
Method: GET
URL: /api/v1/issues/<issue_guid>/action_items
Headers: Content-Type application/json AND Accept application/json AND Authorization Bearer <token>
HTTP Response
Response Type: application/json
Response Data:
A successful API response will contain a 200 response code and a JSON formatted response body corresponding to an array of Action Items on an Issue that matches the <issue_guid>.
Example Response:
[ { "id": 222, "issue_id": 376, "name": "New Name", "detail": "Here are the details...Again", "created_at": "2015-04-01T15:20:18.105-05:00", "updated_at": "2015-04-01T15:40:53.821-05:00", "status": "Open", "deleted_at": null, "guid": "0141181e-43be-4ea6-a7f3-f37ee59ef5d7", "assignee": { "id": 9, "email": "unus.gaffoor@kineticdata.com", "name": "Unus Gaffoor" }, "creator": { "id": 71, "email": "dillon.hodapp@kineticdata.com", "name": "Dillon Hodapp Admin" } } ]
If a query is made that doesn't match any Issues then an empty array is returned. If nothing matches the 'status' URL parameter an empty array is also returned.
A failed API response will contain either a 400 or a 500 series response code based on the exception type, and a JSON formatted response body containing the exception message. See the table below for the types of responses that may be encountered with this API web method.
Example of a failed request:
Response Code: 401
Response Body:
{ "success": false, "message": "Error with your login or password" }
Response Codes
Response Code | Reason |
---|---|
200 | Successful request. |
401 | The auth. token is invalid and needs to be refreshed. |
404 | If the provided URL was not found on this server. |
500 | If there was an unexpected server error. |
Fetching Single Action Item
A single Action Item can be fetched for a particular issue.
HTTP Response
Response Type: application/json
Response Data:
A successful API response will contain a 200 response code and a JSON formatted response body corresponding to an single Action Item on an Issue that matches the <issue_guid>.
Example Response:
{ "id": 222, "issue_id": 376, "name": "New Name", "detail": "Here are the details...Again", "created_at": "2015-04-01T15:20:18.105-05:00", "updated_at": "2015-04-01T15:40:53.821-05:00", "status": "Open", "deleted_at": null, "guid": "0141181e-43be-4ea6-a7f3-f37ee59ef5d7", "assignee": { "id": 9, "email": "unus.gaffoor@kineticdata.com", "name": "Unus Gaffoor" }, "creator": { "id": 71, "email": "dillon.hodapp@kineticdata.com", "name": "Dillon Hodapp Admin" } }
A failed API response will contain either a 400 or a 500 series response code based on the exception type, and a JSON formatted response body containing the exception message. See the table below for the types of responses that may be encountered with this API web method.