@workbuddy/cli-edge 1.0.5 → 1.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +366 -223
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -2709,7 +2709,7 @@ var operations = [
2709
2709
  source: "body",
2710
2710
  type: "string",
2711
2711
  required: false,
2712
- description: "",
2712
+ description: "Search mode",
2713
2713
  enumValues: ["jobs", "stages"]
2714
2714
  },
2715
2715
  {
@@ -2719,7 +2719,7 @@ var operations = [
2719
2719
  source: "body",
2720
2720
  type: "integer",
2721
2721
  required: false,
2722
- description: ""
2722
+ description: "Maximum number of results to return"
2723
2723
  },
2724
2724
  {
2725
2725
  name: "cursor",
@@ -2728,7 +2728,7 @@ var operations = [
2728
2728
  source: "body",
2729
2729
  type: "string",
2730
2730
  required: false,
2731
- description: ""
2731
+ description: "Pagination cursor from a previous response"
2732
2732
  },
2733
2733
  {
2734
2734
  name: "sortBy",
@@ -2737,7 +2737,7 @@ var operations = [
2737
2737
  source: "body",
2738
2738
  type: "string",
2739
2739
  required: false,
2740
- description: "",
2740
+ description: "Field to sort results by",
2741
2741
  enumValues: ["created_at", "due_date", "completed_date", "priority"]
2742
2742
  },
2743
2743
  {
@@ -2747,7 +2747,7 @@ var operations = [
2747
2747
  source: "body",
2748
2748
  type: "string",
2749
2749
  required: false,
2750
- description: "",
2750
+ description: "Sort direction: asc or desc",
2751
2751
  enumValues: ["asc", "desc"]
2752
2752
  },
2753
2753
  {
@@ -2757,7 +2757,7 @@ var operations = [
2757
2757
  source: "body",
2758
2758
  type: "array",
2759
2759
  required: false,
2760
- description: ""
2760
+ description: "Status filter"
2761
2761
  },
2762
2762
  {
2763
2763
  name: "customer",
@@ -2766,7 +2766,7 @@ var operations = [
2766
2766
  source: "body",
2767
2767
  type: "array",
2768
2768
  required: false,
2769
- description: ""
2769
+ description: "Inline customer object — alternative to customerId"
2770
2770
  },
2771
2771
  {
2772
2772
  name: "site",
@@ -2775,7 +2775,7 @@ var operations = [
2775
2775
  source: "body",
2776
2776
  type: "array",
2777
2777
  required: false,
2778
- description: ""
2778
+ description: "Inline site object — alternative to siteId"
2779
2779
  },
2780
2780
  {
2781
2781
  name: "type",
@@ -2883,7 +2883,7 @@ var operations = [
2883
2883
  source: "body",
2884
2884
  type: "string",
2885
2885
  required: false,
2886
- description: ""
2886
+ description: "Free-text search query"
2887
2887
  },
2888
2888
  {
2889
2889
  name: "createdDate",
@@ -2892,7 +2892,7 @@ var operations = [
2892
2892
  source: "body",
2893
2893
  type: "object",
2894
2894
  required: false,
2895
- description: ""
2895
+ description: "Date range filter for creation date"
2896
2896
  },
2897
2897
  {
2898
2898
  name: "dueDate",
@@ -2901,7 +2901,7 @@ var operations = [
2901
2901
  source: "body",
2902
2902
  type: "object",
2903
2903
  required: false,
2904
- description: ""
2904
+ description: "Due date (ISO 8601 datetime)"
2905
2905
  },
2906
2906
  {
2907
2907
  name: "completedDate",
@@ -2910,7 +2910,7 @@ var operations = [
2910
2910
  source: "body",
2911
2911
  type: "object",
2912
2912
  required: false,
2913
- description: ""
2913
+ description: "Completion date (ISO 8601 datetime)"
2914
2914
  },
2915
2915
  {
2916
2916
  name: "finalisedDate",
@@ -2919,7 +2919,7 @@ var operations = [
2919
2919
  source: "body",
2920
2920
  type: "object",
2921
2921
  required: false,
2922
- description: ""
2922
+ description: "Finalisation date (ISO 8601 datetime)"
2923
2923
  },
2924
2924
  {
2925
2925
  name: "stageDueDate",
@@ -2928,7 +2928,7 @@ var operations = [
2928
2928
  source: "body",
2929
2929
  type: "object",
2930
2930
  required: false,
2931
- description: ""
2931
+ description: "stage due date (ISO 8601 datetime)"
2932
2932
  },
2933
2933
  {
2934
2934
  name: "stageCompletedDate",
@@ -2937,7 +2937,7 @@ var operations = [
2937
2937
  source: "body",
2938
2938
  type: "object",
2939
2939
  required: false,
2940
- description: ""
2940
+ description: "stage completed date (ISO 8601 datetime)"
2941
2941
  },
2942
2942
  {
2943
2943
  name: "fields",
@@ -2946,7 +2946,7 @@ var operations = [
2946
2946
  source: "body",
2947
2947
  type: "array",
2948
2948
  required: false,
2949
- description: ""
2949
+ description: "Field projection — array of field names to include in the response"
2950
2950
  },
2951
2951
  {
2952
2952
  name: "include",
@@ -2955,7 +2955,7 @@ var operations = [
2955
2955
  source: "body",
2956
2956
  type: "array",
2957
2957
  required: false,
2958
- description: ""
2958
+ description: "Related entities to include in the response"
2959
2959
  },
2960
2960
  {
2961
2961
  name: "raw-body",
@@ -3013,7 +3013,7 @@ var operations = [
3013
3013
  source: "body",
3014
3014
  type: "string",
3015
3015
  required: true,
3016
- description: ""
3016
+ description: "Reason for the action (e.g. cancellation reason)"
3017
3017
  },
3018
3018
  {
3019
3019
  name: "raw-body",
@@ -3042,7 +3042,7 @@ var operations = [
3042
3042
  source: "body",
3043
3043
  type: "string",
3044
3044
  required: false,
3045
- description: ""
3045
+ description: "Display name"
3046
3046
  },
3047
3047
  {
3048
3048
  name: "description",
@@ -3051,7 +3051,7 @@ var operations = [
3051
3051
  source: "body",
3052
3052
  type: "string",
3053
3053
  required: false,
3054
- description: ""
3054
+ description: "Detailed description"
3055
3055
  },
3056
3056
  {
3057
3057
  name: "customerId",
@@ -3060,7 +3060,7 @@ var operations = [
3060
3060
  source: "body",
3061
3061
  type: "string",
3062
3062
  required: false,
3063
- description: ""
3063
+ description: "Customer ID — use /crm/customers to look up"
3064
3064
  },
3065
3065
  {
3066
3066
  name: "customer",
@@ -3069,7 +3069,7 @@ var operations = [
3069
3069
  source: "body",
3070
3070
  type: "object",
3071
3071
  required: false,
3072
- description: ""
3072
+ description: "Inline customer object — alternative to customerId"
3073
3073
  },
3074
3074
  {
3075
3075
  name: "siteId",
@@ -3078,7 +3078,7 @@ var operations = [
3078
3078
  source: "body",
3079
3079
  type: "string",
3080
3080
  required: false,
3081
- description: ""
3081
+ description: "Site ID — use /crm/sites to look up"
3082
3082
  },
3083
3083
  {
3084
3084
  name: "site",
@@ -3087,7 +3087,7 @@ var operations = [
3087
3087
  source: "body",
3088
3088
  type: "object",
3089
3089
  required: false,
3090
- description: ""
3090
+ description: "Inline site object — alternative to siteId"
3091
3091
  },
3092
3092
  {
3093
3093
  name: "contactId",
@@ -3096,7 +3096,7 @@ var operations = [
3096
3096
  source: "body",
3097
3097
  type: "string",
3098
3098
  required: false,
3099
- description: ""
3099
+ description: "Contact ID — use /crm/contacts to look up"
3100
3100
  },
3101
3101
  {
3102
3102
  name: "contact",
@@ -3105,7 +3105,7 @@ var operations = [
3105
3105
  source: "body",
3106
3106
  type: "object",
3107
3107
  required: false,
3108
- description: ""
3108
+ description: "Inline contact object — alternative to contactId"
3109
3109
  },
3110
3110
  {
3111
3111
  name: "typeId",
@@ -3114,7 +3114,7 @@ var operations = [
3114
3114
  source: "body",
3115
3115
  type: "string",
3116
3116
  required: false,
3117
- description: ""
3117
+ description: "Job type ID — use /settings/job-types to look up"
3118
3118
  },
3119
3119
  {
3120
3120
  name: "priorityId",
@@ -3123,7 +3123,7 @@ var operations = [
3123
3123
  source: "body",
3124
3124
  type: "string",
3125
3125
  required: false,
3126
- description: ""
3126
+ description: "Priority ID — use /settings/priorities to look up"
3127
3127
  },
3128
3128
  {
3129
3129
  name: "priceBookId",
@@ -3132,7 +3132,7 @@ var operations = [
3132
3132
  source: "body",
3133
3133
  type: "string",
3134
3134
  required: false,
3135
- description: ""
3135
+ description: "Price book ID for job pricing"
3136
3136
  },
3137
3137
  {
3138
3138
  name: "ownerId",
@@ -3141,7 +3141,7 @@ var operations = [
3141
3141
  source: "body",
3142
3142
  type: "string",
3143
3143
  required: false,
3144
- description: ""
3144
+ description: "Owner (employee) ID — use /crm/employees to look up"
3145
3145
  },
3146
3146
  {
3147
3147
  name: "fieldSupervisorId",
@@ -3150,7 +3150,7 @@ var operations = [
3150
3150
  source: "body",
3151
3151
  type: "string",
3152
3152
  required: false,
3153
- description: ""
3153
+ description: "Field supervisor (employee) ID — use /crm/employees to look up"
3154
3154
  },
3155
3155
  {
3156
3156
  name: "zoneId",
@@ -3159,7 +3159,7 @@ var operations = [
3159
3159
  source: "body",
3160
3160
  type: "string",
3161
3161
  required: false,
3162
- description: ""
3162
+ description: "Zone ID — use /settings/zones to look up"
3163
3163
  },
3164
3164
  {
3165
3165
  name: "tagIds",
@@ -3168,7 +3168,7 @@ var operations = [
3168
3168
  source: "body",
3169
3169
  type: "array",
3170
3170
  required: false,
3171
- description: ""
3171
+ description: 'Array of tag IDs (comma-separated, e.g. "id1,id2") — use /settings/tags to look up'
3172
3172
  },
3173
3173
  {
3174
3174
  name: "notes",
@@ -3177,7 +3177,7 @@ var operations = [
3177
3177
  source: "body",
3178
3178
  type: "string",
3179
3179
  required: false,
3180
- description: ""
3180
+ description: "Additional notes or comments"
3181
3181
  },
3182
3182
  {
3183
3183
  name: "reference",
@@ -3186,7 +3186,7 @@ var operations = [
3186
3186
  source: "body",
3187
3187
  type: "string",
3188
3188
  required: false,
3189
- description: ""
3189
+ description: "External reference number"
3190
3190
  },
3191
3191
  {
3192
3192
  name: "customerWO",
@@ -3195,7 +3195,7 @@ var operations = [
3195
3195
  source: "body",
3196
3196
  type: "string",
3197
3197
  required: false,
3198
- description: ""
3198
+ description: "Customer work order reference"
3199
3199
  },
3200
3200
  {
3201
3201
  name: "customerPO",
@@ -3204,7 +3204,7 @@ var operations = [
3204
3204
  source: "body",
3205
3205
  type: "string",
3206
3206
  required: false,
3207
- description: ""
3207
+ description: "Customer purchase order reference"
3208
3208
  },
3209
3209
  {
3210
3210
  name: "templateId",
@@ -3213,7 +3213,7 @@ var operations = [
3213
3213
  source: "body",
3214
3214
  type: "string",
3215
3215
  required: false,
3216
- description: ""
3216
+ description: "Template ID to pre-populate fields from a template"
3217
3217
  },
3218
3218
  {
3219
3219
  name: "startDate",
@@ -3222,7 +3222,7 @@ var operations = [
3222
3222
  source: "body",
3223
3223
  type: "string",
3224
3224
  required: false,
3225
- description: "",
3225
+ description: "Start date (ISO 8601 datetime)",
3226
3226
  format: "date-time"
3227
3227
  },
3228
3228
  {
@@ -3232,7 +3232,7 @@ var operations = [
3232
3232
  source: "body",
3233
3233
  type: "string",
3234
3234
  required: false,
3235
- description: "",
3235
+ description: "Due date (ISO 8601 datetime)",
3236
3236
  format: "date-time"
3237
3237
  },
3238
3238
  {
@@ -3242,7 +3242,7 @@ var operations = [
3242
3242
  source: "body",
3243
3243
  type: "object",
3244
3244
  required: false,
3245
- description: ""
3245
+ description: "Custom fields as key-value pairs — validated against tenant field definitions"
3246
3246
  },
3247
3247
  {
3248
3248
  name: "raw-body",
@@ -3280,7 +3280,7 @@ var operations = [
3280
3280
  source: "body",
3281
3281
  type: "string",
3282
3282
  required: false,
3283
- description: "",
3283
+ description: "For optimistic concurrency — update fails if entity was modified after this timestamp",
3284
3284
  format: "date-time"
3285
3285
  },
3286
3286
  {
@@ -3290,7 +3290,7 @@ var operations = [
3290
3290
  source: "body",
3291
3291
  type: "string",
3292
3292
  required: false,
3293
- description: ""
3293
+ description: "Display name"
3294
3294
  },
3295
3295
  {
3296
3296
  name: "description",
@@ -3299,7 +3299,7 @@ var operations = [
3299
3299
  source: "body",
3300
3300
  type: "string",
3301
3301
  required: false,
3302
- description: ""
3302
+ description: "Detailed description"
3303
3303
  },
3304
3304
  {
3305
3305
  name: "siteId",
@@ -3308,7 +3308,7 @@ var operations = [
3308
3308
  source: "body",
3309
3309
  type: "string",
3310
3310
  required: false,
3311
- description: ""
3311
+ description: "Site ID — use /crm/sites to look up"
3312
3312
  },
3313
3313
  {
3314
3314
  name: "contactId",
@@ -3317,7 +3317,7 @@ var operations = [
3317
3317
  source: "body",
3318
3318
  type: "string",
3319
3319
  required: false,
3320
- description: ""
3320
+ description: "Contact ID — use /crm/contacts to look up"
3321
3321
  },
3322
3322
  {
3323
3323
  name: "typeId",
@@ -3326,7 +3326,7 @@ var operations = [
3326
3326
  source: "body",
3327
3327
  type: "string",
3328
3328
  required: false,
3329
- description: ""
3329
+ description: "Job type ID — use /settings/job-types to look up"
3330
3330
  },
3331
3331
  {
3332
3332
  name: "priorityId",
@@ -3335,7 +3335,7 @@ var operations = [
3335
3335
  source: "body",
3336
3336
  type: "string",
3337
3337
  required: false,
3338
- description: ""
3338
+ description: "Priority ID — use /settings/priorities to look up"
3339
3339
  },
3340
3340
  {
3341
3341
  name: "priceBookId",
@@ -3344,7 +3344,7 @@ var operations = [
3344
3344
  source: "body",
3345
3345
  type: "string",
3346
3346
  required: false,
3347
- description: ""
3347
+ description: "Price book ID for job pricing"
3348
3348
  },
3349
3349
  {
3350
3350
  name: "ownerId",
@@ -3353,7 +3353,7 @@ var operations = [
3353
3353
  source: "body",
3354
3354
  type: "string",
3355
3355
  required: false,
3356
- description: ""
3356
+ description: "Owner (employee) ID — use /crm/employees to look up"
3357
3357
  },
3358
3358
  {
3359
3359
  name: "fieldSupervisorId",
@@ -3362,7 +3362,7 @@ var operations = [
3362
3362
  source: "body",
3363
3363
  type: "string",
3364
3364
  required: false,
3365
- description: ""
3365
+ description: "Field supervisor (employee) ID — use /crm/employees to look up"
3366
3366
  },
3367
3367
  {
3368
3368
  name: "zoneId",
@@ -3371,7 +3371,7 @@ var operations = [
3371
3371
  source: "body",
3372
3372
  type: "string",
3373
3373
  required: false,
3374
- description: ""
3374
+ description: "Zone ID — use /settings/zones to look up"
3375
3375
  },
3376
3376
  {
3377
3377
  name: "tagIds",
@@ -3380,7 +3380,7 @@ var operations = [
3380
3380
  source: "body",
3381
3381
  type: "array",
3382
3382
  required: false,
3383
- description: ""
3383
+ description: 'Array of tag IDs (comma-separated, e.g. "id1,id2") — use /settings/tags to look up'
3384
3384
  },
3385
3385
  {
3386
3386
  name: "notes",
@@ -3389,7 +3389,7 @@ var operations = [
3389
3389
  source: "body",
3390
3390
  type: "string",
3391
3391
  required: false,
3392
- description: ""
3392
+ description: "Additional notes or comments"
3393
3393
  },
3394
3394
  {
3395
3395
  name: "reference",
@@ -3398,7 +3398,7 @@ var operations = [
3398
3398
  source: "body",
3399
3399
  type: "string",
3400
3400
  required: false,
3401
- description: ""
3401
+ description: "External reference number"
3402
3402
  },
3403
3403
  {
3404
3404
  name: "customerWO",
@@ -3407,7 +3407,7 @@ var operations = [
3407
3407
  source: "body",
3408
3408
  type: "string",
3409
3409
  required: false,
3410
- description: ""
3410
+ description: "Customer work order reference"
3411
3411
  },
3412
3412
  {
3413
3413
  name: "customerPO",
@@ -3416,7 +3416,7 @@ var operations = [
3416
3416
  source: "body",
3417
3417
  type: "string",
3418
3418
  required: false,
3419
- description: ""
3419
+ description: "Customer purchase order reference"
3420
3420
  },
3421
3421
  {
3422
3422
  name: "startDate",
@@ -3425,7 +3425,7 @@ var operations = [
3425
3425
  source: "body",
3426
3426
  type: "string",
3427
3427
  required: false,
3428
- description: "",
3428
+ description: "Start date (ISO 8601 datetime)",
3429
3429
  format: "date-time"
3430
3430
  },
3431
3431
  {
@@ -3435,7 +3435,7 @@ var operations = [
3435
3435
  source: "body",
3436
3436
  type: "string",
3437
3437
  required: false,
3438
- description: "",
3438
+ description: "Due date (ISO 8601 datetime)",
3439
3439
  format: "date-time"
3440
3440
  },
3441
3441
  {
@@ -3445,7 +3445,7 @@ var operations = [
3445
3445
  source: "body",
3446
3446
  type: "object",
3447
3447
  required: false,
3448
- description: ""
3448
+ description: "Custom fields as key-value pairs — validated against tenant field definitions"
3449
3449
  },
3450
3450
  {
3451
3451
  name: "raw-body",
@@ -3646,7 +3646,7 @@ var operations = [
3646
3646
  source: "body",
3647
3647
  type: "string",
3648
3648
  required: true,
3649
- description: ""
3649
+ description: "Job ID or job number (e.g. J12345)"
3650
3650
  },
3651
3651
  {
3652
3652
  name: "name",
@@ -3655,7 +3655,7 @@ var operations = [
3655
3655
  source: "body",
3656
3656
  type: "string",
3657
3657
  required: true,
3658
- description: ""
3658
+ description: "Display name"
3659
3659
  },
3660
3660
  {
3661
3661
  name: "workCategoryId",
@@ -3664,7 +3664,7 @@ var operations = [
3664
3664
  source: "body",
3665
3665
  type: "string",
3666
3666
  required: false,
3667
- description: ""
3667
+ description: "Work category ID — use /settings/work-types to look up"
3668
3668
  },
3669
3669
  {
3670
3670
  name: "sequence",
@@ -3673,7 +3673,7 @@ var operations = [
3673
3673
  source: "body",
3674
3674
  type: "number",
3675
3675
  required: false,
3676
- description: ""
3676
+ description: "Display order / sequence number"
3677
3677
  },
3678
3678
  {
3679
3679
  name: "startDate",
@@ -3682,7 +3682,7 @@ var operations = [
3682
3682
  source: "body",
3683
3683
  type: "string",
3684
3684
  required: false,
3685
- description: ""
3685
+ description: "Start date (ISO 8601 datetime)"
3686
3686
  },
3687
3687
  {
3688
3688
  name: "dueDate",
@@ -3691,7 +3691,7 @@ var operations = [
3691
3691
  source: "body",
3692
3692
  type: "string",
3693
3693
  required: false,
3694
- description: ""
3694
+ description: "Due date (ISO 8601 datetime)"
3695
3695
  },
3696
3696
  {
3697
3697
  name: "notes",
@@ -3700,7 +3700,7 @@ var operations = [
3700
3700
  source: "body",
3701
3701
  type: "string",
3702
3702
  required: false,
3703
- description: ""
3703
+ description: "Additional notes or comments"
3704
3704
  },
3705
3705
  {
3706
3706
  name: "customFields",
@@ -3709,7 +3709,7 @@ var operations = [
3709
3709
  source: "body",
3710
3710
  type: "object",
3711
3711
  required: false,
3712
- description: ""
3712
+ description: "Custom fields as key-value pairs — validated against tenant field definitions"
3713
3713
  },
3714
3714
  {
3715
3715
  name: "raw-body",
@@ -3747,7 +3747,7 @@ var operations = [
3747
3747
  source: "body",
3748
3748
  type: "string",
3749
3749
  required: false,
3750
- description: ""
3750
+ description: "Display name"
3751
3751
  },
3752
3752
  {
3753
3753
  name: "workCategoryId",
@@ -3756,7 +3756,7 @@ var operations = [
3756
3756
  source: "body",
3757
3757
  type: "string",
3758
3758
  required: false,
3759
- description: ""
3759
+ description: "Work category ID — use /settings/work-types to look up"
3760
3760
  },
3761
3761
  {
3762
3762
  name: "startDate",
@@ -3765,7 +3765,7 @@ var operations = [
3765
3765
  source: "body",
3766
3766
  type: "string",
3767
3767
  required: false,
3768
- description: ""
3768
+ description: "Start date (ISO 8601 datetime)"
3769
3769
  },
3770
3770
  {
3771
3771
  name: "dueDate",
@@ -3774,7 +3774,7 @@ var operations = [
3774
3774
  source: "body",
3775
3775
  type: "string",
3776
3776
  required: false,
3777
- description: ""
3777
+ description: "Due date (ISO 8601 datetime)"
3778
3778
  },
3779
3779
  {
3780
3780
  name: "notes",
@@ -3783,7 +3783,7 @@ var operations = [
3783
3783
  source: "body",
3784
3784
  type: "string",
3785
3785
  required: false,
3786
- description: ""
3786
+ description: "Additional notes or comments"
3787
3787
  },
3788
3788
  {
3789
3789
  name: "tagsSet",
@@ -3852,7 +3852,7 @@ var operations = [
3852
3852
  source: "body",
3853
3853
  type: "object",
3854
3854
  required: false,
3855
- description: ""
3855
+ description: "Custom fields as key-value pairs — validated against tenant field definitions"
3856
3856
  },
3857
3857
  {
3858
3858
  name: "raw-body",
@@ -3930,7 +3930,7 @@ var operations = [
3930
3930
  source: "body",
3931
3931
  type: "string",
3932
3932
  required: false,
3933
- description: "",
3933
+ description: "Completion date (ISO 8601 datetime)",
3934
3934
  format: "date-time"
3935
3935
  },
3936
3936
  {
@@ -3940,7 +3940,7 @@ var operations = [
3940
3940
  source: "body",
3941
3941
  type: "string",
3942
3942
  required: false,
3943
- description: ""
3943
+ description: "Additional notes or comments"
3944
3944
  },
3945
3945
  {
3946
3946
  name: "raw-body",
@@ -3978,7 +3978,7 @@ var operations = [
3978
3978
  source: "body",
3979
3979
  type: "string",
3980
3980
  required: false,
3981
- description: "",
3981
+ description: "Finalisation date (ISO 8601 datetime)",
3982
3982
  format: "date-time"
3983
3983
  },
3984
3984
  {
@@ -4179,7 +4179,7 @@ var operations = [
4179
4179
  source: "body",
4180
4180
  type: "string",
4181
4181
  required: true,
4182
- description: ""
4182
+ description: "Stage ID or stage number"
4183
4183
  },
4184
4184
  {
4185
4185
  name: "contactId",
@@ -4188,7 +4188,7 @@ var operations = [
4188
4188
  source: "body",
4189
4189
  type: "string",
4190
4190
  required: true,
4191
- description: ""
4191
+ description: "Contact ID — use /crm/contacts to look up"
4192
4192
  },
4193
4193
  {
4194
4194
  name: "raw-body",
@@ -4358,7 +4358,7 @@ var operations = [
4358
4358
  source: "body",
4359
4359
  type: "string",
4360
4360
  required: true,
4361
- description: ""
4361
+ description: "Stage ID or stage number"
4362
4362
  },
4363
4363
  {
4364
4364
  name: "status",
@@ -4367,7 +4367,7 @@ var operations = [
4367
4367
  source: "body",
4368
4368
  type: "string",
4369
4369
  required: true,
4370
- description: "",
4370
+ description: "Status filter",
4371
4371
  enumValues: ["enroute", "onsite", "checkedout", "completed", "onhold"]
4372
4372
  },
4373
4373
  {
@@ -4623,7 +4623,7 @@ var operations = [
4623
4623
  source: "path",
4624
4624
  type: "string",
4625
4625
  required: true,
4626
- description: ""
4626
+ description: "Job ID or job number (e.g. J12345)"
4627
4627
  }
4628
4628
  ],
4629
4629
  hasRequestBody: false
@@ -4643,7 +4643,7 @@ var operations = [
4643
4643
  source: "path",
4644
4644
  type: "string",
4645
4645
  required: true,
4646
- description: ""
4646
+ description: "Job ID or job number (e.g. J12345)"
4647
4647
  },
4648
4648
  {
4649
4649
  name: "id",
@@ -4672,7 +4672,7 @@ var operations = [
4672
4672
  source: "path",
4673
4673
  type: "string",
4674
4674
  required: true,
4675
- description: ""
4675
+ description: "Job ID or job number (e.g. J12345)"
4676
4676
  },
4677
4677
  {
4678
4678
  name: "id",
@@ -4701,7 +4701,7 @@ var operations = [
4701
4701
  source: "path",
4702
4702
  type: "string",
4703
4703
  required: true,
4704
- description: ""
4704
+ description: "Job ID or job number (e.g. J12345)"
4705
4705
  },
4706
4706
  {
4707
4707
  name: "body",
@@ -4710,7 +4710,7 @@ var operations = [
4710
4710
  source: "body",
4711
4711
  type: "string",
4712
4712
  required: true,
4713
- description: ""
4713
+ description: "Message body content (HTML supported for email)"
4714
4714
  },
4715
4715
  {
4716
4716
  name: "labelIds",
@@ -4719,7 +4719,7 @@ var operations = [
4719
4719
  source: "body",
4720
4720
  type: "array",
4721
4721
  required: false,
4722
- description: ""
4722
+ description: 'Array of label/tag IDs to attach (comma-separated, e.g. "id1,id2")'
4723
4723
  },
4724
4724
  {
4725
4725
  name: "attachmentIds",
@@ -4728,7 +4728,7 @@ var operations = [
4728
4728
  source: "body",
4729
4729
  type: "array",
4730
4730
  required: false,
4731
- description: ""
4731
+ description: 'Attachment IDs from the upload endpoint (comma-separated, e.g. "id1,id2")'
4732
4732
  },
4733
4733
  {
4734
4734
  name: "sharing",
@@ -4737,7 +4737,7 @@ var operations = [
4737
4737
  source: "body",
4738
4738
  type: "object",
4739
4739
  required: false,
4740
- description: ""
4740
+ description: "Sharing options — control visibility to customer portal and field app"
4741
4741
  },
4742
4742
  {
4743
4743
  name: "raw-body",
@@ -4766,7 +4766,7 @@ var operations = [
4766
4766
  source: "path",
4767
4767
  type: "string",
4768
4768
  required: true,
4769
- description: ""
4769
+ description: "Job ID or job number (e.g. J12345)"
4770
4770
  },
4771
4771
  {
4772
4772
  name: "templateId",
@@ -4775,7 +4775,7 @@ var operations = [
4775
4775
  source: "body",
4776
4776
  type: "string",
4777
4777
  required: false,
4778
- description: ""
4778
+ description: "Template ID to pre-populate fields from a template"
4779
4779
  },
4780
4780
  {
4781
4781
  name: "subject",
@@ -4784,7 +4784,7 @@ var operations = [
4784
4784
  source: "body",
4785
4785
  type: "string",
4786
4786
  required: false,
4787
- description: ""
4787
+ description: "Email subject line"
4788
4788
  },
4789
4789
  {
4790
4790
  name: "body",
@@ -4793,7 +4793,7 @@ var operations = [
4793
4793
  source: "body",
4794
4794
  type: "string",
4795
4795
  required: false,
4796
- description: ""
4796
+ description: "Message body content (HTML supported for email)"
4797
4797
  },
4798
4798
  {
4799
4799
  name: "to",
@@ -4802,7 +4802,7 @@ var operations = [
4802
4802
  source: "body",
4803
4803
  type: "array",
4804
4804
  required: false,
4805
- description: ""
4805
+ description: "Recipients"
4806
4806
  },
4807
4807
  {
4808
4808
  name: "cc",
@@ -4811,7 +4811,7 @@ var operations = [
4811
4811
  source: "body",
4812
4812
  type: "array",
4813
4813
  required: false,
4814
- description: ""
4814
+ description: "CC recipients"
4815
4815
  },
4816
4816
  {
4817
4817
  name: "bcc",
@@ -4820,7 +4820,7 @@ var operations = [
4820
4820
  source: "body",
4821
4821
  type: "array",
4822
4822
  required: false,
4823
- description: ""
4823
+ description: "BCC recipients"
4824
4824
  },
4825
4825
  {
4826
4826
  name: "labelIds",
@@ -4829,7 +4829,7 @@ var operations = [
4829
4829
  source: "body",
4830
4830
  type: "array",
4831
4831
  required: false,
4832
- description: ""
4832
+ description: 'Array of label/tag IDs to attach (comma-separated, e.g. "id1,id2")'
4833
4833
  },
4834
4834
  {
4835
4835
  name: "attachmentIds",
@@ -4838,7 +4838,7 @@ var operations = [
4838
4838
  source: "body",
4839
4839
  type: "array",
4840
4840
  required: false,
4841
- description: ""
4841
+ description: 'Attachment IDs from the upload endpoint (comma-separated, e.g. "id1,id2")'
4842
4842
  },
4843
4843
  {
4844
4844
  name: "sharing",
@@ -4847,7 +4847,7 @@ var operations = [
4847
4847
  source: "body",
4848
4848
  type: "object",
4849
4849
  required: false,
4850
- description: ""
4850
+ description: "Sharing options — control visibility to customer portal and field app"
4851
4851
  },
4852
4852
  {
4853
4853
  name: "raw-body",
@@ -4876,7 +4876,7 @@ var operations = [
4876
4876
  source: "path",
4877
4877
  type: "string",
4878
4878
  required: true,
4879
- description: ""
4879
+ description: "Job ID or job number (e.g. J12345)"
4880
4880
  },
4881
4881
  {
4882
4882
  name: "templateId",
@@ -4885,7 +4885,7 @@ var operations = [
4885
4885
  source: "body",
4886
4886
  type: "string",
4887
4887
  required: false,
4888
- description: ""
4888
+ description: "Template ID to pre-populate fields from a template"
4889
4889
  },
4890
4890
  {
4891
4891
  name: "body",
@@ -4894,7 +4894,7 @@ var operations = [
4894
4894
  source: "body",
4895
4895
  type: "string",
4896
4896
  required: false,
4897
- description: ""
4897
+ description: "Message body content (HTML supported for email)"
4898
4898
  },
4899
4899
  {
4900
4900
  name: "to",
@@ -4903,7 +4903,7 @@ var operations = [
4903
4903
  source: "body",
4904
4904
  type: "array",
4905
4905
  required: false,
4906
- description: ""
4906
+ description: "Recipients"
4907
4907
  },
4908
4908
  {
4909
4909
  name: "labelIds",
@@ -4912,7 +4912,7 @@ var operations = [
4912
4912
  source: "body",
4913
4913
  type: "array",
4914
4914
  required: false,
4915
- description: ""
4915
+ description: 'Array of label/tag IDs to attach (comma-separated, e.g. "id1,id2")'
4916
4916
  },
4917
4917
  {
4918
4918
  name: "sharing",
@@ -4921,7 +4921,7 @@ var operations = [
4921
4921
  source: "body",
4922
4922
  type: "object",
4923
4923
  required: false,
4924
- description: ""
4924
+ description: "Sharing options — control visibility to customer portal and field app"
4925
4925
  },
4926
4926
  {
4927
4927
  name: "raw-body",
@@ -4950,7 +4950,7 @@ var operations = [
4950
4950
  source: "path",
4951
4951
  type: "string",
4952
4952
  required: true,
4953
- description: ""
4953
+ description: "Job ID or job number (e.g. J12345)"
4954
4954
  },
4955
4955
  {
4956
4956
  name: "direction",
@@ -4996,7 +4996,7 @@ var operations = [
4996
4996
  source: "body",
4997
4997
  type: "string",
4998
4998
  required: false,
4999
- description: "",
4999
+ description: "call date (ISO 8601 datetime)",
5000
5000
  format: "date-time"
5001
5001
  },
5002
5002
  {
@@ -5006,7 +5006,7 @@ var operations = [
5006
5006
  source: "body",
5007
5007
  type: "string",
5008
5008
  required: false,
5009
- description: ""
5009
+ description: "Message body content (HTML supported for email)"
5010
5010
  },
5011
5011
  {
5012
5012
  name: "labelIds",
@@ -5015,7 +5015,7 @@ var operations = [
5015
5015
  source: "body",
5016
5016
  type: "array",
5017
5017
  required: false,
5018
- description: ""
5018
+ description: 'Array of label/tag IDs to attach (comma-separated, e.g. "id1,id2")'
5019
5019
  },
5020
5020
  {
5021
5021
  name: "sharing",
@@ -5024,7 +5024,7 @@ var operations = [
5024
5024
  source: "body",
5025
5025
  type: "object",
5026
5026
  required: false,
5027
- description: ""
5027
+ description: "Sharing options — control visibility to customer portal and field app"
5028
5028
  },
5029
5029
  {
5030
5030
  name: "raw-body",
@@ -5053,7 +5053,7 @@ var operations = [
5053
5053
  source: "path",
5054
5054
  type: "string",
5055
5055
  required: true,
5056
- description: ""
5056
+ description: "Job ID or job number (e.g. J12345)"
5057
5057
  },
5058
5058
  {
5059
5059
  name: "body",
@@ -5062,7 +5062,7 @@ var operations = [
5062
5062
  source: "body",
5063
5063
  type: "string",
5064
5064
  required: true,
5065
- description: ""
5065
+ description: "Message body content (HTML supported for email)"
5066
5066
  },
5067
5067
  {
5068
5068
  name: "integrationType",
@@ -5080,7 +5080,7 @@ var operations = [
5080
5080
  source: "body",
5081
5081
  type: "object",
5082
5082
  required: false,
5083
- description: ""
5083
+ description: "Sharing options — control visibility to customer portal and field app"
5084
5084
  },
5085
5085
  {
5086
5086
  name: "raw-body",
@@ -5109,7 +5109,7 @@ var operations = [
5109
5109
  source: "path",
5110
5110
  type: "string",
5111
5111
  required: true,
5112
- description: ""
5112
+ description: "Stage ID or stage number"
5113
5113
  },
5114
5114
  {
5115
5115
  name: "jobId",
@@ -5138,7 +5138,7 @@ var operations = [
5138
5138
  source: "path",
5139
5139
  type: "string",
5140
5140
  required: true,
5141
- description: ""
5141
+ description: "Stage ID or stage number"
5142
5142
  },
5143
5143
  {
5144
5144
  name: "id",
@@ -5176,7 +5176,7 @@ var operations = [
5176
5176
  source: "path",
5177
5177
  type: "string",
5178
5178
  required: true,
5179
- description: ""
5179
+ description: "Stage ID or stage number"
5180
5180
  },
5181
5181
  {
5182
5182
  name: "id",
@@ -5214,7 +5214,7 @@ var operations = [
5214
5214
  source: "path",
5215
5215
  type: "string",
5216
5216
  required: true,
5217
- description: ""
5217
+ description: "Stage ID or stage number"
5218
5218
  },
5219
5219
  {
5220
5220
  name: "jobId",
@@ -5232,7 +5232,7 @@ var operations = [
5232
5232
  source: "body",
5233
5233
  type: "string",
5234
5234
  required: true,
5235
- description: ""
5235
+ description: "Message body content (HTML supported for email)"
5236
5236
  },
5237
5237
  {
5238
5238
  name: "labelIds",
@@ -5241,7 +5241,7 @@ var operations = [
5241
5241
  source: "body",
5242
5242
  type: "array",
5243
5243
  required: false,
5244
- description: ""
5244
+ description: 'Array of label/tag IDs to attach (comma-separated, e.g. "id1,id2")'
5245
5245
  },
5246
5246
  {
5247
5247
  name: "attachmentIds",
@@ -5250,7 +5250,7 @@ var operations = [
5250
5250
  source: "body",
5251
5251
  type: "array",
5252
5252
  required: false,
5253
- description: ""
5253
+ description: 'Attachment IDs from the upload endpoint (comma-separated, e.g. "id1,id2")'
5254
5254
  },
5255
5255
  {
5256
5256
  name: "sharing",
@@ -5259,7 +5259,7 @@ var operations = [
5259
5259
  source: "body",
5260
5260
  type: "object",
5261
5261
  required: false,
5262
- description: ""
5262
+ description: "Sharing options — control visibility to customer portal and field app"
5263
5263
  },
5264
5264
  {
5265
5265
  name: "raw-body",
@@ -5288,7 +5288,7 @@ var operations = [
5288
5288
  source: "path",
5289
5289
  type: "string",
5290
5290
  required: true,
5291
- description: ""
5291
+ description: "Stage ID or stage number"
5292
5292
  },
5293
5293
  {
5294
5294
  name: "jobId",
@@ -5306,7 +5306,7 @@ var operations = [
5306
5306
  source: "body",
5307
5307
  type: "string",
5308
5308
  required: false,
5309
- description: ""
5309
+ description: "Template ID to pre-populate fields from a template"
5310
5310
  },
5311
5311
  {
5312
5312
  name: "subject",
@@ -5315,7 +5315,7 @@ var operations = [
5315
5315
  source: "body",
5316
5316
  type: "string",
5317
5317
  required: false,
5318
- description: ""
5318
+ description: "Email subject line"
5319
5319
  },
5320
5320
  {
5321
5321
  name: "body",
@@ -5324,7 +5324,7 @@ var operations = [
5324
5324
  source: "body",
5325
5325
  type: "string",
5326
5326
  required: false,
5327
- description: ""
5327
+ description: "Message body content (HTML supported for email)"
5328
5328
  },
5329
5329
  {
5330
5330
  name: "to",
@@ -5333,7 +5333,7 @@ var operations = [
5333
5333
  source: "body",
5334
5334
  type: "array",
5335
5335
  required: false,
5336
- description: ""
5336
+ description: "Recipients"
5337
5337
  },
5338
5338
  {
5339
5339
  name: "cc",
@@ -5342,7 +5342,7 @@ var operations = [
5342
5342
  source: "body",
5343
5343
  type: "array",
5344
5344
  required: false,
5345
- description: ""
5345
+ description: "CC recipients"
5346
5346
  },
5347
5347
  {
5348
5348
  name: "bcc",
@@ -5351,7 +5351,7 @@ var operations = [
5351
5351
  source: "body",
5352
5352
  type: "array",
5353
5353
  required: false,
5354
- description: ""
5354
+ description: "BCC recipients"
5355
5355
  },
5356
5356
  {
5357
5357
  name: "labelIds",
@@ -5360,7 +5360,7 @@ var operations = [
5360
5360
  source: "body",
5361
5361
  type: "array",
5362
5362
  required: false,
5363
- description: ""
5363
+ description: 'Array of label/tag IDs to attach (comma-separated, e.g. "id1,id2")'
5364
5364
  },
5365
5365
  {
5366
5366
  name: "attachmentIds",
@@ -5369,7 +5369,7 @@ var operations = [
5369
5369
  source: "body",
5370
5370
  type: "array",
5371
5371
  required: false,
5372
- description: ""
5372
+ description: 'Attachment IDs from the upload endpoint (comma-separated, e.g. "id1,id2")'
5373
5373
  },
5374
5374
  {
5375
5375
  name: "sharing",
@@ -5378,7 +5378,7 @@ var operations = [
5378
5378
  source: "body",
5379
5379
  type: "object",
5380
5380
  required: false,
5381
- description: ""
5381
+ description: "Sharing options — control visibility to customer portal and field app"
5382
5382
  },
5383
5383
  {
5384
5384
  name: "raw-body",
@@ -5407,7 +5407,7 @@ var operations = [
5407
5407
  source: "path",
5408
5408
  type: "string",
5409
5409
  required: true,
5410
- description: ""
5410
+ description: "Stage ID or stage number"
5411
5411
  },
5412
5412
  {
5413
5413
  name: "jobId",
@@ -5425,7 +5425,7 @@ var operations = [
5425
5425
  source: "body",
5426
5426
  type: "string",
5427
5427
  required: false,
5428
- description: ""
5428
+ description: "Template ID to pre-populate fields from a template"
5429
5429
  },
5430
5430
  {
5431
5431
  name: "body",
@@ -5434,7 +5434,7 @@ var operations = [
5434
5434
  source: "body",
5435
5435
  type: "string",
5436
5436
  required: false,
5437
- description: ""
5437
+ description: "Message body content (HTML supported for email)"
5438
5438
  },
5439
5439
  {
5440
5440
  name: "to",
@@ -5443,7 +5443,7 @@ var operations = [
5443
5443
  source: "body",
5444
5444
  type: "array",
5445
5445
  required: false,
5446
- description: ""
5446
+ description: "Recipients"
5447
5447
  },
5448
5448
  {
5449
5449
  name: "labelIds",
@@ -5452,7 +5452,7 @@ var operations = [
5452
5452
  source: "body",
5453
5453
  type: "array",
5454
5454
  required: false,
5455
- description: ""
5455
+ description: 'Array of label/tag IDs to attach (comma-separated, e.g. "id1,id2")'
5456
5456
  },
5457
5457
  {
5458
5458
  name: "sharing",
@@ -5461,7 +5461,7 @@ var operations = [
5461
5461
  source: "body",
5462
5462
  type: "object",
5463
5463
  required: false,
5464
- description: ""
5464
+ description: "Sharing options — control visibility to customer portal and field app"
5465
5465
  },
5466
5466
  {
5467
5467
  name: "raw-body",
@@ -5490,7 +5490,7 @@ var operations = [
5490
5490
  source: "path",
5491
5491
  type: "string",
5492
5492
  required: true,
5493
- description: ""
5493
+ description: "Stage ID or stage number"
5494
5494
  },
5495
5495
  {
5496
5496
  name: "jobId",
@@ -5545,7 +5545,7 @@ var operations = [
5545
5545
  source: "body",
5546
5546
  type: "string",
5547
5547
  required: false,
5548
- description: "",
5548
+ description: "call date (ISO 8601 datetime)",
5549
5549
  format: "date-time"
5550
5550
  },
5551
5551
  {
@@ -5555,7 +5555,7 @@ var operations = [
5555
5555
  source: "body",
5556
5556
  type: "string",
5557
5557
  required: false,
5558
- description: ""
5558
+ description: "Message body content (HTML supported for email)"
5559
5559
  },
5560
5560
  {
5561
5561
  name: "labelIds",
@@ -5564,7 +5564,7 @@ var operations = [
5564
5564
  source: "body",
5565
5565
  type: "array",
5566
5566
  required: false,
5567
- description: ""
5567
+ description: 'Array of label/tag IDs to attach (comma-separated, e.g. "id1,id2")'
5568
5568
  },
5569
5569
  {
5570
5570
  name: "sharing",
@@ -5573,7 +5573,7 @@ var operations = [
5573
5573
  source: "body",
5574
5574
  type: "object",
5575
5575
  required: false,
5576
- description: ""
5576
+ description: "Sharing options — control visibility to customer portal and field app"
5577
5577
  },
5578
5578
  {
5579
5579
  name: "raw-body",
@@ -5602,7 +5602,7 @@ var operations = [
5602
5602
  source: "path",
5603
5603
  type: "string",
5604
5604
  required: true,
5605
- description: ""
5605
+ description: "Stage ID or stage number"
5606
5606
  },
5607
5607
  {
5608
5608
  name: "jobId",
@@ -5620,7 +5620,7 @@ var operations = [
5620
5620
  source: "body",
5621
5621
  type: "string",
5622
5622
  required: true,
5623
- description: ""
5623
+ description: "Message body content (HTML supported for email)"
5624
5624
  },
5625
5625
  {
5626
5626
  name: "integrationType",
@@ -5638,7 +5638,7 @@ var operations = [
5638
5638
  source: "body",
5639
5639
  type: "object",
5640
5640
  required: false,
5641
- description: ""
5641
+ description: "Sharing options — control visibility to customer portal and field app"
5642
5642
  },
5643
5643
  {
5644
5644
  name: "raw-body",
@@ -5667,7 +5667,7 @@ var operations = [
5667
5667
  source: "path",
5668
5668
  type: "string",
5669
5669
  required: true,
5670
- description: ""
5670
+ description: "Job ID or job number (e.g. J12345)"
5671
5671
  }
5672
5672
  ],
5673
5673
  hasRequestBody: false
@@ -5687,7 +5687,7 @@ var operations = [
5687
5687
  source: "path",
5688
5688
  type: "string",
5689
5689
  required: true,
5690
- description: ""
5690
+ description: "Job ID or job number (e.g. J12345)"
5691
5691
  }
5692
5692
  ],
5693
5693
  hasRequestBody: false
@@ -5707,7 +5707,7 @@ var operations = [
5707
5707
  source: "path",
5708
5708
  type: "string",
5709
5709
  required: true,
5710
- description: ""
5710
+ description: "Job ID or job number (e.g. J12345)"
5711
5711
  },
5712
5712
  {
5713
5713
  name: "id",
@@ -5736,7 +5736,7 @@ var operations = [
5736
5736
  source: "path",
5737
5737
  type: "string",
5738
5738
  required: true,
5739
- description: ""
5739
+ description: "Job ID or job number (e.g. J12345)"
5740
5740
  },
5741
5741
  {
5742
5742
  name: "id",
@@ -5765,7 +5765,7 @@ var operations = [
5765
5765
  source: "path",
5766
5766
  type: "string",
5767
5767
  required: true,
5768
- description: ""
5768
+ description: "Stage ID or stage number"
5769
5769
  },
5770
5770
  {
5771
5771
  name: "jobId",
@@ -5794,7 +5794,7 @@ var operations = [
5794
5794
  source: "path",
5795
5795
  type: "string",
5796
5796
  required: true,
5797
- description: ""
5797
+ description: "Stage ID or stage number"
5798
5798
  },
5799
5799
  {
5800
5800
  name: "jobId",
@@ -5823,7 +5823,7 @@ var operations = [
5823
5823
  source: "path",
5824
5824
  type: "string",
5825
5825
  required: true,
5826
- description: ""
5826
+ description: "Stage ID or stage number"
5827
5827
  },
5828
5828
  {
5829
5829
  name: "id",
@@ -5861,7 +5861,7 @@ var operations = [
5861
5861
  source: "path",
5862
5862
  type: "string",
5863
5863
  required: true,
5864
- description: ""
5864
+ description: "Stage ID or stage number"
5865
5865
  },
5866
5866
  {
5867
5867
  name: "id",
@@ -5899,7 +5899,7 @@ var operations = [
5899
5899
  source: "path",
5900
5900
  type: "string",
5901
5901
  required: true,
5902
- description: ""
5902
+ description: "Job ID or job number (e.g. J12345)"
5903
5903
  }
5904
5904
  ],
5905
5905
  hasRequestBody: false
@@ -5919,7 +5919,7 @@ var operations = [
5919
5919
  source: "path",
5920
5920
  type: "string",
5921
5921
  required: true,
5922
- description: ""
5922
+ description: "Job ID or job number (e.g. J12345)"
5923
5923
  },
5924
5924
  {
5925
5925
  name: "name",
@@ -5928,7 +5928,7 @@ var operations = [
5928
5928
  source: "body",
5929
5929
  type: "string",
5930
5930
  required: true,
5931
- description: ""
5931
+ description: "Display name"
5932
5932
  },
5933
5933
  {
5934
5934
  name: "description",
@@ -5937,7 +5937,7 @@ var operations = [
5937
5937
  source: "body",
5938
5938
  type: "string",
5939
5939
  required: false,
5940
- description: ""
5940
+ description: "Detailed description"
5941
5941
  },
5942
5942
  {
5943
5943
  name: "target",
@@ -5956,7 +5956,7 @@ var operations = [
5956
5956
  source: "body",
5957
5957
  type: "string",
5958
5958
  required: false,
5959
- description: ""
5959
+ description: "assignee ID"
5960
5960
  },
5961
5961
  {
5962
5962
  name: "dueDate",
@@ -5965,7 +5965,7 @@ var operations = [
5965
5965
  source: "body",
5966
5966
  type: "string",
5967
5967
  required: false,
5968
- description: "",
5968
+ description: "Due date (ISO 8601 datetime)",
5969
5969
  format: "date-time"
5970
5970
  },
5971
5971
  {
@@ -5975,7 +5975,7 @@ var operations = [
5975
5975
  source: "body",
5976
5976
  type: "array",
5977
5977
  required: false,
5978
- description: ""
5978
+ description: 'Array of tag IDs (comma-separated, e.g. "id1,id2") — use /settings/tags to look up'
5979
5979
  },
5980
5980
  {
5981
5981
  name: "evidenceOptions",
@@ -5993,7 +5993,7 @@ var operations = [
5993
5993
  source: "body",
5994
5994
  type: "object",
5995
5995
  required: false,
5996
- description: ""
5996
+ description: "Sharing options — control visibility to customer portal and field app"
5997
5997
  },
5998
5998
  {
5999
5999
  name: "raw-body",
@@ -6022,7 +6022,7 @@ var operations = [
6022
6022
  source: "path",
6023
6023
  type: "string",
6024
6024
  required: true,
6025
- description: ""
6025
+ description: "Job ID or job number (e.g. J12345)"
6026
6026
  },
6027
6027
  {
6028
6028
  name: "id",
@@ -6051,7 +6051,7 @@ var operations = [
6051
6051
  source: "path",
6052
6052
  type: "string",
6053
6053
  required: true,
6054
- description: ""
6054
+ description: "Job ID or job number (e.g. J12345)"
6055
6055
  },
6056
6056
  {
6057
6057
  name: "id",
@@ -6069,7 +6069,7 @@ var operations = [
6069
6069
  source: "body",
6070
6070
  type: "string",
6071
6071
  required: false,
6072
- description: ""
6072
+ description: "Display name"
6073
6073
  },
6074
6074
  {
6075
6075
  name: "description",
@@ -6078,7 +6078,7 @@ var operations = [
6078
6078
  source: "body",
6079
6079
  type: "string",
6080
6080
  required: false,
6081
- description: ""
6081
+ description: "Detailed description"
6082
6082
  },
6083
6083
  {
6084
6084
  name: "status",
@@ -6087,7 +6087,7 @@ var operations = [
6087
6087
  source: "body",
6088
6088
  type: "string",
6089
6089
  required: false,
6090
- description: "",
6090
+ description: "Status filter",
6091
6091
  enumValues: ["open", "completed"]
6092
6092
  },
6093
6093
  {
@@ -6107,7 +6107,7 @@ var operations = [
6107
6107
  source: "body",
6108
6108
  type: "string",
6109
6109
  required: false,
6110
- description: ""
6110
+ description: "assignee ID"
6111
6111
  },
6112
6112
  {
6113
6113
  name: "dueDate",
@@ -6116,7 +6116,7 @@ var operations = [
6116
6116
  source: "body",
6117
6117
  type: "string",
6118
6118
  required: false,
6119
- description: ""
6119
+ description: "Due date (ISO 8601 datetime)"
6120
6120
  },
6121
6121
  {
6122
6122
  name: "completedOn",
@@ -6134,7 +6134,7 @@ var operations = [
6134
6134
  source: "body",
6135
6135
  type: "string",
6136
6136
  required: false,
6137
- description: ""
6137
+ description: "completed by ID"
6138
6138
  },
6139
6139
  {
6140
6140
  name: "tagIds",
@@ -6143,7 +6143,7 @@ var operations = [
6143
6143
  source: "body",
6144
6144
  type: "array",
6145
6145
  required: false,
6146
- description: ""
6146
+ description: 'Array of tag IDs (comma-separated, e.g. "id1,id2") — use /settings/tags to look up'
6147
6147
  },
6148
6148
  {
6149
6149
  name: "sharing",
@@ -6152,7 +6152,7 @@ var operations = [
6152
6152
  source: "body",
6153
6153
  type: "object",
6154
6154
  required: false,
6155
- description: ""
6155
+ description: "Sharing options — control visibility to customer portal and field app"
6156
6156
  },
6157
6157
  {
6158
6158
  name: "raw-body",
@@ -6181,7 +6181,7 @@ var operations = [
6181
6181
  source: "path",
6182
6182
  type: "string",
6183
6183
  required: true,
6184
- description: ""
6184
+ description: "Job ID or job number (e.g. J12345)"
6185
6185
  },
6186
6186
  {
6187
6187
  name: "id",
@@ -6210,7 +6210,7 @@ var operations = [
6210
6210
  source: "path",
6211
6211
  type: "string",
6212
6212
  required: true,
6213
- description: ""
6213
+ description: "Job ID or job number (e.g. J12345)"
6214
6214
  },
6215
6215
  {
6216
6216
  name: "id",
@@ -6228,7 +6228,7 @@ var operations = [
6228
6228
  source: "body",
6229
6229
  type: "array",
6230
6230
  required: false,
6231
- description: ""
6231
+ description: 'Array of signature attachment IDs (comma-separated in CLI, e.g. "id1,id2")'
6232
6232
  },
6233
6233
  {
6234
6234
  name: "beforePhotoAttachmentIds",
@@ -6237,7 +6237,7 @@ var operations = [
6237
6237
  source: "body",
6238
6238
  type: "array",
6239
6239
  required: false,
6240
- description: ""
6240
+ description: 'Array of before photo attachment IDs (comma-separated in CLI, e.g. "id1,id2")'
6241
6241
  },
6242
6242
  {
6243
6243
  name: "duringPhotoAttachmentIds",
@@ -6246,7 +6246,7 @@ var operations = [
6246
6246
  source: "body",
6247
6247
  type: "array",
6248
6248
  required: false,
6249
- description: ""
6249
+ description: 'Array of during photo attachment IDs (comma-separated in CLI, e.g. "id1,id2")'
6250
6250
  },
6251
6251
  {
6252
6252
  name: "afterPhotoAttachmentIds",
@@ -6255,7 +6255,7 @@ var operations = [
6255
6255
  source: "body",
6256
6256
  type: "array",
6257
6257
  required: false,
6258
- description: ""
6258
+ description: 'Array of after photo attachment IDs (comma-separated in CLI, e.g. "id1,id2")'
6259
6259
  },
6260
6260
  {
6261
6261
  name: "comment",
@@ -6282,7 +6282,7 @@ var operations = [
6282
6282
  source: "body",
6283
6283
  type: "string",
6284
6284
  required: false,
6285
- description: ""
6285
+ description: "form response ID"
6286
6286
  },
6287
6287
  {
6288
6288
  name: "fileAttachmentIds",
@@ -6291,7 +6291,7 @@ var operations = [
6291
6291
  source: "body",
6292
6292
  type: "array",
6293
6293
  required: false,
6294
- description: ""
6294
+ description: 'Array of file attachment IDs (comma-separated in CLI, e.g. "id1,id2")'
6295
6295
  },
6296
6296
  {
6297
6297
  name: "additionalFileAttachmentIds",
@@ -6300,7 +6300,7 @@ var operations = [
6300
6300
  source: "body",
6301
6301
  type: "array",
6302
6302
  required: false,
6303
- description: ""
6303
+ description: 'Array of additional file attachment IDs (comma-separated in CLI, e.g. "id1,id2")'
6304
6304
  },
6305
6305
  {
6306
6306
  name: "complete",
@@ -6338,7 +6338,7 @@ var operations = [
6338
6338
  source: "path",
6339
6339
  type: "string",
6340
6340
  required: true,
6341
- description: ""
6341
+ description: "Stage ID or stage number"
6342
6342
  },
6343
6343
  {
6344
6344
  name: "jobId",
@@ -6347,7 +6347,7 @@ var operations = [
6347
6347
  source: "path",
6348
6348
  type: "string",
6349
6349
  required: true,
6350
- description: ""
6350
+ description: "Job ID or job number (e.g. J12345)"
6351
6351
  }
6352
6352
  ],
6353
6353
  hasRequestBody: false
@@ -6367,7 +6367,7 @@ var operations = [
6367
6367
  source: "path",
6368
6368
  type: "string",
6369
6369
  required: true,
6370
- description: ""
6370
+ description: "Stage ID or stage number"
6371
6371
  },
6372
6372
  {
6373
6373
  name: "jobId",
@@ -6376,7 +6376,7 @@ var operations = [
6376
6376
  source: "path",
6377
6377
  type: "string",
6378
6378
  required: true,
6379
- description: ""
6379
+ description: "Job ID or job number (e.g. J12345)"
6380
6380
  },
6381
6381
  {
6382
6382
  name: "name",
@@ -6385,7 +6385,7 @@ var operations = [
6385
6385
  source: "body",
6386
6386
  type: "string",
6387
6387
  required: true,
6388
- description: ""
6388
+ description: "Display name"
6389
6389
  },
6390
6390
  {
6391
6391
  name: "description",
@@ -6394,7 +6394,7 @@ var operations = [
6394
6394
  source: "body",
6395
6395
  type: "string",
6396
6396
  required: false,
6397
- description: ""
6397
+ description: "Detailed description"
6398
6398
  },
6399
6399
  {
6400
6400
  name: "target",
@@ -6413,7 +6413,7 @@ var operations = [
6413
6413
  source: "body",
6414
6414
  type: "string",
6415
6415
  required: false,
6416
- description: ""
6416
+ description: "assignee ID"
6417
6417
  },
6418
6418
  {
6419
6419
  name: "dueDate",
@@ -6422,7 +6422,7 @@ var operations = [
6422
6422
  source: "body",
6423
6423
  type: "string",
6424
6424
  required: false,
6425
- description: "",
6425
+ description: "Due date (ISO 8601 datetime)",
6426
6426
  format: "date-time"
6427
6427
  },
6428
6428
  {
@@ -6432,7 +6432,7 @@ var operations = [
6432
6432
  source: "body",
6433
6433
  type: "array",
6434
6434
  required: false,
6435
- description: ""
6435
+ description: 'Array of tag IDs (comma-separated, e.g. "id1,id2") — use /settings/tags to look up'
6436
6436
  },
6437
6437
  {
6438
6438
  name: "evidenceOptions",
@@ -6450,7 +6450,7 @@ var operations = [
6450
6450
  source: "body",
6451
6451
  type: "object",
6452
6452
  required: false,
6453
- description: ""
6453
+ description: "Sharing options — control visibility to customer portal and field app"
6454
6454
  },
6455
6455
  {
6456
6456
  name: "raw-body",
@@ -6479,7 +6479,7 @@ var operations = [
6479
6479
  source: "path",
6480
6480
  type: "string",
6481
6481
  required: true,
6482
- description: ""
6482
+ description: "Stage ID or stage number"
6483
6483
  },
6484
6484
  {
6485
6485
  name: "id",
@@ -6517,7 +6517,7 @@ var operations = [
6517
6517
  source: "path",
6518
6518
  type: "string",
6519
6519
  required: true,
6520
- description: ""
6520
+ description: "Stage ID or stage number"
6521
6521
  },
6522
6522
  {
6523
6523
  name: "id",
@@ -6544,7 +6544,7 @@ var operations = [
6544
6544
  source: "body",
6545
6545
  type: "string",
6546
6546
  required: false,
6547
- description: ""
6547
+ description: "Display name"
6548
6548
  },
6549
6549
  {
6550
6550
  name: "description",
@@ -6553,7 +6553,7 @@ var operations = [
6553
6553
  source: "body",
6554
6554
  type: "string",
6555
6555
  required: false,
6556
- description: ""
6556
+ description: "Detailed description"
6557
6557
  },
6558
6558
  {
6559
6559
  name: "status",
@@ -6562,7 +6562,7 @@ var operations = [
6562
6562
  source: "body",
6563
6563
  type: "string",
6564
6564
  required: false,
6565
- description: "",
6565
+ description: "Status filter",
6566
6566
  enumValues: ["open", "completed"]
6567
6567
  },
6568
6568
  {
@@ -6582,7 +6582,7 @@ var operations = [
6582
6582
  source: "body",
6583
6583
  type: "string",
6584
6584
  required: false,
6585
- description: ""
6585
+ description: "assignee ID"
6586
6586
  },
6587
6587
  {
6588
6588
  name: "dueDate",
@@ -6591,7 +6591,7 @@ var operations = [
6591
6591
  source: "body",
6592
6592
  type: "string",
6593
6593
  required: false,
6594
- description: ""
6594
+ description: "Due date (ISO 8601 datetime)"
6595
6595
  },
6596
6596
  {
6597
6597
  name: "completedOn",
@@ -6609,7 +6609,7 @@ var operations = [
6609
6609
  source: "body",
6610
6610
  type: "string",
6611
6611
  required: false,
6612
- description: ""
6612
+ description: "completed by ID"
6613
6613
  },
6614
6614
  {
6615
6615
  name: "tagIds",
@@ -6618,7 +6618,7 @@ var operations = [
6618
6618
  source: "body",
6619
6619
  type: "array",
6620
6620
  required: false,
6621
- description: ""
6621
+ description: 'Array of tag IDs (comma-separated, e.g. "id1,id2") — use /settings/tags to look up'
6622
6622
  },
6623
6623
  {
6624
6624
  name: "sharing",
@@ -6627,7 +6627,7 @@ var operations = [
6627
6627
  source: "body",
6628
6628
  type: "object",
6629
6629
  required: false,
6630
- description: ""
6630
+ description: "Sharing options — control visibility to customer portal and field app"
6631
6631
  },
6632
6632
  {
6633
6633
  name: "raw-body",
@@ -6656,7 +6656,7 @@ var operations = [
6656
6656
  source: "path",
6657
6657
  type: "string",
6658
6658
  required: true,
6659
- description: ""
6659
+ description: "Stage ID or stage number"
6660
6660
  },
6661
6661
  {
6662
6662
  name: "id",
@@ -6694,7 +6694,7 @@ var operations = [
6694
6694
  source: "path",
6695
6695
  type: "string",
6696
6696
  required: true,
6697
- description: ""
6697
+ description: "Stage ID or stage number"
6698
6698
  },
6699
6699
  {
6700
6700
  name: "id",
@@ -6721,7 +6721,7 @@ var operations = [
6721
6721
  source: "body",
6722
6722
  type: "array",
6723
6723
  required: false,
6724
- description: ""
6724
+ description: 'Array of signature attachment IDs (comma-separated in CLI, e.g. "id1,id2")'
6725
6725
  },
6726
6726
  {
6727
6727
  name: "beforePhotoAttachmentIds",
@@ -6730,7 +6730,7 @@ var operations = [
6730
6730
  source: "body",
6731
6731
  type: "array",
6732
6732
  required: false,
6733
- description: ""
6733
+ description: 'Array of before photo attachment IDs (comma-separated in CLI, e.g. "id1,id2")'
6734
6734
  },
6735
6735
  {
6736
6736
  name: "duringPhotoAttachmentIds",
@@ -6739,7 +6739,7 @@ var operations = [
6739
6739
  source: "body",
6740
6740
  type: "array",
6741
6741
  required: false,
6742
- description: ""
6742
+ description: 'Array of during photo attachment IDs (comma-separated in CLI, e.g. "id1,id2")'
6743
6743
  },
6744
6744
  {
6745
6745
  name: "afterPhotoAttachmentIds",
@@ -6748,7 +6748,7 @@ var operations = [
6748
6748
  source: "body",
6749
6749
  type: "array",
6750
6750
  required: false,
6751
- description: ""
6751
+ description: 'Array of after photo attachment IDs (comma-separated in CLI, e.g. "id1,id2")'
6752
6752
  },
6753
6753
  {
6754
6754
  name: "comment",
@@ -6775,7 +6775,7 @@ var operations = [
6775
6775
  source: "body",
6776
6776
  type: "string",
6777
6777
  required: false,
6778
- description: ""
6778
+ description: "form response ID"
6779
6779
  },
6780
6780
  {
6781
6781
  name: "fileAttachmentIds",
@@ -6784,7 +6784,7 @@ var operations = [
6784
6784
  source: "body",
6785
6785
  type: "array",
6786
6786
  required: false,
6787
- description: ""
6787
+ description: 'Array of file attachment IDs (comma-separated in CLI, e.g. "id1,id2")'
6788
6788
  },
6789
6789
  {
6790
6790
  name: "additionalFileAttachmentIds",
@@ -6793,7 +6793,7 @@ var operations = [
6793
6793
  source: "body",
6794
6794
  type: "array",
6795
6795
  required: false,
6796
- description: ""
6796
+ description: 'Array of additional file attachment IDs (comma-separated in CLI, e.g. "id1,id2")'
6797
6797
  },
6798
6798
  {
6799
6799
  name: "complete",
@@ -6831,7 +6831,7 @@ var operations = [
6831
6831
  source: "path",
6832
6832
  type: "string",
6833
6833
  required: true,
6834
- description: ""
6834
+ description: "Job ID or job number (e.g. J12345)"
6835
6835
  }
6836
6836
  ],
6837
6837
  hasRequestBody: false
@@ -6851,7 +6851,7 @@ var operations = [
6851
6851
  source: "path",
6852
6852
  type: "string",
6853
6853
  required: true,
6854
- description: ""
6854
+ description: "Job ID or job number (e.g. J12345)"
6855
6855
  }
6856
6856
  ],
6857
6857
  hasRequestBody: false
@@ -6871,7 +6871,7 @@ var operations = [
6871
6871
  source: "path",
6872
6872
  type: "string",
6873
6873
  required: true,
6874
- description: ""
6874
+ description: "Job ID or job number (e.g. J12345)"
6875
6875
  },
6876
6876
  {
6877
6877
  name: "id",
@@ -6900,7 +6900,7 @@ var operations = [
6900
6900
  source: "path",
6901
6901
  type: "string",
6902
6902
  required: true,
6903
- description: ""
6903
+ description: "Job ID or job number (e.g. J12345)"
6904
6904
  },
6905
6905
  {
6906
6906
  name: "id",
@@ -7534,7 +7534,7 @@ var operations = [
7534
7534
  source: "path",
7535
7535
  type: "string",
7536
7536
  required: true,
7537
- description: ""
7537
+ description: "Entity ID"
7538
7538
  }
7539
7539
  ],
7540
7540
  hasRequestBody: false
@@ -7554,7 +7554,7 @@ var operations = [
7554
7554
  source: "path",
7555
7555
  type: "string",
7556
7556
  required: true,
7557
- description: ""
7557
+ description: "Entity ID"
7558
7558
  }
7559
7559
  ],
7560
7560
  hasRequestBody: false
@@ -7574,7 +7574,7 @@ var operations = [
7574
7574
  source: "path",
7575
7575
  type: "string",
7576
7576
  required: true,
7577
- description: ""
7577
+ description: "Entity ID"
7578
7578
  }
7579
7579
  ],
7580
7580
  hasRequestBody: false
@@ -7594,7 +7594,7 @@ var operations = [
7594
7594
  source: "path",
7595
7595
  type: "string",
7596
7596
  required: true,
7597
- description: ""
7597
+ description: "Entity ID"
7598
7598
  }
7599
7599
  ],
7600
7600
  hasRequestBody: false
@@ -7614,7 +7614,7 @@ var operations = [
7614
7614
  source: "path",
7615
7615
  type: "string",
7616
7616
  required: true,
7617
- description: ""
7617
+ description: "Entity ID"
7618
7618
  }
7619
7619
  ],
7620
7620
  hasRequestBody: false
@@ -7634,7 +7634,7 @@ var operations = [
7634
7634
  source: "path",
7635
7635
  type: "string",
7636
7636
  required: true,
7637
- description: ""
7637
+ description: "Entity ID"
7638
7638
  }
7639
7639
  ],
7640
7640
  hasRequestBody: false
@@ -7716,7 +7716,7 @@ var operations = [
7716
7716
  source: "path",
7717
7717
  type: "string",
7718
7718
  required: true,
7719
- description: ""
7719
+ description: "run ID"
7720
7720
  },
7721
7721
  {
7722
7722
  name: "eventId",
@@ -7782,7 +7782,7 @@ var operations = [
7782
7782
  source: "path",
7783
7783
  type: "string",
7784
7784
  required: true,
7785
- description: ""
7785
+ description: "run ID"
7786
7786
  },
7787
7787
  {
7788
7788
  name: "eventId",
@@ -7849,7 +7849,7 @@ var operations = [
7849
7849
  source: "body",
7850
7850
  type: "string",
7851
7851
  required: false,
7852
- description: ""
7852
+ description: "Entity ID"
7853
7853
  },
7854
7854
  {
7855
7855
  name: "method",
@@ -8090,6 +8090,34 @@ function registerAuthCommands(program2) {
8090
8090
  console.log("Active profile set to " + options.profile);
8091
8091
  });
8092
8092
  }
8093
+ var GROUP_DESCRIPTIONS = {
8094
+ jobs: "Manage jobs — create, update, search, and track work",
8095
+ stages: "Manage stages (work orders) within jobs",
8096
+ settings: "Read tenant configuration — job types, priorities, zones, tags, statuses",
8097
+ attachments: "Upload and manage file attachments",
8098
+ crm: "CRM — customers, employees, contractors, suppliers, contacts, sites",
8099
+ webhooks: "Register and manage webhook subscriptions",
8100
+ exports: "Bulk export entity data",
8101
+ agents: "AI agent bridge — progress, actions, lifecycle callbacks",
8102
+ mcp: "Model Context Protocol tools for AI agents",
8103
+ activities: "Activity log — notes, emails, SMS, phone calls, integrations",
8104
+ files: "Files attached to jobs or stages",
8105
+ tasks: "Tasks and to-dos linked to jobs or stages",
8106
+ contacts: "Contacts linked to jobs",
8107
+ customers: "Customer records",
8108
+ employees: "Employee records",
8109
+ contractors: "Contractor records",
8110
+ suppliers: "Supplier records",
8111
+ companies: "Company records",
8112
+ sites: "Site/location records",
8113
+ invites: "User invitations",
8114
+ email: "Email activities",
8115
+ sms: "SMS activities",
8116
+ note: "Note activities",
8117
+ phone: "Phone call activities",
8118
+ integration: "Integration activities",
8119
+ resources: "Technicians and contractors assigned to stages"
8120
+ };
8093
8121
  function registerGeneratedCommands(program2) {
8094
8122
  const commandCache = new Map;
8095
8123
  commandCache.set("", program2);
@@ -8102,6 +8130,9 @@ function registerGeneratedCommands(program2) {
8102
8130
  let command = commandCache.get(key);
8103
8131
  if (!command) {
8104
8132
  command = parent.command(segment);
8133
+ if (GROUP_DESCRIPTIONS[segment]) {
8134
+ command.description(GROUP_DESCRIPTIONS[segment]);
8135
+ }
8105
8136
  commandCache.set(key, command);
8106
8137
  }
8107
8138
  parent = command;
@@ -8110,7 +8141,19 @@ function registerGeneratedCommands(program2) {
8110
8141
  applyCommonOptions(parent);
8111
8142
  applyOperationOptions(parent, operation.options);
8112
8143
  parent.action(async (options) => {
8113
- const outputFormat = getOutputFormat(options.output);
8144
+ if (options.describe) {
8145
+ console.log(JSON.stringify(describeOperation(operation), null, 2));
8146
+ return;
8147
+ }
8148
+ if (options.example) {
8149
+ const example = generateExample(operation);
8150
+ if (!example) {
8151
+ console.log("This command has no request body.");
8152
+ } else {
8153
+ console.log(JSON.stringify(example, null, 2));
8154
+ }
8155
+ return;
8156
+ }
8114
8157
  const config = resolveConfig({
8115
8158
  profile: options.profile,
8116
8159
  baseUrl: options.baseUrl,
@@ -8119,6 +8162,12 @@ function registerGeneratedCommands(program2) {
8119
8162
  accessToken: options.accessToken,
8120
8163
  apiVersion: options.apiVersion
8121
8164
  });
8165
+ if (options.dryRun) {
8166
+ const dryRun = buildDryRun(operation, options, config);
8167
+ console.log(JSON.stringify(dryRun, null, 2));
8168
+ return;
8169
+ }
8170
+ const outputFormat = getOutputFormat(options.output);
8122
8171
  validateRequiredOptions(operation, options);
8123
8172
  const response = await executeOperation(operation, options, config);
8124
8173
  printResponse(response, outputFormat, options.save);
@@ -8134,6 +8183,9 @@ function applyCommonOptions(command) {
8134
8183
  command.option("--api-version <version>", "WorkBuddy API version header override");
8135
8184
  command.option("--output <format>", "Output format: json, table, raw", "json");
8136
8185
  command.option("--save <file>", "Save the response body to a file");
8186
+ command.option("--describe", "Print machine-readable JSON description of this command");
8187
+ command.option("--example", "Print an example request body for this command");
8188
+ command.option("--dry-run", "Print the request that would be sent without executing it");
8137
8189
  }
8138
8190
  function applyOperationOptions(command, options) {
8139
8191
  for (const option of options) {
@@ -8150,6 +8202,97 @@ function buildOptionDescription(option) {
8150
8202
  }
8151
8203
  return parts.join(" ");
8152
8204
  }
8205
+ function describeOperation(operation) {
8206
+ return {
8207
+ operationId: operation.operationId,
8208
+ command: operation.commandPath.join(" "),
8209
+ method: operation.method,
8210
+ path: operation.path,
8211
+ description: operation.description,
8212
+ hasRequestBody: operation.hasRequestBody,
8213
+ options: operation.options.filter((o) => o.name !== "raw-body").map((option) => ({
8214
+ name: option.name,
8215
+ flag: "--" + option.cliName,
8216
+ source: option.source,
8217
+ type: option.type,
8218
+ required: option.required,
8219
+ description: option.description,
8220
+ ...option.enumValues?.length ? { enum: option.enumValues } : {},
8221
+ ...option.format ? { format: option.format } : {}
8222
+ }))
8223
+ };
8224
+ }
8225
+ function generateExample(operation) {
8226
+ const bodyOptions = operation.options.filter((o) => o.source === "body" && o.name !== "raw-body");
8227
+ if (bodyOptions.length === 0) {
8228
+ return null;
8229
+ }
8230
+ const example = {};
8231
+ for (const option of bodyOptions) {
8232
+ const key = option.bodyPath ?? option.name;
8233
+ let value;
8234
+ if (option.enumValues?.length) {
8235
+ value = option.enumValues[0];
8236
+ } else {
8237
+ switch (option.type) {
8238
+ case "integer":
8239
+ value = 1;
8240
+ break;
8241
+ case "number":
8242
+ value = 0;
8243
+ break;
8244
+ case "boolean":
8245
+ value = false;
8246
+ break;
8247
+ case "array":
8248
+ value = [];
8249
+ break;
8250
+ case "object":
8251
+ value = {};
8252
+ break;
8253
+ default:
8254
+ if (option.format === "date-time") {
8255
+ value = "2026-01-01T00:00:00Z";
8256
+ } else if (option.name.endsWith("Id") || option.name === "id") {
8257
+ value = "<" + option.name + ">";
8258
+ } else {
8259
+ value = option.description || option.name;
8260
+ }
8261
+ }
8262
+ }
8263
+ setNestedValue(example, key, value);
8264
+ }
8265
+ return example;
8266
+ }
8267
+ function buildDryRun(operation, values, config) {
8268
+ let requestPath = "/api/v2/public" + operation.path;
8269
+ for (const option of operation.options.filter((o) => o.source === "path")) {
8270
+ const rawValue = values[option.optionKey];
8271
+ if (rawValue !== undefined && rawValue !== null && rawValue !== "") {
8272
+ requestPath = requestPath.replace("{" + option.name + "}", encodeURIComponent(String(rawValue)));
8273
+ }
8274
+ }
8275
+ const queryParams = {};
8276
+ for (const option of operation.options.filter((o) => o.source === "query")) {
8277
+ const rawValue = values[option.optionKey];
8278
+ if (rawValue !== undefined && rawValue !== null && rawValue !== "") {
8279
+ queryParams[option.name] = String(rawValue);
8280
+ }
8281
+ }
8282
+ const body = buildRequestBody(operation, values);
8283
+ const url = config.baseUrl ? config.baseUrl + requestPath : requestPath;
8284
+ const queryString = Object.entries(queryParams).map(([k, v]) => k + "=" + encodeURIComponent(v)).join("&");
8285
+ return {
8286
+ method: operation.method,
8287
+ url: queryString ? url + "?" + queryString : url,
8288
+ headers: {
8289
+ "Content-Type": "application/json",
8290
+ "X-WorkBuddy-Version": config.apiVersion ?? "2026-01",
8291
+ Authorization: "Bearer <token>"
8292
+ },
8293
+ ...body !== undefined ? { body } : {}
8294
+ };
8295
+ }
8153
8296
  function validateRequiredOptions(operation, values) {
8154
8297
  const hasBody = typeof values.rawBody === "string" && values.rawBody.length > 0;
8155
8298
  const missing = operation.options.filter((option) => {