Skip to Content
kosemdocs
ReferenceAPIEnvironments

List access profile environment grants

Lists standalone environments granted a project access profile, newest grant first. Requires connections.accessProfiles.getIamPolicy on the access profile. Returns grant IDs so admins can revoke access directly.

GET
/v1/projects/{project}/accessProfiles/{accessProfile}/environmentGrants

Lists standalone environments granted a project access profile, newest grant first.

Requires connections.accessProfiles.getIamPolicy on the access profile. Returns grant IDs so admins can revoke access directly.

Authorization

bearer
headerAuthorizationBearer <token>

An access token, or an API key.

Path Parameters

project*string

The project's ID.

Match^prj_[0-7][0-9a-hjkmnp-tv-z]{25}$
accessProfile*string

The access profile's ID.

Match^acp_[0-7][0-9a-hjkmnp-tv-z]{25}$

Query Parameters

pageSize?integer

Maximum number of items to return.

Formatint32
Range0 <= value <= 500
pageToken?string

Page token from a previous response.

Response Body

OK

application/json
  1. response
grants*array<>

Standalone environments granted access to this resource, newest grant first.

nextPageToken*string

Token for the next page; empty on the last page.

Example Request
curl -X GET 'https://api.kosem.ai/v1/projects/string/accessProfiles/string/environmentGrants'
Example Response
{
  "grants": [
    {
      "createTime": "2019-08-24T14:15:22Z",
      "displayName": "string",
      "environment": "string",
      "expireTime": "2019-08-24T14:15:22Z",
      "grantId": "string",
      "grantor": "string",
      "lastUsedTime": "2019-08-24T14:15:22Z",
      "scope": {
        "property1": null,
        "property2": null
      },
      "state": "string",
      "useCount": 0
    }
  ],
  "nextPageToken": "string"
}