Skip to content
This repository was archived by the owner on Nov 29, 2023. It is now read-only.

Commit c28f33a

Browse files
ckoegelxxlaykxxichesnovajrice6713
authored
DX-2775 Update Voice About Page (#682)
* DX-2775 Update Voice About Page * finish Voice about page * DX-2790 * newline at eof * newlines at eof * remove duplicate voice quick start from sidebar * remove startStream for now * change get started button to stay on same tab * alignment of panels * shadows * prep for splash page changes * DX-2816 Updates to Voice About Page (#706) * e911, edgemanagement, sipauthentication settings api spec (#701) Co-authored-by: ichesnov <[email protected]> * DX-2816 Updates to Voice About Page * workflow * branch * remove workflow change * Update hangup.mdx (#707) Fix a broken hyperlink * add stream panel * workflow * remove branch Co-authored-by: Ivan Chesnov <[email protected]> Co-authored-by: ichesnov <[email protected]> Co-authored-by: AJ Rice <[email protected]> * revert landing page changes * update to docusaurus 2.1 Co-authored-by: Ivan Chesnov <[email protected]> Co-authored-by: ichesnov <[email protected]> Co-authored-by: AJ Rice <[email protected]>
1 parent 030b341 commit c28f33a

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+577
-310
lines changed

site/docs/voice/about.mdx

Lines changed: 77 additions & 96 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
id: about
3-
title: Voice
3+
title: Voice API
44
sidebar_label: About
55
slug: /voice
66
description: A general overview of Bandwidth's Voice API
@@ -11,98 +11,79 @@ hide_title: false
1111
image: '@site/static/img/bw-icon.svg'
1212
---
1313

14-
export const Highlight = ({children, color}) => (
15-
<span
16-
style={{
17-
backgroundColor: color,
18-
borderRadius: '2px',
19-
color: '#fff',
20-
padding: '0.2rem',
21-
}}>
22-
{children}
23-
</span>
24-
);
25-
26-
export const Svg = require('@site/static/img/product-icons/voice.svg').default;
27-
28-
<Svg className='about-image'/> <br/>
29-
30-
The Bandwidth Voice API allows you to handle incoming and outgoing PSTN phone calls using HTTP and JSON webhooks, giving you complete control over any call flow.
31-
32-
## Base URL
33-
34-
`https://voice.bandwidth.com/api/v2/accounts/{accountId}`
35-
36-
**Note** HTTP requests to our API use HTTP Basic authentication, which refers to your account's username and password.
37-
38-
## Calls
39-
40-
For help on how to make the proper requests to the API, check out the [API Reference](/apis/voice#operation/createCall) section of the docs. To quickly start making and receiving calls, check out the [guide](/docs/voice/quickStart).
41-
42-
### Creation/Acceptance
43-
44-
A <Highlight color="#079CEE">POST</Highlight> to [`/calls`](/apis/voice#operation/createCall) creates a call object in Bandwidth's network and returns a unique `callId` corresponding to the new call. When creating a call you provide an `answerUrl` in the request body, and upon the call being answered, Bandwidth will send a webhook to the provided URL to inform your application and retrieve BXML from it in order to continue with the call.
45-
46-
To handle inbound calls to your Bandwidth numbers - you associate a [voice application](/docs/account/dashboard-setup#create-a-voice-application) to a group of numbers, known as a Location or Sip-Peer. When incoming calls are received to any of those numbers, Bandwidth sends an [`initiate`](/docs/voice/webhooks/initiate) event webhook to the URL defined in your application and expects BXML in the HTTP response to continue with the call.
47-
48-
### Call Directions
49-
50-
The direction of which the call is coming from may determine how/where callbacks are sent and whether they may submit more BXML. The direction of a call is either inbound or outbound. Inbound calls refer to calls received by your application, and outbound calls are calls that originate from your application (via API requests or BXML verbs).
51-
52-
### BXML
53-
54-
Bandwidth XML allows you to create a voice application as easily as you create a web application. Using Bandwidth XML (or BXML) your application handles incoming call events using standard action verbs that are described in XML.
55-
56-
When calls or call events occur - Bandwidth will send a request (webhook) to your service, expecting BXML in the HTTP response body to continue the call.
57-
58-
### Webhooks
59-
60-
The Voice API uses a number of different [webhooks](/docs/voice/webhooks) to facilitate call control. Certain webhooks expect BXML in the HTTP response to keep the call alive, while others are simply informative. These are also referred to as "callbacks".
61-
62-
### STIR/SHAKEN
63-
64-
The Bandwidth API uses STIR/SHAKEN to help combat fraudulent calls and phone number spoofing. This info can be seen in the [`initiate`](/docs/voice/webhooks/initiate) webhook. For more information, look [here](https://www.bandwidth.com/regulations/stir-shaken/) for Bandwidth's explanation of what it is and why it's important.
65-
66-
## Features and Services of Note
67-
68-
### Text-to-Speech
69-
70-
Use our [SpeakSentence](/docs/voice/bxml/speakSentence) verb to convert typed words to audible speech on the call. Powered by Amazon Polly, which allows us to support seventeen voices and twenty-six languages. Use [SSML](https://www.w3.org/TR/2010/REC-speech-synthesis11-20100907/) to customize your audio to include pauses, emphasis, and much more.
71-
72-
### Recording
73-
74-
With the [Record](/docs/voice/bxml/record) verb, you can save calls to play back or analyze later.
75-
76-
### Transcription
77-
78-
Convert your calls to text using the [Record](/docs/voice/bxml/record) verb's `transcribe` function.
79-
80-
### Conferencing
81-
82-
The [Conference](/docs/voice/bxml/conference) BXML Verb allows you to create conference calls—including with the [coach](/docs/voice/bxml/conference#join-a-conference-as-a-coach) feature that allows for a call to be selectively bridged with certain calls within a conference.
83-
84-
### Answering Machine Detection
85-
86-
[Answering Machine Detection](/docs/voice/guides/machineDetection) allows you to determine whether a human or a machine has answered a call.
87-
88-
### Caller Name Service (CNAM)
89-
90-
Bandwidth's [Caller Name service](/docs/voice/guides/cnamPerDip) provides the business name on VoIP calls in the US and Canada using our CNAM database. This feature is not enabled by default.
91-
92-
## Storage
93-
94-
### Media
95-
96-
The Voice API allows you to playback audio files to end users on phone calls. Only `.wav` and `.mp3` files are supported at this time and Bandwidth recommends limiting audio files to less than 1 hour in length or 250 MB in size.
97-
98-
### Recordings
99-
100-
Bandwidth will keep recordings for up to 30 days. After 30 days, recordings will be deleted from Bandwidth controlled servers.
101-
102-
### Transcriptions
103-
104-
Bandwidth will keep transcriptions for up to 30 days. After 30 days, transcriptions will be deleted from Bandwidth controlled servers.
105-
106-
## Supported Languages and Environments
107-
108-
SDKs are provided for Java, C#, Ruby, NodeJs, Python, and PHP. Examples of the Bandwidth library in these languages are provided throughout the docs.
14+
import DocsGetStarted from '@site/src/components/DocsGetStarted.js';
15+
import DocsSdks from '@site/src/components/DocsSdks.js';
16+
import DocsFeatures from '@site/src/components/DocsFeatures.js';
17+
import VoiceSvg from '@site/static/img/product-icons/voice.svg'
18+
19+
export const getStarted = {
20+
getStartedText: <p>With Bandwidth's Voice API, you can build a custom voice calling application that accesses our voice network using a HTTPS-based interface.
21+
Embed inbound and outbound voice capabilities via a set of well defined APIs - without the hassle of handling telecom infrastructure.
22+
<br/><br/>
23+
Rapidly develop voice-enabled applications by simply sending and receiving HTTPS requests.
24+
When an incoming call comes into a phone number associated with our Voice API platform, we will notify your application via a webhook event.
25+
Your application can then respond to our platform using Bandwidth XML (BXML) to launch any of our features.</p>,
26+
Svg: VoiceSvg,
27+
getStartedButton: {
28+
link: '/docs/voice/quickStart',
29+
text: 'Get Started'
30+
}
31+
};
32+
33+
export const sdks = {
34+
postmanLink: 'https://www.postman.com/bandwidth/workspace/bandwidth-public-workspace/documentation/13566438-444b67ab-72a9-42dd-bac4-ac9a9d092b13'
35+
};
36+
37+
export const features = {
38+
featuresText: `Our simple, flexible and full-featured Voice API gives you access to all the tools you need with Bandwidth.
39+
We use Bandwidth XML (BXML) so your application handles incoming call events using standard
40+
action verbs that are described in XML allowing you to create custom experiences.`,
41+
panels: [
42+
{
43+
Svg: require('@site/static/img/docs-icons/group-circle.svg').default,
44+
title: 'Conferencing',
45+
text: `2-person call with agent 'whisper' supervision or create up to 20 person conferences.`,
46+
link: '/docs/voice/guides/conference/'
47+
},
48+
{
49+
Svg: require('@site/static/img/docs-icons/phone-message.svg').default,
50+
title: 'Text to Speech',
51+
text: `Multiple languages, voices and SSML markup support including WAV and MP3 audio playback.`,
52+
link: '/docs/voice/guides/mediaAndTTS/'
53+
},
54+
{
55+
Svg: require('@site/static/img/docs-icons/gears.svg').default,
56+
title: 'Interactive Voice Control',
57+
text: `DTMF detection and media capabilities like Text-to-Speech and audio file playback.`,
58+
link: '/docs/voice/guides/interactiveVoiceResponse/'
59+
},
60+
{
61+
Svg: require('@site/static/img/docs-icons/code-video-phone.svg').default,
62+
title: 'Recording & Transcription',
63+
text: `Start and stop recording during a call in both dual-channel and mono recording format with transcription.`,
64+
link: '/docs/voice/guides/recording/'
65+
},
66+
{
67+
Svg: require('@site/static/img/docs-icons/siren.svg').default,
68+
title: 'Answering Machine Detection',
69+
text: `Accurately detect and build flexibility to play TTS or connect a call depending on what or who has answered.`,
70+
link: '/docs/voice/guides/machineDetection'
71+
},
72+
{
73+
Svg: require('@site/static/img/docs-icons/controls.svg').default,
74+
title: 'Media Streaming',
75+
text: `Stream media in real-time over WebSockets to your preferred third-party tools.`,
76+
link: '/docs/voice/bxml/startStream'
77+
},
78+
]
79+
};
80+
81+
<DocsGetStarted {...getStarted}/>
82+
83+
## SDKs
84+
85+
<DocsSdks {...sdks}/>
86+
87+
## Features
88+
89+
<DocsFeatures {...features}/>

site/package.json

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,21 +14,20 @@
1414
"write-heading-ids": "docusaurus write-heading-ids"
1515
},
1616
"dependencies": {
17-
"@docusaurus/core": "^2.0.1",
18-
"@docusaurus/preset-classic": "^2.0.1",
17+
"@algolia/client-search": "^4.9.1",
18+
"@docusaurus/core": "^2.1.0",
19+
"@docusaurus/preset-classic": "^2.1.0",
20+
"@types/react": "^17.0.0",
1921
"buffer": "^6.0.3",
22+
"core-js": "^3.1.4",
2023
"js-yaml": "^4.1.0",
2124
"mobx": "^6.3.0",
2225
"react": "^17.0.1",
2326
"react-dom": "^17.0.1",
27+
"react-is": "^18.1.0",
28+
"react-loadable": "*",
2429
"redoc": "^2.0.0-rc.77",
2530
"styled-components": "^5.2.3",
26-
"//": "dependencies below are not 'required' but are included to remove unmet peer dependency warnings",
27-
"@algolia/client-search": "^4.9.1",
28-
"@types/react": "^17.0.0",
29-
"core-js": "^3.1.4",
30-
"react-loadable": "*",
31-
"react-is": "^18.1.0",
3231
"typescript": "^2.7",
3332
"webpack": "^5.0.0"
3433
},

site/sidebar.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,6 @@ module.exports = {
153153
type: "category",
154154
label: "Guides and Tutorials",
155155
items: [
156-
"voice/quickStart",
157156
"voice/outboundCallGuide",
158157
"voice/mediaAndTTSGuide",
159158
"voice/recordingGuide",

site/src/components/BlueButton.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import React from 'react';
2+
import blueButtonStyles from '@site/src/components/css/BlueButton.module.css';
3+
4+
export default function BlueButton({link, text}) {
5+
return (
6+
<div className={blueButtonStyles.blueButton}>
7+
<a href={link} target="_blank" rel="noopener">{text}</a>
8+
</div>
9+
)
10+
}

site/src/components/DocsFeatures.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
import React from 'react';
2+
import docsAboutStyles from '@site/src/components/css/DocsAbout.module.css';
3+
import FeaturePanels from '@site/src/components/FeaturePanels.js';
4+
5+
export default function DocsFeatures({featuresText, panels}) {
6+
return (
7+
<div className={docsAboutStyles.features}>
8+
<div className={docsAboutStyles.featuresText}>{featuresText}</div>
9+
<FeaturePanels panels={panels}/>
10+
</div>
11+
);
12+
}

site/src/components/DocsGetStarted.js

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import React from 'react';
2+
import docsAboutStyles from '@site/src/components/css/DocsAbout.module.css';
3+
import blueButtonStyles from '@site/src/components/css/BlueButton.module.css';
4+
5+
export default function DocsGetStarted({getStartedText, Svg, getStartedButton}) {
6+
return (
7+
<div className={docsAboutStyles.getStarted}>
8+
<div className={docsAboutStyles.getStartedText}>{getStartedText}</div>
9+
<div className={docsAboutStyles.getStartedImage}><Svg/></div>
10+
<div className={blueButtonStyles.blueButton}>
11+
<a href={getStartedButton.link} rel="noopener">{getStartedButton.text}</a>
12+
</div>
13+
</div>
14+
);
15+
}

site/src/components/DocsSdks.js

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
import React from 'react';
2+
import docsAboutStyles from '@site/src/components/css/DocsAbout.module.css';
3+
4+
5+
const sdks = [
6+
{
7+
link: '/sdks/node',
8+
Svg: require('@site/static/img/sdk-icons/node.svg').default
9+
},
10+
{
11+
link: '/sdks/python',
12+
Svg: require('@site/static/img/sdk-icons/python.svg').default
13+
},
14+
{
15+
link: '/sdks/java',
16+
Svg: require('@site/static/img/sdk-icons/java.svg').default
17+
},
18+
{
19+
link: '/sdks/php',
20+
Svg: require('@site/static/img/sdk-icons/php.svg').default
21+
},
22+
{
23+
link: '/sdks/ruby',
24+
Svg: require('@site/static/img/sdk-icons/ruby.svg').default
25+
},
26+
{
27+
link: '/sdks/csharp',
28+
Svg: require('@site/static/img/sdk-icons/csharp.svg').default
29+
}
30+
]
31+
32+
export default function DocsSdks({postmanLink}) {
33+
return (
34+
<div className={docsAboutStyles.sdks}>
35+
<div className={docsAboutStyles.sdksText}>
36+
With a few lines of code we will show you how to use our REST APIs and webhooks through our docs,
37+
code samples and SDKs to build your application.
38+
Select the SDK of your choice or start testing with our <a className={docsAboutStyles.postmanLink} href={postmanLink} target="_blank" rel="noopener">Postman Collection</a> straight away.
39+
</div>
40+
<div className={docsAboutStyles.sdksImages}>
41+
<div className={docsAboutStyles.sdkImageContainer}>
42+
{sdks.map(({link, Svg}, idx) => (
43+
<a key={idx} href={link}><Svg/></a>
44+
))}
45+
</div>
46+
</div>
47+
</div>
48+
);
49+
}

site/src/components/FeaturePanels.js

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
import React from 'react';
2+
import featurePanelStyles from '@site/src/components/css/FeaturePanel.module.css';
3+
4+
function FeaturePanel({Svg, title, text, link}) {
5+
return (
6+
<a className={featurePanelStyles.panel} href={link}>
7+
<div className={featurePanelStyles.header}>
8+
<Svg className={featurePanelStyles.icon}/>
9+
<div className={featurePanelStyles.title}>{title}</div>
10+
</div>
11+
<div className={featurePanelStyles.content}>
12+
<div className={featurePanelStyles.panelText}>{text}</div>
13+
</div>
14+
</a>
15+
);
16+
}
17+
18+
export default function FeaturePanels({panels}) {
19+
return (
20+
<div className={featurePanelStyles.panelsContainer}>
21+
{panels.map((props, idx) => (
22+
<FeaturePanel key={idx} {...props}/>
23+
))}
24+
</div>
25+
);
26+
}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/* Blue Button CSS */
2+
3+
.blueButton {
4+
width: 100%;
5+
height: auto;
6+
display: flex;
7+
8+
}
9+
10+
.blueButton a {
11+
background-color: var(--bwBlue);
12+
border-radius: 20px;
13+
color: #FFFFF2;
14+
font-size: 12px;
15+
font-family: 'Overpass Bold';
16+
text-transform: uppercase;
17+
line-height: 18px;
18+
letter-spacing: .1em;
19+
text-decoration: none;
20+
padding: 12px 30px;
21+
}

0 commit comments

Comments
 (0)