Transcribe Audio and Video to Text
On this page, we dive into audio and video transcription and how you can use it to convert audio and video files to text.
You can transcribe audio and video files using the DevRIFT API. Here, we show you how to do it.
Using a simple cURL request, you can transcribe audio and video files like this:
Example Transcription Request
curl -X POST https://api.devrift.co/v1/transcribe \
-H "Authorization: Bearer {sk_test_foobar...}" \
-d "file=https://example.com/audio.mp3"
Using the Python SDK, you can transcribe audio and video files like this:
# Import the DevRIFT SDK
import transcribe from devrift
# Set your API key
transcribe.api_key = "YOUR_API_KEY"
# Make the request
transcription = transcribe(PATH_OR_URL_TO_FILE)
The transcription
variable will only contain the text of the audio or video file in this example.
Realtime Audio Transcription
You can also transcribe audio in realtime using our API.
We strongly recommend using one of DevRIFT's SDKs for realtime audio transcription.
Using the Python SDK, you can transcribe audio and video files like this:
# Import the DevRIFT SDK
import transcribe from devrift
# Set your API key
transcribe.api_key = "YOUR_API_KEY"
# Make the request
transcription = transcribe.live(PATH_OR_URL_TO_FILE)
The transcription
variable will only contain the text of the audio or video file in this example.