@dsptch-work/api-client 0.47.0 → 0.49.0

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.
@@ -212,12 +212,6 @@ export const zProblem = z.object({
212
212
  *
213
213
  * The item cannot be unarchived while its product is still archived — an item never lives active inside an archived product. Unarchive the product instead, which restores the item along with the rest of the product's holdings.
214
214
  *
215
- * ### recorded_since_termination
216
- *
217
- * **Timecode Changed Since Termination**
218
- *
219
- * Cancelling this timecode's scheduled termination would silently discard changes recorded since it was terminated. Re-read the timecode and reconcile before retrying.
220
- *
221
215
  * ### span_beyond_timeline_end
222
216
  *
223
217
  * **Span Beyond Timeline End**
@@ -430,7 +424,6 @@ export const zProblemTypeCatalog = z.enum([
430
424
  'pay_schedule_deletion_in_progress',
431
425
  'pay_schedule_deletion_refused',
432
426
  'product_archived',
433
- 'recorded_since_termination',
434
427
  'span_beyond_timeline_end',
435
428
  'version_overlap',
436
429
  'precondition_failed',
@@ -1935,6 +1928,47 @@ export const zPayPeriodConfigParameters = z.object({
1935
1928
  approvals_deadline_clock_time: z.string().regex(/^([01][0-9]|2[0-3]):[0-5][0-9]$/),
1936
1929
  time_card_auto_lock_days: z.int().nullish()
1937
1930
  });
1931
+ /**
1932
+ * Schedule a change to an existing pay schedule. effective_date is required; other fields are optional. tz_name, time_mode, and payroll_mode are refused.
1933
+ */
1934
+ export const zPayPeriodConfigUpdateParameters = z.object({
1935
+ effective_date: z.iso.date(),
1936
+ frequency: z.enum(['weekly', 'biweekly']).optional(),
1937
+ start_day_of_week: z.union([
1938
+ z.literal(0),
1939
+ z.literal(1),
1940
+ z.literal(2),
1941
+ z.literal(3),
1942
+ z.literal(4),
1943
+ z.literal(5),
1944
+ z.literal(6)
1945
+ ]).optional(),
1946
+ tz_name: z.string().optional(),
1947
+ rounding_interval: z.union([z.literal(1), z.literal(15)]).optional(),
1948
+ payroll_system: z.enum([
1949
+ 'rippling',
1950
+ 'quickbooks_online',
1951
+ 'paychex',
1952
+ 'gusto'
1953
+ ]).nullish(),
1954
+ paid_after_holiday: z.boolean().optional(),
1955
+ arrear_days: z.int().gte(0).optional(),
1956
+ pay_run_deadline_days: z.int().gte(1).optional(),
1957
+ pay_run_deadline_clock_time: z.string().regex(/^([01][0-9]|2[0-3]):[0-5][0-9]$/).optional(),
1958
+ approvals_deadline_days: z.int().gte(0).optional(),
1959
+ approvals_deadline_clock_time: z.string().regex(/^([01][0-9]|2[0-3]):[0-5][0-9]$/).optional(),
1960
+ time_card_auto_lock_days: z.int().nullish(),
1961
+ time_mode: z.enum([
1962
+ 'none',
1963
+ 'base',
1964
+ 'aggregate'
1965
+ ]).optional(),
1966
+ payroll_mode: z.enum([
1967
+ 'none',
1968
+ 'base',
1969
+ 'aggregate'
1970
+ ]).nullish()
1971
+ });
1938
1972
  /**
1939
1973
  * A pay schedule (PayPeriodConfig) — the top-level timekeeping unit that sets a company's payroll cadence and tracking modes and generates its stream of pay periods. Reads return the version valid at the requested time; create returns the new schedule, keyed by its stable id.
1940
1974
  */
@@ -6827,6 +6861,36 @@ export const zLaborRateResponseObject = z.object({
6827
6861
  fringe_percentage_rate: z.string().nullable(),
6828
6862
  fringe_benefit_weekly_rate_cents: z.string().nullable(),
6829
6863
  fringe_benefit_monthly_rate_cents: z.string().nullable(),
6864
+ fringe_calculation: z.object({
6865
+ available: z.boolean(),
6866
+ hourly_cents: z.string().nullable(),
6867
+ reasons: z.array(z.string()),
6868
+ component_ids: z.array(z.string())
6869
+ }),
6870
+ fringe_benefit_components: z.array(z.object({
6871
+ id: z.string(),
6872
+ position: z.int(),
6873
+ amount_cents: z.string(),
6874
+ period: z.enum([
6875
+ 'hour',
6876
+ 'day',
6877
+ 'week',
6878
+ 'month',
6879
+ 'year',
6880
+ 'shift'
6881
+ ]),
6882
+ kind: z.enum([
6883
+ 'fringe',
6884
+ 'wage_premium',
6885
+ 'unresolved'
6886
+ ]),
6887
+ text: z.string(),
6888
+ attachment_status: z.enum(['rate', 'unresolved']),
6889
+ labor_rate_id: z.string().nullable(),
6890
+ source_sha256: z.string(),
6891
+ start_offset: z.int(),
6892
+ end_offset: z.int()
6893
+ })),
6830
6894
  reference_item_ids: z.array(z.string()),
6831
6895
  created_at: z.iso.datetime(),
6832
6896
  updated_at: z.iso.datetime()
@@ -8497,7 +8561,8 @@ export const zAssetsTransactionEventResponseObject = z.object({
8497
8561
  kind: z.enum([
8498
8562
  'receive',
8499
8563
  'adjust',
8500
- 'transfer'
8564
+ 'transfer',
8565
+ 'transfer_contents'
8501
8566
  ]),
8502
8567
  quantity: z.int()
8503
8568
  }),
@@ -8770,14 +8835,14 @@ export const zAssetsTransferResponseObject = z.object({
8770
8835
  to_assets_site_id: z.string().nullable(),
8771
8836
  to_user_id: z.string().nullable(),
8772
8837
  to_container_item_id: z.string().nullable(),
8773
- from_assets_sub_location_id: z.string().nullable(),
8774
8838
  to_assets_sub_location_id: z.string().nullable(),
8775
8839
  initiated_by_user_id: z.string(),
8776
8840
  completed_at: z.iso.datetime().nullable(),
8777
8841
  transfer_lines: z.array(z.object({
8778
8842
  id: z.string(),
8779
8843
  assets_item_id: z.string(),
8780
- quantity: z.int()
8844
+ quantity: z.int(),
8845
+ from_assets_sub_location_id: z.string().nullable()
8781
8846
  })),
8782
8847
  created_at: z.iso.datetime(),
8783
8848
  updated_at: z.iso.datetime()
@@ -14951,6 +15016,17 @@ export const zGetPayPeriodConfigQuery = z.object({
14951
15016
  * Success
14952
15017
  */
14953
15018
  export const zGetPayPeriodConfigResponse = zPayPeriodConfigResponseObject;
15019
+ export const zUpdatePayPeriodConfigBody = zPayPeriodConfigUpdateParameters;
15020
+ export const zUpdatePayPeriodConfigHeaders = z.object({
15021
+ 'If-Match': z.string()
15022
+ });
15023
+ export const zUpdatePayPeriodConfigPath = z.object({
15024
+ id: z.string()
15025
+ });
15026
+ /**
15027
+ * Accepted
15028
+ */
15029
+ export const zUpdatePayPeriodConfigResponse = zPayPeriodConfigResponseObject;
14954
15030
  export const zListTimeCardActualsQuery = z.object({
14955
15031
  'filter[timekeeping_time_card_id]': z.string().optional(),
14956
15032
  'filter[created_at][gte]': z.iso.datetime().optional(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dsptch-work/api-client",
3
- "version": "0.47.0",
3
+ "version": "0.49.0",
4
4
  "description": "Generated TypeScript client for the DSPTCH REST API.",
5
5
  "keywords": [
6
6
  "dsptch",