@workbuddy/sdk-js-vnext 1.0.146 → 1.0.148

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/index.d.ts +2697 -221
  2. package/index.js +429 -87
  3. package/package.json +1 -1
package/index.js CHANGED
@@ -34,18 +34,6 @@ export class WorkBuddyClient {
34
34
  }
35
35
 
36
36
  this.jobs = {
37
- actions: {
38
- /**
39
- * 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.
40
- * Operation: PublicApiJobActionController_list
41
- */
42
- list: (params = {}, options = {}) => this.request('PublicApiJobActionController_list', params, options),
43
- /**
44
- * 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.
45
- * Operation: PublicApiJobActionController_run
46
- */
47
- run: (params = {}, options = {}) => this.request('PublicApiJobActionController_run', params, options),
48
- },
49
37
  template: {
50
38
  /**
51
39
  * Create a job using a job template. Template-owned fields win over request values before final job validation.
@@ -622,6 +610,11 @@ export class WorkBuddyClient {
622
610
  };
623
611
 
624
612
  this.items = {
613
+ /**
614
+ * Read a line item and its owning Job and Stage IDs.
615
+ * Operation: PublicApiJobLineItemController_get
616
+ */
617
+ get: (params = {}, options = {}) => this.request('PublicApiJobLineItemController_get', params, options),
625
618
  /**
626
619
  * Find a job line item by external integration ID.
627
620
  * Operation: PublicApiJobLineItemController_list
@@ -696,10 +689,10 @@ export class WorkBuddyClient {
696
689
  reissue: (params = {}, options = {}) => this.request('PublicJobStageController_reissue', params, options),
697
690
  },
698
691
  /**
699
- * Create a new stage (work order) within a job. Stages represent discrete phases of work.
700
- * Operation: PublicJobStageController_create
692
+ * Read a stage, its owning Job ID and its current concurrency token.
693
+ * Operation: PublicJobStageController_get
701
694
  */
702
- create: (params = {}, options = {}) => this.request('PublicJobStageController_create', params, options),
695
+ get: (params = {}, options = {}) => this.request('PublicJobStageController_get', params, options),
703
696
  /**
704
697
  * Partially update a stage. Only provided fields will be modified.
705
698
  * Operation: PublicJobStageController_update
@@ -710,6 +703,11 @@ export class WorkBuddyClient {
710
703
  * Operation: PublicJobStageController_delete
711
704
  */
712
705
  delete: (params = {}, options = {}) => this.request('PublicJobStageController_delete', params, options),
706
+ /**
707
+ * Create a new stage (work order) within a job. Stages represent discrete phases of work.
708
+ * Operation: PublicJobStageController_create
709
+ */
710
+ create: (params = {}, options = {}) => this.request('PublicJobStageController_create', params, options),
713
711
  /**
714
712
  * Change stage status to dispatched, making it ready for field work.
715
713
  * Operation: PublicJobStageController_dispatch
@@ -1382,24 +1380,22 @@ Requires scope: settings:read
1382
1380
  export: (params = {}, options = {}) => this.request('PublicExportController_export', params, options),
1383
1381
  };
1384
1382
 
1385
- this.agentHarness = {
1386
- runs: {
1387
- events: {
1388
- /**
1389
- * Used by an external agent to report progress, action-required, completed, failed, heartbeat, or message events for an existing run.
1390
- * Operation: PublicApiAgentHarnessController_ingestEvent
1391
- */
1392
- ingestEvent: (params = {}, options = {}) =>
1393
- this.request('PublicApiAgentHarnessController_ingestEvent', params, options),
1394
- },
1395
- actionResolved: {
1396
- /**
1397
- * Used by an external agent to post the resolution payload for a run that previously entered action-required state.
1398
- * Operation: PublicApiAgentHarnessController_resolveAction
1399
- */
1400
- resolveAction: (params = {}, options = {}) =>
1401
- this.request('PublicApiAgentHarnessController_resolveAction', params, options),
1402
- },
1383
+ this.extensionRuns = {
1384
+ events: {
1385
+ /**
1386
+ * Used by an external agent to report progress, action-required, completed, failed, heartbeat, or message events for an existing run.
1387
+ * Operation: PublicApiExtensionRunsController_ingestEvent
1388
+ */
1389
+ ingestEvent: (params = {}, options = {}) =>
1390
+ this.request('PublicApiExtensionRunsController_ingestEvent', params, options),
1391
+ },
1392
+ actionResolved: {
1393
+ /**
1394
+ * Used by an external agent to post the resolution payload for a run that previously entered action-required state.
1395
+ * Operation: PublicApiExtensionRunsController_resolveAction
1396
+ */
1397
+ resolveAction: (params = {}, options = {}) =>
1398
+ this.request('PublicApiExtensionRunsController_resolveAction', params, options),
1403
1399
  },
1404
1400
  };
1405
1401
 
@@ -1435,7 +1431,7 @@ Requires scope: settings:read
1435
1431
  },
