PCLI2

2.2.0 - 2026-09-22

v2.2.0 Sep 22 2026 at 18:32 UTC

Added

  • asset move puts an asset in another folder (alias mv) - --uuid or --path names the asset, --folder-uuid or --folder-path the destination; / (or /Home) as the path is the root. The asset keeps its UUID and metadata; only its path changes. Silent on success, --dry-run names the asset and the destination. Uses PATCH /tenants/{tenantId}/assets/{assetId}/folder.

  • asset resolve-dependency links a missing dependency to an existing asset (alias resolve-dep) - An assembly whose referenced part was not found stays in the missing-dependencies state. --dependency takes the missing path as asset dependencies lists it, --target-uuid or --target-path the asset that should stand in for it; the server re-indexes the assembly. The dependency must be one of the assembly's missing ones, otherwise the command stops and lists them (exit 64), so a typo never reaches the server. Silent on success, --dry-run names everything. Uses POST /tenants/{tenantId}/assets/{assetId}/resolve-dependency.

  • tenant metadata manages the field registry - Beside list: rename --name OLD --new-name NEW (values on assets are kept), delete --name NAME [--force] (the server refuses a field still in use unless --force, which also removes its values from every asset; confirms unless --yes, --dry-run supported), assets --name NAME [--limit N] (the assets with a value for the field, printed like asset list), coverage (how many assets carry any metadata: counts and a percentage, JSON or CSV), and missing [--folder-path P]* [--extension E]* [--limit N] (the assets with no metadata at all, oldest first; Physna's demo assets excluded). Fields are addressed by their exact registered name; an unknown name lists the registered ones (exit 67). Endpoints: PATCH/DELETE /tenants/{tenantId}/metadata-fields/{fieldId}, GET .../metadata-fields/{fieldId}/assets, GET .../metadata-coverage, GET .../assets/without-metadata.

  • pcli2 report manages report jobs - A new command group for the server-side reports (duplication, simplification, custom). report list [--type] [--status] [--limit] (newest first; CSV ID,NAME,TYPE,STATUS,PROGRESS,GROUPS,MIN_THRESHOLD,MAX_THRESHOLD,CREATED_AT,UPDATED_AT,CREATOR), report get --id, report download --id --format csv|xlsx [-o PATH] (only a COMPLETED report; the file is streamed through a temporary file like an asset download; the default name is the report's name or id plus the extension), report diagnose --id (why a report failed, same shape and exit codes as asset diagnose), report delete --id (confirms unless --yes, --dry-run), and report create for a duplication report over --folder-path folders (subfolders included; --exclude-folder-path, --extension, --exclude-assemblies, --exclude-exact-duplicates, --include-home, thresholds default 80 to 100). --wait polls until the report is COMPLETED, FAILED or CANCELLED (progress on stderr; a credential failure stops at once, any other polling error is retried up to three times in a row) and a report that ended FAILED or CANCELLED exits 69 with a pointer to report diagnose. tenant failures already listed failed reports; their ids now have somewhere to go.

Changed

  • tenant metadata list JSON carries each field's id - The registry listing always sent ids; the client now reads them, since rename and delete address a field by id. The CSV and tree output are unchanged.

  • Dependencies are read by asset ID - asset dependencies, folder dependencies and asset dependency-diff now use GET /tenants/{tenantId}/assets/{assetId}/dependencies-by-id, which looks the asset up by its stored path on the server, so the lookup keeps working after a folder is moved or renamed. The path-based /assets/{assetPath}/dependencies endpoint the commands used is deprecated in Physna's specification. Output is unchanged in every format. The client now also reads each dependency's status (matched, resolved, missing) and never asks the API about a missing dependency's children (it has no asset, so the only UUID to ask about was the nil one).

  • --skip-existing asks the server instead of listing the folder - asset create-batch --skip-existing and folder upload (which checks for existing names in both modes) now send the target paths to POST /tenants/{tenantId}/assets/existing-paths, one request per 1000 files, instead of paging through the whole destination folder. Which files are skipped, the Skipping existing asset: ... lines, the counts and the "Asset already exists" error are unchanged.

  • asset create --override replaces the file in place - When the asset exists and the new file has the same extension, the file is sent to PUT /tenants/{tenantId}/assets/{assetId}/file: the asset keeps its UUID, path and metadata and is re-indexed with the new content. Nothing is deleted, so a failed upload leaves the tenant as it was. --restore-metadata has nothing to do in that case and says so. A file with a different extension still goes the old way (delete, then upload, with the conflict retry and the loss report). --override --dry-run now says which of the two would happen and names the asset; without --override the dry-run line is unchanged. Uploads (asset create, asset create-batch, folder upload) go through the client's upload variant, which shares the token with the rest of the run; it makes no difference today because there is no separate upload timeout setting.

  • asset get takes several --uuid values - They are fetched with one POST /tenants/{tenantId}/assets/batch request (up to 1000 per request) and printed as an asset list, in the same JSON and CSV shapes as asset list. Every id must exist: otherwise nothing is printed and the missing ids are named (exit 67). With one --uuid or --path the output is unchanged. The client's batch method, which nothing used, now calls that endpoint instead of one request per asset.

Fixed

  • folder dependencies lists assemblies in a stable order - The JSON and tree output listed a folder's assemblies in a different order on every run (the folder listing is a map). They are now sorted by path, as the CSV rows already were.

Removed

  • Four path-based dependency methods of the client library - get_asset_dependencies_by_path, get_asset_dependencies_by_path_with_pagination, populate_asset_dependencies_recursive_by_path and the unused populate_asset_dependencies_recursive. Every command that used them holds the asset's UUID already and calls get_asset_dependencies_by_uuid.