agentsvc.io

services / audio-transcribe

textoperational · 4295 ms

Speech to Text (Whisper Transcription)

Speech to text for agents: transcribe a voice note, meeting, podcast or call recording into text with timestamps, in about 100 languages with automatic language detection. Runs OpenAI Whisper (small by default, base for speed) on agentsvc.io itself, the audio is deleted after the call. Send audio_url or audio_base64 (mp3, mp4, m4a, wav, ogg, webm, flac), up to 10 minutes and 24 MB per call. Returns text, detected language, duration and segments with start and end seconds. Also available OpenAI-compatible at POST /v1/audio/transcriptions (multipart file, model whisper-1).

Run free trial ↗3 free calls per day with the example input. Paid: $0.010 USDC, no limit.

Call it

import { wrapFetchWithPayment, x402Client } from "@x402/fetch";
import { registerExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";

const client = new x402Client();
registerExactEvmScheme(client, { signer: privateKeyToAccount(process.env.EVM_PRIVATE_KEY) });
const payFetch = wrapFetchWithPayment(fetch, client);

const res = await payFetch("https://agentsvc.io/api/v1/proxy/audio-transcribe", {
  method: "POST",
  headers: { "Content-Type": "application/json" },
  body: JSON.stringify({"audio_url":"https://agentsvc.io/samples/speech-en.mp3"}),
});
const { data, payment } = await res.json();  // payment.status "settling"; header X-Payment-Settle: sync returns payment.transaction

Input

FieldTypeDescription
audio_urlstringPublic URL of the audio file
audio_base64stringAudio file as base64; or use audio_url
languagestringISO 639-1 code like en or de, default auto-detect
modelsmall | base = "small"small is more accurate, base about twice as fast
timestampsboolean = trueInclude segments with start and end seconds

Output

FieldTypeDescription
textstring
languagestring
language_probabilitynumber
duration_secondsnumber
modelstring
processing_msinteger
segmentsarray
model_licensestring

Example response (data)

{
  "text": "This is a sample recording for the agents.io speech to text service. It turns spoken audio into text with time stamps in about 100 languages.",
  "language": "en",
  "language_probability": 0.998,
  "duration_seconds": 9.17,
  "model": "whisper-small",
  "processing_ms": 3688,
  "segments": [
    {
      "start": 0,
      "end": 4.4,
      "text": "This is a sample recording for the agents.io speech to text service."
    },
    {
      "start": 4.4,
      "end": 9,
      "text": "It turns spoken audio into text with time stamps in about 100 languages."
    }
  ],
  "model_license": "MIT (OpenAI Whisper weights, faster-whisper runtime), runs on agentsvc.io, audio is deleted after the call"
}