| POST | /admin/v1/user_tokens/register_websocket | Generate a one time token for registering websocket. |
|---|
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| ApplicationsId | body | int? | No |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| UserTokens | form | List<UserTokens> | No |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| Status | form | ApiResponseStatus | No | |
| Code | form | int | No | |
| apiVersion | form | string | No | |
| appVersion | form | string | No |
| OK | |
| FAIL | |
| Default |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| Id | form | int | No | |
| ApplicationsId | form | int | No | |
| UsersId | form | int | No | |
| UserTokenActionsId | form | int | No | |
| Token | form | string | No | |
| UsedAt | form | DateTime? | No | |
| ActiveTill | form | DateTime | No | |
| RecordStatusId | form | int | No |
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /admin/v1/user_tokens/register_websocket HTTP/1.1
Host: auth.mepis.si
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
applicationsId: 0
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
appVersion: String,
userTokens:
[
{
id: 0,
applicationsId: 0,
usersId: 0,
userTokenActionsId: 0,
token: String,
usedAt: 0001-01-01,
activeTill: 0001-01-01,
recordStatusId: 0
}
],
status: OK,
code: 0,
apiVersion: String
}