add_log_record

To add a record to the log of an item, use the item/add_log_record method.

Copied!
svc=item/add_log_record&params={"itemId":<long>,
								"action":"<text>",
								"newValue":"<text>",
								"oldValue":"<text>"}

Parameters

Name Description
itemId Item ID.
action Action ID written to the item log. See the list of available actions below.
newValue Action-specific parameter #1 (stored as log parameter p1). Its meaning depends on action.
oldValue Action-specific parameter #2 (stored as log parameter p2). Its meaning depends on action; may be empty for many actions.

Below are available actions and the corresponding log record text.

General

Action ID Action description Action text
custom_msg Manual record Manual record: ‘%s’.
create_unit Item creation Unit ‘%s’ created.
create_user Item creation User ‘%s’ created.
create_group Item creation Unit group ‘%s’ created.
create_resource Item creation Resource ‘%s’ created.
create_account Item creation Account ‘%s’ created.
delete_item Item deletion Item ‘%s’ deleted.
delete_account Item deletion Account ‘%s’ deleted.
update_name Name change Name changed from ‘%s’ to ‘%s’.
update_access Access change
  • Access to user ‘%s’ changed.
  • Access to unit ‘%s’ changed.
  • Access to unit group ‘%s’ changed.
  • Access to resource ‘%s’ changed.
  • Access to route ‘%s’ changed.
  • Access rights for user ‘%s’ changed

Unit properties

Action ID Action description Action text
update_unit_icon Icon change Unit icon changed.
update_unit_pass Access password change Access password changed.
update_unit_phone Phone number change Phone number changed from ‘%s’ to ‘%s’.
update_unit_phone2 Phone number change Second phone number changed from ‘%s’ to ‘%s’.
update_unit_uid Unique ID change Unique ID changed from ‘%s’ to ‘%s’.
update_unit_uid2 Unique ID change Second unique ID changed from ‘%s’ to ‘%s’.
update_unit_hw Device change Device type changed from ‘%s’ to ‘%s’.
update_unit_hw_cfg Device change Device configuration changed.

Counters

Action ID Action description Action text
update_unit_calcflags (updating the sensor calculation settings) Counters Calculation flags changed.
update_unit_milcounter Counters Mileage counter changed from %d %s to %d %s.
update_unit_bytecounter (updating the value of the GPRS traffic counter) Counters GPRS traffic counter changed from %d KB to %d KB.
update_unit_ehcounter Counters Engine hours counter changed from %.2f h to %.2f h.

Report and track settings

Action ID Action description Action text
update_unit_drat (driver activity) Report settings Driver activity source changed.
update_unit_fuel_cfg Report settings Fuel consumption settings changed.
update_unit_trip_cfg Report settings Trip detector settings changed.
update_unit_report_cfg (updating the parameters used in reports) Report settings Unit report settings changed.
update_msgs_filter_cfg (updating the filtration settings of the unit location in messages) Report settings Message filtration settings changed.
update_speed_settings Report settings Speed settings changed.
convert_measure_units Report settings
  • Measurement system changed to %s.
  • Conversion to the %s.
update_track_color_setting Tracks
  • Track colour settings changed to “By trips”.
  • Track colour settings changed to “Single”.
  • Track colour settings changed to “By speed”.
  • Track colour settings changed to “By sensor”.

In Wialon Local, the update_speed_settings action is available starting from version 2404.

Fuel events

Action ID Action description Action text
mark_filling_event Events The fuel filling of %s carried out on %s was marked as false.
unmark_filling_event Events The false event mark has been removed from the fuel filling of %s carried out on %s.
mark_theft_event Events The fuel drain of %s carried out on %s was marked as false.
unmark_theft_event Events The false event mark has been removed from the fuel drain of %s carried out on %s.

For these actions, newValue (log parameter p1) contains the fuel volume, and oldValue (log parameter p2) contains the event time, UNIX time.

