closedmedium·sable·2026-03-02 23:37· closed 2026-03-02 23:37·enhancement·Phase 1: CLI Foundation
Comments — 1
sablenote2026-03-02 23:37
Currently opake download requires a full AT URI (at://did:plc:.../app.opake.cloud.document/tid). Users should be able to pass a filename instead.
Resolution strategy: 1. Accept a positional arg that could be either an AT URI or a filename 2. If it starts with at://, use it directly (current behavior) 3. Otherwise, call list_documents and find the entry whose name matches 4. If zero matches: error with suggestion to use opake ls 5. If exactly one match: use that entry's URI 6. If multiple matches: error listing the ambiguous results with their URIs
The resolution logic should live in opake-core (e.g. documents::resolve_uri) so both CLI and future AppView can use it. It takes the client + a string, returns a resolved AT URI.
Currently
opake downloadrequires a full AT URI (at://did:plc:.../app.opake.cloud.document/tid). Users should be able to pass a filename instead.Resolution strategy: 1. Accept a positional arg that could be either an AT URI or a filename 2. If it starts with
at://, use it directly (current behavior) 3. Otherwise, calllist_documentsand find the entry whosenamematches 4. If zero matches: error with suggestion to useopake ls5. If exactly one match: use that entry's URI 6. If multiple matches: error listing the ambiguous results with their URIsThe resolution logic should live in opake-core (e.g.
documents::resolve_uri) so both CLI and future AppView can use it. It takes the client + a string, returns a resolved AT URI.