MCP on Azure

MCP on Azure

Enables listing image blobs from Azure Blob Storage and generating descriptions using Azure OpenAI's gpt-4o vision model.

Category
Visit Server

README

MCP on Azure – Model Context Server that reads from Blob Storage and describes images with Azure OpenAI

Production-ready sample for running a minimal MCP Server on Azure. It exposes two tools:

  • list_captain_files – list all blob names in a container
  • describe_blob – generate a short description for an image blob using Azure OpenAI (gpt-4o)

✨ What you get

  • A minimal MCP Server built with Express.js.
  • Secure access to Azure Blob Storage using a connection string.
  • Server-side calls to Azure OpenAI vision models for image description.
  • Example .env.example for easy setup.
  • PowerShell & cURL commands for quick testing.

🧱 Architecture



flowchart TD
  A[MCP Client] -->|HTTP| B[MCP Server]
  B -->|List/Fetch| C[Azure Blob Storage]
  B -->|Send image| D[Azure OpenAI gpt-4o Vision]
  D -->|Description| B
  B -->|JSON Response| A

MCP Client (Copilot, Inspector, etc.) sends HTTP requests.

This Server (Express.js) handles /tools endpoints.

Server fetches the file from Azure Blob Storage.

Sends it to Azure OpenAI GPT-4o for a short, clear description.

📦 Prerequisites

  • Node.js 18+ (or 20/22)
  • Azure Storage Account with a container (e.g., captain-azure) containing images
  • Azure OpenAI resource with a gpt-4o deployment
  • Access keys & endpoint for both services

🔐 Environment Variables (.env)

AZURE_STORAGE_CONNECTION_STRING=DefaultEndpointsProtocol=https;AccountName=<name>;AccountKey=<key>;EndpointSuffix=core.windows.net
CONTAINER_NAME=captain-azure
AZURE_OPENAI_ENDPOINT=https://<your-openai>.openai.azure.com
AZURE_OPENAI_KEY=<your-openai-key>
AZURE_OPENAI_DEPLOYMENT_NAME=gpt-4o
AZURE_OPENAI_API_VERSION=2024-02-15-preview

🚀 Install & Run

git clone https://github.com/OfekBenEliezer/mcp-on-azure.git
cd mcp-on-azure
npm install
node server.js
# MCP Server running on: http://localhost:3333

📂 List blobs

PowerShell

Invoke-RestMethod -Uri "http://localhost:3333/tools/list_captain_files" `
  -Method Post `
  -ContentType "application/json"

cURL

curl -s -X POST http://localhost:3333/tools/list_captain_files \
  -H "Content-Type: application/json"

🖼 Describe a blob

PowerShell

Invoke-RestMethod -Uri "http://localhost:3333/tools/describe_blob" `
  -Method Post `
  -Body (@{ blobName = "CertWebinar.png" } | ConvertTo-Json) `
  -ContentType "application/json"

cURL

curl -s -X POST http://localhost:3333/tools/describe_blob \
  -H "Content-Type: application/json" \
  -d '{"blobName":"CertWebinar.png"}'

Expected output

{
  "description": "A short, clear sentence describing the image."
}

🛡️ Security Notes

  • Never commit keys or secrets.
  • If blobs are private, generate SAS URLs with short TTL.
  • Restrict CORS and ingress when running in production.
  • For enterprise scenarios, prefer Managed Identity over raw keys.

📜 License

MIT License – free to use, modify, and distribute with attribution.


👨‍✈️ Built by Captain Azure – Ofek Ben Eliezer

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured