Artifacts
Artifacts provide static HTML hosting for workflow outputs. Upload HTML content (reports, dashboards, visualizations) and receive public URLs for sharing. Each artifact is served with security headers and Moira branding.
Use Cases
Section titled “Use Cases”- Reports: Generate analysis reports accessible via URL
- Dashboards: Create interactive HTML dashboards
- Visualizations: Host charts, graphs, and data visualizations
- Documentation: Publish generated documentation
- Previews: Share work-in-progress outputs with stakeholders
MCP Tool
Section titled “MCP Tool”The artifacts MCP tool provides 6 actions:
artifacts({ action: "upload", name: "report.html", content: "<html>...</html>" })artifacts({ action: "update", uuid: "abc-123", content: "<html>...</html>" })artifacts({ action: "delete", uuid: "abc-123" })artifacts({ action: "list", limit: 10 })artifacts({ action: "stats" })artifacts({ action: "token", ttlMinutes: 60 })| Action | Purpose |
|---|---|
upload | Create new artifact, returns URL |
update | Update existing artifact content |
delete | Remove an artifact |
list | List artifacts with pagination |
stats | Quota usage statistics |
token | Generate one-time upload token |
Upload
Section titled “Upload”Create a new HTML artifact:
artifacts({ action: "upload", name: "analysis-report.html", content: "<html><body><h1>Report</h1></body></html>"})→ { uuid: "d0a925d6-7dd8-49ba-b90c-d03b43062d20", url: "https://static.moiraqq.com/d0a925d6-7dd8-49ba-b90c-d03b43062d20.html", name: "analysis-report.html", size: 52, expiresAt: "2024-03-01T10:00:00Z" }Optional executionId links artifact to a workflow execution for tracking.
Update
Section titled “Update”Replace content of an existing artifact:
artifacts({ action: "update", uuid: "d0a925d6-7dd8-49ba-b90c-d03b43062d20", content: "<html><body><h1>Updated Report</h1></body></html>"})Retrieve artifacts with pagination:
artifacts({ action: "list", limit: 10, offset: 0 })→ { artifacts: [{ uuid: "d0a925d6-...", url: "https://static.moiraqq.com/...", name: "report.html", size: 1024, createdAt: "2024-01-15T10:00:00Z" }], total: 5 }Quotas
Section titled “Quotas”| Limit | Value |
|---|---|
| Max file size | 5 MB |
| Total storage | 100 MB per user |
| Max artifacts | 50 per user |
| Default TTL | 30 days |
Check quota usage with stats action:
artifacts({ action: "stats" })→ { totalArtifacts: 5, totalSize: 51200, storageLimit: 104857600, countLimit: 50, storageUsedPercent: 0.05, countUsedPercent: 10 }Upload Tokens
Section titled “Upload Tokens”Generate one-time tokens for HTTP API uploads. Useful for CI/CD pipelines or external tools that cannot use MCP directly.
artifacts({ action: "token", ttlMinutes: 30 })→ { token: "xyz-789", expiresAt: "2024-01-15T10:30:00Z", uploadUrl: "https://moiraqq.com/api/public/artifacts/upload/xyz-789" }Upload via HTTP:
curl -X POST "https://moiraqq.com/api/public/artifacts/upload/xyz-789" \ -H "Content-Type: application/json" \ -d '{"name": "report.html", "content": "<html>...</html>"}'Tokens are single-use and expire after the specified TTL.
Security
Section titled “Security”Artifacts are served with security headers:
| Header | Value |
|---|---|
| Content-Security-Policy | script-src 'none' |
| X-Content-Type-Options | nosniff |
| Referrer-Policy | strict-origin-when-cross-origin |
| Cache-Control | public, max-age=3600 |
| Last-Modified | Artifact update timestamp |
| ETag | "{uuid}-{timestamp}" |
Branding
Section titled “Branding”All artifacts include a Moira branding footer injected before </body>:
<div class="moira-branding-footer"> Created with <a href="https://moiraqq.com">Moira</a></div>The footer is styled to be unobtrusive and links back to Moira.
Workflow Integration
Section titled “Workflow Integration”Workspace Pattern
Section titled “Workspace Pattern”Use artifacts with the workspace pattern to organize workflow outputs:
./project-analysis/├── step-1/│ └── data-collection.md├── step-2/│ └── analysis.md└── artifacts/ ├── dashboard.html # → upload as artifact └── summary-report.html # → upload as artifactLinking to Executions
Section titled “Linking to Executions”Pass executionId when uploading to link artifacts to workflow executions:
artifacts({ action: "upload", name: "execution-report.html", content: "...", executionId: "exec-abc-123"})Linked artifacts appear in the execution inspector UI.
Web UI
Section titled “Web UI”Artifacts are managed through the web interface at /app/artifacts:
- View all artifacts with name, size, URL, and expiration date
- Upload new artifacts with HTML editor
- Edit existing artifact content
- Copy public URL to clipboard
- Open artifacts in new tab
- Delete artifacts
- Monitor quota usage with visual indicator
Related
Section titled “Related”- MCP Tools Reference —
artifactstool with all 6 actions - Workflow Creation — Workspace pattern for organizing outputs