Implementation details and integration guides for MCP Hub
https://ai.civic.com/hub/mcp
headers: { 'Authorization': `Bearer ${accessToken}` }
headers: { 'Authorization': `Bearer ${process.env.MCP_API_KEY}` }
npx @civic/hub-bridge install claude-desktop
open "~/Library/Application Support/Claude/claude_desktop_config.json"
{ "mcpServers": { "civic": { "command": "npx", "args": ["@civic/hub-bridge"] } } }
import { StreamableHTTPClientTransport } from '@modelcontextprotocol/sdk/client/streamableHttp.js'; import { getTokens } from "@civic/auth/nextjs"; // Get access token const { accessToken } = await getTokens() // Create MCP client const createMCPClient = async () => { const transport = new StreamableHTTPClientTransport( 'https://ai.civic.com/hub/mcp', { requestInit: { headers: { Authorization: `Bearer ${accessToken}` } } } ); return createMCPClient({ transport }); };
{ "name": "Authorization", "value": "Bearer YOUR_API_KEY" }
// List available MCP servers const response = await fetch('https://ai.civic.com/hub/mcp', { method: 'POST', headers: { 'Authorization': `Bearer ${apiKey}`, 'Content-Type': 'application/json' }, body: JSON.stringify({ jsonrpc: '2.0', method: 'tools/list', params: {}, id: 1, }), }); const result = await response.json(); console.log('Available tools:', result.result.tools);
Was this page helpful?