MCP Support Agent
Provides tools to interact with a ticket management REST API built with Express, allowing listing, retrieving, and creating tickets.
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 Support Agentsearch support documents for wifi issues"
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 Support Agent
This repo started as a small Express ticket API. I used it to learn how an existing API can be exposed through MCP, then added an Ollama-based agent and document search with local embeddings and LanceDB.
The code covers two use cases:
ticket tools backed by a REST API
support-document search backed by a local vector database
How it works
User question
↓
Ollama model
↓ requests a tool
TypeScript MCP client
↓ stdio
MCP server
├── ticket tools → Express REST API
└── document search → EmbeddingGemma → LanceDBThe model sees the available tools through MCP listTools(). When it requests a tool, the TypeScript client calls the MCP server and sends the result back to the model.
Related MCP server: OTRS MCP Server
MCP tools
Tool | Description |
| Get all tickets from the REST API |
| Get one ticket by ID |
| Create a ticket after user approval |
| Search support articles by meaning and optional category |
Document search
Support articles are split into sentences and embedded with embeddinggemma:300m-qat-q4_0. The indexing script stores the chunks and their vectors in LanceDB.
At query time, only the question is embedded. LanceDB applies the tenant and category filters, performs a cosine-distance search, and returns up to two matches within the configured distance threshold.
Indexing and querying use the same embedding model. If the model or source articles change, rebuild the index.
Setup
Requirements:
Node.js 20 or newer
Ollama running locally
Install the project and download the local models:
npm install
ollama pull embeddinggemma:300m-qat-q4_0
ollama pull qwen3:1.7bBuild the vector database:
npm run index:documentsLanceDB writes its files to data/, which is ignored by Git.
Run the local agent
npm run agent:localThe included prompt asks for printer help. The agent calls search_documents and prints the sources collected from the MCP result below the model's answer.
Run the ticket API
npm run devAvailable routes:
GET /tickets
GET /tickets/:id
POST /ticketsTickets are kept in memory, so created tickets are cleared when the server restarts.
Run the cloud agent
The cloud example needs an Ollama API key. Copy .env.example to .env and set the key, then run the API and agent in separate terminals:
npm run startnpm run agent:cloudThe example prompt creates a ticket and fetches another one. Write tools require confirmation before they run.
Retrieval checks
npm run evaluate:retrievalThe current test set contains three queries with expected articles and one query that should return no result:
Evaluation accuracy: 4/4 (100%)This is only a check against the small set of articles in this repo, not a general embedding benchmark.
Tenant filtering
Documents for two sample companies are stored in the same LanceDB table. The MCP server uses a fixed company-a tenant to stand in for an authenticated session.
The tool schema does not accept tenantId. A client can send that extra field, but it cannot override the tenant used by the server. A real application would take this value from a verified session or token instead of a constant.
Commands
Command | Description |
| Check TypeScript |
| Compile the project |
| Rebuild the LanceDB table |
| Run retrieval checks |
| List MCP tools and call document search directly |
| Run the local Ollama example |
| Run the Ollama Cloud example |
| Insert or replace the sample Wi-Fi article |
| Delete the sample Wi-Fi article |
Project layout
src/ API, MCP server, agents, and document search
scripts/ Indexing, document updates, and retrieval checks
examples/ Small examples built while learning each pieceThis 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/Hussainzz/api-mcp-rag'
If you have feedback or need assistance with the MCP directory API, please join our Discord server