---
title: "Write, Patch, Read, and Delete data in the Key-Value Store."
method: POST
path: "/secret/data/{path}"
tags: ["secrets"]
---

# Write, Patch, Read, and Delete data in the Key-Value Store.

`POST /secret/data/{path}`

## Request body

- KvDataRequest
  - `data` object — The contents of the data map will be stored and returned on read.
  - `options` object — Options for writing a KV entry. Set the "cas" value to use a Check-And-Set operation. If not set the write will be allowed. If set to 0 a write will only be allowed if the key doesn’t exist. If the index is non-zero the write will only be allowed if the key’s current version matches the version specified in the cas parameter.
  - `version` integer — If provided during a read, the value at the version number will be returned

## Response `200`

OK

---

[API](https://skmtc.net/lensesio/apis/hashicorp-vault-api.md) · [All operations](https://skmtc.net/lensesio/apis/hashicorp-vault-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/lensesio/hashicorp-vault-api/revisions/bd8194de0697/schema)
