Skip to content

User

User Management.


Create

Create a new user and optionally send an email invitation to join the service. When the user follows the invitation and registers, their email address wil be confirmed before they are logged into the service.

Endpoint

1
POST /user/create

Authorized User Role

1
admin

Request Body

Field Type Required Notes
email string yes User email address.
role string yes Authorized role. Select from "user", "admin" or "owner".
sendInvite boolean Send an email invitation.

Response

A user record.

Field Type Notes
accountId string Owning account ID.
cloudId string Device cloud ID.
email string User email address.
first string First name.
id string User ID.
last string Surname.
role string Authorized role.

Get

Endpoint

1
POST /user/get

Authorized User Role

1
user

Request Body

Field Type Role
email string admin
id string admin

Response

Field Type Notes
accountId string Owning account ID.
cloudId string Device cloud ID.
email string User email address.
first string First name.
id string User ID.
last string Surname.
role string Authorized role.

Find

Endpoint

1
POST /user/find

Authorized User Role

1
user

Request Body

Field Type Role
email string admin
id string admin

Response

Paged response.

Field Type Notes
data array An array of merics.
next string Paged cursor to use for the next page of items.
prev string Pages cursor to use for the previous page of items.

User

An array of User items.

Field Type Notes
accountId string Owning account ID.
cloudId string Device cloud ID.
email string User email address.
first string First name.
id string User ID.
last string Surname.
role string Authorized role.

Login

Login the authenticated user

Endpoint

1
POST /user/login

Authorized User Role

1
public

Request Body

Field Type
invite string

Response

Account and user records with useful cached data.

Field Type Notes
account object
user object

Account

Field Type Notes
closed boolean Set to true when account closed.
cloudId string Owning device cloud ID.
created date Date account created.
email string Account email.
id string Unique account ID.
name string Account or company name.

User

Field Type Notes
accountId string Owning account ID.
cloudId string Device cloud ID.
email string User email address.
first string First name.
id string User ID.
last string Surname.
role string Authorized role.

Remove

Endpoint

1
POST /user/remove

Authorized User Role

1
admin

Request Body

Field Type
email string
id string

Update

Update a user identity

Endpoint

1
POST /user/update

Authorized User Role

1
user

Request Body

Field Type
email string
first string
id string
last string
preferences object

Response

Field Type Notes
accountId string Owning account ID.
cloudId string Device cloud ID.
email string User email address.
first string First name.
id string User ID.
last string Surname.
role string Authorized role.

UpdateRole

Endpoint

1
POST /user/updateRole

Authorized User Role

1
admin

Request Body

Field Type Role
id string
role string admin
sendInvite boolean

Response

Field Type Notes
accountId string Owning account ID.
cloudId string Device cloud ID.
email string User email address.
first string First name.
id string User ID.
last string Surname.
role string Authorized role.