---
title: "Clear Session Messages"
method: DELETE
path: "/api/v1/sessions/{session_id}/messages"
tags: ["sessions"]
---

# Clear Session Messages

`DELETE /api/v1/sessions/{session_id}/messages`

## Request

- Base URL: `https://api.gnosari.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.gnosari.com/api/v1/sessions/{session_id}/messages`
- Auth: one of:
  - HTTP bearer
  - API key in header `X-AUTH-TOKEN`

Clear all messages from a session (but keep the session).

Supports three access levels based on session's agent/team:
- PUBLIC: No authentication required
- PASSWORD_PROTECTED: X-Access-Password header required
- PRIVATE: User authentication required

## Path parameters

- `session_id` string, required

## Headers

- `X-Access-Password` string, nullable

## Response `204`

Successful Response

## Other responses

- `422`: Validation Error

---

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