Discover Awesome MCP Servers

Extend your agent with 57,384 capabilities via MCP servers.

All57,384
agentbill-mcp

agentbill-mcp

MCP server for AI agent billing. Preflight spend checks before agent runs. Post-execution usage billing via two MCP tools: preflight() and record_event().

mcp-ebay

mcp-ebay

Enables AI agents to search products, view item details, track and place bids, make Buy It Now purchases, view order history, and track shipments on eBay via browser automation with Playwright.

node-opcua-modeler-mcp-server

node-opcua-modeler-mcp-server

Provides AI agents with offline access to OPC UA companion specification types, dependencies, and engineering units for industrial modeling.

claude-orchestrator

claude-orchestrator

Enables spawning and managing multiple Claude Code agents in parallel with model selection, live tracking via a kanban dashboard, and consolidated answers back in the chat.

keygenix-mcp

keygenix-mcp

Non-custodial TEE key management and signing for AI agents, supporting multiple blockchains.

R2 Bucket MCP

R2 Bucket MCP

Enables file operations (upload, download, list, delete) on Cloudflare R2 (S3-compatible) storage, with dedicated APK upload tool.

MCPCloud

MCPCloud

A self-hosted MCP gateway that lets you write Python functions and register them as skills to be used as tools by any MCP-compatible client like Claude Desktop or Claude API.

OpenWeb Ninja MCP

OpenWeb Ninja MCP

Official MCP server for OpenWeb Ninja: 40+ real-time web data and SERP APIs (Google Maps, Amazon, jobs, Zillow, Trustpilot, web search, news, finance) exposed as MCP tools.

MCP server for Azure Cosmos DB using the Go SDK

MCP server for Azure Cosmos DB using the Go SDK

