@workbuddy/n8n-nodes-workbuddy-vnext 1.0.17 → 1.0.19

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.
@@ -1 +1 @@
1
- {"version":3,"file":"WorkBuddy.node.d.ts","sourceRoot":"","sources":["../../../nodes/WorkBuddy/WorkBuddy.node.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,oBAAoB,EAAE,SAAS,EAAE,oBAAoB,EAAE,MAAM,cAAc,CAAC;AA6E5G,qBAAa,SAAU,YAAW,SAAS;IACzC,WAAW,EAAE,oBAAoB,CAwlkB/B;IAEF,OAAO;;0CAEiC,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;sCAG3D,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;kCAG3D,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;qCAGpD,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;sCAGtD,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;sCAGvD,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;kCAG3D,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;sCAGnD,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;qCAGxD,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;;MAIxF;CACH"}
1
+ {"version":3,"file":"WorkBuddy.node.d.ts","sourceRoot":"","sources":["../../../nodes/WorkBuddy/WorkBuddy.node.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,oBAAoB,EAAE,SAAS,EAAE,oBAAoB,EAAE,MAAM,cAAc,CAAC;AA6E5G,qBAAa,SAAU,YAAW,SAAS;IACzC,WAAW,EAAE,oBAAoB,CAiolB/B;IAEF,OAAO;;0CAEiC,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;sCAG3D,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;kCAG3D,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;qCAGpD,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;sCAGtD,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;sCAGvD,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;kCAG3D,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;sCAGnD,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;qCAGxD,qBAAqB,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;;MAIxF;CACH"}
@@ -287,6 +287,18 @@ class WorkBuddy {
287
287
  },
288
288
  },
289
289
  },
290
+ {
291
+ name: 'Create a new job from template',
292
+ value: 'PublicApiJobController_createFromTemplate',
293
+ action: 'Create a job using a job template. Template-owned fields win over request values before final job validation.',
294
+ description: 'Create a job using a job template. Template-owned fields win over request values before final job validation.',
295
+ routing: {
296
+ request: {
297
+ method: 'POST',
298
+ url: '/api/v2/public/jobs/template/={{ $parameter["templateId"] }}',
299
+ },
300
+ },
301
+ },
290
302
  {
291
303
  name: 'Update job status',
292
304
  value: 'PublicApiJobController_updateStatus',
@@ -3189,6 +3201,26 @@ class WorkBuddy {
3189
3201
  },
3190
3202
  },
3191
3203
  },
3204
+ {
3205
+ displayName: 'Job Number',
3206
+ name: 'jobNumber',
3207
+ type: 'string',
3208
+ default: '',
3209
+ description: '',
3210
+ required: false,
3211
+ displayOptions: {
3212
+ show: {
3213
+ resource: ['jobs'],
3214
+ operation: ['PublicApiJobController_create'],
3215
+ },
3216
+ },
3217
+ routing: {
3218
+ send: {
3219
+ type: 'body',
3220
+ property: 'jobNumber',
3221
+ },
3222
+ },
3223
+ },
3192
3224
  {
3193
3225
  displayName: 'Description',
3194
3226
  name: 'description',
@@ -3551,26 +3583,6 @@ class WorkBuddy {
3551
3583
  },
3552
3584
  },
3553
3585
  },
3554
- {
3555
- displayName: 'Template Id',
3556
- name: 'templateId',
3557
- type: 'string',
3558
- default: '',
3559
- description: 'Template ID to pre-populate fields from a template',
3560
- required: false,
3561
- displayOptions: {
3562
- show: {
3563
- resource: ['jobs'],
3564
- operation: ['PublicApiJobController_create'],
3565
- },
3566
- },
3567
- routing: {
3568
- send: {
3569
- type: 'body',
3570
- property: 'templateId',
3571
- },
3572
- },
3573
- },
3574
3586
  {
3575
3587
  displayName: 'Start Date',
3576
3588
  name: 'startDate',
@@ -3651,6 +3663,545 @@ class WorkBuddy {
3651
3663
  },
3652
3664
  },
3653
3665
  },
