# Retry product production files (`retry_product_production_files`)

Starts the derived production files (EPS, Illustrator PDF or cut outline DXF) of a retained-metal template product again, as Retry does on the product in the merchant admin. Only a package that failed, or one that stayed pending longer than expected, starts again; retried is then true and the package is back at pending. Any other package is left as it stands, with retried false. A product that owes no derived files is refused. Manufacturer order emails that wait for the files are sent when the files complete, as the order already scheduled. Each connection can make six retry attempts a minute, refused ones included; a replay does not count. It requires the products:write scope and an idempotency_key.

- Source URL: https://www.signcustomiser.com/help/mcp/tools/retry_product_production_files/
- Markdown URL: https://www.signcustomiser.com/help/mcp/tools/retry_product_production_files.md
- MCP endpoint: https://mcp.signcustomiser.com
- Required scope: `products:write`
- Behaviour: write

## Purpose

Recover a retained-metal template product whose production files failed or stalled, so its manufacturer hand-off can complete.

## Annotations

| Hint | Value |
| --- | --- |
| readOnlyHint | false |
| destructiveHint | false |
| idempotentHint | true |
| openWorldHint | false |

## Prerequisites

- The id of a retained-metal template product, from list_integration_products.
- A merchant has connected this store and approved the products:write scope.

## Side effects

- Sets the failed or stalled files of the package back to pending and queues them to be made again. A package that cannot be retried now is not changed.
- Uses one of the six retry attempts this connection may make in a minute, even when the attempt is refused. A replay uses none.
- Claims the idempotency_key for at least 24 hours.

## Arguments

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `product_id` | integer | yes | The product id, from list_integration_products. |
| `idempotency_key` | string | yes | A client-generated key unique to this logical write, such as a UUID. Required: repeating the call with the same key and the same arguments replays the original result instead of writing twice, and the same key with different arguments is an idempotency_key_conflict. |

## Result

Whether the package started again, and the package as it now stands: its status, each owed file and its status, whether a retry is possible, whether it is delayed, and how many manufacturer order emails wait for it.

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `request_id` | string | yes |  |
| `store` | object | yes |  |
| `store.id` | integer | yes |  |
| `store.name` | string | yes |  |
| `product_id` | integer | yes |  |
| `retried` | boolean | yes | True when the package started again; false when it could not be retried now and was left as it stands. |
| `production_package` | object | yes |  |
| `production_package.status` | string | yes | pending while any owed file is being made, failed when any failed, complete when every owed file exists. One of: `pending`, `failed`, `complete`. |
| `production_package.files` | array of object | yes |  |
| `production_package.files[].type` | string | yes | One of: `eps`, `illustrator_pdf`, `cut_outline_dxf`. |
| `production_package.files[].status` | string | yes | One of: `pending`, `failed`, `complete`. |
| `production_package.can_retry` | boolean | yes |  |
| `production_package.delayed` | boolean | yes |  |
| `production_package.held_order_emails` | integer | yes | How many manufacturer order emails wait for these files. |
| `production_package.updated_at` | string or null | no |  |
| `idempotent_replay` | boolean | no | True when this call replayed a previously recorded response for the same idempotency_key instead of applying the write again. |

## Error cases

| Code | Recovery |
| --- | --- |
| `idempotency_key_conflict` | That key was used for another call. Re-send the original arguments or issue a new key. |
| `insufficient_scope` | The connection was approved without products:write. |
| `no_production_package` | The product owes no derived production files, so there is nothing to retry. |
| `rate_limited` | This connection has made six retry attempts in the last minute. Wait retry_after seconds. |
| `resource_not_found` | No product with that id belongs to this store. Call list_integration_products to find a valid id. |

## Example: Start a failed EPS file again

Request:

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "retry_product_production_files",
    "arguments": {
      "product_id": 731,
      "idempotency_key": "1b2c3d4e-5f60-4a7b-8c9d-0e1f2a3b4c5d"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "structuredContent": {
      "request_id": "req_01jz9x2k7c8f3m5n6p7q8r9s0t",
      "store": {
        "id": 12,
        "name": "Demo Signs"
      },
      "product_id": 731,
      "retried": true,
      "production_package": {
        "status": "pending",
        "files": [
          {
            "type": "cut_outline_dxf",
            "status": "complete"
          },
          {
            "type": "eps",
            "status": "pending"
          }
        ],
        "can_retry": false,
        "delayed": false,
        "held_order_emails": 1,
        "updated_at": "2026-07-18T03:20:00Z"
      },
      "idempotent_replay": false
    }
  }
}
```

## Example: A product without production files (error)

Request:

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "retry_product_production_files",
    "arguments": {
      "product_id": 732,
      "idempotency_key": "2c3d4e5f-6071-4b8c-9d0e-1f2a3b4c5d6e"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "isError": true,
    "structuredContent": {
      "error": {
        "code": "no_production_package",
        "title": "No production package",
        "detail": "This product has no production files to retry.",
        "recovery": "The product owes no derived production files, so there is nothing to retry. Only a retained-metal template product has them."
      }
    }
  }
}
```
