A blob storage library for Microsoft Agents
Project description
Microsoft Agents Storage - Blob
Azure Blob Storage integration for Microsoft 365 Agents SDK. This library provides persistent storage for conversation state, user data, and custom agent information using Azure Blob Storage.
This library implements the storage interface for the Microsoft 365 Agents SDK using Azure Blob Storage as the backend. It enables your agents to persist conversation state, user preferences, and custom data across sessions. Perfect for production deployments where you need reliable, scalable cloud storage.
What is this?
This library is part of the Microsoft 365 Agents SDK for Python - a comprehensive framework for building enterprise-grade conversational AI agents. The SDK enables developers to create intelligent agents that work across multiple platforms including Microsoft Teams, M365 Copilot, Copilot Studio, and web chat, with support for third-party integrations like Slack, Facebook Messenger, and Twilio.
Release Notes
| Version | Date | Release Notes |
|---|---|---|
| 0.9.0 | 2026-04-15 | 0.9.0 Release Notes |
| 0.8.0 | 2026-02-23 | 0.8.0 Release Notes |
| 0.7.0 | 2026-01-21 | 0.7.0 Release Notes |
| 0.6.1 | 2025-12-01 | 0.6.1 Release Notes |
| 0.6.0 | 2025-11-18 | 0.6.0 Release Notes |
| 0.5.0 | 2025-10-22 | 0.5.0 Release Notes |
Packages Overview
We offer the following PyPI packages to create conversational experiences based on Agents:
Additionally we provide a Copilot Studio Client, to interact with Agents created in CopilotStudio:
| Package Name | PyPI Version | Description |
|---|---|---|
microsoft-agents-copilotstudio-client |
Direct to Engine client to interact with Agents created in CopilotStudio |
Installation
pip install microsoft-agents-storage-blob
Benefits:
- ✅ No secrets in code
- ✅ Managed Identity support
- ✅ Automatic token renewal
- ✅ Fine-grained access control via Azure RBAC
Configuration Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
container_name |
str |
Yes | Name of the blob container to use |
connection_string |
str |
No* | Storage account connection string |
url |
str |
No* | Blob service URL (e.g., https://account.blob.core.windows.net) |
credential |
TokenCredential |
No** | Azure credential for authentication |
*Either connection_string OR (url + credential) must be provided
**Required when using url
Azure Managed Identity
When running in Azure (App Service, Functions, Container Apps), use Managed Identity:
from azure.identity import ManagedIdentityCredential
config = BlobStorageConfig(
container_name="agent-storage",
url="https://myaccount.blob.core.windows.net",
credential=ManagedIdentityCredential()
)
Azure RBAC Roles Required:
Storage Blob Data Contributor- For read/write accessStorage Blob Data Reader- For read-only access
Benefits of switching to BlobStorage:
- ✅ Data persists across restarts
- ✅ Scalable to millions of items
- ✅ Multi-instance support (load balancing)
- ✅ Automatic backups and geo-replication
- ✅ Built-in monitoring and diagnostics
Best Practices
- Use Token Authentication in Production - Avoid storing connection strings; use Managed Identity or DefaultAzureCredential
- Initialize Once - Call
storage.initialize()during app startup, not on every request - Implement Retry Logic - Handle transient failures with exponential backoff
- Monitor Performance - Use Azure Monitor to track storage operations
- Set Lifecycle Policies - Configure automatic cleanup of old data in Azure Portal
- Use Consistent Naming - Establish key naming conventions (e.g.,
user:{id},conversation:{id}) - Batch Operations - Read/write multiple items together when possible
Key Classes Reference
BlobStorage- Main storage implementation using Azure Blob StorageBlobStorageConfig- Configuration settings for connection and authenticationStoreItem- Base class for data models (inherit to create custom types)
Quick Links
Sample Applications
| Name | Description | README |
|---|---|---|
| Quickstart | Simplest agent | Quickstart |
| Auto Sign In | Simple OAuth agent using Graph and GitHub | auto-signin |
| OBO Authorization | OBO flow to access a Copilot Studio Agent | obo-authorization |
| Semantic Kernel Integration | A weather agent built with Semantic Kernel | semantic-kernel-multiturn |
| Streaming Agent | Streams OpenAI responses | azure-ai-streaming |
| Copilot Studio Client | Console app to consume a Copilot Studio Agent | copilotstudio-client |
| Cards Agent | Agent that uses rich cards to enhance conversation design | cards |
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file microsoft_agents_storage_blob-0.9.0.tar.gz.
File metadata
- Download URL: microsoft_agents_storage_blob-0.9.0.tar.gz
- Upload date:
- Size: 10.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: RestSharp/106.13.0.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6910f5fba5c111da01d61b93c3d070c72ff7025fb4516c21a1e2c3bafe27cc07
|
|
| MD5 |
b140aafb3a58fc8909fc9a5d13f4ba4e
|
|
| BLAKE2b-256 |
fbab51d5b3642f520977f523097a08ee3293a6ce9f223f3df37a59847749e03a
|
File details
Details for the file microsoft_agents_storage_blob-0.9.0-py3-none-any.whl.
File metadata
- Download URL: microsoft_agents_storage_blob-0.9.0-py3-none-any.whl
- Upload date:
- Size: 8.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: RestSharp/106.13.0.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9ab21f48ed6a97124106a4055016614093745dc1085c56ae348254e97e0129c6
|
|
| MD5 |
23f76c272cd8f3fdd2e6eab8376bbef6
|
|
| BLAKE2b-256 |
f282c26cb4c609daa77eb999c80be6cd766d85bd2092dbe693edfed225eed813
|