Magidoc

createTimeEntryPlanned
Mutation

Creates a planned-effort TimeEntry on a Todo-backed Timesheet row and recalculates the Todo's planned work distribution. userId and a Todo-backed timeItemId are required at runtime despite the nullable schema typing. Pass planned: true to store seconds as planned effort; omitting planned stores the value as actual time instead, with no recalculation. With planned: true and seconds omitted, the entry is flagged redistributed so its planned value is derived from the Todo's work-effort distribution.

When the entry's date falls inside the Todo's start–due range, planned effort is recalculated across the Todo and every affected Timesheet row is returned; otherwise only the parent row is returned. The return type is [TimeItem] (rows, not the entry) — use createTimeEntry if you need the created TimeEntry back.

The caller must be the row's owner (their own userId, with view access to the Todo) or have update permission on the Todo's Project (Project Admin, Stack Admin, or Workspace Admin).

Arguments

#

date

planned

Pass true to write the planned track; omit to write actual time.

seconds

timeItemId

userEmail

Email address of the timesheet owner, instead of userId. With an organization access token it must belong to a member of the token's organization.

userId

Timesheet owner. Required at runtime.

Response

#

Returns [TimeItem ].

Example

#