In Wialon Local, these actions are available starting from version 2404.

Health check

Action ID Action description Action text
update_health_check_parameters Health check parameters Unit health check parameters updated.

In Wialon Local, the update_health_check_parameters action is available starting from version 2504.

Sensors

Action ID Action description Action text
create_sensor Sensors Sensor ‘%s’ created.
update_sensor Sensors Sensor ‘%s’ modified.
delete_sensor Sensors Sensor ‘%s’ deleted.

Commands

Action ID Action description Action text
create_alias Commands Command ‘%s’ created.
update_alias Commands Command ‘%s’ modified.
delete_alias Commands Command ‘%s’ deleted.

Service intervals

Action ID Action description Action text
create_service_interval Service intervals Service interval ‘%s’ created.
update_service_interval Service intervals Service interval ‘%s’ modified.
delete_service_interval Service intervals Service interval ‘%s’ deleted.

Fields

Action ID Action description Action text
create_custom_field Fields Custom field ‘%s’ created.
update_custom_field Fields Custom field ‘%s’ modified.
delete_custom_field Fields Custom field ‘%s’ deleted.
create_admin_field Fields Admin field ‘%s’ created.
update_admin_field Fields Admin field ‘%s’ modified.
delete_admin_field Fields Admin field ‘%s’ deleted.
update_profile_field Fields Profile field ‘%s’ modified.
delete_profile_field Fields Profile field ‘%s’ deleted.

Import and export

Action ID Action description Action text
import_item_cfg Import Properties imported.
import_unit_cfg Import Properties imported.
import_unit_msgs Import Messages imported.
export_unit_msgs Export Messages exported.

Messages

Action ID Action description Action text
delete_unit_msg Message deletion
  • Deleted SMS message dated %s.
  • Deleted command message dated %s.
  • Deleted event message dated %s.
  • Deleted data message dated %s.
delete_unit_msgs Message deletion
  • Deleted %s SMS messages.
  • Deleted %s command messages.
  • Deleted %s event messages.
  • Deleted %s data messages.

For these actions, oldValue (log parameter p2) contains the type of the deleted messages: 256 (0x0100) for SMS messages, 512 (0x0200) for commands, 1536 (0x0600) for events. Any other value means data messages. For delete_unit_msg, newValue (log parameter p1) contains the message time, UNIX time. For delete_unit_msgs, newValue contains the number of deleted messages.

Drivers