1436
1432
  suspend: {
1437
1433
  /**
1438
- * Stops future scheduled work while preserving history.
1434
+ * Stops future scheduled work while preserving history. Returns execution impact beside data: existing generated Jobs and booked Visits are not cancelled.
1439
1435
  * Operation: PublicServicePlanController_suspend
1440
1436
  */
1441
1437
  suspend: (params = {}, options = {}) => this.request('PublicServicePlanController_suspend', params, options),
@@ -1447,6 +1443,13 @@ Requires scope: settings:read
1447
1443
  */
1448
1444
  archive: (params = {}, options = {}) => this.request('PublicServicePlanController_archive', params, options),
1449
1445
  },
1446
+ restore: {
1447
+ /**
1448
+ * Restores an archived plan to Paused. Starting it remains a separate activate action.
1449
+ * Operation: PublicServicePlanController_restore
1450
+ */
1451
+ restore: (params = {}, options = {}) => this.request('PublicServicePlanController_restore', params, options),
1452
+ },
1450
1453
  lines: {
1451
1454
  tasks: {
1452
1455
  subtasks: {
@@ -1473,6 +1476,12 @@ Requires scope: settings:read
1473
1476
  */
1474
1477
  patch: (params = {}, options = {}) =>
1475
1478
  this.request('PublicServiceLineSubtaskController_patch', params, options),
1479
+ /**
1480
+ * Deletes this standing Subtask and any descendants through the existing domain cascade. The root Task remains unchanged.
1481
+ * Operation: PublicServiceLineSubtaskController_delete
1482
+ */
1483
+ delete: (params = {}, options = {}) =>
1484
+ this.request('PublicServiceLineSubtaskController_delete', params, options),
1476
1485
  },
1477
1486
  /**
1478
1487
  * List root Service Line Tasks
@@ -1495,6 +1504,12 @@ Requires scope: settings:read
1495
1504
  * Operation: PublicServiceLineTaskController_patch
1496
1505
  */
1497
1506
  patch: (params = {}, options = {}) => this.request('PublicServiceLineTaskController_patch', params, options),
1507
+ /**
1508
+ * 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.
1509
+ * Operation: PublicServiceLineTaskController_delete
1510
+ */
1511
+ delete: (params = {}, options = {}) =>
1512
+ this.request('PublicServiceLineTaskController_delete', params, options),
1498
1513
  },
1499
1514
  /**
1500
1515
  * List Service Lines
@@ -1516,7 +1531,17 @@ Requires scope: settings:read
1516
1531
  * Operation: PublicServiceLineController_patch
1517
1532
  */
1518
1533
  patch: (params = {}, options = {}) => this.request('PublicServiceLineController_patch', params, options),
1534
+ /**
1535
+ * Deletes the line and its Task, Subtask and planned-item definitions using existing domain cascade rules. Started plans remain read-only.
1536
+ * Operation: PublicServiceLineController_delete
1537
+ */
1538
+ delete: (params = {}, options = {}) => this.request('PublicServiceLineController_delete', params, options),
1519
1539
  },
