@togglhq/cli 1.11.142 → 1.11.144

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/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-Cuk4ZdmI.js";
2
+ import { a as CommanderError, i as shutdownCliTelemetry, n as captureCliException, r as initCliTelemetry, t as createProgram } from "./program-BEO-4L3J.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-Cuk4ZdmI.js";
1
+ import { t as createProgram } from "./program-BEO-4L3J.js";
2
2
  export { createProgram };
@@ -5495,10 +5495,6 @@ function _joinExpects$1(values$1, separator) {
5495
5495
  */
5496
5496
  const ISO_DATE_REGEX$1 = /^\d{4}-(?:0[1-9]|1[0-2])-(?:[12]\d|0[1-9]|3[01])$/u;
5497
5497
  /**
5498
- * [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time regex.
5499
- */
5500
- const ISO_DATE_TIME_REGEX$1 = /^\d{4}-(?:0[1-9]|1[0-2])-(?:[12]\d|0[1-9]|3[01])[T ](?:0\d|1\d|2[0-3]):[0-5]\d$/u;
5501
- /**
5502
5498
  * [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp regex. Allows a
5503
5499
  * space as a date/time separator and an optional space before the UTC offset.
5504
5500
  */
@@ -5552,22 +5548,6 @@ function isoDate$1(message$1) {
5552
5548
  };
5553
5549
  }
5554
5550
  /* @__NO_SIDE_EFFECTS__ */
5555
- function isoDateTime$1(message$1) {
5556
- return {
5557
- kind: "validation",
5558
- type: "iso_date_time",
5559
- reference: isoDateTime$1,
5560
- async: false,
5561
- expects: null,
5562
- requirement: ISO_DATE_TIME_REGEX$1,
5563
- message: message$1,
5564
- "~run"(dataset, config$1) {
5565
- if (dataset.typed && !this.requirement.test(dataset.value)) _addIssue$1(this, "date-time", dataset, config$1);
5566
- return dataset;
5567
- }
5568
- };
5569
- }
5570
- /* @__NO_SIDE_EFFECTS__ */
5571
5551
  function isoTimestamp(message$1) {
5572
5552
  return {
5573
5553
  kind: "validation",
@@ -7816,8 +7796,7 @@ const OrganizationUserResponseSchema = /* @__PURE__ */ object({
7816
7796
  work_role_id: /* @__PURE__ */ number(),
7817
7797
  workspace_user_id: /* @__PURE__ */ number()
7818
7798
  })),
7819
- custom_field_values: /* @__PURE__ */ optional(/* @__PURE__ */ array(CustomFieldValueSchema)),
7820
- has_calendar_integration: /* @__PURE__ */ optional(/* @__PURE__ */ pipe(/* @__PURE__ */ boolean(), /* @__PURE__ */ description("HasCalendarIntegration is true when the member has a calendar connected in Focus. The field is present only when the request sets include_calendar_integration to true and the calendar lookup succeeded. The field is absent when the lookup failed. Absent means unknown. It does not mean false. A member who connected a calendar in another product stays false here until they open the Focus calendar integrations page.")))
7799
+ custom_field_values: /* @__PURE__ */ optional(/* @__PURE__ */ array(CustomFieldValueSchema))
7821
7800
  });
7822
7801
  const ProjectBulkArchivePayloadSchema = /* @__PURE__ */ object({ project_ids: /* @__PURE__ */ pipe(/* @__PURE__ */ array(/* @__PURE__ */ number()), /* @__PURE__ */ minLength(1), /* @__PURE__ */ maxLength(100)) });
7823
7802
  const ProjectBulkRestorePayloadSchema = /* @__PURE__ */ object({ project_ids: /* @__PURE__ */ pipe(/* @__PURE__ */ array(/* @__PURE__ */ number()), /* @__PURE__ */ minLength(1), /* @__PURE__ */ maxLength(100)) });
@@ -9913,7 +9892,7 @@ async function getOrganizationTeamsClassic(httpClient, organization_id, { worksp
9913
9892
  })
9914
9893
  }).json();
9915
9894
  }
