Quickstart

Get up and running with aiOla’s Speech AI in under 5 minutes. This guide will walk you through your first speech-to-text transcription using our SDKs.

What you’ll build

In this quickstart, you’ll transcribe an audio file into text using aiOla’s Speech-to-Text API. By the end, you’ll have a working example that you can expand upon.

Step 1: Get your API key

First, you’ll need an aiOla API key. If you don’t have one yet, sign up for an account to get started.

Keep your API key secure and never expose it in client-side code or public repositories.

Step 2: Install the SDK

Choose your preferred language and install the aiOla SDK:

$pip install aiola

Step 3: Set up authentication

Create a new file and set up authentication with your API key:

For a comprehensive understanding of aiOla’s authentication system, security best practices, and advanced token management, see our Authentication Guide.

1from aiola import AiolaClient
2
3# Generate access token from your API key
4result = AiolaClient.grant_token(api_key='your-api-key-here')
5access_token = result['accessToken']
6
7# Create the client
8client = AiolaClient(access_token=access_token)

Step 4: Transcribe your first audio file

Now let’s transcribe an audio file. Make sure you have an audio file ready (supported formats: WAV, MP3, FLAC, and others):

1# Open and transcribe an audio file
2with open('path/to/your/audio.wav', 'rb') as audio_file:
3 transcript = client.stt.transcribe_file(
4 file=audio_file,
5 language='en'
6 )
7
8# Print the transcription
9print("Transcription:", transcript)

Step 5: Run your code

Save your file and run it:

$python your_script.py

You should see the transcription of your audio file printed to the console!

Complete example

Here’s the complete working example:

1from aiola import AiolaClient
2
3# Step 1: Set up authentication
4result = AiolaClient.grant_token(api_key='your-api-key-here')
5access_token = result['accessToken']
6client = AiolaClient(access_token=access_token)
7
8# Step 2: Transcribe audio file
9try:
10 with open('path/to/your/audio.wav', 'rb') as audio_file:
11 transcript = client.stt.transcribe_file(
12 file=audio_file,
13 language='en'
14 )
15
16 print("Transcription:", transcript)
17
18except Exception as e:
19 print(f"Error: {e}")

What’s next?

Congratulations! You’ve successfully transcribed your first audio file with aiOla. Here’s what you can explore next:

Core Features

SDKs & Resources

Browser Examples

Building a web application? Check out our complete browser example:

Need help?

  • Check out our detailed guides for more advanced use cases
  • Browse the SDK repositories for additional examples
  • Join our developer community for support and discussions

Ready to build something amazing with speech AI?