Repository navigation
Description
Problem or use case
In the precommitted camera authoring trial using the unreleased authenticated-handler candidate f17b724 (#833), the agent preserved native auth and explicit function routes but timed out after 600 seconds. Its transcript shows repeated schema/CLI inspection and a concrete validation detour:
- It searched installed CLI/source files to discover the project revision command.
- It ran the generated
npm run validatescript withPROJECT_SHA256supplied. The script includes--host-file host.mjsbut no origin, so activation correctly refused withExtensions require an explicit operator origin; pass --origin https://your.site. - Its subsequent command supplied
--origin https://handler.example.test, but the trial ended before a completed delivery.
This is an observed usability gap, not a claim that validation caused the entire timeout or that the runtime's refusal is wrong. The starter already included the recipe README and a task guide. No deployed urlcode.ai or MCP assistance was used. One trial is not a general performance result.
Proposed behavior and alternatives
Provide a small, executable authoring/validation context path that tells an agent exactly which project, host, canonical origin and operator-reviewed revision are needed, and prints a complete runnable command when any are missing. Consider aligning generated npm scripts and the existing agent/context output around that path rather than adding another large guide.
Keep approval explicit: inspecting a revision must never automatically authorize it, silently update grants, or repin at server startup (see #784). Do not put provider configuration into route YAML or infer a production origin from untrusted requests. A static validation mode could clearly distinguish schema checks from host activation if that is useful.
Acceptance should use a clean installed init --with auth consumer, generated scripts, and supplied operator context. Test that missing context yields one actionable command and that explicit context reaches validation without source-code searching. Preserve host/origin propagation fixes from #778/#791.
Related: #832/#833 (native session identity), #822 (extension references). This request concerns the operational handoff to validation, not syntax coverage or more business recipes.
Activity
jimhoyd commentedon Sep 28, 2026
Scope alignment with #841: this remains the authoritative executable-validation-context issue. Prove the installed project/host/origin/reviewed-revision commands through #843, both CLI-only and connected authoring MCP. Coordinate provider discovery with #844 and SDK replacement with #846. Human revision approval stays explicit; no compatibility path for historical tooling is required. This is not blocked on completing the whole ecosystem program.
jimhoyd commentedon Sep 28, 2026
Evidence from the #843 proof (PR: #848). One agent run on a packed checkout of
a996f0d8; observations, not a benchmark.The proof site uses
--host-file host.mjs, an explicit--origin, and an operator--policythat grants the routes'APP_DATABASEbinding and pins the reviewed revision. With all three, CLIvalidate,test,audit --expect-routes 8(ready: true, via signed-instepsfixtures) andservework, and an unreviewed edit is refused with a clearrevision-pin-mismatchuntil the evaluator regenerates the policy. That approval step stayed manual.Gaps an agent hits on the way, all on the path this issue owns:
urlcode bootstrap --jsoncommands.validate/test/startinclude--host-filebut neither--policynor--origin, so none of them run as printed for this site.bootstrap'spaths.outsideProjectsuggests, foroperator/anddata/, "To serve it, build or copy it into app/operator". Those directories hold the Better Auth secret and SQLite databases. The hint should not invite serving operator-only directories.urlcode context,explainandreviewaccept--host-filebut not--policy. The agent has to discover and exportPROJECT_SHA256separately, although the policy file already carries the reviewed revision.--policy(its tool descriptions say so), sorun_validate,run_testandrun_auditfail withbinding-deniedon any site whose routes need an operator-granted binding. Its read-only tools (get_extensions,summarize_yaml_change,validate,plan_feature) worked and saw the host registration. The proof did not change this boundary; deciding whether and how an MCP server may be handed an operator policy is this issue's call.plan_featurefor "let an owner filter their request list by status" suggestedheadless-auth-profileandhealth-pagerecipes (legacy auth, a word match on "status"), not a queryparametersdeclaration.jimhoyd commentedon Sep 28, 2026
Correction to my earlier comment:
bootstrapdid name--originand--policyunderprerequisites; the gap was that neither it norcontext/explain/review/plan-feature/mcpcould accept a policy, so the commands never became complete and hosts neededPROJECT_SHA256by hand.Implementation: #849 (stacked on #848). The reviewed policy pins those commands' hosts and appears in emitted commands; the MCP server verifies it at startup and its runners forward it. On the packed Better Auth proof, MCP
run_validate,run_test(34/34) andrun_auditnow pass with noPROJECT_SHA256. Human approval is unchanged: nothing creates or repins a policy, and a project edit still invalidates it. The PR calls out that this reverses the documented "mcp accepts no --policy" choice, for the maintainer to accept or veto.Pass the operator's reviewed policy to inspection commands and the au…
Run the authoring MCP server on the official MCP SDK (#846, stdio) (#850
feat(core): actionable operator context for scripts and a declarative…
jimhoyd commentedon Sep 29, 2026
Done:
--policyon every inspection command and the MCP runner, with named policy-file errors.URLCODE_ORIGIN/URLCODE_POLICYfallbacks, one runnable command inorigin-required/revision-pin-requiredrefusals, the packedextensions add authacceptance test, andplan_featurelist queries.--expect-routeskept in sync.Approval stays explicit: nothing creates or repins a policy.