io.enterpriseai.resources.RedteamClient
Source: sdks/java/enterprise-ai-java/src/main/java/io/enterpriseai/resources/RedteamClient.java. Back to the Java SDK reference index.
This page is generated by tools/docs/gen_sdk_reference.py from the SDK sources and the OpenAPI text folders. Do not edit it by hand: change the source and regenerate.
Class RedteamClient
Red team runs.
Constructor RedteamClient
RedteamClient(Transport transport)
Creates the client on the shared transport; EnterpriseAIClient builds it and exposes it through the accessor of the same name.
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
transport | Transport | yes | Transport shared by the sub-clients of one client. |
RedteamClient.createRun
JsonNode createRun(Object body)
Run a red team campaign. Sends adversarial probes to the target and stores the findings. Needs tenant_admin, developer, security_officer or ai_governance_officer.
Route: /v1/redteam/runs (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
body | Object | yes | Target, engine, probes and accepted attack success rate. |
Returns: JsonNode. Decoded JSON answer of the operation "Run a red team campaign".
Raises: the typed errors of the transport (Errors).
RedteamClient.createRun
JsonNode createRun(Object body, RequestOptions options)
Run a red team campaign. Sends adversarial probes to the target and stores the findings. Needs tenant_admin, developer, security_officer or ai_governance_officer.
Route: /v1/redteam/runs (POST).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
body | Object | yes | Target, engine, probes and accepted attack success rate. | |
options | RequestOptions | yes | Per call options (idempotency key, traceparent, headers, abort signal). |
Returns: JsonNode. Decoded JSON answer of the operation "Run a red team campaign".
Raises: the typed errors of the transport (Errors).
RedteamClient.getRun
JsonNode getRun(String id)
Get a red team run. Returns one red team run: target, engine, probes, status, summary (total, vulnerable, attack success rate, threshold, per category) and findings. Open to any member of the tenant. Answers 404 not_found.
Route: /v1/redteam/runs/{run_id} (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
id | String | yes | Identifier (UUID) of the red team run. |
Returns: JsonNode. Decoded JSON answer of the operation "Get a red team run".
Raises: the typed errors of the transport (Errors).
RedteamClient.listRuns
Page<JsonNode> listRuns()
List the red team runs. Lists the red team runs of the tenant, newest identifier first, paginated, and probes: the builtin probes (id and category), the garak probe families and whether garak is installed. Open to any member of the tenant.
Route: /v1/redteam/runs (GET).
This element takes no parameter.
Returns: Page<JsonNode>. A Page: One page of a cursor paginated collection ({"items": [...], "next_cursor": "..."|null}).
Raises: the typed errors of the transport (Errors).
RedteamClient.listRuns
Page<JsonNode> listRuns(Map<String, ?> query)
List the red team runs. Lists the red team runs of the tenant, newest identifier first, paginated, and probes: the builtin probes (id and category), the garak probe families and whether garak is installed. Open to any member of the tenant.
Route: /v1/redteam/runs (GET).
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
query | Map<String, ?> | yes | Query string parameters of the route. |
Returns: Page<JsonNode>. A Page: One page of a cursor paginated collection ({"items": [...], "next_cursor": "..."|null}).
Raises: the typed errors of the transport (Errors).