Okay, here's a sample implementation of an MCP (Message Control Protocol) server for Cosmos DB built using the Go SDK. This is a basic example and will need to be adapted to your specific needs. It focuses on the core concepts of connecting to Cosmos DB, listening for messages, and performing basic CRUD operations. **Important Considerations Before You Start:** * **Security:** This example does *not* include robust security measures. In a production environment, you *must* implement proper authentication, authorization, and encryption. Consider using TLS for communication and secure storage of your Cosmos DB credentials. * **Error Handling:** The error handling in this example is simplified. You should implement more comprehensive error handling, logging, and potentially retry mechanisms. * **Scalability:** This is a single-threaded example. For production use, you'll likely need to use goroutines and channels to handle multiple requests concurrently. * **Message Format:** This example assumes a simple string-based message format. You'll likely want to use a more structured format like JSON or Protocol Buffers. * **Dependencies:** Make sure you have the Go Cosmos DB SDK installed: `go get github.com/Azure/azure-sdk-for-go/sdk/data/azcosmos` **Code Example (main.go):** ```go package main import ( "bufio" "context" "encoding/json" "fmt" "log" "net" "os" "strings" "github.com/Azure/azure-sdk-for-go/sdk/azcore" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/data/azcosmos" ) // Constants (replace with your actual values) const ( CosmosDBEndpoint = "YOUR_COSMOSDB_ENDPOINT" // e.g., "https://your-cosmosdb.documents.azure.com:443/" CosmosDBDatabase = "YOUR_DATABASE_NAME" CosmosDBContainer = "YOUR_CONTAINER_NAME" ListenAddress = "localhost:8080" ) // Item represents a document in Cosmos DB. Adjust fields as needed. type Item struct { ID string `json:"id"` Name string `json:"name"` Description string `json:"description,omitempty"` // Optional field } var ( cosmosClient *azcosmos.Client databaseClient *azcosmos.DatabaseClient containerClient *azcosmos.ContainerClient ) func main() { // Initialize Cosmos DB client var err error cosmosClient, err = initializeCosmosClient() if err != nil { log.Fatalf("Failed to initialize Cosmos DB client: %v", err) } databaseClient, err = cosmosClient.NewDatabaseClient(CosmosDBDatabase) if err != nil { log.Fatalf("Failed to initialize Cosmos DB database client: %v", err) } containerClient, err = databaseClient.NewContainerClient(CosmosDBContainer) if err != nil { log.Fatalf("Failed to initialize Cosmos DB container client: %v", err) } // Start listening for connections listener, err := net.Listen("tcp", ListenAddress) if err != nil { log.Fatalf("Failed to start listener: %v", err) } defer listener.Close() fmt.Printf("Listening on %s...\n", ListenAddress) for { conn, err := listener.Accept() if err != nil { log.Printf("Failed to accept connection: %v", err) continue } go handleConnection(conn) // Handle each connection in a separate goroutine } } func initializeCosmosClient() (*azcosmos.Client, error) { // Use Azure Identity for authentication (recommended for production) cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { fmt.Println("Failed to obtain credential. Trying with account key.") // Fallback to account key (less secure, use only for development/testing) accountKey := os.Getenv("COSMOS_ACCOUNT_KEY") // Or read from a config file if accountKey == "" { return nil, fmt.Errorf("COSMOS_ACCOUNT_KEY environment variable not set") } cred, err = azcosmos.NewKeyCredential(accountKey) if err != nil { return nil, fmt.Errorf("failed to create key credential: %w", err) } } clientOptions := &azcosmos.ClientOptions{ ClientOptions: azcore.ClientOptions{ Telemetry: azcore.TelemetryOptions{ Disabled: false, }, }, } client, err := azcosmos.NewClient(CosmosDBEndpoint, cred, clientOptions) if err != nil { return nil, fmt.Errorf("failed to create Cosmos DB client: %w", err) } return client, nil } func handleConnection(conn net.Conn) { defer conn.Close() reader := bufio.NewReader(conn) for { message, err := reader.ReadString('\n') if err != nil { log.Printf("Error reading from connection: %v", err) return } message = strings.TrimSpace(message) if message == "" { continue // Skip empty messages } log.Printf("Received message: %s", message) response, err := processMessage(message) if err != nil { log.Printf("Error processing message: %v", err) response = fmt.Sprintf("ERROR: %v\n", err) } _, err = conn.Write([]byte(response + "\n")) if err != nil { log.Printf("Error writing to connection: %v", err) return } } } func processMessage(message string) (string, error) { // Simple command parsing (e.g., "create <json>", "read <id>", "update <json>", "delete <id>") parts := strings.SplitN(message, " ", 2) if len(parts) < 1 { return "", fmt.Errorf("invalid message format") } command := strings.ToLower(parts[0]) switch command { case "create": if len(parts) < 2 { return "", fmt.Errorf("missing JSON data for create command") } return handleCreate(parts[1]) case "read": if len(parts) < 2 { return "", fmt.Errorf("missing ID for read command") } return handleRead(parts[1]) case "update": if len(parts) < 2 { return "", fmt.Errorf("missing JSON data for update command") } return handleUpdate(parts[1]) case "delete": if len(parts) < 2 { return "", fmt.Errorf("missing ID for delete command") } return handleDelete(parts[1]) default: return "", fmt.Errorf("unknown command: %s", command) } } func handleCreate(jsonData string) (string, error) { var item Item err := json.Unmarshal([]byte(jsonData), &item) if err != nil { return "", fmt.Errorf("failed to unmarshal JSON: %w", err) } // Create the item in Cosmos DB partitionKey := azcosmos.NewPartitionKeyString(item.ID) // Use ID as partition key resp, err := containerClient.CreateItem(context.TODO(), partitionKey, item, nil) if err != nil { return "", fmt.Errorf("failed to create item: %w", err) } return fmt.Sprintf("Item created with ID: %s, Status Code: %d", item.ID, resp.RawResponse.StatusCode), nil } func handleRead(id string) (string, error) { partitionKey := azcosmos.NewPartitionKeyString(id) resp, err := containerClient.ReadItem(context.TODO(), partitionKey, id, nil) if err != nil { return "", fmt.Errorf("failed to read item: %w", err) } var item Item err = json.Unmarshal(resp.Value, &item) if err != nil { return "", fmt.Errorf("failed to unmarshal item: %w", err) } itemJSON, err := json.Marshal(item) if err != nil { return "", fmt.Errorf("failed to marshal item to JSON: %w", err) } return string(itemJSON), nil } func handleUpdate(jsonData string) (string, error) { var item Item err := json.Unmarshal([]byte(jsonData), &item) if err != nil { return "", fmt.Errorf("failed to unmarshal JSON: %w", err) } partitionKey := azcosmos.NewPartitionKeyString(item.ID) resp, err := containerClient.ReplaceItem(context.TODO(), partitionKey, item.ID, item, nil) if err != nil { return "", fmt.Errorf("failed to update item: %w", err) } return fmt.Sprintf("Item updated with ID: %s, Status Code: %d", item.ID, resp.RawResponse.StatusCode), nil } func handleDelete(id string) (string, error) { partitionKey := azcosmos.NewPartitionKeyString(id) resp, err := containerClient.DeleteItem(context.TODO(), partitionKey, id, nil) if err != nil { return "", fmt.Errorf("failed to delete item: %w", err) } return fmt.Sprintf("Item deleted with ID: %s, Status Code: %d", id, resp.RawResponse.StatusCode), nil } ``` **Explanation:** 1. **Dependencies:** Imports necessary packages, including the Azure Cosmos DB SDK. 2. **Constants:** Defines constants for your Cosmos DB endpoint, database name, container name, and the listening address for the MCP server. *Replace these with your actual values.* 3. **Item Struct:** Defines a simple `Item` struct to represent the data you'll be storing in Cosmos DB. Adjust the fields to match your data model. 4. **`main()` Function:** * Initializes the Cosmos DB client using `initializeCosmosClient()`. * Starts a TCP listener on the specified address. * Accepts incoming connections in a loop. * Spawns a new goroutine to handle each connection using the `handleConnection()` function. 5. **`initializeCosmosClient()` Function:** * Creates a Cosmos DB client using Azure Identity (recommended for production). It attempts to use `azidentity.NewDefaultAzureCredential(nil)` which will try to authenticate using various methods (environment variables, managed identity, etc.). * If Azure Identity fails, it falls back to using an account key (less secure, use only for development/testing). It reads the account key from the `COSMOS_ACCOUNT_KEY` environment variable. *Make sure to set this environment variable if you're using the account key method.* * Creates a `azcosmos.Client` instance. 6. **`handleConnection()` Function:** * Reads messages from the connection using a `bufio.Reader`. * Trims whitespace from the message. * Calls `processMessage()` to handle the message. * Writes the response back to the connection. 7. **`processMessage()` Function:** * Parses the message into a command and arguments. * Uses a `switch` statement to handle different commands (create, read, update, delete). * Calls the appropriate handler function for each command. 8. **`handleCreate()` Function:** * Unmarshals the JSON data from the message into an `Item` struct. * Creates the item in Cosmos DB using `containerClient.CreateItem()`. * Uses the `ID` field of the item as the partition key. *Choose an appropriate partition key for your data.* 9. **`handleRead()` Function:** * Reads an item from Cosmos DB using `containerClient.ReadItem()`. * Unmarshals the JSON data from the response into an `Item` struct. * Marshals the `Item` struct back into JSON and returns it. 10. **`handleUpdate()` Function:** * Unmarshals the JSON data from the message into an `Item` struct. * Replaces an item in Cosmos DB using `containerClient.ReplaceItem()`. 11. **`handleDelete()` Function:** * Deletes an item from Cosmos DB using `containerClient.DeleteItem()`. **How to Run:** 1. **Install Dependencies:** `go mod init mcp-cosmosdb` (or your preferred module name) and `go get github.com/Azure/azure-sdk-for-go/sdk/data/azcosmos github.com/Azure/azure-sdk-for-go/sdk/azidentity github.com/Azure/azure-sdk-for-go/sdk/azcore` 2. **Set Environment Variables:** * If using Azure Identity, configure your environment for Azure authentication (e.g., set `AZURE_CLIENT_ID`, `AZURE_CLIENT_SECRET`, `AZURE_TENANT_ID` if using a service principal). * If using an account key, set the `COSMOS_ACCOUNT_KEY` environment variable. 3. **Replace Placeholders:** Update the `CosmosDBEndpoint`, `CosmosDBDatabase`, and `CosmosDBContainer` constants with your actual Cosmos DB values. 4. **Run the Server:** `go run main.go` **Example Usage (using `netcat` or a similar tool):** 1. **Create:** ```bash echo 'create {"id": "item1", "name": "My Item", "description": "A sample item"}' | nc localhost 8080 ``` 2. **Read:** ```bash echo 'read item1' | nc localhost 8080 ``` 3. **Update:** ```bash echo 'update {"id": "item1", "name": "Updated Item", "description": "An updated item"}' | nc localhost 8080 ``` 4. **Delete:** ```bash echo 'delete item1' | nc localhost 8080 ``` **Vietnamese Translation of Key Concepts:** * **MCP Server:** Máy chủ MCP (Máy chủ Giao thức Điều khiển Tin nhắn) * **Cosmos DB:** Cosmos DB (Cơ sở dữ liệu Cosmos) * **Go SDK:** SDK Go (Bộ công cụ phát triển Go) * **Endpoint:** Điểm cuối * **Database:** Cơ sở dữ liệu * **Container:** Vùng chứa * **Item:** Mục (hoặc đối tượng) * **Partition Key:** Khóa phân vùng * **Create:** Tạo * **Read:** Đọc * **Update:** Cập nhật * **Delete:** Xóa * **Authentication:** Xác thực * **Authorization:** Ủy quyền * **Encryption:** Mã hóa * **Goroutine:** Goroutine (một luồng thực thi đồng thời trong Go) * **Channel:** Kênh (dùng để giao tiếp giữa các goroutine) * **JSON:** JSON (Định dạng dữ liệu JSON) * **Environment Variable:** Biến môi trường **Important Notes for Vietnamese Speakers:** * Hãy chắc chắn rằng bạn đã cài đặt Go và các thư viện cần thiết. * Thay thế các giá trị giữ chỗ (ví dụ: `YOUR_COSMOSDB_ENDPOINT`, `YOUR_DATABASE_NAME`, `YOUR_CONTAINER_NAME`) bằng thông tin Cosmos DB thực tế của bạn. * Xem xét các vấn đề bảo mật và xử lý lỗi trong môi trường sản xuất. * Sử dụng khóa phân vùng phù hợp cho dữ liệu của bạn để đảm bảo hiệu suất tốt. * Bạn có thể sử dụng `netcat` hoặc một công cụ tương tự để gửi tin nhắn đến máy chủ MCP. This comprehensive example provides a solid foundation for building your MCP server for Cosmos DB using Go. Remember to adapt it to your specific requirements and prioritize security and error handling. Good luck!

