Generate activation code for the Privilege Manager client.
HTTP Request
POST /generateActivationCode
Request headers
Header | Value |
Authorization | If required by Recast Agent Gateway configuration |
Key | Authentication key if required by Recast Agent Gateway configuration. Key can be passed also as a URI parameter (like: /computerManagedGroupRules?Key=configuredkey) |
Accept | application/json |
Request Parameters
Following table shows the parameters available for the request.
Parameter | Type | Description |
Key | string | Optional. Authentication key if required by Recast Agent Gateway configuration. Can be passed also as a request header |
Request Body
In the request body, supply a JSON representation for generating activation code. Following table shows the properties that are required or available when you generate activation code.
Property | Type | Description | |
ComputerName | string | NETBIOS name of the computer where activation code needs to be created. | |
ComputerDomain | string |
| |
AADDeviceId | string | Device ID of Azure Active Directory joined device. Required only for AAD joined devices that are used AAD targeted Recast Privilege Manager management rules. | |
UserName | string | User account name for account that has permissions to create activation codes for the computer. | |
UserDomain | string | Domain name of the account that has permissions to create activation codes for the computer:
| |
ValidityTimeIndex | int | Validaty time index value that is allowed for the account specified in UserName field. Must be a value that is configured on Self service configuration. | |
Reason | string | Reason why activation code is needed. | |
TemporaryAccountName | string | Name of the local temporary account to be activated. |
Response
If successful, this method returns a 200 OK response code and a activation code in the response body.
Example
Request
Here is an example of the request.
POST https://cgw.dns.domain/api/v1.0/generateActivationCode
Content-Type: application/json
{
"ComputerName": "CENL02",
"ComputerDomain": "domain.ad",
"UserName": "serviceaccount",
"UserDomain": "domain.ad",
"ValidityTimeIndex": 1,
"Reason": "Printer driver installation",
"TemporaryAccountName": "tempadmin"
}
Response
HTTP/1.1 200 OK
Content-Type: application/json
"12341234123412341234"