Skip to main content
Glama

SQL MCP Server

by polarisxb
MIT License
1
5
  • Apple
  • Linux
config.ts1.69 kB
import { AppConfig } from '../core/config/loader.js' import { validateConfig, ValidatedAppConfig } from '../core/config/schema.js' export function makeTestAppConfig(overrides: Partial<AppConfig> = {}): ValidatedAppConfig { const base: AppConfig = { database: { type: 'mysql' as any, host: 'localhost', port: 3306, user: 'test', password: 'test', database: 'test', connectionTimeout: 10000 as number }, cache: { enabled: true, ttl: 3600, storage: 'memory', maxSize: 1000, filePath: null as any, prewarmOnStart: true }, security: { readOnly: false, sensitiveFields: ['password', 'token'], maxQueryLength: 10000, sampleMaxRows: 100, queryTimeoutMs: 10000, rateLimit: { enabled: false, windowMs: 60000, max: 120, perIpMax: 60 }, queryMaxRows: 200 }, logging: { level: 'info', destination: 'console', filePath: '' }, mcp: { transport: 'stdio', httpPort: null as any, serverName: 'Test Server', serverVersion: '1.0.0', stdioSafe: false, stdioCompact: false, outputJsonOnly: false } } return validateConfig(deepMerge(base, overrides) as any) } function deepMerge<T>(target: T, source: Partial<T>): T { const result: any = Array.isArray(target) ? [...(target as any)] : { ...(target as any) } for (const [key, value] of Object.entries(source as any)) { if (value && typeof value === 'object' && !Array.isArray(value)) { result[key] = deepMerge((target as any)[key] ?? {}, value) } else { result[key] = value } } return result as T }

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/polarisxb/sql-mcp'

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