Bug Description
The interactions.get(id="...", include_input=True) method completely omits the initial user prompt and fails to return any user_input fields or steps if the interaction stopped at a requires_action (function call) state. This contradicts the official documentation which states: "The stored resource (retrieved via interactions.get) also includes user_input steps for full context".
To Reproduce
- Call
client.interactions.create() with a text input and a tools declaration.
- The model correctly returns a
function_call step, setting the interaction status to requires_action.
- Call
client.interactions.get(id=..., include_input=True) on that exact interaction ID.
Code Example
from google import genai
light_tool = {
"type": "function",
"name": "set_light_values",
"description": "Sets the brightness of a light.",
"parameters": {
"type": "object",
"properties": {"brightness": {"type": "integer"}},
"required": ["brightness"]
}
}
client = genai.Client()
# 1. Create interaction that triggers a function call
interaction = client.interactions.create(
model="gemini-3.5-flash-lite",
input="Turn the lights down to 20%",
tools=[light_tool],
)
# 2. Fetch the interaction with include_input=True
fetched = client.interactions.get(id=interaction.id, include_input=True)
# 3. Bug demonstration
print("Expected string, Got:", fetched.input)
# Expected: "Turn the lights down to 20%"
# Actual: None
print("Expected 'user_input' step, Got:", [s.type for s in fetched.steps])
# Expected: Includes 'user_input'
# Actual: ['thought', 'function_call']
Expected Behavior
The returned payload should populate the top-level input string field or include a clear user_input step within the history timeline so developers can map the pending tool call back to the original user intent.
Actual Behavior
The input attribute is strictly None, and the original prompt text is completely stripped/unavailable from the fetched resource until the entire lifecycle is completed.
Bug Description
The
interactions.get(id="...", include_input=True)method completely omits the initial user prompt and fails to return anyuser_inputfields or steps if the interaction stopped at arequires_action(function call) state. This contradicts the official documentation which states: "The stored resource (retrieved via interactions.get) also includes user_input steps for full context".To Reproduce
client.interactions.create()with a text input and atoolsdeclaration.function_callstep, setting the interaction status torequires_action.client.interactions.get(id=..., include_input=True)on that exact interaction ID.Code Example
Expected Behavior
The returned payload should populate the top-level
inputstring field or include a clearuser_inputstep within the history timeline so developers can map the pending tool call back to the original user intent.Actual Behavior
The
inputattribute is strictlyNone, and the original prompt text is completely stripped/unavailable from the fetched resource until the entire lifecycle is completed.