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

# Delete branch

> Delete a branch from your store.

**app\_id** `string` *required*

Your store ID in Jelou Shop.

**branch\_id** `string` *required*

The ID of the branch to delete.

> [!WARNING]
>
> You cannot delete a branch that has **active products** linked to it. Deactivate them or move them to another branch before continuing; otherwise you will receive a `409 Conflict` error.

```bash cURL theme={null}
curl -X DELETE "https://gateway.jelou.ai/ecommerce/v2/apps/{app_id}/branches/{branch_id}" \
  -H "x-api-key: YOUR_API_KEY"
```

```json 409 Conflict theme={null}
{
  "message": "No se puede eliminar la sucursal porque tiene productos activos asociados. Desactívalos o muévelos antes de continuar.",
  "errors": {
    "branch": [
      "No se puede eliminar la sucursal porque tiene productos activos asociados."
    ]
  },
  "active_products_count": 12
}
```

> [!NOTE]
>
> The `message` and `errors.branch` texts are returned by the API in Spanish (they are not localized), so they are shown here exactly as the API responds. Use `active_products_count` and the `409` status code for programmatic handling.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.