3666
+ {
3667
+ displayName: 'Template Id',
3668
+ name: 'templateId',
3669
+ type: 'string',
3670
+ default: '',
3671
+ description: 'Job template ID',
3672
+ required: true,
3673
+ displayOptions: {
3674
+ show: {
3675
+ resource: ['jobs'],
3676
+ operation: ['PublicApiJobController_createFromTemplate'],
3677
+ },
3678
+ },
3679
+ },
3680
+ {
3681
+ displayName: 'Customer Id',
3682
+ name: 'customerId',
3683
+ type: 'options',
3684
+ default: '',
3685
+ description: 'Customer ID — use /crm/customers to look up',
3686
+ required: true,
3687
+ displayOptions: {
3688
+ show: {
3689
+ resource: ['jobs'],
3690
+ operation: ['PublicApiJobController_createFromTemplate'],
3691
+ },
3692
+ },
3693
+ typeOptions: {
3694
+ loadOptionsMethod: 'loadCustomerOptions',
3695
+ },
3696
+ routing: {
3697
+ send: {
3698
+ type: 'body',
3699
+ property: 'customerId',
3700
+ },
3701
+ },
3702
+ },
3703
+ {
3704
+ displayName: 'Name',
3705
+ name: 'name',
3706
+ type: 'string',
3707
+ default: '',
3708
+ description: 'Display name',
3709
+ required: false,
3710
+ displayOptions: {
3711
+ show: {
3712
+ resource: ['jobs'],
3713
+ operation: ['PublicApiJobController_createFromTemplate'],
3714
+ },
3715
+ },
3716
+ routing: {
3717
+ send: {
3718
+ type: 'body',
3719
+ property: 'name',
3720
+ },
3721
+ },
3722
+ },
3723
+ {
3724
+ displayName: 'Integration Id',
3725
+ name: 'integrationId',
3726
+ type: 'string',
3727
+ default: '',
3728
+ description: 'integration ID',
3729
+ required: false,
3730
+ displayOptions: {
3731
+ show: {
3732
+ resource: ['jobs'],
3733
+ operation: ['PublicApiJobController_createFromTemplate'],
3734
+ },
3735
+ },
3736
+ routing: {
3737
+ send: {
3738
+ type: 'body',
3739
+ property: 'integrationId',
3740
+ },
3741
+ },
3742
+ },
3743
+ {
3744
+ displayName: 'Job Number',
3745
+ name: 'jobNumber',
3746
+ type: 'string',
3747
+ default: '',
3748
+ description: '',
3749
+ required: false,
3750
+ displayOptions: {
3751
+ show: {
3752
+ resource: ['jobs'],
3753
+ operation: ['PublicApiJobController_createFromTemplate'],
3754
+ },
3755
+ },
3756
+ routing: {
3757
+ send: {
3758
+ type: 'body',
3759
+ property: 'jobNumber',
3760
+ },
3761
+ },
3762
+ },
3763
+ {
3764
+ displayName: 'Description',
3765
+ name: 'description',
3766
+ type: 'string',
3767
+ default: '',
3768
+ description: 'Detailed description',
3769
+ required: false,
3770
+ displayOptions: {
3771
+ show: {
3772
+ resource: ['jobs'],
3773
+ operation: ['PublicApiJobController_createFromTemplate'],
3774
+ },
3775
+ },
3776
+ routing: {
3777
+ send: {
3778
+ type: 'body',
3779
+ property: 'description',
3780
+ },
3781
+ },
3782
+ },
3783
+ {
3784
+ displayName: 'Site Id',
3785
+ name: 'siteId',
3786
+ type: 'options',
3787
+ default: '',
3788
+ description: 'Site ID — use /crm/sites to look up',
3789
+ required: false,
3790
+ displayOptions: {
3791
+ show: {
3792
+ resource: ['jobs'],
3793
+ operation: ['PublicApiJobController_createFromTemplate'],
3794
+ },
3795
+ },
3796
+ typeOptions: {
3797
+ loadOptionsMethod: 'loadSiteOptions',
3798
+ },
3799
+ routing: {
3800
+ send: {
3801
+ type: 'body',
3802
+ property: 'siteId',
3803
+ },
3804
+ },
3805
+ },
3806
+ {
3807
+ displayName: 'Site',
3808
+ name: 'site',
3809
+ type: 'json',
3810
+ default: {},
3811
+ description: 'Inline site object — alternative to siteId',
3812
+ required: false,
3813
+ displayOptions: {
3814
+ show: {
3815
+ resource: ['jobs'],
3816
+ operation: ['PublicApiJobController_createFromTemplate'],
3817
+ },
3818
+ },
3819
+ routing: {
3820
+ send: {
3821
+ type: 'body',
3822
+ property: 'site',
3823
+ },
3824
+ },
3825
+ },
3826
+ {
3827
+ displayName: 'Contact Id',
3828
+ name: 'contactId',
3829
+ type: 'string',
3830
+ default: '',
3831
+ description: 'Contact ID — use /crm/contacts to look up',
3832
+ required: false,
3833
+ displayOptions: {
3834
+ show: {
3835
+ resource: ['jobs'],
3836
+ operation: ['PublicApiJobController_createFromTemplate'],
3837
+ },
3838
+ },
3839
+ routing: {
3840
+ send: {
3841
+ type: 'body',
3842
+ property: 'contactId',
3843
+ },
3844
+ },
3845
+ },
3846
+ {
3847
+ displayName: 'Contact',
3848
+ name: 'contact',
3849
+ type: 'collection',
3850
+ default: {},
3851
+ placeholder: 'Add Contact',
3852
+ description: 'Inline contact object — alternative to contactId',
3853
+ required: false,
3854
+ displayOptions: {
3855
+ show: {
3856
+ resource: ['jobs'],
3857
+ operation: ['PublicApiJobController_createFromTemplate'],
3858
+ },
3859
+ },
3860
+ options: [
3861
+ {
3862
+ displayName: 'Name',
3863
+ name: 'name',
3864
+ type: 'string',
3865
+ default: '',
3866
+ description: 'Display name',
3867
+ },
3868
+ {
3869
+ displayName: 'Phone',
3870
+ name: 'phone',
3871
+ type: 'string',
3872
+ default: '',
3873
+ description: 'Phone number',
3874
+ },
3875
+ {
3876
+ displayName: 'Email',
3877
+ name: 'email',
3878
+ type: 'string',
3879
+ default: '',
3880
+ description: 'Email address',
3881
+ },
3882
+ ],
3883
+ routing: {
3884
+ send: {
3885
+ type: 'body',
3886
+ property: 'contact',
3887
+ },
3888
+ },
3889
+ },
3890
+ {
3891
+ displayName: 'Type Id',
3892
+ name: 'typeId',
3893
+ type: 'options',
3894
+ default: '',
3895
+ description: 'Job type ID — use /settings/job-types to look up',
3896
+ required: false,
3897
+ displayOptions: {
3898
+ show: {
3899
+ resource: ['jobs'],
3900
+ operation: ['PublicApiJobController_createFromTemplate'],
3901
+ },
3902
+ },
3903
+ typeOptions: {
3904
+ loadOptionsMethod: 'loadJobTypeOptions',
3905
+ },
3906
+ routing: {
3907
+ send: {
3908
+ type: 'body',
3909
+ property: 'typeId',
3910
+ },
3911
+ },
3912
+ },
3913
+ {
3914
+ displayName: 'Priority Id',
3915
+ name: 'priorityId',
3916
+ type: 'options',
3917
+ default: '',
3918
+ description: 'Priority ID — use /settings/priorities to look up',
3919
+ required: false,
3920
+ displayOptions: {
3921
+ show: {
3922
+ resource: ['jobs'],
3923
+ operation: ['PublicApiJobController_createFromTemplate'],
3924
+ },
3925
+ },
3926
+ typeOptions: {
3927
+ loadOptionsMethod: 'loadPriorityOptions',
3928
+ },
3929
+ routing: {
3930
+ send: {
3931
+ type: 'body',
3932
+ property: 'priorityId',
3933
+ },
3934
+ },
3935
+ },
3936
+ {
3937
+ displayName: 'Price Book Id',
3938
+ name: 'priceBookId',
3939
+ type: 'string',
3940
+ default: '',
3941
+ description: 'Price book ID for job pricing',
3942
+ required: false,
3943
+ displayOptions: {
3944
+ show: {
3945
+ resource: ['jobs'],
3946
+ operation: ['PublicApiJobController_createFromTemplate'],
3947
+ },
3948
+ },
3949
+ routing: {
3950
+ send: {
3951
+ type: 'body',
3952
+ property: 'priceBookId',
3953
+ },
3954
+ },
3955
+ },
3956
+ {
3957
+ displayName: 'Owner Id',
3958
+ name: 'ownerId',
3959
+ type: 'options',
3960
+ default: '',
3961
+ description: 'Owner (employee) ID — use /crm/employees to look up',
3962
+ required: false,
3963
+ displayOptions: {
3964
+ show: {
3965
+ resource: ['jobs'],
3966
+ operation: ['PublicApiJobController_createFromTemplate'],
3967
+ },
3968
+ },
3969
+ typeOptions: {
3970
+ loadOptionsMethod: 'loadEmployeeOptions',
3971
+ },
3972
+ routing: {
3973
+ send: {
3974
+ type: 'body',
3975
+ property: 'ownerId',
3976
+ },
3977
+ },
3978
+ },
3979
+ {
3980
+ displayName: 'Field Supervisor Id',
3981
+ name: 'fieldSupervisorId',
3982
+ type: 'options',
3983
+ default: '',
3984
+ description: 'Field supervisor (employee) ID — use /crm/employees to look up',
3985
+ required: false,
3986
+ displayOptions: {
3987
+ show: {
3988
+ resource: ['jobs'],
3989
+ operation: ['PublicApiJobController_createFromTemplate'],
3990
+ },
3991
+ },
3992
+ typeOptions: {
3993
+ loadOptionsMethod: 'loadEmployeeOptions',
3994
+ },
3995
+ routing: {
3996
+ send: {
3997
+ type: 'body',
3998
+ property: 'fieldSupervisorId',
3999
+ },
4000
+ },
4001
+ },
4002
+ {
4003
+ displayName: 'Zone Id',
4004
+ name: 'zoneId',
4005
+ type: 'options',
4006
+ default: '',
4007
+ description: 'Zone ID — use /settings/zones to look up',
4008
+ required: false,
4009
+ displayOptions: {
4010
+ show: {
4011
+ resource: ['jobs'],
4012
+ operation: ['PublicApiJobController_createFromTemplate'],
4013
+ },
4014
+ },
4015
+ typeOptions: {
4016
+ loadOptionsMethod: 'loadZoneOptions',
4017
+ },
4018
+ routing: {
4019
+ send: {
4020
+ type: 'body',
4021
+ property: 'zoneId',
4022
+ },
4023
+ },
4024
+ },
4025
+ {
4026
+ displayName: 'Tag Ids',
4027
+ name: 'tagIds',
4028
+ type: 'string',
4029
+ default: '',
4030
+ description: 'Array of tag IDs (comma-separated, e.g. "id1,id2") — use /settings/tags to look up',
4031
+ required: false,
4032
+ displayOptions: {
4033
+ show: {
4034
+ resource: ['jobs'],
4035
+ operation: ['PublicApiJobController_createFromTemplate'],
4036
+ },
4037
+ },
4038
+ routing: {
4039
+ send: {
4040
+ type: 'body',
4041
+ property: 'tagIds',
4042
+ },
4043
+ },
4044
+ },
4045
+ {
4046
+ displayName: 'Notes',
4047
+ name: 'notes',
4048
+ type: 'string',
4049
+ default: '',
4050
+ description: 'Additional notes or comments',
4051
+ required: false,
4052
+ displayOptions: {
4053
+ show: {
4054
+ resource: ['jobs'],
4055
+ operation: ['PublicApiJobController_createFromTemplate'],
4056
+ },
4057
+ },
4058
+ routing: {
4059
+ send: {
4060
+ type: 'body',
4061
+ property: 'notes',
4062
+ },
4063
+ },
4064
+ },
4065
+ {
4066
+ displayName: 'Reference',
4067
+ name: 'reference',
4068
+ type: 'string',
4069
+ default: '',
4070
+ description: 'External reference number',
4071
+ required: false,
4072
+ displayOptions: {
4073
+ show: {
4074
+ resource: ['jobs'],
4075
+ operation: ['PublicApiJobController_createFromTemplate'],
4076
+ },
4077
+ },
4078
+ routing: {
4079
+ send: {
4080
+ type: 'body',
4081
+ property: 'reference',
4082
+ },
4083
+ },
4084
+ },
4085
+ {
4086
+ displayName: 'Customer W O',
4087
+ name: 'customerWO',
4088
+ type: 'string',
4089
+ default: '',
4090
+ description: 'Customer work order reference',
4091
+ required: false,
4092
+ displayOptions: {
4093
+ show: {
4094
+ resource: ['jobs'],
4095
+ operation: ['PublicApiJobController_createFromTemplate'],
4096
+ },
4097
+ },
4098
+ routing: {
4099
+ send: {
4100
+ type: 'body',
4101
+ property: 'customerWO',
4102
+ },
4103
+ },
4104
+ },
4105
+ {
4106
+ displayName: 'Customer P O',
4107
+ name: 'customerPO',
4108
+ type: 'string',
4109
+ default: '',
4110
+ description: 'Customer purchase order reference',
4111
+ required: false,
4112
+ displayOptions: {
4113
+ show: {
4114
+ resource: ['jobs'],
4115
+ operation: ['PublicApiJobController_createFromTemplate'],
4116
+ },
4117
+ },
4118
+ routing: {
4119
+ send: {
4120
+ type: 'body',
4121
+ property: 'customerPO',
4122
+ },
4123
+ },
4124
+ },
4125
+ {
4126
+ displayName: 'Start Date',
4127
+ name: 'startDate',
4128
+ type: 'dateTime',
4129
+ default: '',
4130
+ description: 'Start date (ISO 8601 datetime)',
4131
+ required: false,
4132
+ displayOptions: {
4133
+ show: {
4134
+ resource: ['jobs'],
4135
+ operation: ['PublicApiJobController_createFromTemplate'],
4136
+ },
4137
+ },
4138
+ routing: {
4139
+ send: {
4140
+ type: 'body',
4141
+ property: 'startDate',
4142
+ },
4143
+ },
4144
+ },
4145
+ {
4146
+ displayName: 'Due Date',
4147
+ name: 'dueDate',
4148
+ type: 'dateTime',
4149
+ default: '',
4150
+ description: 'Due date (ISO 8601 datetime)',
4151
+ required: false,
4152
+ displayOptions: {
4153
+ show: {
4154
+ resource: ['jobs'],
4155
+ operation: ['PublicApiJobController_createFromTemplate'],
4156
+ },
4157
+ },
4158
+ routing: {
4159
+ send: {
4160
+ type: 'body',
4161
+ property: 'dueDate',
4162
+ },
4163
+ },
4164
+ },
4165
+ {
4166
+ displayName: 'Custom Fields',
4167
+ name: 'customFields',
4168
+ type: 'json',
4169
+ default: {},
4170
+ description: 'Custom fields as key-value pairs — validated against tenant field definitions',
4171
+ required: false,
4172
+ displayOptions: {
4173
+ show: {
4174
+ resource: ['jobs'],
4175
+ operation: ['PublicApiJobController_createFromTemplate'],
4176
+ },
4177
+ },
4178
+ routing: {
4179
+ send: {
4180
+ type: 'body',
4181
+ property: 'customFields',
4182
+ },
4183
+ },
4184
+ },
4185
+ {
4186
+ displayName: 'Items',
4187
+ name: 'items',
4188
+ type: 'json',
4189
+ default: {},
4190
+ description: '',
4191
+ required: false,
4192
+ displayOptions: {
4193
+ show: {
4194
+ resource: ['jobs'],
4195
+ operation: ['PublicApiJobController_createFromTemplate'],
4196
+ },
4197
+ },
4198
+ routing: {
4199
+ send: {
4200
+ type: 'body',
4201
+ property: 'items',
4202
+ },
4203
+ },
4204
+ },
3654
4205
  {
3655
4206
  displayName: 'Id',
3656
4207
  name: 'id',
@@ -6445,8 +6996,8 @@ class WorkBuddy {
6445
6996
  {
6446
6997
  name: 'Get item',
6447
6998
  value: 'PublicApiItemController_getById',
6448
- action: 'Retrieve a settings item by ID.',
6449
- description: 'Retrieve a settings item by ID.',
6999
+ action: 'Retrieve a settings item by ID, name, or integration ID.',
7000
+ description: 'Retrieve a settings item by ID, name, or integration ID.',
6450
7001
  routing: {
6451
7002
  request: {
6452
7003
  method: 'GET',