chore(rebrand): rename agent + relay URL paths to /api/v1/* (VS-24) #34
Loading…
Reference in a new issue
No description provided.
Delete branch "chore/rebrand-url-paths-VS-24"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
Server-side half of VS-24 (paired with VA-28 slice 6): rename the two agent-facing WebSocket endpoints off the legacy MeshCentral
.ashxhandler names to versioned, vervain-branded paths, and delete the old ones outright (no deprecation alias, per the no-active-deployments guidance).Decisions (from the issue's open questions)
/api/v1/. Lets a future protocol rev ship under/api/v2/without breaking v1 agents./api/v1/agent(control channel) and/api/v1/relay(per-tunnel relay). Composes the chosen/api/...namespace with the/v1/version.pbecomesusage,nodeidbecomesagent_id.id,rauth,auth,browser,slowrelayunchanged.Changes
meshcentral-web/src/wire_paths.rs: single source of truth for the path + param-name constants.build_router): old routes removed, new/api/v1/agent+/api/v1/relayregistered (no-domain and/:domain/...forms). Dropped the/relay.ashxlegacy alias.RelayQuery:nodeid->agent_id,p->usage(wire keys); internal field names unchanged..mshMeshServer=URL builder (meshsettings) and the CSRF-safe-path allowlist (security) reference the constant.public/scripts/agent-redir-ws-0.1.1.js+ its minified twin,public/samples/relay.js,views/messenger.handlebars): emit/api/v1/relaywithusage/agent_id. The minified file was edited by targeted string replacement.Acceptance criteria
wire_paths.rs).grep -rE "agent\.ashx|meshrelay\.ashx"returns zero hits (verified).MeshServer=(regenerate.msh).Out of scope (unchanged)
/control.ashx(user UI channel) and/mcptunnel.ashx(VS-22 MCP rendezvous). Only the two paths named in VS-24 move.Verification
cargo clippy --workspace --all-targets -- -D warningsclean; touched cratesfmt --checkclean;cargo test -p meshcentral-web --lib= 404 passed (incl. updatedbuild_ws_urlexpectations).Note: a pre-existing
cargo fmtdrift inmeshcentral-agent-fetch(untouched by this PR) trips a full-workspacefmt --all --check. Flagging separately; not addressed here to keep the diff scoped.🤖 Generated with Claude Code