Action ID Action description Action text
bind_unit_driver Drivers Driver ‘%s’ was assigned at ‘%s’.
unbind_unit_driver Drivers Driver ‘%s’ was separated at ‘%s’.
create_driver Drivers Driver ‘%s’ created.
update_driver Drivers Driver ‘%s’ updated.
delete_driver Drivers Driver ‘%s’ deleted.
driver_reset_image Drivers Driver ‘%s’ updated.
delete_driver_msg Drivers Message dated %s from driver ‘%s’ deleted.
ignore_bind_unit_driver Drivers Driver ‘%s’ assignment was marked as false on %s.
ignore_unbind_unit_driver Drivers Driver ‘%s’ separation was marked as false on %s.
ignore_any_unit_driver Drivers All assignments and separations of driver ‘%s’ for the interval were marked as false on %s.
delete_driver_action_bind Drivers Driver ‘%s’ assignment was deleted on %s.
delete_driver_action_unbind Drivers Driver ‘%s’ separation was deleted on %s.
delete_driver_action_ignore_bind Drivers False mark was removed from driver ‘%s’ assignment on %s.
delete_driver_action_ignore_unbind Drivers False mark was removed from driver ‘%s’ separation on %s.
delete_driver_action_ignore_any Drivers False marks were removed from all assignments and separations of driver ‘%s’ for the interval on %s.
resource_bind_unit_driver Drivers Driver ‘%s’ was assigned on ‘%s’ to unit ‘%s’.
resource_unbind_unit_driver Drivers Driver ‘%s’ was separated on %s from unit ‘%s’.
resource_ignore_bind_unit_driver Drivers Driver ‘%s’ assignment to unit ‘%s’ was marked as false on %s.
resource_ignore_unbind_unit_driver Drivers Driver ‘%s’ separation from unit ‘%s’ was marked as false on %s.
resource_ignore_any_unit_driver Drivers All assignments and separations of driver ‘%s’ related to unit ‘%s’ for the interval were marked as false on %s.
resource_delete_driver_action_bind Drivers Driver ‘%s’ assignment to unit ‘%s’ was deleted on %s.
resource_delete_driver_action_unbind Drivers Driver ‘%s’ separation from unit ‘%s’ was deleted on %s.
resource_delete_driver_action_ignore_bind Drivers False mark was removed from driver ‘%s’ assignment to unit ‘%s’ on %s.
resource_delete_driver_action_ignore_unbind Drivers False mark was removed from driver ‘%s’ separation from unit ‘%s’ on %s.
resource_delete_driver_action_ignore_any Drivers False marks were removed from all assignments and separations of driver ‘%s’ related to unit ‘%s’ for the interval on %s.
create_drivers_group Drivers Group of drivers ‘%s’ created.
update_drivers_group Drivers Group of drivers ‘%s’ updated.
delete_drivers_group Drivers Group of drivers ‘%s’ deleted.
update_driver_units (updating the list of drivers that should be assigned to units automatically) Change of group members
  • Unit attached to the resource of drivers ‘%s’.
  • Unit removed from the resource of drivers ‘%s’.
  • Unit group attached to the resource of drivers ‘%s’.
  • Unit group removed from the resource of drivers ‘%s’.
  • Automatic assignment list of drivers updated.

The actions with the resource_ prefix are written to the resource log, and the other driver assignment actions are written to the unit log.

The ignore_*, delete_driver_action_*, resource_ignore_*, resource_delete_driver_action_*, resource_bind_unit_driver, and resource_unbind_unit_driver actions aren’t available in Wialon Local.

Trailers

Action ID Action description Action text
bind_unit_trailer Trailers Trailer ‘%s’ was assigned at ‘%s’.
unbind_unit_trailer Trailers Trailer ‘%s’ was separated at ‘%s’.
create_trailer Trailers Trailer ‘%s’ created.
update_trailer Trailers Trailer ‘%s’ updated.
delete_trailer Trailers Trailer ‘%s’ deleted.
trailer_reset_image Trailers Trailer ‘%s’ updated.
delete_trailer_msg Trailers Message dated %s from trailer ‘%s’ deleted.
create_trailers_group Trailers Group of trailers ‘%s’ created.
update_trailers_group Trailers Group of trailers ‘%s’ updated.
delete_trailers_group Trailers Group of trailers ‘%s’ deleted.
update_trailer_units (updating the list of trailers that should be assigned to units automatically) Change of group members
  • Unit attached to the resource of trailers ‘%s’.
  • Unit removed from the resource of trailers ‘%s’.
  • Unit group attached to the resource of trailers ‘%s’.
  • Unit group removed from the resource of trailers ‘%s’.
  • Automatic assignment list of trailers updated.

Passengers

Action ID Action description Action text
bind_unit_tag Passengers Passenger ‘%s’ was assigned at ‘%s’.
unbind_unit_tag Passengers Passenger ‘%s’ was separated at ‘%s’.
create_tag Tags Passenger ‘%s’ created.
update_tag Tags Passenger ‘%s’ updated.
tag_reset_image Tags Passenger ‘%s’ updated.
delete_tag Tags Passenger ‘%s’ deleted.
delete_tag_msg Tags Message dated %s from passenger ‘%s’ deleted.
update_tag_units Tags Automatic assignment list of passengers updated.

User settings

