> ## Documentation Index
> Fetch the complete documentation index at: https://microstrate-1133-notifications-prefs.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Create or update KV entry

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



## OpenAPI

````yaml /api-reference/endpoint/storage/openapi.json put /storage/kv/{bucket}/entries/{key}
openapi: 3.0.3
info:
  title: quiva.ai Gateway
  description: >-
    A comprehensive interface for managing key-value stores, object stores,
    streams, and search indexing
  contact:
    name: quiva.ai Support
    url: https://quiva.ai/help-center/
  version: 1.0.0
servers:
  - url: https://api.quiva.ai
    description: Production API server
security:
  - bearerAuth: []
  - apiKeyAuth: []
paths:
  /storage/kv/{bucket}/entries/{key}:
    put:
      tags:
        - KV Entries
      summary: Create or update KV entry
      description: Creates or updates a key-value entry in the specified bucket
      operationId: putKVEntry
      parameters:
        - $ref: '#/components/parameters/bucketName'
        - $ref: '#/components/parameters/entryKey'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/KVEntryValue'
            example:
              name: John Doe
              email: john@example.com
              age: 30
      responses:
        '200':
          $ref: '#/components/responses/SuccessResponse'
        '400':
          $ref: '#/components/responses/BadRequestError'
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '404':
          $ref: '#/components/responses/NotFoundError'
        '500':
          $ref: '#/components/responses/InternalServerError'
components:
  parameters:
    bucketName:
      name: bucket
      in: path
      description: Name of the bucket
      required: true
      schema:
        type: string
    entryKey:
      name: key
      in: path
      description: Key of the entry
      required: true
      schema:
        type: string
  schemas:
    KVEntryValue:
      type: object
      description: Value to store in KV entry
      additionalProperties: true
    SuccessMessage:
      type: object
      properties:
        message:
          type: string
          example: success
    ErrorResponse:
      type: object
      required:
        - error
      properties:
        error:
          type: string
          description: Error message
  responses:
    SuccessResponse:
      description: Bad Request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/SuccessMessage'
          example:
            message: success
    BadRequestError:
      description: Bad Request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error: validation_error
    UnauthorizedError:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error: unauthorized
    NotFoundError:
      description: Not Found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error: not_found
    InternalServerError:
      description: Internal Server Error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error: internal_error
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
    apiKeyAuth:
      type: apiKey
      in: header
      name: X-Api-Key

````