---
title: "Add a test to a group"
method: POST
path: "/v1/groups/{groupId}/tests"
tags: ["groups"]
---

# Add a test to a group

`POST /v1/groups/{groupId}/tests`

Add an existing test to a test group. Returns 201 when a new membership row was created, or 200 with `added: false` when the test was already a member (idempotent).

## Path parameters

- `groupId` string, uuid, required

## Headers

- `Authorization` string, required

## Request body

- object
  - `testId` string, uuid, required

## Response `200`

Test was already a member; no change

- GroupsAddATestToAGroupResponse200
  - `groupId` string, uuid, required
  - `testId` string, uuid, required
  - `added` boolean, required

## Other responses

- `400` — Bad Request - Invalid input parameters
- `401` — Unauthorized - Invalid or missing API key
- `404` — Not Found - Resource does not exist or is not accessible
- `429` — Too Many Requests - Usage limit exceeded
- `500` — Internal Server Error
- `504` — Gateway Timeout - Test execution exceeded time limit

---

[API](https://skmtc.net/tester/apis/testerarmy-api.md) · [All operations](https://skmtc.net/tester/apis/testerarmy-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/tester/testerarmy-api/versions/7fd19ca2a7fc/schema)
