---
title: "Delete Agent State"
method: DELETE
path: "/api/v1/contexts/{context_id}/state/{key}"
tags: ["agent-state"]
---

# Delete Agent State

`DELETE /api/v1/contexts/{context_id}/state/{key}`

## Request

- Base URL: `https://memory.kagura-ai.com` (the document declares no server; this is the origin it was published from)
- URL: `https://memory.kagura-ai.com/api/v1/contexts/{context_id}/state/{key}`
- Auth: none declared

Delete ``(context_id, key)``. 404 when the key was not present.

## Path parameters

- `context_id` string, uuid, required
- `key` string, required

## Headers

- `authorization` string, nullable

## Response `200`

Successful Response

- AgentStateKeyResponse: Envelope for a write that returns just the affected key (set / delete).
  - `key` string, required

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/kagura-ai/apis/kagura-memory-cloud.md) · [All operations](https://skmtc.dev/kagura-ai/apis/kagura-memory-cloud/llms.txt) · [OpenAPI document](https://skmtc.dev/kagura-ai/apis/kagura-memory-cloud/revisions/09f17f5ada29?raw)