Action ID Action description Action text
update_hosts_mask User settings Host mask changed to ‘%s’.
update_user_pass User settings User password changed.
update_user_flags User settings User flags changed.
update_user_locale User settings First day of week changed.
create_user_notify User settings Notice to the user: ‘%s’.
delete_user_notify User settings User notification ‘%s’ deleted.

Unit groups

Action ID Action description Action text
units_group (adding/removing units to/from a unit group) Change of group members
  • Unit added to the group ‘%s’.
  • Unit removed from the group ‘%s’.
  • Units in group updated.

Geofences

Action ID Action description Action text
create_zone Geofences Geofence ‘%s’ created.
update_zone Geofences Geofence ‘%s’ updated.
delete_zone Geofences Geofence ‘%s’ deleted.
import_zones Geofences Geofences imported.
create_zones_group Geofences Group of geofences ‘%s’ created.
update_zones_group Geofences Group of geofences ‘%s’ updated.
delete_zones_group Geofences Group of geofences deleted.
zone_reset_image Geofences Geofence ‘%s’ updated.

Jobs

Action ID Action description Action text
create_job Jobs Job ‘%s’ created.
switch_job Jobs Job ‘%s’ switched on/off.
update_job Jobs Job ‘%s’ updated.
delete_job Jobs Job ‘%s’ deleted.

Notifications

Action ID Action description Action text
create_notify Notifications Notification ‘%s’ created.
switch_notify Notifications Notification ‘%s’ switched on/off.
update_notify Notifications Notification ‘%s’ updated.
delete_notify Notifications Notification ‘%s’ deleted.

Report templates

Action ID Action description Action text
create_report Report templates Report template ‘%s’ created.
update_report Report templates Report template ‘%s’ updated.
delete_report Report templates Report template ‘%s’ deleted.

Retranslators

Action ID Action description Action text
create_retranslator Retranslators Retranslator ‘%s’ created.
update_retranslator Retranslators Properties updated.
units_retranslator Retranslators Units updated.
switch_retranslator Retranslators Started/Stopped.
msgs_history_retranslator Retranslators
  • Past period retranslator started.
  • Past period retranslator stopped.

Routes

Action ID Action description Action text
create_route Routes Route ‘%s’ created.
update_route_points Routes Check points updated.
update_route_cfg Routes Properties updated.
create_round Routes Ride ‘%s’ created.
update_round Routes Ride ‘%s’ updated.
delete_round Routes Ride ‘%s’ deleted.
create_schedule Routes Schedule ‘%s’ created.
update_schedule Routes Schedule ‘%s’ updated.
delete_schedule Routes Schedule ‘%s’ deleted.

Accounts

Action ID Action description Action text
change_account Account Account changed from ‘%s’ to ‘%s’.
switch_account Account Account blocked/unblocked.
update_dealer_rights Account Dealer rights enabled/disabled.
do_payment Account Payment or days registered.
update_account_flags Account Account flags changed.
update_account_block_balance Account Balance to block account changed.
update_account_deny_balance Account Balance to limit activity changed.
update_account_min_days Account Minimum days counter changed.
update_account_plan Account Billing plan changed to ‘%s’.
update_account_history_period Account History period changed to ‘%s’.
update_account_subplans Account List of subplans changed.
update_service Account Service ‘%s’ updated.
set_business_sphere Account Account business sphere changed to ‘%s’.

In Wialon Local, the set_business_sphere action is available starting from version 2404.

Orders

Action ID Action description Action text
create_order Orders Order ‘%s’ created.
update_order Orders Order ‘%s’ updated.
delete_order Orders Order ‘%s’ deleted.
create_order_route Orders Order route ‘%s’ created.
update_order_route Orders Order route ‘%s’ updated.
delete_order_route Orders Order route ‘%s’ deleted.

Criteria

Action ID Action description Action text
criteria_updated Criteria Criteria updated.

Unit deactivation and activation

