Get user permissions
GET/users/{userId}/permissions
Base URL: https://api.tinkermode.com
Get permissions of the user.
Authentication
Send an Authorization header of the form ModeCloud <AUTH_CODE>.
Must contain API key of the matching user, or the API key of a user with management permissions on the all resource type, or a service account token with the matching permission, or a Project API Key with admin permission.
Path parameters
| Name | Type | Required | Constraints | Description |
|---|---|---|---|---|
userId | integer | Yes | The unique ID for the specified user. |
Responses
200 Successfully retrieved user permissions.
Content type: application/json
Represents a permission of user.
An array of objects with the following shape:
| Property | Type | Required | Constraints | Description | ||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
actions | object | Yes | read-only (server-generated) | Resource IDs on which the user can perform actions. If the user has all objects access for the resource type, it contains “*” or “root” instead of listing all resource IDs. | ||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||
resourceType | string | Yes | read-only (server-generated); one of: all, accessControlGroup, user, userLog, home, homeKeyValue, homeLog, homeDevice, homeSmartModuleREST, homeEvent, homeAlert, entityClass, entity, entityMetric, entityBlob, entityAlert, entityAlertRule, entityAssistant, entityScheduledReportConfiguration, entityScheduledReportExecution, entityAppProxy, entityCustomLog, alertRule, projectLog, projectAlert | Resource type | ||||||||||||||||||||||||||||||
401 Authorization is required to access this resource.
Content type: application/json
| Property | Type | Required | Constraints | Description |
|---|---|---|---|---|
data | object | No | read-only (server-generated) | Any relevant data related to error. |
reason | string | Yes | read-only (server-generated) | Reason of error. |
403 Request failed because of denied permission.
Content type: application/json
| Property | Type | Required | Constraints | Description |
|---|---|---|---|---|
data | object | No | read-only (server-generated) | Any relevant data related to error. |
reason | string | Yes | read-only (server-generated) | Reason of error. |
404 The requested permission does not exist or is not accessible.
Content type: application/json
| Property | Type | Required | Constraints | Description |
|---|---|---|---|---|
data | object | No | read-only (server-generated) | Any relevant data related to error. |
reason | string | Yes | read-only (server-generated) | Reason of error. |
429 Request failed because of rate limit.
Content type: application/json
| Property | Type | Required | Constraints | Description |
|---|---|---|---|---|
data | object | No | read-only (server-generated) | Any relevant data related to error. |
reason | string | Yes | read-only (server-generated) | Reason of error. |
500 An unexpected error has occurred.
Content type: application/json
| Property | Type | Required | Constraints | Description |
|---|---|---|---|---|
data | object | No | read-only (server-generated) | Any relevant data related to error. |
reason | string | Yes | read-only (server-generated) | Reason of error. |
503 The service is temporarily unavailable.
Content type: application/json
| Property | Type | Required | Constraints | Description |
|---|---|---|---|---|
data | object | No | read-only (server-generated) | Any relevant data related to error. |
reason | string | Yes | read-only (server-generated) | Reason of error. |