microsoft-agents-hosting-fastapi
Integration library for Microsoft Agents with FastAPI
Decision gist · record as of 2026-08-14
Yes, if you are building conversational agents with the Microsoft Agents framework and want to deploy them on FastAPI. The package is actively maintained, has low install friction, carries a permissive MIT license, and integrates cleanly with FastAPI's async model. No known vulnerabilities.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python >=3.10
- Low install friction with a pure-Python wheel.
- Actively maintained with releases every 2–3 weeks; last commit 2026-08-13.
License · maintenance · safety
MIT (permissive) — MIT license permits commercial and private use with minimal restrictions; suitable for most projects.
last release 2026-07-30 (15 days) · last repo commit 2026-08-13 · 1,036 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 222,972 downloads/mo, #9,255 on PyPI
Alternatives
Verify before relying
pip install microsoft-agents-hosting-fastapi
from fastapi import FastAPI, Request
from microsoft_agents.hosting.fastapi import start_agent_process, CloudAdapter
from microsoft_agents.hosting.core.app import AgentApplication
app = FastAPI()
adapter = CloudAdapter(connection_manager=connection_manager)
agent_app = AgentApplication()
@app.post("/api/messages")
async def messages(request: Request):
return await start_agent_process(request, agent_app, adapter)- Whether the package supports streaming response patterns beyond what the description excerpt shows
- Specific JWT authorization middleware configuration requirements and defaults
- Whether CloudAdapter and AgentApplication are fully documented or require external Microsoft Agents docs
What it is and what it does
Microsoft Agents Hosting FastAPI is a bridge between the Microsoft Agents framework and FastAPI, allowing you to deploy conversational agents as HTTP services. It wraps the core agent runtime with FastAPI-specific bindings, providing middleware for JWT authorization, predefined channel service endpoints, and support for streaming responses. The package is built on fastapi and starlette, so it inherits their async-first design.
You use it by instantiating a CloudAdapter with your connection manager, creating an AgentApplication, and wiring them into a FastAPI route handler via the start_agent_process function. The library handles the protocol translation between HTTP requests and the agent's internal activity model, letting you focus on agent logic rather than web framework plumbing.
Use it for
- Host a conversational agent as a REST API endpoint that receives and responds to user messages over HTTP
- Integrate Microsoft Agents with existing FastAPI applications for multi-turn dialogue handling
- Deploy agents with JWT-based authorization and channel service compatibility
- Build streaming-capable agent responses for real-time conversation experiences
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes, if you are building conversational agents with the Microsoft Agents framework and want to deploy them on FastAPI.
The package is actively maintained, has low install friction, carries a permissive MIT license, and integrates cleanly with FastAPI's async model. No known vulnerabilities.
Install
microsoft-agents-hosting-fastapi on PyPI
Before you install
Low install friction with a pure-Python wheel. Actively maintained with releases every 2–3 weeks; last commit 2026-08-13. Requires Python >=3.10. Depends on microsoft-agents-hosting-core, fastapi, and starlette.
Requires Python >=3.10
License in practice
MIT license permits commercial and private use with minimal restrictions; suitable for most projects.
Quickstart
pip install microsoft-agents-hosting-fastapi
from fastapi import FastAPI, Request
from microsoft_agents.hosting.fastapi import start_agent_process, CloudAdapter
from microsoft_agents.hosting.core.app import AgentApplication
app = FastAPI()
adapter = CloudAdapter(connection_manager=connection_manager)
agent_app = AgentApplication()
@app.post("/api/messages")
async def messages(request: Request):
return await start_agent_process(request, agent_app, adapter)
Verify before relying
- Whether the package supports streaming response patterns beyond what the description excerpt shows
- Specific JWT authorization middleware configuration requirements and defaults
- Whether CloudAdapter and AgentApplication are fully documented or require external Microsoft Agents docs
Package facts
| License | MIT permissive |
| Python support | Supports the current Python release >=3.10 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 3 packagesmicrosoft-agents-hosting-corefastapistarlette |
| Maintenance | Actively maintained 15 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 222,972 / month, #9,255 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Operating System :: OS IndependentProgramming Language :: Python :: 3 |
Evidence: microsoft_agents_hosting_fastapi-1.3.0-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “fastapi agents framework”
- microsoft-agents-hosting-fastapiProvides FastAPI integration for building and hosting conversational…
- ag_ui_adkBridges Google ADK agents to the AG-UI Protocol, enabling ADK-built…
- copilotkitCopilotKit is a Python SDK for building AI copilots and agents that…
Give your agent the search over MCP, or paste the wish link into any chat.
More Application Frameworks packages
FastAPI is a Python web framework for building REST APIs using type hints, with automatic request validation, serialization, and interactive API documentation.
Provides a way to document function parameters, class attributes, return types, and variables inline using Python's `Annotated` type hint syntax instead of traditional docstrings.
Textual is a Python framework for building cross-platform user interfaces that run in the terminal or web browser using a modern, component-based API.
Install it if you're developing CLI tools, dashboards, or interactive terminal applications.
Typer builds command-line applications from Python functions using type hints, automatically generating help text, argument parsing, and shell completion.
Install it if you are building CLIs in Python.
Build and connect to Model Context Protocol servers that expose tools, resources, and prompts to LLM applications over stdio, HTTP, or SSE transports.
Install it if you need to build or connect to servers.
Werkzeug is a WSGI utility library providing request/response objects, URL routing, an interactive debugger, HTTP utilities, and a development server for building web applications.
See also microsoft-agents-authentication-msal · microsoft-agents-hosting-aiohttp · microsoft-agents-hosting-core · microsoft-agents-hosting-teams · microsoft-agents-activity · agent-framework-azure-ai · agent-framework-azurefunctions · fastapi-cloudevents · ag_ui_adk · microsoft-agents-copilotstudio-client