Agent Native

context7-cli

This skill provides a CLI tool to fetch current library documentation from Context7 and configure Context7 MCP for AI coding editors.

by upstashCommunityNot reviewed

Community author

Agents
Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode, claude.ai and API
License
MIT (permissive)
Pin
feef1b2pinned Oct 9, 2026
Context cost
about 440 tokenswhen the skill loads
GitHub stars
62,806on upstash/context7
Scripts
None found

What it does

“Use the ctx7 CLI to fetch library documentation and configure Context7 MCP. Activate when the user mentions "ctx7" or "context7", needs current docs for any library, or needs to set up Context7 for their AI coding agent.”
The author's description, from SKILL.md

Generated summary from the skill's own text

This skill provides a CLI tool to fetch current library documentation from Context7 and configure Context7 MCP for AI coding editors. It helps agents access up-to-date API references and set up integration with Claude Code, Cursor, or OpenCode.

When to use it

  • User mentions ctx7 or Context7 setup needs
  • Need current library documentation for any package
  • Verifying API signatures or library behavior
  • Setting up Context7 MCP in editor environment

When not to

  • User has offline or cached documentation available
  • Not setting up AI coding agent integration
  • Library documentation already verified and current

Install

These commands install from the publisher's repository and need no account.

skills CLI

npx skills add upstash/context7 --skill context7-cli

Installs from the repository's default branch, which may have changed since the commit we checked.

GitHub CLI 2.90 or later

gh skill install upstash/context7 context7-cli@feef1b2f6078ac8a33acd38d76817000af001373

Installs the commit we checked (feef1b2).

Copy by hand

Download the folder at feef1b2 and put it in .claude/skills/context7-cli for Claude Code and in .agents/skills/context7-cli for Codex, Cursor, Gemini CLI, GitHub Copilot and OpenCode.

Skill folder on GitHub at feef1b2

Copy for your agent

A prompt for any coding agent. It installs this skill from GitHub at the pinned commit, copies the files as they are, and runs nothing unless you ask.

Prompt

Install the agent skill "context7-cli" by upstash.

Source, pinned to commit feef1b2f6078ac8a33acd38d76817000af001373:
https://github.com/upstash/context7/tree/feef1b2f6078ac8a33acd38d76817000af001373/skills/context7-cli

1. Download that folder at exactly this commit. Do not use the default branch.
2. Copy every file unchanged, keeping the folder structure, into .claude/skills/context7-cli/ for Claude Code and .agents/skills/context7-cli/ for Codex, Cursor, Gemini CLI, GitHub Copilot and OpenCode. Create the folders if they do not exist.
3. Do not edit the files, and do not run any script in the folder unless I ask you to.
4. When you are done, list the files you copied and where you put them.

Listing and checks: https://www.agentnative.dev/skills/upstash/context7-cli

SKILL.md at the pin

---
name: context7-cli
description: Use the ctx7 CLI to fetch library documentation and configure Context7 MCP. Activate when the user mentions "ctx7" or "context7", needs current docs for any library, or needs to set up Context7 for their AI coding agent.
---

# ctx7 CLI

The Context7 CLI does two things: fetches up-to-date library documentation and sets up Context7 MCP for your editor.

Make sure the CLI is up to date before running commands:

```bash
npm install -g ctx7@latest
```

Or run directly without installing:

```bash
npx ctx7@latest <command>
```

## What this skill covers

- **[Documentation](references/docs.md)** — Fetch current docs for any library. Use when writing code, verifying API signatures, or when training data may be outdated.
- **[Setup](references/setup.md)** — Configure Context7 MCP for Claude Code / Cursor / OpenCode.

## Quick Reference

```bash
# Documentation
ctx7 library <name> <query>           # Step 1: resolve library ID
ctx7 docs <libraryId> <query>         # Step 2: fetch docs

# Setup
ctx7 setup                            # Configure Context7 MCP (interactive)
ctx7 login                            # Log in for higher rate limits
ctx7 whoami                           # Check current login status
```

## Authentication

```bash
ctx7 login               # Opens browser for OAuth
ctx7 login --no-browser  # Prints URL instead of opening browser
ctx7 logout              # Clear stored tokens
ctx7 whoami              # Show current login status (name + email)
```

Most commands work without login. Exception: `ctx7 setup` requires it unless `--api-key` or `--oauth` is passed. Login also unlocks higher rate limits on docs commands.

Set an API key via environment variable to skip interactive login entirely:

```bash
export CONTEXT7_API_KEY=your_key
```

## Common Mistakes

- Library IDs require a `/` prefix — `/facebook/react` not `facebook/react`
- Always run `ctx7 library` first — `ctx7 docs react "hooks"` will fail without a valid ID

From upstash/context7 at feef1b2, shown as plain text under its license: MIT (permissive). The license text is in LICENSE.

View SKILL.md on GitHub at feef1b2

Files

3 files, 9.6 KB in total. Each file has a sha256 in the pin's manifest; the first 12 characters are shown.

Skill folder on GitHub at feef1b2
All 2 skills from upstash

More from upstash

  • upstash-ratelimit-js

    This skill adds rate limiting to serverless and edge applications using the Upstash Rate Limit TypeScript SDK backed by Upstash Redis.

    Claude Code, Codex, Cursor +4 · about 250 tokens · pinned 6 days ago

All AI and agents skills
  • -21risk-automation

    This skill automates 21risk operations by connecting to the 21risk toolkit through Composio's Rube MCP server.

    by ComposioOfficial publisher

    Claude Code, Codex, Cursor +3 · about 690 tokens · pinned 6 days ago

  • -2chat-automation

    This skill automates 2chat tasks by integrating with Composio's 2chat toolkit through Rube MCP.

    by ComposioOfficial publisher

    Agents not labelled yet · about 680 tokens · pinned 6 days ago

  • ably-automation

    This skill automates Ably messaging platform tasks by connecting to Composio's Ably toolkit through Rube MCP.

    by ComposioOfficial publisher

    Agents not labelled yet · about 680 tokens · pinned 6 days ago

  • abstract-automation

    This skill enables agents to automate Abstract design platform operations through Composio's Abstract toolkit via Rube MCP.

    by ComposioOfficial publisher

    Claude Code, Codex, Cursor +3 · about 690 tokens · pinned 6 days ago

  • abuselpdb-automation

    This skill automates Abuselpdb operations through Composio's toolkit via Rube MCP, enabling the agent to search for IP/domain abuse reports and manage threat…

    by ComposioOfficial publisher

    Agents not labelled yet · about 700 tokens · pinned 6 days ago

  • abyssale-automation

    This skill enables agents to automate Abyssale tasks through Composio's toolkit via Rube MCP.

    by ComposioOfficial publisher

    Claude Code, Codex, Cursor +3 · about 690 tokens · pinned 6 days ago

The skills listed here are third-party software, collected from public GitHub repositories as a catalog of recent skills and provided as is. Agent Native does not write or control them and is not responsible for any harm, loss or damage caused by installing or using them. Labels and checks describe what we saw at one commit and are not a guarantee. Read a skill's files before you run it. Terms of use