LMS Collaborator knowledge base

Home/Technical requirements/API/API - Checklist report

API – Checklist report

To receive a report from the checklist on all tasks you need to:

  • send GET request to URI https://your-domain.davintoo.com/api/v2/check-list/report/{id}
  • the request must contain headings Content-Type: application/json;charset=UTF-8 and Authorization: Bearer xxxxxx.
    Request exapmle:
    curl 'https://your-domain.davintoo.com/api/v2/check-list/report/233'
    -H 'Authorization: Bearer xxxxxx'
    -H 'Content-Type: application/json;charset=UTF-8'

The request supports filtration by the following fields:

position - Position
city - City
department - Department
tags - Tag
result_updated_at - Date of filling in the questionnaire in the checklist
result_status - Current status of the questionnaire in the checklist

If you created several tasks for the checklist, you can add a filter with the task id and display the results of a particular task, so you don't have to print all the tasks in the message.

Request example:
curl 'https://your-domain.davintoo.com/api/v2/check-list/report/233?filter[taskId]=36413'
-H 'Authorization: Bearer xxxxxx'
-H 'Content-Type: application/json;charset=UTF-8'


Answer

  • In case of successful request (HTTP response code - 200), the result will be returned in the form of:
    data - result array
    pager - the object of pagination (information about the number of pages, the current page, and the results)

  • In case of a mistake (HTTP response code - 400) returns JSON object with information about the error:
    {"title":{"required":"Field cannot be empty"}}


Detailed report on checklists

To export a detailed report on the questionnaire in the checklist, where the name of the criterion and the reverse score on the scale will be indicated, you need to:

Request exapmle:

curl 'https://your-domain.davintoo.com/api/rest.php/check-lists-result/?action=get-sub-task-details&sub_task_id=36419'
-H 'Authorization: Bearer xxxxxx'
-H 'Content-Type: application/json;charset=UTF-8'


Answer

  • In case of successful request (HTTP response code - 200), the result will be returned in the form of:
    subTask.element.criteriaGroup - criterion groups and criteria;
    subTask.element.scale.answers - variants of the scale in the checklist;
    answers -result array.

  • In case of a mistake (HTTP response code - 400) returns JSON object with information about the error

Still have questions?
Our technical support team is always happy to help!
Write to us at technical support [email protected]. If you are registered on our Helpdesk - send request button below.
Send request