Employees

List all employees

const empList = await ft.employees.list(query);

Get employee by ID

const emp = await ft.employees.get(id);
  • Returns a Promise that resolves to a Freshteam.models.EmployeeDetail object

Create an employee

const newEmp = await ft.employees.create(employee);
  • Returns a Promise that resolves to a Freshteam.models.Employee object
  • The first argument is of type Freshteam.models.EmployeeCreate

Update an employee

const updatedEmp = await ft.employees.update(id, employee);
  • Returns a Promise that resolves to a Freshteam.models.Employee object
  • The first argument is the employee ID
  • The second argument is an object of type Freshteam.models.Employee

List all employee fields

const fields = await ft.employees.fields();
  • Returns a Promise that resolves to an Array of Freshteam.models.EmployeeField objects

Create an employee field

const newEmpField = await ft.employees.createField(field);
  • Returns a Promise that resolves to a Freshteam.models.EmployeeField object
  • The first argument is of type Freshteam.models.EmployeeFieldCreate
Last Updated: