@togglhq/cli 1.11.65 → 1.11.67

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -81,7 +81,7 @@ Many endpoints use two segments (`toggl tasks list`). Some use nested groups, in
81
81
  - **`toggl organization …`** — organization APIs (not `toggl org …`; there is no `org` top-level command). Examples: `toggl organization invitations list`, `toggl organization members get`, `toggl organization workspaces list`.
82
82
  - **`toggl shared …`** — shared workspace/org data routed through `@toggl/queries` helpers (status, holidays, working hours, time off). Example: `toggl shared status get`.
83
83
 
84
- Core resource groups still include `tasks`, `projects`, `time-blocks`, `time-entries`, `statuses`, `users`, `tags`, `clients`, and others surfaced by the public command catalog. Some low-level endpoints are omitted from the CLI and MCP. Existing public command paths and operation IDs stay stable; use `toggl --help` and `toggl <group> --help` to explore what shipped.
84
+ Core resource groups still include `tasks`, `projects`, `time-entries`, `statuses`, `users`, `tags`, `clients`, and others surfaced by the public command catalog. Some low-level endpoints are omitted from the CLI and MCP. Existing public command paths and operation IDs stay stable; use `toggl --help` and `toggl <group> --help` to explore what shipped.
85
85
 
86
86
  **Typical entity commands:**
87
87
 
@@ -89,7 +89,6 @@ Core resource groups still include `tasks`, `projects`, `time-blocks`, `time-ent
89
89
  | -------------- | -------------------------------------------------------- |
90
90
  | `tasks` | `list` (alias `ls`), `get`, `create`, `update`, `delete` |
91
91
  | `projects` | `list` (alias `ls`), `get`, `create`, `update`, `delete` |
92
- | `time-blocks` | `list` (alias `ls`), `get`, `create`, `update`, `delete` |
93
92
  | `time-entries` | `list` (alias `ls`), `start`, `stop` |
94
93
  | `statuses` | `list` (alias `ls`) |
95
94
  | `users` | `list` (alias `ls`) |
@@ -173,7 +172,6 @@ toggl tasks delete --task-id 12345 --dry-run
173
172
  ```bash
174
173
  toggl tasks delete --task-id 12345 --yes
175
174
  toggl projects delete --project-id 999 --yes
176
- toggl time-blocks delete --task-id 12345 --time-block-id 67890 --yes
177
175
  ```
178
176
 
179
177
  ## Examples
@@ -223,22 +221,6 @@ toggl time-entries start --type break
223
221
  toggl time-entries stop
224
222
  ```
225
223
 
226
- **Time blocks**
227
-
228
- ```bash
229
- # List scheduled blocks for a week
230
- toggl time-blocks list --date-from 2025-01-01 --date-to 2025-01-07
231
-
232
- # Create a time block
233
- toggl time-blocks create --data '{
234
- "task_id": 12345,
235
- "payload": {"start": "2025-01-06T09:00:00Z", "end": "2025-01-06T11:00:00Z"}
236
- }'
237
-
238
- # Delete a time block
239
- toggl time-blocks delete --task-id 12345 --time-block-id 67890 --yes
240
- ```
241
-
242
224
  **Reference data**
243
225
 
244
226
  ```bash
package/build/cli.js CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { a as CommanderError, i as shutdownCliTelemetry, n as captureCliException, r as initCliTelemetry, t as createProgram } from "./program-C5GYCsU3.js";
2
+ import { a as CommanderError, i as shutdownCliTelemetry, n as captureCliException, r as initCliTelemetry, t as createProgram } from "./program-C0-wDCc4.js";
3
3
  import { readFileSync } from "node:fs";
4
4
  import { dirname, join } from "node:path";
5
5
  import { fileURLToPath } from "node:url";
package/build/index.js CHANGED
@@ -1,2 +1,2 @@
1
- import { t as createProgram } from "./program-C5GYCsU3.js";
1
+ import { t as createProgram } from "./program-C0-wDCc4.js";
2
2
  export { createProgram };
@@ -7566,29 +7566,7 @@ const ProjectSchema = /* @__PURE__ */ object({
7566
7566
  start_date: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDate())),
7567
7567
  updated_at: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime()))
7568
7568
  });
7569
- const TimeBlockPayloadSchema = /* @__PURE__ */ object({
7570
- start: /* @__PURE__ */ string(),
7571
- completed: /* @__PURE__ */ optional(/* @__PURE__ */ boolean()),
7572
- duration: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ number(), /* @__PURE__ */ minValue(0))),
7573
- outbound_sync: /* @__PURE__ */ optional(/* @__PURE__ */ boolean())
7574
- });
7575
7569
  const TimeEntryTypeSchema = /* @__PURE__ */ picklist(["activity", "break"]);
7576
- const TimeBlockSchema = /* @__PURE__ */ object({
7577
- created_at: /* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime()),
7578
- id: /* @__PURE__ */ number(),
7579
- start: /* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime()),
7580
- task_id: /* @__PURE__ */ number(),
7581
- toggl_user_id: /* @__PURE__ */ number(),
7582
- workspace_id: /* @__PURE__ */ number(),
7583
- archived_at: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime())),
7584
- calendar_event_id: /* @__PURE__ */ optional(/* @__PURE__ */ number()),
7585
- completed_at: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime())),
7586
- deleted_at: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime())),
7587
- description: /* @__PURE__ */ optional(/* @__PURE__ */ string()),
7588
- duration: /* @__PURE__ */ optional(/* @__PURE__ */ number()),
7589
- timezone: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ description("Timezone is the creator's IANA timezone snapshotted at creation; NULL when unresolved."))),
7590
- updated_at: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime()))
7591
- });
7592
7570
  const BillableSourceSchema = /* @__PURE__ */ picklist(["manual", "task_default"]);
7593
7571
  const TimeEntrySchema = /* @__PURE__ */ object({
7594
7572
  created_at: /* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime()),
@@ -7719,28 +7697,6 @@ const PaginatedStatussSchema = /* @__PURE__ */ object({
7719
7697
  page: /* @__PURE__ */ number(),
7720
7698
  per_page: /* @__PURE__ */ number()
7721
7699
  });
7722
- const PaginatedTimeBlockAggregateWithTasksSchema = /* @__PURE__ */ object({
7723
- data: /* @__PURE__ */ array(/* @__PURE__ */ object({
7724
- created_at: /* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime()),
7725
- has_time_entry: /* @__PURE__ */ boolean(),
7726
- id: /* @__PURE__ */ number(),
7727
- start: /* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime()),
7728
- task_id: /* @__PURE__ */ number(),
7729
- toggl_user_id: /* @__PURE__ */ number(),
7730
- workspace_id: /* @__PURE__ */ number(),
7731
- archived_at: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime())),
7732
- calendar_event_id: /* @__PURE__ */ optional(/* @__PURE__ */ number()),
7733
- completed_at: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime())),
7734
- deleted_at: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime())),
7735
- description: /* @__PURE__ */ optional(/* @__PURE__ */ string()),
7736
- duration: /* @__PURE__ */ optional(/* @__PURE__ */ number()),
7737
- task: /* @__PURE__ */ optional(TaskSchema),
7738
- timezone: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ description("Timezone is the creator's IANA timezone snapshotted at creation; NULL when unresolved."))),
7739
- updated_at: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime()))
7740
- })),
7741
- page: /* @__PURE__ */ number(),
7742
- per_page: /* @__PURE__ */ number()
7743
- });
7744
7700
  const PaginatedTimeEntryWithTasksSchema = /* @__PURE__ */ object({
7745
7701
  data: /* @__PURE__ */ array(/* @__PURE__ */ object({
7746
7702
  created_at: /* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime()),
@@ -8040,28 +7996,6 @@ const TaskPartialUpdatePayloadWithIDSchema = /* @__PURE__ */ object({
8040
7996
  tag_ids: /* @__PURE__ */ optional(/* @__PURE__ */ nullable(/* @__PURE__ */ array(/* @__PURE__ */ number()))),
8041
7997
  team_assignee_ids: /* @__PURE__ */ optional(/* @__PURE__ */ nullable(/* @__PURE__ */ array(/* @__PURE__ */ number())))
8042
7998
  });
8043
- const TimeBlockBulkCreatePayloadSchema = /* @__PURE__ */ object({ time_blocks: /* @__PURE__ */ pipe(/* @__PURE__ */ array(/* @__PURE__ */ object({
8044
- start: /* @__PURE__ */ string(),
8045
- task_id: /* @__PURE__ */ number(),
8046
- completed: /* @__PURE__ */ optional(/* @__PURE__ */ boolean()),
8047
- duration: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ number(), /* @__PURE__ */ minValue(0))),
8048
- outbound_sync: /* @__PURE__ */ optional(/* @__PURE__ */ boolean())
8049
- })), /* @__PURE__ */ minLength(1)) });
8050
- const TimeBlockPartialUpdatePayloadSchema = /* @__PURE__ */ object({
8051
- completed: /* @__PURE__ */ optional(/* @__PURE__ */ boolean()),
8052
- duration: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ number(), /* @__PURE__ */ minValue(0))),
8053
- outbound_sync: /* @__PURE__ */ optional(/* @__PURE__ */ boolean()),
8054
- start: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime())),
8055
- task_id: /* @__PURE__ */ optional(/* @__PURE__ */ number())
8056
- });
8057
- const TimeBlockPartialUpdatePayloadWithIDSchema = /* @__PURE__ */ object({
8058
- id: /* @__PURE__ */ number(),
8059
- completed: /* @__PURE__ */ optional(/* @__PURE__ */ boolean()),
8060
- duration: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ number(), /* @__PURE__ */ minValue(0))),
8061
- outbound_sync: /* @__PURE__ */ optional(/* @__PURE__ */ boolean()),
8062
- start: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ string(), /* @__PURE__ */ isoDateTime())),
8063
- task_id: /* @__PURE__ */ optional(/* @__PURE__ */ number())
8064
- });
8065
7999
  const TimeEntryBulkCreatePayloadSchema = /* @__PURE__ */ object({
8066
8000
  type: /* @__PURE__ */ pipe(TimeEntryTypeSchema, /* @__PURE__ */ description("The type of time entry. This could either be an activity, or a break.")),
8067
8001
  billable: /* @__PURE__ */ optional(/* @__PURE__ */ boolean()),
@@ -10633,104 +10567,6 @@ async function unarchiveTask(httpClient, organization_id, workspace_id, task_id,
10633
10567
  return await httpClient.post(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/unarchive`, { signal }).json();
10634
10568
  }
10635
10569
  //#endregion
10636
- //#region ../focus-queries/dist/time-blocks/requests.ts
10637
- async function getTaskTimeBlocksWithOrgClassic(httpClient, organization_id, workspace_id, task_id, { page, per_page, order_by, archived } = {}, signal) {
10638
- return await httpClient.get(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks`, {
10639
- signal,
10640
- searchParams: buildSearchParams$2({
10641
- page,
10642
- per_page,
10643
- order_by,
10644
- archived
10645
- })
10646
- }).json();
10647
- }
10648
- async function createTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, data, signal) {
10649
- return await httpClient.post(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks`, {
10650
- signal,
10651
- json: data
10652
- }).json();
10653
- }
10654
- async function getTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, signal) {
10655
- return await httpClient.get(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}`, { signal }).json();
10656
- }
10657
- async function updateTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, data, signal) {
10658
- return await httpClient.put(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}`, {
10659
- signal,
10660
- json: data
10661
- }).json();
10662
- }
10663
- async function deleteTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, outbound_sync, signal) {
10664
- return await httpClient.delete(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}`, {
10665
- signal,
10666
- searchParams: buildSearchParams$2({ outbound_sync })
10667
- }).json();
10668
- }
10669
- async function partialUpdateTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, data, signal) {
10670
- return await httpClient.patch(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}`, {
10671
- signal,
10672
- json: data
10673
- }).json();
10674
- }
10675
- async function archiveTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, signal) {
10676
- return await httpClient.post(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}/archive`, { signal }).json();
10677
- }
10678
- async function restoreTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, signal) {
10679
- return await httpClient.patch(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}/restore`, { signal }).json();
10680
- }
10681
- async function unarchiveTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, signal) {
10682
- return await httpClient.post(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}/unarchive`, { signal }).json();
10683
- }
10684
- async function getTimeBlocksRangeWithOrgClassic(httpClient, organization_id, workspace_id, { date_from, date_to, task_id, status_id, page, per_page, archived, order_by }, signal) {
10685
- return await httpClient.get(`organizations/${organization_id}/workspaces/${workspace_id}/time-blocks`, {
10686
- signal,
10687
- searchParams: buildSearchParams$2({
10688
- date_from,
10689
- date_to,
10690
- task_id,
10691
- status_id,
10692
- page,
10693
- per_page,
10694
- archived,
10695
- order_by
10696
- })
10697
- }).json();
10698
- }
10699
- async function bulkCreateTimeBlockWithOrg(httpClient, organization_id, workspace_id, data, signal) {
10700
- return await httpClient.post(`organizations/${organization_id}/workspaces/${workspace_id}/time-blocks/bulk`, {
10701
- signal,
10702
- json: data
10703
- }).json();
10704
- }
10705
- async function bulkDeleteTimeBlockWithOrg(httpClient, organization_id, workspace_id, ids, outbound_sync, signal) {
10706
- return await httpClient.delete(`organizations/${organization_id}/workspaces/${workspace_id}/time-blocks/bulk`, {
10707
- signal,
10708
- searchParams: buildSearchParams$2({
10709
- ids,
10710
- outbound_sync
10711
- })
10712
- }).json();
10713
- }
10714
- async function bulkPartialUpdateTimeBlockWithOrg(httpClient, organization_id, workspace_id, data, signal) {
10715
- return await httpClient.patch(`organizations/${organization_id}/workspaces/${workspace_id}/time-blocks/bulk`, {
10716
- signal,
10717
- json: data
10718
- }).json();
10719
- }
10720
- async function getTimeBlocksRangeStreamWithOrg(httpClient, organization_id, workspace_id, { date_from, date_to, task_id, status_id, archived, order_by }, signal) {
10721
- return await httpClient.get(`organizations/${organization_id}/workspaces/${workspace_id}/time-blocks/stream`, {
10722
- signal,
10723
- searchParams: buildSearchParams$2({
10724
- date_from,
10725
- date_to,
10726
- task_id,
10727
- status_id,
10728
- archived,
10729
- order_by
10730
- })
10731
- }).json();
10732
- }
10733
- //#endregion
10734
10570
  //#region ../focus-queries/dist/time-entries/requests.ts
10735
10571
  async function getTaskTimeEntriesWithOrgClassic(httpClient, organization_id, workspace_id, task_id, { page, per_page, order_by, type, archived, time_block_id } = {}, signal) {
10736
10572
  return await httpClient.get(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-entries`, {
@@ -10963,7 +10799,7 @@ const PublicMeEntryRequestSchema = /* @__PURE__ */ object$2({
10963
10799
  ]))
10964
10800
  });
10965
10801
  //#endregion
10966
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.63_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_3085063bba60f639e8aa7f3285add2c2/node_modules/@toggl/queries/dist/org/invitation/requests.mjs
10802
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.64_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_9a6a00428921d756e77d8976c0226cf3/node_modules/@toggl/queries/dist/org/invitation/requests.mjs
10967
10803
  async function getInvitations(httpClient, signal) {
10968
10804
  return (await httpClient.get(`invitations`, { signal })).json();
10969
10805
  }
@@ -10980,7 +10816,7 @@ async function resendInvitation(httpClient, organization_id, organization_user_i
10980
10816
  return (await httpClient.post(`organizations/${organization_id}/invitations/${organization_user_id}/resend`, { signal })).json();
10981
10817
  }
10982
10818
  //#endregion
