add-tauri-command

add-tauri-command is a skill for Claude Code from kevinlin/cowork-z. It costs 69 tokens per session (986 once invoked), scanned A, original, MIT.

Instructions for adding a Tauri command, which lets a React user interface call backend Rust code in a desktop app.

In plain words
What is it for?
Use it when adding or repairing a Cowork-Z backend command, including its Rust function, registration, and typed frontend wrapper.
Why use it?
A command must be registered in several places; missing one can make it fail at runtime even when the code builds.

Skill for Claude Code

Written for Claude Code: disable-model-invocation in frontmatter.

Good fit Use it when adding or repairing a Cowork-Z backend command, including its Rust function, registration, and typed frontend wrapper.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/kevinlin/cowork-z/add-tauri-command
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 kevinlin/cowork-z --skill add-tauri-command
Clone the repo
git clone --depth 1 https://github.com/kevinlin/cowork-z

Made for: Claude Code.

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 add-tauri-command

README.md
[![agentmods](https://agentmods.dev/badge/skills/kevinlin/cowork-z/add-tauri-command/github.svg)](https://agentmods.dev/skills/kevinlin/cowork-z/add-tauri-command)
Your own site
<a href="https://agentmods.dev/skills/kevinlin/cowork-z/add-tauri-command"><img src="https://agentmods.dev/badge/skills/kevinlin/cowork-z/add-tauri-command/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for add-tauri-command

Your own site · 80×15
<a href="https://agentmods.dev/skills/kevinlin/cowork-z/add-tauri-command"><img src="https://agentmods.dev/badge/skills/kevinlin/cowork-z/add-tauri-command.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 69 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 986 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.00069 $0.00986
Opus 5.5 $0.00028 $0.00394
Sonnet 5.5 $0.00014 $0.00197
Haiku 4.5 $0.00007 $0.00099

Measured 1mo ago against content hash c31de6177fbe, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

add-tauri-command 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 1mo ago.

The scan reads SKILL.md. This mod also ships 1 executable file (templates/wrapper.ts), 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.

.claude/skills/add-tauri-command/SKILL.md · 80 lines

How it starts

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

Add a Tauri Command

A command is not usable until it exists in four places. Miss one and it fails at runtime, not at build time — generate_handler! takes any path that compiles, and invoke() takes any string.

The four edits

Order File Edit
1 src-tauri/src/commands/<domain>.rs the #[tauri::command] fn
2 src-tauri/src/commands/mod.rs pub mod <domain>; — only when the file is new
3 src-tauri/src/lib.rs one line in tauri::generate_handler![], under the matching // Domain comment
4 src/lib/tauri-api.ts the typed invoke() wrapper

Pick an existing domain file before creating one. There are 22; a new domain is rare.

Step 1 — the command

Copy templates/command.rs. Two shapes: plain, and path-taking.

Any command that accepts a caller-supplied path MUST go through path_guard. The renderer is untrusted — an agent will pass whatever path its model produced. Model it on the validate_path helper at the top of src-tauri/src/commands/files.rs, and validate before any fs:: call, never after.

Return Result<T, String>. T must be Serialize; shared shapes live in src-tauri/src/types.rs.

Step 2 — register

lib.rs groups the handler list by domain with // comments. Add the line to its group, not the end of the list.

Step 3 — the frontend wrapper

Copy templates/wrapper.ts.

Argument names cross the bridge as camelCase in TS, snake_case in Rust — Tauri converts them. invoke('add_workspace', { folderPath }) binds to folder_path: String. Get this wrong and the argument silently arrives empty.

The function name is camelCase; the invoke string is the exact Rust fn name.

New return types go in src/shared/ and must mirror the Rust struct's serde casing (rename_all = "camelCase" on the Rust side).

Step 4 — verify

cd src-tauri && cargo check     # Rust compiles
pnpm typecheck                  # TS compiles

Read the full file on GitHub · 80 lines

Files

What ships with it

2 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. 1mo ago First seen · 80 lines · 69 tokens per session scan A c31de6177fbe

Subscribe to this mod's changes

add-tauri-command is a skill published in the GitHub repository kevinlin/cowork-z (13 stars, last pushed 10d ago), licensed MIT. It adds 69 tokens to every session and 986 once invoked, about $0.0003 per session on Opus 5.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

claude-api

Build apps with the Claude API or Anthropic SDK. TRIGGER when: code imports anthropic/@anthropic-ai/sdk/claudeagentsdk, or user asks to use Claude API, Anthropic SDKs, or Agent SDK. DO NOT TRIGGER when: code imports openai/other AI SDK, general programming, or ML/data-science tasks.

PM-Shawn/Abu-Cowork · 84 tokens

mcp-builder

Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node/TypeScript (MCP SDK).

PM-Shawn/Abu-Cowork · 61 tokens

web-artifacts-builder

Suite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web technologies (React, Tailwind CSS, shadcn/ui). Use for complex artifacts requiring state management, routing, or shadcn/ui components - not for simple single-file HTML/JSX artifacts.

PM-Shawn/Abu-Cowork · 64 tokens

前端代码审查

A review checklist for browser-based front-end and React code. It covers security, accessibility, speed, React correctness, maintainability, and Forsion’s no-build environment rules.

Changan-Su/Forsion · 175 tokens

React 组件与状态模式

A collection of patterns for building React components, hooks, and state management, where state means the data that controls what a page shows.

Changan-Su/Forsion · 128 tokens

Forsion Connect AI SDK

Build web pages/apps that call Forsion's AI (LLM chat, server-managed agent conversations with web search, image generation) using the signed-in Forsion account — one script tag, no API keys. Use this whenever the user wants a website or HTML page with any AI feature (smart import/parsing, chatbot/assistant, AI…

Changan-Su/Forsion · 168 tokens