class

PlaceOS::Client::APIWrapper::Users

Inherits PlaceOS::Client::APIWrapper::Endpoint::Destroy < PlaceOS::Client::APIWrapper::Endpoint::Fetch < PlaceOS::Client::APIWrapper::Endpoint < Reference < Object

Instance methods

base

The base route for the endpoint

Source
create(email : String, first_name : String, last_name : String, authority_id : String, password : String | Nil = nil, confirm_password : String | Nil = nil, card_number : String | Nil = nil, groups : Array(String) | Nil = nil, image : String | Nil = nil, locatable : Bool | Nil = nil, staff_id : String | Nil = nil, support : Bool | Nil = nil, sys_admin : Bool | Nil = nil, work_overrides : Hash(String, PlaceOS::Model::User::WorktimePreference) | Nil = nil, work_preferences : Array(PlaceOS::Model::User::WorktimePreference) | Nil = nil)

Creates a new user.

Source
current
Source
resource_token
Source
search(q : String | Nil = nil, limit : Int = 20, offset : Int = 0, authority_id : String | Nil = nil, include_deleted : Bool = false, include_metadata : Bool = false)

List or search for users.

Results maybe filtered by specifying a query - q - to search across zone attributes. A small query language is supported within this:

OperatorAction
+Matches both terms
``
-Negates a single token
"Wraps tokens to form a phrase
( )Provides precedence
~NSpecifies edit distance (fuzziness) after a word
~NSpecifies slop amount (deviation) after a phrase

Up to limit zones will be returned, with a paging based on offset.

Results my also also be limited to those associated with specific tags.

Source
update(id : String, email : String | Nil = nil, first_name : String | Nil = nil, last_name : String | Nil = nil, authority_id : String | Nil = nil, password : String | Nil = nil, confirm_password : String | Nil = nil, card_number : String | Nil = nil, groups : Array(String) | Nil = nil, image : String | Nil = nil, locatable : Bool | Nil = nil, staff_id : String | Nil = nil, support : Bool | Nil = nil, sys_admin : Bool | Nil = nil, work_overrides : Hash(String, PlaceOS::Model::User::WorktimePreference) | Nil = nil, work_preferences : Array(PlaceOS::Model::User::WorktimePreference) | Nil = nil)

Updates an existing user.

Source