Skip to main content
This example demonstrates how to cancel a running team execution by starting a team run in a separate thread and cancelling it from another thread. It shows proper handling of cancelled responses and thread management.

Example

team_cancel_run.py

API Endpoint

Team runs can be cancelled via the AgentOS API:
Example:
Reference: Cancel Team Run API