Part of the installer first-run UX v2 spec (umbrella in the backend tracker; interim copy fixes in tracebloc/client#307). Goal: client create needs zero flags and zero prompts on the installer path — name auto-generated, location omitted.
Auto-generated client name — <firstname>-NN
- Parse
first_name from GET /userinfo/ into api.Identity and persist it in the profile at login (the backend already returns it for account users; fallback when empty: email local-part).
- When
--name is absent, auto-name the client <slug(first_name)>-NN — lukas-01, lukas-02, … NN = next free number scanned from the account's existing client names (ListClients already fetches the full paginated list in runClientCreate). Zero-padded 2 digits.
- No name prompt, ever.
--name / TRACEBLOC_CLIENT_NAME still override.
- The auto-name passes
internal/slug untouched (lukas-01 → lukas-01), so display name = namespace = handle by construction, and the -2 slug collision suffix never fires for auto-names.
- Note: this is a deliberate product deviation from RFC-0001 §6.6 (which derives from the hostname) — decided by Lukas 2026-07-06. Update the RFC §6.6/§7.7 wording in a companion docs commit.
--location optional
- Remove the location requirement: no
errMissingFlag("--location"), no prompt (delete the validateNonEmpty prompt block).
CreateClientRequest.Location → json:"location,omitempty" (the backend accepts absent/blank today — EdgeDevice.location is blank=True, serializer auto-builds required=False).
- Guard the review render (
renderClientReview) for empty location; resumeCommand is already conditional.
- The
internal/geo auto-detect (cli#93) stays available for --location-less enrichment later but must not block or prompt.
Noun pass (naming lock)
- Adopt message: "This cluster is already registered as client …" → machine/client nouns per the naming rule (machine = hardware, client = tracebloc entity).
- Sweep remaining user-facing strings for
vendor → other collaborators (installer strings already swept in client#307).
Acceptance
tracebloc client create --yes --credential-file f with no other flags, non-interactive: succeeds — auto-name minted, no location sent.
- Two machines, same account, same first name →
lukas-01, lukas-02 (numbering, not slug -2 stacking).
- Re-run on the same cluster still adopts (idempotency unchanged).
--name/--location flags still honored verbatim.
Refs: RFC-0001 (cli#55) §6.6/§6.7/§7.7 · connect/install flow family backend#877.
🤖 Generated with Claude Code
Part of the installer first-run UX v2 spec (umbrella in the backend tracker; interim copy fixes in tracebloc/client#307). Goal:
client createneeds zero flags and zero prompts on the installer path — name auto-generated, location omitted.Auto-generated client name —
<firstname>-NNfirst_namefromGET /userinfo/intoapi.Identityand persist it in the profile at login (the backend already returns it for account users; fallback when empty: email local-part).--nameis absent, auto-name the client<slug(first_name)>-NN—lukas-01,lukas-02, … NN = next free number scanned from the account's existing client names (ListClientsalready fetches the full paginated list inrunClientCreate). Zero-padded 2 digits.--name/TRACEBLOC_CLIENT_NAMEstill override.internal/sluguntouched (lukas-01→lukas-01), so display name = namespace = handle by construction, and the-2slug collision suffix never fires for auto-names.--locationoptionalerrMissingFlag("--location"), no prompt (delete thevalidateNonEmptyprompt block).CreateClientRequest.Location→json:"location,omitempty"(the backend accepts absent/blank today —EdgeDevice.locationisblank=True, serializer auto-buildsrequired=False).renderClientReview) for empty location;resumeCommandis already conditional.internal/geoauto-detect (cli#93) stays available for--location-less enrichment later but must not block or prompt.Noun pass (naming lock)
vendor→other collaborators(installer strings already swept in client#307).Acceptance
tracebloc client create --yes --credential-file fwith no other flags, non-interactive: succeeds — auto-name minted, no location sent.lukas-01,lukas-02(numbering, not slug-2stacking).--name/--locationflags still honored verbatim.Refs: RFC-0001 (cli#55) §6.6/§6.7/§7.7 · connect/install flow family backend#877.
🤖 Generated with Claude Code