---
title: "Remove multiple product variants from a selling plan"
description: "Remove multiple product variants from a selling plan. Optionally, you can also update the inventory policy of the removed variants in the same request to avoid making separate API calls. When inventory_policy is provided"
url: https://docs.stoqapp.com/v1/preorders/remove-multiple-product-variants-from-a-selling-plan/
api: "API v1 (legacy)"
method: DELETE
path: "/external/preorders/{id}/remove_variant"
---

# Remove multiple product variants from a selling plan

`DELETE https://app.stoqapp.com/api/v1/external/preorders/{id}/remove_variant`

Remove multiple product variants from a selling plan. Optionally, you can also update the inventory policy
of the removed variants in the same request to avoid making separate API calls.

When `inventory_policy` is provided, the inventory policy update is performed synchronously (inline)
for better performance and to avoid race conditions.

## Path parameters

- `id` (string, required): Selling plan ID

## Query parameters

- `shopify_variant_ids` (array, required): Array of Shopify variant IDs to remove
- `inventory_policy` (string): Optional. Inventory policy to set for the removed variants. CONTINUE allows overselling, DENY prevents it. One of: `CONTINUE`, `DENY`.

## Headers

- `X-Auth-Token` (string, required): API key for authentication

## Returns

- `success` (boolean): e.g. `true`
- `message` (string): e.g. `1 variant removed`
- `variants_removed` (array of integers): List of variant IDs that were removed
- `inventory_policy_updated` (boolean): Whether the inventory policy was successfully updated (only present when inventory_policy is provided)
- `inventory_policy` (string): The inventory policy that was set (only present when inventory_policy_updated is true) One of: `CONTINUE`, `DENY`.

Rate limit: this call costs 2 points ([rate limits](https://docs.stoqapp.com/docs/rate-limits/)).

## Example request

```sh
curl -X DELETE "https://app.stoqapp.com/api/v1/external/preorders/79b44c6c-ebc7-41d4-8a1b-573d7c693454/remove_variant?shopify_variant_ids=SHOPIFY_VARIANT_IDS" \
  -H "X-Auth-Token: $STOQ_API_KEY"
```

## 200

Variants removed successfully

```json
{
  "success": true,
  "message": "1 variant removed",
  "variants_removed": [
    43900910010503
  ],
  "inventory_policy_updated": true,
  "inventory_policy": "DENY"
}
```

## 400

Bad request - missing or invalid parameters

## 401

Unauthorized

## 404

Selling plan or variants not found

## 422

Failed to remove variants or invalid inventory policy

