# Add the Best Skill (OPCAIOS) MCP server (instructions for AI agents)

Best Skill (https://skill.opcaios.org) is a library of AI skills. Its MCP server lets you search, compare and install skills for the user.
A user will say something like: "Read https://skill.opcaios.org/install/mcp.md and follow it to add the MCP." Do the steps below.

- Server URL: `https://skill.opcaios.org/mcp` (Streamable HTTP, JSON-RPC 2.0, stateless; no SSE, no sessions)
- Name to use: `opcaios-skill`
- Read-only public tools need no authentication. Members-only skills need `Authorization: Bearer <token>` (see "Members skills").
- Syntax below follows each client's official documentation as checked on 2026-11-09; it was not executed on every client. If a command is rejected, read the client's MCP documentation and adapt.

## 1. Add the server (pick the client you are running in)

Claude Code:
```bash
claude mcp add --transport http opcaios-skill https://skill.opcaios.org/mcp
```
Docs: https://code.claude.com/docs/en/mcp

Codex:
```bash
codex mcp add opcaios-skill --url https://skill.opcaios.org/mcp
```
Docs: https://developers.openai.com/codex/mcp

Gemini CLI:
```bash
gemini mcp add --transport http opcaios-skill https://skill.opcaios.org/mcp
```
Docs: https://geminicli.com/docs/tools/mcp-server/

Cursor: add to `~/.cursor/mcp.json` (global) or `.cursor/mcp.json` (project), keeping existing servers:
```json
{ "mcpServers": { "opcaios-skill": { "url": "https://skill.opcaios.org/mcp" } } }
```
Docs: https://cursor.com/docs/mcp

VS Code: add to `.vscode/mcp.json` (top-level key is `servers`):
```json
{ "servers": { "opcaios-skill": { "type": "http", "url": "https://skill.opcaios.org/mcp" } } }
```
Docs: https://code.visualstudio.com/docs/agents/reference/mcp-configuration

Claude Desktop: Customize > Connectors > Add custom connector, URL `https://skill.opcaios.org/mcp`, no sign in. (The connection is made from Anthropic's cloud.)
Docs: https://support.claude.com/en/articles/11175166-get-started-with-custom-connectors-using-remote-mcp

Ask before editing the user's configuration files; do not remove existing servers. Restart or reload the client if it does not list the new server.

## 2. Check it works

Call the `list_filters` tool (no arguments); it returns the models, categories and counts. Then `search_skills` with the user's topic.

## 3. Tools

| Tool | Purpose |
| --- | --- |
| `search_skills` | `query?`, `output?`, `role?`, `use_case?`, `model?`, `access?` (free\|members), `agent?`, `limit` (max 20) |
| `get_skill` | `id`: summary, access, requirements/costs, version/rev, preview links, install guides |
| `compare_skills` | `ids`: 2 to 4 skill ids |
| `list_filters` | values and counts for the filters |
| `install_skill` | `id`, `agent` (claude-code, codex, cursor, gemini-cli, antigravity), `scope` (user, project): returns the exact files to write |
| `check_updates` | `installed`: `[{id, rev}]` using the `rev` from `install_skill` |
| `whoami` | login and membership status of the token (there is no daily quota) |
| `request_skill` | `text` (10-500 characters), `email?`: ask the team to add a skill (3 per hour) |

Skill ids are `<model>/<slug>` (community) or `opc/<slug>` (OPCAIOS originals).

## 4. Installing a skill

1. `search_skills` / `get_skill` to find the id; tell the user what it is and whether it is `free` or `members`.
2. Ask which agent and scope if unclear (default: personal folder, `scope: "user"`).
3. Call `install_skill`. The result has `files`: each has `path` (a leading `~` is the user's home folder), `encoding` (`utf8` or `base64`), `content`, `sha256`.
4. Create the folder, write every file, decode `base64` files first, and check each `sha256`. Do not overwrite an existing folder of the same name without asking the user.
5. Follow `instructions` in the result to reload the agent. Folders per agent (verified against official docs): Claude Code `~/.claude/skills` or `.claude/skills`; Codex `~/.agents/skills` or `.agents/skills`; Cursor `~/.cursor/skills` or `.cursor/skills`; Gemini CLI `~/.gemini/skills` or `.gemini/skills`; Antigravity `~/.gemini/config/skills` or `.agents/skills`.

## 5. Members skills

If `install_skill` returns `{"auth_required": true}` or `{"membership_required": true}`, the skill is VIP (members-only). Never try to fetch it any other way.
1. Tell the user to open https://skill.opcaios.org/connect (sign in with the OPCAIOS account) and create a token, or run the CLI: `curl -fsSL https://skill.opcaios.org/cli/opc-skill.mjs -o opc-skill.mjs && node opc-skill.mjs login`, then `node opc-skill.mjs token` prints it. Tokens last 7 days and can be revoked at /connect.
2. The user puts the token in the environment variable `OPC_SKILL_TOKEN` (never ask them to paste it into the chat) and the MCP entry gains the header `Authorization: Bearer ${OPC_SKILL_TOKEN}` in whatever form the client documents (for example `--header "Authorization: Bearer $OPC_SKILL_TOKEN"` for Claude Code and Gemini CLI; `bearer_token_env_var = "OPC_SKILL_TOKEN"` under `[mcp_servers.opcaios-skill]` for Codex; `"headers": {"Authorization": "Bearer ${env:OPC_SKILL_TOKEN}"}` for Cursor and VS Code).
3. Membership status is refreshed whenever the user opens /connect while signed in. After renewing a membership, ask the user to open it once.

## 6. Alternative: command line

`node opc-skill.mjs search "<topic>"`, `show <id>`, `install <id> --agent <agent> [--global|--project] [--force]`, `update`, `login`, `whoami`, `request "<text>"`; add `--json` for machine-readable output. Exit codes: 0 ok, 1 error or conflict, 2 login required, 3 active membership required.

## Privacy

No tracking cookies. IP addresses are not stored (only a daily-rotating HMAC of IP and user agent, deleted after two days). Server logs contain no IPs, tokens or request text. Details: https://skill.opcaios.org/mcp
