Order List
Method for retrieving a list of Orders.
Endpoint and method
GET /v2/order/
Parameters
offsetintoptional
Pagination parameter. Specifies the ordinal number (offset) of the item from which the selection starts. Default is 0
limitintoptional
Pagination parameter. Number of items returned per request. Maximum value is 100. Default is 50
Request example
<?php
$host = 'https://YOUR_LINER_API_HOST';
$token = 'YOUR_API_TOKEN';
$query = http_build_query([
'offset' => 0,
'limit' => 50,
]);
$ch = curl_init($host . '/v2/order/?' . $query);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Content-Type: application/json',
'X-Api-Key: ' . $token,
],
CURLOPT_TIMEOUT => 15,
]);
$response = curl_exec($ch);
$httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
if ($response === false) {
throw new RuntimeException('cURL error: ' . curl_error($ch));
}
curl_close($ch);
echo "HTTP {$httpCode}\n";
echo $response;
const host = "https://YOUR_LINER_API_HOST";
const token = "YOUR_API_TOKEN";
const params = new URLSearchParams();
params.set("offset", "0");
params.set("limit", "50");
const res = await fetch(`${host}/v2/order/?${params.toString()}`, {
method: "GET",
headers: {
"Content-Type": "application/json",
"X-Api-Key": token
}
});
const data = await res.json();
console.log("HTTP", res.status, data);
Response example
{
"success": true,
"message": "",
"data": {
"list": [
{
"id": 123,
"code": "order-001",
"serviceTitle": "Internal name",
"title": "Order title",
"callSchedule": [["09:00", "18:00"]],
"callHolidayOverrides": ["2024-01-01"],
"autoDialingEnabled": true,
"predictiveModeEnabled": false,
"aiModeEnabled": false,
"standaloneAiModeEnabled": false,
"aiModePrompt": "",
"aiModeFirstPhrase": "",
"aiDefaultLanguage": "ru",
"amdDetectionEnabled": false,
"callRecordRule": "client_is_connected",
"callCenterPhone": "+79001234567",
"additionalCallCenterPhones": [],
"sipEndpointUsageScheme": "random_default",
"agentUserIds": [123, 456],
"agentGroupIds": [789],
"showLeadContactsToAgent": true,
"callAttemptsGroupId": 1,
"qualifiedLeadsPerDayLimit": 100,
"callScenarioId": 10,
"leadTransformEnabled": false,
"leadsPriority": 0,
"status": "success",
"speechRecognitionEnabled": false,
"ignoreLeadTimezone": false,
"sipEndpointIds": [123],
"customValues": {
"10": "example value"
},
"createdAt": "2024-01-01T00:00:00Z",
"updatedAt": "2024-01-01T00:00:00Z"
}
],
"next": 50,
"total": 12345
}
}
Response fields
Fields in data
| Field | Type | Description |
|---|---|---|
list |
array |
List of orders. |
next |
int |
Offset to use for the next request. |
total |
int |
Total number of orders. |
Fields in list
| Field | Type | Description |
|---|---|---|
id |
int |
Order identifier in LINER. |
code |
string |
Order code. |
serviceTitle |
string |
Internal order name. |
title |
string |
Display name of the order. |
callSchedule |
array |
A list where each item contains the start and end time of the working day. |
callHolidayOverrides |
array |
List of holidays. |
autoDialingEnabled |
bool |
Whether calls are allowed. |
predictiveModeEnabled |
bool |
Whether calls are allowed in predictive mode. |
aiModeEnabled |
bool |
Whether AI calling is allowed. |
standaloneAiModeEnabled |
bool |
AI processing without online agents. |
aiModePrompt |
string |
Base prompt for the AI bot. |
aiModeFirstPhrase |
string |
First phrase for the AI bot. |
aiDefaultLanguage |
string |
Default language for AI. Available values: ru, gb. |
amdDetectionEnabled |
bool |
Whether answering machine detection is enabled. |
callRecordRule |
string |
When to start call recording. Available values: client_is_connected, agent_is_connected. |
callCenterPhone |
string |
Main call center phone number. |
additionalCallCenterPhones |
array |
Additional call center phone numbers. |
sipEndpointUsageScheme |
string |
Number usage scheme. Available values: random_default, random_without_repetition, even_loaded, even_loaded_daily. |
agentUserIds |
array |
IDs of agents who can work in this order. |
agentGroupIds |
array |
IDs of agent groups who can work in this order. |
showLeadContactsToAgent |
bool |
Whether agents can see lead contacts. |
callAttemptsGroupId |
int |
Call attempt intervals group ID. |
qualifiedLeadsPerDayLimit |
int |
Maximum number of qualified leads per day. |
callScenarioId |
int |
Call scenario ID. |
sipEndpointIds |
array |
List of virtual number identifiers. |
leadTransformEnabled |
bool |
Whether an agent is allowed to change the lead type. |
leadsPriority |
int |
Lead priority within the order. |
status |
string |
Order status. Available values: success, secondary, info. |
speechRecognitionEnabled |
bool |
Whether call recognition is enabled. |
ignoreLeadTimezone |
bool |
Whether to ignore the client’s time zone. |
customValues |
object |
Map of custom field values: key is the custom field ID, value is the stored value for that field. |
createdAt |
string |
Creation date and time (ISO 8601). |
updatedAt |
string |
Update date and time (ISO 8601). |
Note
The structure of the data field is described above. For the overall API response format, see Request Schema