EmployeesApi employeesApi = client.getEmployeesApi();
EmployeesApi
ListEmployees
CompletableFuture<ListEmployeesResponse> listEmployeesAsync(
final String locationId,
final String status,
final Integer limit,
final String cursor)
Parameter | Type | Tags | Description |
---|---|---|---|
locationId |
String |
Query, Optional | - |
status |
String |
Query, Optional | Specifies the EmployeeStatus to filter the employee by. |
limit |
Integer |
Query, Optional | The number of employees to be returned on each page. |
cursor |
String |
Query, Optional | The token required to retrieve the specified page of results. |
String locationId = "location_id4";
String status = "ACTIVE";
Integer limit = 172;
String cursor = "cursor6";
employeesApi.listEmployeesAsync(locationId, status, limit, cursor).thenAccept(result -> {
// TODO success callback handler
}).exceptionally(exception -> {
// TODO failure callback handler
return null;
});
RetrieveEmployee
CompletableFuture<RetrieveEmployeeResponse> retrieveEmployeeAsync(
final String id)
Parameter | Type | Tags | Description |
---|---|---|---|
id |
String |
Template, Required | UUID for the employee that was requested. |
String id = "id0";
employeesApi.retrieveEmployeeAsync(id).thenAccept(result -> {
// TODO success callback handler
}).exceptionally(exception -> {
// TODO failure callback handler
return null;
});