From paxdev
Look up Rust crate information, versions, dependencies, and documentation from crates.io and docs.rs. Use this skill whenever the user asks about a Rust crate, wants to check crate versions, find documentation, compare crate features, look up dependencies, or needs help choosing between crates. Trigger on: crate names, "cargo add", "what version of X", "docs for X", "how to use X in Rust", dependency questions, feature flags, or any Rust ecosystem lookup. Even if the user just mentions a crate name in passing and seems unsure about it, use this skill to pull real data.
npx claudepluginhub paxsonsa/myskillz --plugin paxdevThis skill uses the workspace's default tool permissions.
You have access to the crates.io REST API and docs.rs URL patterns to look up real-time
Creates isolated Git worktrees for feature branches with prioritized directory selection, gitignore safety checks, auto project setup for Node/Python/Rust/Go, and baseline verification.
Executes implementation plans in current session by dispatching fresh subagents per independent task, with two-stage reviews: spec compliance then code quality.
Dispatches parallel agents to independently tackle 2+ tasks like separate test failures or subsystems without shared state or dependencies.
You have access to the crates.io REST API and docs.rs URL patterns to look up real-time information about Rust crates. Use these to give accurate, current answers instead of relying on training data which may be outdated.
Base URL: https://crates.io/api/v1
All requests MUST include a User-Agent header. Use:
User-Agent: claude-rust-docs-skill (https://github.com/apaxson)
curl -s -H "User-Agent: claude-rust-docs-skill" \
"https://crates.io/api/v1/crates/{crate_name}"
Returns:
.crate.description — what it does.crate.max_version / .crate.max_stable_version — latest version.crate.downloads / .crate.recent_downloads — popularity signal.crate.repository — source code link.crate.documentation — docs link (if set by author).crate.homepage — project homepage.crate.keywords / .crate.categories — classification.versions[] — array of all published versions with:
.num — semver string.features — feature flags available.rust_version — MSRV.license — SPDX license.yanked — whether this version was yanked.crate_size — size in bytes.created_at — publish datecurl -s -H "User-Agent: claude-rust-docs-skill" \
"https://crates.io/api/v1/crates?q={search_term}&per_page=10"
Returns .crates[] array with same metadata fields, plus:
.meta.total — total result count.meta.next_page — paginationcurl -s -H "User-Agent: claude-rust-docs-skill" \
"https://crates.io/api/v1/crates/{crate_name}/{version}/dependencies"
Returns .dependencies[] with:
.crate_id — dependency name.req — version requirement string.kind — "normal", "dev", or "build".optional — whether it's behind a feature flag.default_features — whether default features are enabled.features[] — which features are activatedcurl -s -H "User-Agent: claude-rust-docs-skill" \
"https://crates.io/api/v1/crates/{crate_name}/owners"
curl -s -H "User-Agent: claude-rust-docs-skill" \
"https://crates.io/api/v1/crates/{crate_name}/reverse_dependencies?per_page=10"
docs.rs hosts auto-generated rustdoc for every crate published to crates.io.
| URL Pattern | What it shows |
|---|---|
https://docs.rs/{crate} | Latest version docs |
https://docs.rs/{crate}/{version} | Specific version docs |
https://docs.rs/{crate}/latest/{crate}/ | Module root |
https://docs.rs/{crate}/latest/{crate}/{module}/ | Submodule |
https://docs.rs/{crate}/latest/{crate}/struct.{Name}.html | Struct docs |
https://docs.rs/{crate}/latest/{crate}/trait.{Name}.html | Trait docs |
https://docs.rs/{crate}/latest/{crate}/fn.{Name}.html | Function docs |
https://docs.rs/{crate}/latest/{crate}/enum.{Name}.html | Enum docs |
https://docs.rs/crate/{crate}/latest | Crate info page (versions, features, etc.) |
https://docs.rs/crate/{crate}/latest/source/ | Source browser |
Semver ranges work: https://docs.rs/{crate}/~1.0 redirects to latest 1.x.
Note: For crates with hyphens in the name, the module path uses underscores.
Example: https://docs.rs/my-crate/latest/my_crate/ (hyphen in crate name, underscore in module path).
| Resource | URL |
|---|---|
| std library | https://doc.rust-lang.org/std/ |
| Cargo book | https://doc.rust-lang.org/cargo/ |
| Rust reference | https://doc.rust-lang.org/reference/ |
| Rustonomicon | https://doc.rust-lang.org/nomicon/ |
| Edition guide | https://doc.rust-lang.org/edition-guide/ |
| Cargo.toml reference | https://doc.rust-lang.org/cargo/reference/manifest.html |
.crate.max_stable_version (prefer stable over pre-release)cargo add command: cargo add {crate}@{version}https://docs.rs/{crate}/{version}.features objectdefaultFor complex lookups, use the helper script at:
skills/rust-docs/scripts/crate_lookup.sh
Usage:
# Basic crate info
bash skills/rust-docs/scripts/crate_lookup.sh info serde
# Search
bash skills/rust-docs/scripts/crate_lookup.sh search "http client"
# Dependencies for a specific version
bash skills/rust-docs/scripts/crate_lookup.sh deps tokio 1.35.0
# Latest versions (shows last 10)
bash skills/rust-docs/scripts/crate_lookup.sh versions serde
# Reverse deps (who uses this crate)
bash skills/rust-docs/scripts/crate_lookup.sh rdeps serde
When presenting crate information, use this structure:
**{crate_name}** v{version} — {description}
License: {license} | Downloads: {downloads} | Updated: {date}
Repo: {repository_url}
Docs: https://docs.rs/{crate_name}/{version}
`cargo add {crate_name}`
For search results, present as a compact comparison:
| Crate | Version | Downloads | Description |
|-------|---------|-----------|-------------|
| ... | ... | ... | ... |
crates.io asks that automated clients limit to 1 request per second. The helper script includes a small delay between requests. When making multiple API calls manually, space them out. For most user questions, 1-3 API calls is sufficient.