---
title: "End a session"
method: POST
path: "/api/v1/sessions/{session_id}/end"
tags: ["Sessions"]
---

# End a session

`POST /api/v1/sessions/{session_id}/end`

## Request

- Base URL: `https://dashboard.sealgate.ai`
- URL: `https://dashboard.sealgate.ai/api/v1/sessions/{session_id}/end`
- Auth: HTTP bearer

Mark an active session as ended.

## Request body

- EndSessionRequest
  - `reason` string: Reason the session ended

## Response `200`

Session ended

- OkResponse
  - `ok` boolean, required: Whether the operation succeeded

## Other responses

- `401`: Missing or invalid API key
- `403`: The caller's role is not permitted to perform this action
- `404`: The requested resource was not found
- `422`: Request validation failed

---

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