Skip to main content

Integration library for Microsoft Agents with FastAPI

Project description

Microsoft Agents Hosting FastAPI

This library provides FastAPI integration for Microsoft Agents, enabling you to build conversational agents using the FastAPI web framework.

Features

  • FastAPI integration for Microsoft Agents
  • JWT authorization middleware
  • Channel service API endpoints
  • Streaming response support
  • Cloud adapter for processing agent activities

Installation

pip install microsoft-agents-hosting-fastapi

Usage

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()
agent_app = AgentApplication()

@app.post("/api/messages")
async def messages(request: Request):
    return await start_agent_process(request, agent_app, adapter)

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

microsoft_agents_hosting_fastapi-0.7.0.dev0.tar.gz (10.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file microsoft_agents_hosting_fastapi-0.7.0.dev0.tar.gz.

File metadata

File hashes

Hashes for microsoft_agents_hosting_fastapi-0.7.0.dev0.tar.gz
Algorithm Hash digest
SHA256 c4bd87270ec8e4898f5e6f801fc65c41505b4826b0edf2ef24f76cdc0e44bab3
MD5 462f3f501d104d90484a4407748848a7
BLAKE2b-256 a68fca6186559c704897ad115c1041a8e6aed4819ebb785a6b47c66d8b83e2bf

See more details on using hashes here.

File details

Details for the file microsoft_agents_hosting_fastapi-0.7.0.dev0-py3-none-any.whl.

File metadata

File hashes

Hashes for microsoft_agents_hosting_fastapi-0.7.0.dev0-py3-none-any.whl
Algorithm Hash digest
SHA256 23dca5efb3c61bb3c4495717490433b3a8e58598332af231a7f4e409ce65a8f4
MD5 628b885bc45ba0ce7830cedfc716b7ba
BLAKE2b-256 2e9fc3c332d76cba1ad160aa9d4fcee522b806322ffab5c8cb256ba55c71dd71

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page