10983
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.63_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_3085063bba60f639e8aa7f3285add2c2/node_modules/@toggl/queries/dist/org/utils/requests.mjs
10819
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.64_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_9a6a00428921d756e77d8976c0226cf3/node_modules/@toggl/queries/dist/org/utils/requests.mjs
10984
10820
  function buildSearchParams(params, flattenArrays = false) {
10985
10821
  const searchParams = new URLSearchParams();
10986
10822
  Object.entries(params).forEach(([key, value]) => {
@@ -10992,7 +10828,7 @@ function buildSearchParams(params, flattenArrays = false) {
10992
10828
  return searchParams;
10993
10829
  }
10994
10830
  //#endregion
10995
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.63_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_3085063bba60f639e8aa7f3285add2c2/node_modules/@toggl/queries/dist/org/organization-user/requests.mjs
10831
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.64_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_9a6a00428921d756e77d8976c0226cf3/node_modules/@toggl/queries/dist/org/organization-user/requests.mjs
10996
10832
  async function getOrganizationUser(httpClient, organization_id, organization_user_id, signal) {
10997
10833
  return (await httpClient.get(`organizations/${organization_id}/users/${organization_user_id}`, { signal })).json();
10998
10834
  }
@@ -11006,7 +10842,7 @@ async function patchOrganizationUserActive(httpClient, organization_id, organiza
11006
10842
  return (await httpClient.patch(`organizations/${organization_id}/users/${organization_user_id}/active_status/${status}`, { signal })).json();
11007
10843
  }
11008
10844
  //#endregion
11009
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.63_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_3085063bba60f639e8aa7f3285add2c2/node_modules/@toggl/queries/dist/org/workspace/requests.mjs
10845
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.64_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_9a6a00428921d756e77d8976c0226cf3/node_modules/@toggl/queries/dist/org/workspace/requests.mjs
11010
10846
  async function getWorkspaces(httpClient, organization_id, signal) {
11011
10847
  return (await httpClient.get(`organizations/${organization_id}/workspaces`, { signal })).json();
11012
10848
  }
@@ -11026,7 +10862,7 @@ const WorkingHoursUpdateInputSchema = /* @__PURE__ */ object$2({
11026
10862
  });
11027
10863
  const StatusOKSchema = /* @__PURE__ */ object$2({ status: /* @__PURE__ */ string$1() });
11028
10864
  //#endregion
11029
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.63_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_3085063bba60f639e8aa7f3285add2c2/node_modules/@toggl/queries/dist/org/holiday-calendar/requests.mjs
10865
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.64_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_9a6a00428921d756e77d8976c0226cf3/node_modules/@toggl/queries/dist/org/holiday-calendar/requests.mjs
11030
10866
  async function holidayListDates(httpClient, organization_id, { year, country }, signal) {
11031
10867
  return (await httpClient.get(`holidays/organizations/${organization_id}/calendar/dates`, {
11032
10868
  signal,
@@ -11037,12 +10873,12 @@ async function holidayListDates(httpClient, organization_id, { year, country },
11037
10873
  })).json();
11038
10874
  }
11039
10875
  //#endregion
11040
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.63_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_3085063bba60f639e8aa7f3285add2c2/node_modules/@toggl/queries/dist/shared-data/status/requests.mjs
10876
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.64_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_9a6a00428921d756e77d8976c0226cf3/node_modules/@toggl/queries/dist/shared-data/status/requests.mjs
11041
10877
  async function getStatus(httpClient, signal) {
11042
10878
  return (await httpClient.get(`shared_data/api/status`, { signal })).json();
11043
10879
  }
11044
10880
  //#endregion
11045
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.63_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_3085063bba60f639e8aa7f3285add2c2/node_modules/@toggl/queries/dist/org/timeoff/requests.mjs
10881
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.64_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_9a6a00428921d756e77d8976c0226cf3/node_modules/@toggl/queries/dist/org/timeoff/requests.mjs
11046
10882
  async function timeoffListMyEntries(httpClient, organization_id, { from, to }, signal) {
11047
10883
  return (await httpClient.get(`timeoff/organizations/${organization_id}/me`, {
11048
10884
  signal,
@@ -11070,7 +10906,7 @@ async function timeoffDeleteMyEntry(httpClient, organization_id, id, signal) {
11070
10906
  return response.json();
11071
10907
  }
11072
10908
  //#endregion
11073
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.63_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_3085063bba60f639e8aa7f3285add2c2/node_modules/@toggl/queries/dist/shared-data/working-hours/requests.mjs
10909
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.64_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_reac_9a6a00428921d756e77d8976c0226cf3/node_modules/@toggl/queries/dist/shared-data/working-hours/requests.mjs
11074
10910
  async function getMyWorkingHours(httpClient, organization_id, signal) {
11075
10911
  return (await httpClient.get(`shared_data/api/workinghours/${organization_id}/me`, { signal })).json();
11076
10912
  }
@@ -11095,7 +10931,7 @@ async function deleteMyWorkingHours(httpClient, organization_id, data, signal) {
11095
10931
  return response.json();
11096
10932
  }
11097
10933
  //#endregion
11098
- //#region ../cli-core/build/focus-client-Ba1HhujK.js
10934
+ //#region ../cli-core/build/focus-client-D9JzuIl3.js
11099
10935
  /** Request header the API reads to attribute traffic to MCP or CLI. */
11100
10936
  const TOGGL_CLIENT_HEADER = "X-Toggl-Client";
11101
10937
  /** Header the Focus API reads for analytics and presence `platform_origin`. */
@@ -11264,14 +11100,12 @@ async function downloadAttachment(ctx, scope, params) {
11264
11100
  const TimeOffMeUpdateInputSchema$1 = /* @__PURE__ */ intersect([/* @__PURE__ */ object$2({ timeoff_id: /* @__PURE__ */ number$2() }), PublicMeEntryRequestSchema]);
11265
11101
  const TaskPatchSchema = withCustomFieldValues(/* @__PURE__ */ partial(TaskPartialUpdatePayloadSchema));
11266
11102
  const ProjectPatchSchema = withCustomFieldValues(/* @__PURE__ */ partial(ProjectPartialUpdatePayloadSchema));
11267
- const TimeBlockPatchSchema = /* @__PURE__ */ partial(TimeBlockPartialUpdatePayloadSchema);
11268
11103
  const BulkIdsSchema = /* @__PURE__ */ object$2({
11269
11104
  ids: /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(/* @__PURE__ */ number$2()), /* @__PURE__ */ minLength$1(1)),
11270
11105
  outbound_sync: /* @__PURE__ */ optional$1(/* @__PURE__ */ boolean$1())
11271
11106
  });
11272
11107
  const BulkTaskPatchItemsSchema = /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(withCustomFieldValues(TaskPartialUpdatePayloadWithIDSchema)), /* @__PURE__ */ minLength$1(1));
11273
11108
  const BulkProjectPatchItemsSchema = /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(withCustomFieldValues(ProjectPartialUpdatePayloadWithIDSchema)), /* @__PURE__ */ minLength$1(1));
11274
- const BulkTimeBlockPatchItemsSchema = /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(TimeBlockPartialUpdatePayloadWithIDSchema), /* @__PURE__ */ minLength$1(1));
11275
11109
  const BulkTimeEntryPatchItemsSchema = /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(TimeEntryPartialUpdatePayloadWithIDSchema$1), /* @__PURE__ */ minLength$1(1));
11276
11110
  const BulkTimeEntryCreateItemsSchema = /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(TimeEntryBulkCreatePayloadSchema$1), /* @__PURE__ */ minLength$1(1));
11277
11111
  const BulkTimeEntryIdsSchema = /* @__PURE__ */ object$2({ ids: /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(/* @__PURE__ */ number$2()), /* @__PURE__ */ minLength$1(1)) });
@@ -11649,71 +11483,6 @@ var FocusClient = class {
11649
11483
  return await bulkUnarchiveProjects(this.http, this.organizationIdNum, this.workspaceIdNum, input.data);
11650
11484
  });
11651
11485
  }
11652
- async listTimeBlocks(params = {}) {
11653
- const rawFrom = typeof params.date_from === "string" ? params.date_from : "";
11654
- const rawTo = typeof params.date_to === "string" ? params.date_to : "";
11655
- if (!rawFrom || !rawTo) return {
11656
- ok: false,
11657
- status: 400,
11658
- message: "date_from and date_to are required"
11659
- };
11660
- const date_from = normalizeDateFrom(rawFrom);
11661
- const date_to = normalizeDateTo(rawTo);
11662
- const response = await this.run("listTimeBlocks", () => getTimeBlocksRangeWithOrgClassic(this.http, this.organizationIdNum, this.workspaceIdNum, {
11663
- date_from,
11664
- date_to,
11665
- task_id: parseOptionalInt(params.task_id),
11666
- page: parseOptionalInt(params.page),
11667
- per_page: parseOptionalInt(params.per_page)
11668
- }));
11669
- return this.softValidateResponse("listTimeBlocks", PaginatedTimeBlockAggregateWithTasksSchema, response);
11670
- }
11671
- async getTimeBlock(taskId, timeBlockId) {
11672
- const response = await this.run("getTimeBlock", () => getTimeBlockWithOrg(this.http, this.organizationIdNum, this.workspaceIdNum, taskId, timeBlockId));
11673
- return this.softValidateResponse("getTimeBlock", TimeBlockSchema, response);
11674
- }
11675
- async createTimeBlock(taskId, payload) {
11676
- const input = validatePayload(TimeBlockPayloadSchema, payload, "createTimeBlock payload");
11677
- if (!input.ok) return input;
11678
- const response = await this.run("createTimeBlock", () => createTimeBlockWithOrg(this.http, this.organizationIdNum, this.workspaceIdNum, taskId, input.data));
11679
- return this.softValidateResponse("createTimeBlock", TimeBlockSchema, response);
11680
- }
11681
- async updateTimeBlock(taskId, timeBlockId, payload) {
11682
- const input = validatePayload(TimeBlockPatchSchema, payload, "updateTimeBlock payload");
11683
- if (!input.ok) return input;
11684
- return this.run("updateTimeBlock", async () => {
11685
- return await partialUpdateTimeBlockWithOrg(this.http, this.organizationIdNum, this.workspaceIdNum, taskId, timeBlockId, input.data);
11686
- });
11687
- }
11688
- async deleteTimeBlock(taskId, timeBlockId) {
11689
- return this.run("deleteTimeBlock", async () => {
11690
- await deleteTimeBlockWithOrg(this.http, this.organizationIdNum, this.workspaceIdNum, taskId, timeBlockId);
11691
- return null;
11692
- });
11693
- }
11694
- async bulkCreateTimeBlocks(payload) {
11695
- const input = validatePayload(TimeBlockBulkCreatePayloadSchema, payload, "bulkCreateTimeBlocks payload");
11696
- if (!input.ok) return input;
11697
- const response = await this.run("bulkCreateTimeBlocks", () => bulkCreateTimeBlockWithOrg(this.http, this.organizationIdNum, this.workspaceIdNum, input.data));
11698
- return this.softValidateResponse("bulkCreateTimeBlocks", /* @__PURE__ */ array$1(TimeBlockSchema), response);
11699
- }
11700
- async bulkPartialUpdateTimeBlocks(items) {
11701
- const input = validatePayload(BulkTimeBlockPatchItemsSchema, items, "bulkPartialUpdateTimeBlocks items");
11702
- if (!input.ok) return input;
11703
- return this.run("bulkPartialUpdateTimeBlocks", async () => {
11704
- return await bulkPartialUpdateTimeBlockWithOrg(this.http, this.organizationIdNum, this.workspaceIdNum, input.data);
11705
- });
11706
- }
11707
- async bulkDeleteTimeBlocks(ids, outbound_sync) {
11708
- const input = validatePayload(BulkIdsSchema, {
11709
- ids,
11710
- outbound_sync
11711
- }, "bulkDeleteTimeBlocks input");
11712
- if (!input.ok) return input;
11713
- return this.run("bulkDeleteTimeBlocks", async () => {
11714
- return await bulkDeleteTimeBlockWithOrg(this.http, this.organizationIdNum, this.workspaceIdNum, input.data.ids, input.data.outbound_sync);
11715
- });
11716
- }
11717
11486
  async listTimeEntries(params = {}) {
11718
11487
  const rawFrom = typeof params.date_from === "string" ? params.date_from : "";
11719
11488
  const rawTo = typeof params.date_to === "string" ? params.date_to : "";
@@ -13166,7 +12935,7 @@ async function runSkillSetup(options) {
13166
12935
  });
