API employee EN: различия между версиями
Нет описания правки |
IronBot (обсуждение | вклад) (Fix Ukrainian API localization) |
||
| (не показаны 3 промежуточные версии этого же участника) | |||
| Строка 1: | Строка 1: | ||
[[ | '''en''' | [[API_employee_UK|uk]] | [[API employee|ru]] | ||
Section '''[[API_EN|API]]''' ERP "UserSide" | Section '''[[API_EN|API]]''' ERP "UserSide" | ||
| Строка 15: | Строка 15: | ||
Description: Create a PUSH notification for an employee | Description: Create a PUSH notification for an employee | ||
Required parameters: | |||
employee_id - employee ID | employee_id - employee ID | ||
body - text | body - text | ||
Optional parameters: | Optional parameters: | ||
color - HTML color of the notification window | |||
==== address_access_add ==== | ==== address_access_add ==== | ||
| Строка 25: | Строка 25: | ||
''Added in: 3.18beta1'' | ''Added in: 3.18beta1'' | ||
Description: | Description: Add an address object to the available addresses for an employee | ||
Required parameters: | |||
employee_id - id of the employee | employee_id - id of the employee | ||
address_id - | address_id - address object id ''(-1 for all addresses, -2 for objects without an address)'' | ||
is_write - flag - write access | is_write - flag - write access | ||
| Строка 36: | Строка 36: | ||
Description: List of available address objects for an employee | Description: List of available address objects for an employee | ||
Required parameters: | |||
employee_id - employee id | employee_id - employee id | ||
is_write - flag - write access | is_write - flag - write access | ||
| Строка 45: | Строка 45: | ||
Description: Remove an address object from the available addresses for an employee | Description: Remove an address object from the available addresses for an employee | ||
Required parameters: | |||
employee_id - id of the employee | employee_id - id of the employee | ||
address_id - | address_id - address object id ''(-1 for all addresses, -2 for objects without an address)'' | ||
==== check_pass ==== | ==== check_pass ==== | ||
''Added to: 3.16dev2'' | ''Added to: 3.16dev2'' | ||
Description: | Description: Check whether the login and password match for UserSide authentication | ||
Required parameters: | |||
login - login | login - login | ||
pass - password | pass - password | ||
| Строка 59: | Строка 59: | ||
==== edit ==== | ==== edit ==== | ||
''Modified in: 3.19.40 (added ip_phone parameter)'' | |||
''Modified in: 3.19.33 (added is_blocked parameter)'' | |||
''Added in: 3.18beta1'' | ''Added in: 3.18beta1'' | ||
Description: Edit employee record | Description: Edit employee record | ||
Required parameters: | |||
id - id of the employee | id - id of the employee | ||
Optional parameters: | Optional parameters: | ||
| Строка 70: | Строка 74: | ||
date_out - date of resignation | date_out - date of resignation | ||
first_name - name | first_name - name | ||
gps_id - IMEI | gps_id - GPS tracker IMEI | ||
ip_phone - IP phone number | |||
is_blocked - flag - block/unblock the account | |||
middle_name - middle name | middle_name - middle name | ||
last_name - surname | last_name - surname | ||
| Строка 85: | Строка 91: | ||
==== get_division ==== | ==== get_division ==== | ||
''Added in: 3.16dev2'' | ''Added in: 3.16dev2'' | ||
Description: Retrieve information | Description: Retrieve division information | ||
Optional parameters: | Optional parameters: | ||
id - | id - division ID ''(can be comma separated)'' | ||
==== get_division_list ==== | ==== get_division_list ==== | ||
''Added in: 3.16dev2'' | ''Added in: 3.16dev2'' | ||
Description: List of | Description: List of divisions | ||
==== get_employee_id ==== | ==== get_employee_id ==== | ||
| Строка 98: | Строка 104: | ||
''Added in: 3.16dev2'' | ''Added in: 3.16dev2'' | ||
Description: Retrieve employee ID from | Description: Retrieve employee ID from input data | ||
Required parameters: | Required parameters: | ||
data_typer - type of data we are checking ''(possible values: additional_field_XXX, name, login, messenger_chat_id)'' | data_typer - type of data we are checking ''(possible values: additional_field_XXX, name, login, messenger_chat_id)'' | ||
| Строка 107: | Строка 113: | ||
''Added in: 3.16dev2'' | ''Added in: 3.16dev2'' | ||
Description: Action history ''(limit 10000 records in sample results)'' | Description: Action history ''(limit 10000 records in the sample results)'' | ||
Required parameters: | |||
date_from - sampling start date ''(from)'' | date_from - sampling start date ''(from)'' | ||
date_to - sampling end date ''(to)'' | date_to - sampling end date ''(to)'' | ||
| Строка 125: | Строка 131: | ||
''Added in: 3.16dev2'' | ''Added in: 3.16dev2'' | ||
Description: Retrieve information from timesheets | Description: Retrieve information from timesheets | ||
Required parameters: | |||
date_from - start date of sampling | date_from - start date of sampling | ||
date_to - sampling end date | date_to - sampling end date | ||
| Строка 134: | Строка 140: | ||
==== get_work_time_data ==== | ==== get_work_time_data ==== | ||
''Added in: 3.17dev1'' | ''Added in: 3.17dev1'' | ||
Description: Retrieve information | Description: Retrieve employee working time information | ||
Required parameters: | |||
date_from - start date of sampling | date_from - start date of sampling | ||
date_to - date of sampling end | date_to - date of sampling end | ||
| Строка 144: | Строка 150: | ||
''Added in: 3.18beta1'' | ''Added in: 3.18beta1'' | ||
Description: Retrieve information | Description: Retrieve employee unavailability information ''(holiday, sick leave)'' | ||
Required parameters: | |||
None | None | ||
Optional parameters: | Optional parameters: | ||
| Строка 158: | Строка 164: | ||
Description: Add/modify/delete an entry in the timesheet | Description: Add/modify/delete an entry in the timesheet | ||
Required parameters: | |||
employee_id - employee id | employee_id - employee id | ||
date - date | date - date | ||
| Строка 168: | Строка 174: | ||
Description: Add/modify/delete employee unavailability record ''(holiday, sick leave)'' | Description: Add/modify/delete employee unavailability record ''(holiday, sick leave)'' | ||
Required parameters: | |||
employee_id - employee ID | employee_id - employee ID | ||
date_from - period start date | date_from - period start date | ||
| Строка 179: | Строка 185: | ||
''Added in: 3.18beta1'' | ''Added in: 3.18beta1'' | ||
Description: | Description: Add an address object to the list of addresses where an employee can be assigned to work | ||
Required parameters: | Required parameters: | ||
employee_id - id of employee | employee_id - id of employee | ||
address_id - | address_id - address object id ''(-1 for all addresses, -2 for objects without an address)'' | ||
==== task_address_access_list ==== | ==== task_address_access_list ==== | ||
| Строка 188: | Строка 194: | ||
''Added in: 3.18beta1'' | ''Added in: 3.18beta1'' | ||
Description: | Description: List of addresses where an employee can be assigned to jobs | ||
Required parameters: | |||
employee_id - employee id | employee_id - employee id | ||
| Строка 196: | Строка 202: | ||
''Added in: 3.18beta1'' | ''Added in: 3.18beta1'' | ||
Description: | Description: Remove an address object from the list of addresses where an employee can be assigned to work | ||
Required parameters: | |||
employee_id - id of employee | employee_id - id of employee | ||
address_id - | address_id - address object id ''(-1 for all addresses, -2 for objects without an address)'' | ||
==== work_time_finish ==== | ==== work_time_finish ==== | ||
''Added to: 3.16dev5'' | ''Added to: 3.16dev5'' | ||
Description: | Description: Record the end of an employee's working time | ||
Required parameters: | |||
employee_id - employee id | employee_id - employee id | ||
date - date and time | date - date and time | ||
| Строка 212: | Строка 218: | ||
==== work_time_start ==== | ==== work_time_start ==== | ||
''Added to: 3.16dev5'' | ''Added to: 3.16dev5'' | ||
Description: | Description: Record the start of an employee's working time | ||
Required parameters: | |||
employee_id - employee id | employee_id - employee id | ||
date - date and time | date - date and time | ||
Optional parameters: | Optional parameters: | ||
comment - notes | comment - notes | ||
==== division_employee_add ==== | |||
''Added in: 3.19.44'' | |||
Description: Assign an employee to a division | |||
Required parameters: | |||
division_id - division ID | |||
employee_id - employee ID | |||
Optional parameters: | |||
position_type - position type [head|deputy|worker] | |||
position_name - position in the division | |||
date_add - assignment date | |||
==== division_employee_remove ==== | |||
''Added in: 3.19.44'' | |||
Description: Remove an employee from a division | |||
Required parameters: | |||
division_id - division ID | |||
employee_id - employee ID | |||
Optional parameters: | |||
date_remove - removal date | |||
Текущая версия от 11:37, 10 мая 2026
Section API ERP "UserSide"
Purpose: Employees
Additional parameters: action - request subcategory (possible value: see below)
Subcategories
add_notification
Added in: 3.18beta1
Description: Create a PUSH notification for an employee Required parameters: employee_id - employee ID body - text Optional parameters: color - HTML color of the notification window
address_access_add
Added in: 3.18beta1
Description: Add an address object to the available addresses for an employee Required parameters: employee_id - id of the employee address_id - address object id (-1 for all addresses, -2 for objects without an address) is_write - flag - write access
address_access_list
Added in: 3.18beta1
Description: List of available address objects for an employee Required parameters: employee_id - employee id is_write - flag - write access
address_access_remove
Added in: 3.18beta1
Description: Remove an address object from the available addresses for an employee Required parameters: employee_id - id of the employee address_id - address object id (-1 for all addresses, -2 for objects without an address)
check_pass
Added to: 3.16dev2
Description: Check whether the login and password match for UserSide authentication Required parameters: login - login pass - password
Since version 3.16.28, the employee's activity date is updated upon successful authentication
edit
Modified in: 3.19.40 (added ip_phone parameter)
Modified in: 3.19.33 (added is_blocked parameter)
Added in: 3.18beta1
Description: Edit employee record Required parameters: id - id of the employee Optional parameters: date_birthday - date of birth date_in - date of employment date_out - date of resignation first_name - name gps_id - GPS tracker IMEI ip_phone - IP phone number is_blocked - flag - block/unblock the account middle_name - middle name last_name - surname position - position short_name - short name/surname messenger_chat_id - telegram/messenger chat_id
get_data
Added in: 3.16dev2
Description: Retrieve information about an employee Optional parameters: id - id of the employee to sample (can be comma separated)
get_division
Added in: 3.16dev2
Description: Retrieve division information Optional parameters: id - division ID (can be comma separated)
get_division_list
Added in: 3.16dev2
Description: List of divisions
get_employee_id
Modified in: 3.18.7 (added possible messenger_chat_id value to data_typer parameter)
Added in: 3.16dev2
Description: Retrieve employee ID from input data Required parameters: data_typer - type of data we are checking (possible values: additional_field_XXX, name, login, messenger_chat_id) data_value - value
get_history
Modified in: 3.16dev6 (added object_id parameter)
Added in: 3.16dev2
Description: Action history (limit 10000 records in the sample results) Required parameters: date_from - sampling start date (from) date_to - sampling end date (to) Optional parameters: employee_id - employee id (can be comma separated) type_id - id of action type (can be comma separated) object_id - id of related object (can be comma separated)
get_history_type
Added in: 3.16dev2
Description: History action types Optional parameters: id - id of action type
get_timesheet_data
Added in: 3.16dev2
Description: Retrieve information from timesheets Required parameters: date_from - start date of sampling date_to - sampling end date Optional parameters: employee_id - employee id (can be comma separated) division_id - division id (can be comma separated)
get_work_time_data
Added in: 3.17dev1
Description: Retrieve employee working time information Required parameters: date_from - start date of sampling date_to - date of sampling end Optional parameters: employee_id - employee id (can be comma separated)
Added in: 3.18beta1
Description: Retrieve employee unavailability information (holiday, sick leave) Required parameters: None Optional parameters: employee_id - employee id date_from - period start date date_to - end date of the period
set_timesheet_data
Modified in: 3.17dev1 (changed value parameter logic)
Added in: 3.16dev2
Description: Add/modify/delete an entry in the timesheet Required parameters: employee_id - employee id date - date type_id - id of record type (1 - basic time, 2 - overtime, 3 - other) value - number of hours (after 3.17dev1: number of hours or text letter to mark non-working period, or empty value to delete the record; before 3.17dev1: integer value, or: 994 - on duty, 995 - off duty, 996 - holiday, 997 - day off, 998 - sick leave, 999 - business trip, or 0 to delete the record)
Added in: 3.17dev1
Description: Add/modify/delete employee unavailability record (holiday, sick leave) Required parameters: employee_id - employee ID date_from - period start date date_to - period end date Optional parameters: type_id - record type id (1 - holiday, 2 - sick leave, not filled - delete record)
task_address_access_add
Added in: 3.18beta1
Description: Add an address object to the list of addresses where an employee can be assigned to work Required parameters: employee_id - id of employee address_id - address object id (-1 for all addresses, -2 for objects without an address)
task_address_access_list
Added in: 3.18beta1
Description: List of addresses where an employee can be assigned to jobs Required parameters: employee_id - employee id
task_address_access_remove
Added in: 3.18beta1
Description: Remove an address object from the list of addresses where an employee can be assigned to work Required parameters: employee_id - id of employee address_id - address object id (-1 for all addresses, -2 for objects without an address)
work_time_finish
Added to: 3.16dev5
Description: Record the end of an employee's working time Required parameters: employee_id - employee id date - date and time Optional parameters: comment - notes
work_time_start
Added to: 3.16dev5
Description: Record the start of an employee's working time Required parameters: employee_id - employee id date - date and time Optional parameters: comment - notes
division_employee_add
Added in: 3.19.44
Description: Assign an employee to a division Required parameters: division_id - division ID employee_id - employee ID Optional parameters: position_type - position type [head|deputy|worker] position_name - position in the division date_add - assignment date
division_employee_remove
Added in: 3.19.44
Description: Remove an employee from a division Required parameters: division_id - division ID employee_id - employee ID Optional parameters: date_remove - removal date