Stat artifact
stat_artifactVerify the byte size and SHA-256 digest of an exported or saved file in the Inkscape workspace.
Instructions
Return the on-disk byte size + sha256 digest of one sandboxed artifact.
When to use: to VERIFY what you wrote (an export, a render, a saved SVG) — its exact byte size
and content digest — without a wc -c / sha256sum Bash fallback. For a whole SET (and an
aggregate byte total) use stat_artifacts; for image pixel dimensions read the producing
tool's result fields instead.
Key params: path may be workspace-RELATIVE (anchored to the first workspace root, matching
open_document / save_document_as) or absolute; either is sandbox-validated and a
../-escape, an absolute path outside the workspace, or a symlink whose target leaves the
sandbox is rejected with path rejected: outside workspace. The file must exist and be within
the configured size limit; the sha256 is computed streaming so a large file is bounded in
memory.
Return shape: ArtifactStat — {path, bytes, sha256} where path is the WORKSPACE-RELATIVE
POSIX path (never a host path) and sha256 is the lowercase hex digest.
Example: stat_artifact("dist/logo.png")
Risk class: low (read-only stat; nothing is mutated, no Operation Record / snapshot).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| bytes | Yes | ||
| sha256 | Yes |