> This page is for Developer Documentation.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.benchling.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.benchling.com/_mcp/server.

# Batch update RequestV2Definition

PATCH https://{tenant_name}.benchling.com/api/v3/request-v2-definition:batch-update
Content-Type: application/json

Batch update RequestV2Definition synchronously in one transaction. Maximum 25 items per request.

Reference: https://docs.benchling.com/docs/api/benchling-api/request-v-2-definition/batchupdate

## Authentication

- `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer <token>`, where token is your auth token.

## Request

### Headers

- `EARLY-ACCESS` (string, optional) — Set to true to access beta operations via /api/v3.

### Body (application/json)

This endpoint expects an object.

- `items` (list of UpdateRequestV2DefinitionInputWithPathParams, required)

## Response

### 200

OK

- `items` (list of RequestV2Definition, required)

## Errors

### 400 Request V2definition Batch Update Request Bad Request Error

Bad Request

- `detail` (GeneralErrorDetail, required, nullable)
- `instance` (string, required)
- `status` (integer, required)
- `title` (string, required, nullable)
- `type` (string, required)
- `invalidId` (string, optional)

### 403 Request V2definition Batch Update Request Forbidden Error

Forbidden

- `detail` (GeneralErrorDetail, required, nullable)
- `instance` (string, required)
- `status` (integer, required)
- `title` (string, required, nullable)
- `type` (string, required)
- `invalidId` (string, optional)

### 404 Request V2definition Batch Update Request Not Found Error

Not Found

- `detail` (GeneralErrorDetail, required, nullable)
- `instance` (string, required)
- `status` (integer, required)
- `title` (string, required, nullable)
- `type` (string, required)
- `invalidId` (string, optional)

### 409 Request V2definition Batch Update Request Conflict Error

Conflict

- `detail` (GeneralErrorDetail, required, nullable)
- `instance` (string, required)
- `status` (integer, required)
- `title` (string, required, nullable)
- `type` (string, required)
- `invalidId` (string, optional)

### 429 Request V2definition Batch Update Request Too Many Requests Error

Too Many Requests

- `detail` (TooManyRequestsErrorBodyDetail, required, nullable)
- `instance` (string, required)
- `status` (integer, required)
- `title` (string, required, nullable)
- `type` (string, required)
- `invalidId` (string, optional)
- `violated-policies` (list of enum, optional) — The budget policies that rejected the request, in canonical order: `user`, `integration`, then `tenant`.
  - Allowed values: `user`, `integration`, `tenant`

### 500 Request V2definition Batch Update Request Internal Server Error

Internal Server Error

- `detail` (InternalServerErrorBodyDetail, required, nullable)
- `instance` (string, required)
- `status` (integer, required)
- `title` (string, required, nullable)
- `type` (string, required)
- `errorId` (string, optional)

## Types

### UpdateRequestV2DefinitionInputWithPathParams

- `id` (string, required)
- `archiveReason` (string, optional)
- `archived` (boolean, optional)
- `description` (string, optional, nullable) — Description of the request template. Must not exceed 1024 characters and must not contain a null character.
- `name` (string, optional) — Name of the request template. Must not be empty, must not exceed 255 characters, and must not contain a null character.
- `prefix` (string, optional) — Prefix for the displayId of requests created from this template.
- `templateCollectionId` (string, optional) — API ID of the template collection to move this request template to.

### RequestV2Definition

A reusable template that defines the structure and configuration for requests in Benchling. Also known as a "Request Template" in the UI. Each RequestV2Definition specifies a `templateDocument` that serves as the document template for requests, a `workflowTaskSchema` that defines the task structure and fields, and a `prefix` used to generate human-readable display IDs (e.g., "REQ-001") for submissions created from this template. Request templates are organized within `TemplateCollection` folders and support collaboration features like starring (see `Starrable`). When users submit a request, they create a `RequestV2Submission` based on this definition. The template can include a `description` to explain its intended use and can be archived when no longer needed.

- `__typename` (string, optional)
- `archiveReason` (string, optional, nullable)
- `archived` (boolean, optional)
- `createdAt` (string, optional, nullable)
- `creator` (PrincipalRef, optional)
- `description` (string, optional, nullable) — Description of the request template.
- `id` (string, optional)
- `modifiedAt` (string, optional, nullable)
- `name` (string, optional)
- `prefix` (string, optional) — The prefix for the displayId of tasks of this schema.
- `templateCollection` (TemplateCollectionRef, optional)
- `webUrl` (string, optional, nullable)
- `workflowTaskSchema` (WorkflowTaskSchemaRef, optional) — The task schema backing this configuration.

### GeneralErrorDetail

### TooManyRequestsErrorBodyDetail

### InternalServerErrorBodyDetail

### PrincipalRef

- `__typename` (string, optional)
- `id` (string, optional)

### TemplateCollectionRef

- `__typename` (string, optional)
- `id` (string, optional)

### WorkflowTaskSchemaRef

- `__typename` (string, optional)
- `id` (string, optional)

## Examples

**Request**

```json
{
  "items": [
    {
      "id": "id"
    }
  ]
}
```

**Response**

```json
{
  "items": [
    {
      "__typename": "__typename",
      "archiveReason": "archiveReason",
      "archived": true,
      "createdAt": "createdAt",
      "description": "description",
      "id": "id",
      "modifiedAt": "modifiedAt",
      "name": "name",
      "prefix": "prefix",
      "webUrl": "webUrl"
    }
  ]
}
```

**SDK Code**

```python
import requests

url = "https://{tenant_name}.benchling.com/api/v3/request-v2-definition:batch-update"

payload = { "items": [{ "id": "id" }] }
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.patch(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://{tenant_name}.benchling.com/api/v3/request-v2-definition:batch-update';
const options = {
  method: 'PATCH',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: '{"items":[{"id":"id"}]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```