---
title: "Create a replacement for a failed or expired search job"
method: POST
path: "/api/v1/searches/{id}/retry"
---

# Create a replacement for a failed or expired search job

`POST /api/v1/searches/{id}/retry`

## Request

- Base URL: `https://crawdar.com`
- URL: `https://crawdar.com/api/v1/searches/{id}/retry`
- Auth: one of:
  - API key in header `x-job-token` and API key in header `x-api-key`
  - API key in header `x-job-token`

## Path parameters

- `id` string, uuid, required

## Response `201`

Replacement completed from cache

- SearchJobEnvelope
  - `id` string, uuid, required
  - `status` 'queued' | 'running' | 'completed' | 'failed' | 'canceled', required
  - `jobToken` string: Shown once. Send it in x-job-token for subsequent requests.
  - `statusUrl` string, uri, required
  - `exportUrl` string, uri, required
  - `retryUrl` string, uri, required
  - `cancelUrl` string, uri, required
  - `progress` object
  - `expiresInSeconds` integer, required
  - `cacheHit` boolean
  - `resultCount` integer

## Other responses

- `202`: Replacement accepted and running
- `409`: The original job is completed or still running

---

[API](https://skmtc.dev/crawdar/apis/crawdar-public-api.md) · [All operations](https://skmtc.dev/crawdar/apis/crawdar-public-api/llms.txt) · [OpenAPI document](https://skmtc.dev/crawdar/apis/crawdar-public-api/revisions/355bc1f722ee?raw)