13167
12936
  }
13168
12937
  //#endregion
13169
- //#region ../operations/build/validation-DK7SDWIU.js
12938
+ //#region ../operations/build/validation-CLozpAO5.js
13170
12939
  const optionalNumber = /* @__PURE__ */ optional$1(/* @__PURE__ */ number$2());
13171
12940
  const perPageField = (max) => /* @__PURE__ */ optional$1(/* @__PURE__ */ pipe$2(/* @__PURE__ */ number$2(), /* @__PURE__ */ integer(), /* @__PURE__ */ minValue$1(1), /* @__PURE__ */ maxValue$1(max), /* @__PURE__ */ description$1(`Results per page (1-${max})`)));
13172
12941
  const perPageSchema = perPageField(100);
@@ -13181,13 +12950,6 @@ const rateSchedulePayloadSchema = /* @__PURE__ */ pipe$2(/* @__PURE__ */ strictO
13181
12950
  end_date: /* @__PURE__ */ optional$1(rateDateSchema)
13182
12951
  }), /* @__PURE__ */ forward(/* @__PURE__ */ partialCheck([["start_date"], ["end_date"]], ({ start_date, end_date }) => end_date === void 0 || end_date >= start_date, "must be on or after start_date"), ["end_date"]));
13183
12952
  const tagIdFilterSchema = /* @__PURE__ */ union([/* @__PURE__ */ pipe$2(/* @__PURE__ */ number$2(), /* @__PURE__ */ transform((tagId) => [tagId])), /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(/* @__PURE__ */ number$2()), /* @__PURE__ */ minLength$1(1))]);
13184
- const timeBlockListSchema = /* @__PURE__ */ object$2({
13185
- date_from: dateField("Range start — date-only (e.g. '2025-01-01') or RFC3339 datetime. Date-only is expanded to T00:00:00Z."),
13186
- date_to: dateField("Range end — date-only (e.g. '2025-01-07') or RFC3339 datetime. Date-only is expanded to T23:59:59Z."),
13187
- task_id: /* @__PURE__ */ optional$1(/* @__PURE__ */ pipe$2(/* @__PURE__ */ number$2(), /* @__PURE__ */ description$1("Filter by task ID"))),
13188
- page: /* @__PURE__ */ optional$1(/* @__PURE__ */ pipe$2(/* @__PURE__ */ number$2(), /* @__PURE__ */ description$1("Page number"))),
13189
- per_page: perPageSchema
13190
- });
13191
12953
  const timeEntryListSchema = /* @__PURE__ */ object$2({
13192
12954
  date_from: dateField("Range start — date-only (e.g. '2025-01-01') or RFC3339 datetime. Date-only is expanded to T00:00:00Z."),
13193
12955
  date_to: dateField("Range end — date-only (e.g. '2025-01-07') or RFC3339 datetime. Date-only is expanded to T23:59:59Z."),
@@ -13316,19 +13078,6 @@ const projectUpdateSchema = /* @__PURE__ */ object$2({
13316
13078
  project_id: /* @__PURE__ */ number$2(),
13317
13079
  payload: withCustomFieldValues(/* @__PURE__ */ partial(ProjectPartialUpdatePayloadSchema))
13318
13080
  });
13319
- const timeBlockCreateSchema = /* @__PURE__ */ object$2({
13320
- task_id: /* @__PURE__ */ number$2(),
13321
- payload: TimeBlockPayloadSchema
13322
- });
13323
- const timeBlockUpdateSchema = /* @__PURE__ */ object$2({
13324
- task_id: /* @__PURE__ */ number$2(),
13325
- time_block_id: /* @__PURE__ */ number$2(),
13326
- payload: /* @__PURE__ */ partial(TimeBlockPartialUpdatePayloadSchema)
13327
- });
13328
- const timeBlockIdSchema = /* @__PURE__ */ object$2({
13329
- task_id: /* @__PURE__ */ number$2(),
13330
- time_block_id: /* @__PURE__ */ number$2()
13331
- });
13332
13081
  const taskIdSchema = /* @__PURE__ */ object$2({ task_id: /* @__PURE__ */ number$2() });
13333
13082
  const projectIdSchema = /* @__PURE__ */ object$2({ project_id: /* @__PURE__ */ number$2() });
13334
13083
  const emptySchema$1 = /* @__PURE__ */ object$2({});
@@ -13378,7 +13127,6 @@ const bulkIdsWithOutboundSchema = /* @__PURE__ */ object$2({
13378
13127
  const bulkProjectDeleteSchema = /* @__PURE__ */ object$2({ ids: /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(/* @__PURE__ */ number$2()), /* @__PURE__ */ minLength$1(1)) });
13379
13128
  const bulkTaskPatchBodySchema = /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(withCustomFieldValues(TaskPartialUpdatePayloadWithIDSchema)), /* @__PURE__ */ minLength$1(1));
13380
13129
  const bulkProjectPatchBodySchema = /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(withCustomFieldValues(ProjectPartialUpdatePayloadWithIDSchema)), /* @__PURE__ */ minLength$1(1));
13381
- const bulkTimeBlockPatchBodySchema = /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(TimeBlockPartialUpdatePayloadWithIDSchema), /* @__PURE__ */ minLength$1(1));
13382
13130
  const bulkTimeEntryPatchBodySchema = /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(TimeEntryPartialUpdatePayloadWithIDSchema$1), /* @__PURE__ */ minLength$1(1));
13383
13131
  const bulkTimeEntryCreateBodySchema = /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(TimeEntryBulkCreatePayloadSchema$1), /* @__PURE__ */ minLength$1(1));
13384
13132
  const bulkTimeEntryIdsSchema = /* @__PURE__ */ object$2({ ids: /* @__PURE__ */ pipe$2(/* @__PURE__ */ array$1(/* @__PURE__ */ number$2()), /* @__PURE__ */ minLength$1(1)) });
@@ -13481,7 +13229,7 @@ const compositeOverrides = {
13481
13229
  mcp: { entityTool: "projects" }
13482
13230
  },
13483
13231
  "focus.composite.create-task": {
13484
- description: "Create a task with related data such as subtasks, time blocks, and an initial time entry.",
13232
+ description: "Create a task with related data such as subtasks and an initial time entry.",
13485
13233
  cli: {
13486
13234
  group: ["tasks"],
13487
13235
  command: "create-with-children",
@@ -14070,103 +13818,6 @@ const taskOverrides = {
14070
13818
  }]
14071
13819
  }
14072
13820
  };