Action ID Action description Action text
set_active Activation/Deactivation
  • 0: Unit was deactivated.
  • 1: Unit was activated.
  • 2: Unit was activated automatically.

set_active is written for the unit specified by itemId; the newValue parameter (log p1) stores the activation state: 0 = deactivated, 1 = activated, 2 = automatically activated.

Notices about expiring activation codes

Action ID Action description Action text
create_notice Creating a notice about the activation code expiration Notice ‘%s’ created for the user.
update_notice Updating a notice about the activation code expiration Notice ‘%s’ updated for the user.
delete_notice Deleting a notice about the activation code expiration Notice ‘%s’ deleted.
trigger_notice Sending a notice about the activation code expiration Notice ‘%s’ sent to the user.

These actions aren’t available in Wialon Local.

Activation codes

Action ID Action description Action text
update_unit_billing_code Activation code parameter update Activation code updated.
share_billing_code Billing codes Code ‘%s’ shared with account ‘%s’.
unshare_billing_code Billing codes Code ‘%s’ unshared from account ‘%s’.

These actions aren’t available in Wialon Local.

Tasks

Action ID Action description Action text
create_task Task manager Task ‘%s’ created.
update_task_priority Task manager Priority of task ‘%s’ changed to ‘%s’.
update_task_status Task manager Status of task ‘%s’ changed to ‘%s’.
update_task_assignee Task manager Assignee of task ‘%s’ changed to ‘%s’.
add_task_comment Task manager Comment added to task ‘%s’.
edit_task_comment Task manager Comment on task ‘%s’ edited.
delete_task_comment Task manager Comment on task ‘%s’ deleted.
delete_task Task manager Task ‘%s’ deleted.

In Wialon Local, these actions are available starting from version 2504.

Maps provider keys

Action ID Action description Action text
create_map_key Maps provider Key ‘%s’ added.
update_map_key Maps provider Key ‘%s’ updated.
delete_map_key Maps provider Key ‘%s’ deleted.

In Wialon Local, these actions are available starting from version 2304.

Video

Action ID Action description Action text
video_enabled_for_unit Video
  • The video functionality and billing are activated for unit ‘%s’.
  • The video functionality and billing are activated.
video_disabled_for_unit Video
  • The video functionality and billing are deactivated for unit ‘%s’.
  • The video functionality and billing are deactivated.
update_video_settings Video
  • Video settings for unit ‘%s’ were changed.
  • Video settings were changed.
file_saved Video The file is saved successfully.
file_not_saved Video The file is not saved.
delete_file Video
  • The file for unit ‘%s’ was deleted.
  • The file was deleted.
buy_packages_manually Video
  • Traffic packages (%d) were bought for unit ‘%s’.
  • Traffic packages (%d) were bought.
automatic_packages_purchase_limit_change Video
  • The limit for automatic traffic package purchase changed to ‘%d’ for unit ‘%s’.
  • The limit for automatic traffic package purchase was changed to ‘%d’.
update_video_packets_auto Video Traffic packages (%d) were bought.
video_autopay_successed Video Traffic package purchased automatically.
video_autopay_failed Video Failed to purchase a traffic package automatically.

For the actions with two texts, the first one is used if the corresponding parameter contains the unit name.

These actions aren’t available in Wialon Local.

The actions with notices about the expiration of activation codes are recorded in the log of each notice recipient. For each action, the item/add_log_record request is sent with the following parameters:

action itemId newValue oldValue
create_notice Recipient user ID Notice name "" (empty)
update_notice Recipient user ID New notice name "" (empty)
delete_notice Recipient user ID Notice name "" (empty)

Returned result

If the request is successful, an empty JSON is returned.

Copied!
{ }

If not, an error code is returned. Possible error codes:

Code Description
7 The item doesn’t exist, or the user doesn’t have the Manage log access right to it.
4 Wrong input parameters.

If you find a mistake in the text, please select it and press Ctrl+Enter.