> ## Documentation Index
> Fetch the complete documentation index at: https://docs.textyess.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Bulk Update Products

> Update multiple products at once in your catalog

## Overview

The bulk update endpoint allows you to modify multiple existing products in your catalog simultaneously. This is useful for updating prices, inventory, or product details in batch.

## Authentication

This endpoint requires a valid JWT token in the `x-auth-token` header. You can find your token in the [Developers section](https://ai.textyess.com/developers):

```bash theme={null}
x-auth-token: your_jwt_token
```

## Body Parameters

<ParamField
  body="products"
  type="array"
  required
  initialValue={[{
id: "prod_12345",
title: "Updated Product",
description: "An updated product description",
image: "https://example.com/updated-image.jpg",
url: "https://yourstore.com/products/updated-product",
variants: [{
  id: "var_12345",
  title: "Updated Variant",
  price: "39.99",
  inventory_quantity: 75,
  variant_url: "https://yourstore.com/products/updated-product/variant"
}],
collections: ["Best Sellers"]
}]}
>
  Array of products to update. Only include the fields you want to modify - omitted fields will remain unchanged.

  <Expandable title="Show product properties">
    <ParamField body="id" type="string" required>
      Unique identifier for the product (required to identify which product to update)
    </ParamField>

    <ParamField body="title" type="string">
      Updated product title
    </ParamField>

    <ParamField body="description" type="string">
      Updated product description
    </ParamField>

    <ParamField body="image" type="string">
      Updated product image URL
    </ParamField>

    <ParamField body="url" type="string">
      Updated product page URL
    </ParamField>

    <ParamField body="variants" type="array">
      Updated array of product variants

      <Expandable title="Show variant properties">
        <ParamField body="id" type="string" required>
          Unique identifier for the variant (required to identify which variant to update)
        </ParamField>

        <ParamField body="title" type="string">
          Updated variant title
        </ParamField>

        <ParamField body="price" type="string">
          Updated variant price
        </ParamField>

        <ParamField body="inventory_quantity" type="number">
          Updated available quantity
        </ParamField>

        <ParamField body="variant_url" type="string">
          Updated URL for this specific variant
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField body="collections" type="array">
      Updated array of collection names this product belongs to
    </ParamField>
  </Expandable>
</ParamField>

## Response

<ResponseField name="success" type="boolean">
  Indicates if the update was successful
</ResponseField>

<ResponseField name="message" type="string">
  A human-readable message describing the result
</ResponseField>

<ResponseExample>
  ```json 200 theme={null}
  {
    "success": true,
    "message": "Products update queued successfully"
  }
  ```

  ```json 400 theme={null}
  {
    "message": "You hit rate limit"
  }
  ```

  ```json 401 theme={null}
  {
    "message": "Unauthorized"
  }
  ```
</ResponseExample>

## Rate Limiting

You can call the bulk update endpoint up to **100 times per 5 minutes**.
After that will
Exceeding this limit will make it impossible for you to make further calls to this endpoint for 3, 12 and finally 24 hours. **If this limit is exceeded four times you will not be allowed to make calls to this endpoint indefinitely**.

## Best Practices

1. **Partial Updates**: Only include fields that need to be updated - omitted fields will retain their current values.
2. **Batch Size**: Keep batches under 500 products to avoid rate limits.
3. **Error Handling**: Implement retry logic with exponential backoff for rate limit errors.
4. **Validation**: Always include the product and variant IDs to ensure correct updates.
5. **Idempotency**: The operation is not idempotent - sending the same update multiple times will cause issues.
