CINXE.COM

Google Dialogflow CX and Deepgram — Deepgram | Documentation

<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><script id="_fern-gtm"> (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start': new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0], j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src= 'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f); })(window,document,'script','dataLayer','GTM-M5WQMGR'); </script><link rel="preload" href="/api/fern-docs/search/v1/key" as="fetch" crossorigin="anonymous"/><link rel="preload" href="/api/fern-docs/auth/api-key-injection" as="fetch" crossorigin="anonymous"/><meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"/><title>Google Dialogflow CX and Deepgram — Deepgram | Documentation</title><meta name="robots" content="index,follow"/><meta name="description" content="Dialogflow CX is a framework for building virtual agents. Learn how to incorporate Deepgram&#x27;s transcription and text-to-speech for improved accuracy."/><meta name="theme-color" content="#1a1a1f"/><meta property="og:title" content="Google Dialogflow CX and Deepgram — Deepgram | Documentation"/><meta property="og:description" content="Dialogflow CX is a framework for building virtual agents. Learn how to incorporate Deepgram&#x27;s transcription and text-to-speech for improved accuracy."/><meta property="og:url" content="https://developers.deepgram.com/docs/use-deepgram-with-dialogflow-cx"/><meta property="og:site_name" content="Deepgram | Documentation"/><link rel="canonical" href="https://developers.deepgram.com/docs/use-deepgram-with-dialogflow-cx"/><meta name="generator" content="buildwithfern.com"/><link rel="icon" href="https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/favicon.ico" crossorigin="anonymous"/><link rel="preload" href="https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/Inter.woff2" as="font" type="font/woff2" crossorigin="anonymous"/><link rel="preload" href="https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/FiraMono.woff2" as="font" type="font/woff2" crossorigin="anonymous"/><link rel="preload" href="https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/Roobert.woff2" as="font" type="font/woff2" crossorigin="anonymous"/><script type="application/ld+json" id="jsonld-breadcrumb">{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Deepgram | Documentation","item":"https://developers.deepgram.com/"},{"@type":"ListItem","position":2,"name":"Guides","item":"https://developers.deepgram.com/docs"},{"@type":"ListItem","position":3,"name":"Integrations","item":"https://developers.deepgram.com/docs/integrations"},{"@type":"ListItem","position":4,"name":"Google Dialogflow CX and Deepgram","item":"https://developers.deepgram.com/docs/use-deepgram-with-dialogflow-cx"}]}</script><link rel="preload" href="https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/logo.svg" as="image" fetchpriority="high"/><meta name="next-head-count" content="21"/><link href="https://cdn.jsdelivr.net/npm/katex@0.16.8/dist/katex.min.css" rel="stylesheet"/><script id="theme-script" data-nscript="beforeInteractive">(e=>{let t=document.documentElement;function n(e){t.classList.remove("light","dark"),t.classList.add(e),t.style.colorScheme=e}if(1===e.length)n(e[0]);else try{let t=localStorage.getItem("theme")??"system",r=e.length>0&&"system"===t?window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light":t;n(r)}catch{}})(["dark"])</script><link rel="preload" href="https://app.ferndocs.com/_next/static/css/b5ef68ada6ac4b07.css?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt" as="style"/><link rel="stylesheet" href="https://app.ferndocs.com/_next/static/css/b5ef68ada6ac4b07.css?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt" data-n-g=""/><link rel="preload" href="https://app.ferndocs.com/_next/static/css/80bca615e6d01b34.css?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt" as="style"/><link rel="stylesheet" href="https://app.ferndocs.com/_next/static/css/80bca615e6d01b34.css?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="https://app.ferndocs.com/_next/static/chunks/polyfills-78c92fac7aa8fdd8.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script src="https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/dist/output.js" type="module" defer="" data-nscript="beforeInteractive"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/8494.89309af69f67ac9d.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/7191.7664a652cf78e25c.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/9862.425ab7b1c7aa2bbe.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/45bb0db8.463a392675fecfb0.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/92e66809.393f81705c519a34.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/118f301d.0a7382916ef4ac18.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/52d2be3c.b954481fe5a6d824.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/f29dc6a8.0d3c3c8683df2eda.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/6003.c51da136c4cdc4e2.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/8950.bc07b3e1c13f1432.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/5717.a121432bdbac2575.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/3970.c2fe78b12d70f6c5.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/600.9e9db95b2c541679.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/3551.f273dcadace15afb.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/f136264b.fe05aaa57e22d479.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/4217.08fff909190d4e30.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/2729.42c77bdb2d91a65d.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/9042.326e31070d76df17.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/8326.bde182ef6c372b2f.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/6318.58ee0f53c459a73e.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/8508.7a6ed07aa65989af.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/5119.7fbcb17fea114486.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/5438.9dfc11fa11c8ee42.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/6770.7f324a0184155c4e.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/7708.bec065f6e20bb795.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/a20b1002.4488a96695dd3fd2.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/5653.ba43092f7e682928.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/4471.ccd5aeba70bc8ffb.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/7679.47196e74655aa33f.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/4938.1396ed581cf45ffd.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/1017.33e29a306ce9b285.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/3543.329adf52c784d779.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script defer="" src="https://app.ferndocs.com/_next/static/chunks/7575.924e50684a873f53.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt"></script><script src="https://app.ferndocs.com/_next/static/chunks/webpack-08f362e6cd5268e7.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt" defer=""></script><script src="https://app.ferndocs.com/_next/static/chunks/framework-66d89474ad83799b.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt" defer=""></script><script src="https://app.ferndocs.com/_next/static/chunks/main-8bc5002bdb8afd00.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt" defer=""></script><script src="https://app.ferndocs.com/_next/static/chunks/pages/_app-817872fd2c495d6b.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt" defer=""></script><script src="https://app.ferndocs.com/_next/static/chunks/2709-cda5da4a8db8de58.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt" defer=""></script><script src="https://app.ferndocs.com/_next/static/chunks/6053-736813b84433ca4a.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt" defer=""></script><script src="https://app.ferndocs.com/_next/static/chunks/pages/static/%5Bdomain%5D/%5B%5B...slug%5D%5D-31f428dae64597dc.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt" defer=""></script><script src="https://app.ferndocs.com/_next/static/jigMgAOOAbh4GA_fJkAR-/_buildManifest.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt" defer=""></script><script src="https://app.ferndocs.com/_next/static/jigMgAOOAbh4GA_fJkAR-/_ssgManifest.js?dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt" defer=""></script><style id="__jsx-164275153"> :root { --typography-body-font-family: 'Inter', -apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,sans-serif; --typography-heading-font-family: 'Roobert', -apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,sans-serif; --typography-code-font-family: 'FiraMono', ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace; --spacing-page-width: 100%; --spacing-content-width: 44rem; --spacing-content-wide-width: 66.5rem; --spacing-sidebar-width: 18rem; --spacing-header-height: 6.75rem; --spacing-header-height-padded: 5rem; --spacing-header-height-real: 4rem; --grayscale-1: var(--mauve-1); --grayscale-2: var(--mauve-2); --grayscale-3: var(--mauve-3); --grayscale-4: var(--mauve-4); --grayscale-5: var(--mauve-5); --grayscale-6: var(--mauve-6); --grayscale-7: var(--mauve-7); --grayscale-8: var(--mauve-8); --grayscale-9: var(--mauve-9); --grayscale-10: var(--mauve-10); --grayscale-11: var(--mauve-11); --grayscale-12: var(--mauve-12); --grayscale-a1: var(--mauve-a1); --grayscale-a2: var(--mauve-a2); --grayscale-a3: var(--mauve-a3); --grayscale-a4: var(--mauve-a4); --grayscale-a5: var(--mauve-a5); --grayscale-a6: var(--mauve-a6); --grayscale-a7: var(--mauve-a7); --grayscale-a8: var(--mauve-a8); --grayscale-a9: var(--mauve-a9); --grayscale-a10: var(--mauve-a10); --grayscale-a11: var(--mauve-a11); --grayscale-a12: var(--mauve-a12); --accent-1: #f7f7f9; --accent-2: #f1f3f9; --accent-3: #e8ebf7; --accent-4: #dde2f9; --accent-5: #d0d7f8; --accent-6: #c0c8f3; --accent-7: #abb5eb; --accent-8: #8f9be2; --accent-9: #7783f7; --accent-10: #6c77e9; --accent-11: #5158c3; --accent-12: #282c5f; --accent-a1: #7a3b7c04; --accent-a2: #1734c309; --accent-a3: #0926c312; --accent-a4: #0327ea1d; --accent-a5: #0126e92a; --accent-a6: #0322d93b; --accent-a7: #011ec950; --accent-a8: #011cc16d; --accent-a9: #0217f486; --accent-a10: #0214dc91; --accent-a11: #020ca8ad; --accent-a12: #010642d7; --accent-surface: #eff1f9cc; --gray-surface: #ffffffcc; --accent: 119, 131, 247; --accent-aa: 81, 96, 245; --accent-aaa: 32, 52, 243; --accent-tinted: 143, 153, 248; --background: 249, 250, 251; --accent-contrast: rgb(255, 255, 255); --bg-color-card: rgba(255, 255, 255, 0.7); --sidebar-background: transparent; --header-background: transparent; --border: var(--grayscale-a4); --border-concealed: var(--grayscale-a2); --body-text: 0, 0, 0; --body-text-inverted: 255, 255, 255; } @media (max-width: 1024px) { :root { --spacing-header-height: 6.75rem; --spacing-header-height-padded: 5rem; } } :is(.dark) { --grayscale-1: var(--gray-1); --grayscale-2: var(--gray-2); --grayscale-3: var(--gray-3); --grayscale-4: var(--gray-4); --grayscale-5: var(--gray-5); --grayscale-6: var(--gray-6); --grayscale-7: var(--gray-7); --grayscale-8: var(--gray-8); --grayscale-9: var(--gray-9); --grayscale-10: var(--gray-10); --grayscale-11: var(--gray-11); --grayscale-12: var(--gray-12); --grayscale-a1: var(--gray-a1); --grayscale-a2: var(--gray-a2); --grayscale-a3: var(--gray-a3); --grayscale-a4: var(--gray-a4); --grayscale-a5: var(--gray-a5); --grayscale-a6: var(--gray-a6); --grayscale-a7: var(--gray-a7); --grayscale-a8: var(--gray-a8); --grayscale-a9: var(--gray-a9); --grayscale-a10: var(--gray-a10); --grayscale-a11: var(--gray-a11); --grayscale-a12: var(--gray-a12); --accent-1: #050d0a; --accent-2: #0f1a15; --accent-3: #092d21; --accent-4: #003d29; --accent-5: #004b34; --accent-6: #005a40; --accent-7: #006b4d; --accent-8: #00805b; --accent-9: #a1f9d4; --accent-10: #97efca; --accent-11: #66cfa6; --accent-12: #9df5d0; --accent-a1: #00b50003; --accent-a2: #4bfb9c10; --accent-a3: #00fca124; --accent-a4: #00fc9735; --accent-a5: #00ffa543; --accent-a6: #00feac53; --accent-a7: #00fdb165; --accent-a8: #00fdb07b; --accent-a9: #a5ffd9f9; --accent-a10: #a0fed6ef; --accent-a11: #7dffcccd; --accent-a12: #a3ffd8f5; --accent-surface: color(display-p3 0.0863 0.1569 0.1255 / 0.5); --gray-surface: color(display-p3 0 0 0 / 5%); --accent: 161, 249, 212; --accent-aa: 161, 249, 212; --accent-aaa: 161, 249, 212; --accent-tinted: 185, 251, 223; --background: 11, 11, 12; --accent-contrast: rgb(11, 40, 29); --bg-color-card: rgb(26, 26, 31); --bg-color-card-solid: rgb(26, 26, 31); --sidebar-background: rgb(11, 11, 12); --header-background: rgb(26, 26, 31); --border: rgb(44, 44, 51); --border-concealed: rgb(44, 44, 51); --body-text: 255, 255, 255; --body-text-inverted: 0, 0, 0; } @font-face { font-family: 'Inter'; src: url('https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/Inter.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; } @font-face { font-family: 'Roobert'; src: url('https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/Roobert.woff2') format('woff2'); font-weight: 600 900; font-style: normal; font-display: swap; } @font-face { font-family: 'FiraMono'; src: url('https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/FiraMono.woff2') format('woff2'); font-weight: 100 900; font-style: normal; font-display: swap; } html { background-color: #f9fafb; } html.dark { background-color: #0b0b0c; } .fern-button.filled { background: linear-gradient(90deg, #201CFF -91.5%, #13EF95 80.05%) !important; } .fern-header-tab-button[data-state=active] { color: white !important; } .fern-header-tab-button[data-state=active]:after { background: linear-gradient(90deg, #201CFF -91.5%, #13EF95 80.05%) !important; height: 2px !important; } .fern-header-tab-button { padding-left: 24px !important; padding-right: 24px !important; } @media (max-width: 1350px) { .fern-header-tab-button { padding-left: 16px !important; padding-right: 16px !important; } } @media (max-width: 1185px) { .fern-header-tab-button { padding-left: 12px !important; padding-right: 12px !important; } } @media (max-width: 1100px) { .fern-header-tab-button { padding-left: 8px !important; padding-right: 8px !important; } } .fern-mdx-link { color: #79affa !important; text-decoration: none; } .fern-mdx-link svg { color: #79affa !important; } .white .fern-card span { background: white !important; } @media (min-width: 1024px) { .fern-header-right-menu { display: none !important; } } .banner { display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; } .banner p { margin-top: .25rem; margin-bottom: .25rem; } .banner h1 { margin-top: .5rem; margin-bottom: 16px; } .fern-sidebar-link-container[data-state="active"] { color: white !important; } .fern-sidebar-link-text { font-size: 16px !important; } .fern-sidebar-link-container[data-state=active] .fern-sidebar-link-indent:after { border: 0px !important; } .fern-sidebar-link-container[data-state="active"] .fern-sidebar-link { background-color: #232329 !important; } .fern-sidebar-link-container[data-state="active"] .fern-sidebar-link:after { background: linear-gradient(177.85deg, #201CFF -102.27%, #13EF95 101.45%) !important; width: 1px !important; position: absolute !important; content: "" !important; right: 0 !important; top: 0 !important; bottom: 0 !important; border-radius: 8px !important; } .fern-sidebar-link { border-radius: 0 !important; } .fern-sidebar-link-content { padding-left: 1rem !important; padding-right: 1rem !important; padding-top: 0.5rem !important; padding-bottom: 0.5rem !important; } .fern-sidebar-content { padding-left: 0 !important; padding-right: 0 !important; } @media (min-width: 1024px) { .fern-sidebar-container:not(.fern-sidebar-fixed) { padding-left: 0rem !important; } } .fern-header-tab-button span { font-weight: 700 !important; font-size: 16px !important; line-height: 17.5px !important; letter-spacing: 2% !important; } .fern-search-bar { --tw-ring-color: #4E4E52 !important; background-color: #0B0B0C !important; } .fern-sidebar-heading-content, .fern-sidebar-link-container .font-semibold .fern-sidebar-link-text { font-weight: 700 !important; font-size: 14px !important; line-height: 17.5px !important; letter-spacing: 2% !important; color: #A1F9D4 !important; } .fern-breadcrumb-item { color: var(--grayscale-a11) !important; font-weight: 400 !important; } button[role="tab"][data-state="active"] { background-color: #1A1A1F !important; } button[role="tab"][data-state="active"]:after { background: linear-gradient(90deg, #201CFF -91.5%, #13EF95 80.05%) !important; height: 2px !important; position: absolute !important; content: "" !important; right: 0 !important; left: 0 !important; bottom: 0 !important; } button[role="tab"] { box-shadow: none !important; position: relative !important; } button[role="tab"]:hover span { background-color: #1A1A1F !important; } div[class*="callout"] { border-left-width: 2px !important; border-color: var(--tw-ring-color) !important; } .fern-search-bar, .callout-outlined, .fern-card .fern-button { border-radius: 8px !important; } .bg-tag-default-soft { background-color: #28282B !important; } .code-block-root span[style*="color: rgb(194, 195, 197);"] { --shiki-dark: #949498 !important; } .callout-outlined { background-color: #1D2A34 !important; --tw-ring-color: #149AFB !important; } .callout-outlined-warning { background-color: #342D1E !important; --tw-ring-color: #FEC84B !important; } .callout-outlined p, .callout-outlined h5, .callout-outlined-warning p, .callout-outlined-warning h5, .callout-outlined-success p, .callout-outlined-success h5, .callout-outlined-danger p, .callout-outlined-danger h5, .callout-outlined-info p, .callout-outlined-info h5, .callout-outlined-tip p, .callout-outlined-tip h5, .callout-outlined-primary p, .callout-outlined-primary h5, .callout-outlined-check p, .callout-outlined-check h5, .callout-outlined-secondary p, .callout-outlined-warning li { color: var(--grayscale-a11) !important; } .callout-outlined li { margin-top: 0px !important; } .callout-outlined h2 { margin-top: 0px !important; } .callout-outlined-warning h2 { margin-top: 0px !important; } .logs { background-color: #0b0b0c !important; padding: 0.5rem !important; font-family: var(--typography-code-font-family, var(--code-font-fallback)); } div[class*="callout"] .mt-0\.5.w-4 { align-self: center !important; } span[data-badge-type="http-method"], span[data-badge-type="status-code"] { border-radius: 50px !important; } .dg-badge { margin-right: 6px !important; color: #bbbbbf !important; padding: 1px 1px !important; text-decoration: none !important; border-radius: 4px !important; background-origin: border-box !important; background-image: linear-gradient(90deg, #201cff -91.5%, #13ef95 80.05%); display: flex; align-items: center; justify-content: center; width: fit-content; height: fit-content; } .dg-badge span { background-color: #1A1A1F !important; padding: 4px 12px !important; border-radius: 4px !important; display: flex; align-items: center; justify-content: center; } .dg-badge .fa-icon { background: linear-gradient(90deg, #201cff -91.5%, #13ef95 80.05%); margin-right: 4px !important; } .fern-card { background-color: #0B0B0C !important; border-radius: 8px !important; } ol li { margin-top: 2rem !important; } .small .fern-card { padding-bottom: 1rem !important; padding-top: 1rem !important; } .small .fern-card .items-start { align-items: center !important; } .small .fern-card .text-base { color: #BBBBBF !important; font-weight: 600 !important; } .fern-card h3 { margin-top: 0px !important; } .fern-sidebar-tabs { padding-left: 10px !important; } .fern-sidebar-heading { padding-left: 28px !important; } .api-playground-call { width: fit-content !important; height: fit-content !important; display: flex !important; align-items: center !important; justify-content: center !important; padding: 1px !important; border-radius: 4px !important; background-image: linear-gradient(82.38deg, #ff2eea -99.24%, #4b3cff 99.26%) !important; width: 100% !important; margin-top: 1rem !important; } .api-playground-call span:first-child { display: flex !important; align-items: center !important; gap: 12px !important; background-color: #1A1A1F !important; padding: 4px !important; border-radius: 4px !important; width: 100% !important; flex-direction: row !important; } .api-playground-call p { margin: 0 !important; display: flex !important; align-items: center !important; white-space: nowrap !important; } .api-playground-call p div:first-child { display: inline-flex !important; align-items: center !important; } .api-playground-call img { width: 2.5rem !important; height: 2.5rem !important; display: inline-block !important; margin-top: 4px !important; margin-bottom: 4px !important; transform: scaleX(-1) !important; } .invert-white { filter: invert(1) !important; } .fa-icon, .card-icon { width: 2rem !important; height: 2rem !important; } .dg-badge .fa-icon { width: 1rem !important; height: 1rem !important; } .fern-header, .fern-header-tabs { border-bottom-width: 0px !important; } .fern-header-tabs-list-item span { font-family: 'Roobert' !important; } .fern-header-tabs-list, .fern-header-tabs-list-item { height: 100% !important; } .fern-sidebar-link-indent { margin-left: 20px !important; } .fern-sidebar-link-container[data-state=inactive] .fern-sidebar-link:hover { color: #FBFBFF !important; } .t-muted:is(.dark *) { color: #949498 !important; } .dark\:prose-invert:is(.dark *) { --tw-prose-headings: #FBFBFF !important; color: #E1E1E5 !important; } .fern-page-heading * { color: #FBFBFF !important; } .badge a { text-decoration: none !important; color: unset !important; } .badge svg { display: none !important; } .dep { background: #bbbbbf !important; } .dep .fa-icon { background: #bbbbbf !important; } .dep span { text-decoration: line-through !important; } .pink { background-image: linear-gradient(85deg, #ee028b 5.66%, #ae29ff 99.14%) !important; } .pink .fa-icon { background: linear-gradient(85deg, #ee028b 5.66%, #ae29ff 99.14%) !important; } #fern-header { padding-top: 3rem !important; } .fern-sidebar-container { position: sticky !important; top: 0 !important; margin-top: 10rem !important; overflow-y: auto !important; z-index: 20 !important; height: 100vh !important; } .fern-main { margin-top: calc(var(--header-offset, 0) + 3rem) !important; } .fern-endpoint-content-right .fa-icon, .fern-dropdown-item .fa-icon { width: 1rem !important; height: 1rem !important; } .fern-endpoint-content { padding-top: 3rem !important; } #fern-header { position: absolute !important; } div[id="/reference/speech-to-text-api/listen#request"] .flex.flex-col div:nth-of-type(4) span:nth-of-type(2) { display: none !important; } div[id="/reference/speech-to-text-api/listen#request"] .flex.flex-col div:nth-of-type(4) span:nth-of-type(1):after { content: " binary" !important; color: #949498 !important; font-size: .75rem; line-height: 1rem; font-family: 'Inter' !important; text-shadow: 0 1px 3px rgba(0, 0, 0, .4); margin-left: .5rem; } #fern-header { position: absolute !important; } .fern-sidebar-fixed+.fern-main { padding-left: 0px !important; } .api-playground-call a { padding-left: 4px !important; padding-right: 4px !important; color: #79affa !important; text-decoration: none !important; } *,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.tw-absolute{position:absolute}.tw-relative{position:relative}.tw-inset-x-0{left:0;right:0}.tw-top-0{top:0}.tw-z-30{z-index:30}.tw-mx-auto{margin-left:auto;margin-right:auto}.tw-flex{display:flex}.tw-w-full{width:100%}.tw-max-w-\[var\(--spacing-page-width\)\]{max-width:var(--spacing-page-width)}.tw-items-center{align-items:center}.tw-justify-end{justify-content:flex-end}.tw-gap-2{gap:.5rem}.tw-gap-3{gap:.75rem}.tw-rounded-md{border-radius:.375rem}.tw-bg-\[\#232329\]{--tw-bg-opacity: 1;background-color:rgb(35 35 41 / var(--tw-bg-opacity))}.tw-px-3{padding-left:.75rem;padding-right:.75rem}.tw-px-4{padding-left:1rem;padding-right:1rem}.tw-py-2{padding-top:.5rem;padding-bottom:.5rem}.tw-text-\[\#BBBBBF\]{--tw-text-opacity: 1;color:rgb(187 187 191 / var(--tw-text-opacity))}.tw-backdrop-blur-2xl{--tw-backdrop-blur: blur(40px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}#fern-header a{font-size:16px!important;font-family:Inter,sans-serif!important}@media (min-width: 768px){.md\:tw-px-6{padding-left:1.5rem;padding-right:1.5rem}}@media (min-width: 1024px){.lg\:tw-px-8{padding-left:2rem;padding-right:2rem}} </style><style id="__jsx-1533687371">:root{ --header-offset: 108px}@media(max-width:1024px){:root{--header-offset:64px}}</style></head><body class="antialiased"><div id="__next"><noscript id="_fern-gtm-noscript"><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M5WQMGR" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript><div class="fern-background dark:from-transparent"></div><div id="fern-docs" class="fern-container fern-theme-default"><header id="fern-header" role="banner"><div class="fern-header-container width-before-scroll-bar has-background-dark" data-border="hide"><div class="clipped-background"><div class="h-screen opacity-60 dark:opacity-80 fern-background dark:from-transparent"></div></div><div class="fern-header"><nav aria-label="primary" class="fern-header-content max-w-page-width mx-auto"><div class="relative flex h-full min-w-fit flex-1 shrink-0 items-center gap-2 py-1"><div class="flex items-center gap-2"><a href="/"><div class="fern-logo-container"><img alt="Deepgram | Documentation" fetchpriority="high" loading="eager" width="176" height="25" decoding="async" data-nimg="1" class="fern-logo" style="color:transparent;aspect-ratio:7.04;height:24px;width:auto" src="https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/logo.svg"/></div></a></div></div><div class="fern-header-searchbar"><button id="fern-search-button" class="fern-search-bar w-full" disabled=""><span class="search-placeholder"><svg width="1.5em" height="1.5em" viewBox="0 0 24 24" stroke-width="1.5" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="size-icon-md"><path d="M17 17L21 21" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M3 11C3 15.4183 6.58172 19 11 19C13.213 19 15.2161 18.1015 16.6644 16.6493C18.1077 15.2022 19 13.2053 19 11C19 6.58172 15.4183 3 11 3C6.58172 3 3 6.58172 3 11Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path></svg><span>Search...</span></span><kbd class="keyboard-shortcut-hint">/</kbd></button></div><div class="fern-header-right-menu flex-1"><div class="lg-menu"><span class="fern-button-group"></span></div><div class="max-lg-menu"><button tabindex="0" disabled="" data-state="off" aria-disabled="true" data-selected="false" id="fern-search-button" class="max-sm:block fern-button minimal large disabled rounded square"><span class="fern-button-content"><svg width="1.5em" height="1.5em" viewBox="0 0 24 24" stroke-width="1.5" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="!size-icon-md"><path d="M17 17L21 21" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M3 11C3 15.4183 6.58172 19 11 19C13.213 19 15.2161 18.1015 16.6644 16.6493C18.1077 15.2022 19 13.2053 19 11C19 6.58172 15.4183 3 11 3C6.58172 3 3 6.58172 3 11Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path></svg></span></button><button tabindex="0" data-state="off" aria-disabled="false" class="fern-button minimal large rounded square"><span class="fern-button-content"><svg width="1.5em" height="1.5em" stroke-width="1.5" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="!size-icon-md"><path d="M3 5H21" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M3 12H21" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M3 19H21" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path></svg></span></button></div></div></nav></div><nav aria-label="tabs" class="fern-header-tabs"><ul class="fern-header-tabs-list"><li class="fern-header-tabs-list-item"><a class="fern-header-tab-button" data-state="inactive" href="/home/introduction"><div class="flex min-w-0 items-center justify-start space-x-2"><span class="truncate font-medium">Home</span></div></a></li><li class="fern-header-tabs-list-item"><a class="fern-header-tab-button" data-state="inactive" href="/docs/voice-agent"><div class="flex min-w-0 items-center justify-start space-x-2"><span class="truncate font-medium">Voice Agent</span></div></a></li><li class="fern-header-tabs-list-item"><a class="fern-header-tab-button" data-state="inactive" href="/docs/pre-recorded-audio"><div class="flex min-w-0 items-center justify-start space-x-2"><span class="truncate font-medium">Speech to Text</span></div></a></li><li class="fern-header-tabs-list-item"><a class="fern-header-tab-button" data-state="inactive" href="/docs/tts-rest"><div class="flex min-w-0 items-center justify-start space-x-2"><span class="truncate font-medium">Text to Speech</span></div></a></li><li class="fern-header-tabs-list-item"><a class="fern-header-tab-button" data-state="inactive" href="/docs/audio-intelligence"><div class="flex min-w-0 items-center justify-start space-x-2"><span class="truncate font-medium">Intelligence</span></div></a></li><li class="fern-header-tabs-list-item"><a class="fern-header-tab-button" data-state="inactive" href="/reference/deepgram-api-overview"><div class="flex min-w-0 items-center justify-start space-x-2"><span class="truncate font-medium">API Ref</span></div></a></li><li class="fern-header-tabs-list-item"><a class="fern-header-tab-button" data-state="active" href="/docs/make-your-first-api-request"><div class="flex min-w-0 items-center justify-start space-x-2"><span class="truncate font-medium">Guides</span></div></a></li><li class="fern-header-tabs-list-item"><a class="fern-header-tab-button" data-state="inactive" href="/docs/deepgram-sdks"><div class="flex min-w-0 items-center justify-start space-x-2"><span class="truncate font-medium">SDKs</span></div></a></li><li class="fern-header-tabs-list-item"><a class="fern-header-tab-button" data-state="inactive" href="/docs/self-hosted-introduction"><div class="flex min-w-0 items-center justify-start space-x-2"><span class="truncate font-medium">Self-Hosted Deployments</span></div></a></li><li class="fern-header-tabs-list-item"><a class="fern-header-tab-button" data-state="inactive" href="/docs/security-policy"><div class="flex min-w-0 items-center justify-start space-x-2"><span class="truncate font-medium">Security</span></div></a></li></ul></nav></div></header><style> .fern-sidebar-container { border-right-width: 0px; border-left-width: 0px; } :is(.dark) .fern-sidebar-container { border-right-width: 1px; border-left-width: 1px; } </style><div class="fern-body"><nav aria-label="secondary" class="fern-sidebar-container desktop fern-sidebar-fixed"><div dir="ltr" class="fern-scroll-area flex-1" style="position:relative;--radix-scroll-area-corner-width:0px;--radix-scroll-area-corner-height:0px"><style>[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}</style><div data-radix-scroll-area-viewport="" class="fern-scroll-area-viewport group/sidebar fern-sidebar-content" data-scrollbars="vertical" style="overflow-x:hidden;overflow-y:hidden"><div style="min-width:100%;display:table"><ul class="fern-sidebar-tabs lg:hidden"><li><a class="min-h-[32px] lg:min-h-[36px] group/tab-button hover:t-accent flex min-w-0 flex-1 select-none items-center justify-start rounded-lg py-2 text-base group-hover/tab-button:transition lg:px-3 lg:text-sm data-[state=inactive]:t-muted data-[state=active]:t-accent" data-state="inactive" href="/home/introduction"><div class="flex min-w-0 items-center justify-start space-x-4"><div class="min-w-fit"><div class="bg-card-surface ring-border-default group-hover/tab-button:bg-tag-primary group-hover/tab-button:ring-accent/70 group-data-[state=active]/tab-button:bg-accent group-hover/tab-button:group-data-[state=active]/tab-button:bg-accent flex size-6 items-center justify-center rounded-md shadow-sm ring-1 group-data-[state=active]/tab-button:ring-0"><span class="bg-faded group-hover/tab-button:bg-accent group-data-[state=active]/tab-button:bg-background group-hover/tab-button:group-data-[state=active]/tab-button:bg-background size-4 fa-icon" style="mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);mask-repeat:no-repeat;mask-position:center center;-webkit-mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);-webkit-mask-repeat:no-repeat;-webkit-mask-position:center center"></span></div></div><span class="truncate font-medium group-data-[state=active]/tab-button:font-semibold">Home</span></div></a></li><li><a class="min-h-[32px] lg:min-h-[36px] group/tab-button hover:t-accent flex min-w-0 flex-1 select-none items-center justify-start rounded-lg py-2 text-base group-hover/tab-button:transition lg:px-3 lg:text-sm data-[state=inactive]:t-muted data-[state=active]:t-accent" data-state="inactive" href="/docs/voice-agent"><div class="flex min-w-0 items-center justify-start space-x-4"><div class="min-w-fit"><div class="bg-card-surface ring-border-default group-hover/tab-button:bg-tag-primary group-hover/tab-button:ring-accent/70 group-data-[state=active]/tab-button:bg-accent group-hover/tab-button:group-data-[state=active]/tab-button:bg-accent flex size-6 items-center justify-center rounded-md shadow-sm ring-1 group-data-[state=active]/tab-button:ring-0"><span class="bg-faded group-hover/tab-button:bg-accent group-data-[state=active]/tab-button:bg-background group-hover/tab-button:group-data-[state=active]/tab-button:bg-background size-4 fa-icon" style="mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);mask-repeat:no-repeat;mask-position:center center;-webkit-mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);-webkit-mask-repeat:no-repeat;-webkit-mask-position:center center"></span></div></div><span class="truncate font-medium group-data-[state=active]/tab-button:font-semibold">Voice Agent</span></div></a></li><li><a class="min-h-[32px] lg:min-h-[36px] group/tab-button hover:t-accent flex min-w-0 flex-1 select-none items-center justify-start rounded-lg py-2 text-base group-hover/tab-button:transition lg:px-3 lg:text-sm data-[state=inactive]:t-muted data-[state=active]:t-accent" data-state="inactive" href="/docs/pre-recorded-audio"><div class="flex min-w-0 items-center justify-start space-x-4"><div class="min-w-fit"><div class="bg-card-surface ring-border-default group-hover/tab-button:bg-tag-primary group-hover/tab-button:ring-accent/70 group-data-[state=active]/tab-button:bg-accent group-hover/tab-button:group-data-[state=active]/tab-button:bg-accent flex size-6 items-center justify-center rounded-md shadow-sm ring-1 group-data-[state=active]/tab-button:ring-0"><span class="bg-faded group-hover/tab-button:bg-accent group-data-[state=active]/tab-button:bg-background group-hover/tab-button:group-data-[state=active]/tab-button:bg-background size-4 fa-icon" style="mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);mask-repeat:no-repeat;mask-position:center center;-webkit-mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);-webkit-mask-repeat:no-repeat;-webkit-mask-position:center center"></span></div></div><span class="truncate font-medium group-data-[state=active]/tab-button:font-semibold">Speech to Text</span></div></a></li><li><a class="min-h-[32px] lg:min-h-[36px] group/tab-button hover:t-accent flex min-w-0 flex-1 select-none items-center justify-start rounded-lg py-2 text-base group-hover/tab-button:transition lg:px-3 lg:text-sm data-[state=inactive]:t-muted data-[state=active]:t-accent" data-state="inactive" href="/docs/tts-rest"><div class="flex min-w-0 items-center justify-start space-x-4"><div class="min-w-fit"><div class="bg-card-surface ring-border-default group-hover/tab-button:bg-tag-primary group-hover/tab-button:ring-accent/70 group-data-[state=active]/tab-button:bg-accent group-hover/tab-button:group-data-[state=active]/tab-button:bg-accent flex size-6 items-center justify-center rounded-md shadow-sm ring-1 group-data-[state=active]/tab-button:ring-0"><span class="bg-faded group-hover/tab-button:bg-accent group-data-[state=active]/tab-button:bg-background group-hover/tab-button:group-data-[state=active]/tab-button:bg-background size-4 fa-icon" style="mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);mask-repeat:no-repeat;mask-position:center center;-webkit-mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);-webkit-mask-repeat:no-repeat;-webkit-mask-position:center center"></span></div></div><span class="truncate font-medium group-data-[state=active]/tab-button:font-semibold">Text to Speech</span></div></a></li><li><a class="min-h-[32px] lg:min-h-[36px] group/tab-button hover:t-accent flex min-w-0 flex-1 select-none items-center justify-start rounded-lg py-2 text-base group-hover/tab-button:transition lg:px-3 lg:text-sm data-[state=inactive]:t-muted data-[state=active]:t-accent" data-state="inactive" href="/docs/audio-intelligence"><div class="flex min-w-0 items-center justify-start space-x-4"><div class="min-w-fit"><div class="bg-card-surface ring-border-default group-hover/tab-button:bg-tag-primary group-hover/tab-button:ring-accent/70 group-data-[state=active]/tab-button:bg-accent group-hover/tab-button:group-data-[state=active]/tab-button:bg-accent flex size-6 items-center justify-center rounded-md shadow-sm ring-1 group-data-[state=active]/tab-button:ring-0"><span class="bg-faded group-hover/tab-button:bg-accent group-data-[state=active]/tab-button:bg-background group-hover/tab-button:group-data-[state=active]/tab-button:bg-background size-4 fa-icon" style="mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);mask-repeat:no-repeat;mask-position:center center;-webkit-mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);-webkit-mask-repeat:no-repeat;-webkit-mask-position:center center"></span></div></div><span class="truncate font-medium group-data-[state=active]/tab-button:font-semibold">Intelligence</span></div></a></li><li><a class="min-h-[32px] lg:min-h-[36px] group/tab-button hover:t-accent flex min-w-0 flex-1 select-none items-center justify-start rounded-lg py-2 text-base group-hover/tab-button:transition lg:px-3 lg:text-sm data-[state=inactive]:t-muted data-[state=active]:t-accent" data-state="inactive" href="/reference/deepgram-api-overview"><div class="flex min-w-0 items-center justify-start space-x-4"><div class="min-w-fit"><div class="bg-card-surface ring-border-default group-hover/tab-button:bg-tag-primary group-hover/tab-button:ring-accent/70 group-data-[state=active]/tab-button:bg-accent group-hover/tab-button:group-data-[state=active]/tab-button:bg-accent flex size-6 items-center justify-center rounded-md shadow-sm ring-1 group-data-[state=active]/tab-button:ring-0"><span class="bg-faded group-hover/tab-button:bg-accent group-data-[state=active]/tab-button:bg-background group-hover/tab-button:group-data-[state=active]/tab-button:bg-background size-4 fa-icon" style="mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);mask-repeat:no-repeat;mask-position:center center;-webkit-mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);-webkit-mask-repeat:no-repeat;-webkit-mask-position:center center"></span></div></div><span class="truncate font-medium group-data-[state=active]/tab-button:font-semibold">API Ref</span></div></a></li><li><a class="min-h-[32px] lg:min-h-[36px] group/tab-button hover:t-accent flex min-w-0 flex-1 select-none items-center justify-start rounded-lg py-2 text-base group-hover/tab-button:transition lg:px-3 lg:text-sm data-[state=inactive]:t-muted data-[state=active]:t-accent" data-state="active" href="/docs/make-your-first-api-request"><div class="flex min-w-0 items-center justify-start space-x-4"><div class="min-w-fit"><div class="bg-card-surface ring-border-default group-hover/tab-button:bg-tag-primary group-hover/tab-button:ring-accent/70 group-data-[state=active]/tab-button:bg-accent group-hover/tab-button:group-data-[state=active]/tab-button:bg-accent flex size-6 items-center justify-center rounded-md shadow-sm ring-1 group-data-[state=active]/tab-button:ring-0"><span class="bg-faded group-hover/tab-button:bg-accent group-data-[state=active]/tab-button:bg-background group-hover/tab-button:group-data-[state=active]/tab-button:bg-background size-4 fa-icon" style="mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);mask-repeat:no-repeat;mask-position:center center;-webkit-mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);-webkit-mask-repeat:no-repeat;-webkit-mask-position:center center"></span></div></div><span class="truncate font-medium group-data-[state=active]/tab-button:font-semibold">Guides</span></div></a></li><li><a class="min-h-[32px] lg:min-h-[36px] group/tab-button hover:t-accent flex min-w-0 flex-1 select-none items-center justify-start rounded-lg py-2 text-base group-hover/tab-button:transition lg:px-3 lg:text-sm data-[state=inactive]:t-muted data-[state=active]:t-accent" data-state="inactive" href="/docs/deepgram-sdks"><div class="flex min-w-0 items-center justify-start space-x-4"><div class="min-w-fit"><div class="bg-card-surface ring-border-default group-hover/tab-button:bg-tag-primary group-hover/tab-button:ring-accent/70 group-data-[state=active]/tab-button:bg-accent group-hover/tab-button:group-data-[state=active]/tab-button:bg-accent flex size-6 items-center justify-center rounded-md shadow-sm ring-1 group-data-[state=active]/tab-button:ring-0"><span class="bg-faded group-hover/tab-button:bg-accent group-data-[state=active]/tab-button:bg-background group-hover/tab-button:group-data-[state=active]/tab-button:bg-background size-4 fa-icon" style="mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);mask-repeat:no-repeat;mask-position:center center;-webkit-mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);-webkit-mask-repeat:no-repeat;-webkit-mask-position:center center"></span></div></div><span class="truncate font-medium group-data-[state=active]/tab-button:font-semibold">SDKs</span></div></a></li><li><a class="min-h-[32px] lg:min-h-[36px] group/tab-button hover:t-accent flex min-w-0 flex-1 select-none items-center justify-start rounded-lg py-2 text-base group-hover/tab-button:transition lg:px-3 lg:text-sm data-[state=inactive]:t-muted data-[state=active]:t-accent" data-state="inactive" href="/docs/self-hosted-introduction"><div class="flex min-w-0 items-center justify-start space-x-4"><div class="min-w-fit"><div class="bg-card-surface ring-border-default group-hover/tab-button:bg-tag-primary group-hover/tab-button:ring-accent/70 group-data-[state=active]/tab-button:bg-accent group-hover/tab-button:group-data-[state=active]/tab-button:bg-accent flex size-6 items-center justify-center rounded-md shadow-sm ring-1 group-data-[state=active]/tab-button:ring-0"><span class="bg-faded group-hover/tab-button:bg-accent group-data-[state=active]/tab-button:bg-background group-hover/tab-button:group-data-[state=active]/tab-button:bg-background size-4 fa-icon" style="mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);mask-repeat:no-repeat;mask-position:center center;-webkit-mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);-webkit-mask-repeat:no-repeat;-webkit-mask-position:center center"></span></div></div><span class="truncate font-medium group-data-[state=active]/tab-button:font-semibold">Self-Hosted Deployments</span></div></a></li><li><a class="min-h-[32px] lg:min-h-[36px] group/tab-button hover:t-accent flex min-w-0 flex-1 select-none items-center justify-start rounded-lg py-2 text-base group-hover/tab-button:transition lg:px-3 lg:text-sm data-[state=inactive]:t-muted data-[state=active]:t-accent" data-state="inactive" href="/docs/security-policy"><div class="flex min-w-0 items-center justify-start space-x-4"><div class="min-w-fit"><div class="bg-card-surface ring-border-default group-hover/tab-button:bg-tag-primary group-hover/tab-button:ring-accent/70 group-data-[state=active]/tab-button:bg-accent group-hover/tab-button:group-data-[state=active]/tab-button:bg-accent flex size-6 items-center justify-center rounded-md shadow-sm ring-1 group-data-[state=active]/tab-button:ring-0"><span class="bg-faded group-hover/tab-button:bg-accent group-data-[state=active]/tab-button:bg-background group-hover/tab-button:group-data-[state=active]/tab-button:bg-background size-4 fa-icon" style="mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);mask-repeat:no-repeat;mask-position:center center;-webkit-mask-image:url(&quot;https://icons.ferndocs.com/solid/book-open.svg&quot;);-webkit-mask-repeat:no-repeat;-webkit-mask-position:center center"></span></div></div><span class="truncate font-medium group-data-[state=active]/tab-button:font-semibold">Security</span></div></a></li></ul><ul class="fern-sidebar-group"><li class="mt-6"><div class="fern-sidebar-heading"><span class="fern-sidebar-heading-content">Fundamentals</span></div><ul class="fern-sidebar-group"><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/make-your-first-api-request"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Make Your First API Request</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/authenticating"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Authenticating</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/model-metadata"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Model Metadata</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/managing-projects"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Managing Projects</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/using-multiple-projects"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Using Multiple Projects</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/working-with-roles"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Working With Roles &amp; API Scopes</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/supported-audio-formats"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Supported Audio Formats</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/deployment-options"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Deployment Options</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/create-additional-api-keys"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Creating API Keys</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/using-the-sec-websocket-protocol"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Using the Sec-WebSocket-Protocol</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/using-logs-usage"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Logs &amp; Usage Data</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/the-deepgram-model-improvement-partnership-program"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Model Improvement Partnership Program</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/working-with-concurrency-rate-limits"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Working With Concurrency Rate Limits</span></span></a></div></li></ul></li><li class="mt-6"><div class="fern-sidebar-heading"><span class="fern-sidebar-heading-content">Use Case Examples</span></div><ul class="fern-sidebar-group"><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/build-voice-agent-with-twilio-deepgram-openai"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Build a Voice Agent with Twilio &amp; OpenAI &amp; Deepgram</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/calculate-talk-time-analytics"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Calculate Talk Time Analytics</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/transcribe-meetings-in-realtime"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Transcribe Meetings in Realtime</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/transcribe-recorded-calls-with-twilio"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Transcribe Recorded Calls With Twilio</span></span></a></div></li></ul></li><li class="mt-6"><div class="fern-sidebar-heading"><span class="fern-sidebar-heading-content">Integrations</span></div><ul class="fern-sidebar-group"><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/deepgram-with-amazon-connect"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Amazon Connect and Deepgram</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/using-aws-s3-presigned-urls-with-the-deepgram-api"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">AWS S3 Presigned URLs and Deepgram</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/genesys-with-deepgram"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Genesys and Deepgram</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="active"><a class="fern-sidebar-link" href="/docs/use-deepgram-with-dialogflow-cx"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Google Dialogflow CX and Deepgram</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/makecom-deepgram-integration"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Make.com and Deepgram</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/on-premise-twilio-integration"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Twilio and Deepgram STT</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/twilio-and-deepgram-tts"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Twilio and Deepgram TTS</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/twilio-and-deepgram-voice-agent"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Twilio and Deepgram Voice Agent</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/zapier-integration"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Zapier and Deepgram</span></span></a></div></li><li><div class="fern-sidebar-link-container" data-state="inactive"><a class="fern-sidebar-link" href="/docs/integrate-deepgram-with-zoom"><span class="fern-sidebar-link-content"><span class="fern-sidebar-link-text">Zoom and Deepgram</span></span></a></div></li></ul></li></ul></div></div></div></nav><div class="fern-main"><main class="fern-guide-layout"><aside class="fern-layout-toc"><div dir="ltr" class="fern-scroll-area" style="position:relative;--radix-scroll-area-corner-width:0px;--radix-scroll-area-corner-height:0px"><style>[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}</style><div data-radix-scroll-area-viewport="" class="fern-scroll-area-viewport px-4 pb-12 pt-8 lg:pr-8" data-scrollbars="both" style="overflow-x:hidden;overflow-y:hidden"><div style="min-width:100%;display:table"><div class="text-grayscale-a11 m-0 mb-3 text-sm font-medium">On this page</div><ul class="toc-root not-prose" style="--height:0px;--top:0px"><li class="mb-2 last:mb-0" data-depth="0"><a class="block hyphens-auto break-words text-sm transition-colors hover:transition-none text-grayscale-a11 hover:text-grayscale-a12" style="padding-left:0px" href="/docs/use-deepgram-with-dialogflow-cx#before-you-begin">Before you Begin</a></li><li class="mb-2 last:mb-0" data-depth="0"><a class="block hyphens-auto break-words text-sm transition-colors hover:transition-none text-grayscale-a11 hover:text-grayscale-a12" style="padding-left:0px" href="/docs/use-deepgram-with-dialogflow-cx#create-a-dialogflow-cx-agent">Create a Dialogflow CX Agent</a></li><li class="mb-2 last:mb-0" data-depth="0"><a class="block hyphens-auto break-words text-sm transition-colors hover:transition-none text-grayscale-a11 hover:text-grayscale-a12" style="padding-left:0px" href="/docs/use-deepgram-with-dialogflow-cx#try-out-the-demo">Try Out the Demo</a></li><li class="mb-2 last:mb-0" data-depth="0"><a class="block hyphens-auto break-words text-sm transition-colors hover:transition-none text-grayscale-a11 hover:text-grayscale-a12" style="padding-left:0px" href="/docs/use-deepgram-with-dialogflow-cx#high-level-architecture">High-Level Architecture</a></li><li class="mb-2 last:mb-0" data-depth="0"><a class="block hyphens-auto break-words text-sm transition-colors hover:transition-none text-grayscale-a11 hover:text-grayscale-a12" style="padding-left:0px" href="/docs/use-deepgram-with-dialogflow-cx#deeper-look">Deeper Look</a></li><li class="mb-2 last:mb-0" data-depth="0"><a class="block hyphens-auto break-words text-sm transition-colors hover:transition-none text-grayscale-a11 hover:text-grayscale-a12" style="padding-left:0px" href="/docs/use-deepgram-with-dialogflow-cx#options-for-customizing-utterance-segmentation">Options for Customizing Utterance Segmentation</a></li><li class="mb-2 last:mb-0" data-depth="1"><a class="block hyphens-auto break-words text-sm transition-colors hover:transition-none text-grayscale-a11 hover:text-grayscale-a12" style="padding-left:12px" href="/docs/use-deepgram-with-dialogflow-cx#update-dialogflow-with-resumed-utterances">Update Dialogflow with Resumed Utterances</a></li><li class="mb-2 last:mb-0" data-depth="1"><a class="block hyphens-auto break-words text-sm transition-colors hover:transition-none text-grayscale-a11 hover:text-grayscale-a12" style="padding-left:12px" href="/docs/use-deepgram-with-dialogflow-cx#dont-segment-on-endpoints">Don&#x27;t Segment on Endpoints</a></li><li class="mb-2 last:mb-0" data-depth="1"><a class="block hyphens-auto break-words text-sm transition-colors hover:transition-none text-grayscale-a11 hover:text-grayscale-a12" style="padding-left:12px" href="/docs/use-deepgram-with-dialogflow-cx#replace-word-timing-logic-with-utterance_end_ms">Replace Word Timing Logic with utterance_end_ms</a></li><li class="mb-2 last:mb-0" data-depth="0"><a class="block hyphens-auto break-words text-sm transition-colors hover:transition-none text-grayscale-a11 hover:text-grayscale-a12" style="padding-left:0px" href="/docs/use-deepgram-with-dialogflow-cx#audiocodes-as-an-alternative">AudioCodes as an Alternative</a></li></ul></div></div></div></aside><article class="fern-layout-content max-w-content-width"><header class="mb-8"><div class="space-y-1"><div><span class="fern-breadcrumb"><a class="fern-breadcrumb-item" href="/docs/deepgram-with-amazon-connect">Integrations</a></span></div><h1 class="fern-page-heading"><p>Google Dialogflow CX and Deepgram</p></h1></div><div class="prose-p:t-muted mt-2 leading-7"><p>Dialogflow CX is a framework for building virtual agents. Learn how to incorporate Deepgram’s transcription and text-to-speech for improved accuracy.</p></div></header><div class="prose dark:prose-invert prose-h1:mt-[1.5em] first:prose-h1:mt-0 max-w-full break-words"><p>In this guide, we’ll explain how to talk to a Dialogflow CX agent using Deepgram for transcription and text-to-speech. We’ll do this by walking through Deepgram’s <a class="fern-mdx-link" target="_blank" rel="noreferrer" href="https://github.com/deepgram/dialogflow-example">Dialogflow Example<svg width="1.5em" height="1.5em" viewBox="0 0 24 24" stroke-width="1.5" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="external-link-icon"><path d="M21 3L15 3M21 3L12 12M21 3V9" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 13V19C21 20.1046 20.1046 21 19 21H5C3.89543 21 3 20.1046 3 19V5C3 3.89543 3.89543 3 5 3H11" stroke="currentColor" stroke-linecap="round"></path></svg></a> repo on GitHub.</p> <h2 id="before-you-begin" data-state="closed">Before you Begin</h2> <div class="mb-6 mt-4 rounded-lg p-4 first:mt-0 callout-outlined"><div class="flex items-start space-x-3"><div class="mt-0.5 w-4"><svg width="1.5em" height="1.5em" stroke-width="1.5" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="text-intent-default size-icon-md"><path d="M12 11.5V16.5" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 7.51L12.01 7.49889" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 22C17.5228 22 22 17.5228 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12C2 17.5228 6.47715 22 12 22Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path></svg></div><div class="prose prose-sm dark:prose-invert -my-4 flex-1 overflow-x-auto before:mb-4 before:block after:mt-4 after:block"><div class="text-intent-default"><h5 class="leading-snug"></h5><p>Before you can use Deepgram, you’ll need to <a class="fern-mdx-link" target="_blank" rel="noreferrer" href="https://console.deepgram.com/signup?jump=keys">create a Deepgram account<svg width="1.5em" height="1.5em" viewBox="0 0 24 24" stroke-width="1.5" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="external-link-icon"><path d="M21 3L15 3M21 3L12 12M21 3V9" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 13V19C21 20.1046 20.1046 21 19 21H5C3.89543 21 3 20.1046 3 19V5C3 3.89543 3.89543 3 5 3H11" stroke="currentColor" stroke-linecap="round"></path></svg></a>. Signup is free and includes <strong class="font-semibold">$200</strong> in free credit and access to all of Deepgram’s features!</p></div></div></div></div> <div class="mb-6 mt-4 rounded-lg p-4 first:mt-0 callout-outlined"><div class="flex items-start space-x-3"><div class="mt-0.5 w-4"><svg width="1.5em" height="1.5em" stroke-width="1.5" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="text-intent-default size-icon-md"><path d="M12 11.5V16.5" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 7.51L12.01 7.49889" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 22C17.5228 22 22 17.5228 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12C2 17.5228 6.47715 22 12 22Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path></svg></div><div class="prose prose-sm dark:prose-invert -my-4 flex-1 overflow-x-auto before:mb-4 before:block after:mt-4 after:block"><div class="text-intent-default"><h5 class="leading-snug"></h5><p>Before you start, you’ll need to follow the steps in the <a class="fern-mdx-link" href="/docs/make-your-first-api-request">Make Your First API Request</a> guide to obtain a Deepgram API key, and configure your environment if you are choosing to use a Deepgram SDK.</p></div></div></div></div> <h2 id="create-a-dialogflow-cx-agent" data-state="closed">Create a Dialogflow CX Agent</h2> <p>You’ll also need a Dialogflow agent to talk to. If you don’t already have one, the easiest approach is to create a <a class="fern-mdx-link" target="_blank" rel="noreferrer" href="https://cloud.google.com/dialogflow/cx/docs/concept/agents-prebuilt">prebuilt agent<svg width="1.5em" height="1.5em" viewBox="0 0 24 24" stroke-width="1.5" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="external-link-icon"><path d="M21 3L15 3M21 3L12 12M21 3V9" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 13V19C21 20.1046 20.1046 21 19 21H5C3.89543 21 3 20.1046 3 19V5C3 3.89543 3.89543 3 5 3H11" stroke="currentColor" stroke-linecap="round"></path></svg></a>.</p> <h2 id="try-out-the-demo" data-state="closed">Try Out the Demo</h2> <p>Clone the <a class="fern-mdx-link" target="_blank" rel="noreferrer" href="https://github.com/deepgram/dialogflow-example">Dialogflow Example<svg width="1.5em" height="1.5em" viewBox="0 0 24 24" stroke-width="1.5" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="external-link-icon"><path d="M21 3L15 3M21 3L12 12M21 3V9" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 13V19C21 20.1046 20.1046 21 19 21H5C3.89543 21 3 20.1046 3 19V5C3 3.89543 3.89543 3 5 3H11" stroke="currentColor" stroke-linecap="round"></path></svg></a> repo and follow the instructions in <code>README.md</code>. You’ll need to provide your Deepgram API key and your Dialogflow agent information. The <a class="fern-mdx-link" target="_blank" rel="noreferrer" href="https://github.com/deepgram/dialogflow-example#demo">video<svg width="1.5em" height="1.5em" viewBox="0 0 24 24" stroke-width="1.5" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="external-link-icon"><path d="M21 3L15 3M21 3L12 12M21 3V9" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 13V19C21 20.1046 20.1046 21 19 21H5C3.89543 21 3 20.1046 3 19V5C3 3.89543 3.89543 3 5 3H11" stroke="currentColor" stroke-linecap="round"></path></svg></a> in the README shows how the demo should work.</p> <h1 id="high-level-architecture" data-state="closed">High-Level Architecture</h1> <p>Dialogflow agents can accept user input in the form of audio or text. If you send audio to an agent, Google will transcribe it with their own speech-to-text engine. In order to use Deepgram’s transcription, we need to transcribe the audio outside of Dialogflow and send the resulting text to our agent. If we also want to use Deepgram’s text-to-speech for the bot’s voice, we must configure Dialogflow to return agent responses as text. This diagram depicts the full process:</p> <p><span aria-owns="rmiz-modal-" data-rmiz=""><span data-rmiz-content="not-found" style="visibility:visible"><img alt="" loading="lazy" width="976" height="409" decoding="async" data-nimg="1" style="color:transparent;aspect-ratio:2.3863080684596576" srcSet="https://app.ferndocs.com/_next/image?url=https%3A%2F%2Ffiles.buildwithfern.com%2Fhttps%3A%2F%2Fdeepgram.docs.buildwithfern.com%2F2025-02-21T18%3A42%3A13.663Z%2Fimages%2Fc213cc7-dialogflow-architecture-tts.png&amp;w=1080&amp;q=75&amp;dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt 1x, https://app.ferndocs.com/_next/image?url=https%3A%2F%2Ffiles.buildwithfern.com%2Fhttps%3A%2F%2Fdeepgram.docs.buildwithfern.com%2F2025-02-21T18%3A42%3A13.663Z%2Fimages%2Fc213cc7-dialogflow-architecture-tts.png&amp;w=2048&amp;q=75&amp;dpl=dpl_4QpQ8NTiUGorrHCFa7JoGjuJyFCt 2x" src="https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/images/c213cc7-dialogflow-architecture-tts.png"/></span></span></p> <ol class="mb-3 list-outside list-decimal space-y-2"> <li class="">The user speaks into their microphone.</li> <li class="">The integration continuously streams the user’s speech to Deepgram.</li> <li class="">Deepgram streams back transcripts.</li> <li class="">The integration analyzes the transcripts to determine when the user has completed a thought (<a class="fern-mdx-link" target="_blank" rel="noreferrer" href="https://deepgram.com/learn/building-a-conversational-ai-flow-with-deepgram">“utterance segmentation”<svg width="1.5em" height="1.5em" viewBox="0 0 24 24" stroke-width="1.5" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="external-link-icon"><path d="M21 3L15 3M21 3L12 12M21 3V9" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 13V19C21 20.1046 20.1046 21 19 21H5C3.89543 21 3 20.1046 3 19V5C3 3.89543 3.89543 3 5 3H11" stroke="currentColor" stroke-linecap="round"></path></svg></a>). When it finds a complete utterance, it sends it to the Dialogflow agent as text.</li> <li class="">The agent replies with its response, also in the form of text.</li> <li class="">The agent’s response is sent to Deepgram’s text-to-speech engine.</li> <li class="">Deepgram returns the response as audio.</li> <li class="">The audio is played to the user.</li> <li class="">The process repeats until the conversation is finished.</li> </ol> <h1 id="deeper-look" data-state="closed">Deeper Look</h1> <p>At any given time, <code>server.js</code> is in one of two states. In the <strong class="font-semibold">awaiting utterance</strong> state, it is collecting transcripts from Deepgram and looking for an indication that the user has finished their thought. In the <strong class="font-semibold">awaiting bot reply</strong> state, it is discarding transcripts because we’ve already sent the utterance to Dialogflow and it is now the bot’s turn to speak.</p> <p>This is the code that runs when <code>server.js</code> receives a transcription result from Deepgram (note the two states):</p> <div class="bg-card after:ring-card-border relative mb-6 mt-4 flex w-full min-w-0 max-w-full flex-col rounded-lg shadow-sm after:pointer-events-none after:absolute after:inset-0 after:rounded-[inherit] after:ring-1 after:ring-inset after:content-[&#x27;&#x27;] first:mt-0"><div class="bg-tag-default-soft rounded-t-[inherit]"><div class="shadow-border-default mx-px flex min-h-10 items-center justify-between shadow-[inset_0_-1px_0_0]"><div class="flex min-h-10 overflow-x-auto"><div class="flex items-center px-3 py-1.5"><span class="t-muted rounded text-sm font-semibold">JavaScript</span></div></div><button tabindex="0" data-state="closed" aria-disabled="false" class="fern-copy-button group ml-2 mr-1 fern-button minimal normal rounded square"><span class="fern-button-content"><svg width="1.5em" height="1.5em" stroke-width="1.5" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor"><path d="M19.4 20H9.6C9.26863 20 9 19.7314 9 19.4V9.6C9 9.26863 9.26863 9 9.6 9H19.4C19.7314 9 20 9.26863 20 9.6V19.4C20 19.7314 19.7314 20 19.4 20Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15 9V4.6C15 4.26863 14.7314 4 14.4 4H4.6C4.26863 4 4 4.26863 4 4.6V14.4C4 14.7314 4.26863 15 4.6 15H9" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path></svg></span></button></div></div><pre class="code-block-root not-prose rounded-b-[inherit]" tabindex="0"><div dir="ltr" class="fern-scroll-area" style="position:relative;--radix-scroll-area-corner-width:0px;--radix-scroll-area-corner-height:0px"><style>[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}</style><div data-radix-scroll-area-viewport="" class="fern-scroll-area-viewport" data-scrollbars="both" style="overflow-x:hidden;overflow-y:hidden;max-height:479px"><div style="min-width:100%;display:table"><code class="code-block text-sm"><div class="code-block-inner"><table class="code-block-line-group"><colgroup><col class="w-fit"/><col/></colgroup><tbody><tr class="code-block-line"><td class="code-block-line-gutter"><span>1</span></td><td class="code-block-line-content"><span class="line">function handleDgResults(start, duration, isFinal, speechFinal, transcript, words) {</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>2</span></td><td class="code-block-line-content"><span class="line"> switch (voicebotState) {</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>3</span></td><td class="code-block-line-content"><span class="line"> case STATES.AwaitingUtterance:</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>4</span></td><td class="code-block-line-content"><span class="line"> // Update `finalizedTranscript` and `unfinalizedTranscript` in light of the new result</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>5</span></td><td class="code-block-line-content"><span class="line"> updateTranscriptState(transcript, isFinal);</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>6</span></td><td class="code-block-line-content"><span class="line"></span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>7</span></td><td class="code-block-line-content"><span class="line"> // Update `latestTimeSeen` and `latestFinalizedWordEnd` in light of the new result</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>8</span></td><td class="code-block-line-content"><span class="line"> updateSilenceDetectionState(start, duration, words, isFinal);</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>9</span></td><td class="code-block-line-content"><span class="line"></span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>10</span></td><td class="code-block-line-content"><span class="line"> if (finalizedTranscript === &quot;&quot;) {</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>11</span></td><td class="code-block-line-content"><span class="line"> return;</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>12</span></td><td class="code-block-line-content"><span class="line"> }</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>13</span></td><td class="code-block-line-content"><span class="line"></span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>14</span></td><td class="code-block-line-content"><span class="line"> let silenceDetected = </span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>15</span></td><td class="code-block-line-content"><span class="line"> unfinalizedTranscript === &quot;&quot; &amp;&amp; latestTimeSeen - latestFinalizedWordEnd &gt; 1.25;</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>16</span></td><td class="code-block-line-content"><span class="line"></span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>17</span></td><td class="code-block-line-content"><span class="line"> if (silenceDetected || speechFinal) {</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>18</span></td><td class="code-block-line-content"><span class="line"> changeVoicebotState(STATES.AwaitingBotReply);</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>19</span></td><td class="code-block-line-content"><span class="line"> </span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>20</span></td><td class="code-block-line-content"><span class="line"> // Send the completed utterance to Dialogflow</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>21</span></td><td class="code-block-line-content"><span class="line"> sendUtteranceDownstream(finalizedTranscript); </span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>22</span></td><td class="code-block-line-content"><span class="line"> }</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>23</span></td><td class="code-block-line-content"><span class="line"></span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>24</span></td><td class="code-block-line-content"><span class="line"> break;</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>25</span></td><td class="code-block-line-content"><span class="line"> case STATES.AwaitingBotReply:</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>26</span></td><td class="code-block-line-content"><span class="line"> // Discard the transcript; do nothing</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>27</span></td><td class="code-block-line-content"><span class="line"> break;</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>28</span></td><td class="code-block-line-content"><span class="line"> }</span></td></tr><tr class="code-block-line"><td class="code-block-line-gutter"><span>29</span></td><td class="code-block-line-content"><span class="line">}</span></td></tr></tbody></table></div></code></div></div></div></pre></div> <p><code>finalizedTranscript</code> is all of the concatenated <code>is_final=true</code> results that we’ve received since the start of the current utterance. <code>unfinalizedTranscript</code> is the most recent <code>is_final=false</code> result for which we have not yet seen an <code>is_final=true</code>. (If these concepts are unfamiliar, have a look at the documentation on <a class="fern-mdx-link" href="/docs/interim-results">interim results</a>.)</p> <p>When we detect that the current <code>finalizedTranscript</code> contains a full utterance, we send it off to Dialogflow and await the agent’s reply.</p> <p>This detection happens when there is a sufficient period of silence after the transcript. That is, when either of these conditions is met:</p> <ol class="mb-3 list-outside list-decimal space-y-2"> <li class="">We’ve reached an <a class="fern-mdx-link" href="/docs/endpointing">endpoint</a> (<code>speech_final=true</code>), or</li> <li class="">The transcripts reveal a 1.25 second silence after the last finalized word.</li> </ol> <h1 id="options-for-customizing-utterance-segmentation" data-state="closed">Options for Customizing Utterance Segmentation</h1> <p>The approach described above is a solid starting point for detecting end of utterance, but depending on your needs you may want to explore various customizations. For example, you can adjust the <code>endpointing</code> and silence detection values (currently set to <code>500ms</code> and <code>1.25s</code>, respectively). Below are some additional modifications you might consider.</p> <h2 id="update-dialogflow-with-resumed-utterances" data-state="closed">Update Dialogflow with Resumed Utterances</h2> <p>You may want to send tentative utterances to Dialogflow. Then if the user resumes speaking before the agent has replied, you can cancel the original Dialogflow operation and send the new, full utterance to Dialogflow instead. This comes with a couple of advantages:</p> <ul class="mb-3 list-outside list-disc space-y-2"> <li class=""><strong class="font-semibold">Lower latency</strong>. For example, you can set endpointing to a snappy <code>10ms</code> and send the utterance to Dialogflow right away at an endpoint. Then you get the agent reply and hold it until you verify that the user has really stopped speaking, at which point you send it to the user immediately.</li> <li class=""><strong class="font-semibold">Last-minute interjections</strong>. With this approach the user is able to add to their utterance right until the bot reply is sent to them.</li> </ul> <p>If you go this route, make sure that any actions taken by the Dialogflow agent on the tentative utterance are indeed reversible in the event of a replacement utterance. It is possible to rewind the state of the agent itself (see the parameters <a class="fern-mdx-link" target="_blank" rel="noreferrer" href="https://cloud.google.com/dialogflow/cx/docs/reference/rest/v3/QueryParameters">here<svg width="1.5em" height="1.5em" viewBox="0 0 24 24" stroke-width="1.5" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="external-link-icon"><path d="M21 3L15 3M21 3L12 12M21 3V9" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 13V19C21 20.1046 20.1046 21 19 21H5C3.89543 21 3 20.1046 3 19V5C3 3.89543 3.89543 3 5 3H11" stroke="currentColor" stroke-linecap="round"></path></svg></a>), but the agent can’t uncall any webhooks that it called while fulfilling the user’s request.</p> <h2 id="dont-segment-on-endpoints" data-state="closed">Don’t Segment on Endpoints</h2> <p>Endpointing is sometimes said to be a poor indicator of end of utterance. On one hand, an <code>endpointing</code> value that is too low can lead to false positives. On the other hand, an <code>endpointing</code> value that is too high may simply <a class="fern-mdx-link" href="/docs/understanding-end-of-speech-detection-while-streaming#limitations-of-endpointing">not fire due to background noise</a>. So you can try leaving <code>endpointing</code> at its default value of <code>10ms</code> (for rapid finalization of transcripts) and only doing utterance segmentation based on word timing analysis.</p> <h2 id="replace-word-timing-logic-with-utterance_end_ms" data-state="closed">Replace Word Timing Logic with <code>utterance_end_ms</code></h2> <p>Finally, you may choose to use Deepgram’s <a class="fern-mdx-link" href="/docs/understanding-end-of-speech-detection-while-streaming#introducing-the-utteranceend-feature">UtteranceEnd</a> feature in place of the word timing logic. This is really a matter of preference; do you prefer the conciseness of the built-in <code>UtteranceEnd</code> message, or the clarity and flexibility of the explicit word timing logic?</p> <h1 id="audiocodes-as-an-alternative" data-state="closed">AudioCodes as an Alternative</h1> <p>Deepgram’s partner AudioCodes offers a managed solution called <a class="fern-mdx-link" target="_blank" rel="noreferrer" href="https://voiceaiconnect.audiocodes.com/google-dialogflow">VoiceAI Connect<svg width="1.5em" height="1.5em" viewBox="0 0 24 24" stroke-width="1.5" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="external-link-icon"><path d="M21 3L15 3M21 3L12 12M21 3V9" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 13V19C21 20.1046 20.1046 21 19 21H5C3.89543 21 3 20.1046 3 19V5C3 3.89543 3.89543 3 5 3H11" stroke="currentColor" stroke-linecap="round"></path></svg></a>, which enables you to pair Deepgram’s speech-to-text with many different bot frameworks, including Dialogflow CX. Read more about our integration with AudioCodes <a class="fern-mdx-link" target="_blank" rel="noreferrer" href="https://deepgram.com/learn/audiocodes-voicebots-integration">here<svg width="1.5em" height="1.5em" viewBox="0 0 24 24" stroke-width="1.5" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="external-link-icon"><path d="M21 3L15 3M21 3L12 12M21 3V9" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 13V19C21 20.1046 20.1046 21 19 21H5C3.89543 21 3 20.1046 3 19V5C3 3.89543 3.89543 3 5 3H11" stroke="currentColor" stroke-linecap="round"></path></svg></a>.</p> <hr/> <p>What’s Next</p> <ul class="mb-3 list-outside list-disc space-y-2"> <li class=""><a class="fern-mdx-link" href="/reference/deepgram-api-overview">Deepgram API Overview</a></li> </ul></div><footer class="mt-12"><div class="flex gap-4 max-sm:flex-col sm:justify-between"><div><div><div class="flex w-full flex-wrap items-center justify-between gap-4"><div class="flex items-center justify-start gap-2"><span class="t-muted text-sm font-medium">Was this page helpful?</span><span class="fern-button-group"><button tabindex="0" data-state="closed" aria-disabled="false" data-selected="false" type="button" aria-haspopup="dialog" aria-expanded="false" aria-controls="radix-:Rpat8um:" class="fern-button outlined normal"><span class="fern-button-content"><svg width="1.5em" height="1.5em" stroke-width="1.5" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class=""><path d="M16.4724 20H4.1C3.76863 20 3.5 19.7314 3.5 19.4V9.6C3.5 9.26863 3.76863 9 4.1 9H6.86762C7.57015 9 8.22116 8.6314 8.5826 8.02899L11.293 3.51161C11.8779 2.53688 13.2554 2.44422 13.9655 3.33186C14.3002 3.75025 14.4081 4.30635 14.2541 4.81956L13.2317 8.22759C13.1162 8.61256 13.4045 9 13.8064 9H18.3815C19.7002 9 20.658 10.254 20.311 11.5262L18.4019 18.5262C18.1646 19.3964 17.3743 20 16.4724 20Z" stroke="currentColor" stroke-linecap="round"></path><path d="M7 20L7 9" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path></svg><span class="fern-button-text">Yes</span></span></button><button tabindex="0" data-state="closed" aria-disabled="false" data-selected="false" type="button" aria-haspopup="dialog" aria-expanded="false" aria-controls="radix-:R19at8um:" class="fern-button outlined normal"><span class="fern-button-content"><svg width="1.5em" height="1.5em" stroke-width="1.5" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class=""><path d="M16.4724 3.5H4.1C3.76863 3.5 3.5 3.76863 3.5 4.1V13.9C3.5 14.2314 3.76863 14.5 4.1 14.5H6.86762C7.57015 14.5 8.22116 14.8686 8.5826 15.471L11.293 19.9884C11.8779 20.9631 13.2554 21.0558 13.9655 20.1681C14.3002 19.7497 14.4081 19.1937 14.2541 18.6804L13.2317 15.2724C13.1162 14.8874 13.4045 14.5 13.8064 14.5H18.3815C19.7002 14.5 20.658 13.246 20.311 11.9738L18.4019 4.97376C18.1646 4.10364 17.3743 3.5 16.4724 3.5Z" stroke="currentColor" stroke-linecap="round"></path><path d="M7 14.5L7 3.5" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path></svg><span class="fern-button-text">No</span></span></button></span></div></div></div></div><a tabindex="0" aria-disabled="false" data-state="off" class="fern-button outlined normal" target="_blank" rel="noreferrer" href="https://github.com/deepgram/deepgram-fern-config/blob/main/fern/docs/use-deepgram-with-dialogflow-cx.mdx?plain=1"><span class="fern-button-content"><svg width="1.5em" height="1.5em" stroke-width="1.5" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor"><path d="M3 21L12 21H21" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12.2218 5.82839L15.0503 2.99996L20 7.94971L17.1716 10.7781M12.2218 5.82839L6.61522 11.435C6.42769 11.6225 6.32233 11.8769 6.32233 12.1421L6.32233 16.6776L10.8579 16.6776C11.1231 16.6776 11.3774 16.5723 11.565 16.3847L17.1716 10.7781M12.2218 5.82839L17.1716 10.7781" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path></svg><span class="fern-button-text">Edit this page</span></span></a></div><div class="not-prose grid grid-cols-1"><a class="fern-card interactive my-12 flex flex-1 items-center rounded-xl p-6" href="/docs/makecom-deepgram-integration"><div class="flex-1"><div class="text-base font-semibold">Make.com and Deepgram</div></div><span class="sm-4 t-muted sm:border-default inline-flex items-center gap-2 py-2.5 text-sm sm:ml-6 sm:border-l sm:pl-6"><span class="hidden leading-none sm:inline">Up Next</span><svg width="1.5em" height="1.5em" stroke-width="1.5" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" color="currentColor" class="size-icon"><path d="M9 6L15 12L9 18" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path></svg></span></a></div></footer><style> #builtwithfern { display: flex !important; opacity: 100% !important; } #builtwithfern * { display: initial !important; width: unset !important; opacity: 100% !important; } #builtwithfern, #builtwithfern * { visibility: initial !important; overflow: visible !important; position: relative !important; left: unset !important; top: unset !important; right: unset !important; bottom: unset !important; inset: unset !important; }</style><a id="builtwithfern" class="mx-auto flex items-baseline gap-1 mx-auto my-8 w-fit" href="https://buildwithfern.com/?utm_campaign=buildWith&amp;utm_medium=docs&amp;utm_source=developers.deepgram.com" data-state="closed"><span class="t-muted whitespace-nowrap text-xs">Built with</span><svg viewBox="0 0 604 164" fill="none" xmlns="http://www.w3.org/2000/svg" class="transition" style="aspect-ratio:604/164;height:14px;margin-top:-2px"><path fill-rule="evenodd" clip-rule="evenodd" d="M295.294 0H255.861H255.836C234.047 0 221.437 11.4661 221.437 33.483V47.2372H193.242V75.2033H221.437V160.5H253.547V75.2033H288.404V47.2372H253.547V37.3728C253.547 30.7118 257.208 27.9661 263.87 27.9661H295.294V0ZM345.26 43.8081C311.777 43.8081 288.844 67.1979 288.844 103.198H288.87C288.87 139.884 311.802 163.96 346.43 163.96C375.311 163.96 392.727 149.291 399.388 126.816H366.591C363.591 133.02 356.955 137.367 346.633 137.367C331.277 137.367 321.87 129.562 320.497 115.35H400.761C401.219 110.545 401.447 106.401 401.447 102.283C401.447 66.2826 378.744 43.8081 345.26 43.8081ZM369.108 90.5877V91.0453H320.269C321.184 77.7487 329.675 69.0284 345.26 69.0284C360.845 69.0284 369.108 77.7487 369.108 90.5877ZM412.668 47.2321H440.863V67.1898C443.609 54.3508 452.787 47.2321 467.227 47.2321H487.414V51.122C487.414 64.4186 476.634 75.1982 463.338 75.1982C450.727 75.1982 444.753 81.6304 444.753 94.4694V160.52H412.642V47.2321H412.668ZM526.939 47.24H498.744H498.719V160.503H530.829V96.0789C530.829 81.6382 539.321 72.6891 552.16 72.6891C564.999 72.6891 571.889 80.0366 571.889 95.1637V160.528H604V91.7315C604 61.7061 586.559 43.8078 558.821 43.8078C545.753 43.8078 533.601 48.8417 526.939 58.7061V47.24Z" class="fill-grayscale-a10"></path><path d="M149.383 80.2222C138.594 71.101 122.341 67.4445 107.936 78.0925C107.273 78.5747 106.449 77.751 106.952 77.1081C110.367 72.7082 114.325 67.9668 117.519 63.2053C120.774 58.3233 125.636 54.8275 131.241 53.1198C161.076 44.079 152.116 0 152.116 0C152.116 0 106.027 2.97342 111.713 42.7329C112.657 49.3829 110.889 56.1535 106.731 61.4374C101.628 67.8865 95.7008 74.0543 91.4014 78.5144C90.4973 79.4386 88.9705 78.5546 89.3321 77.309C93.4909 63.3058 96.5246 41.648 82.1195 27.685L61.848 10.849L57.9504 15.9922C46.3581 31.2812 49.7534 52.8385 65.0625 64.4108C73.8422 71.0407 77.8201 78.2533 77.1973 86.169C76.8156 90.9104 74.6659 95.3505 71.4514 98.8663C65.4041 105.496 59.7586 112.608 55.3989 120.846C54.7962 121.991 53.0483 121.549 53.1086 120.243C53.7314 106.641 52.4255 75.983 29.5221 65.0336L3.88635 55.1289L1.89737 61.0556C-4.55174 80.182 5.99588 100.614 25.1021 107.104C41.7171 112.749 47.6439 123.457 43.6458 139.51C43.465 140.092 40.572 156.627 40.9738 163.96H59.3969C60.0198 152.589 71.9536 145.115 82.3003 149.756C85.2135 151.062 88.207 152.93 91.2809 155.341C107.755 168.32 132.025 165.246 144.983 148.752L148.68 144.05L125.375 127.315C109.383 114.738 88.0463 120.424 72.255 131.192C70.929 132.096 69.2414 130.65 69.9847 129.203C89.0709 91.7542 113.883 91.8346 123.607 100.152C135.4 110.238 153.261 108.429 163.266 96.5961L166.139 93.2007L149.363 80.2222H149.383Z" class="fill-grayscale-a10"></path></svg></a></article></main></div></div><footer id="fern-footer" class=""></footer></div></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"baseUrl":{"domain":"developers.deepgram.com"},"layout":{"pageWidth":{"type":"full"},"searchbarPlacement":"HEADER","tabsPlacement":"HEADER","contentAlignment":"CENTER","headerPosition":"FIXED","disableHeader":false},"title":"Deepgram | Documentation","favicon":"26b77654-ddc3-48b3-b5a8-1cad6aa0d4c4","colors":{"dark":{"type":"dark","accentPrimary":{"r":161,"g":249,"b":212,"a":1},"logo":"d197717d-51e5-4edb-8918-184b6d1e268e","background":{"type":"solid","r":11,"g":11,"b":12,"a":1},"border":{"r":44,"g":44,"b":51,"a":1},"cardBackground":{"r":26,"g":26,"b":31,"a":1},"sidebarBackground":{"r":11,"g":11,"b":12,"a":1},"headerBackground":{"r":26,"g":26,"b":31,"a":1}}},"js":{"remote":[{"url":"https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/component.js","strategy":"lazyOnload"},{"url":"https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/dist/output.js","strategy":"beforeInteractive"}]},"navbarLinks":[],"logo":{"height":24,"href":"/","dark":{"src":"https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/logo.svg","width":176,"height":25}},"content":{"slug":"docs/use-deepgram-with-dialogflow-cx","title":{"engine":"mdx-bundler","code":"var Component=(()=\u003e{var f=Object.create;var s=Object.defineProperty;var l=Object.getOwnPropertyDescriptor;var x=Object.getOwnPropertyNames;var g=Object.getPrototypeOf,C=Object.prototype.hasOwnProperty;var D=(e,n)=\u003e()=\u003e(n||e((n={exports:{}}).exports,n),n.exports),M=(e,n)=\u003e{for(var o in n)s(e,o,{get:n[o],enumerable:!0})},u=(e,n,o,d)=\u003e{if(n\u0026\u0026typeof n==\"object\"||typeof n==\"function\")for(let t of x(n))!C.call(e,t)\u0026\u0026t!==o\u0026\u0026s(e,t,{get:()=\u003en[t],enumerable:!(d=l(n,t))||d.enumerable});return e};var _=(e,n,o)=\u003e(o=e!=null?f(g(e)):{},u(n||!e||!e.__esModule?s(o,\"default\",{value:e,enumerable:!0}):o,e)),X=e=\u003eu(s({},\"__esModule\",{value:!0}),e);var i=D((v,a)=\u003e{a.exports=_jsx_runtime});var w={};M(w,{default:()=\u003ep,frontmatter:()=\u003eh});var r=_(i());var{useMDXComponents:c}=MdxJsReact;var h=void 0;function m(e){let n={p:\"p\",...c(),...e.components};return(0,r.jsx)(n.p,{children:\"Google Dialogflow CX and Deepgram\"})}function p(e={}){let{wrapper:n}={...c(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(m,{...e})}):m(e)}return X(w);})();\n;return Component;","frontmatter":{},"scope":{},"jsxRefs":[]},"subtitle":{"engine":"mdx-bundler","code":"var Component=(()=\u003e{var f=Object.create;var r=Object.defineProperty;var l=Object.getOwnPropertyDescriptor;var x=Object.getOwnPropertyNames;var g=Object.getPrototypeOf,h=Object.prototype.hasOwnProperty;var w=(e,n)=\u003e()=\u003e(n||e((n={exports:{}}).exports,n),n.exports),C=(e,n)=\u003e{for(var o in n)r(e,o,{get:n[o],enumerable:!0})},i=(e,n,o,a)=\u003e{if(n\u0026\u0026typeof n==\"object\"||typeof n==\"function\")for(let t of x(n))!h.call(e,t)\u0026\u0026t!==o\u0026\u0026r(e,t,{get:()=\u003en[t],enumerable:!(a=l(n,t))||a.enumerable});return e};var D=(e,n,o)=\u003e(o=e!=null?f(g(e)):{},i(n||!e||!e.__esModule?r(o,\"default\",{value:e,enumerable:!0}):o,e)),M=e=\u003ei(r({},\"__esModule\",{value:!0}),e);var u=w((j,d)=\u003e{d.exports=_jsx_runtime});var X={};C(X,{default:()=\u003em,frontmatter:()=\u003e_});var s=D(u());var{useMDXComponents:c}=MdxJsReact;var _=void 0;function p(e){let n={p:\"p\",...c(),...e.components};return(0,s.jsx)(n.p,{children:\"Dialogflow CX is a framework for building virtual agents. Learn how to incorporate Deepgram\\u2019s transcription and text-to-speech for improved accuracy.\"})}function m(e={}){let{wrapper:n}={...c(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(p,{...e})}):p(e)}return M(X);})();\n;return Component;","frontmatter":{},"scope":{},"jsxRefs":[]},"tableOfContents":[{"simpleString":"Before you Begin","anchorString":"before-you-begin","children":[]},{"simpleString":"Create a Dialogflow CX Agent","anchorString":"create-a-dialogflow-cx-agent","children":[]},{"simpleString":"Try Out the Demo","anchorString":"try-out-the-demo","children":[]},{"simpleString":"High-Level Architecture","anchorString":"high-level-architecture","children":[]},{"simpleString":"Deeper Look","anchorString":"deeper-look","children":[]},{"simpleString":"Options for Customizing Utterance Segmentation","anchorString":"options-for-customizing-utterance-segmentation","children":[{"simpleString":"Update Dialogflow with Resumed Utterances","anchorString":"update-dialogflow-with-resumed-utterances","children":[]},{"simpleString":"Don't Segment on Endpoints","anchorString":"dont-segment-on-endpoints","children":[]},{"simpleString":"Replace Word Timing Logic with utterance_end_ms","anchorString":"replace-word-timing-logic-with-utterance_end_ms","children":[]}]},{"simpleString":"AudioCodes as an Alternative","anchorString":"audiocodes-as-an-alternative","children":[]}],"content":{"engine":"mdx-bundler","code":"var Component=(()=\u003e{var g=Object.create;var r=Object.defineProperty;var f=Object.getOwnPropertyDescriptor;var m=Object.getOwnPropertyNames;var w=Object.getPrototypeOf,y=Object.prototype.hasOwnProperty;var D=(n,e)=\u003e()=\u003e(e||n((e={exports:{}}).exports,e),e.exports),v=(n,e)=\u003e{for(var i in e)r(n,i,{get:e[i],enumerable:!0})},l=(n,e,i,o)=\u003e{if(e\u0026\u0026typeof e==\"object\"||typeof e==\"function\")for(let a of m(e))!y.call(n,a)\u0026\u0026a!==i\u0026\u0026r(n,a,{get:()=\u003ee[a],enumerable:!(o=f(e,a))||o.enumerable});return n};var b=(n,e,i)=\u003e(i=n!=null?g(w(n)):{},l(e||!n||!n.__esModule?r(i,\"default\",{value:n,enumerable:!0}):i,n)),x=n=\u003el(r({},\"__esModule\",{value:!0}),n);var c=D((A,d)=\u003e{d.exports=_jsx_runtime});var k={};v(k,{default:()=\u003ep,frontmatter:()=\u003eT});var t=b(c());var{useMDXComponents:s}=MdxJsReact;var T={title:\"Google Dialogflow CX and Deepgram\",subtitle:\"Dialogflow CX is a framework for building virtual agents. Learn how to incorporate Deepgram's transcription and text-to-speech for improved accuracy.\",slug:\"docs/use-deepgram-with-dialogflow-cx\"};function h(n){let e={a:\"a\",code:\"code\",h1:\"h1\",h2:\"h2\",hr:\"hr\",img:\"img\",li:\"li\",ol:\"ol\",p:\"p\",strong:\"strong\",ul:\"ul\",...s(),...n.components},{CodeBlocks:i,Info:o}=e;return i||u(\"CodeBlocks\",!0),o||u(\"Info\",!0),(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(e.p,{children:[\"In this guide, we\\u2019ll explain how to talk to a Dialogflow CX agent using Deepgram for transcription and text-to-speech. We\\u2019ll do this by walking through Deepgram\\u2019s \",(0,t.jsx)(e.a,{href:\"https://github.com/deepgram/dialogflow-example\",children:\"Dialogflow Example\"}),\" repo on GitHub.\"]}),`\n`,(0,t.jsx)(e.h2,{id:\"before-you-begin\",children:\"Before you Begin\"}),`\n`,(0,t.jsx)(o,{children:(0,t.jsxs)(e.p,{children:[\"Before you can use Deepgram, you\\u2019ll need to \",(0,t.jsx)(e.a,{href:\"https://console.deepgram.com/signup?jump=keys\",children:\"create a Deepgram account\"}),\". Signup is free and includes \",(0,t.jsx)(e.strong,{children:\"$200\"}),\" in free credit and access to all of Deepgram\\u2019s features!\"]})}),`\n`,(0,t.jsx)(o,{children:(0,t.jsxs)(e.p,{children:[\"Before you start, you\\u2019ll need to follow the steps in the \",(0,t.jsx)(e.a,{href:\"/docs/make-your-first-api-request\",children:\"Make Your First API Request\"}),\" guide to obtain a Deepgram API key, and configure your environment if you are choosing to use a Deepgram SDK.\"]})}),`\n`,(0,t.jsx)(e.h2,{id:\"create-a-dialogflow-cx-agent\",children:\"Create a Dialogflow CX Agent\"}),`\n`,(0,t.jsxs)(e.p,{children:[\"You\\u2019ll also need a Dialogflow agent to talk to. If you don\\u2019t already have one, the easiest approach is to create a \",(0,t.jsx)(e.a,{href:\"https://cloud.google.com/dialogflow/cx/docs/concept/agents-prebuilt\",children:\"prebuilt agent\"}),\".\"]}),`\n`,(0,t.jsx)(e.h2,{id:\"try-out-the-demo\",children:\"Try Out the Demo\"}),`\n`,(0,t.jsxs)(e.p,{children:[\"Clone the \",(0,t.jsx)(e.a,{href:\"https://github.com/deepgram/dialogflow-example\",children:\"Dialogflow Example\"}),\" repo and follow the instructions in \",(0,t.jsx)(e.code,{children:\"README.md\"}),\". You\\u2019ll need to provide your Deepgram API key and your Dialogflow agent information. The \",(0,t.jsx)(e.a,{href:\"https://github.com/deepgram/dialogflow-example#demo\",children:\"video\"}),\" in the README shows how the demo should work.\"]}),`\n`,(0,t.jsx)(e.h1,{id:\"high-level-architecture\",children:\"High-Level Architecture\"}),`\n`,(0,t.jsx)(e.p,{children:\"Dialogflow agents can accept user input in the form of audio or text. If you send audio to an agent, Google will transcribe it with their own speech-to-text engine. In order to use Deepgram\\u2019s transcription, we need to transcribe the audio outside of Dialogflow and send the resulting text to our agent. If we also want to use Deepgram\\u2019s text-to-speech for the bot\\u2019s voice, we must configure Dialogflow to return agent responses as text. This diagram depicts the full process:\"}),`\n`,(0,t.jsx)(e.p,{children:(0,t.jsx)(e.img,{src:\"https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/images/c213cc7-dialogflow-architecture-tts.png\",alt:\"\",height:\"409\",width:\"976\"})}),`\n`,(0,t.jsxs)(e.ol,{children:[`\n`,(0,t.jsx)(e.li,{children:\"The user speaks into their microphone.\"}),`\n`,(0,t.jsx)(e.li,{children:\"The integration continuously streams the user\\u2019s speech to Deepgram.\"}),`\n`,(0,t.jsx)(e.li,{children:\"Deepgram streams back transcripts.\"}),`\n`,(0,t.jsxs)(e.li,{children:[\"The integration analyzes the transcripts to determine when the user has completed a thought (\",(0,t.jsx)(e.a,{href:\"https://deepgram.com/learn/building-a-conversational-ai-flow-with-deepgram\",children:\"\\u201Cutterance segmentation\\u201D\"}),\"). When it finds a complete utterance, it sends it to the Dialogflow agent as text.\"]}),`\n`,(0,t.jsx)(e.li,{children:\"The agent replies with its response, also in the form of text.\"}),`\n`,(0,t.jsx)(e.li,{children:\"The agent\\u2019s response is sent to Deepgram\\u2019s text-to-speech engine.\"}),`\n`,(0,t.jsx)(e.li,{children:\"Deepgram returns the response as audio.\"}),`\n`,(0,t.jsx)(e.li,{children:\"The audio is played to the user.\"}),`\n`,(0,t.jsx)(e.li,{children:\"The process repeats until the conversation is finished.\"}),`\n`]}),`\n`,(0,t.jsx)(e.h1,{id:\"deeper-look\",children:\"Deeper Look\"}),`\n`,(0,t.jsxs)(e.p,{children:[\"At any given time, \",(0,t.jsx)(e.code,{children:\"server.js\"}),\" is in one of two states. In the \",(0,t.jsx)(e.strong,{children:\"awaiting utterance\"}),\" state, it is collecting transcripts from Deepgram and looking for an indication that the user has finished their thought. In the \",(0,t.jsx)(e.strong,{children:\"awaiting bot reply\"}),\" state, it is discarding transcripts because we\\u2019ve already sent the utterance to Dialogflow and it is now the bot\\u2019s turn to speak.\"]}),`\n`,(0,t.jsxs)(e.p,{children:[\"This is the code that runs when \",(0,t.jsx)(e.code,{children:\"server.js\"}),\" receives a transcription result from Deepgram (note the two states):\"]}),`\n`,(0,t.jsx)(i,{items:[{code:`function handleDgResults(start, duration, isFinal, speechFinal, transcript, words) {\n switch (voicebotState) {\n case STATES.AwaitingUtterance:\n // Update \\`finalizedTranscript\\` and \\`unfinalizedTranscript\\` in light of the new result\n updateTranscriptState(transcript, isFinal);\n\n // Update \\`latestTimeSeen\\` and \\`latestFinalizedWordEnd\\` in light of the new result\n updateSilenceDetectionState(start, duration, words, isFinal);\n\n if (finalizedTranscript === \"\") {\n return;\n }\n\n let silenceDetected = \n unfinalizedTranscript === \"\" \u0026\u0026 latestTimeSeen - latestFinalizedWordEnd \u003e 1.25;\n\n if (silenceDetected || speechFinal) {\n changeVoicebotState(STATES.AwaitingBotReply);\n \n // Send the completed utterance to Dialogflow\n sendUtteranceDownstream(finalizedTranscript); \n }\n\n break;\n case STATES.AwaitingBotReply:\n // Discard the transcript; do nothing\n break;\n }\n}\n`,language:\"javascript\",highlightLines:[],highlightStyle:\"highlight\",maxLines:20,title:\"JavaScript\",wordWrap:!1,matchLanguage:void 0}]}),`\n`,(0,t.jsxs)(e.p,{children:[(0,t.jsx)(e.code,{children:\"finalizedTranscript\"}),\" is all of the concatenated \",(0,t.jsx)(e.code,{children:\"is_final=true\"}),\" results that we\\u2019ve received since the start of the current utterance. \",(0,t.jsx)(e.code,{children:\"unfinalizedTranscript\"}),\" is the most recent \",(0,t.jsx)(e.code,{children:\"is_final=false\"}),\" result for which we have not yet seen an \",(0,t.jsx)(e.code,{children:\"is_final=true\"}),\". (If these concepts are unfamiliar, have a look at the documentation on \",(0,t.jsx)(e.a,{href:\"/docs/interim-results\",children:\"interim results\"}),\".)\"]}),`\n`,(0,t.jsxs)(e.p,{children:[\"When we detect that the current \",(0,t.jsx)(e.code,{children:\"finalizedTranscript\"}),\" contains a full utterance, we send it off to Dialogflow and await the agent\\u2019s reply.\"]}),`\n`,(0,t.jsx)(e.p,{children:\"This detection happens when there is a sufficient period of silence after the transcript. That is, when either of these conditions is met:\"}),`\n`,(0,t.jsxs)(e.ol,{children:[`\n`,(0,t.jsxs)(e.li,{children:[\"We\\u2019ve reached an \",(0,t.jsx)(e.a,{href:\"/docs/endpointing\",children:\"endpoint\"}),\" (\",(0,t.jsx)(e.code,{children:\"speech_final=true\"}),\"), or\"]}),`\n`,(0,t.jsx)(e.li,{children:\"The transcripts reveal a 1.25 second silence after the last finalized word.\"}),`\n`]}),`\n`,(0,t.jsx)(e.h1,{id:\"options-for-customizing-utterance-segmentation\",children:\"Options for Customizing Utterance Segmentation\"}),`\n`,(0,t.jsxs)(e.p,{children:[\"The approach described above is a solid starting point for detecting end of utterance, but depending on your needs you may want to explore various customizations. For example, you can adjust the \",(0,t.jsx)(e.code,{children:\"endpointing\"}),\" and silence detection values (currently set to \",(0,t.jsx)(e.code,{children:\"500ms\"}),\" and \",(0,t.jsx)(e.code,{children:\"1.25s\"}),\", respectively). Below are some additional modifications you might consider.\"]}),`\n`,(0,t.jsx)(e.h2,{id:\"update-dialogflow-with-resumed-utterances\",children:\"Update Dialogflow with Resumed Utterances\"}),`\n`,(0,t.jsx)(e.p,{children:\"You may want to send tentative utterances to Dialogflow. Then if the user resumes speaking before the agent has replied, you can cancel the original Dialogflow operation and send the new, full utterance to Dialogflow instead. This comes with a couple of advantages:\"}),`\n`,(0,t.jsxs)(e.ul,{children:[`\n`,(0,t.jsxs)(e.li,{children:[(0,t.jsx)(e.strong,{children:\"Lower latency\"}),\". For example, you can set endpointing to a snappy \",(0,t.jsx)(e.code,{children:\"10ms\"}),\" and send the utterance to Dialogflow right away at an endpoint. Then you get the agent reply and hold it until you verify that the user has really stopped speaking, at which point you send it to the user immediately.\"]}),`\n`,(0,t.jsxs)(e.li,{children:[(0,t.jsx)(e.strong,{children:\"Last-minute interjections\"}),\". With this approach the user is able to add to their utterance right until the bot reply is sent to them.\"]}),`\n`]}),`\n`,(0,t.jsxs)(e.p,{children:[\"If you go this route, make sure that any actions taken by the Dialogflow agent on the tentative utterance are indeed reversible in the event of a replacement utterance. It is possible to rewind the state of the agent itself (see the parameters \",(0,t.jsx)(e.a,{href:\"https://cloud.google.com/dialogflow/cx/docs/reference/rest/v3/QueryParameters\",children:\"here\"}),\"), but the agent can\\u2019t uncall any webhooks that it called while fulfilling the user\\u2019s request.\"]}),`\n`,(0,t.jsx)(e.h2,{id:\"dont-segment-on-endpoints\",children:\"Don\\u2019t Segment on Endpoints\"}),`\n`,(0,t.jsxs)(e.p,{children:[\"Endpointing is sometimes said to be a poor indicator of end of utterance. On one hand, an \",(0,t.jsx)(e.code,{children:\"endpointing\"}),\" value that is too low can lead to false positives. On the other hand, an \",(0,t.jsx)(e.code,{children:\"endpointing\"}),\" value that is too high may simply \",(0,t.jsx)(e.a,{href:\"/docs/understanding-end-of-speech-detection-while-streaming#limitations-of-endpointing\",children:\"not fire due to background noise\"}),\". So you can try leaving \",(0,t.jsx)(e.code,{children:\"endpointing\"}),\" at its default value of \",(0,t.jsx)(e.code,{children:\"10ms\"}),\" (for rapid finalization of transcripts) and only doing utterance segmentation based on word timing analysis.\"]}),`\n`,(0,t.jsxs)(e.h2,{id:\"replace-word-timing-logic-with-utterance_end_ms\",children:[\"Replace Word Timing Logic with \",(0,t.jsx)(e.code,{children:\"utterance_end_ms\"})]}),`\n`,(0,t.jsxs)(e.p,{children:[\"Finally, you may choose to use Deepgram\\u2019s \",(0,t.jsx)(e.a,{href:\"/docs/understanding-end-of-speech-detection-while-streaming#introducing-the-utteranceend-feature\",children:\"UtteranceEnd\"}),\" feature in place of the word timing logic. This is really a matter of preference; do you prefer the conciseness of the built-in \",(0,t.jsx)(e.code,{children:\"UtteranceEnd\"}),\" message, or the clarity and flexibility of the explicit word timing logic?\"]}),`\n`,(0,t.jsx)(e.h1,{id:\"audiocodes-as-an-alternative\",children:\"AudioCodes as an Alternative\"}),`\n`,(0,t.jsxs)(e.p,{children:[\"Deepgram\\u2019s partner AudioCodes offers a managed solution called \",(0,t.jsx)(e.a,{href:\"https://voiceaiconnect.audiocodes.com/google-dialogflow\",children:\"VoiceAI Connect\"}),\", which enables you to pair Deepgram\\u2019s speech-to-text with many different bot frameworks, including Dialogflow CX. Read more about our integration with AudioCodes \",(0,t.jsx)(e.a,{href:\"https://deepgram.com/learn/audiocodes-voicebots-integration\",children:\"here\"}),\".\"]}),`\n`,(0,t.jsx)(e.hr,{}),`\n`,(0,t.jsx)(e.p,{children:\"What\\u2019s Next\"}),`\n`,(0,t.jsxs)(e.ul,{children:[`\n`,(0,t.jsx)(e.li,{children:(0,t.jsx)(e.a,{href:\"/reference/deepgram-api-overview\",children:\"Deepgram API Overview\"})}),`\n`]})]})}function p(n={}){let{wrapper:e}={...s(),...n.components};return e?(0,t.jsx)(e,{...n,children:(0,t.jsx)(h,{...n})}):h(n)}function u(n,e){throw new Error(\"Expected \"+(e?\"component\":\"object\")+\" `\"+n+\"` to be defined: you likely forgot to import, pass, or provide it.\")}return x(k);})();\n;return Component;","frontmatter":{"title":"Google Dialogflow CX and Deepgram","subtitle":"Dialogflow CX is a framework for building virtual agents. Learn how to incorporate Deepgram's transcription and text-to-speech for improved accuracy.","slug":"docs/use-deepgram-with-dialogflow-cx","edit-this-page-url":"https://github.com/deepgram/deepgram-fern-config/blob/main/fern/docs/use-deepgram-with-dialogflow-cx.mdx?plain=1"},"scope":{},"jsxRefs":["Info","CodeGroup"]},"breadcrumb":[{"title":"Integrations","pointsTo":"docs/deepgram-with-amazon-connect"}],"neighbors":{"prev":{"slug":"docs/genesys-with-deepgram","title":"Genesys and Deepgram"},"next":{"slug":"docs/makecom-deepgram-integration","title":"Make.com and Deepgram"}},"hasAside":false,"type":"markdown-page","apis":{},"endpointIdsToSlugs":{}},"navigation":{"currentTabIndex":6,"tabs":[{"type":"tabGroup","title":"Home","index":0,"slug":"home","pointsTo":"home/introduction"},{"type":"tabGroup","title":"Voice Agent","index":1,"slug":"voice-agent","pointsTo":"docs/voice-agent"},{"type":"tabGroup","title":"Speech to Text","index":2,"slug":"speech-to-text","pointsTo":"docs/pre-recorded-audio"},{"type":"tabGroup","title":"Text to Speech","index":3,"slug":"text-to-speech","pointsTo":"docs/tts-rest"},{"type":"tabGroup","title":"Intelligence","index":4,"slug":"intelligence","pointsTo":"docs/audio-intelligence"},{"type":"tabGroup","title":"API Ref","index":5,"slug":"reference","pointsTo":"reference/deepgram-api-overview"},{"type":"tabGroup","title":"Guides","index":6,"slug":"docs","pointsTo":"docs/make-your-first-api-request"},{"type":"tabGroup","title":"SDKs","index":7,"slug":"sdks","pointsTo":"docs/deepgram-sdks"},{"type":"tabGroup","title":"Self-Hosted Deployments","index":8,"slug":"self-hosted","pointsTo":"docs/self-hosted-introduction"},{"type":"tabGroup","title":"Security","index":9,"slug":"security","pointsTo":"docs/security-policy"}],"versions":[],"sidebar":{"type":"sidebarRoot","id":"e70a6092a728d122c5e85dd23101166726fa4d83c0ae8751a1ebdd8dbbfcc3a5","children":[{"type":"section","id":"ec27da4775293db97c382f6e6c72bc834579fff5fe8297b2b1b7ee035fd49122","children":[{"type":"page","id":"72597ceb0635f8c20461f5337e7cdc78abf13f95c06822a389268da34555f749","title":"Make Your First API Request","slug":"docs/make-your-first-api-request","pageId":"docs/make-your-first-api-request.mdx"},{"type":"page","id":"17d112c737122bee22a39f5f5ac8025e3f693ae494163f457fe60bd3ed5c8add","title":"Authenticating","slug":"docs/authenticating","pageId":"docs/authenticating.mdx"},{"type":"page","id":"fec90bb78783684dc4414501def0851ccf7dff7d1984b738b516de9932bda853","title":"Model Metadata","slug":"docs/model-metadata","pageId":"docs/model-metadata.mdx"},{"type":"page","id":"bf4ba24d3e610464ef6c25f90db8192670df1d766422218e0639782a00022f79","title":"Managing Projects","slug":"docs/managing-projects","pageId":"docs/managing-projects.mdx"},{"type":"page","id":"6e5a81d8593b9492953aa49c2d23f971537726b87ad84ac0949c9861f35b2ba3","title":"Using Multiple Projects","slug":"docs/using-multiple-projects","pageId":"docs/using-multiple-projects.mdx"},{"type":"page","id":"3fb86ef1d374c1ac3350ec8acfa8d0526140409594a0cacf87192399c4009ac3","title":"Working With Roles \u0026 API Scopes","slug":"docs/working-with-roles","pageId":"docs/working-with-roles.mdx"},{"type":"page","id":"41a157108029592c093c7499545c4dec805c71c529b33d26eb8c5a3a163a5f93","title":"Supported Audio Formats","slug":"docs/supported-audio-formats","pageId":"docs/supported-audio-formats.mdx"},{"type":"page","id":"61bf2ff42bbbd494643e7cc6a5940751a066f8292d21962da8a1232377c5e486","title":"Deployment Options","slug":"docs/deployment-options","pageId":"docs/deployment-options.mdx"},{"type":"page","id":"ebe1dd70e58a1952bbb87a12d90efa75a11919a3749de91c1535c623d70f6b21","title":"Creating API Keys","slug":"docs/create-additional-api-keys","pageId":"docs/create-additional-api-keys.mdx"},{"type":"page","id":"130253c7d32a0badaa649170d5341cbc84acd66bebe1a3415abc543106de4f5d","title":"Using the Sec-WebSocket-Protocol","slug":"docs/using-the-sec-websocket-protocol","pageId":"docs/using-the-sec-websocket-protocol.mdx"},{"type":"page","id":"dacdcb100e05959c173b4724f33fa5642f412513e94f60628ffb62dd7e1619b7","title":"Logs \u0026 Usage Data","slug":"docs/using-logs-usage","pageId":"docs/using-logs-usage.mdx"},{"type":"page","id":"f63f72d7546864bc3d88a81c71c0702c4e4616699fb0a2d9a4da2b1dda5a2c5a","title":"Model Improvement Partnership Program","slug":"docs/the-deepgram-model-improvement-partnership-program","pageId":"docs/the-deepgram-model-improvement-partnership-program.mdx"},{"type":"page","id":"ec6f3cd6a7c662a1f385e413377af725aa9c87d3c81938dbcf295799b0c751cb","title":"Working With Concurrency Rate Limits","slug":"docs/working-with-concurrency-rate-limits","pageId":"docs/working-with-concurrency-rate-limits.mdx"}],"title":"Fundamentals","slug":"docs/fundamentals","pointsTo":"docs/make-your-first-api-request"},{"type":"section","id":"0da5260fb2953b1d8dec9b7bbfff502df209197366bd8ea4273e0f68ec592d1b","children":[{"type":"page","id":"84226d8c3d9f65d3e764287f2caf9fe049ba9301c32ac2aa9f8e8800fa7bfc2a","title":"Build a Voice Agent with Twilio \u0026 OpenAI \u0026 Deepgram","slug":"docs/build-voice-agent-with-twilio-deepgram-openai","pageId":"docs/build-voice-agent-with-twilio-deepgram-openai.mdx"},{"type":"page","id":"4fdf9d75e08e4056377bda237adc9c939e18c5aa13a763b8e652ddf110943330","title":"Calculate Talk Time Analytics","slug":"docs/calculate-talk-time-analytics","pageId":"docs/calculate-talk-time-analytics.mdx"},{"type":"page","id":"3f550d055ddfed8ce8f317b1e7d868d046b2ce4961da1cd92c1b0641a042a89f","title":"Transcribe Meetings in Realtime","slug":"docs/transcribe-meetings-in-realtime","pageId":"docs/transcribe-meetings-in-realtime.mdx"},{"type":"page","id":"ea66ac82dc140406c6f810e95c5278b5f6568280951912ed08b6227f0f8d886b","title":"Transcribe Recorded Calls With Twilio","slug":"docs/transcribe-recorded-calls-with-twilio","pageId":"docs/transcribe-recorded-calls-with-twilio.mdx"}],"title":"Use Case Examples","slug":"docs/use-case-examples","pointsTo":"docs/build-voice-agent-with-twilio-deepgram-openai"},{"type":"section","id":"5da5cc748af705d3bad0f55d6b164e274ebe00d2640598a748897560acc2bc00","children":[{"type":"page","id":"016a2cdf3132c8ee79ae2347b7b2e1304aaf6acd5bf962544643e34d7b7165fa","title":"Amazon Connect and Deepgram","slug":"docs/deepgram-with-amazon-connect","pageId":"docs/deepgram-with-amazon-connect.mdx"},{"type":"page","id":"f52bc4b28d07642b2a8313330f8579cd9b64482ac1eabb9586c361a4a234bbe6","title":"AWS S3 Presigned URLs and Deepgram","slug":"docs/using-aws-s3-presigned-urls-with-the-deepgram-api","pageId":"docs/using-aws-s3-presigned-urls-with-the-deepgram-api.mdx"},{"type":"page","id":"caf1dd1d39d0634d7d6a5895787cd70748ccc40393a397fc9b83e6a9e7840069","title":"Genesys and Deepgram","slug":"docs/genesys-with-deepgram","pageId":"docs/genesys-with-deepgram.mdx"},{"type":"page","id":"38dfc5c6acdc8bf48c2b7901677f0f539e8a2620dcbf56de8b483e431f8ea179","title":"Google Dialogflow CX and Deepgram","slug":"docs/use-deepgram-with-dialogflow-cx","pageId":"docs/use-deepgram-with-dialogflow-cx.mdx"},{"type":"page","id":"0aa13cd9944ce5fe355137ee7179a7f689871a3e249813fcc3a18ba7a6d3e0ac","title":"Make.com and Deepgram","slug":"docs/makecom-deepgram-integration","pageId":"docs/makecom-deepgram-integration.mdx"},{"type":"page","id":"4d7939a92a79d60757ba480ad93dc6d1056a68a414d3a6108b0b9102c56c7278","title":"Twilio and Deepgram STT","slug":"docs/on-premise-twilio-integration","pageId":"docs/on-premise-twilio-integration.mdx"},{"type":"page","id":"40ac5dece0044a0df752fba46d04d9aadd53171e4380ba4d50209210b22642da","title":"Twilio and Deepgram TTS","slug":"docs/twilio-and-deepgram-tts","pageId":"docs/twilio-and-deepgram-tts.mdx"},{"type":"page","id":"d99a62dc22499a55b9544bc07d8fd057b6d163d8c47d04b31abc1eada10bcc25","title":"Twilio and Deepgram Voice Agent","slug":"docs/twilio-and-deepgram-voice-agent","pageId":"docs/twilio-and-deepgram-voice-agent.mdx"},{"type":"page","id":"bf1b77093b4e067c31f2d777afa7b1b2224ef587881aff480779b2038c41d9f3","title":"Zapier and Deepgram","slug":"docs/zapier-integration","pageId":"docs/zapier-integration.mdx"},{"type":"page","id":"0916f462098ba6ee6f4df808a6ad63ae8ef6137dc5b3b165d934ab6be6d9278f","title":"Zoom and Deepgram","slug":"docs/integrate-deepgram-with-zoom","pageId":"docs/integrate-deepgram-with-zoom.mdx"}],"title":"Integrations","slug":"docs/integrations","pointsTo":"docs/deepgram-with-amazon-connect"}]},"trailingSlash":false},"edgeFlags":{"isApiPlaygroundEnabled":true,"isApiScrollingDisabled":false,"isWhitelabeled":false,"isSeoDisabled":false,"isTocDefaultEnabled":false,"isSnippetTemplatesEnabled":false,"isSearchDisabled":true,"isHttpSnippetsEnabled":true,"isInlineFeedbackEnabled":false,"isDarkCodeEnabled":false,"isProxyDisabled":false,"isImageZoomDisabled":false,"useJavaScriptAsTypeScript":false,"alwaysEnableJavaScriptFetch":false,"scrollInContainerEnabled":false,"useMdxBundler":true,"isBatchStreamToggleDisabled":false,"isAuthEnabledInDocs":false,"isAskAiEnabled":false,"isAudioFileDownloadSpanSummary":false,"isDocsLogoTextEnabled":false,"isAudioExampleInternal":false,"usesApplicationJsonInFormDataValue":false,"isBinaryOctetStreamAudioPlayer":false,"hasVoiceIdPlaygroundForm":false,"isCohereTheme":false,"isFileForgeHackEnabled":false,"is404PageHidden":false,"isNewSearchExperienceEnabled":false,"isAuthenticatedPagesDiscoverable":false,"isSearchV2Enabled":false},"apis":["3a426c5e-a72e-4a43-b8b7-e1b2ab2bb5b5"],"seo":{"openGraph":{"siteName":"Deepgram | Documentation"},"twitter":{},"additionalMetaTags":[],"additionalLinkTags":[{"rel":"icon","href":"https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/favicon.ico","crossOrigin":"anonymous"},{"rel":"preload","href":"https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/Inter.woff2","as":"font","type":"font/woff2","crossOrigin":"anonymous"},{"rel":"preload","href":"https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/FiraMono.woff2","as":"font","type":"font/woff2","crossOrigin":"anonymous"},{"rel":"preload","href":"https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/Roobert.woff2","as":"font","type":"font/woff2","crossOrigin":"anonymous"}],"breadcrumbList":{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Deepgram | Documentation","item":"https://developers.deepgram.com/"},{"@type":"ListItem","position":2,"name":"Guides","item":"https://developers.deepgram.com/docs"},{"@type":"ListItem","position":3,"name":"Integrations","item":"https://developers.deepgram.com/docs/integrations"},{"@type":"ListItem","position":4,"name":"Google Dialogflow CX and Deepgram","item":"https://developers.deepgram.com/docs/use-deepgram-with-dialogflow-cx"}]},"canonical":"https://developers.deepgram.com/docs/use-deepgram-with-dialogflow-cx","title":"Google Dialogflow CX and Deepgram","description":"Dialogflow CX is a framework for building virtual agents. Learn how to incorporate Deepgram's transcription and text-to-speech for improved accuracy.","titleTemplate":"%s — Deepgram | Documentation","noindex":false,"nofollow":false},"fallback":{},"theme":"default","analyticsConfig":{"gtm":{"containerId":"GTM-M5WQMGR"}},"defaultLang":"curl","stylesheet":"\n:root {\n --typography-body-font-family: 'Inter', -apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,sans-serif;\n --typography-heading-font-family: 'Roobert', -apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,sans-serif;\n --typography-code-font-family: 'FiraMono', ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;\n --spacing-page-width: 100%;\n --spacing-content-width: 44rem;\n --spacing-content-wide-width: 66.5rem;\n --spacing-sidebar-width: 18rem;\n --spacing-header-height: 6.75rem;\n --spacing-header-height-padded: 5rem;\n --spacing-header-height-real: 4rem;\n \n --grayscale-1: var(--mauve-1);\n --grayscale-2: var(--mauve-2);\n --grayscale-3: var(--mauve-3);\n --grayscale-4: var(--mauve-4);\n --grayscale-5: var(--mauve-5);\n --grayscale-6: var(--mauve-6);\n --grayscale-7: var(--mauve-7);\n --grayscale-8: var(--mauve-8);\n --grayscale-9: var(--mauve-9);\n --grayscale-10: var(--mauve-10);\n --grayscale-11: var(--mauve-11);\n --grayscale-12: var(--mauve-12);\n --grayscale-a1: var(--mauve-a1);\n --grayscale-a2: var(--mauve-a2);\n --grayscale-a3: var(--mauve-a3);\n --grayscale-a4: var(--mauve-a4);\n --grayscale-a5: var(--mauve-a5);\n --grayscale-a6: var(--mauve-a6);\n --grayscale-a7: var(--mauve-a7);\n --grayscale-a8: var(--mauve-a8);\n --grayscale-a9: var(--mauve-a9);\n --grayscale-a10: var(--mauve-a10);\n --grayscale-a11: var(--mauve-a11);\n --grayscale-a12: var(--mauve-a12);\n --accent-1: #f7f7f9;\n --accent-2: #f1f3f9;\n --accent-3: #e8ebf7;\n --accent-4: #dde2f9;\n --accent-5: #d0d7f8;\n --accent-6: #c0c8f3;\n --accent-7: #abb5eb;\n --accent-8: #8f9be2;\n --accent-9: #7783f7;\n --accent-10: #6c77e9;\n --accent-11: #5158c3;\n --accent-12: #282c5f;\n --accent-a1: #7a3b7c04;\n --accent-a2: #1734c309;\n --accent-a3: #0926c312;\n --accent-a4: #0327ea1d;\n --accent-a5: #0126e92a;\n --accent-a6: #0322d93b;\n --accent-a7: #011ec950;\n --accent-a8: #011cc16d;\n --accent-a9: #0217f486;\n --accent-a10: #0214dc91;\n --accent-a11: #020ca8ad;\n --accent-a12: #010642d7;\n --accent-surface: #eff1f9cc;\n --gray-surface: #ffffffcc;\n --accent: 119, 131, 247;\n --accent-aa: 81, 96, 245;\n --accent-aaa: 32, 52, 243;\n --accent-tinted: 143, 153, 248;\n --background: 249, 250, 251;\n --accent-contrast: rgb(255, 255, 255);\n --bg-color-card: rgba(255, 255, 255, 0.7);\n --sidebar-background: transparent;\n --header-background: transparent;\n --border: var(--grayscale-a4);\n --border-concealed: var(--grayscale-a2);\n --body-text: 0, 0, 0;\n --body-text-inverted: 255, 255, 255;\n}\n\n@media (max-width: 1024px) {\n :root {\n --spacing-header-height: 6.75rem;\n --spacing-header-height-padded: 5rem;\n }\n}\n\n\n:is(.dark) {\n --grayscale-1: var(--gray-1);\n --grayscale-2: var(--gray-2);\n --grayscale-3: var(--gray-3);\n --grayscale-4: var(--gray-4);\n --grayscale-5: var(--gray-5);\n --grayscale-6: var(--gray-6);\n --grayscale-7: var(--gray-7);\n --grayscale-8: var(--gray-8);\n --grayscale-9: var(--gray-9);\n --grayscale-10: var(--gray-10);\n --grayscale-11: var(--gray-11);\n --grayscale-12: var(--gray-12);\n --grayscale-a1: var(--gray-a1);\n --grayscale-a2: var(--gray-a2);\n --grayscale-a3: var(--gray-a3);\n --grayscale-a4: var(--gray-a4);\n --grayscale-a5: var(--gray-a5);\n --grayscale-a6: var(--gray-a6);\n --grayscale-a7: var(--gray-a7);\n --grayscale-a8: var(--gray-a8);\n --grayscale-a9: var(--gray-a9);\n --grayscale-a10: var(--gray-a10);\n --grayscale-a11: var(--gray-a11);\n --grayscale-a12: var(--gray-a12);\n --accent-1: #050d0a;\n --accent-2: #0f1a15;\n --accent-3: #092d21;\n --accent-4: #003d29;\n --accent-5: #004b34;\n --accent-6: #005a40;\n --accent-7: #006b4d;\n --accent-8: #00805b;\n --accent-9: #a1f9d4;\n --accent-10: #97efca;\n --accent-11: #66cfa6;\n --accent-12: #9df5d0;\n --accent-a1: #00b50003;\n --accent-a2: #4bfb9c10;\n --accent-a3: #00fca124;\n --accent-a4: #00fc9735;\n --accent-a5: #00ffa543;\n --accent-a6: #00feac53;\n --accent-a7: #00fdb165;\n --accent-a8: #00fdb07b;\n --accent-a9: #a5ffd9f9;\n --accent-a10: #a0fed6ef;\n --accent-a11: #7dffcccd;\n --accent-a12: #a3ffd8f5;\n --accent-surface: color(display-p3 0.0863 0.1569 0.1255 / 0.5);\n --gray-surface: color(display-p3 0 0 0 / 5%);\n --accent: 161, 249, 212;\n --accent-aa: 161, 249, 212;\n --accent-aaa: 161, 249, 212;\n --accent-tinted: 185, 251, 223;\n --background: 11, 11, 12;\n --accent-contrast: rgb(11, 40, 29);\n --bg-color-card: rgb(26, 26, 31);\n --bg-color-card-solid: rgb(26, 26, 31);\n --sidebar-background: rgb(11, 11, 12);\n --header-background: rgb(26, 26, 31);\n --border: rgb(44, 44, 51);\n --border-concealed: rgb(44, 44, 51);\n --body-text: 255, 255, 255;\n --body-text-inverted: 0, 0, 0;\n}\n\n@font-face {\n font-family: 'Inter';\n src: url('https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/Inter.woff2') format('woff2');\n font-weight: 400;\n font-style: normal;\n font-display: swap;\n}\n\n@font-face {\n font-family: 'Roobert';\n src: url('https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/Roobert.woff2') format('woff2');\n font-weight: 600 900;\n font-style: normal;\n font-display: swap;\n}\n\n@font-face {\n font-family: 'FiraMono';\n src: url('https://files.buildwithfern.com/https://deepgram.docs.buildwithfern.com/2025-02-21T18:42:13.663Z/assets/FiraMono.woff2') format('woff2');\n font-weight: 100 900;\n font-style: normal;\n font-display: swap;\n}\n\nhtml {\n background-color: #f9fafb;\n}\n\nhtml.dark {\n background-color: #0b0b0c;\n}\n\n\n\n.fern-button.filled {\n\tbackground: linear-gradient(90deg, #201CFF -91.5%, #13EF95 80.05%) !important;\n}\n\n.fern-header-tab-button[data-state=active] {\n\tcolor: white !important;\n}\n\n.fern-header-tab-button[data-state=active]:after {\n\tbackground: linear-gradient(90deg, #201CFF -91.5%, #13EF95 80.05%) !important;\n\theight: 2px !important;\n}\n\n.fern-header-tab-button {\n\tpadding-left: 24px !important;\n\tpadding-right: 24px !important;\n}\n\n@media (max-width: 1350px) {\n\t.fern-header-tab-button {\n\t\tpadding-left: 16px !important;\n\t\tpadding-right: 16px !important;\n\t}\n}\n\n@media (max-width: 1185px) {\n\t.fern-header-tab-button {\n\t\tpadding-left: 12px !important;\n\t\tpadding-right: 12px !important;\n\t}\n}\n\n@media (max-width: 1100px) {\n\t.fern-header-tab-button {\n\t\tpadding-left: 8px !important;\n\t\tpadding-right: 8px !important;\n\t}\n}\n\n.fern-mdx-link {\n\tcolor: #79affa !important;\n\ttext-decoration: none;\n}\n\n.fern-mdx-link svg {\n\tcolor: #79affa !important;\n}\n\n.white .fern-card span {\n\tbackground: white !important;\n}\n\n@media (min-width: 1024px) {\n\t.fern-header-right-menu {\n\t\tdisplay: none !important;\n\t}\n}\n\n.banner {\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: center;\n\talign-items: center;\n\ttext-align: center;\n}\n\n.banner p {\n\tmargin-top: .25rem;\n\tmargin-bottom: .25rem;\n}\n\n.banner h1 {\n\tmargin-top: .5rem;\n\tmargin-bottom: 16px;\n}\n\n.fern-sidebar-link-container[data-state=\"active\"] {\n\tcolor: white !important;\n}\n\n.fern-sidebar-link-text {\n\tfont-size: 16px !important;\n}\n\n.fern-sidebar-link-container[data-state=active] .fern-sidebar-link-indent:after {\n border: 0px !important;\n}\n\n.fern-sidebar-link-container[data-state=\"active\"] .fern-sidebar-link {\n\tbackground-color: #232329 !important;\n}\n\n.fern-sidebar-link-container[data-state=\"active\"] .fern-sidebar-link:after {\n\tbackground: linear-gradient(177.85deg, #201CFF -102.27%, #13EF95 101.45%) !important;\n\twidth: 1px !important;\n\tposition: absolute !important;\n\tcontent: \"\" !important;\n\tright: 0 !important;\n\ttop: 0 !important;\n\tbottom: 0 !important;\n\tborder-radius: 8px !important;\n}\n\n.fern-sidebar-link {\n\tborder-radius: 0 !important;\n}\n\n.fern-sidebar-link-content {\n\tpadding-left: 1rem !important;\n\tpadding-right: 1rem !important;\n\tpadding-top: 0.5rem !important;\n\tpadding-bottom: 0.5rem !important;\n}\n\n.fern-sidebar-content {\n\tpadding-left: 0 !important;\n\tpadding-right: 0 !important;\n}\n\n@media (min-width: 1024px) {\n .fern-sidebar-container:not(.fern-sidebar-fixed) {\n padding-left: 0rem !important;\n }\n}\n\n.fern-header-tab-button span {\n\tfont-weight: 700 !important;\n\tfont-size: 16px !important;\n\tline-height: 17.5px !important;\n\tletter-spacing: 2% !important;\n}\n\n.fern-search-bar {\n\t--tw-ring-color: #4E4E52 !important;\n\tbackground-color: #0B0B0C !important;\n}\n\n.fern-sidebar-heading-content,\n.fern-sidebar-link-container .font-semibold .fern-sidebar-link-text {\n\tfont-weight: 700 !important;\n\tfont-size: 14px !important;\n\tline-height: 17.5px !important;\n\tletter-spacing: 2% !important;\n\tcolor: #A1F9D4 !important;\n}\n\n.fern-breadcrumb-item {\n\tcolor: var(--grayscale-a11) !important;\n\tfont-weight: 400 !important;\n}\n\nbutton[role=\"tab\"][data-state=\"active\"] {\n\tbackground-color: #1A1A1F !important;\n}\n\nbutton[role=\"tab\"][data-state=\"active\"]:after {\n\tbackground: linear-gradient(90deg, #201CFF -91.5%, #13EF95 80.05%) !important;\n\theight: 2px !important;\n\tposition: absolute !important;\n\tcontent: \"\" !important;\n\tright: 0 !important;\n\tleft: 0 !important;\n\tbottom: 0 !important;\n}\n\nbutton[role=\"tab\"] {\n\tbox-shadow: none !important;\n\tposition: relative !important;\n}\n\nbutton[role=\"tab\"]:hover span {\n\tbackground-color: #1A1A1F !important;\n}\n\ndiv[class*=\"callout\"] {\n\tborder-left-width: 2px !important;\n\tborder-color: var(--tw-ring-color) !important;\n}\n\n.fern-search-bar,\n.callout-outlined,\n.fern-card\n.fern-button {\n\tborder-radius: 8px !important;\n}\n\n.bg-tag-default-soft {\n background-color: #28282B !important;\n}\n\n.code-block-root span[style*=\"color: rgb(194, 195, 197);\"] {\n\t--shiki-dark: #949498 !important;\n}\n\n.callout-outlined {\n\tbackground-color: #1D2A34 !important;\n\t--tw-ring-color: #149AFB !important;\n}\n\n.callout-outlined-warning {\n\tbackground-color: #342D1E !important;\n\t--tw-ring-color: #FEC84B !important;\n}\n\n.callout-outlined p,\n.callout-outlined h5,\n.callout-outlined-warning p,\n.callout-outlined-warning h5,\n.callout-outlined-success p,\n.callout-outlined-success h5,\n.callout-outlined-danger p,\n.callout-outlined-danger h5,\n.callout-outlined-info p,\n.callout-outlined-info h5,\n.callout-outlined-tip p,\n.callout-outlined-tip h5,\n.callout-outlined-primary p,\n.callout-outlined-primary h5,\n.callout-outlined-check p,\n.callout-outlined-check h5,\n.callout-outlined-secondary p,\n.callout-outlined-warning li {\n\tcolor: var(--grayscale-a11) !important;\n}\n\n.callout-outlined li {\n\tmargin-top: 0px !important;\n}\n\n.callout-outlined h2 {\n\tmargin-top: 0px !important;\n}\n\n.callout-outlined-warning h2 {\n\tmargin-top: 0px !important;\n}\n\n.logs {\n\tbackground-color: #0b0b0c !important;\n\tpadding: 0.5rem !important;\n\tfont-family: var(--typography-code-font-family, var(--code-font-fallback));\n\n}\n\ndiv[class*=\"callout\"] .mt-0\\.5.w-4 {\n\talign-self: center !important;\n}\n\nspan[data-badge-type=\"http-method\"],\nspan[data-badge-type=\"status-code\"] {\n\tborder-radius: 50px !important;\n}\n\n.dg-badge {\n\tmargin-right: 6px !important;\n\tcolor: #bbbbbf !important;\n\tpadding: 1px 1px !important;\n\ttext-decoration: none !important;\n\tborder-radius: 4px !important;\n\tbackground-origin: border-box !important;\n background-image: linear-gradient(90deg, #201cff -91.5%, #13ef95 80.05%);\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\twidth: fit-content;\n\theight: fit-content;\n}\n\n.dg-badge span {\n\tbackground-color: #1A1A1F !important;\n\tpadding: 4px 12px !important;\n\tborder-radius: 4px !important;\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n}\n\n.dg-badge .fa-icon {\n\tbackground: linear-gradient(90deg, #201cff -91.5%, #13ef95 80.05%);\n\tmargin-right: 4px !important;\n}\n\n.fern-card {\n\tbackground-color: #0B0B0C !important;\n\tborder-radius: 8px !important;\n}\n\nol li {\n\tmargin-top: 2rem !important;\n}\n\n.small .fern-card {\n\tpadding-bottom: 1rem !important;\n\tpadding-top: 1rem !important;\n}\n\n.small .fern-card .items-start {\n\talign-items: center !important;\n}\n\n.small .fern-card .text-base {\n\tcolor: #BBBBBF !important;\n\tfont-weight: 600 !important;\n}\n\n.fern-card h3 {\n\tmargin-top: 0px !important;\n}\n\n.fern-sidebar-tabs {\n\tpadding-left: 10px !important;\n}\n\n.fern-sidebar-heading {\n\tpadding-left: 28px !important;\n}\n\n.api-playground-call {\n\twidth: fit-content !important;\n\theight: fit-content !important;\n\tdisplay: flex !important;\n\talign-items: center !important;\n\tjustify-content: center !important;\n\tpadding: 1px !important;\n\tborder-radius: 4px !important;\n\tbackground-image: linear-gradient(82.38deg, #ff2eea -99.24%, #4b3cff 99.26%) !important;\n\twidth: 100% !important;\n\tmargin-top: 1rem !important;\n}\n\n.api-playground-call span:first-child {\n\tdisplay: flex !important;\n\talign-items: center !important;\n\tgap: 12px !important;\n\tbackground-color: #1A1A1F !important;\n\tpadding: 4px !important;\n\tborder-radius: 4px !important;\n\twidth: 100% !important;\n\tflex-direction: row !important;\n}\n\n.api-playground-call p {\n\tmargin: 0 !important;\n\tdisplay: flex !important;\n\talign-items: center !important;\n\twhite-space: nowrap !important;\n}\n\n.api-playground-call p div:first-child {\n\tdisplay: inline-flex !important;\n\talign-items: center !important;\n}\n\n.api-playground-call img {\n\twidth: 2.5rem !important;\n\theight: 2.5rem !important;\n\tdisplay: inline-block !important;\n\tmargin-top: 4px !important;\n\tmargin-bottom: 4px !important;\n\ttransform: scaleX(-1) !important;\n}\n\n.invert-white {\n\tfilter: invert(1) !important;\n}\n\n.fa-icon,\n.card-icon {\n\twidth: 2rem !important;\n\theight: 2rem !important;\n}\n\n.dg-badge .fa-icon {\n\twidth: 1rem !important;\n\theight: 1rem !important;\n}\n\n.fern-header,\n.fern-header-tabs {\n\tborder-bottom-width: 0px !important;\n}\n\n.fern-header-tabs-list-item span {\n\tfont-family: 'Roobert' !important;\n}\n\n.fern-header-tabs-list,\n.fern-header-tabs-list-item {\n\theight: 100% !important;\n}\n\n.fern-sidebar-link-indent {\n\tmargin-left: 20px !important;\n}\n\n.fern-sidebar-link-container[data-state=inactive] .fern-sidebar-link:hover {\n\tcolor: #FBFBFF !important;\n}\n\n.t-muted:is(.dark *) {\n\tcolor: #949498 !important;\n}\n\n.dark\\:prose-invert:is(.dark *) {\n\t--tw-prose-headings: #FBFBFF !important;\n\tcolor: #E1E1E5 !important;\n}\n\n.fern-page-heading * {\n\tcolor: #FBFBFF !important;\n}\n\n.badge a {\n\ttext-decoration: none !important;\n\tcolor: unset !important;\n}\n\n.badge svg {\n\tdisplay: none !important;\n}\n\n.dep {\n\tbackground: #bbbbbf !important;\n}\n\n.dep .fa-icon {\n\tbackground: #bbbbbf !important;\n}\n\n.dep span {\n\ttext-decoration: line-through !important;\n}\n\n.pink {\n\tbackground-image: linear-gradient(85deg, #ee028b 5.66%, #ae29ff 99.14%) !important;\n}\n\n.pink .fa-icon {\n\tbackground: linear-gradient(85deg, #ee028b 5.66%, #ae29ff 99.14%) !important;\n}\n\n#fern-header {\n\tpadding-top: 3rem !important;\n}\n\n.fern-sidebar-container {\n\tposition: sticky !important;\n\ttop: 0 !important;\n margin-top: 10rem !important;\n\toverflow-y: auto !important;\n\tz-index: 20 !important;\n\theight: 100vh !important;\n}\n\n.fern-main {\n\tmargin-top: calc(var(--header-offset, 0) + 3rem) !important;\n}\n\n.fern-endpoint-content-right .fa-icon,\n.fern-dropdown-item .fa-icon {\n\twidth: 1rem !important;\n\theight: 1rem !important;\n}\n\n.fern-endpoint-content {\n\tpadding-top: 3rem !important;\n}\n\n#fern-header {\n\tposition: absolute !important;\n}\n\ndiv[id=\"/reference/speech-to-text-api/listen#request\"] .flex.flex-col div:nth-of-type(4) span:nth-of-type(2) {\n\tdisplay: none !important;\n}\n\ndiv[id=\"/reference/speech-to-text-api/listen#request\"] .flex.flex-col div:nth-of-type(4) span:nth-of-type(1):after {\n\tcontent: \" binary\" !important;\n\tcolor: #949498 !important;\n\tfont-size: .75rem;\n line-height: 1rem;\n\tfont-family: 'Inter' !important;\n\ttext-shadow: 0 1px 3px rgba(0, 0, 0, .4);\n\tmargin-left: .5rem;\n}\n\n#fern-header {\n\tposition: absolute !important;\n}\n\n.fern-sidebar-fixed+.fern-main {\n\tpadding-left: 0px !important;\n}\n\n.api-playground-call a {\n padding-left: 4px !important;\n padding-right: 4px !important;\n color: #79affa !important;\n text-decoration: none !important;\n}\n\n\n*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.tw-absolute{position:absolute}.tw-relative{position:relative}.tw-inset-x-0{left:0;right:0}.tw-top-0{top:0}.tw-z-30{z-index:30}.tw-mx-auto{margin-left:auto;margin-right:auto}.tw-flex{display:flex}.tw-w-full{width:100%}.tw-max-w-\\[var\\(--spacing-page-width\\)\\]{max-width:var(--spacing-page-width)}.tw-items-center{align-items:center}.tw-justify-end{justify-content:flex-end}.tw-gap-2{gap:.5rem}.tw-gap-3{gap:.75rem}.tw-rounded-md{border-radius:.375rem}.tw-bg-\\[\\#232329\\]{--tw-bg-opacity: 1;background-color:rgb(35 35 41 / var(--tw-bg-opacity))}.tw-px-3{padding-left:.75rem;padding-right:.75rem}.tw-px-4{padding-left:1rem;padding-right:1rem}.tw-py-2{padding-top:.5rem;padding-bottom:.5rem}.tw-text-\\[\\#BBBBBF\\]{--tw-text-opacity: 1;color:rgb(187 187 191 / var(--tw-text-opacity))}.tw-backdrop-blur-2xl{--tw-backdrop-blur: blur(40px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}#fern-header a{font-size:16px!important;font-family:Inter,sans-serif!important}@media (min-width: 768px){.md\\:tw-px-6{padding-left:1.5rem;padding-right:1.5rem}}@media (min-width: 1024px){.lg\\:tw-px-8{padding-left:2rem;padding-right:2rem}}\n\n","featureFlagsConfig":{}},"__N_SSG":true},"page":"/static/[domain]/[[...slug]]","query":{"domain":"developers.deepgram.com","slug":["docs","use-deepgram-with-dialogflow-cx"]},"buildId":"jigMgAOOAbh4GA_fJkAR-","assetPrefix":"https://app.ferndocs.com","isFallback":false,"isExperimentalCompile":false,"dynamicIds":[58494,47191,39862,22055,98508,37110,7575],"gsp":true,"scriptLoader":[]}</script></body></html>

Pages: 1 2 3 4 5 6 7 8 9 10