tapcanvas-api

tapcanvas-api is a skill for Claude Code, Codex from anymouschina/TapCanvas. It costs 104 tokens per session (1,766 once invoked), scanned A, original, MIT.

A single setup and command-line entry point for calling TapCanvas's public chat, drawing, image-understanding, video, task-result, and flow APIs.

In plain words
What is it for?
Use it when an agent needs to send requests to TapCanvas's public API, using one configured server address and API key.
Why use it?
It prevents different tools from using conflicting API settings or silently switching to another endpoint. Missing connection details cause an explicit failure.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when an agent needs to send requests to TapCanvas's public API, using one configured server address and API key.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/anymouschina/tapcanvas/tapcanvas-api
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add anymouschina/TapCanvas --skill tapcanvas-api
Clone the repo
git clone --depth 1 https://github.com/anymouschina/TapCanvas

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for tapcanvas-api

README.md
[![agentmods](https://agentmods.dev/badge/skills/anymouschina/tapcanvas/tapcanvas-api.svg)](https://agentmods.dev/skills/anymouschina/tapcanvas/tapcanvas-api)
Your own site
<a href="https://agentmods.dev/skills/anymouschina/tapcanvas/tapcanvas-api"><img src="https://agentmods.dev/badge/skills/anymouschina/tapcanvas/tapcanvas-api.svg" alt="Measured on agentmods" height="20"></a>
Per session 104 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,766 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00104 $0.01766
Opus 5 $0.00052 $0.00883
Sonnet 5 $0.00021 $0.00353
Haiku 4.5 $0.00010 $0.00177

Measured 4d ago against content hash 3977b38e0893, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

tapcanvas-api scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

The scan reads SKILL.md. This mod also ships 4 executable files (scripts/call.mjs, scripts/internal-media-recovery-tick.mjs, scripts/profile-config.mjs, …), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

apps/agents-cli/skills/tapcanvas-api/SKILL.md · 205 lines

How it starts

The opening of the file, as written. The whole thing — 205 lines — stays where its author put it; the contents beside it link to each section on GitHub.

TapCanvas API

这是 TapCanvas 项目对外 API 的唯一 skill。

目标:

  • 为 TapCanvas 项目的公共接口提供唯一调用入口。
  • 用一个统一配置文件管理 apiBaseUrlapiKey
  • 明确失败,不做静默降级、不猜测默认接口、不切换到旧 skill。

唯一路径

涉及以下任一场景时,只能使用本 skill:

  • 调用 /public/agents/chat
  • 调用 /public/agents/tools/execute 读取或执行当前 Agents 工具面
  • 调用 /public/draw
  • 调用 /public/vision
  • 调用 /public/video
  • 调用 /public/tasks/result
  • 调用 /public/flows 相关接口

禁止:

  • 再使用分散的 TapCanvas API skill
  • 在不同 skill 里各自维护一套 apiKey / apiBaseUrl
  • 未经确认地改用其他 endpoint 或本地伪造结果

配置

必须读取同目录下的 config.json

{
  "apiBaseUrl": "http://localhost:8788",
  "apiKey": "tc_sk_xxx"
}

字段说明:

  • apiBaseUrl: TapCanvas API 域名或本地开发地址,不带尾部斜杠更清晰
  • apiKey: 当前用户生成的 API Key

本地开发实例若已由 Hono 显式启用 TAPCANVAS_DEV_PUBLIC_BYPASS,诊断时可以额外传 --devBypassToken <token>。调用器只在该参数明确出现时发送 x-tap-dev-bypass,并且不会 同时发送 Bearer,以复现浏览器 HttpOnly 会话委托链;生产调用、普通 API Key 调用和 config.json 不会自动启用或保存 bypass。本地 Hono 未显式启用该 token 时请求会原地失败。

诊断已登录浏览器会话时,可以显式传 --sessionCookie <cookie>,或仅在当前进程设置 TAPCANVAS_SESSION_COOKIE;同时必须显式传 --origin <origin> 或设置 TAPCANVAS_SESSION_ORIGIN,以满足浏览器会话的 CSRF 来源校验。调用器只把这些值用于 本次请求,既不写入 config.json,也不与 Bearer 或 dev bypass 同时发送。会话或来源 无效时必须原样返回 401/403。

优先级:

  1. 脚本参数显式传入
  2. config.json
  3. 环境变量 TAPCANVAS_API_BASE_URL / TAPCANVAS_API_KEY

鉴权方式互斥优先级:显式 dev bypass > 显式会话 Cookie > API Key。

如果最终缺少 apiBaseUrlapiKey,必须直接失败。

执行方式

统一使用脚本:

node apps/agents-cli/skills/tapcanvas-api/scripts/call.mjs \
  --endpoint chat \
  --payload '{"vendor":"auto","prompt":"你好"}'

也支持 payload 文件:

node apps/agents-cli/skills/tapcanvas-api/scripts/call.mjs \
  --endpoint draw \
  --payloadFile /abs/path/request.json

本地开发诊断示例:

node apps/agents-cli/skills/tapcanvas-api/scripts/call.mjs \
  --endpoint chat \
  --apiBaseUrl http://127.0.0.1:8788 \
  --devBypassToken '<explicit-local-secret>' \
  --payload '{"prompt":"你好","stream":true}'

Endpoint 规则

可用 endpoint:

  • chat -> POST /public/agents/chat
  • agentTool -> POST /public/agents/tools/execute
  • draw -> POST /public/draw
  • vision -> POST /public/vision
  • video -> POST /public/video
  • taskResult -> POST /public/tasks/result
  • flows -> GET /public/projects/:projectId/flows
  • flowGet -> GET /public/flows/:id
  • flowPatch -> POST /public/flows/:id/patch

Read the full file on GitHub · 205 lines

Files

What ships with it

5 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago Changed · +25 lines 3977b38e0893
  2. 8d ago First seen · 180 lines · 104 tokens per session scan A f9734893c00b

Subscribe to this mod's changes

tapcanvas-api is a skill published in the GitHub repository anymouschina/TapCanvas (600 stars, last pushed 2d ago), licensed MIT. It adds 104 tokens to every session and 1,766 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories