MCP LangChainJS Search Server
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@MCP LangChainJS Search Serversearch for RetrievalQA examples in langchainjs"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP LangChainJS Server
Serveur MCP (Model Context Protocol) en TypeScript permettant de rechercher des exemples et du code dans le dépôt GitHub LangChainJS (langchain-ai/langchainjs). Il expose un outil search_langchain que les clients MCP (ex. Claude Desktop) peuvent appeler pour retrouver rapidement des snippets TS/JS/MD pertinents.
Aperçu
Outil principal:
search_langchainSource: GitHub Search Code API via
@octokit/restTransport:
stdio(pour intégration avec clients MCP)Langage: TypeScript (build vers
dist/)
Related MCP server: Code Search MCP
Prérequis
Node.js 18+ et npm
(Optionnel) Un jeton GitHub personnel pour des quotas plus généreux
Variable d’environnement:
GITHUB_TOKEN
Installation
npm install
npm run buildDémarrage
Développement (TypeScript, sans build):
npm run devWatch (redémarrage auto):
npm run watchProduction (depuis
dist/):
npm startLe serveur écoute via stdio et est destiné à être lancé par un client MCP.
Configuration du client MCP (ex. Claude Desktop)
Exemple de configuration Claude Desktop (à adapter à votre chemin local) :
{
"mcpServers": {
"langchain-js": {
"command": "node",
"args": [
"/chemin/vers/votre/projet/dist/index.js"
],
"env": {
"GITHUB_TOKEN": "votre_token_optionnel"
}
}
}
}Notes:
GITHUB_TOKENest recommandé pour éviter les limitations strictes de l’API publique.Ne commitez jamais de secrets. Préférez des variables d’environnement ou un fichier
.envignoré par Git.
Variables d’environnement
Vous pouvez fournir un jeton GitHub pour augmenter les limites d’API :
export GITHUB_TOKEN=ghp_xxx_votre_tokenOu via un fichier .env (non commité) si votre outil de lancement le supporte.
Outils exposés
search_langchainEntrée:
query(string, requis): la requête de recherche (TS/JS/MD)
Sortie (texte): liste des correspondances avec nom, chemin, et URL HTML
Exemple d’appel (côté client MCP):
{
"name": "search_langchain",
"arguments": { "query": "RetrievalQA" }
}Architecture
src/index.ts: serveur MCP + transportstdio, enregistrement des handlerssrc/tools/search.ts: schéma de l’outil et handlersearch_langchainsrc/github-client.ts: client GitHub (Octokit) pour recherche et lecture de contenusrc/types.ts: types internes (exemples, résultats)
Scripts npm
npm run dev: exécutesrc/index.tsavects-nodenpm run watch: redémarre avecnodemonsur changementsnpm run build: compile TypeScript versdist/npm start: lancenode dist/index.js
Dépannage
Erreurs 403/abuse/ratelimit: fournissez
GITHUB_TOKEN.Résultats vides: vérifiez la requête (
query) et les extensions ciblées (TS/JS/MD).Import/ESM: le projet est configuré en
type: commonjsavects-nodeadapté; utiliseznpm run buildpuisnpm starten prod.
Sécurité
Ne mettez jamais un jeton en clair dans le dépôt.
Préférez des variables d’environnement et des gestionnaires de secrets.
Licence
ISC
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/PlumyCat/mcp-github-langchain-js'
If you have feedback or need assistance with the MCP directory API, please join our Discord server