@workbuddy/n8n-nodes-workbuddy-vnext 1.0.157 → 1.0.159

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.
@@ -248,6 +248,14 @@ class WorkBuddy {
248
248
  name: 'Service Plans Lines Tasks Subtasks',
249
249
  value: 'service-plans-lines-tasks-subtasks',
250
250
  },
251
+ {
252
+ name: 'Sales Leads',
253
+ value: 'sales-leads',
254
+ },
255
+ {
256
+ name: 'Sales Opportunities',
257
+ value: 'sales-opportunities',
258
+ },
251
259
  {
252
260
  name: 'Mcp',
253
261
  value: 'mcp',
@@ -267,30 +275,6 @@ class WorkBuddy {
267
275
  },
268
276
  },
269
277
  options: [
270
- {
271
- name: 'List Job actions',
272
- value: 'PublicApiJobActionController_list',
273
- action: 'Metadata actions that can run on one Job: commands (change status, add note) and bulk-updatable fields as set-field actions. Each lists its input JSON Schema, required security rights and whether the UI confirms it first.',
274
- description: 'Metadata actions that can run on one Job: commands (change status, add note) and bulk-updatable fields as set-field actions. Each lists its input JSON Schema, required security rights and whether the UI confirms it first.',
275
- routing: {
276
- request: {
277
- method: 'GET',
278
- url: '/api/v2/public/jobs/actions',
279
- },
280
- },
281
- },
282
- {
283
- name: 'Run a Job action',
284
- value: 'PublicApiJobActionController_run',
285
- action: 'Runs one action listed by GET /jobs/actions on a single Job, through the same executor as the board. Actions the UI confirms first run without confirmation here; the caller is authorised by its rights.',
286
- description: 'Runs one action listed by GET /jobs/actions on a single Job, through the same executor as the board. Actions the UI confirms first run without confirmation here; the caller is authorised by its rights.',
287
- routing: {
288
- request: {
289
- method: 'POST',
290
- url: '/api/v2/public/jobs/={{ $parameter["id"] }}/actions/={{ $parameter["actionId"] }}',
291
- },
292
- },
293
- },
294
278
  {
295
279
  name: 'Search jobs or stages with complex filters',
296
280
  value: 'PublicApiJobController_search',
@@ -484,55 +468,7 @@ class WorkBuddy {
484
468
  },
485
469
  },
486
470
  ],
487
- default: 'PublicApiJobActionController_list',
488
- },
489
- {
490
- displayName: 'Id',
491
- name: 'id',
492
- type: 'string',
493
- default: '',
494
- description: 'Job ID, job number, or external integration ID',
495
- required: true,
496
- displayOptions: {
497
- show: {
498
- resource: ['jobs'],
499
- operation: ['PublicApiJobActionController_run'],
500
- },
501
- },
502
- },
503
- {
504
- displayName: 'Action Id',
505
- name: 'actionId',
506
- type: 'string',
507
- default: '',
508
- description: 'Action id from GET /jobs/actions',
509
- required: true,
510
- displayOptions: {
511
- show: {
512
- resource: ['jobs'],
513
- operation: ['PublicApiJobActionController_run'],
514
- },
515
- },
516
- },
517
- {
518
- displayName: 'Input',
519
- name: 'input',
520
- type: 'string',
521
- default: '',
522
- description: '',
523
- required: false,
524
- displayOptions: {
525
- show: {
526
- resource: ['jobs'],
527
- operation: ['PublicApiJobActionController_run'],
528
- },
529
- },
530
- routing: {
531
- send: {
532
- type: 'body',
533
- property: 'input',
534
- },
535
- },
471
+ default: 'PublicApiJobController_search',
536
472
  },
537
473
  {
538
474
  displayName: 'Mode',
@@ -5848,6 +5784,18 @@ class WorkBuddy {
5848
5784
  },
5849
5785
  },
5850
5786
  options: [
5787
+ {
5788
+ name: 'Get job line item by ID',
5789
+ value: 'PublicApiJobLineItemController_get',
5790
+ action: 'Read a line item and its owning Job and Stage IDs.',
5791
+ description: 'Read a line item and its owning Job and Stage IDs.',
5792
+ routing: {
5793
+ request: {
5794
+ method: 'GET',
5795
+ url: '/api/v2/public/items/={{ $parameter["id"] }}',
5796
+ },
5797
+ },
5798
+ },
5851
5799
  {
5852
5800
  name: 'Find job line items',
5853
5801
  value: 'PublicApiJobLineItemController_list',
@@ -5861,7 +5809,21 @@ class WorkBuddy {
5861
5809
  },
5862
5810
  },
5863
5811
  ],
5864
- default: 'PublicApiJobLineItemController_list',
5812
+ default: 'PublicApiJobLineItemController_get',
5813
+ },
5814
+ {
5815
+ displayName: 'Id',
5816
+ name: 'id',
5817
+ type: 'string',
5818
+ default: '',
5819
+ description: 'Entity ID',
5820
+ required: true,
5821
+ displayOptions: {
5822
+ show: {
5823
+ resource: ['items'],
5824
+ operation: ['PublicApiJobLineItemController_get'],
5825
+ },
5826
+ },
5865
5827
  },
5866
5828
  {
5867
5829
  displayName: 'Integration Id',
@@ -6642,26 +6604,14 @@ class WorkBuddy {
6642
6604
  },
6643
6605
  options: [
6644
6606
  {
6645
- name: 'Create a new stage',
6646
- value: 'PublicJobStageController_create',
6647
- action: 'Create a new stage (work order) within a job. Stages represent discrete phases of work.',
6648
- description: 'Create a new stage (work order) within a job. Stages represent discrete phases of work.',
6649
- routing: {
6650
- request: {
6651
- method: 'POST',
6652
- url: '/api/v2/public/stages',
6653
- },
6654
- },
6655
- },
6656
- {
6657
- name: 'Set stage finance marks',
6658
- value: 'PublicJobStageController_updateFinance',
6659
- action: 'Mark or unmark a stage Non-Billable and/or Non-Payable. Dispatches the domain finance-lock command once per changed side. Same value is a no-op. Unmarking a stage while the job holds that mark is refused. Requires jobs:financial.',
6660
- description: 'Mark or unmark a stage Non-Billable and/or Non-Payable. Dispatches the domain finance-lock command once per changed side. Same value is a no-op. Unmarking a stage while the job holds that mark is refused. Requires jobs:financial.',
6607
+ name: 'Get stage by ID',
6608
+ value: 'PublicJobStageController_get',
6609
+ action: 'Read a stage, its owning Job ID and its current concurrency token.',
6610
+ description: 'Read a stage, its owning Job ID and its current concurrency token.',
6661
6611
  routing: {
6662
6612
  request: {
6663
- method: 'PATCH',
6664
- url: '/api/v2/public/stages/={{ $parameter["id"] }}/finance',
6613
+ method: 'GET',
6614
+ url: '/api/v2/public/stages/={{ $parameter["id"] }}',
6665
6615
  },
6666
6616
  },
6667
6617
  },
@@ -6689,6 +6639,30 @@ class WorkBuddy {
6689
6639
  },
6690
6640
  },
6691
6641
  },
6642
+ {
6643
+ name: 'Create a new stage',
6644
+ value: 'PublicJobStageController_create',
6645
+ action: 'Create a new stage (work order) within a job. Stages represent discrete phases of work.',
6646
+ description: 'Create a new stage (work order) within a job. Stages represent discrete phases of work.',
6647
+ routing: {
6648
+ request: {
6649
+ method: 'POST',
6650
+ url: '/api/v2/public/stages',
6651
+ },
6652
+ },
6653
+ },
6654
+ {
6655
+ name: 'Set stage finance marks',
6656
+ value: 'PublicJobStageController_updateFinance',
6657
+ action: 'Mark or unmark a stage Non-Billable and/or Non-Payable. Dispatches the domain finance-lock command once per changed side. Same value is a no-op. Unmarking a stage while the job holds that mark is refused. Requires jobs:financial.',
6658
+ description: 'Mark or unmark a stage Non-Billable and/or Non-Payable. Dispatches the domain finance-lock command once per changed side. Same value is a no-op. Unmarking a stage while the job holds that mark is refused. Requires jobs:financial.',
6659
+ routing: {
6660
+ request: {
6661
+ method: 'PATCH',
6662
+ url: '/api/v2/public/stages/={{ $parameter["id"] }}/finance',
6663
+ },
6664
+ },
6665
+ },
6692
6666
  {
6693
6667
  name: 'Dispatch a stage',
6694
6668
  value: 'PublicJobStageController_dispatch',
@@ -6786,25 +6760,33 @@ class WorkBuddy {
6786
6760
  },
6787
6761
  },
6788
6762
  ],
6789
- default: 'PublicJobStageController_create',
6763
+ default: 'PublicJobStageController_get',
6790
6764
  },
