Store or update a key-value pair
Store or update a key-value pair in the specified entity namespace.
- entity: Entity namespace (
user or event)
- key: Key identifier (alphanumeric with dashes/underscores, max 256 chars)
- value: The value to store (JSON, text, or binary)
- ttl: Optional expiration time in seconds (60 to 31536000)
- content_type: Content type (can be in header or body)
- metadata: Optional metadata with schema hints
Returns information about the stored value including whether it was created or updated.
| Path Parameters |
|---|
entity KVEntity — REQUIREDPossible values: [user, event] Entity namespace types for KV storage |
key Key — REQUIRED |
| Header Parameters |
|---|
Content-Type Content-Type |
| Request Body — REQUIRED |
|---|
data object — REQUIREDPayload for store value request (from request body) value Value — REQUIRED | ttl Ttl | metadata | content_type Content Type |
|
| Responses |
|---|
| Schema — OPTIONAL |
|---|
ok Ok — OPTIONALIndicates if the request was successful or not. | data objectResponse data for store operation entity KVEntityPossible values: [user, event] Entity namespace types for KV storage | key Key | created Created | expires_at Expires At | content_type Content Type | size_bytes Size Bytes |
|
|
| Schema — OPTIONAL |
|---|
ok Ok — OPTIONALIndicates if the request was successful or not. | errors object[]type uriPossible values: 1 ≤ length ≤ 2083 A string containing a URI reference that identifies the problem type. | status StatusPossible values: 399 < value < 600 A number indicating the HTTP status code. | title TitlePossible values: 5 ≤ length A string containing a short, human-readable summary of the problem type. | detail DetailPossible values: 5 ≤ length A string containing a human-readable explanation specific to this occurrence of the problem. | instance InstancePossible values: 1 ≤ length A string containing a URI reference that identifies the specific occurrence of the problem. | error_code Error CodeA Number that indicates the error type that occurred. |
|
|