Add a save-artifact skill to social-media-tools

Medium completed
2026-07-02 agentics feature Medium effort

Ship a save-artifact skill for the social-media-tools plugin that copies the HTML Artifact pages Claude generates into ${CLAUDE_PLUGIN_ROOT}/artifacts/ under a dated filename, so a page you just built can be handed off and shared in one command.

Implement Read and implement all steps in the plan at docs/plans/add-save-artifact-skill.md — Add a save-artifact skill to social-media-tools. Verify against the plan's Tests, Verification, and Acceptance Criteria before reporting done. If everything passed, mark completion in docs/plans/add-save-artifact-skill.md — tick each step's [x] marker and each criterion's - [x], set status: completed — and re-render the HTML from the spec. If any check failed, leave status: in-progress and say which.
More ways to run this plan — goal & workflow prompts, file path
Pursue as goal — optimize for the outcome, in parallel
Achieve this goal: Add a save-artifact skill to social-media-tools. The plan at docs/plans/add-save-artifact-skill.md describes one approach — use it as reference, but optimize for the outcome. Fan out across parallel subagents where that serves the outcome. Verify against the plan's Tests, Verification, and Acceptance Criteria before reporting done. If everything passed, mark completion in docs/plans/add-save-artifact-skill.md — tick each step's [x] marker and each criterion's - [x], set status: completed — and re-render the HTML from the spec. If any check failed, leave status: in-progress and say which.
Run as workflow — launch parallel subagents
Run a workflow to implement the plan at docs/plans/add-save-artifact-skill.md — Add a save-artifact skill to social-media-tools. Brief subagents with the plan file at docs/plans/add-save-artifact-skill.md. Reserve a final verification phase for the lead agent, not a subagent. Verify against the plan's Tests, Verification, and Acceptance Criteria before reporting done. If everything passed, mark completion in docs/plans/add-save-artifact-skill.md — tick each step's [x] marker and each criterion's - [x], set status: completed — and re-render the HTML from the spec. If any check failed, leave status: in-progress and say which.
File add-save-artifact-skill.html
Path docs/plans/add-save-artifact-skill.html
Spec docs/plans/add-save-artifact-skill.md
Definition of done 5 / 5 done

Context

The story behind this plan — what prompted the work and why it matters now.

Claude's Artifact tool produces self-contained HTML pages (design-guided pages, dashboards, tools), but each lives only in the chat session — there is no one-step way to drop a finished page somewhere shareable. This adds a save-artifact skill to social-media-tools (the repo's share-focused plugin) that copies a chosen HTML artifact into ${CLAUDE_PLUGIN_ROOT}/artifacts/ . Tradeoff, chosen deliberately: ${CLAUDE_PLUGIN_ROOT} resolves to the installed plugin cache (e.g. ~/.claude/plugins/cache/… ), which is wiped on every plugin reinstall or update — so artifacts saved there are not durable and are not committed with the repo. This location was requested explicitly; the durability tradeoff is tracked in Unresolved Questions.

Files that change

Every file this plan touches, and what happens to each one.

agentics/
  • kit/plugins/social-media-tools/skills/save-artifact/SKILL.md new the save-artifact skill body
  • kit/plugins/social-media-tools/
    • CHANGELOG.md modified add 2.15.0 entry
    • README.md modified list save-artifact skill
  • .claude-plugin/marketplace.json modified bump version to 2.15.0
  • tests/plugins/test-save-artifact.sh new objective smoke test
  • path/to/file.ext modified what changes

Steps

The step-by-step work, in order — each step says what to do, why it matters, and how to check it worked.