6791
6765
  {
6792
- displayName: 'Job Id',
6793
- name: 'jobId',
6766
+ displayName: 'Id',
6767
+ name: 'id',
6794
6768
  type: 'string',
6795
6769
  default: '',
6796
- description: 'Job ID or job number (e.g. J12345)',
6770
+ description: 'Stage ID',
6797
6771
  required: true,
6798
6772
  displayOptions: {
6799
6773
  show: {
6800
6774
  resource: ['stages'],
6801
- operation: ['PublicJobStageController_create'],
6775
+ operation: ['PublicJobStageController_get'],
6802
6776
  },
6803
6777
  },
6804
- routing: {
6805
- send: {
6806
- type: 'body',
6807
- property: 'jobId',
6778
+ },
6779
+ {
6780
+ displayName: 'Id',
6781
+ name: 'id',
6782
+ type: 'string',
6783
+ default: '',
6784
+ description: 'Stage ID',
6785
+ required: true,
6786
+ displayOptions: {
6787
+ show: {
6788
+ resource: ['stages'],
6789
+ operation: ['PublicJobStageController_update'],
6808
6790
  },
6809
6791
  },
6810
6792
  },
@@ -6814,11 +6796,11 @@ class WorkBuddy {
6814
6796
  type: 'string',
6815
6797
  default: '',
6816
6798
  description: 'Display name',
6817
- required: true,
6799
+ required: false,
6818
6800
  displayOptions: {
6819
6801
  show: {
6820
6802
  resource: ['stages'],
6821
- operation: ['PublicJobStageController_create'],
6803
+ operation: ['PublicJobStageController_update'],
6822
6804
  },
6823
6805
  },
6824
6806
  routing: {
@@ -6838,7 +6820,7 @@ class WorkBuddy {
6838
6820
  displayOptions: {
6839
6821
  show: {
6840
6822
  resource: ['stages'],
6841
- operation: ['PublicJobStageController_create'],
6823
+ operation: ['PublicJobStageController_update'],
6842
6824
  },
6843
6825
  },
6844
6826
  typeOptions: {
@@ -6861,7 +6843,7 @@ class WorkBuddy {
6861
6843
  displayOptions: {
6862
6844
  show: {
6863
6845
  resource: ['stages'],
6864
- operation: ['PublicJobStageController_create'],
6846
+ operation: ['PublicJobStageController_update'],
6865
6847
  },
6866
6848
  },
6867
6849
  routing: {
@@ -6881,7 +6863,7 @@ class WorkBuddy {
6881
6863
  displayOptions: {
6882
6864
  show: {
6883
6865
  resource: ['stages'],
6884
- operation: ['PublicJobStageController_create'],
6866
+ operation: ['PublicJobStageController_update'],
6885
6867
  },
6886
6868
  },
6887
6869
  routing: {
@@ -6892,133 +6874,154 @@ class WorkBuddy {
6892
6874
  },
6893
6875
  },
6894
6876
  {
6895
- displayName: 'Custom Fields',
6896
- name: 'customFields',
6897
- type: 'json',
6898
- default: {},
6899
- description: 'Custom fields as key-value pairs — validated against tenant field definitions',
6900
- required: false,
6877
+ displayName: 'Tags Set',
6878
+ name: 'tagsSet',
6879
+ type: 'string',
6880
+ default: '',
6881
+ typeOptions: {
6882
+ multipleValues: true,
6883
+ },
6884
+ description: '',
6901
6885
  displayOptions: {
6902
6886
  show: {
6903
6887
  resource: ['stages'],
6904
- operation: ['PublicJobStageController_create'],
6888
+ operation: ['PublicJobStageController_update'],
6905
6889
  },
6906
6890
  },
6907
6891
  routing: {
6908
6892
  send: {
6909
6893
  type: 'body',
6910
- property: 'customFields',
6894
+ property: 'tags.set',
6911
6895
  },
6912
6896
  },
6913
6897
  },
6914
6898
  {
6915
- displayName: 'Finance',
6916
- name: 'finance',
6917
- type: 'collection',
6918
- default: {},
6919
- placeholder: 'Add Finance',
6899
+ displayName: 'Tags Add',
6900
+ name: 'tagsAdd',
6901
+ type: 'string',
6902
+ default: '',
6903
+ typeOptions: {
6904
+ multipleValues: true,
6905
+ },
6920
6906
  description: '',
6921
- required: false,
6922
6907
  displayOptions: {
6923
6908
  show: {
6924
6909
  resource: ['stages'],
6925
- operation: ['PublicJobStageController_create'],
6910
+ operation: ['PublicJobStageController_update'],
6926
6911
  },
6927
6912
  },
6928
- options: [
6929
- {
6930
- displayName: 'Non Billable',
6931
- name: 'nonBillable',
6932
- type: 'boolean',
6933
- default: false,
6934
- description: '',
6935
- },
6936
- {
6937
- displayName: 'Non Payable',
6938
- name: 'nonPayable',
6939
- type: 'boolean',
6940
- default: false,
6941
- description: '',
6942
- },
6943
- ],
6944
6913
  routing: {
6945
6914
  send: {
6946
6915
  type: 'body',
6947
- property: 'finance',
6916
+ property: 'tags.add',
6948
6917
  },
6949
6918
  },
6950
6919
  },
6951
6920
  {
6952
- displayName: 'Id',
6953
- name: 'id',
6921
+ displayName: 'Tags Remove',
6922
+ name: 'tagsRemove',
6954
6923
  type: 'string',
6955
6924
  default: '',
6956
- description: 'Stage ID',
6957
- required: true,
6925
+ typeOptions: {
6926
+ multipleValues: true,
6927
+ },
6928
+ description: '',
6958
6929
  displayOptions: {
6959
6930
  show: {
6960
6931
  resource: ['stages'],
6961
- operation: ['PublicJobStageController_updateFinance'],
6932
+ operation: ['PublicJobStageController_update'],
6933
+ },
6934
+ },
6935
+ routing: {
6936
+ send: {
6937
+ type: 'body',
6938
+ property: 'tags.remove',
6962
6939
  },
6963
6940
  },
6964
6941
  },
6965
6942
  {
6966
- displayName: 'Non Billable',
6967
- name: 'nonBillable',
6968
- type: 'boolean',
6969
- default: false,
6943
+ displayName: 'Scheduling Tags Set',
6944
+ name: 'schedulingTagsSet',
6945
+ type: 'string',
6946
+ default: '',
6947
+ typeOptions: {
6948
+ multipleValues: true,
6949
+ },
6970
6950
  description: '',
6971
- required: false,
6972
6951
  displayOptions: {
6973
6952
  show: {
6974
6953
  resource: ['stages'],
6975
- operation: ['PublicJobStageController_updateFinance'],
6954
+ operation: ['PublicJobStageController_update'],
6976
6955
  },
6977
6956
  },
6978
6957
  routing: {
6979
6958
  send: {
6980
6959
  type: 'body',
6981
- property: 'nonBillable',
6960
+ property: 'schedulingTags.set',
6982
6961
  },
6983
6962
  },
6984
6963
  },
6985
6964
  {
6986
- displayName: 'Non Payable',
6987
- name: 'nonPayable',
6988
- type: 'boolean',
6989
- default: false,
6965
+ displayName: 'Scheduling Tags Add',
6966
+ name: 'schedulingTagsAdd',
6967
+ type: 'string',
6968
+ default: '',
6969
+ typeOptions: {
6970
+ multipleValues: true,
6971
+ },
6990
6972
  description: '',
6991
- required: false,
6992
6973
  displayOptions: {
6993
6974
  show: {
6994
6975
  resource: ['stages'],
6995
- operation: ['PublicJobStageController_updateFinance'],
6976
+ operation: ['PublicJobStageController_update'],
6996
6977
  },
6997
6978
  },
6998
6979
  routing: {
6999
6980
  send: {
7000
6981
  type: 'body',
7001
- property: 'nonPayable',
6982
+ property: 'schedulingTags.add',
7002
6983
  },
7003
6984
  },
7004
6985
  },
7005
6986
  {
7006
- displayName: 'Note',
7007
- name: 'note',
6987
+ displayName: 'Scheduling Tags Remove',
6988
+ name: 'schedulingTagsRemove',
7008
6989
  type: 'string',
7009
6990
  default: '',
6991
+ typeOptions: {
6992
+ multipleValues: true,
6993
+ },
7010
6994
  description: '',
6995
+ displayOptions: {
6996
+ show: {
6997
+ resource: ['stages'],
6998
+ operation: ['PublicJobStageController_update'],
6999
+ },
7000
+ },
7001
+ routing: {
7002
+ send: {
7003
+ type: 'body',
7004
+ property: 'schedulingTags.remove',
7005
+ },
7006
+ },
7007
+ },
7008
+ {
7009
+ displayName: 'Custom Fields',
7010
+ name: 'customFields',
7011
+ type: 'json',
7012
+ default: {},
7013
+ description: 'Custom fields as key-value pairs — validated against tenant field definitions',
7011
7014
  required: false,
7012
7015
  displayOptions: {
7013
7016
  show: {
7014
7017
  resource: ['stages'],
7015
- operation: ['PublicJobStageController_updateFinance'],
7018
+ operation: ['PublicJobStageController_update'],
7016
7019
  },
7017
7020
  },
7018
7021
  routing: {
7019
7022
  send: {
7020
7023
  type: 'body',
7021
- property: 'note',
7024
+ property: 'customFields',
7022
7025
  },
7023
7026
  },
7024
7027
  },
@@ -7032,7 +7035,27 @@ class WorkBuddy {
7032
7035
  displayOptions: {
7033
7036
  show: {
7034
7037
  resource: ['stages'],
7035
- operation: ['PublicJobStageController_update'],
7038
+ operation: ['PublicJobStageController_delete'],
7039
+ },
7040
+ },
7041
+ },
7042
+ {
7043
+ displayName: 'Job Id',
7044
+ name: 'jobId',
7045
+ type: 'string',
7046
+ default: '',
7047
+ description: 'Job ID or job number (e.g. J12345)',
7048
+ required: true,
7049
+ displayOptions: {
7050
+ show: {
7051
+ resource: ['stages'],
7052
+ operation: ['PublicJobStageController_create'],
7053
+ },
7054
+ },
7055
+ routing: {
7056
+ send: {
7057
+ type: 'body',
7058
+ property: 'jobId',
7036
7059
  },
7037
7060
  },
7038
7061
  },
@@ -7042,11 +7065,11 @@ class WorkBuddy {
7042
7065
  type: 'string',
7043
7066
  default: '',
7044
7067
  description: 'Display name',
7045
- required: false,
7068
+ required: true,
7046
7069
  displayOptions: {
7047
7070
  show: {
7048
7071
  resource: ['stages'],
7049
- operation: ['PublicJobStageController_update'],
7072
+ operation: ['PublicJobStageController_create'],
7050
7073
  },
7051
7074
  },
7052
7075
  routing: {
@@ -7066,7 +7089,7 @@ class WorkBuddy {
7066
7089
  displayOptions: {
7067
7090
  show: {
7068
7091
  resource: ['stages'],
7069
- operation: ['PublicJobStageController_update'],
7092
+ operation: ['PublicJobStageController_create'],
7070
7093
  },
7071
7094
  },
7072
7095
  typeOptions: {
@@ -7089,7 +7112,7 @@ class WorkBuddy {
7089
7112
  displayOptions: {
7090
7113
  show: {
7091
7114
  resource: ['stages'],
7092
- operation: ['PublicJobStageController_update'],
7115
+ operation: ['PublicJobStageController_create'],
7093
7116
  },
7094
7117
  },
7095
7118
  routing: {
@@ -7109,7 +7132,7 @@ class WorkBuddy {
7109
7132
  displayOptions: {
7110
7133
  show: {
7111
7134
  resource: ['stages'],
7112
- operation: ['PublicJobStageController_update'],
7135
+ operation: ['PublicJobStageController_create'],
7113
7136
  },
7114
7137
  },
7115
7138
  routing: {
@@ -7120,168 +7143,133 @@ class WorkBuddy {
7120
7143
  },
7121
7144
  },
7122
7145
  {
7123
- displayName: 'Tags Set',
7124
- name: 'tagsSet',
7125
- type: 'string',
7126
- default: '',
7127
- typeOptions: {
7128
- multipleValues: true,
7129
- },
7130
- description: '',
7146
+ displayName: 'Custom Fields',
7147
+ name: 'customFields',
7148
+ type: 'json',
7149
+ default: {},
7150
+ description: 'Custom fields as key-value pairs — validated against tenant field definitions',
7151
+ required: false,
7131
7152
  displayOptions: {
7132
7153
  show: {
7133
7154
  resource: ['stages'],
7134
- operation: ['PublicJobStageController_update'],
7155
+ operation: ['PublicJobStageController_create'],
7135
7156
  },
7136
7157
  },
7137
7158
  routing: {
7138
7159
  send: {
7139
7160
  type: 'body',
7140
- property: 'tags.set',
7161
+ property: 'customFields',
7141
7162
  },
7142
7163
  },
7143
7164
  },
7144
7165
  {
7145
- displayName: 'Tags Add',
7146
- name: 'tagsAdd',
7147
- type: 'string',
7148
- default: '',
7149
- typeOptions: {
7150
- multipleValues: true,
7151
- },
7166
+ displayName: 'Finance',
7167
+ name: 'finance',
7168
+ type: 'collection',
7169
+ default: {},
7170
+ placeholder: 'Add Finance',
7152
7171
  description: '',
7172
+ required: false,
7153
7173
  displayOptions: {
7154
7174
  show: {
7155
7175
  resource: ['stages'],
7156
- operation: ['PublicJobStageController_update'],
7176
+ operation: ['PublicJobStageController_create'],
7157
7177
  },
7158
7178
  },
7179
+ options: [
7180
+ {
7181
+ displayName: 'Non Billable',
7182
+ name: 'nonBillable',
7183
+ type: 'boolean',
7184
+ default: false,
7185
+ description: '',
7186
+ },
7187
+ {
7188
+ displayName: 'Non Payable',
7189
+ name: 'nonPayable',
7190
+ type: 'boolean',
7191
+ default: false,
7192
+ description: '',
7193
+ },
7194
+ ],
7159
7195
  routing: {
7160
7196
  send: {
7161
7197
  type: 'body',
7162
- property: 'tags.add',
7198
+ property: 'finance',
7163
7199
  },
7164
7200
  },
7165
7201
  },
7166
7202
  {
7167
- displayName: 'Tags Remove',
7168
- name: 'tagsRemove',
7203
+ displayName: 'Id',
7204
+ name: 'id',
7169
7205
  type: 'string',
7170
7206
  default: '',
7171
- typeOptions: {
7172
- multipleValues: true,
7173
- },
7174
- description: '',
7207
+ description: 'Stage ID',
7208
+ required: true,
7175
7209
  displayOptions: {
7176
7210
  show: {
7177
7211
  resource: ['stages'],
7178
- operation: ['PublicJobStageController_update'],
7179
- },
7180
- },
7181
- routing: {
7182
- send: {
7183
- type: 'body',
7184
- property: 'tags.remove',
7212
+ operation: ['PublicJobStageController_updateFinance'],
7185
7213
  },
7186
7214
  },
7187
7215
  },
7188
7216
  {
7189
- displayName: 'Scheduling Tags Set',
7190
- name: 'schedulingTagsSet',
7191
- type: 'string',
7192
- default: '',
7193
- typeOptions: {
7194
- multipleValues: true,
7195
- },
7217
+ displayName: 'Non Billable',
7218
+ name: 'nonBillable',
7219
+ type: 'boolean',
7220
+ default: false,
7196
7221
  description: '',
7222
+ required: false,
7197
7223
  displayOptions: {
7198
7224
  show: {
7199
7225
  resource: ['stages'],
7200
- operation: ['PublicJobStageController_update'],
7226
+ operation: ['PublicJobStageController_updateFinance'],
7201
7227
  },
7202
7228
  },
7203
7229
  routing: {
7204
7230
  send: {
7205
7231
  type: 'body',
7206
- property: 'schedulingTags.set',
7232
+ property: 'nonBillable',
7207
7233
  },
7208
7234
  },
7209
7235
  },
7210
7236
  {
7211
- displayName: 'Scheduling Tags Add',
7212
- name: 'schedulingTagsAdd',
7213
- type: 'string',
7214
- default: '',
7215
- typeOptions: {
7216
- multipleValues: true,
7217
- },
7237
+ displayName: 'Non Payable',
7238
+ name: 'nonPayable',
7239
+ type: 'boolean',
7240
+ default: false,
7218
7241
  description: '',
7242
+ required: false,
7219
7243
  displayOptions: {
7220
7244
  show: {
7221
7245
  resource: ['stages'],
7222
- operation: ['PublicJobStageController_update'],
7246
+ operation: ['PublicJobStageController_updateFinance'],
7223
7247
  },
7224
7248
  },
7225
7249
  routing: {
7226
7250
  send: {
7227
7251
  type: 'body',
7228
- property: 'schedulingTags.add',
7252
+ property: 'nonPayable',
7229
7253
  },
7230
7254
  },
7231
7255
  },
7232
7256
  {
7233
- displayName: 'Scheduling Tags Remove',
7234
- name: 'schedulingTagsRemove',
7257
+ displayName: 'Note',
7258
+ name: 'note',
7235
7259
  type: 'string',
7236
7260
  default: '',
7237
- typeOptions: {
7238
- multipleValues: true,
7239
- },
7240
7261
  description: '',
7241
- displayOptions: {
7242
- show: {
7243
- resource: ['stages'],
7244
- operation: ['PublicJobStageController_update'],
7245
- },
7246
- },
7247
- routing: {
7248
- send: {
7249
- type: 'body',
7250
- property: 'schedulingTags.remove',
7251
- },
7252
- },
7253
- },
7254
- {
7255
- displayName: 'Custom Fields',
7256
- name: 'customFields',
7257
- type: 'json',
7258
- default: {},
7259
- description: 'Custom fields as key-value pairs — validated against tenant field definitions',
7260
7262
  required: false,
7261
7263
  displayOptions: {
7262
7264
  show: {
7263
7265
  resource: ['stages'],
7264
- operation: ['PublicJobStageController_update'],
7266
+ operation: ['PublicJobStageController_updateFinance'],
7265
7267
  },
7266
7268
  },
7267
7269
  routing: {
7268
7270
  send: {
7269
7271
  type: 'body',
7270
- property: 'customFields',
7271
- },
7272
- },
7273
- },
7274
- {
7275
- displayName: 'Id',
7276
- name: 'id',
7277
- type: 'string',
7278
- default: '',
7279
- description: 'Stage ID',
7280
- required: true,
7281
- displayOptions: {
7282
- show: {
7283
- resource: ['stages'],
7284
- operation: ['PublicJobStageController_delete'],
7272
+ property: 'note',
7285
7273
  },
7286
7274
  },
7287
7275
  },
@@ -29539,30 +29527,30 @@ class WorkBuddy {
29539
29527
  options: [
29540
29528
  {
29541
29529
  name: 'Write an agent run event',
29542
- value: 'PublicApiAgentHarnessController_ingestEvent',
29530
+ value: 'PublicApiExtensionRunsController_ingestEvent',
29543
29531
  action: 'Used by an external agent to report progress, action-required, completed, failed, heartbeat, or message events for an existing run.',
29544
29532
  description: 'Used by an external agent to report progress, action-required, completed, failed, heartbeat, or message events for an existing run.',
29545
29533
  routing: {
29546
29534
  request: {
29547
29535
  method: 'POST',
29548
- url: '/api/v2/public/agent-harness/runs/={{ $parameter["runId"] }}/events',
29536
+ url: '/api/v2/public/extension-runs/={{ $parameter["runId"] }}/events',
29549
29537
  },
29550
29538
  },
29551
29539
  },
29552
29540
  {
29553
29541
  name: 'Resolve an action-required run state',
29554
- value: 'PublicApiAgentHarnessController_resolveAction',
29542
+ value: 'PublicApiExtensionRunsController_resolveAction',
29555
29543
  action: 'Used by an external agent to post the resolution payload for a run that previously entered action-required state.',
29556
29544
  description: 'Used by an external agent to post the resolution payload for a run that previously entered action-required state.',
29557
29545
  routing: {
29558
29546
  request: {
29559
29547
  method: 'POST',
29560
- url: '/api/v2/public/agent-harness/runs/={{ $parameter["runId"] }}/action-resolved',
29548
+ url: '/api/v2/public/extension-runs/={{ $parameter["runId"] }}/action-resolved',
29561
29549
  },
29562
29550
  },
29563
29551
  },
29564
29552
  ],
29565
- default: 'PublicApiAgentHarnessController_ingestEvent',
29553
+ default: 'PublicApiExtensionRunsController_ingestEvent',
29566
29554
  },
29567
29555
  {
29568
29556
  displayName: 'Run Id',
@@ -29574,7 +29562,7 @@ class WorkBuddy {
29574
29562
  displayOptions: {
29575
29563
  show: {
29576
29564
  resource: ['agents'],
29577
- operation: ['PublicApiAgentHarnessController_ingestEvent'],
29565
+ operation: ['PublicApiExtensionRunsController_ingestEvent'],
29578
29566
  },
29579
29567
  },
29580
29568
  },
@@ -29588,7 +29576,7 @@ class WorkBuddy {
29588
29576
  displayOptions: {
29589
29577
  show: {
29590
29578
  resource: ['agents'],
29591
- operation: ['PublicApiAgentHarnessController_ingestEvent'],
29579
+ operation: ['PublicApiExtensionRunsController_ingestEvent'],
29592
29580
  },
29593
29581
  },
29594
29582
  routing: {
@@ -29608,7 +29596,7 @@ class WorkBuddy {
29608
29596
  displayOptions: {
29609
29597
  show: {
29610
29598
  resource: ['agents'],
29611
- operation: ['PublicApiAgentHarnessController_ingestEvent'],
29599
+ operation: ['PublicApiExtensionRunsController_ingestEvent'],
29612
29600
  },
29613
29601
  },
29614
29602
  options: [
@@ -29666,7 +29654,7 @@ class WorkBuddy {
29666
29654
  displayOptions: {
29667
29655
  show: {
29668
29656
  resource: ['agents'],
29669
- operation: ['PublicApiAgentHarnessController_ingestEvent'],
29657
+ operation: ['PublicApiExtensionRunsController_ingestEvent'],
29670
29658
  },
29671
29659
  },
29672
29660
  routing: {
@@ -29686,7 +29674,7 @@ class WorkBuddy {
29686
29674
  displayOptions: {
29687
29675
  show: {
29688
29676
  resource: ['agents'],
29689
- operation: ['PublicApiAgentHarnessController_ingestEvent'],
29677
+ operation: ['PublicApiExtensionRunsController_ingestEvent'],
29690
29678
  },
29691
29679
  },
29692
29680
  routing: {
@@ -29706,7 +29694,7 @@ class WorkBuddy {
29706
29694
  displayOptions: {
29707
29695
  show: {
29708
29696
  resource: ['agents'],
29709
- operation: ['PublicApiAgentHarnessController_resolveAction'],
29697
+ operation: ['PublicApiExtensionRunsController_resolveAction'],
29710
29698
  },
29711
29699
  },
29712
29700
  },
@@ -29720,7 +29708,7 @@ class WorkBuddy {
29720
29708
  displayOptions: {
29721
29709
  show: {
29722
29710
  resource: ['agents'],
29723
- operation: ['PublicApiAgentHarnessController_resolveAction'],
29711
+ operation: ['PublicApiExtensionRunsController_resolveAction'],
29724
29712
  },
29725
29713
  },
29726
29714
  routing: {
@@ -29740,7 +29728,7 @@ class WorkBuddy {
29740
29728
  displayOptions: {
29741
29729
  show: {
29742
29730
  resource: ['agents'],
29743
- operation: ['PublicApiAgentHarnessController_resolveAction'],
29731
+ operation: ['PublicApiExtensionRunsController_resolveAction'],
29744
29732
  },
29745
29733
  },
29746
29734
  routing: {
@@ -30030,6 +30018,18 @@ class WorkBuddy {
30030
30018
  },
30031
30019
  },
30032
30020
  options: [
30021
+ {
30022
+ name: 'List Service Plans',
30023
+ value: 'PublicServicePlanController_list',
30024
+ action: 'Lists plans, including archived plans, with literal name search and zero-based page pagination.',
30025
+ description: 'Lists plans, including archived plans, with literal name search and zero-based page pagination.',
30026
+ routing: {
30027
+ request: {
30028
+ method: 'GET',
30029
+ url: '/api/v2/public/service-plans',
30030
+ },
30031
+ },
30032
+ },
30033
30033
  {
30034
30034
  name: 'Create a Service Plan',
30035
30035
  value: 'PublicServicePlanController_create',
@@ -30054,6 +30054,30 @@ class WorkBuddy {
30054
30054
  },
30055
30055
  },
30056
30056
  },
30057
+ {
30058
+ name: 'Update a Service Plan',
30059
+ value: 'PublicServicePlanController_patch',
30060
+ action: 'Edits definition fields and Job defaults while Draft or Paused. Dates must preserve descendant bounds. Empty blackoutRanges clears closures; null dateEnd removes the end date. Null clears a Job default; omitted fields remain unchanged. Customer/site identity and lifecycle fields are not writable here.',
30061
+ description: 'Edits definition fields and Job defaults while Draft or Paused. Dates must preserve descendant bounds. Empty blackoutRanges clears closures; null dateEnd removes the end date. Null clears a Job default; omitted fields remain unchanged. Customer/site identity and lifecycle fields are not writable here.',
30062
+ routing: {
30063
+ request: {
30064
+ method: 'PATCH',
30065
+ url: '/api/v2/public/service-plans/={{ $parameter["identifier"] }}',
30066
+ },
30067
+ },
30068
+ },
30069
+ {
30070
+ name: 'Delete a Service Plan',
30071
+ value: 'PublicServicePlanController_delete',
30072
+ action: 'Deletes a plan and its definitions only when the existing domain operational-history guard permits it. Archive plans with history instead.',
30073
+ description: 'Deletes a plan and its definitions only when the existing domain operational-history guard permits it. Archive plans with history instead.',
30074
+ routing: {
30075
+ request: {
30076
+ method: 'DELETE',
30077
+ url: '/api/v2/public/service-plans/={{ $parameter["identifier"] }}',
30078
+ },
30079
+ },
30080
+ },
30057
30081
  {
30058
30082
  name: 'Start a Service Plan',
30059
30083
  value: 'PublicServicePlanController_activate',
@@ -30069,8 +30093,8 @@ class WorkBuddy {
30069
30093
  {
30070
30094
  name: 'Pause a Service Plan',
30071
30095
  value: 'PublicServicePlanController_suspend',
30072
- action: 'Stops future scheduled work while preserving history.',
30073
- description: 'Stops future scheduled work while preserving history.',
30096
+ action: 'Stops future scheduled work while preserving history. Returns execution impact beside data: existing generated Jobs and booked Visits are not cancelled.',
30097
+ description: 'Stops future scheduled work while preserving history. Returns execution impact beside data: existing generated Jobs and booked Visits are not cancelled.',
30074
30098
  routing: {
30075
30099
  request: {
30076
30100
  method: 'POST',
@@ -30090,8 +30114,83 @@ class WorkBuddy {
30090
30114
  },
30091
30115
  },
30092
30116
  },
30117
+ {
30118
+ name: 'Restore a Service Plan',
30119
+ value: 'PublicServicePlanController_restore',
30120
+ action: 'Restores an archived plan to Paused. Starting it remains a separate activate action.',
30121
+ description: 'Restores an archived plan to Paused. Starting it remains a separate activate action.',
30122
+ routing: {
30123
+ request: {
30124
+ method: 'POST',
30125
+ url: '/api/v2/public/service-plans/={{ $parameter["identifier"] }}/restore',
30126
+ },
30127
+ },
30128
+ },
30093
30129
  ],
30094
- default: 'PublicServicePlanController_create',
30130
+ default: 'PublicServicePlanController_list',
30131
+ },
30132
+ {
30133
+ displayName: 'Search',
30134
+ name: 'search',
30135
+ type: 'string',
30136
+ default: '',
30137
+ description: 'Literal case-insensitive name search',
30138
+ required: false,
30139
+ displayOptions: {
30140
+ show: {
30141
+ resource: ['service-plans'],
30142
+ operation: ['PublicServicePlanController_list'],
30143
+ },
30144
+ },
30145
+ routing: {
30146
+ request: {
30147
+ qs: {
30148
+ search: '={{$value}}',
30149
+ },
30150
+ },
30151
+ },
30152
+ },
30153
+ {
30154
+ displayName: 'Page Size',
30155
+ name: 'pageSize',
30156
+ type: 'number',
30157
+ default: '',
30158
+ description: 'Results per page, 1–200 (default 50)',
30159
+ required: false,
30160
+ displayOptions: {
30161
+ show: {
30162
+ resource: ['service-plans'],
30163
+ operation: ['PublicServicePlanController_list'],
30164
+ },
30165
+ },
30166
+ routing: {
30167
+ request: {
30168
+ qs: {
30169
+ pageSize: '={{$value}}',
30170
+ },
30171
+ },
30172
+ },
30173
+ },
30174
+ {
30175
+ displayName: 'Page',
30176
+ name: 'page',
30177
+ type: 'number',
30178
+ default: '',
30179
+ description: 'Zero-based page (default 0, maximum 100000)',
30180
+ required: false,
30181
+ displayOptions: {
30182
+ show: {
30183
+ resource: ['service-plans'],
30184
+ operation: ['PublicServicePlanController_list'],
30185
+ },
30186
+ },
30187
+ routing: {
30188
+ request: {
30189
+ qs: {
30190
+ page: '={{$value}}',
30191
+ },
30192
+ },
30193
+ },
30095
30194
  },
30096
30195
  {
30097
30196
  displayName: 'Integration Id',
@@ -30199,6 +30298,26 @@ class WorkBuddy {
30199
30298
  },
30200
30299
  },
30201
30300
  },
30301
+ {
30302
+ displayName: 'Description',
30303
+ name: 'description',
30304
+ type: 'string',
30305
+ default: '',
30306
+ description: 'Detailed description',
30307
+ required: false,
30308
+ displayOptions: {
30309
+ show: {
30310
+ resource: ['service-plans'],
30311
+ operation: ['PublicServicePlanController_create'],
30312
+ },
30313
+ },
30314
+ routing: {
30315
+ send: {
30316
+ type: 'body',
30317
+ property: 'description',
30318
+ },
30319
+ },
30320
+ },
30202
30321
  {
30203
30322
  displayName: 'Date End',
30204
30323
  name: 'dateEnd',
@@ -30269,6 +30388,46 @@ class WorkBuddy {
30269
30388
  },
30270
30389
  },
30271
30390
  },
30391
+ {
30392
+ displayName: 'Blackout Ranges',
30393
+ name: 'blackoutRanges',
30394
+ type: 'json',
30395
+ default: {},
30396
+ description: '',
30397
+ required: false,
30398
+ displayOptions: {
30399
+ show: {
30400
+ resource: ['service-plans'],
30401
+ operation: ['PublicServicePlanController_create'],
30402
+ },
30403
+ },
30404
+ routing: {
30405
+ send: {
30406
+ type: 'body',
30407
+ property: 'blackoutRanges',
30408
+ },
30409
+ },
30410
+ },
30411
+ {
30412
+ displayName: 'Job Defaults',
30413
+ name: 'jobDefaults',
30414
+ type: 'string',
30415
+ default: '',
30416
+ description: '',
30417
+ required: false,
30418
+ displayOptions: {
30419
+ show: {
30420
+ resource: ['service-plans'],
30421
+ operation: ['PublicServicePlanController_create'],
30422
+ },
30423
+ },
30424
+ routing: {
30425
+ send: {
30426
+ type: 'body',
30427
+ property: 'jobDefaults',
30428
+ },
30429
+ },
30430
+ },
30272
30431
  {
30273
30432
  displayName: 'Identifier',
30274
30433
  name: 'identifier',
@@ -30283,6 +30442,204 @@ class WorkBuddy {
30283
30442
  },
30284
30443
  },
30285
30444
  },
30445
+ {
30446
+ displayName: 'Identifier',
30447
+ name: 'identifier',
30448
+ type: 'string',
30449
+ default: '',
30450
+ description: 'WorkBuddy Service Plan ID or caller integrationId',
30451
+ required: true,
30452
+ displayOptions: {
30453
+ show: {
30454
+ resource: ['service-plans'],
30455
+ operation: ['PublicServicePlanController_patch'],
30456
+ },
30457
+ },
30458
+ },
30459
+ {
30460
+ displayName: 'Name',
30461
+ name: 'name',
30462
+ type: 'string',
30463
+ default: '',
30464
+ description: 'Display name',
30465
+ required: false,
30466
+ displayOptions: {
30467
+ show: {
30468
+ resource: ['service-plans'],
30469
+ operation: ['PublicServicePlanController_patch'],
30470
+ },
30471
+ },
30472
+ routing: {
30473
+ send: {
30474
+ type: 'body',
30475
+ property: 'name',
30476
+ },
30477
+ },
30478
+ },
30479
+ {
30480
+ displayName: 'Description',
30481
+ name: 'description',
30482
+ type: 'string',
30483
+ default: '',
30484
+ description: 'Detailed description',
30485
+ required: false,
30486
+ displayOptions: {
30487
+ show: {
30488
+ resource: ['service-plans'],
30489
+ operation: ['PublicServicePlanController_patch'],
30490
+ },
30491
+ },
30492
+ routing: {
30493
+ send: {
30494
+ type: 'body',
30495
+ property: 'description',
30496
+ },
30497
+ },
30498
+ },
30499
+ {
30500
+ displayName: 'Job Defaults',
30501
+ name: 'jobDefaults',
30502
+ type: 'string',
30503
+ default: '',
30504
+ description: '',
30505
+ required: false,
30506
+ displayOptions: {
30507
+ show: {
30508
+ resource: ['service-plans'],
30509
+ operation: ['PublicServicePlanController_patch'],
30510
+ },
30511
+ },
30512
+ routing: {
30513
+ send: {
30514
+ type: 'body',
30515
+ property: 'jobDefaults',
30516
+ },
30517
+ },
30518
+ },
30519
+ {
30520
+ displayName: 'Date Start',
30521
+ name: 'dateStart',
30522
+ type: 'string',
30523
+ default: '',
30524
+ description: '',
30525
+ required: false,
30526
+ displayOptions: {
30527
+ show: {
30528
+ resource: ['service-plans'],
30529
+ operation: ['PublicServicePlanController_patch'],
30530
+ },
30531
+ },
30532
+ routing: {
30533
+ send: {
30534
+ type: 'body',
30535
+ property: 'dateStart',
30536
+ },
30537
+ },
30538
+ },
30539
+ {
30540
+ displayName: 'Date End',
30541
+ name: 'dateEnd',
30542
+ type: 'string',
30543
+ default: '',
30544
+ description: '',
30545
+ required: false,
30546
+ displayOptions: {
30547
+ show: {
30548
+ resource: ['service-plans'],
30549
+ operation: ['PublicServicePlanController_patch'],
30550
+ },
30551
+ },
30552
+ routing: {
30553
+ send: {
30554
+ type: 'body',
30555
+ property: 'dateEnd',
30556
+ },
30557
+ },
30558
+ },
30559
+ {
30560
+ displayName: 'Working Days',
30561
+ name: 'workingDays',
30562
+ type: 'multiOptions',
30563
+ default: '',
30564
+ description: '',
30565
+ required: false,
30566
+ displayOptions: {
30567
+ show: {
30568
+ resource: ['service-plans'],
30569
+ operation: ['PublicServicePlanController_patch'],
30570
+ },
30571
+ },
30572
+ options: [
30573
+ {
30574
+ name: 'Mon',
30575
+ value: 'Mon',
30576
+ },
30577
+ {
30578
+ name: 'Tue',
30579
+ value: 'Tue',
30580
+ },
30581
+ {
30582
+ name: 'Wed',
30583
+ value: 'Wed',
30584
+ },
30585
+ {
30586
+ name: 'Thu',
30587
+ value: 'Thu',
30588
+ },
30589
+ {
30590
+ name: 'Fri',
30591
+ value: 'Fri',
30592
+ },
30593
+ {
30594
+ name: 'Sat',
30595
+ value: 'Sat',
30596
+ },
30597
+ {
30598
+ name: 'Sun',
30599
+ value: 'Sun',
30600
+ },
30601
+ ],
30602
+ routing: {
30603
+ send: {
30604
+ type: 'body',
30605
+ property: 'workingDays',
30606
+ },
30607
+ },
30608
+ },
30609
+ {
30610
+ displayName: 'Blackout Ranges',
30611
+ name: 'blackoutRanges',
30612
+ type: 'json',
30613
+ default: {},
30614
+ description: '',
30615
+ required: false,
30616
+ displayOptions: {
30617
+ show: {
30618
+ resource: ['service-plans'],
30619
+ operation: ['PublicServicePlanController_patch'],
30620
+ },
30621
+ },
30622
+ routing: {
30623
+ send: {
30624
+ type: 'body',
30625
+ property: 'blackoutRanges',
30626
+ },
30627
+ },
30628
+ },
30629
+ {
30630
+ displayName: 'Identifier',
30631
+ name: 'identifier',
30632
+ type: 'string',
30633
+ default: '',
30634
+ description: 'WorkBuddy Service Plan ID or caller integrationId',
30635
+ required: true,
30636
+ displayOptions: {
30637
+ show: {
30638
+ resource: ['service-plans'],
30639
+ operation: ['PublicServicePlanController_delete'],
30640
+ },
30641
+ },
30642
+ },
30286
30643
  {
30287
30644
  displayName: 'Identifier',
30288
30645
  name: 'identifier',
@@ -30385,6 +30742,40 @@ class WorkBuddy {
30385
30742
  },
30386
30743
  },
30387
30744
  },
30745
+ {
30746
+ displayName: 'Identifier',
30747
+ name: 'identifier',
30748
+ type: 'string',
30749
+ default: '',
30750
+ description: 'WorkBuddy Service Plan ID or caller integrationId',
30751
+ required: true,
30752
+ displayOptions: {
30753
+ show: {
30754
+ resource: ['service-plans'],
30755
+ operation: ['PublicServicePlanController_restore'],
30756
+ },
30757
+ },
30758
+ },
30759
+ {
30760
+ displayName: 'Reason',
30761
+ name: 'reason',
30762
+ type: 'string',
30763
+ default: '',
30764
+ description: 'Reason for the action (e.g. cancellation reason)',
30765
+ required: false,
30766
+ displayOptions: {
30767
+ show: {
30768
+ resource: ['service-plans'],
30769
+ operation: ['PublicServicePlanController_restore'],
30770
+ },
30771
+ },
30772
+ routing: {
30773
+ send: {
30774
+ type: 'body',
30775
+ property: 'reason',
30776
+ },
30777
+ },
30778
+ },
30388
30779
  // Service Plans Lines Operations
30389
30780
  {
30390
30781
  displayName: 'Operation',
@@ -30445,6 +30836,18 @@ class WorkBuddy {
30445
30836
  },
30446
30837
  },
30447
30838
  },
30839
+ {
30840
+ name: 'Delete a Service Line',
30841
+ value: 'PublicServiceLineController_delete',
30842
+ action: 'Deletes the line and its Task, Subtask and planned-item definitions using existing domain cascade rules. Started plans remain read-only.',
30843
+ description: 'Deletes the line and its Task, Subtask and planned-item definitions using existing domain cascade rules. Started plans remain read-only.',
30844
+ routing: {
30845
+ request: {
30846
+ method: 'DELETE',
30847
+ url: '/api/v2/public/service-plans/={{ $parameter["planId"] }}/lines/={{ $parameter["identifier"] }}',
30848
+ },
30849
+ },
30850
+ },
30448
30851
  ],
30449
30852
  default: 'PublicServiceLineController_list',
30450
30853
  },
@@ -30662,7 +31065,7 @@ class WorkBuddy {
30662
31065
  {
30663
31066
  displayName: 'Working Days',
30664
31067
  name: 'workingDays',
30665
- type: 'multiOptions',
31068
+ type: 'string',
30666
31069
  default: '',
30667
31070
  description: '',
30668
31071
  required: false,
@@ -30672,40 +31075,113 @@ class WorkBuddy {
30672
31075
  operation: ['PublicServiceLineController_create'],
30673
31076
  },
30674
31077
  },
30675
- options: [
30676
- {
30677
- name: 'Mon',
30678
- value: 'Mon',
31078
+ routing: {
31079
+ send: {
31080
+ type: 'body',
31081
+ property: 'workingDays',
30679
31082
  },
30680
- {
30681
- name: 'Tue',
30682
- value: 'Tue',
31083
+ },
31084
+ },
31085
+ {
31086
+ displayName: 'Blackout Ranges',
31087
+ name: 'blackoutRanges',
31088
+ type: 'json',
31089
+ default: {},
31090
+ description: '',
31091
+ required: false,
31092
+ displayOptions: {
31093
+ show: {
31094
+ resource: ['service-plans-lines'],
31095
+ operation: ['PublicServiceLineController_create'],
30683
31096
  },
30684
- {
30685
- name: 'Wed',
30686
- value: 'Wed',
31097
+ },
31098
+ routing: {
31099
+ send: {
31100
+ type: 'body',
31101
+ property: 'blackoutRanges',
30687
31102
  },
30688
- {
30689
- name: 'Thu',
30690
- value: 'Thu',
31103
+ },
31104
+ },
31105
+ {
31106
+ displayName: 'Owner Id',
31107
+ name: 'ownerId',
31108
+ type: 'options',
31109
+ default: '',
31110
+ description: 'Owner (employee) ID — use /crm/employees to look up',
31111
+ required: false,
31112
+ displayOptions: {
31113
+ show: {
31114
+ resource: ['service-plans-lines'],
31115
+ operation: ['PublicServiceLineController_create'],
30691
31116
  },
30692
- {
30693
- name: 'Fri',
30694
- value: 'Fri',
31117
+ },
31118
+ typeOptions: {
31119
+ loadOptionsMethod: 'loadEmployeeOptions',
31120
+ },
31121
+ routing: {
31122
+ send: {
31123
+ type: 'body',
31124
+ property: 'ownerId',
30695
31125
  },
30696
- {
30697
- name: 'Sat',
30698
- value: 'Sat',
31126
+ },
31127
+ },
31128
+ {
31129
+ displayName: 'Requires Approval',
31130
+ name: 'requiresApproval',
31131
+ type: 'boolean',
31132
+ default: false,
31133
+ description: '',
31134
+ required: false,
31135
+ displayOptions: {
31136
+ show: {
31137
+ resource: ['service-plans-lines'],
31138
+ operation: ['PublicServiceLineController_create'],
30699
31139
  },
30700
- {
30701
- name: 'Sun',
30702
- value: 'Sun',
31140
+ },
31141
+ routing: {
31142
+ send: {
31143
+ type: 'body',
31144
+ property: 'requiresApproval',
30703
31145
  },
30704
- ],
31146
+ },
31147
+ },
31148
+ {
31149
+ displayName: 'Overdue Grace Days',
31150
+ name: 'overdueGraceDays',
31151
+ type: 'string',
31152
+ default: '',
31153
+ description: '',
31154
+ required: false,
31155
+ displayOptions: {
31156
+ show: {
31157
+ resource: ['service-plans-lines'],
31158
+ operation: ['PublicServiceLineController_create'],
31159
+ },
31160
+ },
30705
31161
  routing: {
30706
31162
  send: {
30707
31163
  type: 'body',
30708
- property: 'workingDays',
31164
+ property: 'overdueGraceDays',
31165
+ },
31166
+ },
31167
+ },
31168
+ {
31169
+ displayName: 'Job Change Cutoff Minutes',
31170
+ name: 'jobChangeCutoffMinutes',
31171
+ type: 'string',
31172
+ default: '',
31173
+ description: '',
31174
+ required: false,
31175
+ displayOptions: {
31176
+ show: {
31177
+ resource: ['service-plans-lines'],
31178
+ operation: ['PublicServiceLineController_create'],
31179
+ },
31180
+ },
31181
+ routing: {
31182
+ send: {
31183
+ type: 'body',
31184
+ property: 'jobChangeCutoffMinutes',
30709
31185
  },
30710
31186
  },
30711
31187
  },
@@ -31020,7 +31496,7 @@ class WorkBuddy {
31020
31496
  {
31021
31497
  displayName: 'Working Days',
31022
31498
  name: 'workingDays',
31023
- type: 'multiOptions',
31499
+ type: 'string',
31024
31500
  default: '',
31025
31501
  description: '',
31026
31502
  required: false,
@@ -31030,40 +31506,113 @@ class WorkBuddy {
31030
31506
  operation: ['PublicServiceLineController_patch'],
31031
31507
  },
31032
31508
  },
31033
- options: [
31034
- {
31035
- name: 'Mon',
31036
- value: 'Mon',
31509
+ routing: {
31510
+ send: {
31511
+ type: 'body',
31512
+ property: 'workingDays',
31037
31513
  },
31038
- {
31039
- name: 'Tue',
31040
- value: 'Tue',
31514
+ },
31515
+ },
31516
+ {
31517
+ displayName: 'Blackout Ranges',
31518
+ name: 'blackoutRanges',
31519
+ type: 'json',
31520
+ default: {},
31521
+ description: '',
31522
+ required: false,
31523
+ displayOptions: {
31524
+ show: {
31525
+ resource: ['service-plans-lines'],
31526
+ operation: ['PublicServiceLineController_patch'],
31041
31527
  },
31042
- {
31043
- name: 'Wed',
31044
- value: 'Wed',
31528
+ },
31529
+ routing: {
31530
+ send: {
31531
+ type: 'body',
31532
+ property: 'blackoutRanges',
31045
31533
  },
31046
- {
31047
- name: 'Thu',
31048
- value: 'Thu',
31534
+ },
31535
+ },
31536
+ {
31537
+ displayName: 'Owner Id',
31538
+ name: 'ownerId',
31539
+ type: 'options',
31540
+ default: '',
31541
+ description: 'Owner (employee) ID — use /crm/employees to look up',
31542
+ required: false,
31543
+ displayOptions: {
31544
+ show: {
31545
+ resource: ['service-plans-lines'],
31546
+ operation: ['PublicServiceLineController_patch'],
31049
31547
  },
31050
- {
31051
- name: 'Fri',
31052
- value: 'Fri',
31548
+ },
31549
+ typeOptions: {
31550
+ loadOptionsMethod: 'loadEmployeeOptions',
31551
+ },
31552
+ routing: {
31553
+ send: {
31554
+ type: 'body',
31555
+ property: 'ownerId',
31053
31556
  },
31054
- {
31055
- name: 'Sat',
31056
- value: 'Sat',
31557
+ },
31558
+ },
31559
+ {
31560
+ displayName: 'Requires Approval',
31561
+ name: 'requiresApproval',
31562
+ type: 'boolean',
31563
+ default: false,
31564
+ description: '',
31565
+ required: false,
31566
+ displayOptions: {
31567
+ show: {
31568
+ resource: ['service-plans-lines'],
31569
+ operation: ['PublicServiceLineController_patch'],
31057
31570
  },
31058
- {
31059
- name: 'Sun',
31060
- value: 'Sun',
31571
+ },
31572
+ routing: {
31573
+ send: {
31574
+ type: 'body',
31575
+ property: 'requiresApproval',
31061
31576
  },
31062
- ],
31577
+ },
31578
+ },
31579
+ {
31580
+ displayName: 'Overdue Grace Days',
31581
+ name: 'overdueGraceDays',
31582
+ type: 'string',
31583
+ default: '',
31584
+ description: '',
31585
+ required: false,
31586
+ displayOptions: {
31587
+ show: {
31588
+ resource: ['service-plans-lines'],
31589
+ operation: ['PublicServiceLineController_patch'],
31590
+ },
31591
+ },
31063
31592
  routing: {
31064
31593
  send: {
31065
31594
  type: 'body',
31066
- property: 'workingDays',
31595
+ property: 'overdueGraceDays',
31596
+ },
31597
+ },
31598
+ },
31599
+ {
31600
+ displayName: 'Job Change Cutoff Minutes',
31601
+ name: 'jobChangeCutoffMinutes',
31602
+ type: 'string',
31603
+ default: '',
31604
+ description: '',
31605
+ required: false,
31606
+ displayOptions: {
31607
+ show: {
31608
+ resource: ['service-plans-lines'],
31609
+ operation: ['PublicServiceLineController_patch'],
31610
+ },
31611
+ },
31612
+ routing: {
31613
+ send: {
31614
+ type: 'body',
31615
+ property: 'jobChangeCutoffMinutes',
31067
31616
  },
31068
31617
  },
31069
31618
  },
@@ -31156,6 +31705,34 @@ class WorkBuddy {
31156
31705
  },
31157
31706
  },
31158
31707
  },
31708
+ {
31709
+ displayName: 'Plan Id',
31710
+ name: 'planId',
31711
+ type: 'string',
31712
+ default: '',
31713
+ description: 'WorkBuddy Service Plan ID',
31714
+ required: true,
31715
+ displayOptions: {
31716
+ show: {
31717
+ resource: ['service-plans-lines'],
31718
+ operation: ['PublicServiceLineController_delete'],
31719
+ },
31720
+ },
31721
+ },
31722
+ {
31723
+ displayName: 'Identifier',
31724
+ name: 'identifier',
31725
+ type: 'string',
31726
+ default: '',
31727
+ description: 'WorkBuddy Service Line ID or caller integrationId',
31728
+ required: true,
31729
+ displayOptions: {
31730
+ show: {
31731
+ resource: ['service-plans-lines'],
31732
+ operation: ['PublicServiceLineController_delete'],
31733
+ },
31734
+ },
31735
+ },
31159
31736
  // Service Plans Lines Tasks Operations
31160
31737
  {
31161
31738
  displayName: 'Operation',
@@ -31216,6 +31793,18 @@ class WorkBuddy {
31216
31793
  },
31217
31794
  },
31218
31795
  },
31796
+ {
31797
+ name: 'Delete a root Service Line Task',
31798
+ value: 'PublicServiceLineTaskController_delete',
31799
+ action: 'Deletes the standing Task subtree and lets the existing domain clean up associated items, Visit exceptions and projections. This is not a Visit-specific exclusion.',
31800
+ description: 'Deletes the standing Task subtree and lets the existing domain clean up associated items, Visit exceptions and projections. This is not a Visit-specific exclusion.',
31801
+ routing: {
31802
+ request: {
31803
+ method: 'DELETE',
31804
+ url: '/api/v2/public/service-plans/={{ $parameter["planId"] }}/lines/={{ $parameter["lineId"] }}/tasks/={{ $parameter["identifier"] }}',
31805
+ },
31806
+ },
31807
+ },
31219
31808
  ],
31220
31809
  default: 'PublicServiceLineTaskController_list',
31221
31810
  },
@@ -31482,8 +32071,8 @@ class WorkBuddy {
31482
32071
  {
31483
32072
  displayName: 'Exceptions',
31484
32073
  name: 'exceptions',
31485
- type: 'json',
31486
- default: {},
32074
+ type: 'string',
32075
+ default: '',
31487
32076
  description: '',
31488
32077
  required: false,
31489
32078
  displayOptions: {
@@ -31889,6 +32478,48 @@ class WorkBuddy {
31889
32478
  },
31890
32479
  },
31891
32480
  },
32481
+ {
32482
+ displayName: 'Plan Id',
32483
+ name: 'planId',
32484
+ type: 'string',
32485
+ default: '',
32486
+ description: 'WorkBuddy Service Plan ID',
32487
+ required: true,
32488
+ displayOptions: {
32489
+ show: {
32490
+ resource: ['service-plans-lines-tasks'],
32491
+ operation: ['PublicServiceLineTaskController_delete'],
32492
+ },
32493
+ },
32494
+ },
32495
+ {
32496
+ displayName: 'Line Id',
32497
+ name: 'lineId',
32498
+ type: 'string',
32499
+ default: '',
32500
+ description: 'WorkBuddy Service Line ID or caller integrationId',
32501
+ required: true,
32502
+ displayOptions: {
32503
+ show: {
32504
+ resource: ['service-plans-lines-tasks'],
32505
+ operation: ['PublicServiceLineTaskController_delete'],
32506
+ },
32507
+ },
32508
+ },
32509
+ {
32510
+ displayName: 'Identifier',
32511
+ name: 'identifier',
32512
+ type: 'string',
32513
+ default: '',
32514
+ description: 'WorkBuddy root Task ID or caller integrationId',
32515
+ required: true,
32516
+ displayOptions: {
32517
+ show: {
32518
+ resource: ['service-plans-lines-tasks'],
32519
+ operation: ['PublicServiceLineTaskController_delete'],
32520
+ },
32521
+ },
32522
+ },
31892
32523
  // Service Plans Lines Tasks Subtasks Operations
31893
32524
  {
31894
32525
  displayName: 'Operation',
@@ -31949,6 +32580,18 @@ class WorkBuddy {
31949
32580
  },
31950
32581
  },
31951
32582
  },
32583
+ {
32584
+ name: 'Delete a Subtask',
32585
+ value: 'PublicServiceLineSubtaskController_delete',
32586
+ action: 'Deletes this standing Subtask and any descendants through the existing domain cascade. The root Task remains unchanged.',
32587
+ description: 'Deletes this standing Subtask and any descendants through the existing domain cascade. The root Task remains unchanged.',
32588
+ routing: {
32589
+ request: {
32590
+ method: 'DELETE',
32591
+ url: '/api/v2/public/service-plans/={{ $parameter["planId"] }}/lines/={{ $parameter["lineId"] }}/tasks/={{ $parameter["taskId"] }}/subtasks/={{ $parameter["identifier"] }}',
32592
+ },
32593
+ },
32594
+ },
31952
32595
  ],
31953
32596
  default: 'PublicServiceLineSubtaskController_list',
31954
32597
  },
@@ -32598,6 +33241,2365 @@ class WorkBuddy {
32598
33241
  },
32599
33242
  },
32600
33243
  },
33244
+ {
33245
+ displayName: 'Plan Id',
33246
+ name: 'planId',
33247
+ type: 'string',
33248
+ default: '',
33249
+ description: 'WorkBuddy Service Plan ID',
33250
+ required: true,
33251
+ displayOptions: {
33252
+ show: {
33253
+ resource: ['service-plans-lines-tasks-subtasks'],
33254
+ operation: ['PublicServiceLineSubtaskController_delete'],
33255
+ },
33256
+ },
33257
+ },
33258
+ {
33259
+ displayName: 'Line Id',
33260
+ name: 'lineId',
33261
+ type: 'string',
33262
+ default: '',
33263
+ description: 'WorkBuddy Service Line ID or caller integrationId',
33264
+ required: true,
33265
+ displayOptions: {
33266
+ show: {
33267
+ resource: ['service-plans-lines-tasks-subtasks'],
33268
+ operation: ['PublicServiceLineSubtaskController_delete'],
33269
+ },
33270
+ },
33271
+ },
33272
+ {
33273
+ displayName: 'Task Id',
33274
+ name: 'taskId',
33275
+ type: 'string',
33276
+ default: '',
33277
+ description: 'WorkBuddy root Task ID or caller integrationId',
33278
+ required: true,
33279
+ displayOptions: {
33280
+ show: {
33281
+ resource: ['service-plans-lines-tasks-subtasks'],
33282
+ operation: ['PublicServiceLineSubtaskController_delete'],
33283
+ },
33284
+ },
33285
+ },
33286
+ {
33287
+ displayName: 'Identifier',
33288
+ name: 'identifier',
33289
+ type: 'string',
33290
+ default: '',
33291
+ description: 'WorkBuddy Subtask ID or caller integrationId',
33292
+ required: true,
33293
+ displayOptions: {
33294
+ show: {
33295
+ resource: ['service-plans-lines-tasks-subtasks'],
33296
+ operation: ['PublicServiceLineSubtaskController_delete'],
33297
+ },
33298
+ },
33299
+ },
33300
+ // Sales Leads Operations
33301
+ {
33302
+ displayName: 'Operation',
33303
+ name: 'operation',
33304
+ type: 'options',
33305
+ noDataExpression: true,
33306
+ displayOptions: {
33307
+ show: {
33308
+ resource: ['sales-leads'],
33309
+ },
33310
+ },
33311
+ options: [
33312
+ {
33313
+ name: 'List leads',
33314
+ value: 'PublicLeadController_list',
33315
+ action: '',
33316
+ description: '',
33317
+ routing: {
33318
+ request: {
33319
+ method: 'GET',
33320
+ url: '/api/v2/public/leads',
33321
+ },
33322
+ },
33323
+ },
33324
+ {
33325
+ name: 'Create lead',
33326
+ value: 'PublicLeadController_create',
33327
+ action: 'Account name, email, phone and contact first/last names are required, as in the UI. Address is optional until conversion.',
33328
+ description: 'Account name, email, phone and contact first/last names are required, as in the UI. Address is optional until conversion.',
33329
+ routing: {
33330
+ request: {
33331
+ method: 'POST',
33332
+ url: '/api/v2/public/leads',
33333
+ },
33334
+ },
33335
+ },
33336
+ {
33337
+ name: 'Get lead',
33338
+ value: 'PublicLeadController_get',
33339
+ action: '',
33340
+ description: '',
33341
+ routing: {
33342
+ request: {
33343
+ method: 'GET',
33344
+ url: '/api/v2/public/leads/={{ $parameter["id"] }}',
33345
+ },
33346
+ },
33347
+ },
33348
+ {
33349
+ name: 'Update lead',
33350
+ value: 'PublicLeadController_update',
33351
+ action: 'Account/contact members merge into their stored snapshots, as in the legacy pipeline. Qualify a lead with the convert operation rather than writing Qualified.',
33352
+ description: 'Account/contact members merge into their stored snapshots, as in the legacy pipeline. Qualify a lead with the convert operation rather than writing Qualified.',
33353
+ routing: {
33354
+ request: {
33355
+ method: 'PATCH',
33356
+ url: '/api/v2/public/leads/={{ $parameter["id"] }}',
33357
+ },
33358
+ },
33359
+ },
33360
+ {
33361
+ name: 'Convert lead',
33362
+ value: 'PublicLeadController_convert',
33363
+ action: 'Creates a CRM customer and optionally an opportunity. Requires leads:write and customer-create permission (crm:write for application tokens). User-linked tokens remain restricted to their user rights. Uses the current Lead address unless one is supplied.',
33364
+ description: 'Creates a CRM customer and optionally an opportunity. Requires leads:write and customer-create permission (crm:write for application tokens). User-linked tokens remain restricted to their user rights. Uses the current Lead address unless one is supplied.',
33365
+ routing: {
33366
+ request: {
33367
+ method: 'POST',
33368
+ url: '/api/v2/public/leads/={{ $parameter["id"] }}/convert',
33369
+ },
33370
+ },
33371
+ },
33372
+ ],
33373
+ default: 'PublicLeadController_list',
33374
+ },
33375
+ {
33376
+ displayName: 'Stage',
33377
+ name: 'stage',
33378
+ type: 'options',
33379
+ default: '',
33380
+ description: '',
33381
+ required: false,
33382
+ displayOptions: {
33383
+ show: {
33384
+ resource: ['sales-leads'],
33385
+ operation: ['PublicLeadController_list'],
33386
+ },
33387
+ },
33388
+ routing: {
33389
+ request: {
33390
+ qs: {
33391
+ stage: '={{$value}}',
33392
+ },
33393
+ },
33394
+ },
33395
+ options: [
33396
+ {
33397
+ name: 'New',
33398
+ value: 'New',
33399
+ },
33400
+ {
33401
+ name: 'In Progress',
33402
+ value: 'In Progress',
33403
+ },
33404
+ {
33405
+ name: 'Qualified',
33406
+ value: 'Qualified',
33407
+ },
33408
+ {
33409
+ name: 'Disqualified',
33410
+ value: 'Disqualified',
33411
+ },
33412
+ ],
33413
+ },
33414
+ {
33415
+ displayName: 'Search',
33416
+ name: 'search',
33417
+ type: 'string',
33418
+ default: '',
33419
+ description: 'Search Lead name, prospect account name or account email.',
33420
+ required: false,
33421
+ displayOptions: {
33422
+ show: {
33423
+ resource: ['sales-leads'],
33424
+ operation: ['PublicLeadController_list'],
33425
+ },
33426
+ },
33427
+ routing: {
33428
+ request: {
33429
+ qs: {
33430
+ search: '={{$value}}',
33431
+ },
33432
+ },
33433
+ },
33434
+ },
33435
+ {
33436
+ displayName: 'Cursor',
33437
+ name: 'cursor',
33438
+ type: 'string',
33439
+ default: '',
33440
+ description: '',
33441
+ required: false,
33442
+ displayOptions: {
33443
+ show: {
33444
+ resource: ['sales-leads'],
33445
+ operation: ['PublicLeadController_list'],
33446
+ },
33447
+ },
33448
+ routing: {
33449
+ request: {
33450
+ qs: {
33451
+ cursor: '={{$value}}',
33452
+ },
33453
+ },
33454
+ },
33455
+ },
33456
+ {
33457
+ displayName: 'Limit',
33458
+ name: 'limit',
33459
+ type: 'number',
33460
+ default: 50,
33461
+ description: 'Page size, from 1 to 200. Defaults to 50.',
33462
+ required: false,
33463
+ displayOptions: {
33464
+ show: {
33465
+ resource: ['sales-leads'],
33466
+ operation: ['PublicLeadController_list'],
33467
+ },
33468
+ },
33469
+ routing: {
33470
+ request: {
33471
+ qs: {
33472
+ limit: '={{$value}}',
33473
+ },
33474
+ },
33475
+ },
33476
+ },
33477
+ {
33478
+ displayName: 'Account',
33479
+ name: 'account',
33480
+ type: 'collection',
33481
+ default: {},
33482
+ placeholder: 'Add Account',
33483
+ description: 'Typed-in prospect account details. Updates merge supplied members into the stored snapshot.',
33484
+ required: true,
33485
+ displayOptions: {
33486
+ show: {
33487
+ resource: ['sales-leads'],
33488
+ operation: ['PublicLeadController_create'],
33489
+ },
33490
+ },
33491
+ options: [
33492
+ {
33493
+ displayName: 'Name',
33494
+ name: 'name',
33495
+ type: 'string',
33496
+ default: '',
33497
+ description: 'Prospect account name. Also supplies the Lead display name; this is not an existing CRM account reference.',
33498
+ },
33499
+ {
33500
+ displayName: 'Type',
33501
+ name: 'type',
33502
+ type: 'options',
33503
+ default: '',
33504
+ description: 'Customer account type used when qualifying the Lead. Defaults to Business when not otherwise specified.',
33505
+ options: [
33506
+ {
33507
+ name: 'Business',
33508
+ value: 'Business',
33509
+ },
33510
+ {
33511
+ name: 'Individual',
33512
+ value: 'Individual',
33513
+ },
33514
+ ],
33515
+ },
33516
+ {
33517
+ displayName: 'Phone',
33518
+ name: 'phone',
33519
+ type: 'string',
33520
+ default: '',
33521
+ description: 'Required account phone, using the same phone validation as the Lead UI.',
33522
+ },
33523
+ {
33524
+ displayName: 'Email',
33525
+ name: 'email',
33526
+ type: 'string',
33527
+ default: '',
33528
+ description: 'Required account email, using the same email validation as the Lead UI.',
33529
+ },
33530
+ {
33531
+ displayName: 'Website',
33532
+ name: 'website',
33533
+ type: 'string',
33534
+ default: '',
33535
+ description: '',
33536
+ },
33537
+ {
33538
+ displayName: 'Annual Revenue',
33539
+ name: 'annualRevenue',
33540
+ type: 'string',
33541
+ default: '',
33542
+ description: '',
33543
+ },
33544
+ {
33545
+ displayName: 'Industry',
33546
+ name: 'industry',
33547
+ type: 'string',
33548
+ default: '',
33549
+ description: '',
33550
+ },
33551
+ {
33552
+ displayName: 'Employees',
33553
+ name: 'employees',
33554
+ type: 'string',
33555
+ default: '',
33556
+ description: '',
33557
+ },
33558
+ ],
33559
+ routing: {
33560
+ send: {
33561
+ type: 'body',
33562
+ property: 'account',
33563
+ },
33564
+ },
33565
+ },
33566
+ {
33567
+ displayName: 'Contact',
33568
+ name: 'contact',
33569
+ type: 'collection',
33570
+ default: {},
33571
+ placeholder: 'Add Contact',
33572
+ description: 'Typed-in prospect contact details. Updates merge supplied members into the stored snapshot.',
33573
+ required: true,
33574
+ displayOptions: {
33575
+ show: {
33576
+ resource: ['sales-leads'],
33577
+ operation: ['PublicLeadController_create'],
33578
+ },
33579
+ },
33580
+ options: [
33581
+ {
33582
+ displayName: 'First Name',
33583
+ name: 'firstName',
33584
+ type: 'string',
33585
+ default: '',
33586
+ description: 'Prospect contact first name; typed-in Lead details, not a CRM contact ID.',
33587
+ },
33588
+ {
33589
+ displayName: 'Last Name',
33590
+ name: 'lastName',
33591
+ type: 'string',
33592
+ default: '',
33593
+ description: 'Prospect contact last name.',
33594
+ },
33595
+ {
33596
+ displayName: 'Title',
33597
+ name: 'title',
33598
+ type: 'string',
33599
+ default: '',
33600
+ description: '',
33601
+ },
33602
+ {
33603
+ displayName: 'Email',
33604
+ name: 'email',
33605
+ type: 'string',
33606
+ default: '',
33607
+ description: 'Email address',
33608
+ },
33609
+ {
33610
+ displayName: 'Mobile',
33611
+ name: 'mobile',
33612
+ type: 'string',
33613
+ default: '',
33614
+ description: 'Mobile phone number',
33615
+ },
33616
+ {
33617
+ displayName: 'Work Phone',
33618
+ name: 'workPhone',
33619
+ type: 'string',
33620
+ default: '',
33621
+ description: '',
33622
+ },
33623
+ ],
33624
+ routing: {
33625
+ send: {
33626
+ type: 'body',
33627
+ property: 'contact',
33628
+ },
33629
+ },
33630
+ },
33631
+ {
33632
+ displayName: 'Billing Company Id',
33633
+ name: 'billingCompanyId',
33634
+ type: 'string',
33635
+ default: '',
33636
+ description: 'ID of an active WorkBuddy billing company.',
33637
+ required: true,
33638
+ displayOptions: {
33639
+ show: {
33640
+ resource: ['sales-leads'],
33641
+ operation: ['PublicLeadController_create'],
33642
+ },
33643
+ },
33644
+ routing: {
33645
+ send: {
33646
+ type: 'body',
33647
+ property: 'billingCompanyId',
33648
+ },
33649
+ },
33650
+ },
33651
+ {
33652
+ displayName: 'Owner Id',
33653
+ name: 'ownerId',
33654
+ type: 'options',
33655
+ default: '',
33656
+ description: 'ID of an active Employee or Team, matching the legacy Lead owner picker.',
33657
+ required: true,
33658
+ displayOptions: {
33659
+ show: {
33660
+ resource: ['sales-leads'],
33661
+ operation: ['PublicLeadController_create'],
33662
+ },
33663
+ },
33664
+ typeOptions: {
33665
+ loadOptionsMethod: 'loadEmployeeOptions',
33666
+ },
33667
+ routing: {
33668
+ send: {
33669
+ type: 'body',
33670
+ property: 'ownerId',
33671
+ },
33672
+ },
33673
+ },
33674
+ {
33675
+ displayName: 'Description',
33676
+ name: 'description',
33677
+ type: 'string',
33678
+ default: '',
33679
+ description: 'Detailed description',
33680
+ required: false,
33681
+ displayOptions: {
33682
+ show: {
33683
+ resource: ['sales-leads'],
33684
+ operation: ['PublicLeadController_create'],
33685
+ },
33686
+ },
33687
+ routing: {
33688
+ send: {
33689
+ type: 'body',
33690
+ property: 'description',
33691
+ },
33692
+ },
33693
+ },
33694
+ {
33695
+ displayName: 'Address',
33696
+ name: 'address',
33697
+ type: 'string',
33698
+ default: '',
33699
+ description: 'Optional prospect address. Null clears it. No siteId is accepted; an address is required only when converting.',
33700
+ required: false,
33701
+ displayOptions: {
33702
+ show: {
33703
+ resource: ['sales-leads'],
33704
+ operation: ['PublicLeadController_create'],
33705
+ },
33706
+ },
33707
+ routing: {
33708
+ send: {
33709
+ type: 'body',
33710
+ property: 'address',
33711
+ },
33712
+ },
33713
+ },
33714
+ {
33715
+ displayName: 'Amount',
33716
+ name: 'amount',
33717
+ type: 'number',
33718
+ default: 0,
33719
+ description: '',
33720
+ required: false,
33721
+ displayOptions: {
33722
+ show: {
33723
+ resource: ['sales-leads'],
33724
+ operation: ['PublicLeadController_create'],
33725
+ },
33726
+ },
33727
+ routing: {
33728
+ send: {
33729
+ type: 'body',
33730
+ property: 'amount',
33731
+ },
33732
+ },
33733
+ },
33734
+ {
33735
+ displayName: 'Expected Close',
33736
+ name: 'expectedClose',
33737
+ type: 'string',
33738
+ default: '',
33739
+ description: 'Expected close date/time as an ISO 8601 UTC timestamp. Null clears it.',
33740
+ required: false,
33741
+ displayOptions: {
33742
+ show: {
33743
+ resource: ['sales-leads'],
33744
+ operation: ['PublicLeadController_create'],
33745
+ },
33746
+ },
33747
+ routing: {
33748
+ send: {
33749
+ type: 'body',
33750
+ property: 'expectedClose',
33751
+ },
33752
+ },
33753
+ },
33754
+ {
33755
+ displayName: 'Job Type Id',
33756
+ name: 'jobTypeId',
33757
+ type: 'string',
33758
+ default: '',
33759
+ description: 'Job Type ID. Null clears the selection.',
33760
+ required: false,
33761
+ displayOptions: {
33762
+ show: {
33763
+ resource: ['sales-leads'],
33764
+ operation: ['PublicLeadController_create'],
33765
+ },
33766
+ },
33767
+ routing: {
33768
+ send: {
33769
+ type: 'body',
33770
+ property: 'jobTypeId',
33771
+ },
33772
+ },
33773
+ },
33774
+ {
33775
+ displayName: 'Source Id',
33776
+ name: 'sourceId',
33777
+ type: 'string',
33778
+ default: '',
33779
+ description: 'Lead Source label ID, available from GET /settings/tags?type=lead-source. Null clears it.',
33780
+ required: false,
33781
+ displayOptions: {
33782
+ show: {
33783
+ resource: ['sales-leads'],
33784
+ operation: ['PublicLeadController_create'],
33785
+ },
33786
+ },
33787
+ routing: {
33788
+ send: {
33789
+ type: 'body',
33790
+ property: 'sourceId',
33791
+ },
33792
+ },
33793
+ },
33794
+ {
33795
+ displayName: 'Tag Ids',
33796
+ name: 'tagIds',
33797
+ type: 'string',
33798
+ default: '',
33799
+ description: 'Lead label IDs, available from GET /settings/tags?type=lead. Replaces the tag list; null or an empty array clears it.',
33800
+ required: false,
33801
+ displayOptions: {
33802
+ show: {
33803
+ resource: ['sales-leads'],
33804
+ operation: ['PublicLeadController_create'],
33805
+ },
33806
+ },
33807
+ routing: {
33808
+ send: {
33809
+ type: 'body',
33810
+ property: 'tagIds',
33811
+ },
33812
+ },
33813
+ },
33814
+ {
33815
+ displayName: 'Stage',
33816
+ name: 'stage',
33817
+ type: 'options',
33818
+ default: '',
33819
+ description: 'Creation stage, matching all options in the legacy create picker. Defaults to New.',
33820
+ required: false,
33821
+ displayOptions: {
33822
+ show: {
33823
+ resource: ['sales-leads'],
33824
+ operation: ['PublicLeadController_create'],
33825
+ },
33826
+ },
33827
+ options: [
33828
+ {
33829
+ name: 'New',
33830
+ value: 'New',
33831
+ },
33832
+ {
33833
+ name: 'In Progress',
33834
+ value: 'In Progress',
33835
+ },
33836
+ {
33837
+ name: 'Qualified',
33838
+ value: 'Qualified',
33839
+ },
33840
+ {
33841
+ name: 'Disqualified',
33842
+ value: 'Disqualified',
33843
+ },
33844
+ ],
33845
+ routing: {
33846
+ send: {
33847
+ type: 'body',
33848
+ property: 'stage',
33849
+ },
33850
+ },
33851
+ },
33852
+ {
33853
+ displayName: 'Id',
33854
+ name: 'id',
33855
+ type: 'string',
33856
+ default: '',
33857
+ description: 'WorkBuddy Lead ID',
33858
+ required: true,
33859
+ displayOptions: {
33860
+ show: {
33861
+ resource: ['sales-leads'],
33862
+ operation: ['PublicLeadController_get'],
33863
+ },
33864
+ },
33865
+ },
33866
+ {
33867
+ displayName: 'Id',
33868
+ name: 'id',
33869
+ type: 'string',
33870
+ default: '',
33871
+ description: 'WorkBuddy Lead ID',
33872
+ required: true,
33873
+ displayOptions: {
33874
+ show: {
33875
+ resource: ['sales-leads'],
33876
+ operation: ['PublicLeadController_update'],
33877
+ },
33878
+ },
33879
+ },
33880
+ {
33881
+ displayName: 'Account',
33882
+ name: 'account',
33883
+ type: 'collection',
33884
+ default: {},
33885
+ placeholder: 'Add Account',
33886
+ description: 'Changed account members, merged with the stored snapshot as in the legacy pipeline.',
33887
+ required: false,
33888
+ displayOptions: {
33889
+ show: {
33890
+ resource: ['sales-leads'],
33891
+ operation: ['PublicLeadController_update'],
33892
+ },
33893
+ },
33894
+ options: [
33895
+ {
33896
+ displayName: 'Name',
33897
+ name: 'name',
33898
+ type: 'string',
33899
+ default: '',
33900
+ description: 'Prospect account name. Also supplies the Lead display name; this is not an existing CRM account reference.',
33901
+ },
33902
+ {
33903
+ displayName: 'Type',
33904
+ name: 'type',
33905
+ type: 'options',
33906
+ default: '',
33907
+ description: 'Customer account type used when qualifying the Lead. Defaults to Business when not otherwise specified.',
33908
+ options: [
33909
+ {
33910
+ name: 'Business',
33911
+ value: 'Business',
33912
+ },
33913
+ {
33914
+ name: 'Individual',
33915
+ value: 'Individual',
33916
+ },
33917
+ ],
33918
+ },
33919
+ {
33920
+ displayName: 'Phone',
33921
+ name: 'phone',
33922
+ type: 'string',
33923
+ default: '',
33924
+ description: 'Required account phone, using the same phone validation as the Lead UI.',
33925
+ },
33926
+ {
33927
+ displayName: 'Email',
33928
+ name: 'email',
33929
+ type: 'string',
33930
+ default: '',
33931
+ description: 'Required account email, using the same email validation as the Lead UI.',
33932
+ },
33933
+ {
33934
+ displayName: 'Website',
33935
+ name: 'website',
33936
+ type: 'string',
33937
+ default: '',
33938
+ description: '',
33939
+ },
33940
+ {
33941
+ displayName: 'Annual Revenue',
33942
+ name: 'annualRevenue',
33943
+ type: 'string',
33944
+ default: '',
33945
+ description: '',
33946
+ },
33947
+ {
33948
+ displayName: 'Industry',
33949
+ name: 'industry',
33950
+ type: 'string',
33951
+ default: '',
33952
+ description: '',
33953
+ },
33954
+ {
33955
+ displayName: 'Employees',
33956
+ name: 'employees',
33957
+ type: 'string',
33958
+ default: '',
33959
+ description: '',
33960
+ },
33961
+ ],
33962
+ routing: {
33963
+ send: {
33964
+ type: 'body',
33965
+ property: 'account',
33966
+ },
33967
+ },
33968
+ },
33969
+ {
33970
+ displayName: 'Contact',
33971
+ name: 'contact',
33972
+ type: 'collection',
33973
+ default: {},
33974
+ placeholder: 'Add Contact',
33975
+ description: 'Changed contact members, merged with the stored snapshot as in the legacy pipeline.',
33976
+ required: false,
33977
+ displayOptions: {
33978
+ show: {
33979
+ resource: ['sales-leads'],
33980
+ operation: ['PublicLeadController_update'],
33981
+ },
33982
+ },
33983
+ options: [
33984
+ {
33985
+ displayName: 'First Name',
33986
+ name: 'firstName',
33987
+ type: 'string',
33988
+ default: '',
33989
+ description: 'Prospect contact first name; typed-in Lead details, not a CRM contact ID.',
33990
+ },
33991
+ {
33992
+ displayName: 'Last Name',
33993
+ name: 'lastName',
33994
+ type: 'string',
33995
+ default: '',
33996
+ description: 'Prospect contact last name.',
33997
+ },
33998
+ {
33999
+ displayName: 'Title',
34000
+ name: 'title',
34001
+ type: 'string',
34002
+ default: '',
34003
+ description: '',
34004
+ },
34005
+ {
34006
+ displayName: 'Email',
34007
+ name: 'email',
34008
+ type: 'string',
34009
+ default: '',
34010
+ description: 'Email address',
34011
+ },
34012
+ {
34013
+ displayName: 'Mobile',
34014
+ name: 'mobile',
34015
+ type: 'string',
34016
+ default: '',
34017
+ description: 'Mobile phone number',
34018
+ },
34019
+ {
34020
+ displayName: 'Work Phone',
34021
+ name: 'workPhone',
34022
+ type: 'string',
34023
+ default: '',
34024
+ description: '',
34025
+ },
34026
+ ],
34027
+ routing: {
34028
+ send: {
34029
+ type: 'body',
34030
+ property: 'contact',
34031
+ },
34032
+ },
34033
+ },
34034
+ {
34035
+ displayName: 'Description',
34036
+ name: 'description',
34037
+ type: 'string',
34038
+ default: '',
34039
+ description: 'Detailed description',
34040
+ required: false,
34041
+ displayOptions: {
34042
+ show: {
34043
+ resource: ['sales-leads'],
34044
+ operation: ['PublicLeadController_update'],
34045
+ },
34046
+ },
34047
+ routing: {
34048
+ send: {
34049
+ type: 'body',
34050
+ property: 'description',
34051
+ },
34052
+ },
34053
+ },
34054
+ {
34055
+ displayName: 'Address',
34056
+ name: 'address',
34057
+ type: 'string',
34058
+ default: '',
34059
+ description: 'Optional prospect address. Null clears it. No siteId is accepted; an address is required only when converting.',
34060
+ required: false,
34061
+ displayOptions: {
34062
+ show: {
34063
+ resource: ['sales-leads'],
34064
+ operation: ['PublicLeadController_update'],
34065
+ },
34066
+ },
34067
+ routing: {
34068
+ send: {
34069
+ type: 'body',
34070
+ property: 'address',
34071
+ },
34072
+ },
34073
+ },
34074
+ {
34075
+ displayName: 'Amount',
34076
+ name: 'amount',
34077
+ type: 'number',
34078
+ default: 0,
34079
+ description: '',
34080
+ required: false,
34081
+ displayOptions: {
34082
+ show: {
34083
+ resource: ['sales-leads'],
34084
+ operation: ['PublicLeadController_update'],
34085
+ },
34086
+ },
34087
+ routing: {
34088
+ send: {
34089
+ type: 'body',
34090
+ property: 'amount',
34091
+ },
34092
+ },
34093
+ },
34094
+ {
34095
+ displayName: 'Expected Close',
34096
+ name: 'expectedClose',
34097
+ type: 'string',
34098
+ default: '',
34099
+ description: 'Expected close date/time as an ISO 8601 UTC timestamp. Null clears it.',
34100
+ required: false,
34101
+ displayOptions: {
34102
+ show: {
34103
+ resource: ['sales-leads'],
34104
+ operation: ['PublicLeadController_update'],
34105
+ },
34106
+ },
34107
+ routing: {
34108
+ send: {
34109
+ type: 'body',
34110
+ property: 'expectedClose',
34111
+ },
34112
+ },
34113
+ },
34114
+ {
34115
+ displayName: 'Billing Company Id',
34116
+ name: 'billingCompanyId',
34117
+ type: 'string',
34118
+ default: '',
34119
+ description: 'ID of an active WorkBuddy billing company.',
34120
+ required: false,
34121
+ displayOptions: {
34122
+ show: {
34123
+ resource: ['sales-leads'],
34124
+ operation: ['PublicLeadController_update'],
34125
+ },
34126
+ },
34127
+ routing: {
34128
+ send: {
34129
+ type: 'body',
34130
+ property: 'billingCompanyId',
34131
+ },
34132
+ },
34133
+ },
34134
+ {
34135
+ displayName: 'Owner Id',
34136
+ name: 'ownerId',
34137
+ type: 'options',
34138
+ default: '',
34139
+ description: 'ID of an active Employee or Team, matching the legacy Lead owner picker.',
34140
+ required: false,
34141
+ displayOptions: {
34142
+ show: {
34143
+ resource: ['sales-leads'],
34144
+ operation: ['PublicLeadController_update'],
34145
+ },
34146
+ },
34147
+ typeOptions: {
34148
+ loadOptionsMethod: 'loadEmployeeOptions',
34149
+ },
34150
+ routing: {
34151
+ send: {
34152
+ type: 'body',
34153
+ property: 'ownerId',
34154
+ },
34155
+ },
34156
+ },
34157
+ {
34158
+ displayName: 'Job Type Id',
34159
+ name: 'jobTypeId',
34160
+ type: 'string',
34161
+ default: '',
34162
+ description: 'Job Type ID. Null clears the selection.',
34163
+ required: false,
34164
+ displayOptions: {
34165
+ show: {
34166
+ resource: ['sales-leads'],
34167
+ operation: ['PublicLeadController_update'],
34168
+ },
34169
+ },
34170
+ routing: {
34171
+ send: {
34172
+ type: 'body',
34173
+ property: 'jobTypeId',
34174
+ },
34175
+ },
34176
+ },
34177
+ {
34178
+ displayName: 'Source Id',
34179
+ name: 'sourceId',
34180
+ type: 'string',
34181
+ default: '',
34182
+ description: 'Lead Source label ID, available from GET /settings/tags?type=lead-source. Null clears it.',
34183
+ required: false,
34184
+ displayOptions: {
34185
+ show: {
34186
+ resource: ['sales-leads'],
34187
+ operation: ['PublicLeadController_update'],
34188
+ },
34189
+ },
34190
+ routing: {
34191
+ send: {
34192
+ type: 'body',
34193
+ property: 'sourceId',
34194
+ },
34195
+ },
34196
+ },
34197
+ {
34198
+ displayName: 'Tag Ids',
34199
+ name: 'tagIds',
34200
+ type: 'string',
34201
+ default: '',
34202
+ description: 'Lead label IDs, available from GET /settings/tags?type=lead. Replaces the tag list; null or an empty array clears it.',
34203
+ required: false,
34204
+ displayOptions: {
34205
+ show: {
34206
+ resource: ['sales-leads'],
34207
+ operation: ['PublicLeadController_update'],
34208
+ },
34209
+ },
34210
+ routing: {
34211
+ send: {
34212
+ type: 'body',
34213
+ property: 'tagIds',
34214
+ },
34215
+ },
34216
+ },
34217
+ {
34218
+ displayName: 'Stage',
34219
+ name: 'stage',
34220
+ type: 'options',
34221
+ default: '',
34222
+ description: '',
34223
+ required: false,
34224
+ displayOptions: {
34225
+ show: {
34226
+ resource: ['sales-leads'],
34227
+ operation: ['PublicLeadController_update'],
34228
+ },
34229
+ },
34230
+ options: [
34231
+ {
34232
+ name: 'New',
34233
+ value: 'New',
34234
+ },
34235
+ {
34236
+ name: 'In Progress',
34237
+ value: 'In Progress',
34238
+ },
34239
+ {
34240
+ name: 'Disqualified',
34241
+ value: 'Disqualified',
34242
+ },
34243
+ ],
34244
+ routing: {
34245
+ send: {
34246
+ type: 'body',
34247
+ property: 'stage',
34248
+ },
34249
+ },
34250
+ },
34251
+ {
34252
+ displayName: 'Id',
34253
+ name: 'id',
34254
+ type: 'string',
34255
+ default: '',
34256
+ description: 'WorkBuddy Lead ID',
34257
+ required: true,
34258
+ displayOptions: {
34259
+ show: {
34260
+ resource: ['sales-leads'],
34261
+ operation: ['PublicLeadController_convert'],
34262
+ },
34263
+ },
34264
+ },
34265
+ {
34266
+ displayName: 'Account Type',
34267
+ name: 'accountType',
34268
+ type: 'options',
34269
+ default: '',
34270
+ description: 'Type of CRM customer to create. Overrides account.type when both are supplied.',
34271
+ required: false,
34272
+ displayOptions: {
34273
+ show: {
34274
+ resource: ['sales-leads'],
34275
+ operation: ['PublicLeadController_convert'],
34276
+ },
34277
+ },
34278
+ options: [
34279
+ {
34280
+ name: 'Business',
34281
+ value: 'Business',
34282
+ },
34283
+ {
34284
+ name: 'Individual',
34285
+ value: 'Individual',
34286
+ },
34287
+ ],
34288
+ routing: {
34289
+ send: {
34290
+ type: 'body',
34291
+ property: 'accountType',
34292
+ },
34293
+ },
34294
+ },
34295
+ {
34296
+ displayName: 'Account',
34297
+ name: 'account',
34298
+ type: 'collection',
34299
+ default: {},
34300
+ placeholder: 'Add Account',
34301
+ description: 'Optional replacement prospect account details. Phone and email are optional during conversion. Omit to use the Lead snapshot.',
34302
+ required: false,
34303
+ displayOptions: {
34304
+ show: {
34305
+ resource: ['sales-leads'],
34306
+ operation: ['PublicLeadController_convert'],
34307
+ },
34308
+ },
34309
+ options: [
34310
+ {
34311
+ displayName: 'Name',
34312
+ name: 'name',
34313
+ type: 'string',
34314
+ default: '',
34315
+ description: 'Prospect account name. Also supplies the Lead display name; this is not an existing CRM account reference.',
34316
+ },
34317
+ {
34318
+ displayName: 'Type',
34319
+ name: 'type',
34320
+ type: 'options',
34321
+ default: '',
34322
+ description: 'Customer account type used when qualifying the Lead. Defaults to Business when not otherwise specified.',
34323
+ options: [
34324
+ {
34325
+ name: 'Business',
34326
+ value: 'Business',
34327
+ },
34328
+ {
34329
+ name: 'Individual',
34330
+ value: 'Individual',
34331
+ },
34332
+ ],
34333
+ },
34334
+ {
34335
+ displayName: 'Phone',
34336
+ name: 'phone',
34337
+ type: 'string',
34338
+ default: '',
34339
+ description: 'Prospect phone. Required when creating/editing the account snapshot; optional during conversion, as in the UI.',
34340
+ },
34341
+ {
34342
+ displayName: 'Email',
34343
+ name: 'email',
34344
+ type: 'string',
34345
+ default: '',
34346
+ description: 'Prospect email. Required when creating/editing the account snapshot; optional during conversion, as in the UI.',
34347
+ },
34348
+ {
34349
+ displayName: 'Website',
34350
+ name: 'website',
34351
+ type: 'string',
34352
+ default: '',
34353
+ description: '',
34354
+ },
34355
+ {
34356
+ displayName: 'Annual Revenue',
34357
+ name: 'annualRevenue',
34358
+ type: 'string',
34359
+ default: '',
34360
+ description: '',
34361
+ },
34362
+ {
34363
+ displayName: 'Industry',
34364
+ name: 'industry',
34365
+ type: 'string',
34366
+ default: '',
34367
+ description: '',
34368
+ },
34369
+ {
34370
+ displayName: 'Employees',
34371
+ name: 'employees',
34372
+ type: 'string',
34373
+ default: '',
34374
+ description: '',
34375
+ },
34376
+ ],
34377
+ routing: {
34378
+ send: {
34379
+ type: 'body',
34380
+ property: 'account',
34381
+ },
34382
+ },
34383
+ },
34384
+ {
34385
+ displayName: 'Contact',
34386
+ name: 'contact',
34387
+ type: 'collection',
34388
+ default: {},
34389
+ placeholder: 'Add Contact',
34390
+ description: 'Inline contact object — alternative to contactId',
34391
+ required: false,
34392
+ displayOptions: {
34393
+ show: {
34394
+ resource: ['sales-leads'],
34395
+ operation: ['PublicLeadController_convert'],
34396
+ },
34397
+ },
34398
+ options: [
34399
+ {
34400
+ displayName: 'First Name',
34401
+ name: 'firstName',
34402
+ type: 'string',
34403
+ default: '',
34404
+ description: 'Prospect contact first name; typed-in Lead details, not a CRM contact ID.',
34405
+ },
34406
+ {
34407
+ displayName: 'Last Name',
34408
+ name: 'lastName',
34409
+ type: 'string',
34410
+ default: '',
34411
+ description: 'Prospect contact last name.',
34412
+ },
34413
+ {
34414
+ displayName: 'Title',
34415
+ name: 'title',
34416
+ type: 'string',
34417
+ default: '',
34418
+ description: '',
34419
+ },
34420
+ {
34421
+ displayName: 'Email',
34422
+ name: 'email',
34423
+ type: 'string',
34424
+ default: '',
34425
+ description: 'Email address',
34426
+ },
34427
+ {
34428
+ displayName: 'Mobile',
34429
+ name: 'mobile',
34430
+ type: 'string',
34431
+ default: '',
34432
+ description: 'Mobile phone number',
34433
+ },
34434
+ {
34435
+ displayName: 'Work Phone',
34436
+ name: 'workPhone',
34437
+ type: 'string',
34438
+ default: '',
34439
+ description: '',
34440
+ },
34441
+ ],
34442
+ routing: {
34443
+ send: {
34444
+ type: 'body',
34445
+ property: 'contact',
34446
+ },
34447
+ },
34448
+ },
34449
+ {
34450
+ displayName: 'Address',
34451
+ name: 'address',
34452
+ type: 'collection',
34453
+ default: {},
34454
+ placeholder: 'Add Address',
34455
+ description: 'Conversion address override. When omitted, the stored Lead address is used; one of those addresses must be present.',
34456
+ required: false,
34457
+ displayOptions: {
34458
+ show: {
34459
+ resource: ['sales-leads'],
34460
+ operation: ['PublicLeadController_convert'],
34461
+ },
34462
+ },
34463
+ options: [
34464
+ {
34465
+ displayName: 'Name',
34466
+ name: 'name',
34467
+ type: 'string',
34468
+ default: '',
34469
+ description: 'Display name',
34470
+ },
34471
+ {
34472
+ displayName: 'Street1',
34473
+ name: 'street1',
34474
+ type: 'string',
34475
+ default: '',
34476
+ description: '',
34477
+ },
34478
+ {
34479
+ displayName: 'Street2',
34480
+ name: 'street2',
34481
+ type: 'string',
34482
+ default: '',
34483
+ description: '',
34484
+ },
34485
+ {
34486
+ displayName: 'Suburb',
34487
+ name: 'suburb',
34488
+ type: 'string',
34489
+ default: '',
34490
+ description: '',
34491
+ },
34492
+ {
34493
+ displayName: 'State',
34494
+ name: 'state',
34495
+ type: 'string',
34496
+ default: '',
34497
+ description: '',
34498
+ },
34499
+ {
34500
+ displayName: 'Postal Code',
34501
+ name: 'postalCode',
34502
+ type: 'string',
34503
+ default: '',
34504
+ description: '',
34505
+ },
34506
+ {
34507
+ displayName: 'Country',
34508
+ name: 'country',
34509
+ type: 'string',
34510
+ default: '',
34511
+ description: '',
34512
+ },
34513
+ {
34514
+ displayName: 'Lat',
34515
+ name: 'lat',
34516
+ type: 'number',
34517
+ default: 0,
34518
+ description: '',
34519
+ },
34520
+ {
34521
+ displayName: 'Lgn',
34522
+ name: 'lgn',
34523
+ type: 'number',
34524
+ default: 0,
34525
+ description: '',
34526
+ },
34527
+ {
34528
+ displayName: 'Timezone',
34529
+ name: 'timezone',
34530
+ type: 'string',
34531
+ default: '',
34532
+ description: '',
34533
+ },
34534
+ ],
34535
+ routing: {
34536
+ send: {
34537
+ type: 'body',
34538
+ property: 'address',
34539
+ },
34540
+ },
34541
+ },
34542
+ {
34543
+ displayName: 'Opportunity',
34544
+ name: 'opportunity',
34545
+ type: 'collection',
34546
+ default: {},
34547
+ placeholder: 'Add Opportunity',
34548
+ description: 'Include a name to also create an Opportunity. Omit to create only the customer and qualify the Lead.',
34549
+ required: false,
34550
+ displayOptions: {
34551
+ show: {
34552
+ resource: ['sales-leads'],
34553
+ operation: ['PublicLeadController_convert'],
34554
+ },
34555
+ },
34556
+ options: [
34557
+ {
34558
+ displayName: 'Name',
34559
+ name: 'name',
34560
+ type: 'string',
34561
+ default: '',
34562
+ description: 'Display name',
34563
+ },
34564
+ ],
34565
+ routing: {
34566
+ send: {
34567
+ type: 'body',
34568
+ property: 'opportunity',
34569
+ },
34570
+ },
34571
+ },
34572
+ // Sales Opportunities Operations
34573
+ {
34574
+ displayName: 'Operation',
34575
+ name: 'operation',
34576
+ type: 'options',
34577
+ noDataExpression: true,
34578
+ displayOptions: {
34579
+ show: {
34580
+ resource: ['sales-opportunities'],
34581
+ },
34582
+ },
34583
+ options: [
34584
+ {
34585
+ name: 'List opportunities',
34586
+ value: 'PublicOpportunityController_list',
34587
+ action: '',
34588
+ description: '',
34589
+ routing: {
34590
+ request: {
34591
+ method: 'GET',
34592
+ url: '/api/v2/public/opportunities',
34593
+ },
34594
+ },
34595
+ },
34596
+ {
34597
+ name: 'Create opportunity',
34598
+ value: 'PublicOpportunityController_create',
34599
+ action: 'Requires name, customerId, billingCompanyId and ownerId. Site/contact are optional. Omitted stage uses the pipeline New-stage default.',
34600
+ description: 'Requires name, customerId, billingCompanyId and ownerId. Site/contact are optional. Omitted stage uses the pipeline New-stage default.',
34601
+ routing: {
34602
+ request: {
34603
+ method: 'POST',
34604
+ url: '/api/v2/public/opportunities',
34605
+ },
34606
+ },
34607
+ },
34608
+ {
34609
+ name: 'List opportunity stages',
34610
+ value: 'PublicOpportunityController_stages',
34611
+ action: 'Configured Open/Closed stages, including New, Won and Lost. Use these IDs for creation and change-stage.',
34612
+ description: 'Configured Open/Closed stages, including New, Won and Lost. Use these IDs for creation and change-stage.',
34613
+ routing: {
34614
+ request: {
34615
+ method: 'GET',
34616
+ url: '/api/v2/public/opportunities/stages',
34617
+ },
34618
+ },
34619
+ },
34620
+ {
34621
+ name: 'Get opportunity',
34622
+ value: 'PublicOpportunityController_get',
34623
+ action: '',
34624
+ description: '',
34625
+ routing: {
34626
+ request: {
34627
+ method: 'GET',
34628
+ url: '/api/v2/public/opportunities/={{ $parameter["id"] }}',
34629
+ },
34630
+ },
34631
+ },
34632
+ {
34633
+ name: 'Update opportunity',
34634
+ value: 'PublicOpportunityController_update',
34635
+ action: 'Updates ordinary fields, including on closed Opportunities. Use change-stage for stage transitions. Sites merge using the existing pipeline behaviour.',
34636
+ description: 'Updates ordinary fields, including on closed Opportunities. Use change-stage for stage transitions. Sites merge using the existing pipeline behaviour.',
34637
+ routing: {
34638
+ request: {
34639
+ method: 'PATCH',
34640
+ url: '/api/v2/public/opportunities/={{ $parameter["id"] }}',
34641
+ },
34642
+ },
34643
+ },
34644
+ {
34645
+ name: 'Change opportunity stage',
34646
+ value: 'PublicOpportunityController_changeStage',
34647
+ action: 'Supports reopening. Closing requires Mark Opportunities; Lost also requires a Lost Reason. Stage probability and quote-close effects follow the existing pipeline.',
34648
+ description: 'Supports reopening. Closing requires Mark Opportunities; Lost also requires a Lost Reason. Stage probability and quote-close effects follow the existing pipeline.',
34649
+ routing: {
34650
+ request: {
34651
+ method: 'POST',
34652
+ url: '/api/v2/public/opportunities/={{ $parameter["id"] }}/change-stage',
34653
+ },
34654
+ },
34655
+ },
34656
+ ],
34657
+ default: 'PublicOpportunityController_list',
34658
+ },
34659
+ {
34660
+ displayName: 'Stage Id',
34661
+ name: 'stageId',
34662
+ type: 'string',
34663
+ default: '',
34664
+ description: 'Configured Opportunity stage ID.',
34665
+ required: false,
34666
+ displayOptions: {
34667
+ show: {
34668
+ resource: ['sales-opportunities'],
34669
+ operation: ['PublicOpportunityController_list'],
34670
+ },
34671
+ },
34672
+ routing: {
34673
+ request: {
34674
+ qs: {
34675
+ stageId: '={{$value}}',
34676
+ },
34677
+ },
34678
+ },
34679
+ },
34680
+ {
34681
+ displayName: 'Search',
34682
+ name: 'search',
34683
+ type: 'string',
34684
+ default: '',
34685
+ description: 'Search Opportunity number, name or customer name.',
34686
+ required: false,
34687
+ displayOptions: {
34688
+ show: {
34689
+ resource: ['sales-opportunities'],
34690
+ operation: ['PublicOpportunityController_list'],
34691
+ },
34692
+ },
34693
+ routing: {
34694
+ request: {
34695
+ qs: {
34696
+ search: '={{$value}}',
34697
+ },
34698
+ },
34699
+ },
34700
+ },
34701
+ {
34702
+ displayName: 'Cursor',
34703
+ name: 'cursor',
34704
+ type: 'string',
34705
+ default: '',
34706
+ description: '',
34707
+ required: false,
34708
+ displayOptions: {
34709
+ show: {
34710
+ resource: ['sales-opportunities'],
34711
+ operation: ['PublicOpportunityController_list'],
34712
+ },
34713
+ },
34714
+ routing: {
34715
+ request: {
34716
+ qs: {
34717
+ cursor: '={{$value}}',
34718
+ },
34719
+ },
34720
+ },
34721
+ },
34722
+ {
34723
+ displayName: 'Limit',
34724
+ name: 'limit',
34725
+ type: 'number',
34726
+ default: 50,
34727
+ description: '',
34728
+ required: false,
34729
+ displayOptions: {
34730
+ show: {
34731
+ resource: ['sales-opportunities'],
34732
+ operation: ['PublicOpportunityController_list'],
34733
+ },
34734
+ },
34735
+ routing: {
34736
+ request: {
34737
+ qs: {
34738
+ limit: '={{$value}}',
34739
+ },
34740
+ },
34741
+ },
34742
+ },
34743
+ {
34744
+ displayName: 'Name',
34745
+ name: 'name',
34746
+ type: 'string',
34747
+ default: '',
34748
+ description: 'Opportunity name; required by the legacy form.',
34749
+ required: true,
34750
+ displayOptions: {
34751
+ show: {
34752
+ resource: ['sales-opportunities'],
34753
+ operation: ['PublicOpportunityController_create'],
34754
+ },
34755
+ },
34756
+ routing: {
34757
+ send: {
34758
+ type: 'body',
34759
+ property: 'name',
34760
+ },
34761
+ },
34762
+ },
34763
+ {
34764
+ displayName: 'Customer Id',
34765
+ name: 'customerId',
34766
+ type: 'options',
34767
+ default: '',
34768
+ description: 'Existing active customer ID.',
34769
+ required: true,
34770
+ displayOptions: {
34771
+ show: {
34772
+ resource: ['sales-opportunities'],
34773
+ operation: ['PublicOpportunityController_create'],
34774
+ },
34775
+ },
34776
+ typeOptions: {
34777
+ loadOptionsMethod: 'loadCustomerOptions',
34778
+ },
34779
+ routing: {
34780
+ send: {
34781
+ type: 'body',
34782
+ property: 'customerId',
34783
+ },
34784
+ },
34785
+ },
34786
+ {
34787
+ displayName: 'Billing Company Id',
34788
+ name: 'billingCompanyId',
34789
+ type: 'string',
34790
+ default: '',
34791
+ description: 'WorkBuddy billing company ID, not a CRM Company account ID.',
34792
+ required: true,
34793
+ displayOptions: {
34794
+ show: {
34795
+ resource: ['sales-opportunities'],
34796
+ operation: ['PublicOpportunityController_create'],
34797
+ },
34798
+ },
34799
+ routing: {
34800
+ send: {
34801
+ type: 'body',
34802
+ property: 'billingCompanyId',
34803
+ },
34804
+ },
34805
+ },
34806
+ {
34807
+ displayName: 'Owner Id',
34808
+ name: 'ownerId',
34809
+ type: 'options',
34810
+ default: '',
34811
+ description: 'Employee owner ID, matching the legacy Opportunity owner picker.',
34812
+ required: true,
34813
+ displayOptions: {
34814
+ show: {
34815
+ resource: ['sales-opportunities'],
34816
+ operation: ['PublicOpportunityController_create'],
34817
+ },
34818
+ },
34819
+ typeOptions: {
34820
+ loadOptionsMethod: 'loadEmployeeOptions',
34821
+ },
34822
+ routing: {
34823
+ send: {
34824
+ type: 'body',
34825
+ property: 'ownerId',
34826
+ },
34827
+ },
34828
+ },
34829
+ {
34830
+ displayName: 'Area Manager Id',
34831
+ name: 'areaManagerId',
34832
+ type: 'string',
34833
+ default: '',
34834
+ description: 'area manager ID',
34835
+ required: false,
34836
+ displayOptions: {
34837
+ show: {
34838
+ resource: ['sales-opportunities'],
34839
+ operation: ['PublicOpportunityController_create'],
34840
+ },
34841
+ },
34842
+ routing: {
34843
+ send: {
34844
+ type: 'body',
34845
+ property: 'areaManagerId',
34846
+ },
34847
+ },
34848
+ },
34849
+ {
34850
+ displayName: 'Description',
34851
+ name: 'description',
34852
+ type: 'string',
34853
+ default: '',
34854
+ description: 'Detailed description',
34855
+ required: false,
34856
+ displayOptions: {
34857
+ show: {
34858
+ resource: ['sales-opportunities'],
34859
+ operation: ['PublicOpportunityController_create'],
34860
+ },
34861
+ },
34862
+ routing: {
34863
+ send: {
34864
+ type: 'body',
34865
+ property: 'description',
34866
+ },
34867
+ },
34868
+ },
34869
+ {
34870
+ displayName: 'Amount',
34871
+ name: 'amount',
34872
+ type: 'number',
34873
+ default: 0,
34874
+ description: '',
34875
+ required: false,
34876
+ displayOptions: {
34877
+ show: {
34878
+ resource: ['sales-opportunities'],
34879
+ operation: ['PublicOpportunityController_create'],
34880
+ },
34881
+ },
34882
+ routing: {
34883
+ send: {
34884
+ type: 'body',
34885
+ property: 'amount',
34886
+ },
34887
+ },
34888
+ },
34889
+ {
34890
+ displayName: 'Probability',
34891
+ name: 'probability',
34892
+ type: 'number',
34893
+ default: 0,
34894
+ description: 'Estimated probability. Stage changes use the selected stage probability, as in the UI.',
34895
+ required: false,
34896
+ displayOptions: {
34897
+ show: {
34898
+ resource: ['sales-opportunities'],
34899
+ operation: ['PublicOpportunityController_create'],
34900
+ },
34901
+ },
34902
+ routing: {
34903
+ send: {
34904
+ type: 'body',
34905
+ property: 'probability',
34906
+ },
34907
+ },
34908
+ },
34909
+ {
34910
+ displayName: 'Expected Close',
34911
+ name: 'expectedClose',
34912
+ type: 'string',
34913
+ default: '',
34914
+ description: '',
34915
+ required: false,
34916
+ displayOptions: {
34917
+ show: {
34918
+ resource: ['sales-opportunities'],
34919
+ operation: ['PublicOpportunityController_create'],
34920
+ },
34921
+ },
34922
+ routing: {
34923
+ send: {
34924
+ type: 'body',
34925
+ property: 'expectedClose',
34926
+ },
34927
+ },
34928
+ },
34929
+ {
34930
+ displayName: 'Job Type Id',
34931
+ name: 'jobTypeId',
34932
+ type: 'string',
34933
+ default: '',
34934
+ description: 'job type ID',
34935
+ required: false,
34936
+ displayOptions: {
34937
+ show: {
34938
+ resource: ['sales-opportunities'],
34939
+ operation: ['PublicOpportunityController_create'],
34940
+ },
34941
+ },
34942
+ routing: {
34943
+ send: {
34944
+ type: 'body',
34945
+ property: 'jobTypeId',
34946
+ },
34947
+ },
34948
+ },
34949
+ {
34950
+ displayName: 'Source Id',
34951
+ name: 'sourceId',
34952
+ type: 'string',
34953
+ default: '',
34954
+ description: 'Lead Source label ID from GET /settings/tags?type=lead-source.',
34955
+ required: false,
34956
+ displayOptions: {
34957
+ show: {
34958
+ resource: ['sales-opportunities'],
34959
+ operation: ['PublicOpportunityController_create'],
34960
+ },
34961
+ },
34962
+ routing: {
34963
+ send: {
34964
+ type: 'body',
34965
+ property: 'sourceId',
34966
+ },
34967
+ },
34968
+ },
34969
+ {
34970
+ displayName: 'Tag Ids',
34971
+ name: 'tagIds',
34972
+ type: 'string',
34973
+ default: '',
34974
+ description: 'Opportunity label IDs from GET /settings/tags?type=opportunity. Null or [] clears the selection.',
34975
+ required: false,
34976
+ displayOptions: {
34977
+ show: {
34978
+ resource: ['sales-opportunities'],
34979
+ operation: ['PublicOpportunityController_create'],
34980
+ },
34981
+ },
34982
+ routing: {
34983
+ send: {
34984
+ type: 'body',
34985
+ property: 'tagIds',
34986
+ },
34987
+ },
34988
+ },
34989
+ {
34990
+ displayName: 'Site Id',
34991
+ name: 'siteId',
34992
+ type: 'options',
34993
+ default: '',
34994
+ description: 'Optional CRM site belonging to the selected customer. Use site instead for an ad-hoc address.',
34995
+ required: false,
34996
+ displayOptions: {
34997
+ show: {
34998
+ resource: ['sales-opportunities'],
34999
+ operation: ['PublicOpportunityController_create'],
35000
+ },
35001
+ },
35002
+ typeOptions: {
35003
+ loadOptionsMethod: 'loadSiteOptions',
35004
+ },
35005
+ routing: {
35006
+ send: {
35007
+ type: 'body',
35008
+ property: 'siteId',
35009
+ },
35010
+ },
35011
+ },
35012
+ {
35013
+ displayName: 'Site',
35014
+ name: 'site',
35015
+ type: 'string',
35016
+ default: '',
35017
+ description: 'Optional ad-hoc site snapshot. Does not create a CRM site. Cannot be supplied with siteId.',
35018
+ required: false,
35019
+ displayOptions: {
35020
+ show: {
35021
+ resource: ['sales-opportunities'],
35022
+ operation: ['PublicOpportunityController_create'],
35023
+ },
35024
+ },
35025
+ routing: {
35026
+ send: {
35027
+ type: 'body',
35028
+ property: 'site',
35029
+ },
35030
+ },
35031
+ },
35032
+ {
35033
+ displayName: 'Contact Id',
35034
+ name: 'contactId',
35035
+ type: 'string',
35036
+ default: '',
35037
+ description: 'Optional contact belonging to the customer or selected site.',
35038
+ required: false,
35039
+ displayOptions: {
35040
+ show: {
35041
+ resource: ['sales-opportunities'],
35042
+ operation: ['PublicOpportunityController_create'],
35043
+ },
35044
+ },
35045
+ routing: {
35046
+ send: {
35047
+ type: 'body',
35048
+ property: 'contactId',
35049
+ },
35050
+ },
35051
+ },
35052
+ {
35053
+ displayName: 'Site Contact Id',
35054
+ name: 'siteContactId',
35055
+ type: 'string',
35056
+ default: '',
35057
+ description: 'Site-contact snapshot from a contact belonging to the customer or selected site. Null clears it.',
35058
+ required: false,
35059
+ displayOptions: {
35060
+ show: {
35061
+ resource: ['sales-opportunities'],
35062
+ operation: ['PublicOpportunityController_create'],
35063
+ },
35064
+ },
35065
+ routing: {
35066
+ send: {
35067
+ type: 'body',
35068
+ property: 'siteContactId',
35069
+ },
35070
+ },
35071
+ },
35072
+ {
35073
+ displayName: 'Contact',
35074
+ name: 'contact',
35075
+ type: 'string',
35076
+ default: '',
35077
+ description: 'Optional name-only ad-hoc contact snapshot, matching the stored Opportunity contact. Cannot be supplied with contactId. Create richer contacts through the CRM API and supply contactId.',
35078
+ required: false,
35079
+ displayOptions: {
35080
+ show: {
35081
+ resource: ['sales-opportunities'],
35082
+ operation: ['PublicOpportunityController_create'],
35083
+ },
35084
+ },
35085
+ routing: {
35086
+ send: {
35087
+ type: 'body',
35088
+ property: 'contact',
35089
+ },
35090
+ },
35091
+ },
35092
+ {
35093
+ displayName: 'Customer Site Id',
35094
+ name: 'customerSiteId',
35095
+ type: 'string',
35096
+ default: '',
35097
+ description: 'Optional customer-side address site ID belonging to the selected customer.',
35098
+ required: false,
35099
+ displayOptions: {
35100
+ show: {
35101
+ resource: ['sales-opportunities'],
35102
+ operation: ['PublicOpportunityController_create'],
35103
+ },
35104
+ },
35105
+ routing: {
35106
+ send: {
35107
+ type: 'body',
35108
+ property: 'customerSiteId',
35109
+ },
35110
+ },
35111
+ },
35112
+ {
35113
+ displayName: 'Stage Id',
35114
+ name: 'stageId',
35115
+ type: 'string',
35116
+ default: '',
35117
+ description: 'Open Opportunity stage ID from GET /opportunities/stages. Omit to use the existing New-stage pipeline default.',
35118
+ required: false,
35119
+ displayOptions: {
35120
+ show: {
35121
+ resource: ['sales-opportunities'],
35122
+ operation: ['PublicOpportunityController_create'],
35123
+ },
35124
+ },
35125
+ routing: {
35126
+ send: {
35127
+ type: 'body',
35128
+ property: 'stageId',
35129
+ },
35130
+ },
35131
+ },
35132
+ {
35133
+ displayName: 'Id',
35134
+ name: 'id',
35135
+ type: 'string',
35136
+ default: '',
35137
+ description: 'WorkBuddy Opportunity ID or Opportunity number',
35138
+ required: true,
35139
+ displayOptions: {
35140
+ show: {
35141
+ resource: ['sales-opportunities'],
35142
+ operation: ['PublicOpportunityController_get'],
35143
+ },
35144
+ },
35145
+ },
35146
+ {
35147
+ displayName: 'Id',
35148
+ name: 'id',
35149
+ type: 'string',
35150
+ default: '',
35151
+ description: 'WorkBuddy Opportunity ID',
35152
+ required: true,
35153
+ displayOptions: {
35154
+ show: {
35155
+ resource: ['sales-opportunities'],
35156
+ operation: ['PublicOpportunityController_update'],
35157
+ },
35158
+ },
35159
+ },
35160
+ {
35161
+ displayName: 'Name',
35162
+ name: 'name',
35163
+ type: 'string',
35164
+ default: '',
35165
+ description: 'Opportunity name; required by the legacy form.',
35166
+ required: false,
35167
+ displayOptions: {
35168
+ show: {
35169
+ resource: ['sales-opportunities'],
35170
+ operation: ['PublicOpportunityController_update'],
35171
+ },
35172
+ },
35173
+ routing: {
35174
+ send: {
35175
+ type: 'body',
35176
+ property: 'name',
35177
+ },
35178
+ },
35179
+ },
35180
+ {
35181
+ displayName: 'Customer Id',
35182
+ name: 'customerId',
35183
+ type: 'options',
35184
+ default: '',
35185
+ description: 'Existing active customer ID.',
35186
+ required: false,
35187
+ displayOptions: {
35188
+ show: {
35189
+ resource: ['sales-opportunities'],
35190
+ operation: ['PublicOpportunityController_update'],
35191
+ },
35192
+ },
35193
+ typeOptions: {
35194
+ loadOptionsMethod: 'loadCustomerOptions',
35195
+ },
35196
+ routing: {
35197
+ send: {
35198
+ type: 'body',
35199
+ property: 'customerId',
35200
+ },
35201
+ },
35202
+ },
35203
+ {
35204
+ displayName: 'Billing Company Id',
35205
+ name: 'billingCompanyId',
35206
+ type: 'string',
35207
+ default: '',
35208
+ description: 'WorkBuddy billing company ID, not a CRM Company account ID.',
35209
+ required: false,
35210
+ displayOptions: {
35211
+ show: {
35212
+ resource: ['sales-opportunities'],
35213
+ operation: ['PublicOpportunityController_update'],
35214
+ },
35215
+ },
35216
+ routing: {
35217
+ send: {
35218
+ type: 'body',
35219
+ property: 'billingCompanyId',
35220
+ },
35221
+ },
35222
+ },
35223
+ {
35224
+ displayName: 'Owner Id',
35225
+ name: 'ownerId',
35226
+ type: 'options',
35227
+ default: '',
35228
+ description: 'Employee owner ID, matching the legacy Opportunity owner picker.',
35229
+ required: false,
35230
+ displayOptions: {
35231
+ show: {
35232
+ resource: ['sales-opportunities'],
35233
+ operation: ['PublicOpportunityController_update'],
35234
+ },
35235
+ },
35236
+ typeOptions: {
35237
+ loadOptionsMethod: 'loadEmployeeOptions',
35238
+ },
35239
+ routing: {
35240
+ send: {
35241
+ type: 'body',
35242
+ property: 'ownerId',
35243
+ },
35244
+ },
35245
+ },
35246
+ {
35247
+ displayName: 'Area Manager Id',
35248
+ name: 'areaManagerId',
35249
+ type: 'string',
35250
+ default: '',
35251
+ description: 'area manager ID',
35252
+ required: false,
35253
+ displayOptions: {
35254
+ show: {
35255
+ resource: ['sales-opportunities'],
35256
+ operation: ['PublicOpportunityController_update'],
35257
+ },
35258
+ },
35259
+ routing: {
35260
+ send: {
35261
+ type: 'body',
35262
+ property: 'areaManagerId',
35263
+ },
35264
+ },
35265
+ },
35266
+ {
35267
+ displayName: 'Description',
35268
+ name: 'description',
35269
+ type: 'string',
35270
+ default: '',
35271
+ description: 'Detailed description',
35272
+ required: false,
35273
+ displayOptions: {
35274
+ show: {
35275
+ resource: ['sales-opportunities'],
35276
+ operation: ['PublicOpportunityController_update'],
35277
+ },
35278
+ },
35279
+ routing: {
35280
+ send: {
35281
+ type: 'body',
35282
+ property: 'description',
35283
+ },
35284
+ },
35285
+ },
35286
+ {
35287
+ displayName: 'Amount',
35288
+ name: 'amount',
35289
+ type: 'number',
35290
+ default: 0,
35291
+ description: '',
35292
+ required: false,
35293
+ displayOptions: {
35294
+ show: {
35295
+ resource: ['sales-opportunities'],
35296
+ operation: ['PublicOpportunityController_update'],
35297
+ },
35298
+ },
35299
+ routing: {
35300
+ send: {
35301
+ type: 'body',
35302
+ property: 'amount',
35303
+ },
35304
+ },
35305
+ },
35306
+ {
35307
+ displayName: 'Probability',
35308
+ name: 'probability',
35309
+ type: 'number',
35310
+ default: 0,
35311
+ description: 'Estimated probability. Stage changes use the selected stage probability, as in the UI.',
35312
+ required: false,
35313
+ displayOptions: {
35314
+ show: {
35315
+ resource: ['sales-opportunities'],
35316
+ operation: ['PublicOpportunityController_update'],
35317
+ },
35318
+ },
35319
+ routing: {
35320
+ send: {
35321
+ type: 'body',
35322
+ property: 'probability',
35323
+ },
35324
+ },
35325
+ },
35326
+ {
35327
+ displayName: 'Expected Close',
35328
+ name: 'expectedClose',
35329
+ type: 'string',
35330
+ default: '',
35331
+ description: '',
35332
+ required: false,
35333
+ displayOptions: {
35334
+ show: {
35335
+ resource: ['sales-opportunities'],
35336
+ operation: ['PublicOpportunityController_update'],
35337
+ },
35338
+ },
35339
+ routing: {
35340
+ send: {
35341
+ type: 'body',
35342
+ property: 'expectedClose',
35343
+ },
35344
+ },
35345
+ },
35346
+ {
35347
+ displayName: 'Job Type Id',
35348
+ name: 'jobTypeId',
35349
+ type: 'string',
35350
+ default: '',
35351
+ description: 'job type ID',
35352
+ required: false,
35353
+ displayOptions: {
35354
+ show: {
35355
+ resource: ['sales-opportunities'],
35356
+ operation: ['PublicOpportunityController_update'],
35357
+ },
35358
+ },
35359
+ routing: {
35360
+ send: {
35361
+ type: 'body',
35362
+ property: 'jobTypeId',
35363
+ },
35364
+ },
35365
+ },
35366
+ {
35367
+ displayName: 'Source Id',
35368
+ name: 'sourceId',
35369
+ type: 'string',
35370
+ default: '',
35371
+ description: 'Lead Source label ID from GET /settings/tags?type=lead-source.',
35372
+ required: false,
35373
+ displayOptions: {
35374
+ show: {
35375
+ resource: ['sales-opportunities'],
35376
+ operation: ['PublicOpportunityController_update'],
35377
+ },
35378
+ },
35379
+ routing: {
35380
+ send: {
35381
+ type: 'body',
35382
+ property: 'sourceId',
35383
+ },
35384
+ },
35385
+ },
35386
+ {
35387
+ displayName: 'Tag Ids',
35388
+ name: 'tagIds',
35389
+ type: 'string',
35390
+ default: '',
35391
+ description: 'Opportunity label IDs from GET /settings/tags?type=opportunity. Null or [] clears the selection.',
35392
+ required: false,
35393
+ displayOptions: {
35394
+ show: {
35395
+ resource: ['sales-opportunities'],
35396
+ operation: ['PublicOpportunityController_update'],
35397
+ },
35398
+ },
35399
+ routing: {
35400
+ send: {
35401
+ type: 'body',
35402
+ property: 'tagIds',
35403
+ },
35404
+ },
35405
+ },
35406
+ {
35407
+ displayName: 'Site Id',
35408
+ name: 'siteId',
35409
+ type: 'options',
35410
+ default: '',
35411
+ description: 'Optional CRM site belonging to the selected customer. Use site instead for an ad-hoc address.',
35412
+ required: false,
35413
+ displayOptions: {
35414
+ show: {
35415
+ resource: ['sales-opportunities'],
35416
+ operation: ['PublicOpportunityController_update'],
35417
+ },
35418
+ },
35419
+ typeOptions: {
35420
+ loadOptionsMethod: 'loadSiteOptions',
35421
+ },
35422
+ routing: {
35423
+ send: {
35424
+ type: 'body',
35425
+ property: 'siteId',
35426
+ },
35427
+ },
35428
+ },
35429
+ {
35430
+ displayName: 'Site',
35431
+ name: 'site',
35432
+ type: 'string',
35433
+ default: '',
35434
+ description: 'Optional ad-hoc site snapshot. Does not create a CRM site. Cannot be supplied with siteId.',
35435
+ required: false,
35436
+ displayOptions: {
35437
+ show: {
35438
+ resource: ['sales-opportunities'],
35439
+ operation: ['PublicOpportunityController_update'],
35440
+ },
35441
+ },
35442
+ routing: {
35443
+ send: {
35444
+ type: 'body',
35445
+ property: 'site',
35446
+ },
35447
+ },
35448
+ },
35449
+ {
35450
+ displayName: 'Contact Id',
35451
+ name: 'contactId',
35452
+ type: 'string',
35453
+ default: '',
35454
+ description: 'Optional contact belonging to the customer or selected site.',
35455
+ required: false,
35456
+ displayOptions: {
35457
+ show: {
35458
+ resource: ['sales-opportunities'],
35459
+ operation: ['PublicOpportunityController_update'],
35460
+ },
35461
+ },
35462
+ routing: {
35463
+ send: {
35464
+ type: 'body',
35465
+ property: 'contactId',
35466
+ },
35467
+ },
35468
+ },
35469
+ {
35470
+ displayName: 'Site Contact Id',
35471
+ name: 'siteContactId',
35472
+ type: 'string',
35473
+ default: '',
35474
+ description: 'Site-contact snapshot from a contact belonging to the customer or selected site. Null clears it.',
35475
+ required: false,
35476
+ displayOptions: {
35477
+ show: {
35478
+ resource: ['sales-opportunities'],
35479
+ operation: ['PublicOpportunityController_update'],
35480
+ },
35481
+ },
35482
+ routing: {
35483
+ send: {
35484
+ type: 'body',
35485
+ property: 'siteContactId',
35486
+ },
35487
+ },
35488
+ },
35489
+ {
35490
+ displayName: 'Contact',
35491
+ name: 'contact',
35492
+ type: 'string',
35493
+ default: '',
35494
+ description: 'Optional name-only ad-hoc contact snapshot, matching the stored Opportunity contact. Cannot be supplied with contactId. Create richer contacts through the CRM API and supply contactId.',
35495
+ required: false,
35496
+ displayOptions: {
35497
+ show: {
35498
+ resource: ['sales-opportunities'],
35499
+ operation: ['PublicOpportunityController_update'],
35500
+ },
35501
+ },
35502
+ routing: {
35503
+ send: {
35504
+ type: 'body',
35505
+ property: 'contact',
35506
+ },
35507
+ },
35508
+ },
35509
+ {
35510
+ displayName: 'Customer Site Id',
35511
+ name: 'customerSiteId',
35512
+ type: 'string',
35513
+ default: '',
35514
+ description: 'Optional customer-side address site ID belonging to the selected customer.',
35515
+ required: false,
35516
+ displayOptions: {
35517
+ show: {
35518
+ resource: ['sales-opportunities'],
35519
+ operation: ['PublicOpportunityController_update'],
35520
+ },
35521
+ },
35522
+ routing: {
35523
+ send: {
35524
+ type: 'body',
35525
+ property: 'customerSiteId',
35526
+ },
35527
+ },
35528
+ },
35529
+ {
35530
+ displayName: 'Id',
35531
+ name: 'id',
35532
+ type: 'string',
35533
+ default: '',
35534
+ description: 'WorkBuddy Opportunity ID',
35535
+ required: true,
35536
+ displayOptions: {
35537
+ show: {
35538
+ resource: ['sales-opportunities'],
35539
+ operation: ['PublicOpportunityController_changeStage'],
35540
+ },
35541
+ },
35542
+ },
35543
+ {
35544
+ displayName: 'Stage Id',
35545
+ name: 'stageId',
35546
+ type: 'string',
35547
+ default: '',
35548
+ description: 'Stage ID or stage number',
35549
+ required: true,
35550
+ displayOptions: {
35551
+ show: {
35552
+ resource: ['sales-opportunities'],
35553
+ operation: ['PublicOpportunityController_changeStage'],
35554
+ },
35555
+ },
35556
+ routing: {
35557
+ send: {
35558
+ type: 'body',
35559
+ property: 'stageId',
35560
+ },
35561
+ },
35562
+ },
35563
+ {
35564
+ displayName: 'Lost Reason Id',
35565
+ name: 'lostReasonId',
35566
+ type: 'string',
35567
+ default: '',
35568
+ description: 'Opportunity Lost Reason label ID from GET /settings/tags?type=opportunity-lost.',
35569
+ required: false,
35570
+ displayOptions: {
35571
+ show: {
35572
+ resource: ['sales-opportunities'],
35573
+ operation: ['PublicOpportunityController_changeStage'],
35574
+ },
35575
+ },
35576
+ routing: {
35577
+ send: {
35578
+ type: 'body',
35579
+ property: 'lostReasonId',
35580
+ },
35581
+ },
35582
+ },
35583
+ {
35584
+ displayName: 'Lost Reason Note',
35585
+ name: 'lostReasonNote',
35586
+ type: 'string',
35587
+ default: '',
35588
+ description: '',
35589
+ required: false,
35590
+ displayOptions: {
35591
+ show: {
35592
+ resource: ['sales-opportunities'],
35593
+ operation: ['PublicOpportunityController_changeStage'],
35594
+ },
35595
+ },
35596
+ routing: {
35597
+ send: {
35598
+ type: 'body',
35599
+ property: 'lostReasonNote',
35600
+ },
35601
+ },
35602
+ },
32601
35603
  // Mcp Operations
32602
35604
  {
32603
35605
  displayName: 'Operation',