# Cancel a bulk upload

`POST /api/bobsync/products-bulk/cancel`

**Base URLs:**

- Sandbox: `https://api.tools.qa.bobshop.co.za`
- Production: `https://api.tools.bobshop.co.za`

**Authentication:** Bearer token required (see the Authentication page).

## Example request

```bash
curl -X POST 'https://api.tools.qa.bobshop.co.za/api/bobsync/products-bulk/cancel' \
  -H "content-type: application/json" \
  -H "Authorization: Bearer <API_KEY>" \
  -d '{
  "channel_id": 1
}'
```

Stop a bulk upload that is currently running.

| Field | Type | Required | Notes |
| --- | --- | --- | --- |
| `channel_id` | integer | yes | The API channel your token belongs to. Support can give it to you before your first order. |

The run stops before the next product. Products already handled stay as they
are.

## Failures

| Status | Body | Meaning |
| --- | --- | --- |
| `400` | `invalid channel_id` | `channel_id` missing or not positive. |
| `400` | `could not get channel` | The channel could not be found. |
| `403` | `user 123 does not have access to channel 456` | The channel does not belong to you. |

## Response

`200` with a fixed acknowledgement. Call [Check bulk upload status](bulk_upload_status.md) for the
final counts.

```json
{
    "errors": null,
    "import_count": 0,
    "import_success_count": 0,
    "is_running": false
}
```
