This page describes the user management API's for 3DM Publisher.
Please familiarize yourself with the basics first before continuing.
A User models a well-known user of the server.
Properties:
| Property | Required | Type | Description |
|---|---|---|---|
| id | * | number | Unique identifier. |
| username | * | number | Unique name of the user. |
| number | E-mail address of the user. | ||
| first_name | number | First name of the user. | |
| last_name | number | Last name of the user. | |
| description | number | Description of the user. | |
| passwordForceChange | boolean | User is required to set a new password on first login? | |
| passwordLastModified | number | Unix timestamp that was updated on the last password update of the user. |
A Usergroup is a list of users.
Properties:
| Property | Required | Type | Description |
|---|---|---|---|
| id | * | number | Unique identifier. |
| name | * | number | Name of the group. |
| type | team (default) | Type of the group. | |
| user | User[] | The list of users that are in this group. Defines a user reference only (an object with only the id field set) |
This operation retrieves all users.
GET /api/3/user
[ { "id": 28, "username": "test", "email": "test@company.com", "first_name": "Test", "last_name": "User", "password": "test123", "description": "Test user" "language": "english", "preferences": "{}", "description": "Supportl", "passwordLastModified": 1651217754682 }, ... ]
This operation creates a new user account.
The password can be provided in plain text using the password field.
Fields: Model: User
POST /api/3/user
{ "username": "test", "email": "test@company.com", "first_name": "Test", "last_name": "User", "password": "test123", "passwordForceChange": true, "description": "Test user" }
{ "id": 28, "email": "test@company.com", "username": "test", "first_name": "Test", "last_name": "User", "language": "english", "preferences": "{}", "password": "ecd71870d1963316a97e3ac3408c9835ad8cf0f3c1bc703527c30265534f75ae", "description": "Test user", "passwordForceChange": true, "passwordLastModified": 1753874442231 }
{ "code": "field_not_unique", "message": "Uniqueness check failed: Another item with this name value 'test' already exists.", }
The following fields can be updated:
Fields: see Model: User
POST /api/3/user/123
{ "first_name": "John" }
No content
This operation deletes an existing user account.
DELETE /api/3/user/123
No content
{ "code": "not_found", "message": "Delete failed: An item with this id does not exist." }
This operation retrieves all usergroups.
id field filled in.
GET /api/3/usergroup
[ { "id": 4, "name": "TestGroup", "description": "description", "type": "team", "user": [ { "id": 20 } ] }, ... ]
This operation creates a new usergroup.
Fields: Model: User Group Fields: Model: User
POST /api/3/usergroup
{ "name": "TestGroup", "description": "description", "type": "team", "user": [ { "id": 20 } ] }
{ "id": 4, "name": "TestGroup", "description": "description", "type": "team", "user": [ { "id": 20 } ] }
{ "code": "field_not_unique", "message": "Uniqueness check failed: Another item with this name value 'TestGroup' already exists.", }
The following fields can be updated:
Fields: Model: Usergroup
Fields: Model: User
POST /api/3/usergroup/123
{ "name": "Users2", "user": [ { "id": 22 } ] }
No content
This operation deletes an existing usergroup.
DELETE /api/3/usergroup/123
No content
{ "code": "not_found", "message": "Delete failed: An item with this id does not exist." }