---
title: "End Conversations"
method: POST
path: "/v1/end-conversations"
---

# End Conversations

`POST /v1/end-conversations`

End multiple running conversations by marking them in Redis for the LiveKit agent to terminate.

This endpoint:
1. Checks that each test result exists and is in RUNNING status
2. Writes control objects to Redis for the LiveKit agent to pick up
3. Schedules a 30-second fallback watchdog for each conversation
4. Returns which conversations were successfully marked for ending and which failed

The fallback watchdog ensures that if LiveKit fails to respond, the conversation
status will be updated after 30 seconds to prevent it from appearing stuck forever.

## Headers

- `X-API-Key` string, required

## Request body

- EndConversationsRequest — Pydantic model for ending multiple conversations
  - `test_result_ids` integer[], required — List of test result IDs to end

## Response `200`

Successful Response

- EndConversationsResponse — Response for end conversations request
  - `success` boolean, required — Whether the operation was successful
  - `ended_count` integer, required — Number of conversations marked for ending
  - `test_result_ids` integer[], required — Test result IDs that were processed
  - `failed_ids` integer[], nullable — Test result IDs that failed to process (if any)
  - `message` string, required — Status message

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/getbluejay/apis/bluejay-api.md) · [All operations](https://skmtc.net/getbluejay/apis/bluejay-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/getbluejay/bluejay-api/revisions/f48cef80963f/schema)
