Search

getEmployees

Returns an array of employees.

Input parameters

Parameter nameDescriptionPossible valueRequired
employeeIDEmployee's IDInteger
searchNameSearch from employee name, e-mail or phone.String
changedSinceRetrieve 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)
userGroupIDGet 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
usernameOrEmailSearch for a specific employee by user name or e-mail address.Integer
warehouseIDGet employees that work in a particular location (have access rights for a particular location).Integer
getProductInfoSet 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)
searchAttributeNameSearch from attribute name. searchAttributeName and searchAttributeValue have to be specified bothString
searchAttributeValueSearch from attribute valueString
langRetrieve 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'name', 'group' or 'lastChanged'. By default 'name'.
orderByDir
recordsOnPageNumber of records API should return. By default 20, at most 100.Integer
pageNoAPI returns at most recordsOnPage items at a time. To retrive the next recordsOnPage items, send a new request with pageNo incremented by one. By default, API returns "page 1".Integer

Response

Field nameTypeDescription
employeeIDInteger(deprecated alternative name: id)
fullNameStringFull name of the customer, use for displaying customer name.
employeeNameStringFor companies only.
firstNameString(Given name.) For persons only.
lastNameString(Surname.) For persons only.
phoneString
mobileString
emailString
faxString
codeStringNational ID number
genderStringGender: "male", "female" or empty string
userIDInteger stringIf employee does not have user account, this attribute is not returned.
usernameStringIf employee does not have user account, this attribute is not returned.
userGroupIDInteger stringIf employee does not have user account, this attribute is not returned.
performsColoring0 or 1DO NOT USE - NOT A STANDARD FIELD. Indicates whether this employee performs coloring.
warehousesArrayArray 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
pointsOfSaleStringA 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.
productIDsArraySalon-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 getProducts with parameter nonStockProduct set to 1.
attributesArrayAdditional attributes. Each item looks like this:

Field nameTypeDescription
attributeNameStringAttribute name
attributeTypeStringAttribute type
attributeValueStringAttribute value
lastModifiedUnix timestampLast modification time.
lastModifiedByUserNameString
****************To retrieve the following fields, set input parameter responseMode = "detail". These fields are not included in the output by default.
skypeString
birthdayDate (yyyy-mm-dd)Person's birthday
jobTitleIDIntegerPerson's job title ID
jobTitleNameString
notesString
addedUnix timestampCreation time.
****************End of extra output fields