| Name | Type | Required | Data |
|---|---|---|---|
| username | Text varchar(50) | YES | Username |
| password | Text varchar(100) | YES | Password |
| user_token | Text | YES | Token provided |
| Name | Type | Required | Data |
|---|---|---|---|
| {from_date} | date (Y-m-d) | YES | Logs from date |
| {to_date} | date (Y-m-d) | YES | Logs to date |
$post = [
'username' => '',
'password' => '',
'user_token' => '',
];
$ch = curl_init('https://api.rrr.lt/get/logs/{from_date}/{to_date}');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $post);
$response = json_decode(curl_exec($ch));
curl_close($ch);
{
"list": [
{
"action": "add_part",
"item_list": [
{
"id": null,
"id_bridge": null,
"car_id": null,
"name": null,
"price": null,
"external_id": null
}
],
"date": "2019-08-01 15:19:17",
"user": "Super Admin",
"details":"{\"category_id\":\"164\",\"car_id\":\"5\",\"name\":\"Atbulin\ės eigos \žibintas\",\"date\":\"2019-08-01 15:19:17\",\"create_date\":\"2019-08-01 15:19:17\",\"mechanic\":\"1\"}"
},
{
"action": "add_part_price",
"item_list": [
{
"id": null,
"id_bridge": null,
"car_id": null,
"name": null,
"price": null,
"external_id": null,
}
],
"date": "2019-08-01 15:19:50",
"user": "Super Admin",
"details": null
},
{
"action": "edit_part",
"item_list": [
{
"id": null,
"id_bridge": null,
"car_id": null,
"name": null,
"price": null,
"external_id": null,
}
],
"date": "2019-08-01 15:19:50",
"user": "Super Admin",
"details": "{\"quality\":{\"old\":\"\",\"new\":\"0\"},\"price\":{\"old\":\"0\",\"new\":\"50\"},\"seo\":{\"old\":null,\"new\":\"mdg57-audi-a4-s4-b9-atbulines-eigos-zibintas\"},\"shop_url\":{\"old\":null,\"new\":\"rrr.lt\\/mdg57-audi-a4-s4-b9-atbulines-eigos-zibintas\"},\"show_url\":{\"old\":null,\"new\":\"rrr.lt\\/mindaugas\\/mdg57-audi-a4-s4-b9-atbulines-eigos-zibintas?cm=44\"}}"
},
...
],
"msg": "OK",
"status_code": "R200"
}