在 ProtoHub 上管理原型。当用户想要上传目录或 ZIP 文件作为原型、更新现有原型、列出原型或获取预览链接时,请使用此技能。它支持自动打包文件夹、强制校验入口文件 (index.html),以及按名称搜索原型以便更新。
This skill allows AI Agents to manage prototypes on ProtoHub. It provides automated tools for packaging, publishing, and discovering prototypes (folders or ZIP files) in the ProtoHub Private Sandbox.
index.html before uploading.Before performing any action, the AI Agent MUST verify that the following environment variables are set:
PROTOHUB_API_KEY: Required for authentication.PROTOHUB_URL: Base URL of the ProtoHub server (default: http://localhost:48080).Strict Validation Rule: If either of these is missing from the environment and has not been provided by the user in the current session, the Agent MUST NOT attempt to run the script and MUST NOT retry with placeholder values. Instead, immediately ask the user to provide the missing configuration.
export PROTOHUB_API_KEY="your-api-key"
export PROTOHUB_URL="http://localhost:48080"
python skills/tc-protohub/scripts/publish.py publish ./my-dist-folder --name "My Prototype Name"
Overwrites content while maintaining the same ID and URL.
python skills/tc-protohub/scripts/publish.py publish ./my-dist-folder --id 1024
Useful for finding the ID when the user says "Update the 'Login Page' prototype".
python skills/tc-protohub/scripts/publish.py list --name "Login Page"
python skills/tc-protohub/scripts/publish.py get-link 1024
index.html is at the root of your directory or ZIP file.publish.py list --name "..." to find a matching prototype first.http://localhost:48080. Override using the PROTOHUB_URL env var or --url flag.401 Unauthorized: API Key is missing or invalid.404 Not Found: The specified prototypeId does not exist.Missing index.html: The script will abort the upload to prevent broken previews.ZIP package — ready to use