History
Methods
DeleteRecord
Try to remove a record and transcription files.
To call this method, make sure your service account has one of the following roles:
Parameters
record_id:
number
OptionalThe record ID to remove. You can retrieve the record ID via the CallSessionInfoType.records method
record_url:
string
OptionalThe record URL to remove. You can retrieve the record URL via the CallSessionInfoType.records method
Returns
result:
number
DownloadHistoryReport
Downloads the required history report.
Please note, that the history report can return in a compressed state (*.gzip). In order for CURL to process a compressed file correctly, add the --compressed key.
To call this method, make sure your service account has one of the following roles:
Parameters
history_report_id:
number
The history report ID
Returns
file_content:
The method returns a raw data, there is no 'file_content' parameter in fact
GetACDHistory
Gets the ACD history.
To call this method, make sure your service account has one of the following roles:
Parameters
acd_queue_id:
intlist
OptionalThe ACD queue ID list to filter separated by semicolons (;)
acd_request_id:
stringlist
OptionalThe ACD request ID list separated by semicolons (;)
acd_session_history_id:
intlist
OptionalThe ACD session history ID list separated by semicolons (;)
count:
number
OptionalDefaults on: 20The max returning record count
desc_order:
boolean
OptionalWhether to get records in the descent order
from_date:
timestamp
The UTC 'from' date filter in 24-h format: YYYY-MM-DD HH:mm:ss
min_waiting_time:
number
OptionalThe min waiting time filter
offset:
number
OptionalDefaults on: 0The first N records are skipped in the output
operator_hangup:
boolean
OptionalWhether to get the calls terminated by the operator
output:
string
OptionalDefaults on: jsonThe output format. The following values available: json, csv, xls. The default value is json
rejected:
boolean
OptionalWhether the call is rejected calls by the 'max_queue_size', 'max_waiting_time' threshold
to_date:
timestamp
The UTC 'to' date filter in 24-h format: YYYY-MM-DD HH:mm:ss
unserviced:
boolean
OptionalWhether the call is unserviced by the operator
user_id:
intlist
OptionalThe user ID list to filter separated by semicolons (;)
with_events:
boolean
OptionalDefaults on: falseWhether to get the bound events
with_header:
boolean
OptionalDefaults on: trueWhether to get a CSV file with the column names if the output=csv
Returns
count:
number
The returned ACD session count
result:
total_count:
number
The total found ACD session count
GetAuditLog
Gets the history of account changes.
To call this method, make sure your service account has one of the following roles:
Parameters
advanced_filters:
string
OptionalA relation ID to filter (for example: a phone_number value, a user_id value, an application_id value)
audit_log_id:
intlist
OptionalThe audit history ID list separated by semicolons (;)
count:
number
OptionalDefaults on: 100The max returning record count
desc_order:
boolean
OptionalDefaults on: falseWhether to get records in the descent order
filtered_admin_user_id:
string
OptionalThe admin user ID to filter
filtered_cmd:
stringlist
OptionalThe function list separated by semicolons (;) to filter
filtered_ip:
stringlist
OptionalThe IP list separated by semicolons (;) to filter
from_date:
timestamp
The UTC 'from' date filter in 24-h format: YYYY-MM-DD HH:mm:ss
offset:
number
OptionalDefaults on: 0The first N records are skipped in the output
timezone:
string
OptionalDefaults on: Etc/GMTThe selected timezone or the 'auto' value (the account location)
to_date:
timestamp
The UTC 'to' date filter in 24-h format: YYYY-MM-DD HH:mm:ss
with_total_count:
boolean
OptionalDefaults on: falseWhether to include the 'total_count' and increase performance
Returns
count:
number
The returned item count
result:
timezone:
string
The used timezone
total_count:
number
The total found item count
GetAuditLogAsync
The GetAuditLog asynchronous implementation. Use this function to download a large amounts of data. Take a look at the GetHistoryReports and DownloadHistoryReport functions for downloading details.
To call this method, make sure your service account has one of the following roles:
Parameters
advanced_filters:
string
OptionalA relation ID to filter (for example: a phone_number value, a user_id value, an application_id value)
audit_log_id:
intlist
OptionalThe audit history ID list separated by semicolons (;)
desc_order:
boolean
OptionalDefaults on: falseWhether to get records in the descent order
filtered_admin_user_id:
string
OptionalThe admin user ID to filter
filtered_cmd:
stringlist
OptionalThe function list separated by semicolons (;) to filter
filtered_ip:
stringlist
OptionalThe IP list separated by semicolons (;) to filter
from_date:
timestamp
The UTC 'from' date filter in 24-h format: YYYY-MM-DD HH:mm:ss
output:
string
OptionalDefaults on: csvThe output format. The following values available: csv. The default value is csv
timezone:
string
OptionalDefaults on: Etc/GMTThe selected timezone or the 'auto' value (the account location)
to_date:
timestamp
The UTC 'to' date filter in 24-h format: YYYY-MM-DD HH:mm:ss
with_header:
boolean
OptionalDefaults on: trueWhether to get a CSV file with the column names if the output=csv
Returns
history_report_id:
number
The history report ID
result:
number
1
GetBriefCallHistory
Gets the account's brief call history in the asynchronous mode. Take a look at the GetHistoryReports and DownloadHistoryReport functions for downloading details.
To call this method, make sure your service account has one of the following roles:
Parameters
application_id:
number
OptionalTo receive the call history for a specific application, pass the application ID to this parameter
application_name:
string
OptionalThe application name, can be used instead of application_id
call_session_history_custom_data:
string
OptionalTo filter the call history by the custom_data passed to the call sessions, pass the custom data to this parameter
call_session_history_id:
intlist
OptionalTo get the call history for the specific sessions, pass the session IDs to this parameter separated by a semicolon (;). You can find the session ID in the AppEvents.Started event's sessionID property in a scenario, or retrieve it from the call_session_history_id value returned from the StartScenarios or StartConference methods
desc_order:
boolean
OptionalDefaults on: falseWhether to get records in the descent order
from_date:
timestamp
The from date in the selected timezone in 24-h format: YYYY-MM-DD HH:mm:ss
local_number:
stringlist
OptionalTo receive a call history for a specific local numbers, pass the number list separated by semicolons (;). A local number is a number on the platform side
output:
string
The output format. The following values available: csv.
remote_number:
stringlist
OptionalTo receive a call history for a specific remote numbers, pass the number list separated by semicolons (;). A remote number is a number on the client side
rule_name:
string
OptionalTo receive the call history for a specific routing rule, pass the rule name to this parameter. Applies only if you set application_id or application_name
timezone:
string
OptionalDefaults on: Etc/GMTThe selected timezone or the 'auto' value (the account location)
to_date:
timestamp
The to date in the selected timezone in 24-h format: YYYY-MM-DD HH:mm:ss
with_header:
boolean
OptionalDefaults on: trueWhether to get a CSV file with the column names if the output=csv
Returns
history_report_id:
number
The history report ID
result:
number
1
GetCallHistory
Gets the account's call history (including call duration, cost, logs and other call information). You can filter the call history by a certain date.
To call this method, make sure your service account has one of the following roles:
Parameters
application_id:
number
OptionalTo receive the call history for a specific application, pass the application ID to this parameter
application_name:
string
OptionalThe application name, can be used instead of application_id
call_session_history_custom_data:
string
OptionalTo filter the call history by the custom_data passed to the call sessions, pass the custom data to this parameter
call_session_history_id:
intlist
OptionalTo get the call history for the specific sessions, pass the session IDs to this parameter separated by a semicolon (;). You can find the session ID in the AppEvents.Started event's sessionID property in a scenario, or retrieve it from the call_session_history_id value returned from the StartScenarios or StartConference methods
child_account_id:
intlist
OptionalThe child account ID list separated by semicolons (;)
children_calls_only:
boolean
OptionalDefaults on: falseWhether to get the children account calls only
count:
number
OptionalDefaults on: 20The number of returning records. The maximum value is 1000
desc_order:
boolean
OptionalDefaults on: falseWhether to get records in the descent order
from_date:
timestamp
The from date in the selected timezone in 24-h format: YYYY-MM-DD HH:mm:ss
local_number:
stringlist
OptionalTo receive a call history for a specific local numbers, pass the number list separated by semicolons (;). A local number is a number on the platform side
offset:
number
OptionalDefaults on: 0The number of records to skip in the output. The maximum value of 10000
remote_number:
stringlist
OptionalTo receive a call history for a specific remote numbers, pass the number list separated by semicolons (;). A remote number is a number on the client side. Ignored if the
remote_number_list
parameter is not emptyremote_number_list:
object
OptionalA JS array of strings of specific remote phone numbers to sort the call history. Has higher priority than the
remote_number
parameter. If the array is empty, theremote_number
parameter is used insteadrule_name:
string
OptionalTo receive the call history for a specific routing rule, pass the rule name to this parameter. Applies only if you set application_id or application_name
timezone:
string
OptionalDefaults on: Etc/GMTThe selected timezone or the 'auto' value (the account location)
to_date:
timestamp
The to date in the selected timezone in 24-h format: YYYY-MM-DD HH:mm:ss
user_id:
intlist
OptionalTo receive the call history for a specific users, pass the user ID list separated by semicolons (;). If it is specified, the output contains the calls from the listed users only
with_calls:
boolean
OptionalDefaults on: falseWhether to receive a list of sessions with all calls within the sessions, including phone numbers, call cost and other information
with_other_resources:
boolean
OptionalDefaults on: trueWhether to get other resources usage (see ResourceUsageType)
with_records:
boolean
OptionalDefaults on: falseWhether to get the calls' records
with_total_count:
boolean
OptionalDefaults on: trueWhether to include the 'total_count' and increase performance
Returns
count:
number
The returned call session count
result:
The CallSessionInfoType records
timezone:
string
The used timezone
total_count:
number
The total found call session count
GetCallHistoryAsync
The GetCallHistory asynchronous implementation. Use this function to download a large amounts of data. Take a look at the GetHistoryReports and DownloadHistoryReport functions for downloading details.
To call this method, make sure your service account has one of the following roles:
Parameters
application_id:
number
OptionalTo receive the call history for a specific application, pass the application ID to this parameter
application_name:
string
OptionalThe application name, can be used instead of application_id
call_session_history_custom_data:
string
OptionalTo filter the call history by the custom_data passed to the call sessions, pass the custom data to this parameter
call_session_history_id:
intlist
OptionalTo get the call history for the specific sessions, pass the session IDs to this parameter separated by a semicolon (;). You can find the session ID in the AppEvents.Started event's sessionID property in a scenario, or retrieve it from the call_session_history_id value returned from the StartScenarios or StartConference methods
child_account_id:
intlist
OptionalThe child account ID list separated by semicolons (;)
children_calls_only:
boolean
OptionalDefaults on: falseWhether to get the children account calls only
desc_order:
boolean
OptionalDefaults on: falseWhether to get records in the descent order
from_date:
timestamp
The from date in the selected timezone in 24-h format: YYYY-MM-DD HH:mm:ss
local_number:
stringlist
OptionalTo receive a call history for a specific local numbers, pass the number list separated by semicolons (;). A local number is a number on the platform side
output:
string
OptionalDefaults on: csvThe output format. The following values available: csv. The default value is csv
remote_number:
stringlist
OptionalTo receive a call history for a specific remote numbers, pass the number list separated by semicolons (;). A remote number is a number on the client side
rule_name:
string
OptionalTo receive the call history for a specific routing rule, pass the rule name to this parameter. Applies only if you set application_id or application_name
timezone:
string
OptionalDefaults on: Etc/GMTThe selected timezone or the 'auto' value (the account location)
to_date:
timestamp
The to date in the selected timezone in 24-h format: YYYY-MM-DD HH:mm:ss
user_id:
intlist
OptionalTo receive the call history for a specific users, pass the user ID list separated by semicolons (;). If it is specified, the output contains the calls from the listed users only
with_calls:
boolean
OptionalDefaults on: falseWhether to receive a list of sessions with all calls within the sessions, including phone numbers, call cost and other information
with_header:
boolean
OptionalDefaults on: trueWhether to get a CSV file with the column names if the output=csv
with_other_resources:
boolean
OptionalDefaults on: trueWhether to get other resources usage (see ResourceUsageType)
with_records:
boolean
OptionalDefaults on: falseWhether to get the calls' records
Returns
history_report_id:
number
The history report ID
result:
number
1
GetHistoryReports
Gets the list of history reports and their statuses. The method returns info about the reports made via GetCallHistoryAsync, GetTransactionHistoryAsync, GetAuditLogAsync and GetBriefCallHistory asynchronous methods. Note that the file_size field in response is valid only for the video calls.
To call this method, make sure your service account has one of the following roles:
Parameters
application_id:
intlist
OptionalThe application ID to filter. Can be a list separated by semicolons (;). Use the 'all' value to select all applications
count:
number
OptionalDefaults on: 20The max returning record count
created_from:
timestamp
OptionalThe UTC creation from date filter in 24-h format: YYYY-MM-DD HH:mm:ss
created_to:
timestamp
OptionalThe UTC creation to date filter in 24-h format: YYYY-MM-DD HH:mm:ss
desc_order:
boolean
OptionalDefaults on: falseWhether to get records in the descent order
history_report_id:
number
OptionalThe history report ID to filter
history_type:
stringlist
OptionalDefaults on: callsThe history report type list separated by semicolons (;). Use the 'all' value to select all history report types. The following values are possible: calls, calls_brief, transactions, audit, call_list, transactions_on_hold
is_completed:
boolean
OptionalWhether the report is completed
offset:
number
OptionalDefaults on: 0The first N records are skipped in the output
Returns
count:
number
The returned reports count
result:
total_count:
number
The total found reports count
GetTransactionHistory
Gets the transaction history.
To call this method, make sure your service account has one of the following roles:
Parameters
child_account_id:
intlist
OptionalThe child account ID list separated by semicolons (;). Use the 'all' value to select all child accounts
children_transactions_only:
boolean
OptionalDefaults on: falseWhether to get the children account transactions only
count:
number
OptionalDefaults on: 20The number of returning records. The maximum value is 1000
desc_order:
boolean
OptionalWhether to get records in the descent order
from_date:
timestamp
The from date in the selected timezone in 24-h format: YYYY-MM-DD HH:mm:ss
is_uncommitted:
boolean
OptionalDefaults on: falseWhether to get transactions on hold (transactions for which money is reserved but not yet withdrawn from the account)
offset:
number
OptionalDefaults on: 0The number of records to skip in the output with a maximum value of 10000
timezone:
string
OptionalDefaults on: Etc/GMTThe selected timezone or the 'auto' value (the account location)
to_date:
timestamp
The to date in the selected timezone in 24-h format: YYYY-MM-DD HH:mm:ss
transaction_id:
intlist
OptionalThe transaction ID list separated by semicolons (;)
transaction_type:
stringlist
OptionalThe transaction type list separated by semicolons (;). The following values are possible: gift_revoke, resource_charge, money_distribution, subscription_charge, subscription_installation_charge, card_periodic_payment, card_overrun_payment, card_payment, rub_card_periodic_payment, rub_card_overrun_payment, rub_card_payment, robokassa_payment, gift, promo, adjustment, wire_transfer, us_wire_transfer, refund, discount, mgp_charge, mgp_startup, mgp_business, mgp_big_business, mgp_enterprise, mgp_large_enterprise, techsupport_charge, tax_charge, monthly_fee_charge, grace_credit_payment, grace_credit_provision, mau_charge, mau_overrun, im_charge, im_overrun, fmc_charge, sip_registration_charge, development_fee, money_transfer_to_child, money_transfer_to_parent, money_acceptance_from_child, money_acceptance_from_parent, phone_number_installation, phone_number_charge, toll_free_phone_number_installation, toll_free_phone_number_charge, services, user_money_transfer, paypal_payment, paypal_overrun_payment, paypal_periodic_payment
user_id:
intlist
OptionalThe user ID list separated by semicolons (;)
users_transactions_only:
boolean
OptionalDefaults on: falseWhether to get the users' transactions only
with_total_count:
boolean
OptionalDefaults on: falseWhether to include the 'total_count' and increase performance
Returns
count:
number
The returned transaction count
result:
timezone:
string
The used timezone. 'Etc/GMT' for example
total_count:
number
The total found transaction count
GetTransactionHistoryAsync
The GetTransactionHistory asynchronous implementation. Use this function to download a large amounts of data. Take a look at the GetHistoryReports and DownloadHistoryReport functions for downloading details.
To call this method, make sure your service account has one of the following roles:
Parameters
child_account_id:
intlist
OptionalThe child account ID list separated by semicolons (;). Use the 'all' value to select all child accounts
children_transactions_only:
boolean
OptionalDefaults on: falseWhether to get the children account transactions only
desc_order:
boolean
OptionalWhether to get records in the descent order
from_date:
timestamp
The from date in the selected timezone in 24-h format: YYYY-MM-DD HH:mm:ss
is_uncommitted:
boolean
OptionalDefaults on: falseWhether to get transactions on hold (transactions for which money is reserved but not yet withdrawn from the account)
output:
string
OptionalDefaults on: csvThe output format. The following values available: csv. The default value is csv
timezone:
string
OptionalDefaults on: Etc/GMTThe selected timezone or the 'auto' value (the account location)
to_date:
timestamp
The to date in the selected timezone in 24-h format: YYYY-MM-DD HH:mm:ss
transaction_id:
intlist
OptionalThe transaction ID list separated by semicolons (;)
transaction_type:
stringlist
OptionalThe transaction type list separated by semicolons (;). The following values are possible: gift_revoke, resource_charge, money_distribution, subscription_charge, subscription_installation_charge, card_periodic_payment, card_overrun_payment, card_payment, rub_card_periodic_payment, rub_card_overrun_payment, rub_card_payment, robokassa_payment, gift, promo, adjustment, wire_transfer, us_wire_transfer, refund, discount, mgp_charge, mgp_startup, mgp_business, mgp_big_business, mgp_enterprise, mgp_large_enterprise, techsupport_charge, tax_charge, monthly_fee_charge, grace_credit_payment, grace_credit_provision, mau_charge, mau_overrun, im_charge, im_overrun, fmc_charge, sip_registration_charge, development_fee, money_transfer_to_child, money_transfer_to_parent, money_acceptance_from_child, money_acceptance_from_parent, phone_number_installation, phone_number_charge, toll_free_phone_number_installation, toll_free_phone_number_charge, services, user_money_transfer, paypal_payment, paypal_overrun_payment, paypal_periodic_payment
user_id:
intlist
OptionalThe user ID list separated by semicolons (;)
users_transactions_only:
boolean
OptionalDefaults on: falseWhether to get the users' transactions only
with_header:
boolean
OptionalDefaults on: trueWhether to get a CSV file with the column names if the output=csv
Returns
history_report_id:
number
The history report ID
result:
number
1