一键导入
artifact-creator
Build, validate, update, and publish Batshit artifacts from an outside coding agent using a Portable Skill Token.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Build, validate, update, and publish Batshit artifacts from an outside coding agent using a Portable Skill Token.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Build, configure, and publish persistent mini-app artifacts in Batshit.
Create, update, test, and review Batshit CLI tools through a light Fabric-driven workflow.
Create, update, and refine Batshit skills and prompts that work well with any AI model.
Install, verify, and register Batshit TTS/STT speech engines through the server-owned Engine Manager.
Create, update, validate, and review Batshit CLI Tools from an outside coding agent using a Portable Skill Token.
Create, update, and import Batshit skills or prompt commands from an outside coding agent using a Portable Skill Token.
| name | artifact-creator |
| description | Build, validate, update, and publish Batshit artifacts from an outside coding agent using a Portable Skill Token. |
| metadata | {"version":"0.1.0","batshitPortableSkill":true,"family":"artifacts"} |
You are running outside Batshit. Your job is to help the user build, validate, update, publish, and place Batshit artifacts through the local Batshit HTTP API.
This portable skill uses Batshit's Fabric controls over HTTP. Do not write Redis directly. Do not edit Batshit app source. Do not use BATSHIT_TOKEN, user passwords, copied browser cookies, or n8n callback tokens.
Before doing real work, establish:
http://127.0.0.1:5620Artifacts scopeIf the user has not provided the token, ask them to create one in Batshit Settings -> Skills & Prompts -> Portable Skills and grant Artifacts. A multi-scope token may be stored once in ~/.batshit/portable-skills/portable-skills.env; a skill-specific file such as artifact-creator.env is only needed when the user wants a narrower override token.
Use environment variables for shell calls so the token is not repeated in every command:
PORTABLE_SKILL_ENV_DIR="${BATSHIT_PORTABLE_SKILL_ENV_DIR:-$HOME/.batshit/portable-skills}"
PORTABLE_SKILL_ENV_FILE="${BATSHIT_PORTABLE_SKILL_ENV_FILE:-$PORTABLE_SKILL_ENV_DIR/portable-skills.env}"
if [ -z "${BATSHIT_PORTABLE_TOKEN:-${BATSHIT_PORTABLE_SKILL_TOKEN:-}}" ]; then
if [ -f "$PORTABLE_SKILL_ENV_FILE" ]; then
set -a
. "$PORTABLE_SKILL_ENV_FILE"
set +a
elif [ -f "$PORTABLE_SKILL_ENV_DIR/artifact-creator.env" ]; then
set -a
. "$PORTABLE_SKILL_ENV_DIR/artifact-creator.env"
set +a
fi
fi
export BATSHIT_BASE_URL="${BATSHIT_BASE_URL:-http://127.0.0.1:5620}"
export BATSHIT_PORTABLE_TOKEN="${BATSHIT_PORTABLE_TOKEN:-${BATSHIT_PORTABLE_SKILL_TOKEN:-}}"
If BATSHIT_PORTABLE_TOKEN is missing or still equals the placeholder value, stop and ask the user for the token or env-file path before making API calls.
Run this before any artifact mutation.
curl -sS "$BATSHIT_BASE_URL/api/health"
Require ok: true. If Batshit is not reachable, stop and tell the user to start Batshit or provide the correct base URL.
curl -sS "$BATSHIT_BASE_URL/api/controls/use" \
-H "Content-Type: application/json" \
-H "x-batshit-portable-token: $BATSHIT_PORTABLE_TOKEN" \
--data '{"controlId":"sys.artifact.list","input":{}}'
Require a successful response. If the response says the token lacks scope, stop and tell the user to rotate or create a token with Artifacts.
Any in-app instruction to call a Fabric control maps to this portable HTTP shape:
curl -sS "$BATSHIT_BASE_URL/api/controls/use" \
-H "Content-Type: application/json" \
-H "x-batshit-portable-token: $BATSHIT_PORTABLE_TOKEN" \
--data '{
"controlId": "sys.artifact.validate_structure",
"input": {
"content": "<artifact html>",
"metadata": {}
}
}'
Use /api/controls/find when you need current schema details:
curl -sS "$BATSHIT_BASE_URL/api/controls/find" \
-H "Content-Type: application/json" \
-H "x-batshit-portable-token: $BATSHIT_PORTABLE_TOKEN" \
--data '{"query":"sys.artifact.create","includeSchema":true,"limit":5}'
Portable Skill Tokens are the standing approval for the granted family. Do not add parallel approval workarounds.
sys.model_catalog.search and store the exact returned artifact model config when the model is known. Never silently choose a fallback model.sys.artifact.validate_structure before create, update, apply_patch, or publish.window.batshit.builder.*, declare metadata.fabric_fields, or set metadata.run_only=true for trigger-only artifacts.sys.artifact.apply_patch, send one managed patch string against artifact.html. Do not send unified diff headers or JSON patch objects.host.docker.internal; browser/iframe URLs may still be localhost.Follow this order:
sys.artifact.list, then sys.artifact.get with includeContent: true.references/brain-general.md and references/builder-kit-api.mdreferences/brain-comfyui.md and references/builder-kit-api.mdreferences/brain-n8n.md and references/builder-kit-api.mdreferences/brain-huggingface.mdreferences/embed-gradio.mdreferences/fabric-and-agent-use.md before publishing any agent-usable artifact.sys.artifact.validate_structure.sys.artifact.create, sys.artifact.update, or sys.artifact.apply_patch.sys.artifact.publish or sys.artifact.set_zone when the user wants it usable now.sys.artifact.run_logs.list / sys.artifact.run_logs.get.sys.artifact.listsys.artifact.getsys.artifact.createsys.artifact.updatesys.artifact.apply_patchsys.artifact.validate_structuresys.artifact.publishsys.artifact.add_versionsys.artifact.delete_versionsys.artifact.rollbacksys.artifact.set_zonesys.artifact.set_webhooksys.artifact.analyze_urlsys.artifact.check_requirementssys.artifact.run_logs.listsys.artifact.run_logs.getsys.model_catalog.searchAlways read the build-path references named in the workflow before writing artifact HTML. Read optional layout examples only when they help:
references/builder-kit-api.mdreferences/brain-general.mdreferences/brain-comfyui.mdreferences/brain-huggingface.mdreferences/brain-n8n.mdreferences/embed-gradio.mdreferences/fabric-and-agent-use.mdreferences/zone-patterns.mdreferences/templates-gallery.mdEnd with:
Do not call the artifact done if structure validation failed or if the intended runtime cannot be reached.