---
outline: deep
---

# DF0013: Shared State Not Found

## Message

> Shared state of "`{key}`" is not found, please provide an initial value for the first time

## Cause

`RpcSharedStateHost.get()` was called for a key that has no stored state yet, and no `initialValue` was passed.

## Fix

Pass `initialValue` on the first call: `ctx.rpc.sharedState.get(key, { initialValue: ... })`.

## Source

- [`packages/devframe/src/node/rpc-shared-state.ts`](https://github.com/devframes/devframe/blob/main/packages/devframe/src/node/rpc-shared-state.ts) — `RpcSharedStateHost.get()` throws `DF0013` when neither an existing entry nor an `initialValue` is provided for a key.
