---
title: "Read KVStore data"
method: POST
path: "/read/"
tags: ["KVStore", "public"]
---

# Read KVStore data

`POST /read/`

Read KVStore data for the specified keys and from the specified stores. If a World ID or Launch Context ID header
are supplied, the respective Project ID header _must_ also be supplied.

Data can be read from either the client or server store by both the user and Unreal server or service accounts.
Client store data can only be written by the user whose store it is but can be read by the user and an Unreal server
or service account. The server store can only be written by the Unreal server or service account but may be read
by both the user and the server.

We offer a canonical place to store the username and avatar URL of each user. These can be found in the client store,
at organization level, under the keys "_morpheus_username" and "_morpheus_avatar_url" respectively.

## Headers

- `x-m2-organization-id` string, required
- `x-m2-project-id` string
- `x-m2-launch-context-id` string
- `x-m2-world-id` string

## Request body

- object[] — Request to read from a KV Store for a given user, store and key.
  - `id` string, required — The ID of the user who's store is being accessed
  - `store` union, required — Client or Server KV Store
    - 'kvstoreClient'
    - 'kvstoreServer'
  - `key` string, required — The key of the value of interest

## Response `200`

The response for a KV Store read request.

- object[] — The response for a KV Store read request.
  - `status` union, required — Indicates if the request key was found or not.
    - 'ok'
    - 'not-found'
  - `id` string, required — The ID of the user who's store is being accessed
  - `store` union, required — Client or Server KV Store
    - 'kvstoreClient'
    - 'kvstoreServer'
  - `object` KvstoreShape, required — Generic shape of a kvstore object
    - `key` string, required
    - `data` unknown

## Other responses

- `4XX` — The error object returned by the API when an error occurs

---

[API](https://skmtc.net/otherside/apis/key-value-store.md) · [All operations](https://skmtc.net/otherside/apis/key-value-store/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/otherside/key-value-store/revisions/fc05ba366987/schema)
