# Google Gemini 3.8 Flash TTS — Text To Audio > Gemini 3.8 Flash TTS (Text To Audio) on GPTProto — model-specific API access. Use the endpoint, authentication and response format below. ## Overview - **Guide status: available** - **Catalog model ID**: `gemini-3.8-flash-tts` - **Lifecycle**: listed (source: model-scene.releaseStatus/preRelease/isShow; not an inference availability test) - **max_input_tokens**: unknown - **platform_max_input_tokens**: unknown (source missing or nonpositive; not parsed from marketing text) - **provider_context_tokens**: 32768 (source: Data API models.context_length, uniquely matched provider SKU; separate from platform input limits) - **Context source**: model-scene.maxInTokenNumber, tokens; platform-published input limit, not an independently verified provider maximum - **Editorial facts**: marketing summaries are excluded; use the structured context, pricing and request fields below - **API availability**: not tested; available means a model-specific request is documented - **Base URL**: use the full Endpoint URL below; no shared SDK base URL is asserted - **Endpoint**: `POST https://gptproto.com/v1beta/models/gemini-3.8-flash-tts:generateContent` - **Model ID**: `gemini-3.8-flash-tts` - **Request model value**: not a shared body parameter; use the endpoint and request schema below - **Vendor**: Google - **Scene**: `text-to-audio` - **Category**: text-to-audio - **Modalities**: input text → output audio - **Model page**: https://gptproto.com/model/google/gemini-3.8-flash-tts Send API requests to the absolute Endpoint URL in this guide. The website address used to read documentation, including localhost, is not an inference base URL. ## Authentication Every request needs a GPTProto API key. Create one at https://gptproto.com/dashboard/api-key, then export it: ```bash export GPTPROTO_API_KEY="your-api-key" ``` Header: `x-goog-api-key: $GPTPROTO_API_KEY`. ## Pricing Billing shape: `per_token_text`. Platform USD quotes already include the discount. Run rows are complete request totals for their listed parameters. Second/token rows are unit rates. Pricing controls describe billing, not the server's accepted API parameters. ### Token rates (2 published rows) - **Input** — $0.8 per 1M tokens; USD; unit rate - **Output** — $14.4 per 1M tokens; USD; unit rate Prices may change. The model page always shows the live price: https://gptproto.com/model/google/gemini-3.8-flash-tts ## API Information The examples below use this model's published request format. Export your API key and supply any example inputs required by the request. ### Input Schema The JSON below is a published request example. Complete server parameter ranges/defaults are not independently confirmed here: **Full Example**: ```json { "contents": [ { "role": "user", "parts": [ { "text": "你好,请把这段话输出为 MP3 格式。" } ] } ], "generationConfig": { "responseModalities": [ "AUDIO" ], "responseFormat": { "audio": { "mimeType": "audio/mp3" } } } } ``` ## Usage Examples ### 1. Submit a request ```bash curl --request POST "https://gptproto.com/v1beta/models/gemini-3.8-flash-tts:generateContent" \ --header "x-goog-api-key: $GPTPROTO_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "contents": [ { "role": "user", "parts": [ { "text": "你好,请把这段话输出为 MP3 格式。" } ] } ], "generationConfig": { "responseModalities": [ "AUDIO" ], "responseFormat": { "audio": { "mimeType": "audio/mp3" } } } }' ``` ```python import os import requests url = "https://gptproto.com/v1beta/models/gemini-3.8-flash-tts:generateContent" headers = { "x-goog-api-key": os.environ["GPTPROTO_API_KEY"], "Content-Type": "application/json" } payload = { "contents": [ { "role": "user", "parts": [ { "text": "你好,请把这段话输出为 MP3 格式。" } ] } ], "generationConfig": { "responseModalities": [ "AUDIO" ], "responseFormat": { "audio": { "mimeType": "audio/mp3" } } } } response = requests.request("POST", url, headers=headers, json=payload) print(response.json()) ``` ```typescript const response = await fetch("https://gptproto.com/v1beta/models/gemini-3.8-flash-tts:generateContent", { method: "POST", headers: { "x-goog-api-key": process.env.GPTPROTO_API_KEY ?? "", "Content-Type": "application/json", }, body: JSON.stringify({ contents: [ { role: "user", parts: [ { text: "你好,请把这段话输出为 MP3 格式。", }, ], }, ], generationConfig: { responseModalities: [ "AUDIO", ], responseFormat: { audio: { mimeType: "audio/mp3", }, }, }, }), }); const data = await response.json(); console.log(data); ``` ## HTTP Status Codes - `400` — malformed body, a parameter or value this model does not accept, or input blocked by the provider's content moderation - `401` — missing or invalid API key - `403` — insufficient credits - `413` — request body too large - `429` — rate limited; retry with backoff - `500` — An internal server error occurred - `502` — An internal server error occurred - `504` — Gateway timeout — upstream service did not respond in time; retry later ## Additional Resources - [Model page](https://gptproto.com/model/google/gemini-3.8-flash-tts) - [All models](https://gptproto.com/model) - [API keys](https://gptproto.com/dashboard/api-key) - [Platform overview for LLMs](https://gptproto.com/llms-full.txt) - Any other model: `https://gptproto.com/model/{vendor}/{model}/{scene}/llms.txt`