---
title: "Batch create TestDefinition"
method: POST
path: "/api/v3/test-definition:batch-create"
tags: ["Test Definition"]
---

# Batch create TestDefinition

`POST /api/v3/test-definition:batch-create`

## Request

- Base URL: `https://{tenant_name}.benchling.com`
- URL: `https://{tenant_name}.benchling.com/api/v3/test-definition:batch-create`
- Auth: HTTP bearer

Batch create Test Definitions synchronously in one transaction. Maximum 25 items per request.

Each item follows the same field requirements as the single-create endpoint. If any item fails validation, the transaction fails and no Test Definitions are created.

## Headers

- `EARLY-ACCESS` string

## Request body

- object
  - `items` CreateTestDefinitionInput[], required
    - `description` string, required: Human-readable description for the test definition. Empty strings are allowed; values must be at most 255 characters.
    - `name` string, required: Display name for the test definition. Must be non-empty after trimming whitespace and unique within the organization.
    - `organizationId` string, required: The API ID of the organization that owns the test definition.
    - `resultSchemaId` string, required: The API ID of the result schema that defines the shape of results captured for this test.

## Response `201`

Created

- TestDefinitionBatchcreateResponse201
  - `items` TestDefinition[], required
    - `__typename` string
    - `archiveReason` string, nullable
    - `archived` boolean
    - `createdAt` string, datetime: Timestamp of when the test definition was created.
    - `creator` PrincipalRef
      - `__typename` string
      - `id` string, api_id
    - `description` string: The description of the test definition. Empty strings are allowed.
    - `id` string: The ID of the test definition.
    - `modifiedAt` string, datetime: Timestamp of when the test definition was last modified.
    - `name` string: The name of the test definition.
    - `organization` OrganizationRef
      - `__typename` string
      - `id` string, api_id
    - `resultSchema` ResultSchemaRef
      - `__typename` string
      - `id` string, api_id

## Other responses

- `400`: Bad Request
- `403`: Forbidden
- `404`: Not Found
- `409`: Conflict
- `429`: Too Many Requests
- `500`: Internal Server Error

---

[API](https://skmtc.dev/benchling/apis/benchling-api.md) - [All operations](https://skmtc.dev/benchling/apis/benchling-api/llms.txt) - [OpenAPI document](https://skmtc.dev/benchling/apis/benchling-api/revisions/c9f087b98b8b?raw)