14073
- const timeBlockOverrides = {
14074
- "focus.time-blocks.list": {
14075
- agentGuidance: "Returns scheduled time blocks in a date range. Requires date_from and date_to. Accepts date-only strings (YYYY-MM-DD) or RFC3339 datetimes — date-only is automatically expanded: date_from to T00:00:00Z, date_to to T23:59:59Z. Results include associated task summaries.",
14076
- examples: [{
14077
- description: "List time blocks for a date range (date-only, expanded to full-day range)",
14078
- data: {
14079
- date_from: "2025-01-01",
14080
- date_to: "2025-01-07"
14081
- }
14082
- }, {
14083
- description: "List time blocks with explicit RFC3339 timestamps",
14084
- data: {
14085
- date_from: "2025-01-01T00:00:00Z",
14086
- date_to: "2025-01-07T23:59:59Z"
14087
- }
14088
- }]
14089
- },
14090
- "focus.time-blocks.get": {
14091
- agentGuidance: "Fetch a single time block by task ID and time block ID.",
14092
- examples: [{
14093
- description: "Get a time block",
14094
- data: {
14095
- task_id: 12345,
14096
- time_block_id: 67890
14097
- }
14098
- }]
14099
- },
14100
- "focus.time-blocks.create": {
14101
- agentGuidance: "Required: task_id and payload.start (ISO 8601 datetime). Optionally set payload.duration (minutes) and payload.completed.",
14102
- examples: [{
14103
- description: "Schedule a 1-hour time block",
14104
- data: {
14105
- task_id: 12345,
14106
- payload: {
14107
- start: "2025-01-15T09:00:00Z",
14108
- duration: 60
14109
- }
14110
- }
14111
- }]
14112
- },
14113
- "focus.time-blocks.update": {
14114
- agentGuidance: "Partial update — provide task_id, time_block_id, and fields to change in payload.",
14115
- examples: [{
14116
- description: "Mark a time block as completed",
14117
- data: {
14118
- task_id: 12345,
14119
- time_block_id: 67890,
14120
- payload: { completed: true }
14121
- }
14122
- }]
14123
- },
14124
- "focus.time-blocks.delete": {
14125
- agentGuidance: "Permanently removes the scheduled time block from the task.",
14126
- examples: [{
14127
- description: "Delete a time block",
14128
- data: {
14129
- task_id: 12345,
14130
- time_block_id: 67890
14131
- }
14132
- }]
14133
- },
14134
- "focus.time-blocks.bulk-create": {
14135
- agentGuidance: "Body shape: { time_blocks: [{ task_id, start, duration?, completed? }, ...] }. Creates many blocks in one request.",
14136
- examples: [{
14137
- description: "Schedule two blocks",
14138
- data: { time_blocks: [{
14139
- task_id: 12345,
14140
- start: "2025-01-15T09:00:00Z",
14141
- duration: 60
14142
- }, {
14143
- task_id: 12345,
14144
- start: "2025-01-15T11:00:00Z",
14145
- duration: 30
14146
- }] }
14147
- }]
14148
- },
14149
- "focus.time-blocks.bulk-patch": {
14150
- agentGuidance: "JSON array of { id: timeBlockId, ...partial fields }; same fields as single time-block update.",
14151
- examples: [{
14152
- description: "Mark two blocks complete",
14153
- data: [{
14154
- id: 101,
14155
- completed: true
14156
- }, {
14157
- id: 102,
14158
- completed: true
14159
- }]
14160
- }]
14161
- },
14162
- "focus.time-blocks.bulk-delete": {
14163
- agentGuidance: "Deletes time blocks by numeric id list in one HTTP call (not task_id/time_block_id pairs).",
14164
- examples: [{
14165
- description: "Delete two blocks",
14166
- data: { ids: [101, 102] }
14167
- }]
14168
- }
14169
- };
14170
13821
  const timeEntryOverrides = {
14171
13822
  "focus.time-entries.list": {
14172
13823
  agentGuidance: "Returns tracked time entries in a date range, including taskless entries (tracked on a project with no task). Requires date_from and date_to. Accepts date-only strings (YYYY-MM-DD) or RFC3339 datetimes — date-only is automatically expanded: date_from to T00:00:00Z, date_to to T23:59:59Z. Optional project_id keeps only entries on that project (sent to the API; client also scans up to 50 list pages of 100, then slices page/per_page; not a full workspace scan). If truncated is true, more unfiltered rows exist than were scanned — narrow date_from/date_to. Pass include_taskless:false to hide taskless rows. Includes task and project context.",
@@ -15699,6 +15350,104 @@ async function getProjectSuggestionsForMultipleTasks(httpClient, organization_id
15699
15350
  }).json();
15700
15351
  }
15701
15352
  //#endregion
15353
+ //#region ../focus-queries/dist/time-blocks/requests.ts
15354
+ async function getTaskTimeBlocksWithOrgClassic(httpClient, organization_id, workspace_id, task_id, { page, per_page, order_by, archived } = {}, signal) {
15355
+ return await httpClient.get(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks`, {
15356
+ signal,
15357
+ searchParams: buildSearchParams$2({
15358
+ page,
15359
+ per_page,
15360
+ order_by,
15361
+ archived
15362
+ })
15363
+ }).json();
15364
+ }
15365
+ async function createTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, data, signal) {
15366
+ return await httpClient.post(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks`, {
15367
+ signal,
15368
+ json: data
15369
+ }).json();
15370
+ }
15371
+ async function getTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, signal) {
15372
+ return await httpClient.get(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}`, { signal }).json();
15373
+ }
15374
+ async function updateTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, data, signal) {
15375
+ return await httpClient.put(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}`, {
15376
+ signal,
15377
+ json: data
15378
+ }).json();
15379
+ }
15380
+ async function deleteTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, outbound_sync, signal) {
15381
+ return await httpClient.delete(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}`, {
15382
+ signal,
15383
+ searchParams: buildSearchParams$2({ outbound_sync })
15384
+ }).json();
15385
+ }
15386
+ async function partialUpdateTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, data, signal) {
15387
+ return await httpClient.patch(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}`, {
15388
+ signal,
15389
+ json: data
15390
+ }).json();
15391
+ }
15392
+ async function archiveTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, signal) {
15393
+ return await httpClient.post(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}/archive`, { signal }).json();
15394
+ }
15395
+ async function restoreTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, signal) {
15396
+ return await httpClient.patch(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}/restore`, { signal }).json();
15397
+ }
15398
+ async function unarchiveTimeBlockWithOrg(httpClient, organization_id, workspace_id, task_id, time_block_id, signal) {
15399
+ return await httpClient.post(`organizations/${organization_id}/workspaces/${workspace_id}/tasks/${task_id}/time-blocks/${time_block_id}/unarchive`, { signal }).json();
15400
+ }
15401
+ async function getTimeBlocksRangeWithOrgClassic(httpClient, organization_id, workspace_id, { date_from, date_to, task_id, status_id, page, per_page, archived, order_by }, signal) {
15402
+ return await httpClient.get(`organizations/${organization_id}/workspaces/${workspace_id}/time-blocks`, {
15403
+ signal,
15404
+ searchParams: buildSearchParams$2({
15405
+ date_from,
15406
+ date_to,
15407
+ task_id,
15408
+ status_id,
15409
+ page,
15410
+ per_page,
15411
+ archived,
15412
+ order_by
15413
+ })
15414
+ }).json();
15415
+ }
15416
+ async function bulkCreateTimeBlockWithOrg(httpClient, organization_id, workspace_id, data, signal) {
15417
+ return await httpClient.post(`organizations/${organization_id}/workspaces/${workspace_id}/time-blocks/bulk`, {
15418
+ signal,
15419
+ json: data
15420
+ }).json();
15421
+ }
15422
+ async function bulkDeleteTimeBlockWithOrg(httpClient, organization_id, workspace_id, ids, outbound_sync, signal) {
15423
+ return await httpClient.delete(`organizations/${organization_id}/workspaces/${workspace_id}/time-blocks/bulk`, {
15424
+ signal,
15425
+ searchParams: buildSearchParams$2({
15426
+ ids,
15427
+ outbound_sync
15428
+ })
15429
+ }).json();
15430
+ }
15431
+ async function bulkPartialUpdateTimeBlockWithOrg(httpClient, organization_id, workspace_id, data, signal) {
15432
+ return await httpClient.patch(`organizations/${organization_id}/workspaces/${workspace_id}/time-blocks/bulk`, {
15433
+ signal,
15434
+ json: data
15435
+ }).json();
15436
+ }
15437
+ async function getTimeBlocksRangeStreamWithOrg(httpClient, organization_id, workspace_id, { date_from, date_to, task_id, status_id, archived, order_by }, signal) {
15438
+ return await httpClient.get(`organizations/${organization_id}/workspaces/${workspace_id}/time-blocks/stream`, {
15439
+ signal,
15440
+ searchParams: buildSearchParams$2({
15441
+ date_from,
15442
+ date_to,
15443
+ task_id,
15444
+ status_id,
15445
+ archived,
15446
+ order_by
15447
+ })
15448
+ }).json();
15449
+ }
15450
+ //#endregion
15702
15451
  //#region ../focus-queries/dist/time-entry-constraints/requests.ts
