Skip to main content
GET
Count the rows of a file attached to an AI Assistant message

Authorizations

X-API-Key
string
header
required

Path Parameters

attachment_id
string<uuid>
required

Query Parameters

sheet
string | null

A workbook sheet by name, matched without case when no sheet has exactly that name; omit for the attached sheet.

Required string length: 1 - 255

Response

Successful Response

How many rows a file's sheet has, with what the sheet says about itself.

The count of the rows GET …/rows/ pages through, read the same way, and what a reader needs to read those rows: their column names, the sheet they come from and the workbook's others, whether the header is only a title, and what reading the sheet had to do. The comments on no data row are a list of their own, GET …/comments/: a count holds values, never records.

columns
string[]
required

The header row's names for the sheet read, one per cell of each row.

comment_notes
string[]
required

Why some of the sheet's cell comments could not be read: true of the rows whose comments_unread is true.

count
integer
required

Data rows in the whole sheet read.

header_is_title
boolean
required

Whether the first row is a one-cell title over a wider table, so the column names, if any, are in one of the rows below; the import and the column read take that row's number as header_row.

notes
string[]
required

Sentences about what reading the sheet had to do.

sheet
string | null
required

The workbook sheet read; null for a CSV or a PDF.

sheet_names
string[]
required

Every visible sheet of the workbook, in tab order; empty for a CSV or a PDF.