Skip to main content
Artifact tools let agents save, load, and list files during execution. Useful for persisting generated code, reports, images, or any data the agent produces.

Setup

Available tools

save_artifact

Returns a confirmation string with the version number and byte count.

load_artifact

Returns the file content as text, or base64-encoded string for binary files.

list_artifacts

Returns a newline-separated list of all saved artifact filenames, or "No artifacts saved.".

Versioning

Every save_artifact call increments the version number for that filename. The version is tracked in EventActions.artifact_delta so artifact changes appear in the session event log.

CallContext API

Tools can also save and load artifacts programmatically via CallContext:

Artifact services

Composer YAML

Artifact tools are not yet available as a builtin in Composer YAML. Use the Python API to add them to your agent.