Skip to main content
The TypeScript SDK and docs are currently in beta. Report issues on GitHub.
Event emitted when a new output item is added to the response

Example Usage

import { OpenResponsesStreamEventResponseOutputItemAdded } from "@openrouter/sdk/models";

let value: OpenResponsesStreamEventResponseOutputItemAdded = {
  type: "response.output_item.added",
  outputIndex: 0,
  item: {
    id: "item-1",
    role: "assistant",
    type: "message",
    content: [],
  },
  sequenceNumber: 2,
};

Fields

FieldTypeRequiredDescriptionExample
type”response.output_item.added”:heavy_check_mark:N/A
outputIndexnumber:heavy_check_mark:N/A
itemmodels.ResponsesOutputItem:heavy_check_mark:An output item from the response{"id": "msg-abc123","role": "assistant","type": "message","status": "completed","content": [{"type": "output_text","text": "Hello! How can I help you today?"}
]
}
sequenceNumbernumber:heavy_check_mark:N/A