mcp-arcgis-houston

mcp-arcgis-houston

This MCP server provides access to City of Houston GIS open geospatial data, enabling search, query, and schema retrieval of datasets like parcels and zoning through ArcGIS feature services.

livewire-flux-mcp

livewire-flux-mcp

MCP server that provides access to Livewire Flux components and layouts documentation, enabling AI assistants to fetch and search through documentation on demand.

nanobanana-mcp

nanobanana-mcp

MCP server for AI image generation supporting text-to-image and image-to-image editing via any OpenAI-compatible service, with configurable models, aspect ratios, and sizes.

MCP Maximo Server

MCP Maximo Server

Wraps IBM Maximo API services as MCP tools, enabling AI applications like Dify Agent to manage assets, work orders, and inventory through natural language interactions with enterprise asset management systems.

narajangteo-pro

narajangteo-pro

Integrates 6 Korean public procurement APIs to search, analyze, and manage procurement data using natural language.

code-context-mcp

code-context-mcp

Indexes codebases into a SQLite database to provide metadata, exports, dependency graphs, and change tracking for JS/TS projects. It enables users to search for symbols, map internal dependencies, and monitor file changes through MCP tools and a web dashboard.

Firewalla MCP Server

Firewalla MCP Server

A production-ready server that connects Claude Desktop to Firewalla network management capabilities, allowing users to monitor devices, analyze network traffic, manage security alerts, and configure firewall rules through natural language.

