Skip to main content

Goal

Use the State module to share data between Functions without a separate database.

Steps

1. Enable the State module

iii-config.yaml

2. Write state

state-writer.ts

3. Read state

state-reader.ts

4. Atomic updates

Use state::update with update operations for safe concurrent modifications:
state-update.ts

Result

State is shared across all Functions in the system. Any Function can read or write to any scope/key pair. The Engine handles consistency and persistence based on the configured adapter.