> ## 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.

# Update item

> Replace any Google Forms item while preserving generated IDs by default.

`updateItem` performs a full replacement of a selected form item. It preserves
the existing item ID and position, and corresponding question IDs where possible.

## Example

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

export default automation("Update a section heading", () => {
  onHttpRequest({ scope: "automation" })

  updateItem({
    form: "form-id",
    itemReference: 2,
    item: { type: "pageBreak", title: "Contact details" },
  })
})
```

## Inputs

`form`, `itemReference` (immutable item ID or one-based position), and a complete
replacement `item` are required. Item definitions match [Add item](/reference/integrations/google-forms/actions/add-item#item-types).
`requiredRevisionId` is optional.

`account` optionally selects the Google account binding.

## Output

Returns the complete updated `Form`. Because the update mask is the whole item,
omitted replacement fields are removed rather than preserved.