15703
15452
  async function getTimeEntryConstraints(httpClient, workspace_id, signal) {
15704
15453
  return await httpClient.get(`workspaces/${workspace_id}/time-entry-constraints`, { signal }).json();
@@ -23542,10 +23291,22 @@ const generatedFocusOperations = [
23542
23291
  interactive: "default"
23543
23292
  },
23544
23293
  mcp: { entityTool: "time-blocks" },
23545
- inputSchema: TimeBlockBulkCreatePayloadSchema,
23294
+ inputSchema: /* @__PURE__ */ looseObject({ payload: /* @__PURE__ */ looseObject({ time_blocks: /* @__PURE__ */ array$1(/* @__PURE__ */ looseObject({
23295
+ start: apiDateTimeString,
23296
+ task_id: /* @__PURE__ */ number$2(),
23297
+ completed: /* @__PURE__ */ optional$1(/* @__PURE__ */ boolean$1()),
23298
+ duration: /* @__PURE__ */ optional$1(/* @__PURE__ */ number$2()),
23299
+ outbound_sync: /* @__PURE__ */ optional$1(/* @__PURE__ */ boolean$1())
23300
+ })) }) }),
23546
23301
  execute: (input, { client }) => {
23547
23302
  const data = input;
23548
- return client.bulkCreateTimeBlocks(data);
23303
+ return client.runGeneratedRequest("bulkCreateTimeBlockWithOrg", () => callGeneratedRequest(bulkCreateTimeBlockWithOrg, [
23304
+ client.httpClient,
23305
+ client.organizationId,
23306
+ client.workspaceIdNumber,
23307
+ data.payload ?? data.data ?? data,
23308
+ void 0
23309
+ ]));
23549
23310
  }
23550
23311
  },
23551
23312
  {
@@ -23563,31 +23324,47 @@ const generatedFocusOperations = [
23563
23324
  interactive: "default"
23564
23325
  },
23565
23326
  mcp: { entityTool: "time-blocks" },
23566
- inputSchema: bulkIdsWithOutboundSchema,
23327
+ inputSchema: /* @__PURE__ */ looseObject({
23328
+ ids: /* @__PURE__ */ array$1(/* @__PURE__ */ number$2()),
23329
+ outbound_sync: /* @__PURE__ */ optional$1(/* @__PURE__ */ boolean$1())
23330
+ }),
23567
23331
  execute: (input, { client }) => {
23568
23332
  const data = input;
23569
- return client.bulkDeleteTimeBlocks(data.ids, data.outbound_sync);
23333
+ return client.runGeneratedRequest("bulkDeleteTimeBlockWithOrg", () => callGeneratedRequest(bulkDeleteTimeBlockWithOrg, [
23334
+ client.httpClient,
23335
+ client.organizationId,
23336
+ client.workspaceIdNumber,
23337
+ data.ids,
23338
+ data.outbound_sync,
23339
+ void 0
23340
+ ]));
23570
23341
  }
23571
23342
  },
23572
23343
  {
23573
- id: "focus.time-blocks.bulk-patch",
23344
+ id: "focus.time-blocks.bulk-partial-update",
23574
23345
  family: "focus",
23575
23346
  resource: "time-blocks",
23576
- action: "bulk-patch",
23577
- title: "Bulk Patch Time Blocks",
23578
- description: "Bulk Patch Time Blocks.",
23347
+ action: "bulk-partial-update",
23348
+ title: "Bulk Partial Update Time Blocks",
23349
+ description: "Bulk Partial Update Time Blocks.",
23579
23350
  safety: "update",
23580
23351
  destructive: false,
23581
23352
  cli: {
23582
23353
  group: ["time-blocks", "bulk"],
23583
- command: "patch",
23584
- interactive: "default"
23354
+ command: "partial-update",
23355
+ interactive: "hidden"
23585
23356
  },
23586
23357
  mcp: { entityTool: "time-blocks" },
23587
- inputSchema: bulkTimeBlockPatchBodySchema,
23358
+ inputSchema: /* @__PURE__ */ looseObject({ payload: /* @__PURE__ */ unknown$1() }),
23588
23359
  execute: (input, { client }) => {
23589
23360
  const data = input;
23590
- return client.bulkPartialUpdateTimeBlocks(data);
23361
+ return client.runGeneratedRequest("bulkPartialUpdateTimeBlockWithOrg", () => callGeneratedRequest(bulkPartialUpdateTimeBlockWithOrg, [
23362
+ client.httpClient,
23363
+ client.organizationId,
23364
+ client.workspaceIdNumber,
23365
+ data.payload ?? data.data ?? data,
23366
+ void 0
23367
+ ]));
23591
23368
  }
23592
23369
  },
23593
23370
  {
@@ -23605,10 +23382,25 @@ const generatedFocusOperations = [
23605
23382
  interactive: "default"
23606
23383
  },
23607
23384
  mcp: { entityTool: "time-blocks" },
23608
- inputSchema: timeBlockCreateSchema,
23385
+ inputSchema: /* @__PURE__ */ looseObject({
23386
+ payload: /* @__PURE__ */ looseObject({
23387
+ start: apiDateTimeString,
23388
+ completed: /* @__PURE__ */ optional$1(/* @__PURE__ */ boolean$1()),
23389
+ duration: /* @__PURE__ */ optional$1(/* @__PURE__ */ number$2()),
23390
+ outbound_sync: /* @__PURE__ */ optional$1(/* @__PURE__ */ boolean$1())
23391
+ }),
23392
+ task_id: /* @__PURE__ */ number$2()
23393
+ }),
23609
23394
  execute: (input, { client }) => {
23610
23395
  const data = input;
23611
- return client.createTimeBlock(data.task_id, data.payload);
23396
+ return client.runGeneratedRequest("createTimeBlockWithOrg", () => callGeneratedRequest(createTimeBlockWithOrg, [
23397
+ client.httpClient,
23398
+ client.organizationId,
23399
+ client.workspaceIdNumber,
23400
+ data.task_id,
23401
+ data.payload ?? data.data ?? data,
23402
+ void 0
23403
+ ]));
23612
23404
  }
23613
23405
  },
23614
23406
  {
@@ -23626,10 +23418,22 @@ const generatedFocusOperations = [
23626
23418
  interactive: "default"
23627
23419
  },
23628
23420
  mcp: { entityTool: "time-blocks" },
23629
- inputSchema: timeBlockIdSchema,
23421
+ inputSchema: /* @__PURE__ */ looseObject({
23422
+ outbound_sync: /* @__PURE__ */ optional$1(/* @__PURE__ */ boolean$1()),
23423
+ task_id: /* @__PURE__ */ number$2(),
23424
+ time_block_id: /* @__PURE__ */ number$2()
23425
+ }),
23630
23426
  execute: (input, { client }) => {
23631
23427
  const data = input;
23632
- return client.deleteTimeBlock(data.task_id, data.time_block_id);
23428
+ return client.runGeneratedRequest("deleteTimeBlockWithOrg", () => callGeneratedRequest(deleteTimeBlockWithOrg, [
23429
+ client.httpClient,
23430
+ client.organizationId,
23431
+ client.workspaceIdNumber,
23432
+ data.task_id,
23433
+ data.time_block_id,
23434
+ data.outbound_sync,
23435
+ void 0
23436
+ ]));
23633
23437
  }
23634
23438
  },
23635
23439
  {
@@ -23647,10 +23451,56 @@ const generatedFocusOperations = [
23647
23451
  interactive: "available"
23648
23452
  },
23649
23453
  mcp: { entityTool: "time-blocks" },
23650
- inputSchema: timeBlockIdSchema,
23454
+ inputSchema: /* @__PURE__ */ looseObject({
23455
+ task_id: /* @__PURE__ */ number$2(),
23456
+ time_block_id: /* @__PURE__ */ number$2()
23457
+ }),
23458
+ execute: (input, { client }) => {
23459
+ const data = input;
23460
+ return client.runGeneratedRequest("getTimeBlockWithOrg", () => callGeneratedRequest(getTimeBlockWithOrg, [
23461
+ client.httpClient,
23462
+ client.organizationId,
23463
+ client.workspaceIdNumber,
23464
+ data.task_id,
23465
+ data.time_block_id,
23466
+ void 0
23467
+ ]));
23468
+ }
23469
+ },
23470
+ {
23471
+ id: "focus.time-blocks.get-range",
23472
+ family: "focus",
23473
+ resource: "time-blocks",
23474
+ action: "get-range",
23475
+ title: "Get Range Time Blocks",
23476
+ description: "Get Range Time Blocks.",
23477
+ safety: "read",
23478
+ destructive: false,
23479
+ cli: {
23480
+ group: ["time-blocks"],
23481
+ command: "get-range",
23482
+ interactive: "hidden"
23483
+ },
23484
+ mcp: { entityTool: "time-blocks" },
23485
+ inputSchema: /* @__PURE__ */ looseObject({
23486
+ archived: /* @__PURE__ */ unknown$1(),
23487
+ date_from: /* @__PURE__ */ unknown$1(),
23488
+ date_to: /* @__PURE__ */ unknown$1(),
23489
+ order_by: /* @__PURE__ */ unknown$1(),
23490
+ page: /* @__PURE__ */ number$2(),
23491
+ per_page: /* @__PURE__ */ unknown$1(),
23492
+ status_id: /* @__PURE__ */ number$2(),
23493
+ task_id: /* @__PURE__ */ number$2()
23494
+ }),
23651
23495
  execute: (input, { client }) => {
23652
23496
  const data = input;
23653
- return client.getTimeBlock(data.task_id, data.time_block_id);
23497
+ return client.runGeneratedRequest("getTimeBlocksRangeWithOrgClassic", () => callGeneratedRequest(getTimeBlocksRangeWithOrgClassic, [
23498
+ client.httpClient,
23499
+ client.organizationId,
23500
+ client.workspaceIdNumber,
23501
+ data,
23502
+ void 0
23503
+ ]));
23654
23504
  }
23655
23505
  },
