Skip to content

fix: cases CLI/SDK alignment with ext-cases backend#274

Merged
maximelb merged 2 commits intocli-v2from
fix/cases-backend-alignment
Apr 3, 2026
Merged

fix: cases CLI/SDK alignment with ext-cases backend#274
maximelb merged 2 commits intocli-v2from
fix/cases-backend-alignment

Conversation

@maximelb
Copy link
Copy Markdown
Contributor

@maximelb maximelb commented Apr 3, 2026

Summary

  • Bug fix: export --with-data used detection_id instead of detect_id when reading detection records from the API response, causing all detection fetches to silently fail (every detection was skipped)
  • Missing feature: Add is_public parameter to add_note SDK method and --is-public/--no-is-public flag to CLI add-note command (backend supports it, was not exposed)
  • Missing feature: Add update_note_visibility SDK method and update-note CLI command for PATCH /cases/{n}/notes/{id} endpoint (toggle note public/private visibility)
  • Missing feature: Add list_orgs SDK method and orgs CLI command for GET /orgs endpoint (discover ext-cases-subscribed organizations)

Test plan

  • All 177 existing + new unit tests pass
  • SDK tests cover add_note with is_public (true, false, None)
  • SDK tests cover update_note_visibility (set public, set private)
  • SDK tests cover list_orgs (path, no query params)
  • CLI tests cover add-note --is-public / --no-is-public
  • CLI tests cover update-note (public, private, missing flags)
  • CLI tests cover orgs command
  • Export tests updated to use detect_id field name
  • Help text test updated to verify new commands appear

🤖 Generated with Claude Code

maximelb and others added 2 commits April 3, 2026 09:50
- Fix export --with-data using wrong field name (detection_id -> detect_id),
  which caused all detection fetches to silently fail
- Add is_public parameter to add_note SDK method and --is-public flag to
  CLI add-note command
- Add update_note_visibility SDK method and CLI update-note command for
  toggling note public/private visibility
- Add list_orgs SDK method and CLI orgs command for discovering
  ext-cases-subscribed organizations

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@maximelb maximelb requested a review from dzimine-lc April 3, 2026 18:44
@maximelb maximelb merged commit 604b819 into cli-v2 Apr 3, 2026
7 checks passed
@maximelb maximelb deleted the fix/cases-backend-alignment branch April 3, 2026 18:44
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