Returning a function call result to the OpenAI Responses API

OAI-SE Responses API & Vector Stores Medium Question 16 of 24

The Responses API requests get_order with call_id call_81. The application runs the lookup and needs to continue the conversation with its result.

Which input item returns the result to that call?

Show answer and explanation

DA function_call_output item carrying call_id call_81 and the lookup's result text

A function_call_output item is the vehicle for a tool result and it references the model's original call through call_id, so returning call_81 with the result closes that call. A freshly generated call_id correlates to nothing outstanding, a plain user message leaves the call unanswered so the model may repeat it, and a function_call item carries arguments the model chose rather than a result the application produced.

Source: developers.openai.com/api/docs/guides/function-calling

Anonymous, no account needed. Your tally stays in this browser.

Next question Start 5 timed questions Browse all 24 original OAI-SE practice questions