PDD Shopping MCP

PDD Shopping MCP

Enables searching, normalizing, and signal-analyzing products on Pinduoduo, with built-in fraud signals to help Claude reason about product authenticity.

Google Workspace MCP Server

Google Workspace MCP Server

A comprehensive integration providing 114 tools to manage Google Drive, Docs, Sheets, Slides, Gmail, Calendar, and more through the Model Context Protocol. It enables seamless interaction with the full Google Workspace suite for file management, communication, and scheduling directly within Claude.

Google Drive MCP Server

Google Drive MCP Server

Enables interaction with Google Drive files and Google Sheets through search, read, and write operations. Supports automatic conversion of Google Workspace files to readable formats and direct spreadsheet cell updates.

vertex-cli

vertex-cli

Enables lookup of Nostr profiles and checking of Vertex API credit balance using the Vertex API.

ckg-mcp

ckg-mcp

A Compact Knowledge Graph MCP server providing pre-structured domain knowledge as a routing layer for agent stacks, enabling efficient structural queries (e.g., prerequisites, dependency chains) without hallucinations.

Spinitron API MCP Server

Spinitron API MCP Server

Enables interaction with Spinitron's radio playlist management and broadcasting data through a Multi-Agent Conversation Protocol interface, allowing users to query and manage radio station playlists, spins, and other broadcasting data via natural language.

