---
title: "Sweep Stale Calls Endpoint"
method: POST
path: "/internal/sweep-stale-calls"
tags: ["Internal", "Internal"]
---

# Sweep Stale Calls Endpoint

`POST /internal/sweep-stale-calls`

## Request

- Base URL: `https://api.call2me.app`
- URL: `https://api.call2me.app/internal/sweep-stale-calls`
- Auth: HTTP bearer

Close call rows and web sessions that outlived their room.

Until now the only thing that closed a stranded row was somebody opening
the panel's call list, because the sweep lived inside that read path. A
call cut off mid-conversation — an agent restart, a browser that died
without reporting, a missed webhook — therefore showed as "in progress"
for as long as nobody looked, and for a browser room it did worse than
look wrong: `idx_web_sessions_one_open` allows a single open session per
interpreter, so one stranded row made that address unusable.

Everything here is time-guarded and idempotent, so running it every few
minutes is safe.

## Headers

- `x-internal-key` string, nullable

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/call2me/apis/call2me-api.md) · [All operations](https://skmtc.dev/call2me/apis/call2me-api/llms.txt) · [OpenAPI document](https://skmtc.dev/call2me/apis/call2me-api/revisions/3951f9b7e47d?raw)
