> ## Documentation Index
> Fetch the complete documentation index at: https://docs.vivix.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# response.output_item.done

Returned when an item is done streaming. Also emitted when a response is interrupted, incomplete, or cancelled.

## Event fields

<ResponseField name="event_id" type="string" required>
  The unique ID of the server event.
</ResponseField>

<ResponseField name="type" type="string" required>
  Event type. Must be `response.output_item.done`.
</ResponseField>

<ResponseField name="response_id" type="string" required>
  The ID of the response to which the item belongs.
</ResponseField>

<ResponseField name="output_index" type="number" required>
  The index of the output item in the response.
</ResponseField>

<ResponseField name="item" type="conversation_item" required>
  The item that is done.
</ResponseField>

<ResponseField name="id" type="string" required>
  The unique ID of the item.
</ResponseField>

<ResponseField name="type" type="string" required>
  The item type.
</ResponseField>

<ResponseField name="status" type="'completed' | 'incomplete' | 'in_progress'">
  The status of the item.
</ResponseField>

<ResponseField name="role" type="string">
  Message role, when the output item is a message.
</ResponseField>

<ResponseField name="content" type="array">
  Final message content, when the output item is a message.
</ResponseField>

<ResponseField name="call_id" type="string">
  The ID of the function call, when the output item is a function call.
</ResponseField>

<ResponseField name="name" type="string">
  The function name, when the output item is a function call.
</ResponseField>

<ResponseField name="arguments" type="string">
  The final function arguments as a JSON string, when the output item is a function call.
</ResponseField>

<ResponseExample>
  ```json response.output_item.done theme={null}
  {
    "event_id": "evt_output_item_done_001",
    "type": "response.output_item.done",
    "response_id": "resp_001",
    "output_index": 0,
    "item": {
      "id": "msg_007",
      "type": "message",
      "status": "completed",
      "role": "assistant",
      "content": [
        {
          "type": "text",
          "text": "This model is best for live demos."
        }
      ]
    }
  }
  ```

  ```json response.output_item.done function call theme={null}
  {
    "event_id": "evt_output_item_done_002",
    "type": "response.output_item.done",
    "response_id": "resp_001",
    "output_index": 1,
    "item": {
      "id": "fc_001",
      "type": "function_call",
      "status": "completed",
      "call_id": "call_001",
      "name": "get_product",
      "arguments": "{\"product_id\":\"sku_123\"}"
    }
  }
  ```
</ResponseExample>