desktop-touch-mcp

desktop-touch-mcp

Allows AI clients to see and control Windows 10/11 desktops via MCP, with screenshots, UI Automation, Chrome CDP, keyboard/mouse, and terminal using semantic element targeting.

arcgis-grandchute

arcgis-grandchute

Enables AI agents to search and query Town of Grand Chute, Wisconsin open geospatial datasets (parcels, zoning, public works) via ArcGIS Feature Services.

MCP Server Demo

MCP Server Demo

A simple demonstration project for the Model Control Protocol (MCP) server that provides tools for AI assistants to fetch news articles, perform calculations, retrieve weather data, and generate personalized greetings.

basic-mcp

basic-mcp

Provides a suite of deterministic tools for time calculations, math, and string manipulation that LLMs often struggle to perform accurately. It also includes utilities for secure randomness, data validation, and basic network operations like DNS lookups.

brain-mcp

brain-mcp

Provides intelligent conversation memory storage using DuckDB, with support for multiple storage backends and automatic memory consolidation.

telegram-mcp-notify

telegram-mcp-notify

Enables AI coding agents to send structured Telegram notifications for events like questions, plan_ready, final, attention_needed, and error.

sqlite-readonly-mcp

sqlite-readonly-mcp

A read-only SQLite MCP server for remote Linux deployment that provides secure database querying via SELECT statements and table listing. It uses Bearer Token authentication and returns JSON results through Streamable HTTP, designed to run behind Nginx with HTTPS.

MCP Utility Server

MCP Utility Server

A beginner-friendly MCP server offering time, math, internet quotes, dad jokes, file tools, web search, and optional LangChain agent.