Skip to content

docs: correct setup-code expiry contract - #965

Merged
shanselman merged 1 commit into
mainfrom
codex/docs-setup-code-expiry
Jul 10, 2026
Merged

shanselman merged 1 commit into
mainfrom
codex/docs-setup-code-expiry

Conversation

@steipete

@steipete steipete commented Jul 10, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Problem: the gateway integration guide says official setup codes contain expiresAtMs and still lists support for a removed client-side expiry parser.
  • Why it matters: Windows integration work can depend on a payload field that the Gateway never emits.
  • What changed: document the upstream { url, urls?, bootstrapToken } payload, the Windows-consumed { url, bootstrapToken } shape, and the Gateway-owned 10-minute lifetime; remove the stale checklist item.
  • User impact: setup and pairing documentation now matches both current Gateway and Windows implementations.
  • What did NOT change (scope boundary): no runtime, protocol, credential, or pairing behavior changed.

Change Type (select all)

  • Bug fix
  • Feature
  • Refactor
  • Docs / instructions
  • Tests / validation
  • Security hardening
  • Chore / infra

Scope (select all touched areas)

  • Tray / WinUI UX
  • Windows node capability
  • Local MCP / winnode
  • Gateway / connection / pairing
  • Setup / onboarding
  • Permissions / privacy / security
  • Tests / CI / docs

Linked Issue/PR

Validation

  • ./build.ps1 — PASS (Shared, Cli, WinNodeCli, SetupEngine, WinUI)
  • dotnet test ./tests/OpenClaw.Shared.Tests/OpenClaw.Shared.Tests.csproj --no-restore — PASS (2,732 passed, 0 failed, 31 skipped; 2,763 total)
  • dotnet test ./tests/OpenClaw.Tray.Tests/OpenClaw.Tray.Tests.csproj --no-restore — PASS (1,669 passed, 0 failed, 0 skipped)
  • git diff --check — PASS
  • Structured autoreview — PASS, no accepted/actionable findings

Real behavior proof

  • Environment tested: native Windows x64 (AWS Crabbox cbx_334b40932fe4, public networking, no Tailscale); source audit against OpenClaw Gateway and Windows decoder
  • PR head / commit tested: 795b7b7a2856e6f0c82662612d45c767bfe48ae4
  • Exact steps or command run: inspected the Gateway setup payload type/builder and TTL constant, then inspected the current Windows setup-code decoder
  • Evidence after fix: Gateway payload type is { url, urls?, bootstrapToken }; DEVICE_BOOTSTRAP_TOKEN_TTL_MS is 10 minutes; Windows reads only url and bootstrapToken
  • Observed result: all five stale expiry claims are removed or corrected without changing runtime behavior
  • Screenshot/artifact links verified? (Yes/No/N/A): N/A
  • Not verified / blocked: none

Source evidence:

Security Impact (required)

  • New permissions/capabilities? (Yes/No): No
  • Secrets/tokens handling changed? (Yes/No): No
  • New/changed network calls? (Yes/No): No
  • Command/tool execution surface changed? (Yes/No): No
  • Data access scope changed? (Yes/No): No
  • If any Yes, explain risk + mitigation: N/A

Compatibility / Migration

  • Backward compatible? (Yes/No): Yes
  • Config/env changes? (Yes/No): No
  • Migration needed? (Yes/No): No
  • If yes, exact upgrade steps: N/A

Review Conversations

  • I replied to or resolved every bot review conversation I addressed in this PR.
  • I left unresolved only conversations that still need reviewer or maintainer judgment.

@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. P3 Low-risk cleanup, docs, polish, ergonomics, or speculative feature. labels Jul 10, 2026
@clawsweeper

clawsweeper Bot commented Jul 10, 2026

Copy link
Copy Markdown

Codex review: needs maintainer review before merge. Reviewed July 10, 2026, 5:25 PM ET / 21:25 UTC.

Summary
Update the gateway integration guide to document the upstream { url, urls?, bootstrapToken } payload, the Windows-consumed { url, bootstrapToken } shape, and Gateway-enforced token expiry.

Reproducibility: yes. at high confidence from source inspection. Current main documents expiry metadata that the authoritative Gateway payload omits and the active Windows decoder does not consume.

Review metrics: 1 noteworthy metric.

  • Documentation scope: 1 file; 6 additions, 5 deletions. The patch corrects five stale contract references without changing runtime, protocol, configuration, or dependencies.

Root-cause cluster
Relationship: fixed_by_candidate
Canonical: #964
Summary: This PR directly implements the paired documentation issue and should close it when merged.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Merge readiness
Overall: 🐚 platinum hermit
Proof: 🌊 off-meta tidepool
Patch quality: 🐚 platinum hermit
Result: ready for maintainer review.

Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch.

