Gemini 3.8 Flash-Lite TTS: dokumentacja API
Szybka, lekka synteza mowy w 70 głosach
Jednym kluczem API PopNow wywołasz Gemini 3.8 Flash-Lite TTS z własnego kodu. Znajdziesz tu identyfikatory modelu, które trzeba wysłać, każde pole wejściowe, koszt zapytania w USD i gotowe zapytanie do wklejenia w terminalu.
Opisy parametrów pochodzą ze schematu wejściowego modelu i są dostępne tylko po angielsku.
W skrócie
- Twórca
- Wynik
- Audio
- Od
- $0.00021 USD za sekundę wyniku
- Typowy czas
- ok. 26 s
- Identyfikatory modelu
Ceny są podane w USD, a opłaty są pobierane z Twojego salda PopNow. Przy przyjęciu zadania rezerwowana jest maksymalna kwota, po zakończeniu rozliczane jest rzeczywiste zużycie, a reszta zostaje zwolniona. Nieudane zadania są bezpłatne. Dokładną wycenę przed uruchomieniem uzyskasz przez POST /api/v1/jobs/quote.
Tekst na mowę
google/gemini-3.8-flash-lite-tts/text-to-speech
Cena
| Opcja | USD |
|---|---|
Domyślnie | $0.00021 za sekundę wyniku |
Parametry
| Pole | Typ | Domyślnie | Dozwolone wartości | Do czego służy |
|---|---|---|---|---|
textOpcjonalne | string | — | do 10 000 znaków | Words to speak, up to 10,000 characters. Native inline cues include <laugh>, <sigh> and <short pause>. |
dialogueOpcjonalne | array<object> | — | do 20 elementów | A scripted conversation, used instead of text: each line names a speaker from speakers. |
speakersOpcjonalne | array<object> | — | do 2 elementów | The cast for dialogue: one or two voices, each with a name the lines refer to. |
voice_idOpcjonalne | string | Kore | Achernar, Achird, Algenib, Algieba, Alnilam, Aoede, Arlo, Autonoe, Bodi, Brio, Callirrhoe, Charon, Cleo, Cruz, … (+56) | Prebuilt voice that reads the text. Each voice has a fixed character. |
styleOpcjonalne | string | — | whisper, empathetic, vocal_smile, newscaster, promo_hype, deadpan | Overall manner of the reading. Omit it to use the voice's own default manner. |
paceOpcjonalne | string | — | natural, rapid_fire, the_drift, staccato | Rhythm of the reading. Omit it to keep the voice's own rhythm. |
accentOpcjonalne | string | — | neutral, american_general, american_valley, american_south, british_rp, british_brixton, transatlantic, australian | English accent used for the reading. |
instructionsOpcjonalne | string | — | do 1000 znaków | How to read the text: mood, distance from the microphone, who is listening. Shapes the delivery and is not spoken. |
sceneOpcjonalne | string | — | do 500 znaków | Where and to whom the words are spoken. Shapes the delivery and is not spoken. |
filler_wordsOpcjonalne | boolean | false | — | Allow filler words in a two-speaker conversation. Has no effect on single-speaker requests. |
temperatureOpcjonalne | number | — | od 0 do 2 | Variation between takes; higher is less predictable. |
Przykładowe zapytanie
To zapytanie działa w obecnej postaci; pominięte pola mają wartości domyślne. Najpierw zapisz klucz w zmiennej POPNOW_API_KEY.
curl -X POST "https://api.popnow.ai/api/v1/jobs/createTask?wait=60" \
-H "Authorization: Bearer $POPNOW_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"model": "google/gemini-3.8-flash-lite-tts/text-to-speech",
"input": {
"text": "Hi there! This voice was created with the PopNow API in just a few seconds."
}
}'Odpowiedź od razu zawiera taskId. Wynik pobierzesz przez GET /api/v1/jobs/recordInfo albo dodaj callBackUrl, by dostać powiadomienie.
curl "https://api.popnow.ai/api/v1/jobs/recordInfo?taskId=TASK_ID_FROM_CREATE_TASK" \
-H "Authorization: Bearer $POPNOW_API_KEY"
