Skip to content

fix(uteke-client): prefer /room/summary-document with legacy fallback#178

Merged
ajianaz merged 1 commit into
developfrom
fix/room-document-endpoint-rename
Jul 20, 2026
Merged

fix(uteke-client): prefer /room/summary-document with legacy fallback#178
ajianaz merged 1 commit into
developfrom
fix/room-document-endpoint-rename

Conversation

@ajianaz

@ajianaz ajianaz commented Jul 20, 2026

Copy link
Copy Markdown
Collaborator

What

Migrates room_document() to the canonical endpoint name introduced by uteke #735 (post-v0.8.0-tag develop), with a backward-compatible fallback so Corin keeps working against the already-released v0.8.0 tag.

Why

Uteke #735 renamed POST /room/documentPOST /room/summary-document to avoid colliding with the existing GET /room/summary. The old route still works on newer servers but logs a deprecation warning and will eventually be removed.

This is the only deprecated/renamed endpoint in uteke develop that Corin uses. Cross-checked every other endpoint Corin calls (/recall, /search, /doc/*, /memory, /graph/*, /room/*, /tags, /timeline, /edges) — all unchanged and stable.

How

room_document() now:

  1. Tries POST /room/summary-document (canonical, develop).
  2. On HTTP 404 (older server, e.g. released v0.8.0 tag) → falls back to legacy POST /room/document.
  3. Any other non-success status → surfaced as an error with context.

Also adds a module-doc compat note and updates the format_room_document doc comment.

Compat note: /api/v1/ prefix NOT used

Verified that /recall (plain, no search_type) and /search return the stable [{memory, score}] shape across uteke 0.7.x–0.8.x, so no version prefix is needed. The /api/v1/ / /api/v2/ prefix (uteke #737) is currently broken in develop anyway — ApiVersion::from_path strips the leading slash so versioned routes 404 against the route match arms.

Verification (all green)

Check Result
cargo fmt --all -- --check
cargo clippy -- -D warnings ✅ 0 warnings
cargo test ✅ 14/14 pass
svelte-check ✅ 0 errors
vitest --run ✅ 61/61 pass
npm run build ✅ built in 5.37s

Rust-only change (+43/-1 across 2 files). No frontend touched.

uteke #735 (post-v0.8.0-tag develop) renames POST /room/document to
POST /room/summary-document to avoid colliding with the existing
GET /room/summary. The old route still works on newer servers but logs
a deprecation warning and will eventually be removed.

room_document() now prefers /room/summary-document and falls back to
the legacy /room/document on HTTP 404, so Corin works against both the
released v0.8.0 tag (which only has the old route) and the upcoming
release cut from develop.

Also documents /recall and /search compat in the module doc: both
return the stable [{memory, score}] shape across uteke 0.7.x-0.8.x, so
no /api/v1/ prefix is needed (and that prefix is currently broken in
uteke develop anyway due to a leading-slash stripping bug in
ApiVersion::from_path).
@github-actions

Copy link
Copy Markdown

🔍 Cora AI Code Review

No issues found. Code looks good!


Review powered by cora-cli · BYOK · MIT

@ajianaz
ajianaz merged commit 78951ac into develop Jul 20, 2026
8 checks passed
@ajianaz ajianaz mentioned this pull request Jul 20, 2026
ajianaz added a commit that referenced this pull request Jul 20, 2026
Patch release — Windows Documents-tab fix, uteke 0.8.x compatibility, and
a full dependency sweep (incl. vite 6→8).

- bump version 0.3.1 → 0.3.2 (package.json, Cargo.toml, Cargo.lock,
  tauri.conf.json)
- CHANGELOG entry

Contents (since v0.3.1):
- Fixed: Windows "uteke CLI not found" — HTTP-first version gate reads
  /health `version`; CLI discovery now PATHEXT-aware (#171, #180)
- Fixed: uteke 0.8.x room-document compat — /room/summary-document with
  legacy /room/document fallback (#178)
- Changed: version gate HTTP-first for local servers too (#180)
- Deps: vite 6→8 + @sveltejs/vite-plugin-svelte 5→7 (#179), tokio
  1.52→1.53 (#175), serde/thiserror/toml/tauri-plugin-dialog,
  @codemirror/language/dompurify/marked, actions/setup-node 6→7 (#172)
@ajianaz ajianaz mentioned this pull request Jul 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant