Get cluster access request

This API call gets cluster access request information for a specific request access ID. The request produces an application/json payload.

Authentication

To execute this request, you need one of the following API-Token scopes:

  • Cluster token management (ClusterTokenManagement)
  • Service Provider API (ServiceProviderAPI )
  • Nodekeeper access for node management (Nodekeeper)
    To learn how to obtain and use it, see Cluster API - Authentication.

Endpoint

/api/cluster/v2/remoteaccess/requests

Parameters

Parameter
Type
Description
In
Required
requestId
string

Request id param

path
required

Response

Response codes

Code
Type
Description
200

Successful

400
-

Bad request

403
-

Approving remote access request is disabled

404
-

Not found

Response body objects

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

  • devops-admin
  • devops-user
  • devops-viewer
createdTimestamp
integer

Access request created at (timestamp)

expirationTimestamp
integer

Access expires at (timestamp)

state
string

Access request state

  • ACCEPTED
  • EXPIRED
  • PENDING
  • REJECTED
stateModifiedByUser
string

Access request state was modified by user

Response body JSON model

{
"requestId": "string",
"userId": "string",
"reason": "string",
"requestedDays": 1,
"role": "devops-admin",
"createdTimestamp": 1,
"expirationTimestamp": 1,
"state": "ACCEPTED",
"stateModifiedByUser": "string"
}

Example

In this example, you request to list remote access permission for a specific request access ID (7a397770-86b7-473b-b23e-4a07d79f2eff). In return, you receive a JSON response that indicates that the request ID 7a397770-86b7-473b-b23e-4a07d79f2eff is for user john.smith@dynatrace.com that has remote access permission with admin role for 7 days and the reason is to verify cluster state after upgrade.

Curl

curl -X GET "https://myManaged.cluster.com/api/cluster/v2/remoteaccess/requests/7a397770-86b7-473b-b23e-4a07d79f2eff"
-H "accept: application/json"

Request URL

https://myManaged.cluster.com/api/cluster/v2/remoteaccess/requests/7a397770-86b7-473b-b23e-4a07d79f2eff

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": 1587081600000,
"state": "ACCEPTED",
"stateModifiedByUser": "katie.novak"
}

Response code

200