gemini-3.1-flash-live-preview: sessions greet, then never process the caller's audio, then close with 1011 "Internal error encountered."

Summary

On models/gemini-3.1-flash-live-preview, some Live API sessions set up normally and speak their first turn, but never process the user’s audio after that. No inputTranscription arrives, the model never takes a turn, and text cues are ignored too. If we leave the session open, the server closes it about 10 s later with WebSocket close 1011 Internal error encountered.

We run an outbound phone agent that speaks German, so each failed session is a real caller who hears a greeting and then silence. We moved this traffic to our paid project on 2026-10-01 at 16:25 UTC. Since then the project has run 553 sessions, and 223 of the calls were answered. Nine of those answered calls hit this failure:

  • 3 were closed by the server with 1011.
  • 6 we ended or switched to another model ourselves, because our own audio level check shows the caller talking and nothing was transcribed.

Environment

  • Model: models/gemini-3.1-flash-live-preview
  • Endpoint: wss://generativelanguage.googleapis.com/ws/google.ai.generativelanguage.v1beta.GenerativeService.BidiGenerateContent, raw WebSocket from Node.js (not the SDK)
  • Paid project: gen-lang-client-0787392492, Tier 1 (prepay)
  • Live API limit shown in AI Studio: 150K TPM. Our peak over the last day was 47.9K TPM (about a third of the limit) and 9 RPM.
  • Server location: Germany (EU)
  • Load: 1–3 concurrent sessions, one session per phone call. Each session is opened a few seconds before the call is answered.
  • Audio in: audio/pcm;rate=16000, streamed in real time as 20 ms chunks (telephony G.711 upsampled to 16 kHz). The first turn is triggered by a short realtimeInput.text cue.

Setup message (abridged):

{
  "model": "models/gemini-3.1-flash-live-preview",
  "generationConfig": {
    "responseModalities": ["AUDIO"],
    "thinkingConfig": { "thinkingLevel": "minimal" },
    "speechConfig": { "voiceConfig": { "prebuiltVoiceConfig": { "voiceName": "…" } }, "languageCode": "de-DE" }
  },
  "systemInstruction": { "parts": [{ "text": "… (about 5.5K tokens)" }] },
  "inputAudioTranscription": {},
  "outputAudioTranscription": {},
  "realtimeInputConfig": {
    "automaticActivityDetection": {
      "startOfSpeechSensitivity": "START_SENSITIVITY_LOW",
      "endOfSpeechSensitivity": "END_SENSITIVITY_HIGH",
      "prefixPaddingMs": 200,
      "silenceDurationMs": 500
    }
  },
  "contextWindowCompression": { "triggerTokens": 12000, "slidingWindow": { "targetTokens": 5000 } },
  "tools": [{ "functionDeclarations": [ "… end_call and similar …" ] }]
}

What happens in a failing session

  1. setupComplete arrives normally, in about 0.4 s.
  2. We send the text cue, and the model speaks its greeting with normal latency (about 0.5 s).
  3. The caller answers. We keep streaming their audio, but no inputTranscription arrives and the model never takes a turn. Further realtimeInput.text cues are ignored as well.
  4. The server closes the socket with 1011 Internal error encountered. On this project, the two sessions we left open after a greeting closed 9.5 s and 11.4 s after the greeting started.

What we’ve measured (this project only)

  • None of the failing sessions ever produced an inputTranscription. We have not seen a session that transcribed the caller and then stopped, so whether a session works seems to be decided when it is created.
  • It doesn’t look like quota. All three server closes carried Internal error encountered. No Live session on this project was refused with a 429 or a quota error, and our peak use was about a third of the TPM limit.
  • models/gemini-3.8-live on the same project heard the caller in both calls we switched over to it mid-call while the caller was still talking (2026-10-03, 12:23 and 13:13 UTC).

Timestamps (UTC) for lookup

Sessions closed by the server with 1011 Internal error encountered.:

  • 2026-10-02: opened 15:32:43, greeting 15:33:07, closed 15:33:17
  • 2026-10-02: opened 16:13:56, never spoke its greeting, closed 16:14:22
  • 2026-10-02: opened 17:43:43, greeting 17:43:57, closed 17:44:09

Sessions that went deaf with the caller talking, which we ended or switched before any 1011 arrived (open, then greeting, then the time we detected the failure):

  • 2026-10-02: 15:15:54 / 15:16:03 / 15:16:16
  • 2026-10-02: 15:46:08 / 15:46:31 / 15:46:43
  • 2026-10-03: 12:22:45 / 12:22:54 / 12:23:02
  • 2026-10-03: 12:46:32 / 12:46:47 / 12:46:59
  • 2026-10-03: 13:12:18 / 13:12:39 / 13:12:56
  • 2026-10-03: 13:17:29 / 13:17:55 / 13:18:07

Questions

  1. Is there a known issue or capacity problem with gemini-3.1-flash-live-preview in late September / early October 2026?
  2. What does 1011 Internal error encountered. mean in this pattern, given that we are well under our rate limits and never get a 429?
  3. Is there a session or request ID we can log, so you can trace one specific session? We don’t see one in setupComplete.
  4. Is there anything we should change on our side? Or is there a recommended alternative for production phone traffic, such as Vertex AI?

I’m happy to share more timestamps or a minimal reproduction.

Hi @Aliant,

Thanks for sharing the detailed setup and timestamps. We tested your exact configuration over raw Node.js WebSockets with gemini-3.1-flash-live-preview, and all test sessions transcribed the caller’s audio and completed follow-up turns normally.

Here are the answers to your questions:

  1. Why 1011 happens under quota: Since your usage is well below Tier 1 limits, an occasional 1011 (“Internal error encountered.”) points to a transient backend worker error on that specific connection rather than a rate limit.
  2. How to log a session ID: setupComplete is empty by design. Enable Session Resumption (sessionResumption: {}) in your setup message—the server will send sessionResumptionUpdate.newHandle tokens that you can log for tracing and use to instantly reconnect if a call drops.
  3. Recommended production setup: We recommend moving production phone traffic to gemini-3.8-live, which is the default model for low-latency voice agents. When switching, omit thinkingLevel (not supported on 3.8 Live) and speechConfig.languageCode (native audio models detect language automatically per the Live API Capabilities Guide).