Skip to content

Latest commit

 

History

History
80 lines (58 loc) · 3.08 KB

File metadata and controls

80 lines (58 loc) · 3.08 KB

Update

Update personal access key.

PUT |apiUrl|/api/|apiVersion|/my/personalaccesskey/{id}

URI Parameters

Name Type Description
id UUID id of the personal access key

Body Parameters

Name Type Description
name string name of the personal access key
validTo datetime date when key expires (max 5 years)
scopes string[] table of scopes <list-of-scopes> that is assigned to key

Responses

+------------------------+-------------------------+ | Name +========================+=========+===============+ | 204 No Content +------------------------+-------------------------+

Scopes

Name Description
Account.ReadWrite Grants user possibility to read and write data connected with account

Examples

Sample request

curl -X PUT "|apiUrl|/api/|apiVersion|/my/personalaccesskey/bcc1fdc9-13ee-43b3-a13e-eaba8eaf7996" -H "accept: application/json" -H "Content-Type: application/json-patch+json" -H "Authorization: Bearer <<access token>>" -d "<<body>>"

Body:

{
    "name": "SomeExampleKeyName",
    "validTo": "2021-04-26T06:02:04.197Z",
    "scopes": [
        "Device.Read",
        "Organization.ReadWrite"
    ]
}

Sample response

HTTP status code: 204

{   
    "success": true,
    "errorMessages": [],
    "statusCode": 204
}