1540
+ /**
1541
+ * Lists plans, including archived plans, with literal name search and zero-based page pagination.
1542
+ * Operation: PublicServicePlanController_list
1543
+ */
1544
+ list: (params = {}, options = {}) => this.request('PublicServicePlanController_list', params, options),
1520
1545
  /**
1521
1546
  * Creates only the Service Plan contract header. Lines and Tasks are added through their nested endpoints.
1522
1547
  * Operation: PublicServicePlanController_create
@@ -1527,6 +1552,92 @@ Requires scope: settings:read
1527
1552
  * Operation: PublicServicePlanController_get
1528
1553
  */
1529
1554
  get: (params = {}, options = {}) => this.request('PublicServicePlanController_get', params, options),
1555
+ /**
1556
+ * 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.
1557
+ * Operation: PublicServicePlanController_patch
1558
+ */
1559
+ patch: (params = {}, options = {}) => this.request('PublicServicePlanController_patch', params, options),
1560
+ /**
1561
+ * Deletes a plan and its definitions only when the existing domain operational-history guard permits it. Archive plans with history instead.
1562
+ * Operation: PublicServicePlanController_delete
1563
+ */
1564
+ delete: (params = {}, options = {}) => this.request('PublicServicePlanController_delete', params, options),
1565
+ };
1566
+
1567
+ this.leads = {
1568
+ convert: {
1569
+ /**
1570
+ * 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.
1571
+ * Operation: PublicLeadController_convert
1572
+ */
1573
+ convert: (params = {}, options = {}) => this.request('PublicLeadController_convert', params, options),
1574
+ },
1575
+ /**
1576
+ * List leads
1577
+ * Operation: PublicLeadController_list
1578
+ */
1579
+ list: (params = {}, options = {}) => this.request('PublicLeadController_list', params, options),
1580
+ /** Iterate all items by following cursor pagination for list(). */
1581
+ all: (params = {}, options = {}) => this.paginate('PublicLeadController_list', params, options),
1582
+ /** Iterate raw pages by following cursor pagination for list(). */
1583
+ pages: (params = {}, options = {}) => this.paginatePages('PublicLeadController_list', params, options),
1584
+ /**
1585
+ * Account name, email, phone and contact first/last names are required, as in the UI. Address is optional until conversion.
1586
+ * Operation: PublicLeadController_create
1587
+ */
1588
+ create: (params = {}, options = {}) => this.request('PublicLeadController_create', params, options),
1589
+ /**
1590
+ * Get lead
1591
+ * Operation: PublicLeadController_get
1592
+ */
1593
+ get: (params = {}, options = {}) => this.request('PublicLeadController_get', params, options),
1594
+ /**
1595
+ * Account/contact members merge into their stored snapshots, as in the legacy pipeline. Qualify a lead with the convert operation rather than writing Qualified.
1596
+ * Operation: PublicLeadController_update
1597
+ */
1598
+ update: (params = {}, options = {}) => this.request('PublicLeadController_update', params, options),
1599
+ };
1600
+
1601
+ this.opportunities = {
1602
+ stages: {
1603
+ /**
1604
+ * Configured Open/Closed stages, including New, Won and Lost. Use these IDs for creation and change-stage.
1605
+ * Operation: PublicOpportunityController_stages
1606
+ */
1607
+ stages: (params = {}, options = {}) => this.request('PublicOpportunityController_stages', params, options),
1608
+ },
1609
+ changeStage: {
1610
+ /**
1611
+ * Supports reopening. Closing requires Mark Opportunities; Lost also requires a Lost Reason. Stage probability and quote-close effects follow the existing pipeline.
1612
+ * Operation: PublicOpportunityController_changeStage
1613
+ */
1614
+ changeStage: (params = {}, options = {}) =>
1615
+ this.request('PublicOpportunityController_changeStage', params, options),
1616
+ },
1617
+ /**
1618
+ * List opportunities
1619
+ * Operation: PublicOpportunityController_list
1620
+ */
1621
+ list: (params = {}, options = {}) => this.request('PublicOpportunityController_list', params, options),
1622
+ /** Iterate all items by following cursor pagination for list(). */
1623
+ all: (params = {}, options = {}) => this.paginate('PublicOpportunityController_list', params, options),
1624
+ /** Iterate raw pages by following cursor pagination for list(). */
1625
+ pages: (params = {}, options = {}) => this.paginatePages('PublicOpportunityController_list', params, options),
1626
+ /**
1627
+ * Requires name, customerId, billingCompanyId and ownerId. Site/contact are optional. Omitted stage uses the pipeline New-stage default.
1628
+ * Operation: PublicOpportunityController_create
1629
+ */
1630
+ create: (params = {}, options = {}) => this.request('PublicOpportunityController_create', params, options),
1631
+ /**
1632
+ * Get opportunity
1633
+ * Operation: PublicOpportunityController_get
1634
+ */
1635
+ get: (params = {}, options = {}) => this.request('PublicOpportunityController_get', params, options),
1636
+ /**
1637
+ * Updates ordinary fields, including on closed Opportunities. Use change-stage for stage transitions. Sites merge using the existing pipeline behaviour.
1638
+ * Operation: PublicOpportunityController_update
1639
+ */
1640
+ update: (params = {}, options = {}) => this.request('PublicOpportunityController_update', params, options),
1530
1641
  };
