Audio
Trascrizione vocale
Invia model e file come multipart/form-data: WAV PCM mono completo, massimo 25,000,000 byte, rispettando frequenza e durata del canale. Facoltativi: language (due lettere minuscole, es. it) e response_format=json (unico formato e predefinito). Lascia generare boundary a curl. URL, ID file, prompt, timestamp e stream non sono supportati.
STT usa input_audio_second o token; TTS usa input_character. In speech_billing_unit, utf16_code_unit e unicode_code_point contano gli emoji diversamente. La prenotazione non è un tetto di spesa; la liquidazione può essere asincrona. Prove mancanti non significano costo zero. Entrambi accettano X-Felo-Channel e inviano una sola volta al canale scelto. Disattiva i tentativi automatici anche dell'SDK dopo timeout o disconnessione. Conserva X-Request-Id e l'eventuale X-Generation-Id. Console Playground non supporta ancora l'audio. configured_rates usa tariffe congelate e utilizzo verificato; upstream_cost usa il costo verificato del fornitore con ricarico e sconto pubblicati.
- Tipo: stringX
- Felo - Channel Ordered comma-separated public channel codes. Omit this header to use default; default must be used alone. In wallet mode, default scans the model's effective public channel order in reverse, skips unpublished or unavailable channels, and uses the first eligible channel. Explicit codes follow the supplied order. For stateless Chat Completions, Messages and Responses, the server may try another selected channel or provider group after a confirmed upstream rejection. A single explicit channel limits routing to that channel. Legacy provider headers cannot override channel routing.
- Tipo: object200
Il JSON sincrono contiene
texte, facoltativamente,usagein secondi o token.usage.costè il costo del fornitore, non l'addebito finale Felo. Non occorre interrogare un task.- Tipo: stringtextobbligatorio
- Tipo: object | nullusage
- costTipo: numbermin:0
Reported upstream cost in USD.
- inputTipo: object
_token _details - audioTipo: integer
_tokens min:0Integer numbers.
- textTipo: integer
_tokens min:0Integer numbers.
- inputTipo: integer
_tokens min:0Integer numbers.
- outputTipo: integer
_tokens min:0Integer numbers.
- secondsTipo: numbermin:0
Duration reported by the selected channel.
- totalTipo: integer
_tokens min:0Integer numbers.
- typeTipo: string enumvalori
- duration
- tokens
application/json - Tipo: object400
Upload, wallet or upstream error
- Tipo: objecterrorobbligatorio
- codeTipo: string | null
- messageTipo: string
- paramTipo: string | null
- typeTipo: string
application/json - Tipo: object402
Upload, wallet or upstream error
- Tipo: objecterrorobbligatorio
- codeTipo: string | null
- messageTipo: string
- paramTipo: string | null
- typeTipo: string
application/json - Tipo: object413
Upload, wallet or upstream error
- Tipo: objecterrorobbligatorio
- codeTipo: string | null
- messageTipo: string
- paramTipo: string | null
- typeTipo: string
application/json - Tipo: object415
Upload, wallet or upstream error
- Tipo: objecterrorobbligatorio
- codeTipo: string | null
- messageTipo: string
- paramTipo: string | null
- typeTipo: string
application/json - Tipo: object429
Upload, wallet or upstream error
- Tipo: objecterrorobbligatorio
- codeTipo: string | null
- messageTipo: string
- paramTipo: string | null
- typeTipo: string
application/json - Tipo: object500
Upload, wallet or upstream error
- Tipo: objecterrorobbligatorio
- codeTipo: string | null
- messageTipo: string
- paramTipo: string | null
- typeTipo: string
application/json - Tipo: object502
Upload, wallet or upstream error
- Tipo: objecterrorobbligatorio
- codeTipo: string | null
- messageTipo: string
- paramTipo: string | null
- typeTipo: string
application/json - Tipo: object503
Upload, wallet or upstream error
- Tipo: objecterrorobbligatorio
- codeTipo: string | null
- messageTipo: string
- paramTipo: string | null
- typeTipo: string
application/json - Tipo: object504
Upload, wallet or upstream error
- Tipo: objecterrorobbligatorio
- codeTipo: string | null
- messageTipo: string
- paramTipo: string | null
- typeTipo: string
application/json
curl https://openapi.felo.ai/api/v1/audio/transcriptions \
--request POST \
--header 'Content-Type: multipart/form-data' \
--header 'Authorization: Bearer YOUR_SECRET_TOKEN' \
--form 'model=grok-stt-2.0' \
--form 'file=@filename' \
--form 'language=' \
--form 'response_format=json'
{
"text": "string",
"usage": {
"seconds": 0,
"type": "duration",
"input_tokens": 0,
"output_tokens": 0,
"total_tokens": 0,
"input_token_details": {
"text_tokens": 0,
"audio_tokens": 0
},
"cost": 0
}
}