Task actions
Task search
Identification is required, example url:
$ curl https://SystemId:APIKey@r3.minicrm.hu/Api/R3/ToDoList/1234
Get all tasks belonging to a project.
In the response, the data comes in one array. The number of the tasks can be found on its Count key. The possible values could be Open (open tasks), Closed (closed tasks) and all (all tasks). Example of listing open tasks:
$ curl https://SystemId:APIKey@r3.minicrm.hu/Api/R3/ToDoList/1234?Status=Open
Example output:
{
"Count":2,
"Results":[
{
"Id":"1111",
"Status":"Open",
"Comment":"Do something.",
"Deadline":"2012-01-17 23:59:00",
"UserId":"3200",
"Type":"0",
"Url":"https://r3.minicrm.hu/Api/R3/ToDo/1111"
},
{
"Id":"2222",
"Status":"Open",
"Comment":"Do something else.",
"Deadline":"2013-01-22 23:59:00",
"UserId":"3300",
"Type":"1566",
"Url":"https://r3.minicrm.hu/Api/R3/ToDo/2222"
}
]
}
Task (GET)
Identification is required, example url:
$ curl https://SystemId:APIKey@r3.minicrm.hu/Api/R3/ToDo/1111
Getting the data of a task. In the output, the data comes in an array.
Example output:
{
"Id":1111,
"UserId":"John Doe",
"ProjectId":2001,
"Type":"",
"Status":"Open",
"Deadline":"2012-01-17 23:59:00",
"Comment":"Do something.",
"Attachments":{
"FileName":"details.pdf",
"Url":"http://cdn.minicrm.hu/doc/2013/04-25/A/Q/AQFwQq7Os0kE5ykH_GSJfg-1"
}
}
Task (PUT)
$ curl -XPUT https://SystemId:APIKey@r3.minicrm.hu/Api/R3/ToDo/1111 -d '{
"Comment":"Do something more.",
"Deadline":"2013-01-25 13:30:00"
}'
The service URL equals to the URL of task download. You can download a task with GET request, and with PUT request, you can modify data. It is possible to add a new task by omitting the ID (1111 at the end of example url). It is important that in case of a new task, it is required to send the ProjectId field, and in case of an existing task, the ProjectID field cannot be edited.
The data structure expected by input is the same as the structure received by the download of the task. Input format is JSON serialized array.
Example output:
{
"Id":1111
}