Skip to main content
Glama

Appwrite Docs MCP Server

Official
by appwrite
index.ts1.33 kB
import { MCPServer } from "mcp-framework"; import { initLibrariesWithFeatures } from "./lib/utils/process-libraries.js"; import { vectorStore } from "./lib/vector-store.js"; const port = parseInt(process.env.PORT ?? "1234"); await initLibrariesWithFeatures(); async function inspectVectorStore() { const count = await vectorStore.describeIndex({ indexName: "docs" }); console.log("Vector store count:", count); } await inspectVectorStore(); const server = new MCPServer({ transport: { type: "http-stream", options: { port, // Port to listen on endpoint: "/", // HTTP endpoint path (default: "/mcp") responseMode: "stream", // Response mode: "batch" or "stream" (default: "batch") batchTimeout: 30000, // Timeout for batch responses in ms (default: 30000) session: { enabled: true, headerName: "Mcp-Session-Id", allowClientTermination: true, }, cors: { // CORS configuration allowOrigin: "*", allowMethods: "GET, POST, DELETE, OPTIONS", allowHeaders: "Content-Type, Accept, Authorization, x-api-key, Mcp-Session-Id, Last-Event-ID", exposeHeaders: "Content-Type, Authorization, x-api-key, Mcp-Session-Id", maxAge: "86400", }, auth: {}, }, }, }); await server.start();

Latest Blog Posts

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/appwrite/mcp-for-docs'

If you have feedback or need assistance with the MCP directory API, please join our Discord server