# Vertex AI Interactions API: the terminal \`interaction.completed\` event has no durable event id, breaking stream resume dedup

**URL:** <https://discuss.ai.google.dev/t/vertex-ai-interactions-api-the-terminal-interaction-completed-event-has-no-durable-event-id-breaking-stream-resume-dedup/191423>\
**Category:** Gemini API\
**Tags:** vertexai\
**Created:** [October 22, 2026, 4:27am UTC](https://discuss.ai.google.dev/t/vertex-ai-interactions-api-the-terminal-interaction-completed-event-has-no-durable-event-id-breaking-stream-resume-dedup/191423 "2026-10-22T04:27:28Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Liangwen\_Chen](https://d1dlmcr85iqnpo.cloudfront.net/user_avatar/discuss.ai.google.dev/liangwen_chen/32/22507_2.png) [@Liangwen\_Chen](https://discuss.ai.google.dev/u/Liangwen_Chen)\
**Post date:** [October 22, 2026, 4:27am UTC](https://discuss.ai.google.dev/t/vertex-ai-interactions-api-the-terminal-interaction-completed-event-has-no-durable-event-id-breaking-stream-resume-dedup/191423/1 "2026-10-22T04:27:29Z")

</div>

**\*\*Component:\*\*** Vertex AI — Gemini Interactions API (`aiplatform.googleapis.com/v1beta1/…/interactions`)

**\*\*Type:\*\*** Defect (upstream API behaviour)

**\*\*Live-verified:\*\*** 2026-10-21, direct to Vertex (no intermediary), project `gcp-sdet-test`, location `global`, model `gemini-3.8-flash`

**## Summary**

The final event of an Interactions event stream (`interaction.completed`) is delivered with a **\*\*synthesized placeholder id\*\*** (`0_unset_`) that is never persisted. Consequences:

1. **\*\*Unstable id across deliveries:\*\*** resuming from a durably stored id re-delivers `interaction.completed` with a _\*different\*_ `event_id` than the client originally received (a fresh `0_unset_` on every delivery), so clients cannot recognize it as the same logical event by id.

2. **\*\*Non-exclusive resume:\*\*** resuming with `last_event_id` set to an `unset` id re-delivers the boundary event itself — under the _\*requested\*_ id but with a _\*different payload\*_ than originally delivered. Deterministic (4/4 runs).

Both violate standard SSE `Last-Event-ID` semantics (the client should receive only events _\*after\*_ the last one it processed, with ids stable per logical event) and make id-based deduplication unreliable exactly where it matters most: reconnecting at the end of a stream.

**## Event id format**

Stream events carry an `event_id` JSON field of the form `v1_\<base64url(seq_type_timestampMicros)\>`, for example:

| event\_id | decoded | event |

|—|—|—|

| `v1_MV90ZXh0XzE3OTI1NTQwMTk5OTg2MTc=` | `1_text_1792554019998617` | `step.delta` (durable) |

| `v1_MF91bnNldF8xNzkyNTU0MDIwMTg3NTk2` | `0_unset_1792554020187596` | `interaction.completed` (placeholder) |

The `interaction.completed` event is consistently the last id-carrying event of a stream and always carries an `unset` placeholder id.

**## Steps to reproduce**

1. `POST …/interactions` with `stream: true` and a short prompt (e.g. “Count from 1 to 5.”).

2. Parse the SSE `data:` payloads and note the `event_id` of the final `interaction.completed` event (`0_unset_`).

3. `GET /{id}?stream=true&last_event_id=` — observe the re-delivered `interaction.completed` carries `0_unset_`, `T1 ≠ T0` (symptom 1).

4. `GET /{id}?stream=true&last_event_id=0_unset_` — observe the stream contains `interaction.completed` with `event_id = 0_unset_` again, but a different payload than the original delivery (symptom 2).

5. Repeat step 4: the result is identical every time (deterministic).

**## Observed vs expected (4 runs, same project/model, interaction confirmed `completed` before each resume)**

| Resume point | Expected (SSE semantics) | Observed |

|—|—|—|

| Stored id (`1_text_`) | events strictly after ``; re-delivered events keep their ids | ✅ Exclusive (4/4) — but the re-delivered `interaction.completed` carries a **\*\*new\*\*** id `0_unset_\<T0+~500µs\>` each time (❌ symptom 1) |

| `unset` id (`0_unset_`) | events strictly after `` | ❌ The boundary event **\*\*is re-delivered\*\*** (4/4, deterministic), carrying the **\*\*requested id\*\*** with a **\*\*different payload\*\*** (❌ symptom 2) |

**## Payload difference (symptom 2 detail)**

Same `event_id` (`0_unset_`) delivered twice with different bodies — the replayed event is reconstructed, not replayed from a log:

```json

// original delivery

{“interaction”:{“id”:“…”,“status”:“completed”,“usage”:{_…_},“role”:“model”,“created”:“…”,“updated”:“…”,“service\_tier”:“standard”,“object”:“interaction”,_…_},“event\_id”:“v1\_MF91bnNldF8x…NzU5Ng”,“event\_type”:“interaction.completed”}

// re-delivery on resume (same event\_id, no “role” field, different key order)

{“interaction”:{“id”:“…”,“status”:“completed”,“usage”:{_…_},“service\_tier”:“standard”,“object”:“interaction”,“model”:“…”},“event\_id”:“v1\_MF91bnNldF8x…NzU5Ng”,“event\_type”:“interaction.completed”}

```

**## Impact**

- A client that reconnects right after receiving the final `interaction.completed` event — the exact scenario resume exists for — receives that event **\*\*again\*\*** , with the same id but different content.

- Deduplication by `event_id` is impossible for the terminal event: the same logical event surfaces under different ids across deliveries (symptom 1), and the same id surfaces with different payloads (symptom 2).

- No error is returned at any point; the inconsistency is fully silent.

**## Suggested direction**

Assign a durable id to the terminal `interaction.completed` event (and any other events currently delivered as `0_unset_`), so that `last_event_id` resume is exclusive and id-stable for every event on the stream.

**## Reproduction notes**

Verified with bare HTTPS requests (JWT-bearer service-account auth, `Authorization: Bearer `) against `[https://aiplatform.googleapis.com/v1beta1/projects//locations/global/interactions\`](https://aiplatform.googleapis.com/v1beta1/projects//locations/global/interactions%5C%60); no SDK, no proxy layer, response bytes inspected directly. Each resume was issued only after `GET /{id}` confirmed the interaction was `completed`, ruling out resumption of a still-active stream. All probe interactions were deleted after the run.

---

<div class="post-metadata">

**Author:** ![Mahesh\_Sutar](https://d1dlmcr85iqnpo.cloudfront.net/user_avatar/discuss.ai.google.dev/mahesh_sutar/32/31644_2.png) [@Mahesh\_Sutar](https://discuss.ai.google.dev/u/Mahesh_Sutar)\
**Post date:** [October 22, 2026, 7:29am UTC](https://discuss.ai.google.dev/t/vertex-ai-interactions-api-the-terminal-interaction-completed-event-has-no-durable-event-id-breaking-stream-resume-dedup/191423/2 "2026-10-22T07:29:39Z")

</div>

Hello @Liangwen_Chen ,  
For issues related to the Vertex API, please contact your sales representative if you have one. Otherwise, you can find more relevant assistance on the [Google Cloud Forum](https://discuss.google.dev/c/google-cloud/14).
