-
Notifications
You must be signed in to change notification settings - Fork 208
multiple dial out sample #340
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
v-nyerkala
wants to merge
13
commits into
main
Choose a base branch
from
v-nyerkala/sample/multiple-dial-out
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 7 commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
7bd4456
Initial check-in
v-nyerkala c8472dd
Updated UI
v-nyerkala 50a68b7
Updated code
v-nyerkala 18c5821
Updated code
v-nyerkala fff5391
Updated Code
v-nyerkala 89c9c34
Updated Readme
v-nyerkala 278b001
Update .env - removed sensitive data
v-kuppu 9a9b9ce
Updated readme
v-nyerkala 04d7f22
Moveparticipants Sample - Addressed review comments
v-kuppu e80f383
Merge branch 'main' into v-nyerkala/sample/multiple-dial-out
v-kuppu 203265d
Update .env with placeholder values
v-nyerkala b1f8ab4
Delete add-1-on-1-phone-calling/package-lock.json
v-nyerkala 0eba8b1
Delete callautomation-connect-rooms-quickstart/.env
v-nyerkala File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,6 @@ | ||
| PORT=8080 | ||
| CONNECTION_STRING="<YOUR_CONNECTION_STRING>" | ||
| ACS_RESOURCE_PHONE_NUMBER ="<YOUR_ACS_NUMBER>" | ||
| TARGET_PHONE_NUMBER="<+1XXXXXXXXXX>" | ||
| CALLBACK_URI="<VS_TUNNEL_URL>" | ||
| COGNITIVE_SERVICES_ENDPOINT="<COGNITIVE_SERVICES_ENDPOINT>" | ||
| CONNECTION_STRING="" | ||
| ACS_RESOURCE_PHONE_NUMBER ="" | ||
| TARGET_PHONE_NUMBER="" | ||
| CALLBACK_URI="" | ||
| COGNITIVE_SERVICES_ENDPOINT="" | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| # Ignore node_modules directory | ||
| node_modules/ | ||
|
|
||
| # Ignore environment variables file | ||
| .env | ||
|
|
||
| # Ignore build output directory | ||
| dist/ | ||
| build/ | ||
| public/assets/ | ||
|
|
||
| # Ignore IDE/Editor-specific files | ||
| .vscode/ | ||
| .vs | ||
| .idea/ | ||
|
|
||
| # Ignore user-specific configuration files | ||
| .npmrc | ||
| .gitconfig | ||
|
|
||
| # Ignore log files | ||
| *.log | ||
|
|
||
| # Ignore OS-generated files | ||
| .DS_Store | ||
| Thumbs.db | ||
|
|
||
| # Ignore package lock files | ||
| package-lock.json | ||
| yarn.lock |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,55 @@ | ||
|
|
||
| |page_type|languages|products | ||
| |---|---|---| | ||
| |sample|<table><tr><td>Typescript</tr></td></table>|<table><tr><td>azure</td><td>azure-communication-services</td></tr></table>| | ||
|
|
||
| # Multiple Dial Out using Call Automation SDK | ||
|
|
||
| In this quickstart sample, we cover how you can use the Call Automation SDK to perform multiple dial-outs using Azure Communication Services (ACS) calls. This involves creating and managing several outgoing calls simultaneously and dynamically moving participants between these active calls. | ||
|
|
||
| ## Prerequisites | ||
|
|
||
| - Create an Azure account with an active subscription. For details, see [Create an account for free](https://azure.microsoft.com/free/) | ||
| - [Visual Studio Code](https://code.visualstudio.com/download) installed | ||
| - [Node.js](https://nodejs.org/en/download) installed | ||
| - Create an Azure Communication Services resource. For details, see [Create an Azure Communication Resource](https://docs.microsoft.com/azure/communication-services/quickstarts/create-communication-resource). You will need to record your resource **connection string** for this sample. | ||
| - Get a phone number for your new Azure Communication Services resource. For details, see [Get a phone number](https://learn.microsoft.com/azure/communication-services/quickstarts/telephony/get-phone-number?tabs=windows&pivots=programming-language-csharp) | ||
|
|
||
| ## Before running the sample for the first time | ||
|
|
||
| 1. Open an instance of PowerShell, Windows Terminal, Command Prompt or equivalent and navigate to the directory that you would like to clone the sample to. | ||
| 2. git clone `https://github.com/Azure-Samples/communication-services-javascript-quickstarts.git`. | ||
| 3. cd into the `callautomation-connect-rooms-quickstart` folder. | ||
| 4. From the root of the above folder, and with node installed, run `npm install` | ||
|
|
||
| ### Setup and host your Azure DevTunnel | ||
|
|
||
| [Azure DevTunnels](https://learn.microsoft.com/en-us/azure/developer/dev-tunnels/get-started?tabs=windows) is an Azure service that enables you to share local web services hosted on the internet. Use the commands below to connect your local development environment to the public internet. This creates a tunnel with a persistent endpoint URL and which allows anonymous access. We will then use this endpoint to notify your application of calling events from the ACS Call Automation service. | ||
|
|
||
| ```bash | ||
| devtunnel create --allow-anonymous | ||
| devtunnel port create -p 8080 | ||
| devtunnel host | ||
| ``` | ||
|
|
||
| ### Configuring application | ||
|
|
||
| Create/Open the `.env` file to configure the following settings | ||
|
|
||
| 1. `PORT`: Assign constant 8080 | ||
| 2. `CONNECTION_STRING`: Azure Communication Service resource's connection string. | ||
| 3. `ACS_INBOUND_PHONE_NUMBER`: Inbound Phone number associated with the Azure Communication Service resource. For e.g. "+1425XXXAAAA" | ||
| 4. `ACS_OUTBOUND_PHONE_NUMBER`: Outbound Phone number associated with the Azure Communication Service resource. For e.g. "+1425XXXAAAA" | ||
| 5. `USER_PHONE_NUMBER`: User phone number to add in the call. For e.g. "+1425XXXAAAA" | ||
| 6. `ACS_TEST_IDENTITY_2`: An ACS Communication Identifier to add in the call. | ||
| 7. `ACS_TEST_IDENTITY_3`: Another ACS Communication Identifier to add in the call. | ||
| 8. `CALLBACK_URI`: Base url of the app. (For local development replace the dev tunnel url) | ||
| 9. `COGNITIVE_SERVICES_ENDPOINT` : Cognitive service endpoint. | ||
|
|
||
| ### Run app locally | ||
|
|
||
| 1. Open a new Powershell window, cd into the `callautomation-multiple-dial-out` folder and run `npm run dev` | ||
| 2. Browser should pop up with the below page. If not navigate it to `http://localhost:8080/` | ||
| 3. Follow the steps. | ||
|
|
||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,29 @@ | ||
| { | ||
| "name": "callautomation_connect_rooms", | ||
| "version": "1.0.0", | ||
| "description": "", | ||
| "main": "index.js", | ||
| "scripts": { | ||
| "build": "tsc", | ||
| "dev": "nodemon ./src/app.ts" | ||
| }, | ||
| "keywords": [], | ||
| "author": "", | ||
| "license": "ISC", | ||
| "dependencies": { | ||
| "@azure/communication-call-automation": "^1.5.0", | ||
| "@azure/communication-common": "^2.2.0", | ||
| "@azure/communication-identity": "^1.3.1", | ||
| "@azure/communication-rooms": "^1.1.1", | ||
| "@azure/eventgrid": "^4.12.0", | ||
| "@types/express": "^4.17.17", | ||
| "@types/node": "^20.2.1", | ||
| "dotenv": "^16.0.3", | ||
| "express": "^4.18.2" | ||
| }, | ||
| "devDependencies": { | ||
| "nodemon": "^2.0.22", | ||
| "ts-node": "^10.9.1", | ||
| "typescript": "^5.0.4" | ||
| } | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.