gabriel / muse public
feat patch task/117-phase5-domain-crud-cli #1 / 1
AI Agent gabriel · 15 days ago · Jul 3, 2026 · Diff

feat: muse domains update / muse domains delete (CRUD CLI parity)

musehub#117 Phase 5 (DOM_18): CLI equivalents of the server's new PATCH/DELETE /api/domains routes, alongside the existing publish (Create).

- muse domains update --author X --slug Y [--name] [--description] [--viewer-type] [--version] [--capabilities] [--dry-run] [--json] Partial update — only passed fields change. --dry-run validates --viewer-type/--capabilities locally, same as publish's DOM_15. - muse domains delete --author X --slug Y [--json] Deprecates the domain (soft flag flip on the server, not a hard delete).

New _patch_json/_delete_request HTTP helpers mirroring _post_json. 16 new CLI tests (success, --json, 403/404/422, --dry-run, no-token, network error). Bump version to 0.2.0rc16.

sha256:38005a5db979d6bd95c2edeca23a0daa179826f303035ac99e3ddc9241671e0e sha
+25 ~6 symbols
3 changed · 1120 in snapshot files
sha256:604f4ec565ced6a6d4a39b56c1747dff83692237274afc767e1f91cb1c1bea91 snapshot
+25
symbols added
~6
symbols modified
3
files changed
1120
files in snapshot
0
dead code introduced
Semantic Changes 31 symbols
~ muse/cli/commands/domains.py .py 7 symbols added, 4 symbols modified
+ _DeleteResultJson class class _DeleteResultJson L264–277
+ _UpdateResultJson class class _UpdateResultJson L247–262
+ _delete_request function function _delete_request L801–819
+ _patch_json function function _patch_json L772–798
+ cast import import cast L62–62
+ run_delete function function run_delete L1286–1379
+ run_update function function run_update L1106–1280
~ pyproject.toml .toml 2 symbols modified
~ tests/test_domains_publish.py .py 18 symbols added
+ _DELETE_REQUIRED_ARGS variable variable _DELETE_REQUIRED_ARGS L541–546
+ _UPDATE_REQUIRED_ARGS variable variable _UPDATE_REQUIRED_ARGS L533–539
+ test_delete_http_403_not_owner function function test_delete_http_403_not_owner L718–731
+ test_delete_http_404_not_found_or_already_deprecated function function test_delete_http_404_not_found_or_already_deprecated L734–747
+ test_delete_json_flag function function test_delete_json_flag L698–708
+ test_delete_missing_required_author function function test_delete_missing_required_author L760–764
+ test_delete_network_error function function test_delete_network_error L750–757
+ test_delete_no_token function function test_delete_no_token L711–715
+ test_delete_success function function test_delete_success L684–695
+ test_update_dry_run_invalid_viewer_type function function test_update_dry_run_invalid_viewer_type L664–681
+ test_update_dry_run_valid function function test_update_dry_run_valid L654–661
+ test_update_http_403_not_owner function function test_update_http_403_not_owner L606–619
+ test_update_http_404_not_found function function test_update_http_404_not_found L622–635
+ test_update_http_422_validation function function test_update_http_422_validation L638–651
+ test_update_json_flag function function test_update_json_flag L569–584
+ test_update_no_fields_exits_one function function test_update_no_fields_exits_one L587–596
+ test_update_no_token function function test_update_no_token L599–603
+ test_update_success function function test_update_success L549–566
Files Changed
~3
1120 in snapshot
← Older Oldest on task/117-phase5-domain-crud-cli
All commits
Newer → Latest on task/117-phase5-domain-crud-cli

0 comments

No comments yet. Be the first to start the discussion.

To add a comment, use the Muse CLI: muse hub commit comment sha256:38005a5db979d6bd95c2edeca23a0daa179826f303035ac99e3ddc9241671e0e --body "your comment"