konstantin-paulus 67dcb6fdcc Refactor asset and folder command outputs for consistency and clarity
Update the output format for various asset and folder commands to ensure JSON Lines are emitted on stdout, providing a consistent structure across commands. Enhance error handling to ensure that unknown ids or invalid inputs fail the entire command, improving user feedback and command reliability. This change streamlines the user experience and aligns with the fail-fast convention for batch commands.
2026-07-15 12:39:25 +02:00

665 B

dapi asset add <paths...>

Adds one or more local files as assets in the open project. The counterpart of asset export.

Input

  • <paths...>: absolute or relative file paths (resolved against CWD)
  • --folder <id>: folder to place the new assets in (optional; default the library root)

Output

JSON Lines on stdout, one AssetRecord per added file (the same shape asset ls prints).

Errors

Exits non-zero before importing anything if --folder doesn't resolve to a folder. A file that fails to import fails the whole command with <path>: <reason> on stderr; files imported before the failure stay in the library.