Getting Started with Remote MCP Servers using Azure Functions (Java)
LocalAbout Getting Started with Remote MCP Servers using Azure Functions (Java)
A Java sample collection for building and deploying remote MCP servers with Azure Functions. It is aimed at developers and includes tool, prompt, structured-content, and interactive weather app examples.
Key features
- 01Java-based Azure Functions samples
- 02Local execution and debugging
- 03Deployment with `azd up`
- 04Microsoft Entra authentication
- 05Tool, prompt, and structured-content examples
- 06Interactive weather MCP App
Use cases
- 01Prototype a remote MCP server in Java
- 02Debug a sample locally before deployment
- 03Deploy MCP samples to Azure
- 04Explore tools, prompts, and MCP App resources
MCP support
The samples demonstrate remote MCP servers that expose tools, prompts, structured content, and an interactive weather app through MCP.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
Tools
Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.
Details
From the project READMERemote MCP Servers using Azure Functions (Java)
A collection of samples for building and deploying remote MCP servers to Azure using Azure Functions (Java). Each sample runs locally with debugging and deploys to Azure with azd up.
All samples are configured with built-in authentication using Microsoft Entra as the identity provider. You can also use API Management to secure the server, or add network isolation with VNET.
If you're looking for samples in other languages, see: .NET/C# | Node.js/TypeScript | Python
Prerequisites
- JDK 17 (or newer)
- Apache Maven
- Azure Functions Core Tools v4 >=
4.0.7030 - Azure Developer CLI (for deployment)
- Visual Studio Code + Azure Functions extension (recommended)
Samples in this repo
| Project | Path | Description |
|---|---|---|
| FunctionsMcpTool | samples/FunctionsMcpTool/ | MCP tools, prompts, and structured content; includes blob storage tools, prompt templates, image content, and multi-content responses. |
| McpWeatherApp | samples/McpWeatherApp/ | MCP App with an interactive weather UI (MCP tool + resource + metadata). |
Run locally
Each project has its own README with instructions for running locally, connecting to the MCP server, deploying to Azure, and more:
Next Steps
- Learn more about the Azure Functions MCP extension
- Learn more about built-in MCP auth
- Follow our blog posts on Azure SDK Blog and Tech Community for updates.
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.