Users
List of valid attributes:
Attribute | Description | Specifics |
---|---|---|
discarded_at | Null or timestamp of removal | Cannot be set |
Email address of the user | Optional, Unique on account if set | |
status | Status of the user | Cannot be set. Is one of created (user can be invited), invited (user was invited), active (user completed the invite and can signin), deactivated (user was deactivated and cannot signin anymore) or deleted . |
name | Name of the user | - |
avatar | Filename of avatar picture | Optional, should be without directory prefixes, e.g. avatar.png |
The following relationships can be included in requests:
Relationship | Type |
---|---|
account | belongs_to |
account_memberships | has_many |
teams | has_many |
team_memberships | has_many |
Meta data: Permissions
Group | Description |
---|---|
actions | Contains permissions to edit or delete , invite a user or revoke an invitation |
Create
Example request:
{ "data": { "type": "user", "attributes": { "name": "Name", } }}
Example response:
{ "data": { "id": "98815bd8-f3e6-41ec-8c4a-25a431ac6ce4", "type": "user", "attributes": { ... } }}
This endpoint creates a user.
HTTP Request
POST /api/v1/users
Update
Example request:
{ "data": { "type": "user", "attributes": { "name": "New Username" } }}
Example response:
{ "data": { "id": "98815bd8-f3e6-41ec-8c4a-25a431ac6ce4", "type": "user", "attributes": { ... } }}
This endpoint updates a user.
HTTP Request
PUT /api/v1/users/:user_id
URL Parameters
Parameter | Description |
---|---|
user_id | The ID of the user to update |
Show
Example response:
{ "data": { "id": "98815bd8-f3e6-41ec-8c4a-25a431ac6ce4", "type": "user", "attributes": { ... } }}
This endpoint returns a user.
HTTP Request
GET /api/v1/users/:user_id
URL Parameters
Parameter | Description |
---|---|
user_id | The ID of the user to return |
List
Example response:
{ "data": [ { "id": "98815bd8-f3e6-41ec-8c4a-25a431ac6ce4", "type": "user", "attributes": { ... } }, { ... } ]}
This endpoint returns users.
HTTP Request
GET /api/v1/users
Delete
Example response:
{ "data": { "id": "98815bd8-f3e6-41ec-8c4a-25a431ac6ce4", "type": "user", "attributes": { ... } }}
This endpoint deletes a user.
HTTP Request
DELETE /api/v1/users/:user_id
URL Parameters
Parameter | Description |
---|---|
user_id | The ID of the user to delete |