-
-
Notifications
You must be signed in to change notification settings - Fork 1
Quick Installation
Deploy ACSforMCS to Azure in minutes using either the Deploy to Azure button or release packages. This guide provides the fastest path to get your telephony integration running.
The easiest way to deploy ACSforMCS with an interactive Azure Portal interface:
What gets created:
- App Service Plan and Web App
- Key Vault with secure configuration
- Azure Communication Services
- Azure Cognitive Services (Speech)
- Application Insights (optional)
Prerequisites:
-
Microsoft Entra ID Object ID (required for Key Vault access):
# Get your Object ID az ad signed-in-user show --query id -o tsvNote: The
objectIdproperty has been renamed toidin newer Azure CLI versions -
Azure subscription with appropriate permissions
Configuration during deployment:
- Project Name: Base name for resources (3-15 characters)
- Environment: dev, test, stage, or prod
- Region: Choose optimal Azure region
- SKU: Free F1 (testing) or Standard S1 (production recommended)
- Phone Number: E.164 format (optional, can configure later)
- DirectLine Secret: From Copilot Studio (optional, can configure later)
Post-deployment steps:
-
Configure phone number and Event Grid (see Phone Number Configuration section below):
- Get a phone number from Azure Communication Services
- Configure Event Grid subscription to route calls to your web app
- Set up webhook endpoint:
https://your-app-name.azurewebsites.net/api/incomingCall
-
Configure Copilot Studio integration (see Copilot Studio Integration):
- Get DirectLine secret from Settings → Security → Web Channel Security
- Add DirectLine secret to Azure Key Vault
- Design voice-friendly conversation topics
-
Use release package for Application Deployment:
- Download the latest release package
- Extract and run
.\scripts\setup-configuration.ps1to configure phone number and DirectLine secret - Run
.\scripts\deploy-application.ps1to deploy your application code
Optional Need detailed configuration guidance? See ARM Template Reference for complete technical details.
Download and deploy using pre-built packages with PowerShell automation:
- Go to GitHub Releases
- Download the latest release ZIP file
- Extract to a local folder
If you don't have Azure resources yet:
# Create all required Azure resources
.\scripts\create-azure-resources.ps1 -ApplicationName "myproject"# Initialize configuration
.\scripts\setup-configuration.ps1
# Deploy application
.\scripts\deploy-application.ps1After deployment, complete these essential steps:
Get a phone number from your Azure Communication Services resource and configure event routing:
- Azure Portal → Communication Services → Your ACS resource
- Phone Numbers → Get a number
-
Choose options:
- Country/Region: Select your region
- Number Type: Local or Toll-free
- Use Case: Application-to-Person (A2P) for bot interactions
- Calling: Enable "Make calls" and "Receive calls"
- Search for available numbers and Add to cart
- Purchase the selected number
Route incoming calls to your ACSforMCS application:
- Azure Portal → Communication Services → Your ACS resource
- Events → Event Subscriptions → Create
-
Configure subscription:
- Name: IncomingCallSubscription
- Event Schema: Event Grid Schema
-
Event Types: Select only
Microsoft.Communication.IncomingCall - Endpoint Type: Web Hook
-
Endpoint:
https://your-app-name.azurewebsites.net/api/incomingCall
- Create the subscription
- Retry Policy: Set Max Event Delivery Attempts to 2
- Event Time to Live: Set to 1 minute (calls only ring for 30 seconds)
- Enable Logging: Configure diagnostic settings for troubleshooting
Configure your bot for telephony:
-
Get DirectLine Secret from your Copilot Studio agent:
- Go to Settings → Security → Web Channel Security
- Copy one of the Secret Keys
-
Configure in Key Vault:
az keyvault secret set --vault-name "your-keyvault" --name "DirectLineSecret" --value "your-secret"
See DirectLine Secret Configuration for detailed bot configuration.
Add your phone number to the application:
az keyvault secret set --vault-name "your-keyvault" --name "AgentPhoneNumber" --value "+1234567890"-
Check application status:
- Visit:
https://your-app-name.azurewebsites.net - Should see: "Hello Azure Communication Services, here is Copilot Studio!"
- Visit:
-
Verify configuration (Development mode):
- Visit:
https://your-app-name.azurewebsites.net/swagger - Use API key from Key Vault secret
HealthCheckApiKey
- Visit:
-
Test phone integration:
- Call your Azure Communication Services phone number
- Should connect to your Copilot Studio agent
In Development mode, monitor active calls:
curl -H "X-API-Key: your-api-key" https://your-app-name.azurewebsites.net/health/calls- Swagger documentation enabled at
/swagger - Health monitoring endpoints enabled
- Detailed logging for debugging
- API key protection for all monitoring endpoints
Switch to production for optimal performance:
.\scripts\switch-to-production.ps1
.\scripts\deploy-application.ps1Production mode:
- Disables Swagger documentation
- Disables monitoring endpoints
- Optimizes logging for performance
- Reduces attack surface
# 1. Create Azure resources
.\scripts\create-azure-resources.ps1 -ApplicationName "myapp"
# 2. Configure application
.\scripts\setup-configuration.ps1
# 3. Deploy
.\scripts\deploy-application.ps1# 1. Configure with existing Key Vault
.\scripts\setup-configuration.ps1 -KeyVaultName "your-keyvault"
# 2. Deploy application
.\scripts\deploy-application.ps1# Check current status
.\scripts\show-environment.ps1
# Switch to development (enables monitoring)
.\scripts\switch-to-development.ps1
# Switch to production (optimizes performance)
.\scripts\switch-to-production.ps1
# Deploy after changes
.\scripts\deploy-application.ps1"Unauthorized" accessing Swagger:
- Get API key:
az keyvault secret show --vault-name "your-kv" --name "HealthCheckApiKey" --query value -o tsv - Add header:
X-API-Key: your-api-key
Phone calls not connecting:
- Verify Event Grid subscription: Check that subscription is active and pointing to correct endpoint
-
Check webhook endpoint URL: Ensure URL format is
https://your-app-name.azurewebsites.net/api/incomingCall - Verify phone number capabilities: Ensure "Receive calls" is enabled for your phone number
- Test Event Grid delivery: Check Event Grid delivery logs in Azure portal
- Validate DirectLine secret: Ensure DirectLine secret is configured correctly in Key Vault
Phone number issues:
- Number not receiving calls: Verify number capabilities include "Receive calls"
- Event Grid delivery failures: Check diagnostic logs in Communication Services Events
- Webhook validation errors: Ensure your application handles EventGrid subscription validation
Configuration errors:
# Validate configuration
.\scripts\setup-configuration.ps1 -ValidateOnly
# Force reconfiguration
.\scripts\setup-configuration.ps1 -ForceKey Vault access denied:
# Get your Object ID and fix access
$objectId = az ad signed-in-user show --query id -o tsv
.\scripts\fix-keyvault-access.ps1 -KeyVaultName "kv-yourproject-prod" -UserObjectId $objectIdAzure CLI authentication:
az login
az account show- Use Standard S1 App Service Plan or higher
- Enable Application Insights for monitoring
- Use Production mode for optimal performance
- Configure auto-scaling based on call volume
- Basic B1 plan minimum for testing
- Keep Development mode enabled for debugging
- Use health endpoints for monitoring
- Enable detailed logging for troubleshooting
- All sensitive configuration stored in Azure Key Vault
- RBAC permissions for Key Vault access
- API key protection for monitoring endpoints
- HTTPS only communication
- Managed Identity for Azure service authentication
- Copilot Studio Integration: Configure your bot agents
- Azure Development: Full development workflow
- Local Development: Development with tunnels
- Code Documentation: Technical implementation details
Ready to configure your bot? Proceed to DirectLine Secret Setup.
- New to ACSforMCS? → Project Purpose
- Ready to deploy? → Quick Installation
- Configure bot? → Copilot Studio Integration
- Development? → Azure Development