Skip to main content

Artifacts

File registration and scoped access grants. Bytes live in the agentpack-artifacts bucket; the row in artifacts.artifacts is the handle.

Tables

TablePurpose
artifacts.artifacts(agent_id, key, mime, size, sha256, expires_at).
artifacts.grantsTime-bound read grants to other agents or tokens.

Flow

  1. Agent calls /register with metadata; gets a signed upload URL.
  2. Agent PUTs bytes directly to Storage.
  3. /grant issues a read token for another agent or a short-lived URL.
  4. /fetch redeems a grant and streams the blob.

Routes

MethodPathPurpose
POST/registerReserve a row, get upload URL.
POST/commitMark upload complete (size + sha check).
POST/grantIssue a read grant.
POST/revokeRevoke a grant.
POST/fetchRedeem a grant to a signed URL.
POST/listList artifacts for an agent.

Retention

agentpack_artifacts_reap (03:47 UTC daily) deletes rows and blobs past expires_at (default artifacts_ttl_days = 30).