1
done Author the save-artifact SKILL.md at kit/plugins/social-media-tools/skills/save-artifact/SKILL.md — frontmatter ( name: save-artifact , a three-part description ending in a trigger phrase, allowed-tools: Bash, Read, Write, Glob, AskUserQuestion, ToolSearch, ExitPlanMode ) plus a body that (1) resolves the source HTML artifact — explicit path arg, else materializes an in-chat artifact to a temp file via Write , else Glob + AskUserQuestion ; (2) resolves ${CLAUDE_PLUGIN_ROOT}/artifacts and mkdir -p s it, erroring clearly if the variable is unset rather than writing elsewhere; (3) copies to a dated <slug>-YYYY-MM-DD.html basename, appending -2 / -3 on collision; (4) reports the saved absolute path.
Why
The skill body is the whole deliverable — everything else is registration and docs. One SKILL.md matches how every other social-media-tools skill is structured.
Verify
head -6 SKILL.md shows valid YAML frontmatter with a three-part description ≤200 chars; the body names the ${CLAUDE_PLUGIN_ROOT}/artifacts destination, the copy step, and the unset-variable guard.
2
done Bump the social-media-tools version in .claude-plugin/marketplace.json from 2.13.0 to 2.15.0 (originally planned as 2.14.0; main took 2.14.0 for export-session while this plan was in flight) (skills auto-discover, so no plugin.json edit; do not add a version field to plugin.json ).
Why
Relative-path plugins take their version only from marketplace.json , and a new skill is a MINOR bump per the repo's semver rule.
Verify
python3 -c "import json;print([p['version'] for p in json.load(open('.claude-plugin/marketplace.json'))['plugins'] if p['name']=='social-media-tools'])" prints ['2.15.0'] ; settings.json marketplace-JSON validation passes.
3
done Add a ## v2.15.0 — 2026-07-02 — save-artifact entry to kit/plugins/social-media-tools/CHANGELOG.md and a save-artifact bullet to the ### Skills list in kit/plugins/social-media-tools/README.md .
Why
The repo requires docs and changelog updates alongside any plugin change, and the README skills list is how users discover the skill.
Verify
grep -c save-artifact kit/plugins/social-media-tools/CHANGELOG.md kit/plugins/social-media-tools/README.md returns ≥1 for both; the CHANGELOG's top entry is v2.15.0 .

Tests

The tests that prove the change does what it promises.

Tier 2 — Non-code plan
Objective save-artifact drops an HTML page into the plugin artifacts dir File: tests/plugins/test-save-artifact.sh Type: smoke test (bash, matching the repo's tests/plugins/test-*.sh convention) Asserts: given a sample artifact HTML and a temp CLAUDE_PLUGIN_ROOT , the copy step lands a dated copy under $CLAUDE_PLUGIN_ROOT/artifacts/ and prints its path; with CLAUDE_PLUGIN_ROOT unset it exits non-zero and writes nothing. Run: bash tests/plugins/test-save-artifact.sh

Definition of done

The plan counts as done when every statement below is true — check each one off as you verify it.

Final check

One last pass to confirm the whole change works end to end.

Load the plugin locally with claude --plugin-dir ./kit/plugins/social-media-tools , generate or open a sample HTML artifact, then invoke /social-media-tools:save-artifact <path> . Confirm a dated copy appears under the resolved ${CLAUDE_PLUGIN_ROOT}/artifacts/ directory and the reported absolute path matches. Re-run with CLAUDE_PLUGIN_ROOT unset and confirm the skill errors without writing. Finally run bash tests/plugins/test-save-artifact.sh and confirm it exits 0.

Wrapping up

Three gates that must all pass before this plan is marked completed.

Required

Completion Report

No items to report — all requirements met.

Next steps

Follow-up ideas that came up along the way — none of them are required to finish this plan.

Add a share-artifact companion that generates a social card for a saved artifact

Paste this prompt into Claude to execute this follow-up:

Add a `share-artifact` skill to kit/plugins/social-media-tools that takes a saved artifact HTML (from ${CLAUDE_PLUGIN_ROOT}/artifacts, produced by save-artifact) and generates a dark-mode social card previewing it, reusing the existing card-generation pipeline (templates/ + Playwright screenshot) that share-code and share-blog already use. Bump the plugin version and update the CHANGELOG and README.
Build an artifact gallery over the artifacts directory Wish List

Speculative / blue-sky idea — not on the critical path. Paste into Claude when ready to explore:

Paste this prompt into Claude to execute this follow-up:

Add an `artifact-library` skill to kit/plugins/social-media-tools, modeled on the existing media-library skill, that scans ${CLAUDE_PLUGIN_ROOT}/artifacts for saved *.html artifacts and builds a filterable HTML index page linking to each one, then opens it in the browser. Handle the empty-directory case gracefully and note that the cache location is non-durable.