Skip to main content
GET
/
responses
/
{response_id}
/
input_items
List input items
curl --request GET \
  --url https://api.openai.com/v1/responses/{response_id}/input_items \
  --header 'Authorization: Bearer <token>'
{
  "object": "list",
  "data": [
    {
      "role": "user",
      "content": [
        {
          "type": "input_text",
          "text": "<string>"
        }
      ],
      "id": "<string>",
      "type": "message",
      "status": "in_progress"
    }
  ],
  "has_more": true,
  "first_id": "<string>",
  "last_id": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

response_id
string
required

The ID of the response to retrieve input items for.

Query Parameters

limit
integer
default:20

A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 20.

order
enum<string>

The order to return the input items in. Default is asc.

  • asc: Return the input items in ascending order.
  • desc: Return the input items in descending order.
Available options:
asc,
desc
after
string

An item ID to list items after, used in pagination.

before
string

An item ID to list items before, used in pagination.

include
enum<string>[]

Additional fields to include in the response. See the include parameter for Response creation above for more information.

Specify additional output data to include in the model response. Currently supported values are:

  • file_search_call.results: Include the search results of the file search tool call.
  • message.input_image.image_url: Include image urls from the input message.
  • computer_call_output.output.image_url: Include image urls from the computer call output.
Available options:
file_search_call.results,
message.input_image.image_url,
computer_call_output.output.image_url

Response

200 - application/json

OK

A list of Response items.

object
enum<string>
required

The type of object returned, must be list.

Available options:
list
data
(Input message · object | Output message · object | File search tool call · object | Computer tool call · object | Computer tool call output · object | Web search tool call · object | Function tool call · object | Function tool call output · object)[]
required

A list of items used to generate this response.

Content item used to generate a response.

has_more
boolean
required

Whether there are more items available.

first_id
string
required

The ID of the first item in the list.

last_id
string
required

The ID of the last item in the list.