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

> Updates an existing `Timecard`.

`square.updateTimecard` updates an existing `Timecard`.

## Example

```ts automations/square-update-timecard.automation.ts theme={null}
import { automation, onDashboardRun } from "automate.ax"
import { square } from "automate.ax/square"

export default automation("Update Square Timecard", () => {
  onDashboardRun({ title: "Update Square Timecard" })

  square.updateTimecard({
    id: "id",
    timecard: {
      locationId: "PAA1RJZZKXBFG",
      startAt: "2019-01-25T03:11:00-05:00",
      endAt: "2019-01-25T13:11:00-05:00",
      wage: {
        title: "Bartender",
        hourlyRate: {
          amount: BigInt("1500"),
          currency: "USD",
        },
        tipEligible: true,
      },
      breaks: [
        {
          id: "X7GAQYVVRRG6P",
          startAt: "2019-01-25T06:11:00-05:00",
          endAt: "2019-01-25T06:16:00-05:00",
          breakTypeId: "REGS1EQR1TPZ5",
          name: "Tea Break",
          expectedDuration: "PT5M",
          isPaid: true,
        },
      ],
      status: "CLOSED",
      version: 1,
      teamMemberId: "ormj0jJJZ5OZIzxrZYJI",
      declaredCashTipMoney: {
        amount: BigInt("500"),
        currency: "USD",
      },
    },
  })
})
```

## Inputs

Every input accepts a compatible signal. It requires `TIMECARDS_READ` and `TIMECARDS_WRITE`.

| Field      | Type              | Required | Default | Description                         |
| ---------- | ----------------- | -------- | ------- | ----------------------------------- |
| `id`       | `string`          | Yes      | —       | The ID of the object being updated. |
| `timecard` | `Square.Timecard` | Yes      | —       | The updated `Timecard` object.      |

Use the official [UpdateTimecard reference](https://developer.squareup.com/reference/square/labor-api/update-timecard) for provider field semantics and limits.

## Output

Returns the official `Square.UpdateTimecardResponse` response as a codec-safe object. Square integer money amounts remain `bigint` values.
