MakerRepo CLI – Artifacts
The artifacts subcommands let you manage, view, and interact with artifacts in the local repository.
Artifacts are discovered by scanning the current directory for Python packages and modules that define
@artifact-decorated functions. You can refer to artifacts by name or by module/name when there are
multiple artifacts with the same name.
For the concept of artifacts and the @artifact decorator, see Artifacts.
All examples below assume you run commands from the repository root.
For caching, logging, and completion flags that apply to all subcommands, see:
List artifacts
List artifacts discovered from the current repository. Prints a table of Module, Name, and Sample for each artifact.
| Option | Description |
|---|---|
-o, --output |
Output format (default: table). Use -o json for JSON to stdout. |
View artifacts
Run the OCP viewer locally and send the built artifact(s) to it. If you omit artifact names, an interactive prompt lets you select which artifact(s) to view.
| Option | Description |
|---|---|
-p, --port |
Port for the OCP Viewer to receive model data (default: 3939). |
--camera |
Camera preset when loading the model (default: reset). |
--colormap |
Colormap for coloring parts (e.g. tab10, none). Default: none. |
--versioned |
Use the versioned model for artifacts (if available). When the artifact returns a Result with a versioned variant (e.g. a model with a build version mark), this flag shows that variant instead of the primary model. Fails if versioned is requested but not provided. |
Export artifacts
Export artifact(s) to file(s). Supported formats: STEP, STL, BREP, glTF, 3MF, SVG, DXF. Format is inferred from the output path extension if not specified.
| Option | Description |
|---|---|
-o, --output |
Output file or directory (default: current directory). |
-f, --format |
Export format (default: step, or inferred from -o extension). |
--versioned |
Use the versioned model for artifacts (if available). Exports the versioned variant from a Result instead of the primary model when set. |
If you pass a single artifact and a path with a file extension (e.g. -o part.step), that file is written.
If you pass a directory or multiple artifacts, one file per artifact is written (e.g. module_artifact.step).
Snapshot
Capture a screenshot of the artifact(s) and save it as an image file. Uses a headless CAD viewer to render and capture the image.
| Option | Description |
|---|---|
-o, --output |
Output image file path (default: snapshot.png). |
--camera |
Camera view preset for the snapshot (default: iso). |
--colormap |
Colormap for coloring parts (default: none). |
--versioned |
Use the versioned model for artifacts (if available). Snapshots the versioned variant from a Result when set. |