23656
23506
  {
@@ -23722,24 +23572,42 @@ const generatedFocusOperations = [
23722
23572
  }
23723
23573
  },
23724
23574
  {
23725
- id: "focus.time-blocks.list",
23575
+ id: "focus.time-blocks.partial-update",
23726
23576
  family: "focus",
23727
23577
  resource: "time-blocks",
23728
- action: "list",
23729
- title: "List Time Blocks",
23730
- description: "List Time Blocks.",
23731
- safety: "read",
23578
+ action: "partial-update",
23579
+ title: "Partial Update Time Blocks",
23580
+ description: "Partial Update Time Blocks.",
23581
+ safety: "update",
23732
23582
  destructive: false,
23733
23583
  cli: {
23734
23584
  group: ["time-blocks"],
23735
- command: "list",
23736
- interactive: "available"
23585
+ command: "partial-update",
23586
+ interactive: "default"
23737
23587
  },
23738
23588
  mcp: { entityTool: "time-blocks" },
23739
- inputSchema: timeBlockListSchema,
23589
+ inputSchema: /* @__PURE__ */ looseObject({
23590
+ payload: /* @__PURE__ */ looseObject({
23591
+ completed: /* @__PURE__ */ optional$1(/* @__PURE__ */ boolean$1()),
23592
+ duration: /* @__PURE__ */ optional$1(/* @__PURE__ */ number$2()),
23593
+ outbound_sync: /* @__PURE__ */ optional$1(/* @__PURE__ */ boolean$1()),
23594
+ start: /* @__PURE__ */ optional$1(apiDateTimeString),
23595
+ task_id: /* @__PURE__ */ optional$1(/* @__PURE__ */ number$2())
23596
+ }),
23597
+ task_id: /* @__PURE__ */ number$2(),
23598
+ time_block_id: /* @__PURE__ */ number$2()
23599
+ }),
23740
23600
  execute: (input, { client }) => {
23741
23601
  const data = input;
23742
- return client.listTimeBlocks(data);
23602
+ return client.runGeneratedRequest("partialUpdateTimeBlockWithOrg", () => callGeneratedRequest(partialUpdateTimeBlockWithOrg, [
23603
+ client.httpClient,
23604
+ client.organizationId,
23605
+ client.workspaceIdNumber,
23606
+ data.task_id,
23607
+ data.time_block_id,
23608
+ data.payload ?? data.data ?? data,
23609
+ void 0
23610
+ ]));
23743
23611
  }
23744
23612
  },
