Welcome to the API documentation for the Whisper AI Transcription Service. This service offers a simple and powerful way to transcribe audio files to text using OpenAI Whisper models.
The Whisper AI Transcription Service is a FastAPI-based microservice that uses OpenAI Whisper to transcribe audio files to text. The service accepts audio files in various formats and can automatically recognize the language of the content, with optimized support for Italian.
This API is designed to be intuitive and easy to integrate into any application that requires audio transcription functionality.
Currently, the service does not require authentication and is publicly accessible. However, it is subject to rate limiting to prevent abuse.
To ensure service availability for all users, the following usage limits are in place:
The API uses standard HTTP status codes to indicate the success or failure of a request. Here are the main error codes you might encounter:
| Code | Description |
|---|---|
| 200 | Success. The request has been processed correctly. |
| 400 | Bad request. May be due to missing parameters or invalid files. |
| 500 | Internal server error. A problem occurred while processing the request. |
This section describes in detail the endpoints available in the API and how to use them.
This endpoint accepts an audio file and transcribes it to text. It supports various audio formats such as MP3, WAV, M4A, FLAC, and others.
| Name | Type | Required | Description |
|---|---|---|---|
| audio_file | File | Yes | The audio file to transcribe. Must be a valid audio format. |
| language | String | No | Language code of the audio (e.g., "it" for Italian). If not specified, Whisper will attempt to automatically detect the language. |
The transcription was completed successfully.
{
"transcription": "Text transcribed from the audio file."
}
Missing or invalid parameters.
{
"detail": "The uploaded file is not an audio file"
}
An error occurred while processing the request.
{
"detail": "Error during transcription: [error message]"
}
All responses are in JSON format and include the following fields:
| Field | Type | Description |
|---|---|---|
| transcription | String | The text transcribed from the audio file. |
{
"transcription": "This is an example of text transcribed from an audio file."
}
curl -X POST "https://transcription.wraiter.it/transcribe/" \
-H "accept: application/json" \
-H "Content-Type: multipart/form-data" \
-F "audio_file=@/path/to/audio_file.mp3" \
-F "language=it"
const formData = new FormData();
formData.append('audio_file', fileInput.files[0]);
formData.append('language', 'it');
fetch('https://transcription.wraiter.it/transcribe/', {
method: 'POST',
body: formData
})
.then(response => response.json())
.then(data => {
console.log('Transcription:', data.transcription);
})
.catch(error => {
console.error('Error:', error);
});
import requests
url = "https://transcription.wraiter.it/transcribe/"
files = {
'audio_file': open('audio_file.mp3', 'rb')
}
data = {
'language': 'it'
}
response = requests.post(url, files=files, data=data)
result = response.json()
print("Transcription:", result['transcription'])
For questions, support, or feedback about this API, you can contact us through the following channels: