# `ExGram.FSM.Key.User`
[🔗](https://github.com/rockneurotiko/ex_gram_fsm/blob/v0.1.0/lib/ex_gram/fsm/key/user.ex#L1)

FSM key: `{user_id}`.

Scopes FSM state globally per-user, across all chats. This means:
- A user carries the same FSM state whether they message the bot in a DM,
  a group chat, or via an inline query.
- Different users always have independent FSM state.

Use this when you want a single conversation flow that persists across contexts,
for example a registration flow that works the same in DMs and groups.

## Key shape

| Update type | Key |
|-------------|-----|
| Any update with a user | `{user_id}` |
| Channel post (no user) | `:error` — FSM state is skipped |

---

*Consult [api-reference.md](api-reference.md) for complete listing*
