Grant remote access permission

Grants remote access permission to a specific user. You can specify the user role, duration, and reason for remote access request.

The request consumes and produces an application/json payload.

Endpoint

/api/cluster/v1/remoteaccess/requests

Response format

The AccessRequestData object

Access Request data

Element Type Description
requestId string

Request id

userId string

User id

reason string

Request reason description

requestedDays integer

For how many days access is requested

role string

Requested role

The role element can hold these values.
createdTimestamp integer

Access request created at (timestamp)

expirationTimestamp integer

Access expires at (timestamp)

state string

Access request state

The state element can hold these values.
stateModifiedByUser string

Access request state was modified by user

Possible values

Possible values for the state element in the AccessRequestData object:

  • ACCEPTED
  • EXPIRED
  • PENDING
  • REJECTED

Possible values for the role element in the AccessRequestData object:

  • devops-admin
  • devops-user
  • devops-viewer

Response code

Code Description
201

Successfully created

400

Invalid parameters

403

Approving remote access request is disabled

500

Operation failed

513

Mission Control is unavailable

Example

In this example, you grant the user john.smith@dynatrace.com a remote cluster permission with an admin role for 7 days.

Curl

		  
curl -X POST "https://myManaged.cluster.com/api/cluster/v1/remoteaccess/requests"
          -H  "accept: application/json"
		  -H  "Content-Type: */*"
		  -d "{\"userId\":\"john.smith@dynatrace.com\",\"reason\":\"SUP-123456 Verifying cluster state after upgrade\",\"requestedDays\":7,\"role\":\"devops-admin\"}"
		  

Request URL

https://myManaged.cluster.com/api/cluster/v1/remoteaccess/requests

Request body

api-examples/cluster/remote-access/post-grant-remote-access-permission.json
Download
{
  "userId": "john.smith@dynatrace.com",
  "reason": "SUP-123456 Verifying cluster state after upgrade",
  "requestedDays": 7,
  "role": "devops-admin"
}

Response body

{
  "requestId":"7a397770-86b7-473b-b23e-4a07d79f2eff",
  "userId":"john.smith@dynatrace.com",
  "reason":"SUP-123456 Verifying cluster state after upgrade",
  "requestedDays":7,
  "role":"devops-admin",
  "createdTimestamp":1586452866661,
  "expirationTimestamp":null,
  "state":"PENDING",
  "stateModifiedByUser":null
}

Response code

201