Some checks failed
Build & Deploy docs / build-deploy (push) Failing after 10m17s
- Nouveau générateur scripts/gen_api_reference.py : 19 namespaces → docs/api/metier/ (10) + docs/api/systeme/ (9) + notifications.md + types.md (96 types · 55 enums · 4 flags) + SUMMARY.md literate-nav - Badges permissionScope (perm-none/control/configure/admin) dans extra.css - Guide docs/integrations/jsonrpc-api.md (connexion TCP/WS, auth, conventions énergie) - mkdocs.yml : Référence API dans la nav, REST→JsonRPC renommé - mkdocs build --strict : 0 warnings · --check idempotent Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
286 lines
5.9 KiB
Markdown
286 lines
5.9 KiB
Markdown
# Users
|
|
|
|
<!-- BEGIN GENERATED: __api_Users__ -->
|
|
## Méthodes
|
|
|
|
### Users.ChangePassword
|
|
|
|
<span class="badge perm-admin">ADMIN</span>
|
|
|
|
Change the password for the currently logged in user.
|
|
|
|
**Paramètres :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `newPassword` | `String` | |
|
|
|
|
**Retour :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `error` | [UserError](../types.md#usererror) | |
|
|
|
|
---
|
|
|
|
### Users.ChangeUserPassword
|
|
|
|
<span class="badge perm-admin">ADMIN</span>
|
|
|
|
Change the password for the given user. All tokens for this user will be removed in order to force all clients to log in again.
|
|
|
|
**Paramètres :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `newPassword` | `String` | |
|
|
| `username` | `String` | |
|
|
|
|
**Retour :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `error` | [UserError](../types.md#usererror) | |
|
|
|
|
---
|
|
|
|
### Users.CreateUser
|
|
|
|
<span class="badge perm-admin">ADMIN</span>
|
|
|
|
Create a new user in the API with the given username and password. Use scopes to define the permissions for the new user. If the user has not the permission "PermissionScopeAccessAllThings", the list of things this user has access to can be defined in the "allowedThingIds" property. If no scopes are given, this user will be an admin user. Call Authenticate after this to obtain a device token for this user.
|
|
|
|
**Paramètres :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `allowedThingIds` | `Uuid`[] | optionnel |
|
|
| `displayName` | `String` | optionnel |
|
|
| `email` | `String` | optionnel |
|
|
| `scopes` | [PermissionScopes](../types.md#permissionscopes) | optionnel |
|
|
| `password` | `String` | |
|
|
| `username` | `String` | |
|
|
|
|
**Retour :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `error` | [UserError](../types.md#usererror) | |
|
|
|
|
---
|
|
|
|
### Users.GetTokens
|
|
|
|
<span class="badge perm-admin">ADMIN</span>
|
|
|
|
Get all the tokens for the current user.
|
|
|
|
**Paramètres :**
|
|
|
|
_Aucun paramètre._
|
|
|
|
**Retour :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `error` | [UserError](../types.md#usererror) | |
|
|
| `tokenInfoList` | [TokenInfoList](../types.md#tokeninfolist) | optionnel |
|
|
|
|
---
|
|
|
|
### Users.GetUserInfo
|
|
|
|
<span class="badge perm-none">PUBLIC</span>
|
|
|
|
Get info about the current token (the currently logged in user).
|
|
|
|
**Paramètres :**
|
|
|
|
_Aucun paramètre._
|
|
|
|
**Retour :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `error` | [UserError](../types.md#usererror) | |
|
|
| `userInfo` | [UserInfo](../types.md#userinfo) | optionnel |
|
|
|
|
---
|
|
|
|
### Users.GetUserTokens
|
|
|
|
<span class="badge perm-admin">ADMIN</span>
|
|
|
|
Get all the tokens for the given username.
|
|
|
|
**Paramètres :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `username` | `String` | |
|
|
|
|
**Retour :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `error` | [UserError](../types.md#usererror) | |
|
|
| `tokenInfoList` | [TokenInfoList](../types.md#tokeninfolist) | optionnel |
|
|
|
|
---
|
|
|
|
### Users.GetUsers
|
|
|
|
<span class="badge perm-admin">ADMIN</span>
|
|
|
|
Return a list of all users in the system.
|
|
|
|
**Paramètres :**
|
|
|
|
_Aucun paramètre._
|
|
|
|
**Retour :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `users` | [UserInfoList](../types.md#userinfolist) | |
|
|
|
|
---
|
|
|
|
### Users.RemoveToken
|
|
|
|
<span class="badge perm-admin">ADMIN</span>
|
|
|
|
Revoke access for a given token. Depending on the logged in user only the own tokens can be removed. If you are logged in as admin, any token can be removed.
|
|
|
|
**Paramètres :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `tokenId` | `Uuid` | |
|
|
|
|
**Retour :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `error` | [UserError](../types.md#usererror) | |
|
|
|
|
---
|
|
|
|
### Users.RemoveUser
|
|
|
|
<span class="badge perm-admin">ADMIN</span>
|
|
|
|
Remove a user from the system.
|
|
|
|
**Paramètres :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `username` | `String` | |
|
|
|
|
**Retour :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `error` | [UserError](../types.md#usererror) | |
|
|
|
|
---
|
|
|
|
### Users.SetUserInfo
|
|
|
|
<span class="badge perm-admin">ADMIN</span>
|
|
|
|
Change user info. If username is given, info for the respective user is changed, otherwise the current user info is edited. Requires admin permissions to edit user info other than the own.
|
|
|
|
**Paramètres :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `displayName` | `String` | optionnel |
|
|
| `email` | `String` | optionnel |
|
|
| `username` | `String` | optionnel |
|
|
|
|
**Retour :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `error` | [UserError](../types.md#usererror) | |
|
|
|
|
---
|
|
|
|
### Users.SetUserScopes
|
|
|
|
<span class="badge perm-admin">ADMIN</span>
|
|
|
|
Set the permissions (scopes) for a given user. If the user has not the permission "PermissionScopeAccessAllThings" the list of thing IDs this user has access to can be defined in the "allowedThingIds" property.
|
|
|
|
**Paramètres :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `allowedThingIds` | `Uuid`[] | optionnel |
|
|
| `scopes` | [PermissionScopes](../types.md#permissionscopes) | |
|
|
| `username` | `String` | |
|
|
|
|
**Retour :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `error` | [UserError](../types.md#usererror) | |
|
|
|
|
---
|
|
|
|
## Notifications
|
|
|
|
### Users.PushButtonAuthFinished
|
|
|
|
Emitted when a push button authentication reaches final state. NOTE: This notification is special. It will only be emitted to connections that did actively request a push button authentication, but also it will be emitted regardless of the notification settings.
|
|
|
|
**Paramètres :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `token` | `String` | optionnel |
|
|
| `success` | `Bool` | |
|
|
| `transactionId` | `Int` | |
|
|
|
|
---
|
|
|
|
### Users.UserAdded
|
|
|
|
Emitted when a user is added to the system.
|
|
|
|
**Paramètres :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `userInfo` | [UserInfo](../types.md#userinfo) | |
|
|
|
|
---
|
|
|
|
### Users.UserChanged
|
|
|
|
Emitted whenever a user is changed.
|
|
|
|
**Paramètres :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `userInfo` | [UserInfo](../types.md#userinfo) | |
|
|
|
|
---
|
|
|
|
### Users.UserRemoved
|
|
|
|
Emitted when a user is removed from the system.
|
|
|
|
**Paramètres :**
|
|
|
|
| Champ | Type | Notes |
|
|
| --- | --- | --- |
|
|
| `username` | `String` | |
|
|
|
|
---
|
|
|
|
<!-- END GENERATED -->
|