Rank-up moves:

  • Update the PR body with completed ./build.ps1, shared-test, and tray-test results.

Risk before merge

  • [P1] Merge readiness remains unproven until the repository-required build, shared tests, and tray tests complete successfully; those results were still pending in the PR body and CI during review.

Maintainer options:

  1. Decide the mitigation before merge
    Keep the source-accurate one-file documentation correction and merge it after the required validation completes and its results are recorded.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Next step before merge

  • [P2] No concrete defect remains for an automated repair lane; the PR needs only required validation completion and normal maintainer merge review.

Security
Cleared: The documentation-only diff changes no executable code, dependencies, workflows, permissions, credentials, or network behavior.

Review details

Best possible solution:

Keep the source-accurate one-file documentation correction and merge it after the required validation completes and its results are recorded.

Do we have a high-confidence way to reproduce the issue?

Yes, at high confidence from source inspection. Current main documents expiry metadata that the authoritative Gateway payload omits and the active Windows decoder does not consume.

Is this the best way to solve the issue?

Yes. Correcting the existing integration guide is the narrowest maintainable solution and avoids reintroducing an unsupported client-side expiry contract.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 053501c6dfae.

Label changes

Label changes:

  • add P3: This is a focused documentation accuracy fix with limited blast radius and no runtime behavior change.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: Real behavior proof is not required because this PR only changes files under docs/.

Label justifications:

  • P3: This is a focused documentation accuracy fix with limited blast radius and no runtime behavior change.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: Real behavior proof is not required because this PR only changes files under docs/.
Evidence reviewed

What I checked:

Likely related people:

  • shanselman: Authored the QR setup-pairing work and the strongest merged history across the integration guide, decoder, and setup-code tests. (role: feature introducer; confidence: high; commits: 00670860ed76, ed218e960712, 4166e0fd63f8; files: docs/gateway-node-integration.md, src/OpenClaw.Connection/SetupCodeDecoder.cs, tests/OpenClaw.Connection.Tests/SetupCodeDecoderTests.cs)
  • steipete: Authored merged onboarding redesign work that established the current setup flow and removed the obsolete client-side expiry behavior referenced by the guide. (role: recent setup redesign contributor; confidence: high; commits: adcb4c378f90; files: src/OpenClaw.Connection/SetupCodeDecoder.cs, docs/CONNECTION_ARCHITECTURE.md, docs/ONBOARDING_WIZARD.md)
What the crustacean ranks mean
  • 🦀 challenger crab: rare, exceptional readiness with strong proof, clean implementation, and convincing validation.
  • 🦞 diamond lobster: very strong readiness with only minor maintainer review expected.
  • 🐚 platinum hermit: good normal PR, likely mergeable with ordinary maintainer review.
  • 🦐 gold shrimp: useful signal, but proof or patch confidence is still limited.
  • 🦪 silver shellfish: thin signal; proof, validation, or implementation needs work.
  • 🧂 unranked krab: not merge-ready because proof is missing/unusable or there are serious correctness or safety concerns.
  • 🌊 off-meta tidepool: rating does not apply to this item.

Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

How this review workflow works
  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@shanselman
shanselman merged commit 622c0e2 into main Jul 10, 2026
13 checks passed
@shanselman
shanselman deleted the codex/docs-setup-code-expiry branch July 10, 2026 21:46
@steipete

Copy link
Copy Markdown
Contributor Author

Land-ready proof at exact head 795b7b7a2856e6f0c82662612d45c767bfe48ae4:

  • Structured autoreview: clean; no accepted/actionable findings.
  • Native Windows x64 via AWS Crabbox cbx_334b40932fe4 (public networking, no Tailscale):
    • ./build.ps1 — PASS: Shared, Cli, WinNodeCli, SetupEngine, WinUI.
    • dotnet test ./tests/OpenClaw.Shared.Tests/OpenClaw.Shared.Tests.csproj --no-restore — PASS: 2,732 passed, 0 failed, 31 skipped; 2,763 total.
    • dotnet test ./tests/OpenClaw.Tray.Tests/OpenClaw.Tray.Tests.csproj --no-restore — PASS: 1,669 passed, 0 failed, 0 skipped.
  • Hosted CI: Build and Test run 29124301210 and CodeQL run 29124299655 completed successfully at the same head. This includes full tests, three setup/recovery E2E lanes, and x64/ARM64 packaging.
  • Source contract proof: the upstream payload is { url, urls?, bootstrapToken }, the Gateway enforces the 10-minute TTL, and the current Windows decoder consumes only url and bootstrapToken.
  • Proof gaps: none.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P3 Low-risk cleanup, docs, polish, ergonomics, or speculative feature. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Docs: correct the setup-code expiry contract

2 participants