@workbuddy/sdk-js-vnext 1.0.2 → 1.0.4

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.
Files changed (3) hide show
  1. package/index.d.ts +650 -14
  2. package/index.js +177 -1
  3. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -85,6 +85,8 @@ export class WorkBuddyApiError extends Error {
85
85
  export class WorkBuddyClient {
86
86
  /** Jobs API operations. */
87
87
  jobs: WorkBuddyJobsResource;
88
+ /** Items API operations. */
89
+ items: WorkBuddyItemsResource;
88
90
  /** Stages API operations. */
89
91
  stages: WorkBuddyStagesResource;
90
92
  /** Settings API operations. */
@@ -823,6 +825,37 @@ export interface WorkBuddyJobsCreateParams extends WorkBuddyRequestParams {
823
825
  * Custom fields as key-value pairs — validated against tenant field definitions
824
826
  */
825
827
  customFields?: Record<string, unknown>;
828
+
829
+ items?: {
830
+ integrationId?: string;
831
+ code: string;
832
+ description?: string;
833
+ longDescription?: string;
834
+ quantity: number;
835
+ location?: string;
836
+ note?: string;
837
+ buyPrice?: number;
838
+ sellPrice?: number;
839
+ invoicingStatus?: 'Billable' | 'No Charge' | 'Not Billable';
840
+ suppliedBySubcontractor?: boolean;
841
+ }[];
842
+ }
843
+
844
+ export interface WorkBuddyJobsStatusUpdateStatusParams extends WorkBuddyRequestParams {
845
+ /**
846
+ * Job ID
847
+ */
848
+ id: string;
849
+ /**
850
+ * For optimistic concurrency — update fails if entity was modified after this timestamp
851
+ */
852
+ updatedAt?: string;
853
+ /**
854
+ * Status filter
855
+ */
856
+ status: 'open' | 'in_progress' | 'on_hold' | 'completed' | 'finalised' | 'closed' | 'cancelled';
857
+
858
+ note?: string;
826
859
  }
827
860
 
828
861
  export interface WorkBuddyJobsUpdateParams extends WorkBuddyRequestParams {
@@ -964,6 +997,31 @@ export interface WorkBuddyJobsStagesItemsListParams extends WorkBuddyRequestPara
964
997
  limit?: number;
965
998
  }
966
999
 
1000
+ export interface WorkBuddyJobsStagesItemsCreateStageItemsParams extends WorkBuddyRequestParams {
1001
+ /**
1002
+ * Job ID
1003
+ */
1004
+ id: string;
1005
+ /**
1006
+ * Stage ID
1007
+ */
1008
+ stageId: string;
1009
+
1010
+ items: {
1011
+ integrationId?: string;
1012
+ code: string;
1013
+ description?: string;
1014
+ longDescription?: string;
1015
+ quantity: number;
1016
+ location?: string;
1017
+ note?: string;
1018
+ buyPrice?: number;
1019
+ sellPrice?: number;
1020
+ invoicingStatus?: 'Billable' | 'No Charge' | 'Not Billable';
1021
+ suppliedBySubcontractor?: boolean;
1022
+ }[];
1023
+ }
1024
+
967
1025
  export interface WorkBuddyJobsStagesItemsGetStageItemParams extends WorkBuddyRequestParams {
968
1026
  /**
969
1027
  * Job ID
@@ -979,6 +1037,67 @@ export interface WorkBuddyJobsStagesItemsGetStageItemParams extends WorkBuddyReq
979
1037
  itemId: string;
980
1038
  }
981
1039
 
1040
+ export interface WorkBuddyJobsStagesItemsUpdateStageItemParams extends WorkBuddyRequestParams {
1041
+ /**
1042
+ * Job ID
1043
+ */
1044
+ id: string;
1045
+ /**
1046
+ * Stage ID
1047
+ */
1048
+ stageId: string;
1049
+ /**
1050
+ * Item ID
1051
+ */
1052
+ itemId: string;
1053
+ /**
1054
+ * For optimistic concurrency — update fails if entity was modified after this timestamp
1055
+ */
1056
+ updatedAt: string;
1057
+
1058
+ quantity?: number;
1059
+
1060
+ unit?: string;
1061
+
1062
+ location?: string;
1063
+
1064
+ note?: string;
1065
+
1066
+ buyPrice?: number;
1067
+
1068
+ sellPrice?: number;
1069
+ /**
1070
+ * Status filter
1071
+ */
1072
+ status?: 'Normal' | 'Variation' | 'Cancelled' | 'Requested' | 'Pending Review' | 'Declined' | 'Deleted';
1073
+
1074
+ invoicingStatus?: 'Billable' | 'No Charge' | 'Not Billable';
1075
+
1076
+ suppliedBySubcontractor?: boolean;
1077
+ }
1078
+
1079
+ export interface WorkBuddyJobsStagesItemsDeleteStageItemParams extends WorkBuddyRequestParams {
1080
+ /**
1081
+ * Job ID
1082
+ */
1083
+ id: string;
1084
+ /**
1085
+ * Stage ID
1086
+ */
1087
+ stageId: string;
1088
+ /**
1089
+ * Item ID
1090
+ */
1091
+ itemId: string;
1092
+ }
1093
+
1094
+ export interface WorkBuddyItemsListParams extends WorkBuddyRequestParams {
1095
+ /**
1096
+ * External integration ID for the line item
1097
+ */
1098
+ integrationId: string;
1099
+ }
1100
+
982
1101
  export interface WorkBuddyStagesCreateParams extends WorkBuddyRequestParams {
983
1102
  /**
984
1103
  * Job ID or job number (e.g. J12345)
@@ -1091,6 +1210,8 @@ export interface WorkBuddyStagesFinaliseFinaliseParams extends WorkBuddyRequestP
1091
1210
  * Finalisation date (ISO 8601 datetime)
1092
1211
  */
1093
1212
  finalisedDate?: string;
1213
+
1214
+ note?: string;
1094
1215
  }
1095
1216
 
1096
1217
  export interface WorkBuddyStagesCancelCancelParams extends WorkBuddyRequestParams {
@@ -1555,6 +1676,14 @@ export interface WorkBuddySettingsItemCategoriesUpsertParams extends WorkBuddyRe
1555
1676
 
1556
1677
  export interface WorkBuddySettingsUomsListParams extends WorkBuddyRequestParams {}
1557
1678
 
1679
+ export interface WorkBuddySettingsCustomFieldsJobsListJobCustomFieldsParams extends WorkBuddyRequestParams {}
1680
+
1681
+ export interface WorkBuddySettingsCustomFieldsStagesListStageCustomFieldsParams extends WorkBuddyRequestParams {}
1682
+
1683
+ export interface WorkBuddySettingsCustomFieldsAccountsListAccountCustomFieldsParams extends WorkBuddyRequestParams {}
1684
+
1685
+ export interface WorkBuddySettingsCustomFieldsItemsListItemCustomFieldsParams extends WorkBuddyRequestParams {}
1686
+
1558
1687
  export interface WorkBuddyAttachmentsCreateUploadSessionParams extends WorkBuddyRequestParams {
1559
1688
  fileName: string;
1560
1689
 
@@ -2419,6 +2548,10 @@ export interface WorkBuddyJobsContactsDeleteParams extends WorkBuddyRequestParam
2419
2548
  }
2420
2549
 
2421
2550
  export interface WorkBuddyCrmCustomersListParams extends WorkBuddyRequestParams {
2551
+ /**
2552
+ * Filter by external integration identifier
2553
+ */
2554
+ integrationId?: string;
2422
2555
  /**
2423
2556
  * Filter by status (e.g. Active, Inactive). Default: Active only
2424
2557
  */
@@ -2525,6 +2658,8 @@ export interface WorkBuddyCrmCustomersUpdateParams extends WorkBuddyRequestParam
2525
2658
  timezone?: string;
2526
2659
  };
2527
2660
 
2661
+ primarySite?: Record<string, unknown>;
2662
+
2528
2663
  owner?: Record<string, unknown>;
2529
2664
 
2530
2665
  labels?: Record<string, unknown>[];
@@ -2675,6 +2810,8 @@ export interface WorkBuddyCrmContractorsUpdateParams extends WorkBuddyRequestPar
2675
2810
  timezone?: string;
2676
2811
  };
2677
2812
 
2813
+ primarySite?: Record<string, unknown>;
2814
+
2678
2815
  owner?: Record<string, unknown>;
2679
2816
 
2680
2817
  labels?: Record<string, unknown>[];
@@ -2806,6 +2943,8 @@ export interface WorkBuddyCrmSuppliersUpdateParams extends WorkBuddyRequestParam
2806
2943
  timezone?: string;
2807
2944
  };
2808
2945
 
2946
+ primarySite?: Record<string, unknown>;
2947
+
2809
2948
  owner?: Record<string, unknown>;
2810
2949
 
2811
2950
  labels?: Record<string, unknown>[];
@@ -3147,11 +3286,14 @@ export type WorkBuddyJobsSearchResponse = {
3147
3286
  id: string;
3148
3287
  jobId: string;
3149
3288
  stageId: string;
3289
+ integrationId?: string;
3150
3290
  code?: string;
3151
3291
  description: string;
3152
3292
  type?: string;
3153
3293
  quantity: number;
3154
3294
  unit?: string;
3295
+ location?: string;
3296
+ note?: string;
3155
3297
  status?: string;
3156
3298
  buyPrice?: number;
3157
3299
  sellPrice?: number;
@@ -3227,11 +3369,14 @@ export type WorkBuddyJobsGetResponse = {
3227
3369
  id: string;
3228
3370
  jobId: string;
3229
3371
  stageId: string;
3372
+ integrationId?: string;
3230
3373
  code?: string;
3231
3374
  description: string;
3232
3375
  type?: string;
3233
3376
  quantity: number;
3234
3377
  unit?: string;
3378
+ location?: string;
3379
+ note?: string;
3235
3380
  status?: string;
3236
3381
  buyPrice?: number;
3237
3382
  sellPrice?: number;
@@ -3306,11 +3451,95 @@ export type WorkBuddyJobsCreateResponse = {
3306
3451
  id: string;
3307
3452
  jobId: string;
3308
3453
  stageId: string;
3454
+ integrationId?: string;
3309
3455
  code?: string;
3310
3456
  description: string;
3311
3457
  type?: string;
3312
3458
  quantity: number;
3313
3459
  unit?: string;
3460
+ location?: string;
3461
+ note?: string;
3462
+ status?: string;
3463
+ buyPrice?: number;
3464
+ sellPrice?: number;
3465
+ invoicingStatus?: string;
3466
+ suppliedBySubcontractor: boolean;
3467
+ createdAt: string;
3468
+ updatedAt: string;
3469
+ }[];
3470
+ totals?: { sellTotal: number; buyTotal: number };
3471
+ customFields?: string;
3472
+ createdAt: string;
3473
+ updatedAt: string;
3474
+ }[];
3475
+ totals?: { sellTotal: number; buyTotal: number };
3476
+ customFields?: string;
3477
+ dueDate?: string;
3478
+ startDate?: string;
3479
+ createdAt: string;
3480
+ updatedAt: string;
3481
+ };
3482
+ export type WorkBuddyJobsStatusUpdateStatusResponse = {
3483
+ id: string;
3484
+ integrationId?: string;
3485
+ jobNumber: string;
3486
+ name?: string;
3487
+ description: string;
3488
+ status: { id?: string; name?: string; systemStatus: string };
3489
+ customer: { id: string; name: string };
3490
+ site?: string;
3491
+ contact?: string;
3492
+ customerSupervisor?: string;
3493
+ type?: string;
3494
+ priority?: string;
3495
+ owner?: string;
3496
+ fieldSupervisor?: string;
3497
+ zones?: { id: string; name: string }[];
3498
+ tags?: { id: string; name: string; color?: string }[];
3499
+ systemTags?: { id: string; name: string; color?: string }[];
3500
+ notes?: string;
3501
+ reference?: string;
3502
+ customerWO?: string;
3503
+ customerPO?: string;
3504
+ priceBook?: string;
3505
+ billingCompany?: string;
3506
+ policy?: string;
3507
+ thresholds?: string;
3508
+ stages?: {
3509
+ id: string;
3510
+ stageNumber: string;
3511
+ jobId: string;
3512
+ job?: { id: string; jobNumber: string; description?: string };
3513
+ name?: string;
3514
+ description?: string;
3515
+ status: { id?: string; name?: string; systemStatus: string };
3516
+ sequence?: number;
3517
+ owner?: string;
3518
+ contractor?: string;
3519
+ technician?: string;
3520
+ resources?: string;
3521
+ startDate?: string;
3522
+ dueDate?: string;
3523
+ completedDate?: string;
3524
+ completedBy?: string;
3525
+ completedNote?: string;
3526
+ finalisedDate?: string;
3527
+ notes?: string;
3528
+ tags?: string;
3529
+ systemTags?: string;
3530
+ schedulingTags?: string;
3531
+ items?: {
3532
+ id: string;
3533
+ jobId: string;
3534
+ stageId: string;
3535
+ integrationId?: string;
3536
+ code?: string;
3537
+ description: string;
3538
+ type?: string;
3539
+ quantity: number;
3540
+ unit?: string;
3541
+ location?: string;
3542
+ note?: string;
3314
3543
  status?: string;
3315
3544
  buyPrice?: number;
3316
3545
  sellPrice?: number;
@@ -3384,11 +3613,14 @@ export type WorkBuddyJobsUpdateResponse = {
3384
3613
  id: string;
3385
3614
  jobId: string;
3386
3615
  stageId: string;
3616
+ integrationId?: string;
3387
3617
  code?: string;
3388
3618
  description: string;
3389
3619
  type?: string;
3390
3620
  quantity: number;
3391
3621
  unit?: string;
3622
+ location?: string;
3623
+ note?: string;
3392
3624
  status?: string;
3393
3625
  buyPrice?: number;
3394
3626
  sellPrice?: number;
@@ -3462,11 +3694,14 @@ export type WorkBuddyJobsDispatchResponse = {
3462
3694
  id: string;
3463
3695
  jobId: string;
3464
3696
  stageId: string;
3697
+ integrationId?: string;
3465
3698
  code?: string;
3466
3699
  description: string;
3467
3700
  type?: string;
3468
3701
  quantity: number;
3469
3702
  unit?: string;
3703
+ location?: string;
3704
+ note?: string;
3470
3705
  status?: string;
3471
3706
  buyPrice?: number;
3472
3707
  sellPrice?: number;
@@ -3532,11 +3767,14 @@ export type WorkBuddyJobsStagesGetJobStageResponse = {
3532
3767
  id: string;
3533
3768
  jobId: string;
3534
3769
  stageId: string;
3770
+ integrationId?: string;
3535
3771
  code?: string;
3536
3772
  description: string;
3537
3773
  type?: string;
3538
3774
  quantity: number;
3539
3775
  unit?: string;
3776
+ location?: string;
3777
+ note?: string;
3540
3778
  status?: string;
3541
3779
  buyPrice?: number;
3542
3780
  sellPrice?: number;
@@ -3555,11 +3793,14 @@ export type WorkBuddyJobsStagesItemsListResponse = {
3555
3793
  id: string;
3556
3794
  jobId: string;
3557
3795
  stageId: string;
3796
+ integrationId?: string;
3558
3797
  code?: string;
3559
3798
  description: string;
3560
3799
  type?: string;
3561
3800
  quantity: number;
3562
3801
  unit?: string;
3802
+ location?: string;
3803
+ note?: string;
3563
3804
  status?: string;
3564
3805
  buyPrice?: number;
3565
3806
  sellPrice?: number;
@@ -3570,15 +3811,40 @@ export type WorkBuddyJobsStagesItemsListResponse = {
3570
3811
  }[];
3571
3812
  pagination: { limit: number; hasMore: boolean; nextCursor: string };
3572
3813
  };
3814
+ export type WorkBuddyJobsStagesItemsCreateStageItemsResponse = {
3815
+ items: {
3816
+ id: string;
3817
+ jobId: string;
3818
+ stageId: string;
3819
+ integrationId?: string;
3820
+ code?: string;
3821
+ description: string;
3822
+ type?: string;
3823
+ quantity: number;
3824
+ unit?: string;
3825
+ location?: string;
3826
+ note?: string;
3827
+ status?: string;
3828
+ buyPrice?: number;
3829
+ sellPrice?: number;
3830
+ invoicingStatus?: string;
3831
+ suppliedBySubcontractor: boolean;
3832
+ createdAt: string;
3833
+ updatedAt: string;
3834
+ }[];
3835
+ };
3573
3836
  export type WorkBuddyJobsStagesItemsGetStageItemResponse = {
3574
3837
  id: string;
3575
3838
  jobId: string;
3576
3839
  stageId: string;
3840
+ integrationId?: string;
3577
3841
  code?: string;
3578
3842
  description: string;
3579
3843
  type?: string;
3580
3844
  quantity: number;
3581
3845
  unit?: string;
3846
+ location?: string;
3847
+ note?: string;
3582
3848
  status?: string;
3583
3849
  buyPrice?: number;
3584
3850
  sellPrice?: number;
@@ -3587,6 +3853,50 @@ export type WorkBuddyJobsStagesItemsGetStageItemResponse = {
3587
3853
  createdAt: string;
3588
3854
  updatedAt: string;
3589
3855
  };
3856
+ export type WorkBuddyJobsStagesItemsUpdateStageItemResponse = {
3857
+ id: string;
3858
+ jobId: string;
3859
+ stageId: string;
3860
+ integrationId?: string;
3861
+ code?: string;
3862
+ description: string;
3863
+ type?: string;
3864
+ quantity: number;
3865
+ unit?: string;
3866
+ location?: string;
3867
+ note?: string;
3868
+ status?: string;
3869
+ buyPrice?: number;
3870
+ sellPrice?: number;
3871
+ invoicingStatus?: string;
3872
+ suppliedBySubcontractor: boolean;
3873
+ createdAt: string;
3874
+ updatedAt: string;
3875
+ };
3876
+ export type WorkBuddyJobsStagesItemsDeleteStageItemResponse = { deleted?: boolean };
3877
+ export type WorkBuddyItemsListResponse = {
3878
+ items: {
3879
+ id: string;
3880
+ jobId: string;
3881
+ stageId: string;
3882
+ integrationId?: string;
3883
+ code?: string;
3884
+ description: string;
3885
+ type?: string;
3886
+ quantity: number;
3887
+ unit?: string;
3888
+ location?: string;
3889
+ note?: string;
3890
+ status?: string;
3891
+ buyPrice?: number;
3892
+ sellPrice?: number;
3893
+ invoicingStatus?: string;
3894
+ suppliedBySubcontractor: boolean;
3895
+ createdAt: string;
3896
+ updatedAt: string;
3897
+ }[];
3898
+ pagination: { limit: number; hasMore: boolean; nextCursor: string };
3899
+ };
3590
3900
  export type WorkBuddyStagesCreateResponse = {
3591
3901
  id: string;
3592
3902
  stageNumber: string;
@@ -3614,11 +3924,14 @@ export type WorkBuddyStagesCreateResponse = {
3614
3924
  id: string;
3615
3925
  jobId: string;
3616
3926
  stageId: string;
3927
+ integrationId?: string;
3617
3928
  code?: string;
3618
3929
  description: string;
3619
3930
  type?: string;
3620
3931
  quantity: number;
3621
3932
  unit?: string;
3933
+ location?: string;
3934
+ note?: string;
3622
3935
  status?: string;
3623
3936
  buyPrice?: number;
3624
3937
  sellPrice?: number;
@@ -3659,11 +3972,14 @@ export type WorkBuddyStagesUpdateResponse = {
3659
3972
  id: string;
3660
3973
  jobId: string;
3661
3974
  stageId: string;
3975
+ integrationId?: string;
3662
3976
  code?: string;
3663
3977
  description: string;
3664
3978
  type?: string;
3665
3979
  quantity: number;
3666
3980
  unit?: string;
3981
+ location?: string;
3982
+ note?: string;
3667
3983
  status?: string;
3668
3984
  buyPrice?: number;
3669
3985
  sellPrice?: number;
@@ -3705,11 +4021,14 @@ export type WorkBuddyStagesDispatchResponse = {
3705
4021
  id: string;
3706
4022
  jobId: string;
3707
4023
  stageId: string;
4024
+ integrationId?: string;
3708
4025
  code?: string;
3709
4026
  description: string;
3710
4027
  type?: string;
3711
4028
  quantity: number;
3712
4029
  unit?: string;
4030
+ location?: string;
4031
+ note?: string;
3713
4032
  status?: string;
3714
4033
  buyPrice?: number;
3715
4034
  sellPrice?: number;
@@ -3750,11 +4069,14 @@ export type WorkBuddyStagesCompleteCompleteResponse = {
3750
4069
  id: string;
3751
4070
  jobId: string;
3752
4071
  stageId: string;
4072
+ integrationId?: string;
3753
4073
  code?: string;
3754
4074
  description: string;
3755
4075
  type?: string;
3756
4076
  quantity: number;
3757
4077
  unit?: string;
4078
+ location?: string;
4079
+ note?: string;
3758
4080
  status?: string;
3759
4081
  buyPrice?: number;
3760
4082
  sellPrice?: number;
@@ -3795,11 +4117,14 @@ export type WorkBuddyStagesFinaliseFinaliseResponse = {
3795
4117
  id: string;
3796
4118
  jobId: string;
3797
4119
  stageId: string;
4120
+ integrationId?: string;
3798
4121
  code?: string;
3799
4122
  description: string;
3800
4123
  type?: string;
3801
4124
  quantity: number;
3802
4125
  unit?: string;
4126
+ location?: string;
4127
+ note?: string;
3803
4128
  status?: string;
3804
4129
  buyPrice?: number;
3805
4130
  sellPrice?: number;
@@ -3840,11 +4165,14 @@ export type WorkBuddyStagesCancelCancelResponse = {
3840
4165
  id: string;
3841
4166
  jobId: string;
3842
4167
  stageId: string;
4168
+ integrationId?: string;
3843
4169
  code?: string;
3844
4170
  description: string;
3845
4171
  type?: string;
3846
4172
  quantity: number;
3847
4173
  unit?: string;
4174
+ location?: string;
4175
+ note?: string;
3848
4176
  status?: string;
3849
4177
  buyPrice?: number;
3850
4178
  sellPrice?: number;
@@ -3885,11 +4213,14 @@ export type WorkBuddyStagesReverseReverseResponse = {
3885
4213
  id: string;
3886
4214
  jobId: string;
3887
4215
  stageId: string;
4216
+ integrationId?: string;
3888
4217
  code?: string;
3889
4218
  description: string;
3890
4219
  type?: string;
3891
4220
  quantity: number;
3892
4221
  unit?: string;
4222
+ location?: string;
4223
+ note?: string;
3893
4224
  status?: string;
3894
4225
  buyPrice?: number;
3895
4226
  sellPrice?: number;
@@ -4170,6 +4501,58 @@ export type WorkBuddySettingsItemCategoriesUpsertResponse = {
4170
4501
  export type WorkBuddySettingsUomsListResponse = {
4171
4502
  items: { id: string; name: string; abbreviation?: string; type?: string; wholeNumber?: boolean; active?: boolean }[];
4172
4503
  };
4504
+ export type WorkBuddySettingsCustomFieldsJobsListJobCustomFieldsResponse = {
4505
+ items: {
4506
+ key: string;
4507
+ name: string;
4508
+ parent: string;
4509
+ type?: string;
4510
+ required?: boolean;
4511
+ readonly?: boolean;
4512
+ defaultValue?: string;
4513
+ options?: string;
4514
+ sortOrder?: number;
4515
+ }[];
4516
+ };
4517
+ export type WorkBuddySettingsCustomFieldsStagesListStageCustomFieldsResponse = {
4518
+ items: {
4519
+ key: string;
4520
+ name: string;
4521
+ parent: string;
4522
+ type?: string;
4523
+ required?: boolean;
4524
+ readonly?: boolean;
4525
+ defaultValue?: string;
4526
+ options?: string;
4527
+ sortOrder?: number;
4528
+ }[];
4529
+ };
4530
+ export type WorkBuddySettingsCustomFieldsAccountsListAccountCustomFieldsResponse = {
4531
+ items: {
4532
+ key: string;
4533
+ name: string;
4534
+ parent: string;
4535
+ type?: string;
4536
+ required?: boolean;
4537
+ readonly?: boolean;
4538
+ defaultValue?: string;
4539
+ options?: string;
4540
+ sortOrder?: number;
4541
+ }[];
4542
+ };
4543
+ export type WorkBuddySettingsCustomFieldsItemsListItemCustomFieldsResponse = {
4544
+ items: {
4545
+ key: string;
4546
+ name: string;
4547
+ parent: string;
4548
+ type?: string;
4549
+ required?: boolean;
4550
+ readonly?: boolean;
4551
+ defaultValue?: string;
4552
+ options?: string;
4553
+ sortOrder?: number;
4554
+ }[];
4555
+ };
4173
4556
  export type WorkBuddyAttachmentsCreateUploadSessionResponse = {
4174
4557
  uploadUrl: string;
4175
4558
  headers: { 'x-ms-blob-type': string; 'Content-Type': string };
@@ -4227,7 +4610,16 @@ export type WorkBuddyJobsContactsCreateResponse = unknown;
4227
4610
  export type WorkBuddyJobsContactsGetResponse = unknown;
4228
4611
  export type WorkBuddyJobsContactsDeleteResponse = unknown;
4229
4612
  export type WorkBuddyCrmCustomersListResponse = {
4230
- items: { id: string; name: string; type: string }[];
4613
+ items: {
4614
+ id: string;
4615
+ name: string;
4616
+ type: string;
4617
+ integrationId?: string;
4618
+ address?: string;
4619
+ phone?: string;
4620
+ mobile?: string;
4621
+ email?: string;
4622
+ }[];
4231
4623
  pagination: { limit: number; hasMore: boolean; nextCursor: string };
4232
4624
  };
4233
4625
  export type WorkBuddyCrmCustomersCreateResponse = {
@@ -4237,6 +4629,7 @@ export type WorkBuddyCrmCustomersCreateResponse = {
4237
4629
  type: string;
4238
4630
  legalName: string;
4239
4631
  phone: string;
4632
+ mobile: string;
4240
4633
  email: string;
4241
4634
  website: string;
4242
4635
  integrationId: string;
@@ -4260,6 +4653,7 @@ export type WorkBuddyCrmCustomersGetResponse = {
4260
4653
  type: string;
4261
4654
  legalName: string;
4262
4655
  phone: string;
4656
+ mobile: string;
4263
4657
  email: string;
4264
4658
  website: string;
4265
4659
  integrationId: string;
@@ -4283,6 +4677,7 @@ export type WorkBuddyCrmCustomersUpdateResponse = {
4283
4677
  type: string;
4284
4678
  legalName: string;
4285
4679
  phone: string;
4680
+ mobile: string;
4286
4681
  email: string;
4287
4682
  website: string;
4288
4683
  integrationId: string;
@@ -4300,7 +4695,16 @@ export type WorkBuddyCrmCustomersUpdateResponse = {
4300
4695
  };
4301
4696
  };
4302
4697
  export type WorkBuddyCrmCustomersContactsListResponse = {
4303
- items: { id: string; name: string; type: string }[];
4698
+ items: {
4699
+ id: string;
4700
+ name: string;
4701
+ type: string;
4702
+ integrationId?: string;
4703
+ address?: string;
4704
+ phone?: string;
4705
+ mobile?: string;
4706
+ email?: string;
4707
+ }[];
4304
4708
  pagination: { limit: number; hasMore: boolean; nextCursor: string };
4305
4709
  };
4306
4710
  export type WorkBuddyCrmCustomersSitesListResponse = {
@@ -4308,12 +4712,41 @@ export type WorkBuddyCrmCustomersSitesListResponse = {
4308
4712
  pagination: { limit: number; hasMore: boolean; nextCursor: string };
4309
4713
  };
4310
4714
  export type WorkBuddyCrmEmployeesListResponse = {
4311
- items: { id: string; name: string; type: string }[];
4715
+ items: {
4716
+ id: string;
4717
+ name: string;
4718
+ type: string;
4719
+ integrationId?: string;
4720
+ address?: string;
4721
+ phone?: string;
4722
+ mobile?: string;
4723
+ email?: string;
4724
+ }[];
4312
4725
  pagination: { limit: number; hasMore: boolean; nextCursor: string };
4313
4726
  };
4314
- export type WorkBuddyCrmEmployeesGetResponse = { item: { id: string; name: string; type: string } };
4727
+ export type WorkBuddyCrmEmployeesGetResponse = {
4728
+ item: {
4729
+ id: string;
4730
+ name: string;
4731
+ type: string;
4732
+ integrationId?: string;
4733
+ address?: string;
4734
+ phone?: string;
4735
+ mobile?: string;
4736
+ email?: string;
4737
+ };
4738
+ };
4315
4739
  export type WorkBuddyCrmContractorsListResponse = {
4316
- items: { id: string; name: string; type: string }[];
4740
+ items: {
4741
+ id: string;
4742
+ name: string;
4743
+ type: string;
4744
+ integrationId?: string;
4745
+ address?: string;
4746
+ phone?: string;
4747
+ mobile?: string;
4748
+ email?: string;
4749
+ }[];
4317
4750
  pagination: { limit: number; hasMore: boolean; nextCursor: string };
4318
4751
  };
4319
4752
  export type WorkBuddyCrmContractorsCreateResponse = {
@@ -4323,6 +4756,7 @@ export type WorkBuddyCrmContractorsCreateResponse = {
4323
4756
  type: string;
4324
4757
  legalName: string;
4325
4758
  phone: string;
4759
+ mobile: string;
4326
4760
  email: string;
4327
4761
  website: string;
4328
4762
  integrationId: string;
@@ -4353,6 +4787,7 @@ export type WorkBuddyCrmContractorsGetResponse = {
4353
4787
  type: string;
4354
4788
  legalName: string;
4355
4789
  phone: string;
4790
+ mobile: string;
4356
4791
  email: string;
4357
4792
  website: string;
4358
4793
  integrationId: string;
@@ -4383,6 +4818,7 @@ export type WorkBuddyCrmContractorsUpdateResponse = {
4383
4818
  type: string;
4384
4819
  legalName: string;
4385
4820
  phone: string;
4821
+ mobile: string;
4386
4822
  email: string;
4387
4823
  website: string;
4388
4824
  integrationId: string;
@@ -4407,7 +4843,16 @@ export type WorkBuddyCrmContractorsUpdateResponse = {
4407
4843
  };
4408
4844
  };
4409
4845
  export type WorkBuddyCrmSuppliersListResponse = {
4410
- items: { id: string; name: string; type: string }[];
4846
+ items: {
4847
+ id: string;
4848
+ name: string;
4849
+ type: string;
4850
+ integrationId?: string;
4851
+ address?: string;
4852
+ phone?: string;
4853
+ mobile?: string;
4854
+ email?: string;
4855
+ }[];
4411
4856
  pagination: { limit: number; hasMore: boolean; nextCursor: string };
4412
4857
  };
4413
4858
  export type WorkBuddyCrmSuppliersCreateResponse = {
@@ -4417,6 +4862,7 @@ export type WorkBuddyCrmSuppliersCreateResponse = {
4417
4862
  type: string;
4418
4863
  legalName: string;
4419
4864
  phone: string;
4865
+ mobile: string;
4420
4866
  email: string;
4421
4867
  website: string;
4422
4868
  integrationId: string;
@@ -4448,6 +4894,7 @@ export type WorkBuddyCrmSuppliersGetResponse = {
4448
4894
  type: string;
4449
4895
  legalName: string;
4450
4896
  phone: string;
4897
+ mobile: string;
4451
4898
  email: string;
4452
4899
  website: string;
4453
4900
  integrationId: string;
@@ -4479,6 +4926,7 @@ export type WorkBuddyCrmSuppliersUpdateResponse = {
4479
4926
  type: string;
4480
4927
  legalName: string;
4481
4928
  phone: string;
4929
+ mobile: string;
4482
4930
  email: string;
4483
4931
  website: string;
4484
4932
  integrationId: string;
@@ -4504,25 +4952,105 @@ export type WorkBuddyCrmSuppliersUpdateResponse = {
4504
4952
  };
4505
4953
  };
4506
4954
  export type WorkBuddyCrmCompaniesListResponse = {
4507
- items: { id: string; name: string; type: string }[];
4955
+ items: {
4956
+ id: string;
4957
+ name: string;
4958
+ type: string;
4959
+ integrationId?: string;
4960
+ address?: string;
4961
+ phone?: string;
4962
+ mobile?: string;
4963
+ email?: string;
4964
+ }[];
4508
4965
  pagination: { limit: number; hasMore: boolean; nextCursor: string };
4509
4966
  };
4510
- export type WorkBuddyCrmCompaniesGetResponse = { item: { id: string; name: string; type: string } };
4967
+ export type WorkBuddyCrmCompaniesGetResponse = {
4968
+ item: {
4969
+ id: string;
4970
+ name: string;
4971
+ type: string;
4972
+ integrationId?: string;
4973
+ address?: string;
4974
+ phone?: string;
4975
+ mobile?: string;
4976
+ email?: string;
4977
+ };
4978
+ };
4511
4979
  export type WorkBuddyCrmExternalUsersListResponse = {
4512
- items: { id: string; name: string; type: string }[];
4980
+ items: {
4981
+ id: string;
4982
+ name: string;
4983
+ type: string;
4984
+ integrationId?: string;
4985
+ address?: string;
4986
+ phone?: string;
4987
+ mobile?: string;
4988
+ email?: string;
4989
+ }[];
4513
4990
  pagination: { limit: number; hasMore: boolean; nextCursor: string };
4514
4991
  };
4515
- export type WorkBuddyCrmExternalUsersGetResponse = { item: { id: string; name: string; type: string } };
4992
+ export type WorkBuddyCrmExternalUsersGetResponse = {
4993
+ item: {
4994
+ id: string;
4995
+ name: string;
4996
+ type: string;
4997
+ integrationId?: string;
4998
+ address?: string;
4999
+ phone?: string;
5000
+ mobile?: string;
5001
+ email?: string;
5002
+ };
5003
+ };
4516
5004
  export type WorkBuddyCrmContactsListResponse = {
4517
- items: { id: string; name: string; type: string }[];
5005
+ items: {
5006
+ id: string;
5007
+ name: string;
5008
+ type: string;
5009
+ integrationId?: string;
5010
+ address?: string;
5011
+ phone?: string;
5012
+ mobile?: string;
5013
+ email?: string;
5014
+ }[];
4518
5015
  pagination: { limit: number; hasMore: boolean; nextCursor: string };
4519
5016
  };
4520
- export type WorkBuddyCrmContactsGetResponse = { item: { id: string; name: string; type: string } };
5017
+ export type WorkBuddyCrmContactsGetResponse = {
5018
+ item: {
5019
+ id: string;
5020
+ name: string;
5021
+ type: string;
5022
+ integrationId?: string;
5023
+ address?: string;
5024
+ phone?: string;
5025
+ mobile?: string;
5026
+ email?: string;
5027
+ };
5028
+ };
4521
5029
  export type WorkBuddyCrmInvitesListResponse = {
4522
- items: { id: string; name: string; type: string }[];
5030
+ items: {
5031
+ id: string;
5032
+ name: string;
5033
+ type: string;
5034
+ integrationId?: string;
5035
+ address?: string;
5036
+ phone?: string;
5037
+ mobile?: string;
5038
+ email?: string;
5039
+ }[];
4523
5040
  pagination: { limit: number; hasMore: boolean; nextCursor: string };
4524
5041
  };
4525
- export type WorkBuddyCrmInvitesGetResponse = { item: { id: string; name: string; type: string } };
5042
+ export type WorkBuddyCrmInvitesGetResponse = {
5043
+ item: {
5044
+ id: string;
5045
+ name: string;
5046
+ type: string;
5047
+ integrationId?: string;
5048
+ address?: string;
5049
+ phone?: string;
5050
+ mobile?: string;
5051
+ email?: string;
5052
+ };
5053
+ };
4526
5054
  export type WorkBuddyCrmSitesListResponse = {
4527
5055
  items: { id: string; name: string; address: string }[];
4528
5056
  pagination: { limit: number; hasMore: boolean; nextCursor: string };
@@ -4598,6 +5126,8 @@ export type WorkBuddyMcpCreateResponse = unknown;
4598
5126
  export type WorkBuddyMcpDeleteResponse = unknown;
4599
5127
 
4600
5128
  export interface WorkBuddyJobsResource {
5129
+ /** Status API operations. */
5130
+ status: WorkBuddyJobsStatusResource;
4601
5131
  /** Stages API operations. */
4602
5132
  stages: WorkBuddyJobsStagesResource;
4603
5133
  /** Activities API operations. */
@@ -4672,6 +5202,17 @@ export interface WorkBuddyJobsResource {
4672
5202
  ): Promise<TResponse>;
4673
5203
  }
4674
5204
 
5205
+ export interface WorkBuddyJobsStatusResource {
5206
+ /**
5207
+ * Change an existing job status and cascade the change to stages through the job domain command.
5208
+ * Operation: PublicApiJobController_updateStatus
5209
+ */
5210
+ updateStatus<TResponse = WorkBuddyJobsStatusUpdateStatusResponse>(
5211
+ params: WorkBuddyJobsStatusUpdateStatusParams,
5212
+ options?: WorkBuddyRequestOptions
5213
+ ): Promise<TResponse>;
5214
+ }
5215
+
4675
5216
  export interface WorkBuddyJobsStagesResource {
4676
5217
  /** Items API operations. */
4677
5218
  items: WorkBuddyJobsStagesItemsResource;
@@ -4730,6 +5271,15 @@ export interface WorkBuddyJobsStagesItemsResource {
4730
5271
  params: WorkBuddyJobsStagesItemsListParams,
4731
5272
  options?: WorkBuddyRequestOptions
4732
5273
  ): AsyncIterable<TPage>;
5274
+ /**
5275
+ * Add one or more catalogue-backed line items to a stage.
5276
+ * Operation: PublicApiJobController_createStageItems
5277
+ */
5278
+ createStageItems<TResponse = WorkBuddyJobsStagesItemsCreateStageItemsResponse>(
5279
+ params: WorkBuddyJobsStagesItemsCreateStageItemsParams,
5280
+ options?: WorkBuddyRequestOptions
5281
+ ): Promise<TResponse>;
5282
+
4733
5283
  /**
4734
5284
  * Get a specific item within a stage.
4735
5285
  * Operation: PublicApiJobController_getStageItem
@@ -4738,6 +5288,24 @@ export interface WorkBuddyJobsStagesItemsResource {
4738
5288
  params: WorkBuddyJobsStagesItemsGetStageItemParams,
4739
5289
  options?: WorkBuddyRequestOptions
4740
5290
  ): Promise<TResponse>;
5291
+
5292
+ /**
5293
+ * Update mutable fields on a stage line item.
5294
+ * Operation: PublicApiJobController_updateStageItem
5295
+ */
5296
+ updateStageItem<TResponse = WorkBuddyJobsStagesItemsUpdateStageItemResponse>(
5297
+ params: WorkBuddyJobsStagesItemsUpdateStageItemParams,
5298
+ options?: WorkBuddyRequestOptions
5299
+ ): Promise<TResponse>;
5300
+
5301
+ /**
5302
+ * Remove or cancel a stage item depending on tenant deletion settings.
5303
+ * Operation: PublicApiJobController_deleteStageItem
5304
+ */
5305
+ deleteStageItem<TResponse = WorkBuddyJobsStagesItemsDeleteStageItemResponse>(
5306
+ params: WorkBuddyJobsStagesItemsDeleteStageItemParams,
5307
+ options?: WorkBuddyRequestOptions
5308
+ ): Promise<TResponse>;
4741
5309
  }
4742
5310
 
4743
5311
  export interface WorkBuddyJobsStagesResourcesResource {
@@ -5261,6 +5829,17 @@ export interface WorkBuddyJobsContactsResource {
5261
5829
  ): Promise<TResponse>;
5262
5830
  }
5263
5831
 
5832
+ export interface WorkBuddyItemsResource {
5833
+ /**
5834
+ * Find a job line item by external integration ID.
5835
+ * Operation: PublicApiJobLineItemController_list
5836
+ */
5837
+ list<TResponse = WorkBuddyItemsListResponse>(
5838
+ params: WorkBuddyItemsListParams,
5839
+ options?: WorkBuddyRequestOptions
5840
+ ): Promise<TResponse>;
5841
+ }
5842
+
5264
5843
  export interface WorkBuddyStagesResource {
5265
5844
  /** Complete API operations. */
5266
5845
  complete: WorkBuddyStagesCompleteResource;
@@ -5389,6 +5968,8 @@ export interface WorkBuddySettingsResource {
5389
5968
  itemCategories: WorkBuddySettingsItemCategoriesResource;
5390
5969
  /** Uoms API operations. */
5391
5970
  uoms: WorkBuddySettingsUomsResource;
5971
+ /** Custom Fields API operations. */
5972
+ customFields: WorkBuddySettingsCustomFieldsResource;
5392
5973
  }
5393
5974
 
5394
5975
  export interface WorkBuddySettingsEntityStatusesResource {
@@ -5595,6 +6176,61 @@ export interface WorkBuddySettingsUomsResource {
5595
6176
  ): Promise<TResponse>;
5596
6177
  }
5597
6178
 
6179
+ export interface WorkBuddySettingsCustomFieldsResource {
6180
+ /** Jobs API operations. */
6181
+ jobs: WorkBuddySettingsCustomFieldsJobsResource;
6182
+ /** Stages API operations. */
6183
+ stages: WorkBuddySettingsCustomFieldsStagesResource;
6184
+ /** Accounts API operations. */
6185
+ accounts: WorkBuddySettingsCustomFieldsAccountsResource;
6186
+ /** Items API operations. */
6187
+ items: WorkBuddySettingsCustomFieldsItemsResource;
6188
+ }
6189
+
6190
+ export interface WorkBuddySettingsCustomFieldsJobsResource {
6191
+ /**
6192
+ * Retrieve configured custom fields that may be used in Job customFields payloads.
6193
+ * Operation: PublicApiCustomFieldController_listJobCustomFields
6194
+ */
6195
+ listJobCustomFields<TResponse = WorkBuddySettingsCustomFieldsJobsListJobCustomFieldsResponse>(
6196
+ params?: WorkBuddySettingsCustomFieldsJobsListJobCustomFieldsParams,
6197
+ options?: WorkBuddyRequestOptions
6198
+ ): Promise<TResponse>;
6199
+ }
6200
+
6201
+ export interface WorkBuddySettingsCustomFieldsStagesResource {
6202
+ /**
6203
+ * Retrieve configured custom fields that may be used in Stage customFields payloads.
6204
+ * Operation: PublicApiCustomFieldController_listStageCustomFields
6205
+ */
6206
+ listStageCustomFields<TResponse = WorkBuddySettingsCustomFieldsStagesListStageCustomFieldsResponse>(
6207
+ params?: WorkBuddySettingsCustomFieldsStagesListStageCustomFieldsParams,
6208
+ options?: WorkBuddyRequestOptions
6209
+ ): Promise<TResponse>;
6210
+ }
6211
+
6212
+ export interface WorkBuddySettingsCustomFieldsAccountsResource {
6213
+ /**
6214
+ * Retrieve configured custom fields that may be used in CRM account customFields payloads.
6215
+ * Operation: PublicApiCustomFieldController_listAccountCustomFields
6216
+ */
6217
+ listAccountCustomFields<TResponse = WorkBuddySettingsCustomFieldsAccountsListAccountCustomFieldsResponse>(
6218
+ params?: WorkBuddySettingsCustomFieldsAccountsListAccountCustomFieldsParams,
6219
+ options?: WorkBuddyRequestOptions
6220
+ ): Promise<TResponse>;
6221
+ }
6222
+
6223
+ export interface WorkBuddySettingsCustomFieldsItemsResource {
6224
+ /**
6225
+ * Retrieve configured custom fields that may be used in settings item customFields payloads.
6226
+ * Operation: PublicApiCustomFieldController_listItemCustomFields
6227
+ */
6228
+ listItemCustomFields<TResponse = WorkBuddySettingsCustomFieldsItemsListItemCustomFieldsResponse>(
6229
+ params?: WorkBuddySettingsCustomFieldsItemsListItemCustomFieldsParams,
6230
+ options?: WorkBuddyRequestOptions
6231
+ ): Promise<TResponse>;
6232
+ }
6233
+
5598
6234
  export interface WorkBuddyAttachmentsResource {
5599
6235
  /**
5600
6236
  * Creates an upload session and returns a SAS URL for direct upload to Azure Blob Storage.
package/index.js CHANGED
@@ -34,6 +34,14 @@ export class WorkBuddyClient {
34
34
  }
35
35
 
36
36
  this.jobs = {
37
+ status: {
38
+ /**
39
+ * Change an existing job status and cascade the change to stages through the job domain command.
40
+ * Operation: PublicApiJobController_updateStatus
41
+ */
42
+ updateStatus: (params = {}, options = {}) =>
43
+ this.request('PublicApiJobController_updateStatus', params, options),
44
+ },
37
45
  stages: {
38
46
  items: {
39
47
  /**
@@ -46,12 +54,30 @@ export class WorkBuddyClient {
46
54
  /** Iterate raw pages by following cursor pagination for list(). */
47
55
  pages: (params = {}, options = {}) =>
48
56
  this.paginatePages('PublicApiJobController_getStageItems', params, options),
57
+ /**
58
+ * Add one or more catalogue-backed line items to a stage.
59
+ * Operation: PublicApiJobController_createStageItems
60
+ */
61
+ createStageItems: (params = {}, options = {}) =>
62
+ this.request('PublicApiJobController_createStageItems', params, options),
49
63
  /**
50
64
  * Get a specific item within a stage.
51
65
  * Operation: PublicApiJobController_getStageItem
52
66
  */
53
67
  getStageItem: (params = {}, options = {}) =>
54
68
  this.request('PublicApiJobController_getStageItem', params, options),
69
+ /**
70
+ * Update mutable fields on a stage line item.
71
+ * Operation: PublicApiJobController_updateStageItem
72
+ */
73
+ updateStageItem: (params = {}, options = {}) =>
74
+ this.request('PublicApiJobController_updateStageItem', params, options),
75
+ /**
76
+ * Remove or cancel a stage item depending on tenant deletion settings.
77
+ * Operation: PublicApiJobController_deleteStageItem
78
+ */
79
+ deleteStageItem: (params = {}, options = {}) =>
80
+ this.request('PublicApiJobController_deleteStageItem', params, options),
55
81
  },
56
82
  resources: {
57
83
  reissue: {
@@ -417,6 +443,14 @@ export class WorkBuddyClient {
417
443
  dispatch: (params = {}, options = {}) => this.request('PublicApiJobController_dispatch', params, options),
418
444
  };
419
445
 
446
+ this.items = {
447
+ /**
448
+ * Find a job line item by external integration ID.
449
+ * Operation: PublicApiJobLineItemController_list
450
+ */
451
+ list: (params = {}, options = {}) => this.request('PublicApiJobLineItemController_list', params, options),
452
+ };
453
+
420
454
  this.stages = {
421
455
  complete: {
422
456
  /**
@@ -601,6 +635,40 @@ export class WorkBuddyClient {
601
635
  */
602
636
  list: (params = {}, options = {}) => this.request('PublicApiUoMController_list', params, options),
603
637
  },
638
+ customFields: {
639
+ jobs: {
640
+ /**
641
+ * Retrieve configured custom fields that may be used in Job customFields payloads.
642
+ * Operation: PublicApiCustomFieldController_listJobCustomFields
643
+ */
644
+ listJobCustomFields: (params = {}, options = {}) =>
645
+ this.request('PublicApiCustomFieldController_listJobCustomFields', params, options),
646
+ },
647
+ stages: {
648
+ /**
649
+ * Retrieve configured custom fields that may be used in Stage customFields payloads.
650
+ * Operation: PublicApiCustomFieldController_listStageCustomFields
651
+ */
652
+ listStageCustomFields: (params = {}, options = {}) =>
653
+ this.request('PublicApiCustomFieldController_listStageCustomFields', params, options),
654
+ },
655
+ accounts: {
656
+ /**
657
+ * Retrieve configured custom fields that may be used in CRM account customFields payloads.
658
+ * Operation: PublicApiCustomFieldController_listAccountCustomFields
659
+ */
660
+ listAccountCustomFields: (params = {}, options = {}) =>
661
+ this.request('PublicApiCustomFieldController_listAccountCustomFields', params, options),
662
+ },
663
+ items: {
664
+ /**
665
+ * Retrieve configured custom fields that may be used in settings item customFields payloads.
666
+ * Operation: PublicApiCustomFieldController_listItemCustomFields
667
+ */
668
+ listItemCustomFields: (params = {}, options = {}) =>
669
+ this.request('PublicApiCustomFieldController_listItemCustomFields', params, options),
670
+ },
671
+ },
604
672
  };
605
673
 
606
674
  this.attachments = {
@@ -1236,6 +1304,18 @@ export const operations = [
1236
1304
  queryParams: [],
1237
1305
  hasRequestBody: true,
1238
1306
  },
1307
+ {
1308
+ operationId: 'PublicApiJobController_updateStatus',
1309
+ resourcePath: ['jobs', 'status'],
1310
+ actionName: 'updateStatus',
1311
+ displayName: 'Update job status',
1312
+ description: 'Change an existing job status and cascade the change to stages through the job domain command.',
1313
+ method: 'PATCH',
1314
+ path: '/jobs/{id}/status',
1315
+ pathParams: ['id'],
1316
+ queryParams: [],
1317
+ hasRequestBody: true,
1318
+ },
1239
1319
  {
1240
1320
  operationId: 'PublicApiJobController_update',
1241
1321
  resourcePath: ['jobs'],
@@ -1300,6 +1380,18 @@ export const operations = [
1300
1380
  queryParams: ['cursor', 'limit'],
1301
1381
  hasRequestBody: false,
1302
1382
  },
1383
+ {
1384
+ operationId: 'PublicApiJobController_createStageItems',
1385
+ resourcePath: ['jobs', 'stages', 'items'],
1386
+ actionName: 'createStageItems',
1387
+ displayName: 'Create stage items',
1388
+ description: 'Add one or more catalogue-backed line items to a stage.',
1389
+ method: 'POST',
1390
+ path: '/jobs/{id}/stages/{stageId}/items',
1391
+ pathParams: ['id', 'stageId'],
1392
+ queryParams: [],
1393
+ hasRequestBody: true,
1394
+ },
1303
1395
  {
1304
1396
  operationId: 'PublicApiJobController_getStageItem',
1305
1397
  resourcePath: ['jobs', 'stages', 'items'],
@@ -1312,6 +1404,42 @@ export const operations = [
1312
1404
  queryParams: [],
1313
1405
  hasRequestBody: false,
1314
1406
  },
1407
+ {
1408
+ operationId: 'PublicApiJobController_updateStageItem',
1409
+ resourcePath: ['jobs', 'stages', 'items'],
1410
+ actionName: 'updateStageItem',
1411
+ displayName: 'Update stage item',
1412
+ description: 'Update mutable fields on a stage line item.',
1413
+ method: 'PATCH',
1414
+ path: '/jobs/{id}/stages/{stageId}/items/{itemId}',
1415
+ pathParams: ['id', 'stageId', 'itemId'],
1416
+ queryParams: [],
1417
+ hasRequestBody: true,
1418
+ },
1419
+ {
1420
+ operationId: 'PublicApiJobController_deleteStageItem',
1421
+ resourcePath: ['jobs', 'stages', 'items'],
1422
+ actionName: 'deleteStageItem',
1423
+ displayName: 'Delete stage item',
1424
+ description: 'Remove or cancel a stage item depending on tenant deletion settings.',
1425
+ method: 'DELETE',
1426
+ path: '/jobs/{id}/stages/{stageId}/items/{itemId}',
1427
+ pathParams: ['id', 'stageId', 'itemId'],
1428
+ queryParams: [],
1429
+ hasRequestBody: false,
1430
+ },
1431
+ {
1432
+ operationId: 'PublicApiJobLineItemController_list',
1433
+ resourcePath: ['items'],
1434
+ actionName: 'list',
1435
+ displayName: 'Find job line items',
1436
+ description: 'Find a job line item by external integration ID.',
1437
+ method: 'GET',
1438
+ path: '/items',
1439
+ pathParams: [],
1440
+ queryParams: ['integrationId'],
1441
+ hasRequestBody: false,
1442
+ },
1315
1443
  {
1316
1444
  operationId: 'PublicJobStageController_create',
1317
1445
  resourcePath: ['stages'],
@@ -1732,6 +1860,54 @@ export const operations = [
1732
1860
  queryParams: [],
1733
1861
  hasRequestBody: false,
1734
1862
  },
1863
+ {
1864
+ operationId: 'PublicApiCustomFieldController_listJobCustomFields',
1865
+ resourcePath: ['settings', 'customFields', 'jobs'],
1866
+ actionName: 'listJobCustomFields',
1867
+ displayName: 'List job custom fields',
1868
+ description: 'Retrieve configured custom fields that may be used in Job customFields payloads.',
1869
+ method: 'GET',
1870
+ path: '/settings/custom-fields/jobs',
1871
+ pathParams: [],
1872
+ queryParams: [],
1873
+ hasRequestBody: false,
1874
+ },
1875
+ {
1876
+ operationId: 'PublicApiCustomFieldController_listStageCustomFields',
1877
+ resourcePath: ['settings', 'customFields', 'stages'],
1878
+ actionName: 'listStageCustomFields',
1879
+ displayName: 'List stage custom fields',
1880
+ description: 'Retrieve configured custom fields that may be used in Stage customFields payloads.',
1881
+ method: 'GET',
1882
+ path: '/settings/custom-fields/stages',
1883
+ pathParams: [],
1884
+ queryParams: [],
1885
+ hasRequestBody: false,
1886
+ },
1887
+ {
1888
+ operationId: 'PublicApiCustomFieldController_listAccountCustomFields',
1889
+ resourcePath: ['settings', 'customFields', 'accounts'],
1890
+ actionName: 'listAccountCustomFields',
1891
+ displayName: 'List account custom fields',
1892
+ description: 'Retrieve configured custom fields that may be used in CRM account customFields payloads.',
1893
+ method: 'GET',
1894
+ path: '/settings/custom-fields/accounts',
1895
+ pathParams: [],
1896
+ queryParams: [],
1897
+ hasRequestBody: false,
1898
+ },
1899
+ {
1900
+ operationId: 'PublicApiCustomFieldController_listItemCustomFields',
1901
+ resourcePath: ['settings', 'customFields', 'items'],
1902
+ actionName: 'listItemCustomFields',
1903
+ displayName: 'List item custom fields',
1904
+ description: 'Retrieve configured custom fields that may be used in settings item customFields payloads.',
1905
+ method: 'GET',
1906
+ path: '/settings/custom-fields/items',
1907
+ pathParams: [],
1908
+ queryParams: [],
1909
+ hasRequestBody: false,
1910
+ },
1735
1911
  {
1736
1912
  operationId: 'PublicAttachmentController_createUploadSession',
1737
1913
  resourcePath: ['attachments'],
@@ -2273,7 +2449,7 @@ export const operations = [
2273
2449
  method: 'GET',
2274
2450
  path: '/customers',
2275
2451
  pathParams: [],
2276
- queryParams: ['status', 'cursor', 'limit'],
2452
+ queryParams: ['integrationId', 'status', 'cursor', 'limit'],
2277
2453
  hasRequestBody: false,
2278
2454
  },
2279
2455
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@workbuddy/sdk-js-vnext",
3
- "version": "1.0.2",
3
+ "version": "1.0.4",
4
4
  "description": "WorkBuddy Public API JavaScript client",
5
5
  "license": "MIT",
6
6
  "type": "module",