---
title: "POST /api/rpc/queryUsers"
method: POST
path: "/api/rpc/queryUsers"
tags: ["users"]
---

# POST /api/rpc/queryUsers

`POST /api/rpc/queryUsers`

## Request

- Base URL: `https://21risk.com`
- URL: `https://21risk.com/api/rpc/queryUsers`
- Auth: OAuth 2 (client credentials, token URL `/api/v1/oauth/token`)

Get all users (members) in a group. Supports pagination, filtering by name, email, status, and group membership.

## Request body

- object
  - `tenant` unknown, required
  - `query` string
  - `sites` unknown
  - `userType` string: Valid operands: user, agent. Comma-separated values for OR, semicolon for AND. Use ! to exclude, ^ for exact match, * for any value, !* for empty.
  - `groups` string: Operands must represent integer IDs, such as "1,2" or "!3". Comma-separated values for OR, semicolon for AND. Use ! to exclude, ^ for exact match, * for any value, !* for empty.
  - `status` string: Valid operands: activeMember, deleted, neverSeen, passiveMember. Comma-separated values for OR, semicolon for AND. Use ! to exclude, ^ for exact match, * for any value, !* for empty.
  - `name` string: Plain text means contains. Use operators: contains, equal, startswith, endswith. Prefix with ! to negate.
  - `email` string: Plain text means contains. Use operators: contains, equal, startswith, endswith. Prefix with ! to negate.
  - `includes` string[]: Only include records whose IDs are in this list.
  - `excludes` string[]: Exclude records whose IDs are in this list.
  - `after` string: Cursor-based pagination: return results after this cursor. Use pageInfo.endCursor from the previous page.
  - `before` string: Cursor-based pagination: return results before this cursor. Use pageInfo.startCursor from the current/previous page.
  - `first` union
    - integer
    - 'all'
  - `last` integer: Cursor-based pagination: number of results to return before the before cursor. Use for backward pagination.
  - `sort` 'name' | 'email' | 'status' | 'createdDate'
  - `direction` 'asc' | 'desc'

## Response `200`

Successful response

---

[API](https://skmtc.dev/21risk/apis/21risk-api.md) · [All operations](https://skmtc.dev/21risk/apis/21risk-api/llms.txt) · [OpenAPI document](https://skmtc.dev/21risk/apis/21risk-api/revisions/273a727dfd49?raw)
