getEmployees

This call is deprecated. We recommend to use Account Administration API instead.

The corresponding new call is: GET /v1/employee.

Retrieve list of employees.

To create an employee, or update employee information, see API call saveEmployee.

For other employee-related API calls, see:

  • recordGDPRConfirmation - to record that the employee agrees to follow the data protection requirements of General Data Protection Regulation;
  • getSchedule - to retrieve employees' work schedules. (This is a salon-specific feature, and not actively in use any more.)
  • getTimeSlots - to retrieve available time slots in employee's schedule. (This is a salon-specific feature, and not actively in use any more.)

Input parameters

Parameter name Description Possible value Required
employeeID Employee's ID integer
searchName Search from employee name, e-mail or phone. string
changedSince Retrieve only items that have been added or modified since the specified timestamp. Use it to keep a local database in sync with Erply. Integer (Unix timestamp)
userGroupID Get employees that belong to a specific user group. Note that if employee does not have a user account, it will never be returned when using this filter. integer
usernameOrEmail Search for a specific employee by user name or e-mail address. integer
warehouseID Get employees that work in a particular location (have access rights for a particular location). integer
drawerID Get employees that use the given drawer id. string
getProductInfo Set this to 1 if you are using Salon / Spa module and want to get a list of services (products) that each stylist performs. This information will be returned in attribute productIDs - see below. Integer - 1 or 0
birthdayMonthDayFrom

Filter employees by birthday — get all employees whose birthday is on or after the specified month and day.

If you only specify birthdayMonthDayFrom and not birthdayMonthDayTo, all birthdays between the specified day and the end of the year are returned.

Combine the two filters to get birthdays in a specific range (eg. birthdays in June or July). Year wrap-around is supported: filter birthdayMonthDayFrom = "12-01", birthdayMonthDayTo = "01-31" returns birthdays in December and January.

Both month and day must be two digits. Use a leading zero if necessary.

String (mm-dd)
birthdayMonthDayTo

Filter employees by birthday — get all employees whose birthday is on or before the specified month and day.

If you only specify birthdayMonthDayTo and not birthdayMonthDayFrom, all birthdays between the beginning of the year and the specified day are returned.

Combine the two filters to get birthdays in a specific range (eg. birthdays in June or July). Year wrap-around is supported: filter birthdayMonthDayFrom = "12-01", birthdayMonthDayTo = "01-31" returns birthdays in December and January.

Both month and day must be two digits. Use a leading zero if necessary.

String (mm-dd)
searchAttributeName Name of attribute to search from. Both "searchAttributeName" and "searchAttributeValue" have to be specified. Error 1030 will be returned if value is an array. string
searchAttributeValue Attribute value to search for. Error 1030 will be returned if value is an array. string
lang Retrieve item names in a specific language. If omitted, API will return item names in the default language of your Erply account.
Possible values:
  • 'eng' - English
  • 'spa' - Spanish
  • 'ger' - German
  • 'swe' - Swedish
  • 'fin' - Finnish
  • 'rus' - Russian
  • 'est' - Estonian
  • 'lat' - Latvian
  • 'lit' - Lithuanian
  • 'gre' - Greek
string
orderBy 'employeeID', 'name', 'group' or 'lastChanged'. By default 'name'.
orderByDir Sort direction: 'asc' (ascending order) or 'desc' (descending order). By default, items are sorted in ascending order. string
recordsOnPage Number of records API should return. By default 20, at most 100. integer
pageNo API returns at most recordsOnPage items at a time. To retrieve the next recordsOnPage items, send a new request with pageNo incremented by one. By default, API returns "page 1". integer

Response

Field name Type Description
employeeID integer (deprecated alternative name: id)
fullName string Full name of the customer, use for displaying customer name.
employeeName string For companies only.
firstName string (Given name.) For persons only.
lastName string (Surname.) For persons only.
phone string
mobile string
email string
fax string
code string National ID number
gender string Gender: "male", "female" or empty string
userID Integer string If employee does not have user account, this attribute is not returned.
username string If employee does not have user account, this attribute is not returned.
userGroupID Integer string If employee does not have user account, this attribute is not returned.
performsColoring integer 0 or 1. DO NOT USE - NOT A STANDARD FIELD. Indicates whether this employee performs coloring.
warehouses array Array of locations (warehouse IDs) in which the employee is working.
In other words, the locations for which the employee has access rights. Array elements have the following structure:
Field nameTypeDescription
idIntegerWarehouse ID
pointsOfSale string A comma-separated list of registers (Point of sale IDs) in which the employee is working.
In other words, the registers for which the employee has access rights.

Attributes warehouses and pointsOfSale both show basically the same information, because user rights are defined per-location. Using pointsOfSale just saves you the trouble of looking up register IDs for each location.
productIDs array Salon-specific attribute. Available only if Salon / Spa module is enabled on your account, and if you have set getProductInfo parameter to 1.

A list of services that the stylist / attendant performs. (Services are also listed in the products table, although marked as "non-stock products" - that's why this attribute returns product IDs.)

Each element of the array has the following parameters:
Field nameTypeDescription
productIDIntegerProduct (service) ID
productCodeStringProduct (service) code
productNameStringProduct (service) name
productGroupIntegerProduct (service) group

For other salon-related API calls, see getSchedule and getTimeSlots. To get a list of all salon services, use API call getProducts with parameter nonStockProduct set to 1.
attributes array Additional attributes. Each item looks like this:

Field nameTypeDescription
attributeNameStringAttribute name
attributeTypeStringAttribute type
attributeValueStringAttribute value
lastModified integer Unix timestamp. Last modification time.
lastModifiedByUserName string

Detail Response

Field name Type Description
skype string
birthday Date (yyyy-mm-dd) Person's birthday
jobTitleID integer Person's job title ID
jobTitleName string
notes string
drawerID string Drawer id for the employee. Used only when drawer counting feature is enabled on the account.
added integer Unix timestamp. Creation time.