---
title: "Logout"
method: POST
path: "/api/v1/logout"
tags: ["Chat"]
---

# Logout

`POST /api/v1/logout`

## Request

- Base URL: `https://backend.caspr.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://backend.caspr.ai/api/v1/logout`
- Auth: none declared

User logout endpoint.
Invalidates the user's token by clearing it from the database.

## Request body

- LogoutRequest
  - `refresh_token` string, required

## Response `200`

Successful Response

- LogoutResponse
  - `success` boolean
  - `message` string

## Other responses

- `401`: Unauthorized
- `422`: Unprocessable Entity
- `500`: Internal Server Error

---

[API](https://skmtc.dev/caspr/apis/casper-api.md) - [All operations](https://skmtc.dev/caspr/apis/casper-api/llms.txt) - [OpenAPI document](https://skmtc.dev/caspr/apis/casper-api/revisions/f9765e3aa00c?raw)