23745
23613
  {
@@ -23819,27 +23687,6 @@ const generatedFocusOperations = [
23819
23687
  interactive: "default"
23820
23688
  },
23821
23689
  mcp: { entityTool: "time-blocks" },
23822
- inputSchema: timeBlockUpdateSchema,
23823
- execute: (input, { client }) => {
23824
- const data = input;
23825
- return client.updateTimeBlock(data.task_id, data.time_block_id, data.payload);
23826
- }
23827
- },
23828
- {
23829
- id: "focus.time-blocks.update-with-org",
23830
- family: "focus",
23831
- resource: "time-blocks",
23832
- action: "update-with-org",
23833
- title: "Update With Org Time Blocks",
23834
- description: "Update With Org Time Blocks.",
23835
- safety: "update",
23836
- destructive: false,
23837
- cli: {
23838
- group: ["time-blocks"],
23839
- command: "update-with-org",
23840
- interactive: "default"
23841
- },
23842
- mcp: { entityTool: "time-blocks" },
23843
23690
  inputSchema: /* @__PURE__ */ looseObject({
23844
23691
  payload: /* @__PURE__ */ looseObject({
23845
23692
  start: apiDateTimeString,
@@ -26349,7 +26196,6 @@ const focusOperationOverrides = {
26349
26196
  ...projectAttachmentOverrides,
26350
26197
  ...rateOverrides,
26351
26198
  ...readOnlyPostOverrides,
26352
- ...timeBlockOverrides,
26353
26199
  ...timeEntryOverrides,
26354
26200
  ...versionOverrides,
26355
26201
  ...statusOverrides,
@@ -26698,7 +26544,6 @@ function extractRootArrayItemSchema(schema) {
26698
26544
  }
26699
26545
  function singularLabelFromOperationId(operationId) {
26700
26546
  if (operationId.includes("time-entries")) return "time entry";
26701
- if (operationId.includes("time-blocks")) return "time block";
26702
26547
  if (operationId.includes("tasks")) return "task";
26703
26548
  if (operationId.includes("projects")) return "project";
26704
26549
  return "item";
@@ -26723,7 +26568,6 @@ function singularizeLabel(label) {
26723
26568
  const t = label.trim();
26724
26569
  if (t.length <= 1) return t;
26725
26570
  const lower = t.toLowerCase();
26726
- if (lower === "time blocks") return "time block";
26727
26571
  if (lower.endsWith("ies")) return `${t.slice(0, -3)}y`;
26728
26572
  if (lower.endsWith("s")) return t.slice(0, -1);
26729
26573
  return t;
@@ -27960,4 +27804,4 @@ Common commands:
27960
27804
  //#endregion
27961
27805
  export { CommanderError as a, shutdownCliTelemetry as i, captureCliException as n, initCliTelemetry as r, createProgram as t };
27962
27806
 
27963
- //# sourceMappingURL=program-C5GYCsU3.js.map
27807
+ //# sourceMappingURL=program-C0-wDCc4.js.map
package/build/program.js CHANGED
@@ -1,2 +1,2 @@
1
- import { t as createProgram } from "./program-C5GYCsU3.js";
1
+ import { t as createProgram } from "./program-C0-wDCc4.js";
2
2
  export { createProgram };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@togglhq/cli",
3
- "version": "1.11.65",
3
+ "version": "1.11.67",
4
4
  "description": "Toggl CLI for Toggl 2.0 API operations.",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",
@@ -56,7 +56,7 @@
56
56
  "devDependencies": {
57
57
  "@toggl/cli-core": "workspace:^",
58
58
  "@toggl/operations": "workspace:^",
59
- "@toggl/queries": "2.2.63",
59
+ "@toggl/queries": "2.2.64",
60
60
  "@types/node": "22.19.11",
61
61
  "tsdown": "0.21.8",
62
62
  "typescript": "5.9.3",
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: toggl-cli
3
- description: Use the Toggl CLI to work with Toggl 2.0 tasks, projects, time entries, time blocks, workspaces, authentication, and CLI maintenance from an agent-friendly terminal workflow. Trigger when the user asks to inspect or modify Toggl 2.0 data through the terminal, authenticate Toggl, switch workspaces, install or refresh the Toggl agent skill, update the CLI, or automate Toggl 2.0 workflows.
3
+ description: Use the Toggl CLI to work with Toggl 2.0 tasks, projects, time entries, workspaces, authentication, and CLI maintenance from an agent-friendly terminal workflow. Trigger when the user asks to inspect or modify Toggl 2.0 data through the terminal, authenticate Toggl, switch workspaces, install or refresh the Toggl agent skill, update the CLI, or automate Toggl 2.0 workflows.
4
4
  ---
5
5
 
6
6
  # Toggl CLI
@@ -11,7 +11,7 @@ Use the `toggl` command when the user wants to inspect or modify Toggl 2.0 data
11
11
 
12
12
  Use this skill when the task involves:
13
13
 
14
- - Listing, reading, creating, updating, or deleting Toggl 2.0 tasks, projects, time blocks, or time entries.
14
+ - Listing, reading, creating, updating, or deleting Toggl 2.0 tasks, projects, or time entries.
15
15
  - Managing saved views, custom fields (admin), and task/project attachments (including file upload and download).
16
16
  - Finding workspace metadata such as statuses, users, and workspace IDs.
17
17
  - Authenticating the Toggl CLI, switching saved profiles, or switching the active workspace.
@@ -49,7 +49,6 @@ Do not use this skill for Toggl Track APIs, raw Toggl 2.0 API calls, or MCP serv
49
49
  - Tasks: `reference/tasks.md`
50
50
  - Projects: `reference/projects.md`
51
51
  - Time entries: `reference/time-entries.md`
52
- - Time blocks: `reference/time-blocks.md`
53
52
  - Rates and billables (Toggl 2.0 API vs Track): `reference/rates-and-billables.md`
54
53
  - Statuses and users: `reference/statuses-users.md`
55
54
  - Reports (`get-workload` vs `get-flexq-data`): `reference/reports.md`
@@ -31,7 +31,6 @@ Core resources and actions:
31
31
  | -------------- | ----------------------------------------------------------------------------------- |
32
32
  | `tasks` | `list`, `get`, `create`, `update`, `delete`, and **`bulk`** subcommands (see below) |
33
33
  | `projects` | `list`, `get`, `create`, `update`, `delete`, and **`bulk`** subcommands |
34
- | `time-blocks` | `list`, `get`, `create`, `update`, `delete`, and **`bulk`** subcommands |
35
34
  | `time-entries` | `list`, `start`, `stop`, and **`bulk`** subcommands |
36
35
  | `statuses` | `list` |
37
36
  | `users` | `list` |
@@ -44,7 +43,6 @@ Bulk mutations use a nested command: **`toggl <resource> bulk <verb>`** (for exa
44
43
  | -------------- | --------------------------------------------------------------------------- |
45
44
  | `tasks` | `create`, `patch`, `delete`, `archive`, `restore`, `unarchive`, `duplicate` |
46
45
  | `projects` | `patch`, `delete`, `archive`, `restore`, `unarchive` |
47
- | `time-blocks` | `create`, `patch`, `delete` |
48
46
  | `time-entries` | `create`, `patch`, `delete`, `restore` |
49
47
 
50
48
  `list` commands also have the `ls` alias.
@@ -103,7 +101,6 @@ Bulk endpoints expect JSON via `--data` or `--data-file` (arrays for patch-style
103
101
  ```bash
104
102
  toggl --json tasks bulk patch --dry-run --data '[{"id":111,"status_id":456789},{"id":222,"status_id":456789}]'
105
103
  toggl --json projects bulk patch --data-file ./project-updates.json
106
- toggl --json time-blocks bulk create --data '{"time_blocks":[{"task_id":12345,"start":"2026-04-01T09:00:00Z","duration":60}]}'
107
104
  toggl --json time-entries bulk patch --data '[{"id":9001,"description":"Updated"}]'
108
105
  toggl --json tasks bulk delete --data '{"ids":[111,222]}' --yes
109
106
  ```
@@ -125,10 +122,8 @@ Delete commands require `--yes`. Never add `--yes` unless the user clearly reque
125
122
  ```bash
126
123
  toggl --json tasks delete --task-id 12345 --yes
127
124
  toggl --json projects delete --project-id 123456 --yes
128
- toggl --json time-blocks delete --task-id 12345 --time-block-id 67890 --yes
129
125
  toggl --json tasks bulk delete --data '{"ids":[111,222]}' --yes
130
126
  toggl --json projects bulk delete --data '{"ids":[123456,123457]}' --yes
131
- toggl --json time-blocks bulk delete --data '{"ids":[101,102]}' --yes
132
127
  ```
133
128
 
134
129
  ## Dates
@@ -142,7 +137,7 @@ Examples:
142
137
 
143
138
  ```bash
144
139
  toggl --json time-entries list --date-from 2026-04-01 --date-to 2026-04-07
145
- toggl --json time-blocks list --date-from 2026-04-01T08:00:00+03:00 --date-to 2026-04-01T17:00:00+03:00
140
+ toggl --json time-entries list --date-from 2026-04-01T08:00:00+03:00 --date-to 2026-04-01T17:00:00+03:00
146
141
  ```
147
142
 
148
143
  ## Discovery
@@ -11,7 +11,6 @@ Environment/Profile
11
11
  -> Workspace
12
12
  -> Projects
13
13
  -> Tasks
14
- -> Time blocks
15
14
  -> Time entries
16
15
  -> Statuses
17
16
  -> Users
@@ -27,7 +26,7 @@ A profile stores credentials and the selected workspace. Use profiles when the u
27
26
 
28
27
  ### Workspace
29
28
 
30
- A workspace is the top-level context for projects, tasks, statuses, users, time entries, and time blocks. Most IDs only make sense inside the active workspace.
29
+ A workspace is the top-level context for projects, tasks, statuses, users, and time entries. Most IDs only make sense inside the active workspace.
31
30
 
32
31
  Use workspace commands when the agent needs to list available workspaces, refresh workspace metadata, switch the default workspace, or override the workspace for one command.
33
32
 
@@ -59,12 +58,6 @@ A time entry represents actual tracked time. Starting a time entry begins the ru
59
58
 
60
59
  Use time entries when the user wants to track work, start a break, stop tracking, or inspect actual logged time.
61
60
 
62
- ### Time Block
63
-
64
- A time block represents scheduled or planned work. Time blocks usually belong to a task and have explicit start/end times.
65
-
66
- Use time blocks when the user wants to schedule, plan, move, inspect, or delete calendar-like time blocks.
67
-
68
61
  ## Choosing the Right Command
69
62
 
70
63
  If the user wants to:
@@ -74,7 +67,6 @@ If the user wants to:
74
67
  - Move work through a workflow: resolve the task ID and status ID, then update the task.
75
68
  - Track actual time: resolve the task ID, then start a time entry.
76
69
  - Stop tracking: stop the current time entry.
77
- - Schedule planned work: resolve the task ID, then create a time block.
78
70
  - Find people: list users.
79
71
  - Change workspace context: list or switch workspaces, or pass `--workspace-id`.
80
72
 
@@ -70,7 +70,7 @@ Use `YYYY-MM-DD` for full days or RFC 3339 for exact datetimes:
70
70
 
71
71
  ```bash
72
72
  toggl --json time-entries list --date-from 2026-04-01 --date-to 2026-04-07
73
- toggl --json time-blocks list --date-from 2026-04-01T08:00:00+03:00 --date-to 2026-04-01T17:00:00+03:00
73
+ toggl --json time-entries list --date-from 2026-04-01T08:00:00+03:00 --date-to 2026-04-01T17:00:00+03:00
74
74
  ```
75
75
 
76
76
  ## Destructive Operation Blocked
@@ -75,18 +75,6 @@ Stop the running timer:
75
75
  toggl --json time-entries stop
76
76
  ```
77
77
 
78
- ## Plan a Time Block
79
-
80
- 1. Resolve the task ID.
81
- 2. Convert user-provided times to RFC 3339 datetimes.
82
- 3. Dry-run when the time range was inferred.
83
- 4. Create the block.
84
-
85
- ```bash
86
- toggl time-blocks create --data '{"task_id":12345,"payload":{"start":"2026-04-06T09:00:00+03:00","end":"2026-04-06T11:00:00+03:00"}}' --dry-run
87
- toggl --json time-blocks create --data '{"task_id":12345,"payload":{"start":"2026-04-06T09:00:00+03:00","end":"2026-04-06T11:00:00+03:00"}}'
88
- ```
89
-
90
78
  ## Switch Workspace
91
79
 
92
80
  List workspaces, refresh if needed, then switch:
@@ -1,43 +0,0 @@
1
- # Time Blocks
2
-
3
- Use time block commands to inspect, create, update, and delete scheduled time blocks.
4
-
5
- ## Commands
6
-
7
- List time blocks for a date range:
8
-
9
- ```bash
10
- toggl --json time-blocks list --date-from 2026-04-01 --date-to 2026-04-07
11
- ```
12
-
13
- Get one time block:
14
-
15
- ```bash
16
- toggl --json time-blocks get --task-id <task-id> --time-block-id <time-block-id>
17
- ```
18
-
19
- Create a time block:
20
-
21
- ```bash
22
- toggl --json time-blocks create --data '{"task_id":12345,"payload":{"start":"2026-04-06T09:00:00Z","end":"2026-04-06T11:00:00Z"}}'
23
- ```
24
-
25
- Update a time block:
26
-
27
- ```bash
28
- toggl --json time-blocks update --data '{"task_id":12345,"time_block_id":67890,"payload":{"start":"2026-04-06T10:00:00Z","end":"2026-04-06T12:00:00Z"}}'
29
- ```
30
-
31
- Delete a time block only after explicit user confirmation:
32
-
33
- ```bash
34
- toggl --json time-blocks delete --task-id <task-id> --time-block-id <time-block-id> --yes
35
- ```
36
-
37
- ## Agent Workflow
38
-
39
- Use RFC 3339 timestamps for exact scheduled blocks. If the user gives local times, preserve the intended time zone offset when possible.
40
-
41
- Time block commands usually need both `task_id` and `time_block_id`. Resolve both IDs with a list or get command before mutating.
42
-
43
- Use `--dry-run` before creating or updating blocks when times were inferred from natural language.