public interface UsersApi extends Api.Simple<User>
| Modifier and Type | Method and Description |
|---|---|
User |
create(User userCreationInfo)
Create a new User.
|
void |
delete(Reference<User> userReference)
Delete a user.
|
User |
get(Reference<User> userReference)
Retrieve an existing user
|
User |
getSelf()
Retrieve the currently authenticated user
|
default List<User> |
list()
Returns a list of your users.
|
List<User> |
list(Boolean isActive,
Instant updatedSince)
Return a list of users, filtered by activity and update date, newest user
first.
|
Pagination<User> |
list(Boolean isActive,
Instant updatedSince,
int page,
int perPage)
Return a list of users, filtered by activity and update date, newest user
first.
|
User |
update(Reference<User> user,
UserUpdateInfo toChange)
Change an existing user.
|
default List<User> list()
List<User> list(Boolean isActive, Instant updatedSince)
isActive - if true, return only getActive users. Set to null to disable
filteringupdatedSince - return only users that have been updated at least 1 second after
updatedSince. Set to null to disable filtering.Pagination<User> list(Boolean isActive, Instant updatedSince, int page, int perPage)
isActive - if true, return only getActive users. Set to null to disable
filteringupdatedSince - return only users that have been updated at least 1 second after
updatedSince. Set to null to disable filtering.page - the page numberperPage - how many results to return for one page. Max 100User create(User userCreationInfo)
create in interface Api.Create<User>userCreationInfo - a user creation object with the wanted properties. Null fields
will get a default value according to the Harvest docsUser getSelf()
User update(Reference<User> user, UserUpdateInfo toChange)
user - a reference to an existing UsertoChange - The properties to be changed. Null fields will be left as is.void delete(Reference<User> userReference)
delete in interface Api.Delete<User>userReference - a reference to an existing User to be deleted