| Requires any of the roles: | Admin, TenantAdmin, AccessAdmin |
| PUT | /BusinessUserAccess | Updates an access for a business user. |
|---|
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| BusinessUserAccessId | body | string | Yes | BusinessUser Access ID |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| ValidFrom | form | string | Yes | Access comes into effect after this time |
| ValidTo | form | string | No | Time when access stops. If you don't specify then access is active for undefined end time. |
| Label | form | string | No | Access label. |
| Spaces | form | List<ThingBusinessUserAccessDto> | Yes | List of spaces that the access is granted for. |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| Version | form | integer | No | Api version |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| ThingId | form | Guid | No | |
| AccessCount | form | int? | No | |
| FromHour | form | TimeSpan? | No | |
| ToHour | form | TimeSpan? | No | |
| Exclusive | form | bool | No |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| Id | form | Guid? | No |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| ResponseStatus | form | ResponseStatus | 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.
PUT /BusinessUserAccess HTTP/1.1
Host: api.4spaces.io
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
businessUserAccessId: 00000000000000000000000000000000,
validFrom: -62135596800000,
validTo: -62135596800000,
label: String,
spaces:
[
{
thingId: 00000000000000000000000000000000,
accessCount: 0,
fromHour: PT0S,
toHour: PT0S,
exclusive: False
}
],
version: 0
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
id: 00000000000000000000000000000000,
responseStatus:
{
errorCode: String,
message: String,
stackTrace: String,
errors:
[
{
errorCode: String,
fieldName: String,
message: String,
meta:
{
String: String
}
}
],
meta:
{
String: String
}
}
}