---
title: "Batch create ScratchFile"
method: POST
path: "/api/v3/scratch-file:batch-create"
tags: ["Scratch File"]
---

# Batch create ScratchFile

`POST /api/v3/scratch-file:batch-create`

## Request

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

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

## Request body

- object
  - `items` CreateScratchFileInput[], required
    - `filename` string, required
    - `name` string

## Response `201`

Created

- ScratchFileBatchcreateResponse201
  - `items` ScratchFile[], required
    - `__typename` string
    - `createdAt` string, datetime, nullable
    - `creator` PrincipalRef
      - `__typename` string
      - `id` string, api_id
    - `downloadUrl` string, nullable
    - `errorMessage` string, nullable
    - `externalFileId` string, nullable
    - `file` FileRef
      - `__typename` string
      - `id` string, api_id
    - `filename` string
    - `id` string
    - `mimeType` string, nullable
    - `modifiedAt` string, datetime, nullable
    - `name` string
    - `originAutomationStepData` AutomationStepDataRef
      - `__typename` string
      - `id` string, api_id
    - `originPipelineStepData` AutomationStepDataRef
      - `__typename` string
      - `id` string, api_id
    - `size` integer, nullable
    - `uploadStatus` 'SUCCEEDED' | 'FAILED_VALIDATION' | 'IN_PROGRESS' | 'NOT_UPLOADED'
    - `uploadUrl` string, nullable

## 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/3873a10bf7b8?raw)
