Get a directory group
GET /v1/directories/{directory_id}/groups/{directory_group_id} · permission directories:read
Returns one group the identity provider provisioned into the directory: ID, external ID, display name and member count; never a member. To list a group's members use GET /v1/directories/{directory_id}/users?group_id=….
Request
| Field | Type | Required | Description |
|---|---|---|---|
directory_id |
path | yes | SCIM directory ID (dir_…). |
directory_group_id |
path | yes | Directory group ID (dsg_…). |
There is no request body.
Response
200 OK with the group.
{
"id": "dsg_01j9xn3p5q7r9s1t3v5w7x9y1a",
"external_id": "00g1a2b3c4",
"name": "Engineering",
"member_count": 12
}
Errors
| HTTP | code | When |
|---|---|---|
| 404 | not_found |
The directory or the group does not exist in this environment, or the group belongs to another directory. |
| 401 | unauthenticated |
The credential is missing, invalid or revoked. |
| 403 | insufficient_permissions |
The credential lacks the required permission. |
| 429 | rate_limited |
The rate limit was exceeded; retry after the Retry-After period. |
| 503 | service_unavailable |
Directory sync is temporarily unavailable or not configured in this deployment; retry after the Retry-After period. |
Example
curl -i "https://api.eu.keenauth.com/v1/directories/dir_01j9xm2n4p6q8r0s2t4v6w8y0z/groups/dsg_01j9xn3p5q7r9s1t3v5w7x9y1a" \
-H "Authorization: Bearer $KEENAUTH_SECRET_KEY"