---
title: "Create or update KV entry"
method: PUT
path: "/storage/kv/{bucket}/entries/{key}"
tags: ["KV Entries"]
---

# Create or update KV entry

`PUT /storage/kv/{bucket}/entries/{key}`

## Request

- Base URL: `https://api.quiva.ai`
- URL: `https://api.quiva.ai/storage/kv/{bucket}/entries/{key}`
- Auth: one of:
  - HTTP bearer
  - API key in header `x-api-key`
- TypeScript: <https://skmtc.dev/quivaworks/apis/quiva-ai-gateway-5/docs/storage/kv/:bucket/entries/:key/put.ts> (a function with typed inputs; its response is checked against the schema)

Creates or updates a key-value entry in the specified bucket

## Path parameters

- `bucket` string, required
- `key` string, required

## Request body

- KVEntryValue: Value to store in KV entry

## Response `200`

Bad Request

- SuccessMessage
  - `message` string

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `404`: Not Found
- `500`: Internal Server Error

## Changes

- **2025-07-04** `d566a61279be`: 3 breaking, 1 warning, 1 info
  - added the new path request parameter `bucket`
  - added the new path request parameter `key`
  - removed the success response with the status `201`
  - removed the request property `value`
  - …1 more
- **2025-06-13** `e4ad9e1ccd66`: 3 warning, 1 info
  - removed the optional property `bucket` from the response with the `200` status
  - removed the optional property `key` from the response with the `200` status
  - removed the optional property `status` from the response with the `200` status
  - added the optional property `message` to the response with the `200` status

[Operation history](https://skmtc.dev/quivaworks/apis/quiva-ai-gateway-5/changes/storage/kv/:bucket/entries/:key/put.md)

---

[API](https://skmtc.dev/quivaworks/apis/quiva-ai-gateway-5.md) - [All operations](https://skmtc.dev/quivaworks/apis/quiva-ai-gateway-5/llms.txt) - [OpenAPI document](https://skmtc.dev/quivaworks/apis/quiva-ai-gateway-5/revisions/104591eadd10?raw)