9916
- async function getOrganizationUsersClassic(httpClient, organization_id, { workspaces, user_account_ids, org_user_ids, groups, toggl_products, active_status, roles, only_admins, filter, sort_dir, page, per_page, tag_ids, include_working_hours, include_rates, pinned_ids, has_group, cf_filter, include_custom_fields, include_calendar_integration } = {}, signal) {
9895
+ async function getOrganizationUsersClassic(httpClient, organization_id, { workspaces, user_account_ids, org_user_ids, groups, toggl_products, active_status, roles, only_admins, filter, sort_dir, page, per_page, tag_ids, include_working_hours, include_rates, pinned_ids, has_group, cf_filter, include_custom_fields } = {}, signal) {
9917
9896
  const response = await httpClient.get(`organizations/${organization_id}/users`, {
9918
9897
  signal,
9919
9898
  searchParams: buildSearchParams$2({
@@ -9935,8 +9914,7 @@ async function getOrganizationUsersClassic(httpClient, organization_id, { worksp
9935
9914
  pinned_ids,
9936
9915
  has_group,
9937
9916
  cf_filter,
9938
- include_custom_fields,
9939
- include_calendar_integration
9917
+ include_custom_fields
9940
9918
  }, true)
9941
9919
  });
9942
9920
  return withResponseMeta(await response.json(), response.headers, response.status);
@@ -10799,7 +10777,7 @@ const PublicMeEntryRequestSchema = /* @__PURE__ */ object$2({
10799
10777
  ]))
10800
10778
  });
10801
10779
  //#endregion
10802
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.121_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_e64cae9c3cafee71d14fb3e3541ac7f7/node_modules/@toggl/queries/dist/org/invitation/requests.mjs
10780
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.124_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_969a045e6e4f645cea4cd5f88b441655/node_modules/@toggl/queries/dist/org/invitation/requests.mjs
10803
10781
  async function getInvitations(httpClient, signal) {
10804
10782
  return (await httpClient.get(`invitations`, { signal })).json();
10805
10783
  }
@@ -10816,7 +10794,7 @@ async function resendInvitation(httpClient, organization_id, organization_user_i
10816
10794
  return (await httpClient.post(`organizations/${organization_id}/invitations/${organization_user_id}/resend`, { signal })).json();
10817
10795
  }
10818
10796
  //#endregion
10819
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.121_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_e64cae9c3cafee71d14fb3e3541ac7f7/node_modules/@toggl/queries/dist/org/utils/requests.mjs
10797
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.124_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_969a045e6e4f645cea4cd5f88b441655/node_modules/@toggl/queries/dist/org/utils/requests.mjs
10820
10798
  function buildSearchParams(params, flattenArrays = false) {
10821
10799
  const searchParams = new URLSearchParams();
10822
10800
  Object.entries(params).forEach(([key, value]) => {
@@ -10828,7 +10806,7 @@ function buildSearchParams(params, flattenArrays = false) {
10828
10806
  return searchParams;
10829
10807
  }
10830
10808
  //#endregion
10831
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.121_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_e64cae9c3cafee71d14fb3e3541ac7f7/node_modules/@toggl/queries/dist/org/organization-user/requests.mjs
10809
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.124_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_969a045e6e4f645cea4cd5f88b441655/node_modules/@toggl/queries/dist/org/organization-user/requests.mjs
10832
10810
  async function getOrganizationUser(httpClient, organization_id, organization_user_id, signal) {
10833
10811
  return (await httpClient.get(`organizations/${organization_id}/users/${organization_user_id}`, { signal })).json();
10834
10812
  }
@@ -10842,7 +10820,7 @@ async function patchOrganizationUserActive(httpClient, organization_id, organiza
10842
10820
  return (await httpClient.patch(`organizations/${organization_id}/users/${organization_user_id}/active_status/${status}`, { signal })).json();
10843
10821
  }
10844
10822
  //#endregion
10845
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.121_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_e64cae9c3cafee71d14fb3e3541ac7f7/node_modules/@toggl/queries/dist/org/workspace/requests.mjs
10823
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.124_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_969a045e6e4f645cea4cd5f88b441655/node_modules/@toggl/queries/dist/org/workspace/requests.mjs
10846
10824
  async function getWorkspaces(httpClient, organization_id, signal) {
10847
10825
  return (await httpClient.get(`organizations/${organization_id}/workspaces`, { signal })).json();
10848
10826
  }
@@ -10851,7 +10829,7 @@ async function getWorkspaceUserMeRoles(httpClient, organization_id, workspace_id
10851
10829
  }
10852
10830
  const WorkingHoursCreateInputSchema = /* @__PURE__ */ object$2({
10853
10831
  working_hours: /* @__PURE__ */ pipe$2(/* @__PURE__ */ number$2(), /* @__PURE__ */ maxValue$1(168)),
10854
- starting_hours: /* @__PURE__ */ optional$1(/* @__PURE__ */ pipe$2(/* @__PURE__ */ number$2(), /* @__PURE__ */ minValue$1(0), /* @__PURE__ */ maxValue$1(24))),
10832
+ starting_hours: /* @__PURE__ */ optional$1(/* @__PURE__ */ pipe$2(/* @__PURE__ */ number$2(), /* @__PURE__ */ maxValue$1(24))),
10855
10833
  weekday: /* @__PURE__ */ optional$1(/* @__PURE__ */ pipe$2(/* @__PURE__ */ number$2(), /* @__PURE__ */ minValue$1(0), /* @__PURE__ */ maxValue$1(6)))
10856
10834
  });
10857
10835
  const WorkingHoursUpdateInputSchema = /* @__PURE__ */ object$2({
@@ -10862,7 +10840,7 @@ const WorkingHoursUpdateInputSchema = /* @__PURE__ */ object$2({
10862
10840
  });
10863
10841
  const StatusOKSchema = /* @__PURE__ */ object$2({ status: /* @__PURE__ */ string$1() });
10864
10842
  //#endregion
10865
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.121_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_e64cae9c3cafee71d14fb3e3541ac7f7/node_modules/@toggl/queries/dist/org/holiday-calendar/requests.mjs
10843
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.124_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_969a045e6e4f645cea4cd5f88b441655/node_modules/@toggl/queries/dist/org/holiday-calendar/requests.mjs
10866
10844
  async function holidayListDates(httpClient, organization_id, { year, country }, signal) {
10867
10845
  return (await httpClient.get(`holidays/organizations/${organization_id}/calendar/dates`, {
10868
10846
  signal,
@@ -10873,12 +10851,12 @@ async function holidayListDates(httpClient, organization_id, { year, country },
10873
10851
  })).json();
10874
10852
  }
10875
10853
  //#endregion
10876
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.121_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_e64cae9c3cafee71d14fb3e3541ac7f7/node_modules/@toggl/queries/dist/shared-data/status/requests.mjs
10854
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.124_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_969a045e6e4f645cea4cd5f88b441655/node_modules/@toggl/queries/dist/shared-data/status/requests.mjs
10877
10855
  async function getStatus(httpClient, signal) {
10878
10856
  return (await httpClient.get(`shared_data/api/status`, { signal })).json();
10879
10857
  }
10880
10858
  //#endregion
10881
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.121_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_e64cae9c3cafee71d14fb3e3541ac7f7/node_modules/@toggl/queries/dist/org/timeoff/requests.mjs
10859
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.124_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_969a045e6e4f645cea4cd5f88b441655/node_modules/@toggl/queries/dist/org/timeoff/requests.mjs
10882
10860
  async function timeoffListMyEntries(httpClient, organization_id, { from, to }, signal) {
10883
10861
  return (await httpClient.get(`timeoff/organizations/${organization_id}/me`, {
10884
10862
  signal,
@@ -10906,7 +10884,7 @@ async function timeoffDeleteMyEntry(httpClient, organization_id, id, signal) {
10906
10884
  return response.json();
10907
10885
  }
10908
10886
  //#endregion
10909
- //#region ../../node_modules/.pnpm/@toggl+queries@2.2.121_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_e64cae9c3cafee71d14fb3e3541ac7f7/node_modules/@toggl/queries/dist/shared-data/working-hours/requests.mjs
10887
+ //#region ../../node_modules/.pnpm/@toggl+queries@2.2.124_@tanstack+react-query@5.99.0_react@19.2.5__@toggl+sync@0.2.4_rea_969a045e6e4f645cea4cd5f88b441655/node_modules/@toggl/queries/dist/shared-data/working-hours/requests.mjs
10910
10888
  async function getMyWorkingHours(httpClient, organization_id, signal) {
10911
10889
  return (await httpClient.get(`shared_data/api/workinghours/${organization_id}/me`, { signal })).json();
10912
10890
  }
@@ -15125,9 +15103,6 @@ async function dismissATemplateEstimateSuggestion(httpClient, organization_id, w
15125
15103
  }
15126
15104
  //#endregion
15127
15105
  //#region ../focus-queries/dist/reports/requests.ts
15128
- async function getForecastAvailability(httpClient, workspace_id, signal) {
15129
- return await httpClient.get(`reports/workspaces/${workspace_id}/forecast-availability`, { signal }).json();
15130
- }
15131
15106
  async function getProfitabilityReport(httpClient, workspace_id, data, response_format, include_dicts, xTogglReportExport, signal) {
15132
15107
  return await httpClient.post(`reports/workspaces/${workspace_id}/profitability`, {
15133
15108
  signal,
@@ -15573,21 +15548,6 @@ async function upsertTimeEntryConstraints(httpClient, workspace_id, data, signal
15573
15548
  }).json();
15574
15549
  }
15575
15550
  //#endregion
15576
- //#region ../focus-queries/dist/time-entry-groups/requests.ts
15577
- async function getTimeEntryGroupsUsersClassic(httpClient, organization_id, workspace_id, { start_date, end_date, user_id, page, per_page, order_by }, signal) {
15578
- return await httpClient.get(`organizations/${organization_id}/workspaces/${workspace_id}/time-entries/groups/users`, {
15579
- signal,
15580
- searchParams: buildSearchParams$2({
15581
- start_date,
15582
- end_date,
15583
- user_id,
15584
- page,
15585
- per_page,
15586
- order_by
15587
- })
15588
- }).json();
15589
- }
15590
- //#endregion
15591
15551
  //#region ../focus-queries/dist/time-off/requests.ts
15592
15552
  async function getTimeoffsByUserIds(httpClient, organization_id, { user_id, start_date, end_date }, signal) {
15593
15553
  return await httpClient.get(`organizations/${organization_id}/timeoff`, {
@@ -20638,28 +20598,6 @@ const generatedFocusOperations = [
20638
20598
  ]));
20639
20599
  }
20640
20600
  },
20641
- {
20642
- id: "focus.reports.get-forecast-availability",
20643
- family: "focus",
20644
- resource: "reports",
20645
- action: "get-forecast-availability",
20646
- title: "Get Forecast Availability Reports",
20647
- description: "Get Forecast Availability Reports.",
20648
- safety: "read",
20649
- destructive: false,
20650
- cli: {
20651
- group: ["reports"],
20652
- command: "get-forecast-availability",
20653
- interactive: "hidden"
20654
- },
20655
- mcp: { entityTool: "reports" },
20656
- inputSchema: /* @__PURE__ */ looseObject({}),
20657
- execute: (_input, { client }) => client.runGeneratedRequest("getForecastAvailability", () => callGeneratedRequest(getForecastAvailability, [
20658
- client.httpClient,
20659
- client.workspaceIdNumber,
20660
- void 0
20661
- ]))
20662
- },
20663
20601
  {
20664
20602
  id: "focus.reports.get-profitability",
20665
20603
  family: "focus",
@@ -24320,40 +24258,6 @@ const generatedFocusOperations = [
24320
24258
  ]));
24321
24259
  }
24322
24260
  },
24323
- {
24324
- id: "focus.time-entries.groups-get-users",
24325
- family: "focus",
24326
- resource: "time-entries",
24327
- action: "groups-get-users",
24328
- title: "Groups Get Users Time Entries",
24329
- description: "Groups Get Users Time Entries.",
24330
- safety: "read",
24331
- destructive: false,
24332
- cli: {
24333
- group: ["time-entries", "groups"],
24334
- command: "get-users",
24335
- interactive: "hidden"
24336
- },
24337
- mcp: { entityTool: "time-entries" },
24338
- inputSchema: /* @__PURE__ */ looseObject({
24339
- end_date: /* @__PURE__ */ pipe$2(/* @__PURE__ */ string$1(), /* @__PURE__ */ isoDate$1()),
24340
- order_by: /* @__PURE__ */ unknown$1(),
24341
- page: /* @__PURE__ */ number$2(),
24342
- per_page: /* @__PURE__ */ unknown$1(),
24343
- start_date: /* @__PURE__ */ pipe$2(/* @__PURE__ */ string$1(), /* @__PURE__ */ isoDate$1()),
24344
- user_id: /* @__PURE__ */ number$2()
24345
- }),
24346
- execute: (input, { client }) => {
24347
- const data = input;
24348
- return client.runGeneratedRequest("getTimeEntryGroupsUsersClassic", () => callGeneratedRequest(getTimeEntryGroupsUsersClassic, [
24349
- client.httpClient,
24350
- client.organizationId,
24351
- client.workspaceIdNumber,
24352
- data,
24353
- void 0
24354
- ]));
24355
- }
24356
- },
24357
24261
  {
24358
24262
  id: "focus.time-entries.list",
24359
24263
  family: "focus",
@@ -27914,4 +27818,4 @@ Common commands:
27914
27818
  //#endregion
27915
27819
  export { CommanderError as a, shutdownCliTelemetry as i, captureCliException as n, initCliTelemetry as r, createProgram as t };
27916
27820
 
27917
- //# sourceMappingURL=program-Cuk4ZdmI.js.map
27821
+ //# sourceMappingURL=program-BEO-4L3J.js.map
package/build/program.js CHANGED
@@ -1,2 +1,2 @@
1
- import { t as createProgram } from "./program-Cuk4ZdmI.js";
1
+ import { t as createProgram } from "./program-BEO-4L3J.js";
2
2
  export { createProgram };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@togglhq/cli",
3
- "version": "1.11.142",
3
+ "version": "1.11.144",
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.121",
59
+ "@toggl/queries": "2.2.124",
60
60
  "@types/node": "22.19.11",
61
61
  "tsdown": "0.21.8",
62
62
  "typescript": "5.9.3",