---
title: "Stop Bot"
method: POST
path: "/bot-orchestration/stop-bot"
tags: ["Bot Orchestration"]
---

# Stop Bot

`POST /bot-orchestration/stop-bot`

Stop a bot with the specified configuration.

Sends a stop command to a running bot instance via MQTT. This gracefully stops
the trading script, optionally cancels open orders, and updates the bot run
record in the database with final performance status.

Important: This endpoint only stops the trading script within the container.
The Docker container continues running and can be restarted with start-bot.
To completely remove a bot and archive its data, use stop-and-archive-bot instead.

The endpoint captures the bot's final performance status before stopping, which
is then persisted to the database for historical tracking.

## Request body

- StopBotAction — Action to stop a bot's trading operations. This action gracefully stops the trading script. The Docker container continues running and can be restarted with StartBotAction. Example: { "bot_name": "my-bot-20240115-143022", "skip_order_cancellation": false, "async_backend": false }
  - `bot_name` string, required — Name of the bot instance to act upon. This should match the instance_name used when the bot was deployed (e.g., 'my-trading-bot-20240115-143022').
  - `skip_order_cancellation` boolean — Controls whether to cancel open orders on the exchange when stopping. When False (default), all open orders are cancelled before stopping. When True, orders remain open on the exchange. Use True for quick stops or when you want to manually manage existing orders.
  - `async_backend` boolean — When True, the stop command is sent asynchronously and returns immediately. When False (default), waits for confirmation that the bot has stopped.

## Response `200`

Successful Response

- unknown

## Other responses

- `422` — Validation Error

## Changes

- **2025-12-20** `1005bcd47280` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/hummingbot/apis/hummingbot-api/changes/bot-orchestration/stop-bot/post.md)

---

[API](https://skmtc.dev/hummingbot/apis/hummingbot-api.md) · [All operations](https://skmtc.dev/hummingbot/apis/hummingbot-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/hummingbot/hummingbot-api/revisions/cb6b6935c8e2/schema)
