You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+20-11Lines changed: 20 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -36,7 +36,7 @@ Context7 fetches up-to-date code examples and documentation right into your LLM'
36
36
- 2️⃣ Tell the LLM to `use context7`
37
37
- 3️⃣ Get working code answers
38
38
39
-
No tab-switching, no hallucinated APIs that don't exist, no outdated code generations.
39
+
No tab-switching, no hallucinated APIs that don't exist, no outdated code generation.
40
40
41
41
## 📚 Adding Projects
42
42
@@ -386,7 +386,7 @@ Open Claude Desktop developer settings and edit your `claude_desktop_config.json
386
386
<details>
387
387
<summary><b>Install in Opencode</b></summary>
388
388
389
-
Add this to your Opencode configuration file. See [Opencode MCP docs](https://opencode.ai/docs/mcp-servers)docs for more info.
389
+
Add this to your Opencode configuration file. See [Opencode MCP docs](https://opencode.ai/docs/mcp-servers) for more info.
390
390
391
391
#### Opencode Remote Server Connection
392
392
@@ -438,7 +438,7 @@ command = "npx"
438
438
439
439
See [JetBrains AI Assistant Documentation](https://www.jetbrains.com/help/ai-assistant/configure-an-mcp-server.html) for more details.
440
440
441
-
1. In JetBrains IDEs go to `Settings` -> `Tools` -> `AI Assistant` -> `Model Context Protocol (MCP)`
441
+
1. In JetBrains IDEs, go to `Settings` -> `Tools` -> `AI Assistant` -> `Model Context Protocol (MCP)`
442
442
2. Click `+ Add`.
443
443
3. Click on `Command` in the top-left corner of the dialog and select the As JSON option from the list
444
444
4. Add this configuration and click `OK`
@@ -621,7 +621,7 @@ If you prefer to run the MCP server in a Docker container:
621
621
<details>
622
622
<summary><b>Install Using the Desktop Extension</b></summary>
623
623
624
-
Install the [context7.dxt](dxt/context7.dxt) file under the dxt folder and add it to your client. For more information please check out [the desktop extensions docs](https://github.com/anthropics/dxt#desktop-extensions-dxt).
624
+
Install the [context7.dxt](dxt/context7.dxt) file under the dxt folder and add it to your client. For more information, please check out [the desktop extensions docs](https://github.com/anthropics/dxt#desktop-extensions-dxt).
625
625
626
626
</details>
627
627
@@ -981,22 +981,31 @@ Context7 MCP provides the following tools that LLMs can use:
981
981
982
982
### Add a Rule
983
983
984
-
> If you don’t want to add `use context7` to every prompt, you can define a simple rule in your `.windsurfrules` file in Windsurf or from `Cursor Settings > Rules` section in Cursor (or the equivalent in your MCP client) to auto-invoke Context7 on any code question:
984
+
> If you don’t want to add `use context7` to every prompt, you can define a simple rule in your MCP client's rule section:
985
985
>
986
+
> * For Windsurf, in `.windsurfrules` file
987
+
>
988
+
> * For Cursor, from `Cursor Settings > Rules` section
989
+
>
990
+
> * For Claude Code, in `CLAUDE.md` file
991
+
>
992
+
> Or the equivalent in your MCP client to auto-invoke Context7 on any code question.
993
+
>
994
+
> Example Rule:
986
995
> ```toml
987
-
> [[calls]]
988
-
> match = "when the user requests code examples, setup or configuration steps, or library/API documentation"
989
-
> tool = "context7"
996
+
> Always use context7 when I need code generation, setup or configuration steps, or
997
+
> library/API documentation. This means you should automatically use the Context7 MCP
998
+
> tools to resolve library id and get library docs without me having to explicitly ask.
990
999
> ```
991
1000
>
992
-
> From then on you’ll get Context7’s docs in any related conversation without typing anything extra. You can add your use cases to the match part.
1001
+
> From then on, you’ll get Context7’s docs in any related conversation without typing anything extra. You can alter the rule to match your use cases.
993
1002
994
1003
### Use Library Id
995
1004
996
1005
> If you already know exactly which library you want to use, add its Context7 ID to your prompt. That way, Context7 MCP server can skip the library-matching step and directly continue with retrieving docs.
997
1006
>
998
1007
> ```txt
999
-
> implement basic authentication with supabase. use library /supabase/supabase for api and docs
1008
+
> Implement basic authentication with Supabase. use library /supabase/supabase for API and docs.
1000
1009
> ```
1001
1010
>
1002
1011
> The slash syntax tells the MCP tool exactly which library to load docs for.
@@ -1033,7 +1042,7 @@ bun run dist/index.js
1033
1042
-`--port <number>` – Port to listen on when using `http` transport (default `3000`).
1034
1043
-`--api-key <key>` – API key for authentication. You can get your API key by creating an account at [context7.com/dashboard](https://context7.com/dashboard).
1035
1044
1036
-
Example with http transport and port 8080:
1045
+
Example with HTTP transport and port 8080:
1037
1046
1038
1047
```bash
1039
1048
bun run dist/index.js --transport http --port 8080
0 commit comments