1531
1642
 
1532
1643
  this.mcp = {
@@ -1749,32 +1860,6 @@ function buildErrorMessage(response, data) {
1749
1860
  }
1750
1861
 
1751
1862
  export const operations = [
1752
- {
1753
- operationId: 'PublicApiJobActionController_list',
1754
- resourcePath: ['jobs', 'actions'],
1755
- actionName: 'list',
1756
- displayName: 'List Job actions',
1757
- description:
1758
- '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.',
1759
- method: 'GET',
1760
- path: '/jobs/actions',
1761
- pathParams: [],
1762
- queryParams: [],
1763
- hasRequestBody: false,
1764
- },
1765
- {
1766
- operationId: 'PublicApiJobActionController_run',
1767
- resourcePath: ['jobs', 'actions'],
1768
- actionName: 'run',
1769
- displayName: 'Run a Job action',
1770
- description:
1771
- '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.',
1772
- method: 'POST',
1773
- path: '/jobs/{id}/actions/{actionId}',
1774
- pathParams: ['id', 'actionId'],
1775
- queryParams: [],
1776
- hasRequestBody: true,
1777
- },
1778
1863
  {
1779
1864
  operationId: 'PublicApiJobController_search',
1780
1865
  resourcePath: ['jobs'],
@@ -1978,6 +2063,18 @@ export const operations = [
1978
2063
  queryParams: [],
1979
2064
  hasRequestBody: false,
1980
2065
  },
2066
+ {
2067
+ operationId: 'PublicApiJobLineItemController_get',
2068
+ resourcePath: ['items'],
2069
+ actionName: 'get',
2070
+ displayName: 'Get job line item by ID',
2071
+ description: 'Read a line item and its owning Job and Stage IDs.',
2072
+ method: 'GET',
2073
+ path: '/items/{id}',
2074
+ pathParams: ['id'],
2075
+ queryParams: [],
2076
+ hasRequestBody: false,
2077
+ },
1981
2078
  {
1982
2079
  operationId: 'PublicApiJobLineItemController_list',
1983
2080
  resourcePath: ['items'],
@@ -2089,29 +2186,16 @@ export const operations = [
2089
2186
  hasRequestBody: false,
2090
2187
  },
2091
2188
  {
2092
- operationId: 'PublicJobStageController_create',
2189
+ operationId: 'PublicJobStageController_get',
2093
2190
  resourcePath: ['stages'],
2094
- actionName: 'create',
2095
- displayName: 'Create a new stage',
2096
- description: 'Create a new stage (work order) within a job. Stages represent discrete phases of work.',
2097
- method: 'POST',
2098
- path: '/stages',
2099
- pathParams: [],
2100
- queryParams: [],
2101
- hasRequestBody: true,
2102
- },
2103
- {
2104
- operationId: 'PublicJobStageController_updateFinance',
2105
- resourcePath: ['stages', 'finance'],
2106
- actionName: 'updateFinance',
2107
- displayName: 'Set stage finance marks',
2108
- description:
2109
- '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.',
2110
- method: 'PATCH',
2111
- path: '/stages/{id}/finance',
2191
+ actionName: 'get',
2192
+ displayName: 'Get stage by ID',
2193
+ description: 'Read a stage, its owning Job ID and its current concurrency token.',
2194
+ method: 'GET',
2195
+ path: '/stages/{id}',
2112
2196
  pathParams: ['id'],
2113
2197
  queryParams: [],
2114
- hasRequestBody: true,
2198
+ hasRequestBody: false,
2115
2199
  },
2116
2200
  {
2117
2201
  operationId: 'PublicJobStageController_update',
@@ -2138,6 +2222,31 @@ export const operations = [
2138
2222
  queryParams: [],
2139
2223
  hasRequestBody: false,
2140
2224
  },
2225
+ {
2226
+ operationId: 'PublicJobStageController_create',
2227
+ resourcePath: ['stages'],
2228
+ actionName: 'create',
2229
+ displayName: 'Create a new stage',
2230
+ description: 'Create a new stage (work order) within a job. Stages represent discrete phases of work.',
2231
+ method: 'POST',
2232
+ path: '/stages',
2233
+ pathParams: [],
2234
+ queryParams: [],
2235
+ hasRequestBody: true,
2236
+ },
2237
+ {
2238
+ operationId: 'PublicJobStageController_updateFinance',
2239
+ resourcePath: ['stages', 'finance'],
2240
+ actionName: 'updateFinance',
2241
+ displayName: 'Set stage finance marks',
2242
+ description:
2243
+ '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.',
2244
+ method: 'PATCH',
2245
+ path: '/stages/{id}/finance',
2246
+ pathParams: ['id'],
2247
+ queryParams: [],
2248
+ hasRequestBody: true,
2249
+ },
2141
2250
  {
2142
2251
  operationId: 'PublicJobStageController_dispatch',
2143
2252
  resourcePath: ['stages'],
@@ -4052,27 +4161,27 @@ export const operations = [
4052
4161
  hasRequestBody: false,
4053
4162
  },
4054
4163
  {
4055
- operationId: 'PublicApiAgentHarnessController_ingestEvent',
4056
- resourcePath: ['agentHarness', 'runs', 'events'],
4164
+ operationId: 'PublicApiExtensionRunsController_ingestEvent',
4165
+ resourcePath: ['extensionRuns', 'events'],
4057
4166
  actionName: 'ingestEvent',
4058
4167
  displayName: 'Write an agent run event',
4059
4168
  description:
4060
4169
  'Used by an external agent to report progress, action-required, completed, failed, heartbeat, or message events for an existing run.',
4061
4170
  method: 'POST',
4062
- path: '/agent-harness/runs/{runId}/events',
4171
+ path: '/extension-runs/{runId}/events',
4063
4172
  pathParams: ['runId'],
4064
4173
  queryParams: [],
4065
4174
  hasRequestBody: true,
4066
4175
  },
4067
4176
  {
4068
- operationId: 'PublicApiAgentHarnessController_resolveAction',
4069
- resourcePath: ['agentHarness', 'runs', 'actionResolved'],
4177
+ operationId: 'PublicApiExtensionRunsController_resolveAction',
4178
+ resourcePath: ['extensionRuns', 'actionResolved'],
4070
4179
  actionName: 'resolveAction',
4071
4180
  displayName: 'Resolve an action-required run state',
4072
4181
  description:
4073
4182
  'Used by an external agent to post the resolution payload for a run that previously entered action-required state.',
4074
4183
  method: 'POST',
4075
- path: '/agent-harness/runs/{runId}/action-resolved',
4184
+ path: '/extension-runs/{runId}/action-resolved',
4076
4185
  pathParams: ['runId'],
4077
4186
  queryParams: [],
4078
4187
  hasRequestBody: true,
@@ -4113,6 +4222,18 @@ export const operations = [
4113
4222
  queryParams: ['status'],
4114
4223
  hasRequestBody: false,
4115
4224
  },
4225
+ {
4226
+ operationId: 'PublicServicePlanController_list',
4227
+ resourcePath: ['servicePlans'],
4228
+ actionName: 'list',
4229
+ displayName: 'List Service Plans',
4230
+ description: 'Lists plans, including archived plans, with literal name search and zero-based page pagination.',
4231
+ method: 'GET',
4232
+ path: '/service-plans',
4233
+ pathParams: [],
4234
+ queryParams: ['search', 'pageSize', 'page'],
4235
+ hasRequestBody: false,
4236
+ },
4116
4237
  {
4117
4238
  operationId: 'PublicServicePlanController_create',
4118
4239
  resourcePath: ['servicePlans'],
@@ -4138,6 +4259,32 @@ export const operations = [
4138
4259
  queryParams: [],
4139
4260
  hasRequestBody: false,
4140
4261
  },
4262
+ {
4263
+ operationId: 'PublicServicePlanController_patch',
4264
+ resourcePath: ['servicePlans'],
4265
+ actionName: 'patch',
4266
+ displayName: 'Update a Service Plan',
4267
+ description:
4268
+ '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.',
4269
+ method: 'PATCH',
4270
+ path: '/service-plans/{identifier}',
4271
+ pathParams: ['identifier'],
4272
+ queryParams: [],
4273
+ hasRequestBody: true,
4274
+ },
4275
+ {
4276
+ operationId: 'PublicServicePlanController_delete',
4277
+ resourcePath: ['servicePlans'],
4278
+ actionName: 'delete',
4279
+ displayName: 'Delete a Service Plan',
4280
+ description:
4281
+ 'Deletes a plan and its definitions only when the existing domain operational-history guard permits it. Archive plans with history instead.',
4282
+ method: 'DELETE',
4283
+ path: '/service-plans/{identifier}',
4284
+ pathParams: ['identifier'],
4285
+ queryParams: [],
4286
+ hasRequestBody: false,
4287
+ },
4141
4288
  {
4142
4289
  operationId: 'PublicServicePlanController_activate',
4143
4290
  resourcePath: ['servicePlans', 'activate'],
@@ -4155,7 +4302,8 @@ export const operations = [
4155
4302
  resourcePath: ['servicePlans', 'suspend'],
4156
4303
  actionName: 'suspend',
4157
4304
  displayName: 'Pause a Service Plan',
4158
- description: 'Stops future scheduled work while preserving history.',
4305
+ description:
4306
+ 'Stops future scheduled work while preserving history. Returns execution impact beside data: existing generated Jobs and booked Visits are not cancelled.',
4159
4307
  method: 'POST',
4160
4308
  path: '/service-plans/{identifier}/suspend',
4161
4309
  pathParams: ['identifier'],
@@ -4174,6 +4322,18 @@ export const operations = [
4174
4322
  queryParams: [],
4175
4323
  hasRequestBody: true,
4176
4324
  },
4325
+ {
4326
+ operationId: 'PublicServicePlanController_restore',
4327
+ resourcePath: ['servicePlans', 'restore'],
4328
+ actionName: 'restore',
4329
+ displayName: 'Restore a Service Plan',
4330
+ description: 'Restores an archived plan to Paused. Starting it remains a separate activate action.',
4331
+ method: 'POST',
4332
+ path: '/service-plans/{identifier}/restore',
4333
+ pathParams: ['identifier'],
4334
+ queryParams: [],
4335
+ hasRequestBody: true,
4336
+ },
4177
4337
  {
4178
4338
  operationId: 'PublicServiceLineController_list',
4179
4339
  resourcePath: ['servicePlans', 'lines'],
@@ -4222,6 +4382,19 @@ export const operations = [
4222
4382
  queryParams: [],
4223
4383
  hasRequestBody: true,
4224
4384
  },
4385
+ {
4386
+ operationId: 'PublicServiceLineController_delete',
4387
+ resourcePath: ['servicePlans', 'lines'],
4388
+ actionName: 'delete',
4389
+ displayName: 'Delete a Service Line',
4390
+ description:
4391
+ 'Deletes the line and its Task, Subtask and planned-item definitions using existing domain cascade rules. Started plans remain read-only.',
4392
+ method: 'DELETE',
4393
+ path: '/service-plans/{planId}/lines/{identifier}',
4394
+ pathParams: ['planId', 'identifier'],
4395
+ queryParams: [],
4396
+ hasRequestBody: false,
4397
+ },
4225
4398
  {
4226
4399
  operationId: 'PublicServiceLineTaskController_list',
4227
4400
  resourcePath: ['servicePlans', 'lines', 'tasks'],
@@ -4271,6 +4444,19 @@ export const operations = [
4271
4444
  queryParams: [],
4272
4445
  hasRequestBody: true,
4273
4446
  },
4447
+ {
4448
+ operationId: 'PublicServiceLineTaskController_delete',
4449
+ resourcePath: ['servicePlans', 'lines', 'tasks'],
4450
+ actionName: 'delete',
4451
+ displayName: 'Delete a root Service Line Task',
4452
+ description:
4453
+ '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.',
4454
+ method: 'DELETE',
4455
+ path: '/service-plans/{planId}/lines/{lineId}/tasks/{identifier}',
4456
+ pathParams: ['planId', 'lineId', 'identifier'],
4457
+ queryParams: [],
4458
+ hasRequestBody: false,
4459
+ },
4274
4460
  {
4275
4461
  operationId: 'PublicServiceLineSubtaskController_list',
4276
4462
  resourcePath: ['servicePlans', 'lines', 'tasks', 'subtasks'],
@@ -4320,6 +4506,162 @@ export const operations = [
4320
4506
  queryParams: [],
4321
4507
  hasRequestBody: true,
4322
4508
  },
4509
+ {
4510
+ operationId: 'PublicServiceLineSubtaskController_delete',
4511
+ resourcePath: ['servicePlans', 'lines', 'tasks', 'subtasks'],
4512
+ actionName: 'delete',
4513
+ displayName: 'Delete a Subtask',
4514
+ description:
4515
+ 'Deletes this standing Subtask and any descendants through the existing domain cascade. The root Task remains unchanged.',
4516
+ method: 'DELETE',
4517
+ path: '/service-plans/{planId}/lines/{lineId}/tasks/{taskId}/subtasks/{identifier}',
4518
+ pathParams: ['planId', 'lineId', 'taskId', 'identifier'],
4519
+ queryParams: [],
4520
+ hasRequestBody: false,
4521
+ },
4522
+ {
4523
+ operationId: 'PublicLeadController_list',
4524
+ resourcePath: ['leads'],
4525
+ actionName: 'list',
4526
+ paginatedItemsActionName: 'all',
4527
+ paginatedPagesActionName: 'pages',
4528
+ displayName: 'List leads',
4529
+ description: 'List leads',
4530
+ method: 'GET',
4531
+ path: '/leads',
4532
+ pathParams: [],
4533
+ queryParams: ['stage', 'search', 'cursor', 'limit'],
4534
+ hasRequestBody: false,
4535
+ },
4536
+ {
4537
+ operationId: 'PublicLeadController_create',
4538
+ resourcePath: ['leads'],
4539
+ actionName: 'create',
4540
+ displayName: 'Create lead',
4541
+ description:
4542
+ 'Account name, email, phone and contact first/last names are required, as in the UI. Address is optional until conversion.',
4543
+ method: 'POST',
4544
+ path: '/leads',
4545
+ pathParams: [],
4546
+ queryParams: [],
4547
+ hasRequestBody: true,
4548
+ },
4549
+ {
4550
+ operationId: 'PublicLeadController_get',
4551
+ resourcePath: ['leads'],
4552
+ actionName: 'get',
4553
+ displayName: 'Get lead',
4554
+ description: 'Get lead',
4555
+ method: 'GET',
4556
+ path: '/leads/{id}',
4557
+ pathParams: ['id'],
4558
+ queryParams: [],
4559
+ hasRequestBody: false,
4560
+ },
4561
+ {
4562
+ operationId: 'PublicLeadController_update',
4563
+ resourcePath: ['leads'],
4564
+ actionName: 'update',
4565
+ displayName: 'Update lead',
4566
+ description:
4567
+ 'Account/contact members merge into their stored snapshots, as in the legacy pipeline. Qualify a lead with the convert operation rather than writing Qualified.',
4568
+ method: 'PATCH',
4569
+ path: '/leads/{id}',
4570
+ pathParams: ['id'],
4571
+ queryParams: [],
4572
+ hasRequestBody: true,
4573
+ },
4574
+ {
4575
+ operationId: 'PublicLeadController_convert',
4576
+ resourcePath: ['leads', 'convert'],
4577
+ actionName: 'convert',
4578
+ displayName: 'Convert lead',
4579
+ description:
4580
+ '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.',
4581
+ method: 'POST',
4582
+ path: '/leads/{id}/convert',
4583
+ pathParams: ['id'],
4584
+ queryParams: [],
4585
+ hasRequestBody: true,
4586
+ },
4587
+ {
4588
+ operationId: 'PublicOpportunityController_list',
4589
+ resourcePath: ['opportunities'],
4590
+ actionName: 'list',
4591
+ paginatedItemsActionName: 'all',
4592
+ paginatedPagesActionName: 'pages',
4593
+ displayName: 'List opportunities',
4594
+ description: 'List opportunities',
4595
+ method: 'GET',
4596
+ path: '/opportunities',
4597
+ pathParams: [],
4598
+ queryParams: ['stageId', 'search', 'cursor', 'limit'],
4599
+ hasRequestBody: false,
4600
+ },
4601
+ {
4602
+ operationId: 'PublicOpportunityController_create',
4603
+ resourcePath: ['opportunities'],
4604
+ actionName: 'create',
4605
+ displayName: 'Create opportunity',
4606
+ description:
4607
+ 'Requires name, customerId, billingCompanyId and ownerId. Site/contact are optional. Omitted stage uses the pipeline New-stage default.',
4608
+ method: 'POST',
4609
+ path: '/opportunities',
4610
+ pathParams: [],
4611
+ queryParams: [],
4612
+ hasRequestBody: true,
4613
+ },
4614
+ {
4615
+ operationId: 'PublicOpportunityController_stages',
4616
+ resourcePath: ['opportunities', 'stages'],
4617
+ actionName: 'stages',
4618
+ displayName: 'List opportunity stages',
4619
+ description:
4620
+ 'Configured Open/Closed stages, including New, Won and Lost. Use these IDs for creation and change-stage.',
4621
+ method: 'GET',
4622
+ path: '/opportunities/stages',
4623
+ pathParams: [],
4624
+ queryParams: [],
4625
+ hasRequestBody: false,
4626
+ },
4627
+ {
4628
+ operationId: 'PublicOpportunityController_get',
4629
+ resourcePath: ['opportunities'],
4630
+ actionName: 'get',
4631
+ displayName: 'Get opportunity',
4632
+ description: 'Get opportunity',
4633
+ method: 'GET',
4634
+ path: '/opportunities/{id}',
4635
+ pathParams: ['id'],
4636
+ queryParams: [],
4637
+ hasRequestBody: false,
4638
+ },
4639
+ {
4640
+ operationId: 'PublicOpportunityController_update',
4641
+ resourcePath: ['opportunities'],
4642
+ actionName: 'update',
4643
+ displayName: 'Update opportunity',
4644
+ description:
4645
+ 'Updates ordinary fields, including on closed Opportunities. Use change-stage for stage transitions. Sites merge using the existing pipeline behaviour.',
4646
+ method: 'PATCH',
4647
+ path: '/opportunities/{id}',
4648
+ pathParams: ['id'],
4649
+ queryParams: [],
4650
+ hasRequestBody: true,
4651
+ },
4652
+ {
4653
+ operationId: 'PublicOpportunityController_changeStage',
4654
+ resourcePath: ['opportunities', 'changeStage'],
4655
+ actionName: 'changeStage',
4656
+ displayName: 'Change opportunity stage',
4657
+ description:
4658
+ 'Supports reopening. Closing requires Mark Opportunities; Lost also requires a Lost Reason. Stage probability and quote-close effects follow the existing pipeline.',
4659
+ method: 'POST',
4660
+ path: '/opportunities/{id}/change-stage',
4661
+ pathParams: ['id'],
4662
+ queryParams: [],
4663
+ hasRequestBody: true,
4664
+ },
4323
4665
  {
4324
4666
  operationId: 'McpV3StreamableController_handleGet',
4325
4667
  resourcePath: ['mcp'],