---
title: "Publish artifacts"
description: "Choose the CLI, MCP, or HTTP publishing path and create immutable artifact versions."
---

> Documentation Index
> Fetch the complete documentation index at: https://artifactserver.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Publish artifacts

Artifact Server supports complete single-file and multi-file publications through one verified upload contract. Choose the publication path based on where the files exist.

## Publish from an agent

Connect your agent to a local installation. Then install the Artifact Server skill:

```sh
artifactserver connect
npx skills add plannotator/artifact-server
```

Inside the source checkout, use `pnpm artifactserver connect --data .artifact-server` instead.

In clients that expose installed skills as slash commands:

```text
/artifact-server upload that HTML design doc
```

The skill uses the CLI when the file is on your machine. It uses MCP when the content already exists in the agent or server. The skill returns the full-screen review link first.

## Publish manually

If the bytes are already on disk, use the installed CLI:

```sh
artifactserver publish ./prototype/index.html \
  --name "Checkout prototype" \
  --tag prototype \
  --tag checkout
```

When working inside the Artifact Server source checkout, use `pnpm artifactserver publish` with the same arguments.

For a directory, Artifact Server reads the declared files and computes the manifest. It stages the upload, verifies each file, and commits one immutable version.

## Files already in an agent session

If an agent already has the content, use the connected Artifact Server MCP. The agent does not need to write the files to your machine first. MCP and the CLI return the same artifact and version identity.

The same Artifact Server skill routes explicit installation, deployment, upgrade, backup, restore, and repair requests to separate server-operation instructions. Routine publication does not load administrator procedures.

## Publish a new version

A new publication never edits a committed version. After stale-write and byte verification succeed, Artifact Server creates a version and updates the current-version pointer.

```text
Artifact link  ───────────────→ current version
Exact link v1 ───────────────→ immutable v1
Exact link v2 ───────────────→ immutable v2
```

Retries use idempotency records so a repeated successful request resolves to the original version instead of creating a duplicate.

Source: https://artifactserver.com/docs/publish/index.mdx
