# API

> ### A note on col/row values
>
> Grid always passes col/row coordinate pairs in the format \[col, row] and never \[row, col]. This is to more accurately match an \[x, y] world, even though most english speakers will tend to say "row col".

## API Overview

Details of each property can be found by clicking on it.

### Types

| Name                                                | Description                                                           |
| --------------------------------------------------- | --------------------------------------------------------------------- |
| [GridColumn](/api/common-types.md#gridcolumn)       | A column description. Passed to the `columns` property.               |
| [GridCell](/api/common-types.md#gridcell)           | The basic interface for defining a cell                               |
| [GridSelection](/api/common-types.md#gridselection) | The most basic representation of the selected cells in the data grid. |
| [Theme](/api/common-types.md#theme)                 | The theme used by the data grid to get all color and font information |

### DataEditorRef

| Name                                                       | Description                                                                                                  |
| ---------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ |
| [appendRow](/api/dataeditorref.md#appendrow)               | Append a row to the data grid.                                                                               |
| [emit](/api/dataeditorref.md#emit)                         | Used to emit commands normally emitted by keyboard shortcuts.                                                |
| [focus](/api/dataeditorref.md#focus)                       | Focuses the data grid.                                                                                       |
| [getBounds](/api/dataeditorref.md#getbounds)               | Gets the current screen-space bounds of a desired cell.                                                      |
| [remeasureColumns](/api/dataeditorref.md#remeasurecolumns) | Causes the columns in the selection to have their natural sizes recomputed and re-emitted as a resize event. |
| [scrollTo](/api/dataeditorref.md#scrollto)                 | Tells the data-grid to scroll to a particular location.                                                      |
| [updateCells](/api/dataeditorref.md#updatecells)           | Invalidates the rendering of a list of passed cells.                                                         |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.grid.glideapps.com/api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
