From 9443c2f10f09748c0b094fe0dadb2bcfe7134509 Mon Sep 17 00:00:00 2001 From: Sandra Rodgers <45321563+SandraRodgers@users.noreply.github.com> Date: Wed, 11 Oct 2023 08:22:17 -0500 Subject: [PATCH] Update README.md to add on prem info (#150) * Update README.md Add info about custom api endpoint for onprem * Update README.md --------- Co-authored-by: Luke Oliff --- README.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/README.md b/README.md index 12c82d4d..5823f5bc 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,7 @@ Official Python SDK for [Deepgram](https://www.deepgram.com/). Power your apps w * [Examples](#examples) * [Testing](#testing) * [Configuration](#configuration) + * [Custom API Endpoint] [#custom-api-endpoint] * [Transcription](#transcription) * [Remote Files](#remote-files) * [Local Files](#local-files) @@ -111,6 +112,17 @@ DEEPGRAM_API_KEY = 'YOUR_API_KEY' deepgram = Deepgram(DEEPGRAM_API_KEY) ``` +## Custom API Endpoint + +In order to point the SDK at a different API environment (e.g., for on-prem deployments), you can pass in an object setting the `api_url` when initializing the Deepgram client. + +```py +dg_client = Deepgram({ + "api_key": DEEPGRAM_API_KEY, + "api_url": "http://localhost:8080/v1/listen" +}) +``` + # Transcription ## Remote Files