---
id: w5/m12/t004
title: Create flow at `/new/redis` parity (name, plan picker, captured options)
worker: worker5
status: done
estimate: 60m
depends_on: [w5/m12/t002]
---

## Objective

The "New Key Value" flow matching the captured `/new/redis`: name field (DNS-safe validation mirroring the CR contract), plan tier cards (`free`/`starter`/`standard` with memory/price from the tiers catalog), and whichever captured options bex supports today (e.g. version display; `maxmemoryPolicy` only if w2/m7 shipped it — otherwise omit rather than fake). Submits the create mutation, lands on the new store's detail with a `creating` state that resolves to `available`.

## Context

- m8's create-database dialog is the interaction template; follow the capture on whether Render uses a full page or dialog for KV.
- Plan metadata should come from the API (w2/m7 tiers surface) or a checked-in mirror of `lego/types/tiers/tiers.yaml` — no hardcoded divergent copies.
- Unsupported Render fields: leave out, and note the omission for t006's parity pass.

## Steps

1. Build the form per capture; client validation consistent with API errors.
2. Wire the create mutation + optimistic/redirect behavior; error surface for 4xx.
3. Verify offline against the stub: create → appears in list → detail reachable.

## Files

- `dashboard/src/features/keyvalue/components/` (create form/dialog)
- Route registration (`/new` entry point per capture, e.g. `keyvalue.new` or dialog on the list page)

## Acceptance criteria

- [ ] Flow matches the captured structure; plan cards show real tier data.
- [ ] Invalid name/plan surfaces the API's error; success reaches the detail page.
- [ ] en+zh; lint/typecheck green.

## Out of scope

- ipAllowList/persistence options bex doesn't support (parity-noted, not faked).
