---
title: "Issue a presigned PUT URL for uploading a batch input JSONL"
method: POST
path: "/routines/{routine_id}/run-batch/upload-url"
tags: ["routines"]
---

# Issue a presigned PUT URL for uploading a batch input JSONL

`POST /routines/{routine_id}/run-batch/upload-url`

## Request

- Base URL: `https://api.clay.com/public/v0`
- URL: `https://api.clay.com/public/v0/routines/{routine_id}/run-batch/upload-url`
- Auth: API key in header `clay-api-key`

Creates a presigned URL for uploading a JSONL file used by a batch routine run.

## Path parameters

- `routine_id` string, required

## Response `200`

200

- BatchUploadUrlResponse
  - `file_id` string, required
  - `upload_url` string, uri, required

## Other responses

- `400`: 400
- `401`: 401
- `403`: 403
- `404`: 404
- `429`: 429

## Changes

- **2026-07-31** `881a05e984ea`: 1 breaking, 1 warning, 1 info
  - for the `path` request parameter `routine_id`, the minLength was increased from `0` to `1`
  - for the `path` request parameter `routine_id`, the maxLength was set to `64`
  - added the non-success response with the status `400`

[Operation history](https://skmtc.dev/clay/apis/clay-public-api/changes/routines/:routine_id/run-batch/upload-url/post.md)

---

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