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

> ## Agent Instructions
> Automate.ax automations are TypeScript programs.
> Use Bun for installation and command examples.
> Use Automate.ax for the product name and automate.ax for the package, CLI, and domain.
> Treat documented public APIs as current; do not invent transitional or deprecated names.

# Format range

> Apply common text, fill, alignment, wrapping, and number formats to a Google Sheets range.

`formatRange` changes only the format properties you provide across a structured
grid range.

## Example

```ts theme={null}
import { automation, onHttpRequest } from "automate.ax"
import { formatRange } from "automate.ax/google-sheets"

export default automation("Format an order header", () => {
  onHttpRequest({ scope: "automation" })

  formatRange({
    spreadsheet: "spreadsheet-id",
    range: {
      sheet: "Orders",
      startRow: 1,
      endRow: 1,
      startColumn: 1,
      endColumn: 4,
    },
    bold: true,
    backgroundColor: "#E8F0FE",
    horizontalAlignment: "center",
    wrap: "wrap",
  })
})
```

## Inputs

`spreadsheet` and structured one-based `range` are required. Provide at least
one of six-digit `backgroundColor`/`textColor`, `bold`, `italic`,
`strikethrough`, horizontal (`left`, `center`, `right`) or vertical (`top`,
`middle`, `bottom`) alignment, `wrap` (`overflow`, `clip`, `wrap`), or
`numberFormat`. Number types are `text`, `number`, `percent`, `currency`,
`date`, `time`, `dateTime`, or `scientific`, with an optional Sheets pattern.

`account` optionally selects the Google account binding.

## Output

Returns the resolved zero-based, end-exclusive grid range with numeric
`sheetId`. Existing unspecified formatting remains unchanged.
