Create a transcription
Creates a new transcription from an audio or video file.
curl -X POST "https://api.fetchmedia.io/v1/transcribe" \
-H "Content-Type: application/json" \
-H "X-API-KEY: YOUR_API_KEY" \
-d '{
"file_url": "https://www3.cde.ca.gov/download/rod/big_buck_bunny.mp4",
"webhook": "https://example.com/webhook"
}'
import requests
import json
url = "https://api.fetchmedia.io/v1/transcribe"
headers = {
"Content-Type": "application/json",
"X-API-KEY": "YOUR_API_KEY"
}
data = {
"file_url": "https://www3.cde.ca.gov/download/rod/big_buck_bunny.mp4",
"webhook": "https://example.com/webhook"
}
response = requests.post(url, headers=headers, json=data)
print(response.json())
const response = await fetch("https://api.fetchmedia.io/v1/transcribe", {
method: "POST",
headers: {
"Content-Type": "application/json",
"X-API-KEY": "YOUR_API_KEY"
},
body: JSON.stringify({
"file_url": "https://www3.cde.ca.gov/download/rod/big_buck_bunny.mp4",
"webhook": "https://example.com/webhook"
})
});
const data = await response.json();
console.log(data);
package main
import (
"fmt"
"net/http"
"bytes"
"encoding/json"
)
func main() {
data := []byte(`{
"file_url": "https://www3.cde.ca.gov/download/rod/big_buck_bunny.mp4",
"webhook": "https://example.com/webhook"
}`)
req, err := http.NewRequest("POST", "https://api.fetchmedia.io/v1/transcribe", bytes.NewBuffer(data))
if err != nil {
panic(err)
}
req.Header.Set("Content-Type", "application/json")
req.Header.Set("X-API-KEY", "YOUR_API_KEY")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
fmt.Println("Response Status:", resp.Status)
}
require 'net/http'
require 'json'
uri = URI('https://api.fetchmedia.io/v1/transcribe')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri)
request['Content-Type'] = 'application/json'
request['X-API-KEY'] = 'YOUR_API_KEY'
request.body = '{
"file_url": "https://www3.cde.ca.gov/download/rod/big_buck_bunny.mp4",
"webhook": "https://example.com/webhook"
}'
response = http.request(request)
puts response.body
{
"transcribe_id": "123e4567-e89b-12d3-a456-426614174000"
}
{
"error": "Unprocessable Entity",
"message": "The request was well-formed but contains semantic errors",
"code": 422,
"details": [
{
"field": "password",
"message": "Password must be at least 8 characters long"
}
]
}
POST
/transcribe
POST
API Key (header: X-API-KEY)
X-API-KEYstring
RequiredAPI key (sent in header)
API Key (query: key)
keystring
RequiredAPI key (sent in query)
Content-Typestring
RequiredThe media type of the request body
Options: multipart/form-data, application/json
filestring
The file to transcribe. Mutually exclusive with file_url.
Format: binary
file_urlstring
The URL of the file to transcribe. Mutually exclusive with file.
Format: url
webhookstring
The webhook to send the payload once the transcription is completed.
Format: url
Request Preview
Response
Response will appear here after sending the request
Authentication
header
X-API-KEYstring
RequiredAPI Key for authentication. Provide your API key in the header.
query
keystring
RequiredAPI Key for authentication. Provide your API key in the query.
Body
file_urlstring
The URL of the file to transcribe. Mutually exclusive with file.
webhookstring
The webhook to send the payload once the transcription is completed.
Responses
transcribe_idstring
The ID of the transcription.
errorsstring[]
Was this page helpful?
Last updated Feb 20, 2026
Built with Documentation.AI