The problem
You’ve probably been asked this question before: “How many concurrent calls are we handling through our Microsoft Teams Direct Routing SBCs?”
Normally Teams admins head straight to the Teams Admin Center, check those usage reports for their SBCs, and find hourly incoming and outgoing call counts. While helpful, this doesn’t answer the real question: How many calls were happening simultaneously?
This becomes even more challenging when you’re running multiple SBCs with load balancing - you need to piece together the total concurrent call picture across your entire SIP trunk infrastructure.
A PowerShell Solution
I needed better visibility into concurrent call patterns, so I built a PowerShell script that handles the calculations and data aggregation. The script includes an HTML dashboard (with some support from 🤖 Copilot for the visual elements) that provides:
- ✅ Actual concurrent calls calculations
- ✅ Cross-SBC aggregation for total infrastructure view
- ✅ HTML dashboard for reporting
- ✅ Dual data sources: Graph API or CSV exports
- ✅ Business hours analysis for capacity planning
- ✅ Weekly usage patterns and trend analysis
GitHub Repository
You can find the script and detailed instructions in the GitHub repository: Teams Direct Routing Concurrent Calls Analysis
Sample Output
The generated HTML report will look like this:
Key Features
🔄 Flexible Data Sources - Two options depending on your workflow:
- Graph API: Direct connection for automation with flexible date ranges
- App Secret or Certificate authentication modes
- CSV Import: Works with Teams Admin Center exports for ad-hoc analysis
📊 Easy Analytics
- Daily concurrent call trends with visual charts
- Business hours averages (Monday-Friday, 8AM-6PM)
- 90th percentile capacity thresholds
- Weekly heatmaps showing peak usage times
- Top 10 highest traffic days for pattern analysis
How to use this script
Option 1: Graph API connection (flexible approach)
Best for flexible reporting for example in context of the date range.
Prerequisites
Cause the Graph permission for that is only usable in the application context (and not your user context), you need an Azure App Registration with GraphAPI application permission CallRecords.Read.All
Authentication Examples
App Secret Authentication:
|
|
Certificate Authentication:
|
|
Date Range Options
|
|
Option 2: CSV Import (Quick Analysis)
Perfect for one-time analysis or when you prefer working with Teams Admin Center exports.
Step 1: Export from Teams Admin Center
- Navigate to Teams Admin Center → Analytics & reports → Usage reports
- Select PSTN and SMS usage
- Choose Direct Routing tab
- Set your date range and export to Excel
- Save as CSV format
Step 2: Run the Analysis
|
|
Additional Options
|
|
What You Get
📈 Key Metrics
- Analysis Period: Days covered in the report
- Peak Daily Calls: Maximum concurrent call load
- Daily Average: Typical concurrent call volume
- Business Hours Average: Workday-specific metrics (Mon-Fri, 8AM-6PM)
- 90th Percentile: Capacity planning baseline
- High-Volume Days: Days exceeding normal patterns
📊 Visual Analysis
- Daily Trends: Line charts with Monday markers for week-over-week comparison
- Weekly Heatmaps: Identify peak call times throughout the week
- Traffic Rankings: Sorted list of highest-volume days
🔍 Per-SBC Analysis
For multi-SBC environments:
- Individual SBC load patterns
- Capacity utilization comparison
- Load balancing effectiveness assessment
Additional information
In the README file of the repository, you will find more information regarding the script, including the prerequisites, how to create the Azure App Registration, and how to set up the required permissions.