@factorialco/api-client 3.0.0-beta.2026100119 → 3.0.0-beta.2026100121

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.
@@ -4405,6 +4405,12 @@ export type IntegrationsSyncRun = {
4405
4405
  * Timestamp when the sync run finished
4406
4406
  */
4407
4407
  finished_at?: string;
4408
+ /**
4409
+ * Scope of this sync run. Holds `from` and `to`, the inclusive ISO-8601 dates of the period it covers; either key is absent when unknown, and the object is empty when the run is not date-scoped.
4410
+ */
4411
+ context: {
4412
+ [key: string]: unknown;
4413
+ };
4408
4414
  /**
4409
4415
  * Identifier of the company
4410
4416
  */
@@ -4448,6 +4454,44 @@ export type IntegrationsSyncableItem = {
4448
4454
  */
4449
4455
  syncable_type: 'compensations/compensation' | 'expenses/expense' | 'employee_updates/leave' | 'employee_updates/worked_time' | 'finance/vendor';
4450
4456
  };
4457
+ export type IntegrationsSyncableState = {
4458
+ /**
4459
+ * Identifier of the syncable state
4460
+ */
4461
+ id: string;
4462
+ /**
4463
+ * Identifier of the Factorial record this state is linked to
4464
+ */
4465
+ syncable_id?: string;
4466
+ /**
4467
+ * The resource type of the linked record, in "namespace/resource" form
4468
+ */
4469
+ resource_syncable_type: string;
4470
+ /**
4471
+ * UUID of the marketplace integration
4472
+ */
4473
+ integration_uuid: string;
4474
+ /**
4475
+ * Synchronization status of the record
4476
+ */
4477
+ status: 'synced' | 'syncing' | 'outdated' | 'invalid' | 'failed';
4478
+ /**
4479
+ * Error or validation messages of the syncable state
4480
+ */
4481
+ error_messages: Array<unknown>;
4482
+ /**
4483
+ * Timestamp of the last status change
4484
+ */
4485
+ status_updated_at: string;
4486
+ /**
4487
+ * Identifier of the record in the external system
4488
+ */
4489
+ external_identifier?: string;
4490
+ /**
4491
+ * Timestamp when the linked Factorial record was deleted, if any
4492
+ */
4493
+ syncable_deleted_at?: string;
4494
+ };
4451
4495
  export type IntegrationsSyncableSyncRun = {
4452
4496
  /**
4453
4497
  * Identifier of the syncable sync run
@@ -7159,7 +7203,13 @@ export type TimeoffLeave = {
7159
7203
  */
7160
7204
  duration_attributes?: string;
7161
7205
  /**
7162
- * Number of days taken for paid leave
7206
+ * Per-day breakdown of the leave's workable and used units, keyed by calendar date. Populated only when the read requests `include_duration_by_day=true`; null otherwise.
7207
+ */
7208
+ duration_by_day_attributes?: {
7209
+ [key: string]: unknown;
7210
+ };
7211
+ /**
7212
+ * Number of days taken for paid leave. Reflects the summed per-day used total when the per-day breakdown is computed; otherwise the leave's calendar-day duration.
7163
7213
  */
7164
7214
  days_taken: number;
7165
7215
  };
@@ -15986,6 +16036,57 @@ export type GetApi20261001ResourcesIntegrationsSyncableItemsResponses = {
15986
16036
  };
15987
16037
  };
15988
16038
  export type GetApi20261001ResourcesIntegrationsSyncableItemsResponse = GetApi20261001ResourcesIntegrationsSyncableItemsResponses[keyof GetApi20261001ResourcesIntegrationsSyncableItemsResponses];
16039
+ export type GetApi20261001ResourcesIntegrationsSyncableStatesData = {
16040
+ body?: never;
16041
+ path?: never;
16042
+ query?: {
16043
+ /**
16044
+ * Filter syncable states by their identifiers
16045
+ */
16046
+ 'ids[]'?: Array<string>;
16047
+ /**
16048
+ * Filter syncable states by the identifiers of the linked API resource, identified by resource_syncable_type field
16049
+ */
16050
+ 'syncable_ids[]'?: Array<string>;
16051
+ /**
16052
+ * The resource type of the linked records, in "namespace/resource" form. Required when filtering by syncable_ids.
16053
+ */
16054
+ resource_syncable_type?: string;
16055
+ /**
16056
+ * Filter syncable states by the UUID of the marketplace integration
16057
+ */
16058
+ integration_uuid?: string;
16059
+ };
16060
+ url: '/api/2026-10-01/resources/integrations/syncable_states';
16061
+ };
16062
+ export type GetApi20261001ResourcesIntegrationsSyncableStatesResponses = {
16063
+ /**
16064
+ * OK
16065
+ */
16066
+ 200: {
16067
+ data?: Array<IntegrationsSyncableState>;
16068
+ meta?: PagedIndexMeta;
16069
+ };
16070
+ };
16071
+ export type GetApi20261001ResourcesIntegrationsSyncableStatesResponse = GetApi20261001ResourcesIntegrationsSyncableStatesResponses[keyof GetApi20261001ResourcesIntegrationsSyncableStatesResponses];
16072
+ export type GetApi20261001ResourcesIntegrationsSyncableStatesByIdData = {
16073
+ body?: never;
16074
+ path: {
16075
+ /**
16076
+ * Filter syncable states by their identifiers
16077
+ */
16078
+ id: string;
16079
+ };
16080
+ query?: never;
16081
+ url: '/api/2026-10-01/resources/integrations/syncable_states/{id}';
16082
+ };
16083
+ export type GetApi20261001ResourcesIntegrationsSyncableStatesByIdResponses = {
16084
+ /**
16085
+ * OK
16086
+ */
16087
+ 200: IntegrationsSyncableState;
16088
+ };
16089
+ export type GetApi20261001ResourcesIntegrationsSyncableStatesByIdResponse = GetApi20261001ResourcesIntegrationsSyncableStatesByIdResponses[keyof GetApi20261001ResourcesIntegrationsSyncableStatesByIdResponses];
15989
16090
  export type GetApi20261001ResourcesIntegrationsSyncableSyncRunsData = {
15990
16091
  body?: never;
15991
16092
  path?: never;
@@ -23037,6 +23138,10 @@ export type GetApi20261001ResourcesTimeoffLeavesData = {
23037
23138
  * Retrieve leave duration
23038
23139
  */
23039
23140
  include_duration?: boolean;
23141
+ /**
23142
+ * Retrieve the per-day breakdown of the leave's duration (`duration_by_day_attributes`)
23143
+ */
23144
+ include_duration_by_day?: boolean;
23040
23145
  /**
23041
23146
  * Retrieve workable leaves
23042
23147
  */