Hi,
I have encountered a reproducible issue with stateful conversation continuation in the Gemini Interactions API using the Antigravity managed agent.
Agent: antigravity-preview-05-2026
API revision: 2026-05-20
Service tier: standard
Endpoint: /v1beta/interactions
I maintain a persistent conversation by storing the returned previous_interaction_id and environment_id after each successful interaction.
The conversation initially completed five consecutive interactions successfully. All of those interactions are still retrievable through GET /v1beta/interactions/{id} and report status: completed.
After the fifth turn, however, the continuation chain became unusable.
What I tested
1. Fresh Antigravity interaction, no previous_interaction_id
Result:
HTTP 200
The agent responds normally and a new remote environment is created.
This confirms that the API key, account, Antigravity agent and environment provisioning are working.
2. Continue from interaction #5 using a fresh environment
Request uses:
previous_interaction_id = interaction #5
environment = remote
Result consistently:
HTTP 400
{"error":{"message":"Precondition check failed.","code":"invalid_request"}}
However, interaction #5 itself is retrievable and reports:
status: completed
3. Continue from interaction #4 using a fresh environment
Result consistently:
HTTP 503
The service is currently unavailable.
Repeated retries produce the same result.
4. Continue from interaction #3 using a fresh environment
This produces a particularly unexpected result.
The new request contains only:
Diagnostic only. Reply exactly: CONTEXT_OK
The API returns:
HTTP 200
but instead of responding CONTEXT_OK, it effectively replays the original historical interaction #4.
The response content corresponds to the previous #4 turn and, importantly, the usage statistics are identical to the original interaction #4:
input_tokens: 118585
cached_tokens: 106496
output_tokens: 1455
thought_tokens: 2040
total_tokens: 122080
A new interaction ID and a new environment ID are returned, but the model appears to process/replay the historical next turn rather than the newly supplied input.
Environment verification
I also checked the environment used by the original conversation through:
GET /v1beta/environments/{environment_id}
It returns:
HTTP 200
status: active
Interactions #4 and #5 both reference that same environment and both report status: completed.
I additionally tested continuation using environment: remote to eliminate the original sandbox as the cause. The problem remains.
Current behaviour summary
Fresh interaction -> HTTP 200, works normally
Continue from interaction #3 -> HTTP 200,
but replays historical #4
instead of processing new input
Continue from interaction #4 -> repeated HTTP 503
Continue from interaction #5 -> repeated HTTP 400
"Precondition check failed"
This appears to be a server-side conversation/continuation state issue rather than an API key, quota or environment problem.
The same API key can create fresh Antigravity interactions successfully at the same time.
Expected behaviour
A completed interaction should remain usable as previous_interaction_id, and the new input should become the next conversation turn.
Using environment: remote should allow the conversation to continue with a new sandbox while preserving the conversation history.
Additional information available
I have retained:
-
exact UTC timestamps,
-
interaction IDs,
-
environment IDs,
-
complete retained interaction responses,
-
per-turn token telemetry,
-
API responses for the 400 / 503 cases,
-
and a minimal reproduction script.
For privacy reasons I am not posting the full interaction IDs publicly, because they belong to a longer persistent conversation.
I can provide the full IDs and raw responses privately to Google engineering if needed.
Is this a known limitation or bug in stateful continuation for antigravity-preview-05-2026?
Thanks.