Skip to main content
Glama

MCP Gemini Server

by bsmi021
logger.ts1.25 kB
import chalk from "chalk"; // Using chalk for colored output // Simple console logger with levels and colors // Define log levels (optional, for potential filtering later) enum LogLevel { DEBUG, INFO, WARN, ERROR, } // Basic configuration (could be enhanced) const currentLogLevel = LogLevel.DEBUG; // Show all logs by default export const logger = { debug: (message: string, ...args: unknown[]) => { if (currentLogLevel <= LogLevel.DEBUG) { console.error(chalk.gray(`[DEBUG] `), ...args); } }, info: (message: string, ...args: unknown[]) => { if (currentLogLevel <= LogLevel.INFO) { console.error(chalk.blue(`[INFO] `), ...args); } }, warn: (message: string, ...args: unknown[]) => { if (currentLogLevel <= LogLevel.WARN) { console.error(chalk.yellow(`[WARN] `), ...args); } }, error: (message: string, ...args: unknown[]) => { if (currentLogLevel <= LogLevel.ERROR) { // Log error message and stack trace if available console.error(chalk.red(`[ERROR] `), ...args); const errorArg = args.find((arg) => arg instanceof Error); if (errorArg instanceof Error && errorArg.stack) { console.error(chalk.red(errorArg.stack)); } } }, };

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/bsmi021/mcp-gemini-server'

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