@workbuddy/sdk-js-vnext 1.0.0
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.
- package/index.d.ts +6257 -0
- package/index.js +2842 -0
- package/package.json +23 -0
package/index.js
ADDED
|
@@ -0,0 +1,2842 @@
|
|
|
1
|
+
const PUBLIC_API_BASE_PATH = '/api/v2/public';
|
|
2
|
+
const DEFAULT_API_VERSION = '2026-01';
|
|
3
|
+
const DEFAULT_TOKEN_URL = 'https://tarek.workbuddy.dev/api/oauth2/token';
|
|
4
|
+
|
|
5
|
+
export class WorkBuddyApiError extends Error {
|
|
6
|
+
constructor(message, response, data) {
|
|
7
|
+
super(message);
|
|
8
|
+
this.name = 'WorkBuddyApiError';
|
|
9
|
+
this.response = response;
|
|
10
|
+
this.status = response.status;
|
|
11
|
+
this.data = data;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export class WorkBuddyClient {
|
|
16
|
+
constructor(options) {
|
|
17
|
+
if (!options?.baseUrl) {
|
|
18
|
+
throw new Error('WorkBuddyClient requires a baseUrl option.');
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
this.baseUrl = options.baseUrl;
|
|
22
|
+
this.apiVersion = options.apiVersion ?? DEFAULT_API_VERSION;
|
|
23
|
+
this.accessToken = options.accessToken;
|
|
24
|
+
this.accessTokenProvider = options.getAccessToken;
|
|
25
|
+
this.clientId = options.clientId;
|
|
26
|
+
this.clientSecret = options.clientSecret;
|
|
27
|
+
this.tokenUrl = options.tokenUrl ?? DEFAULT_TOKEN_URL;
|
|
28
|
+
this.fetch = options.fetch ?? globalThis.fetch?.bind(globalThis);
|
|
29
|
+
this.defaultHeaders = options.headers ?? {};
|
|
30
|
+
this.token = undefined;
|
|
31
|
+
|
|
32
|
+
if (!this.fetch) {
|
|
33
|
+
throw new Error('No fetch implementation found. Use Node 18+ or pass options.fetch.');
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
this.jobs = {
|
|
37
|
+
stages: {
|
|
38
|
+
items: {
|
|
39
|
+
/**
|
|
40
|
+
* Get all items (line items) for a stage.
|
|
41
|
+
* Operation: PublicApiJobController_getStageItems
|
|
42
|
+
*/
|
|
43
|
+
list: (params = {}, options = {}) => this.request('PublicApiJobController_getStageItems', params, options),
|
|
44
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
45
|
+
all: (params = {}, options = {}) => this.paginate('PublicApiJobController_getStageItems', params, options),
|
|
46
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
47
|
+
pages: (params = {}, options = {}) =>
|
|
48
|
+
this.paginatePages('PublicApiJobController_getStageItems', params, options),
|
|
49
|
+
/**
|
|
50
|
+
* Get a specific item within a stage.
|
|
51
|
+
* Operation: PublicApiJobController_getStageItem
|
|
52
|
+
*/
|
|
53
|
+
getStageItem: (params = {}, options = {}) =>
|
|
54
|
+
this.request('PublicApiJobController_getStageItem', params, options),
|
|
55
|
+
},
|
|
56
|
+
resources: {
|
|
57
|
+
reissue: {
|
|
58
|
+
/**
|
|
59
|
+
* Reissue dispatch notification
|
|
60
|
+
* Operation: PublicJobStageResourceController_reissue
|
|
61
|
+
*/
|
|
62
|
+
reissue: (params = {}, options = {}) =>
|
|
63
|
+
this.request('PublicJobStageResourceController_reissue', params, options),
|
|
64
|
+
},
|
|
65
|
+
status: {
|
|
66
|
+
/**
|
|
67
|
+
* Update status (enroute, onsite, checkedout, completed, onhold).
|
|
68
|
+
* Operation: PublicJobStageResourceController_updateStatus
|
|
69
|
+
*/
|
|
70
|
+
updateStatus: (params = {}, options = {}) =>
|
|
71
|
+
this.request('PublicJobStageResourceController_updateStatus', params, options),
|
|
72
|
+
},
|
|
73
|
+
/**
|
|
74
|
+
* Get all assigned resources for a stage.
|
|
75
|
+
* Operation: PublicJobStageResourceController_list
|
|
76
|
+
*/
|
|
77
|
+
list: (params = {}, options = {}) => this.request('PublicJobStageResourceController_list', params, options),
|
|
78
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
79
|
+
all: (params = {}, options = {}) => this.paginate('PublicJobStageResourceController_list', params, options),
|
|
80
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
81
|
+
pages: (params = {}, options = {}) =>
|
|
82
|
+
this.paginatePages('PublicJobStageResourceController_list', params, options),
|
|
83
|
+
/**
|
|
84
|
+
* Assign a technician or contractor.
|
|
85
|
+
* Operation: PublicJobStageResourceController_assign
|
|
86
|
+
*/
|
|
87
|
+
assign: (params = {}, options = {}) =>
|
|
88
|
+
this.request('PublicJobStageResourceController_assign', params, options),
|
|
89
|
+
/**
|
|
90
|
+
* Get a specific resource assignment.
|
|
91
|
+
* Operation: PublicJobStageResourceController_get
|
|
92
|
+
*/
|
|
93
|
+
get: (params = {}, options = {}) => this.request('PublicJobStageResourceController_get', params, options),
|
|
94
|
+
/**
|
|
95
|
+
* Unassign resource from stage
|
|
96
|
+
* Operation: PublicJobStageResourceController_unassign
|
|
97
|
+
*/
|
|
98
|
+
unassign: (params = {}, options = {}) =>
|
|
99
|
+
this.request('PublicJobStageResourceController_unassign', params, options),
|
|
100
|
+
},
|
|
101
|
+
activities: {
|
|
102
|
+
note: {
|
|
103
|
+
/**
|
|
104
|
+
* Create note activity (Stages)
|
|
105
|
+
* Operation: PublicStageActivitiesController_createNote
|
|
106
|
+
*/
|
|
107
|
+
createNote: (params = {}, options = {}) =>
|
|
108
|
+
this.request('PublicStageActivitiesController_createNote', params, options),
|
|
109
|
+
},
|
|
110
|
+
email: {
|
|
111
|
+
/**
|
|
112
|
+
* Create email activity (Stages)
|
|
113
|
+
* Operation: PublicStageActivitiesController_createEmail
|
|
114
|
+
*/
|
|
115
|
+
createEmail: (params = {}, options = {}) =>
|
|
116
|
+
this.request('PublicStageActivitiesController_createEmail', params, options),
|
|
117
|
+
},
|
|
118
|
+
sms: {
|
|
119
|
+
/**
|
|
120
|
+
* Create SMS activity (Stages)
|
|
121
|
+
* Operation: PublicStageActivitiesController_createSms
|
|
122
|
+
*/
|
|
123
|
+
createSms: (params = {}, options = {}) =>
|
|
124
|
+
this.request('PublicStageActivitiesController_createSms', params, options),
|
|
125
|
+
},
|
|
126
|
+
phone: {
|
|
127
|
+
/**
|
|
128
|
+
* Create phone activity (Stages)
|
|
129
|
+
* Operation: PublicStageActivitiesController_createPhone
|
|
130
|
+
*/
|
|
131
|
+
createPhone: (params = {}, options = {}) =>
|
|
132
|
+
this.request('PublicStageActivitiesController_createPhone', params, options),
|
|
133
|
+
},
|
|
134
|
+
integration: {
|
|
135
|
+
/**
|
|
136
|
+
* Create integration activity (Stages)
|
|
137
|
+
* Operation: PublicStageActivitiesController_createIntegration
|
|
138
|
+
*/
|
|
139
|
+
createIntegration: (params = {}, options = {}) =>
|
|
140
|
+
this.request('PublicStageActivitiesController_createIntegration', params, options),
|
|
141
|
+
},
|
|
142
|
+
thread: {
|
|
143
|
+
/**
|
|
144
|
+
* Create thread activity (Stages)
|
|
145
|
+
* Operation: PublicStageActivitiesController_createThread
|
|
146
|
+
*/
|
|
147
|
+
createThread: (params = {}, options = {}) =>
|
|
148
|
+
this.request('PublicStageActivitiesController_createThread', params, options),
|
|
149
|
+
},
|
|
150
|
+
/**
|
|
151
|
+
* List activities (Stages)
|
|
152
|
+
* Operation: PublicStageActivitiesController_list
|
|
153
|
+
*/
|
|
154
|
+
list: (params = {}, options = {}) => this.request('PublicStageActivitiesController_list', params, options),
|
|
155
|
+
/**
|
|
156
|
+
* Get activity by ID (Stages)
|
|
157
|
+
* Operation: PublicStageActivitiesController_getById
|
|
158
|
+
*/
|
|
159
|
+
get: (params = {}, options = {}) => this.request('PublicStageActivitiesController_getById', params, options),
|
|
160
|
+
/**
|
|
161
|
+
* Delete activity (Stages)
|
|
162
|
+
* Operation: PublicStageActivitiesController_delete
|
|
163
|
+
*/
|
|
164
|
+
delete: (params = {}, options = {}) =>
|
|
165
|
+
this.request('PublicStageActivitiesController_delete', params, options),
|
|
166
|
+
},
|
|
167
|
+
files: {
|
|
168
|
+
/**
|
|
169
|
+
* List files (Stages)
|
|
170
|
+
* Operation: PublicStageFilesController_list
|
|
171
|
+
*/
|
|
172
|
+
list: (params = {}, options = {}) => this.request('PublicStageFilesController_list', params, options),
|
|
173
|
+
/**
|
|
174
|
+
* Create file (Stages)
|
|
175
|
+
* Operation: PublicStageFilesController_create
|
|
176
|
+
*/
|
|
177
|
+
create: (params = {}, options = {}) => this.request('PublicStageFilesController_create', params, options),
|
|
178
|
+
/**
|
|
179
|
+
* Get file by ID (Stages)
|
|
180
|
+
* Operation: PublicStageFilesController_getById
|
|
181
|
+
*/
|
|
182
|
+
get: (params = {}, options = {}) => this.request('PublicStageFilesController_getById', params, options),
|
|
183
|
+
/**
|
|
184
|
+
* Delete file (Stages)
|
|
185
|
+
* Operation: PublicStageFilesController_delete
|
|
186
|
+
*/
|
|
187
|
+
delete: (params = {}, options = {}) => this.request('PublicStageFilesController_delete', params, options),
|
|
188
|
+
},
|
|
189
|
+
tasks: {
|
|
190
|
+
evidence: {
|
|
191
|
+
/**
|
|
192
|
+
* Submit task evidence (Stages)
|
|
193
|
+
* Operation: PublicStageTasksController_submitEvidence
|
|
194
|
+
*/
|
|
195
|
+
submitEvidence: (params = {}, options = {}) =>
|
|
196
|
+
this.request('PublicStageTasksController_submitEvidence', params, options),
|
|
197
|
+
},
|
|
198
|
+
/**
|
|
199
|
+
* List tasks (Stages)
|
|
200
|
+
* Operation: PublicStageTasksController_list
|
|
201
|
+
*/
|
|
202
|
+
list: (params = {}, options = {}) => this.request('PublicStageTasksController_list', params, options),
|
|
203
|
+
/**
|
|
204
|
+
* Create task (Stages)
|
|
205
|
+
* Operation: PublicStageTasksController_create
|
|
206
|
+
*/
|
|
207
|
+
create: (params = {}, options = {}) => this.request('PublicStageTasksController_create', params, options),
|
|
208
|
+
/**
|
|
209
|
+
* Get task by ID (Stages)
|
|
210
|
+
* Operation: PublicStageTasksController_getById
|
|
211
|
+
*/
|
|
212
|
+
get: (params = {}, options = {}) => this.request('PublicStageTasksController_getById', params, options),
|
|
213
|
+
/**
|
|
214
|
+
* Update task (Stages)
|
|
215
|
+
* Operation: PublicStageTasksController_update
|
|
216
|
+
*/
|
|
217
|
+
update: (params = {}, options = {}) => this.request('PublicStageTasksController_update', params, options),
|
|
218
|
+
/**
|
|
219
|
+
* Delete task (Stages)
|
|
220
|
+
* Operation: PublicStageTasksController_delete
|
|
221
|
+
*/
|
|
222
|
+
delete: (params = {}, options = {}) => this.request('PublicStageTasksController_delete', params, options),
|
|
223
|
+
},
|
|
224
|
+
/**
|
|
225
|
+
* Get all stages (work orders) for a job.
|
|
226
|
+
* Operation: PublicApiJobController_getJobStages
|
|
227
|
+
*/
|
|
228
|
+
list: (params = {}, options = {}) => this.request('PublicApiJobController_getJobStages', params, options),
|
|
229
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
230
|
+
all: (params = {}, options = {}) => this.paginate('PublicApiJobController_getJobStages', params, options),
|
|
231
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
232
|
+
pages: (params = {}, options = {}) =>
|
|
233
|
+
this.paginatePages('PublicApiJobController_getJobStages', params, options),
|
|
234
|
+
/**
|
|
235
|
+
* Get a specific stage within a job.
|
|
236
|
+
* Operation: PublicApiJobController_getJobStage
|
|
237
|
+
*/
|
|
238
|
+
getJobStage: (params = {}, options = {}) => this.request('PublicApiJobController_getJobStage', params, options),
|
|
239
|
+
},
|
|
240
|
+
activities: {
|
|
241
|
+
note: {
|
|
242
|
+
/**
|
|
243
|
+
* Create note activity (Jobs)
|
|
244
|
+
* Operation: PublicJobActivitiesController_createNote
|
|
245
|
+
*/
|
|
246
|
+
createNote: (params = {}, options = {}) =>
|
|
247
|
+
this.request('PublicJobActivitiesController_createNote', params, options),
|
|
248
|
+
},
|
|
249
|
+
email: {
|
|
250
|
+
/**
|
|
251
|
+
* Create email activity (Jobs)
|
|
252
|
+
* Operation: PublicJobActivitiesController_createEmail
|
|
253
|
+
*/
|
|
254
|
+
createEmail: (params = {}, options = {}) =>
|
|
255
|
+
this.request('PublicJobActivitiesController_createEmail', params, options),
|
|
256
|
+
},
|
|
257
|
+
sms: {
|
|
258
|
+
/**
|
|
259
|
+
* Create SMS activity (Jobs)
|
|
260
|
+
* Operation: PublicJobActivitiesController_createSms
|
|
261
|
+
*/
|
|
262
|
+
createSms: (params = {}, options = {}) =>
|
|
263
|
+
this.request('PublicJobActivitiesController_createSms', params, options),
|
|
264
|
+
},
|
|
265
|
+
phone: {
|
|
266
|
+
/**
|
|
267
|
+
* Create phone activity (Jobs)
|
|
268
|
+
* Operation: PublicJobActivitiesController_createPhone
|
|
269
|
+
*/
|
|
270
|
+
createPhone: (params = {}, options = {}) =>
|
|
271
|
+
this.request('PublicJobActivitiesController_createPhone', params, options),
|
|
272
|
+
},
|
|
273
|
+
integration: {
|
|
274
|
+
/**
|
|
275
|
+
* Create integration activity (Jobs)
|
|
276
|
+
* Operation: PublicJobActivitiesController_createIntegration
|
|
277
|
+
*/
|
|
278
|
+
createIntegration: (params = {}, options = {}) =>
|
|
279
|
+
this.request('PublicJobActivitiesController_createIntegration', params, options),
|
|
280
|
+
},
|
|
281
|
+
thread: {
|
|
282
|
+
/**
|
|
283
|
+
* Create thread activity (Jobs)
|
|
284
|
+
* Operation: PublicJobActivitiesController_createThread
|
|
285
|
+
*/
|
|
286
|
+
createThread: (params = {}, options = {}) =>
|
|
287
|
+
this.request('PublicJobActivitiesController_createThread', params, options),
|
|
288
|
+
},
|
|
289
|
+
/**
|
|
290
|
+
* List activities (Jobs)
|
|
291
|
+
* Operation: PublicJobActivitiesController_list
|
|
292
|
+
*/
|
|
293
|
+
list: (params = {}, options = {}) => this.request('PublicJobActivitiesController_list', params, options),
|
|
294
|
+
/**
|
|
295
|
+
* Get activity by ID (Jobs)
|
|
296
|
+
* Operation: PublicJobActivitiesController_getById
|
|
297
|
+
*/
|
|
298
|
+
get: (params = {}, options = {}) => this.request('PublicJobActivitiesController_getById', params, options),
|
|
299
|
+
/**
|
|
300
|
+
* Delete activity (Jobs)
|
|
301
|
+
* Operation: PublicJobActivitiesController_delete
|
|
302
|
+
*/
|
|
303
|
+
delete: (params = {}, options = {}) => this.request('PublicJobActivitiesController_delete', params, options),
|
|
304
|
+
},
|
|
305
|
+
files: {
|
|
306
|
+
/**
|
|
307
|
+
* List files (Jobs)
|
|
308
|
+
* Operation: PublicJobFilesController_list
|
|
309
|
+
*/
|
|
310
|
+
list: (params = {}, options = {}) => this.request('PublicJobFilesController_list', params, options),
|
|
311
|
+
/**
|
|
312
|
+
* Create file (Jobs)
|
|
313
|
+
* Operation: PublicJobFilesController_create
|
|
314
|
+
*/
|
|
315
|
+
create: (params = {}, options = {}) => this.request('PublicJobFilesController_create', params, options),
|
|
316
|
+
/**
|
|
317
|
+
* Get file by ID (Jobs)
|
|
318
|
+
* Operation: PublicJobFilesController_getById
|
|
319
|
+
*/
|
|
320
|
+
get: (params = {}, options = {}) => this.request('PublicJobFilesController_getById', params, options),
|
|
321
|
+
/**
|
|
322
|
+
* Delete file (Jobs)
|
|
323
|
+
* Operation: PublicJobFilesController_delete
|
|
324
|
+
*/
|
|
325
|
+
delete: (params = {}, options = {}) => this.request('PublicJobFilesController_delete', params, options),
|
|
326
|
+
},
|
|
327
|
+
tasks: {
|
|
328
|
+
evidence: {
|
|
329
|
+
/**
|
|
330
|
+
* Submit task evidence (Jobs)
|
|
331
|
+
* Operation: PublicJobTasksController_submitEvidence
|
|
332
|
+
*/
|
|
333
|
+
submitEvidence: (params = {}, options = {}) =>
|
|
334
|
+
this.request('PublicJobTasksController_submitEvidence', params, options),
|
|
335
|
+
},
|
|
336
|
+
/**
|
|
337
|
+
* List tasks (Jobs)
|
|
338
|
+
* Operation: PublicJobTasksController_list
|
|
339
|
+
*/
|
|
340
|
+
list: (params = {}, options = {}) => this.request('PublicJobTasksController_list', params, options),
|
|
341
|
+
/**
|
|
342
|
+
* Create task (Jobs)
|
|
343
|
+
* Operation: PublicJobTasksController_create
|
|
344
|
+
*/
|
|
345
|
+
create: (params = {}, options = {}) => this.request('PublicJobTasksController_create', params, options),
|
|
346
|
+
/**
|
|
347
|
+
* Get task by ID (Jobs)
|
|
348
|
+
* Operation: PublicJobTasksController_getById
|
|
349
|
+
*/
|
|
350
|
+
get: (params = {}, options = {}) => this.request('PublicJobTasksController_getById', params, options),
|
|
351
|
+
/**
|
|
352
|
+
* Update task (Jobs)
|
|
353
|
+
* Operation: PublicJobTasksController_update
|
|
354
|
+
*/
|
|
355
|
+
update: (params = {}, options = {}) => this.request('PublicJobTasksController_update', params, options),
|
|
356
|
+
/**
|
|
357
|
+
* Delete task (Jobs)
|
|
358
|
+
* Operation: PublicJobTasksController_delete
|
|
359
|
+
*/
|
|
360
|
+
delete: (params = {}, options = {}) => this.request('PublicJobTasksController_delete', params, options),
|
|
361
|
+
},
|
|
362
|
+
contacts: {
|
|
363
|
+
/**
|
|
364
|
+
* List contact links
|
|
365
|
+
* Operation: PublicJobContactsController_list
|
|
366
|
+
*/
|
|
367
|
+
list: (params = {}, options = {}) => this.request('PublicJobContactsController_list', params, options),
|
|
368
|
+
/**
|
|
369
|
+
* Create contact link
|
|
370
|
+
* Operation: PublicJobContactsController_create
|
|
371
|
+
*/
|
|
372
|
+
create: (params = {}, options = {}) => this.request('PublicJobContactsController_create', params, options),
|
|
373
|
+
/**
|
|
374
|
+
* Get contact link by ID
|
|
375
|
+
* Operation: PublicJobContactsController_getById
|
|
376
|
+
*/
|
|
377
|
+
get: (params = {}, options = {}) => this.request('PublicJobContactsController_getById', params, options),
|
|
378
|
+
/**
|
|
379
|
+
* Delete contact link
|
|
380
|
+
* Operation: PublicJobContactsController_delete
|
|
381
|
+
*/
|
|
382
|
+
delete: (params = {}, options = {}) => this.request('PublicJobContactsController_delete', params, options),
|
|
383
|
+
},
|
|
384
|
+
/**
|
|
385
|
+
* Advanced search endpoint for complex queries. Use mode='jobs' (default) to search jobs, or mode='stages' to search stages with embedded job context. Supports multiple filters, date ranges, and field projection via JSON body.
|
|
386
|
+
* Operation: PublicApiJobController_search
|
|
387
|
+
*/
|
|
388
|
+
search: (params = {}, options = {}) => this.request('PublicApiJobController_search', params, options),
|
|
389
|
+
/** Iterate all items by following cursor pagination for search(). */
|
|
390
|
+
all: (params = {}, options = {}) => this.paginate('PublicApiJobController_search', params, options),
|
|
391
|
+
/** Iterate raw pages by following cursor pagination for search(). */
|
|
392
|
+
pages: (params = {}, options = {}) => this.paginatePages('PublicApiJobController_search', params, options),
|
|
393
|
+
/**
|
|
394
|
+
* Retrieve a single job by its ID, human-readable job number, or external integration ID.
|
|
395
|
+
* Operation: PublicApiJobController_get
|
|
396
|
+
*/
|
|
397
|
+
get: (params = {}, options = {}) => this.request('PublicApiJobController_get', params, options),
|
|
398
|
+
/**
|
|
399
|
+
* Cancel a job by ID or job number. Jobs cannot be permanently deleted, only cancelled. This changes the job status to 'cancelled'. A reason must be provided.
|
|
400
|
+
* Operation: PublicApiJobController_delete
|
|
401
|
+
*/
|
|
402
|
+
delete: (params = {}, options = {}) => this.request('PublicApiJobController_delete', params, options),
|
|
403
|
+
/**
|
|
404
|
+
* Create a new job with the specified details. Requires either customerId or inline customer object.
|
|
405
|
+
* Operation: PublicApiJobController_create
|
|
406
|
+
*/
|
|
407
|
+
create: (params = {}, options = {}) => this.request('PublicApiJobController_create', params, options),
|
|
408
|
+
/**
|
|
409
|
+
* Partially update a job. Only provided fields will be modified.
|
|
410
|
+
* Operation: PublicApiJobController_update
|
|
411
|
+
*/
|
|
412
|
+
update: (params = {}, options = {}) => this.request('PublicApiJobController_update', params, options),
|
|
413
|
+
/**
|
|
414
|
+
* Change job status to dispatched, making it ready for field work.
|
|
415
|
+
* Operation: PublicApiJobController_dispatch
|
|
416
|
+
*/
|
|
417
|
+
dispatch: (params = {}, options = {}) => this.request('PublicApiJobController_dispatch', params, options),
|
|
418
|
+
};
|
|
419
|
+
|
|
420
|
+
this.stages = {
|
|
421
|
+
complete: {
|
|
422
|
+
/**
|
|
423
|
+
* Mark a stage as completed. Field work is done but stage may still need finalisation/billing.
|
|
424
|
+
* Operation: PublicJobStageController_complete
|
|
425
|
+
*/
|
|
426
|
+
complete: (params = {}, options = {}) => this.request('PublicJobStageController_complete', params, options),
|
|
427
|
+
},
|
|
428
|
+
finalise: {
|
|
429
|
+
/**
|
|
430
|
+
* Finalise a completed stage. This typically indicates billing/invoicing is complete.
|
|
431
|
+
* Operation: PublicJobStageController_finalise
|
|
432
|
+
*/
|
|
433
|
+
finalise: (params = {}, options = {}) => this.request('PublicJobStageController_finalise', params, options),
|
|
434
|
+
},
|
|
435
|
+
cancel: {
|
|
436
|
+
/**
|
|
437
|
+
* Cancel a stage. Provide a reason/note for the cancellation.
|
|
438
|
+
* Operation: PublicJobStageController_cancel
|
|
439
|
+
*/
|
|
440
|
+
cancel: (params = {}, options = {}) => this.request('PublicJobStageController_cancel', params, options),
|
|
441
|
+
},
|
|
442
|
+
reverse: {
|
|
443
|
+
/**
|
|
444
|
+
* Reverse (reopen) a stage to a previous status. This is an admin action that bypasses normal transition rules and clears fields appropriate to the target status.
|
|
445
|
+
* Operation: PublicJobStageController_reverse
|
|
446
|
+
*/
|
|
447
|
+
reverse: (params = {}, options = {}) => this.request('PublicJobStageController_reverse', params, options),
|
|
448
|
+
},
|
|
449
|
+
reissue: {
|
|
450
|
+
/**
|
|
451
|
+
* Resend dispatch notifications to all resources and contractor assigned to this stage.
|
|
452
|
+
* Operation: PublicJobStageController_reissue
|
|
453
|
+
*/
|
|
454
|
+
reissue: (params = {}, options = {}) => this.request('PublicJobStageController_reissue', params, options),
|
|
455
|
+
},
|
|
456
|
+
/**
|
|
457
|
+
* Create a new stage (work order) within a job. Stages represent discrete phases of work.
|
|
458
|
+
* Operation: PublicJobStageController_create
|
|
459
|
+
*/
|
|
460
|
+
create: (params = {}, options = {}) => this.request('PublicJobStageController_create', params, options),
|
|
461
|
+
/**
|
|
462
|
+
* Partially update a stage. Only provided fields will be modified.
|
|
463
|
+
* Operation: PublicJobStageController_update
|
|
464
|
+
*/
|
|
465
|
+
update: (params = {}, options = {}) => this.request('PublicJobStageController_update', params, options),
|
|
466
|
+
/**
|
|
467
|
+
* Permanently delete a stage and all associated items/resources. This action cannot be undone.
|
|
468
|
+
* Operation: PublicJobStageController_delete
|
|
469
|
+
*/
|
|
470
|
+
delete: (params = {}, options = {}) => this.request('PublicJobStageController_delete', params, options),
|
|
471
|
+
/**
|
|
472
|
+
* Change stage status to dispatched, making it ready for field work.
|
|
473
|
+
* Operation: PublicJobStageController_dispatch
|
|
474
|
+
*/
|
|
475
|
+
dispatch: (params = {}, options = {}) => this.request('PublicJobStageController_dispatch', params, options),
|
|
476
|
+
};
|
|
477
|
+
|
|
478
|
+
this.settings = {
|
|
479
|
+
entityStatuses: {
|
|
480
|
+
/**
|
|
481
|
+
* Retrieve all active statuses for a given entity type. Supported entities: customer, contractor, supplier
|
|
482
|
+
* Operation: PublicApiEntityStatusController_list
|
|
483
|
+
*/
|
|
484
|
+
list: (params = {}, options = {}) => this.request('PublicApiEntityStatusController_list', params, options),
|
|
485
|
+
},
|
|
486
|
+
jobStatuses: {
|
|
487
|
+
/**
|
|
488
|
+
* Retrieve all possible job statuses. These are system-defined status values that represent the aggregated state of a job based on its stages.
|
|
489
|
+
* Operation: PublicApiJobStatusController_list
|
|
490
|
+
*/
|
|
491
|
+
list: (params = {}, options = {}) => this.request('PublicApiJobStatusController_list', params, options),
|
|
492
|
+
},
|
|
493
|
+
jobTypes: {
|
|
494
|
+
/**
|
|
495
|
+
* Retrieve all active job types configured for the tenant. Job types categorize jobs by the type of work being performed (e.g., Maintenance, Installation, Repair).
|
|
496
|
+
* Operation: PublicApiJobTypeController_list
|
|
497
|
+
*/
|
|
498
|
+
list: (params = {}, options = {}) => this.request('PublicApiJobTypeController_list', params, options),
|
|
499
|
+
},
|
|
500
|
+
priorities: {
|
|
501
|
+
/**
|
|
502
|
+
* Retrieve all active priority levels configured for the tenant. Priorities indicate the urgency of jobs (e.g., Critical, High, Medium, Low).
|
|
503
|
+
* Operation: PublicApiPriorityController_list
|
|
504
|
+
*/
|
|
505
|
+
list: (params = {}, options = {}) => this.request('PublicApiPriorityController_list', params, options),
|
|
506
|
+
},
|
|
507
|
+
stageStatuses: {
|
|
508
|
+
/**
|
|
509
|
+
* Retrieve all stage statuses configured for the tenant. Stage statuses represent the workflow states a stage (work order) can transition through (e.g., New, Dispatched, En Route, On Site, Completed, Finalised).
|
|
510
|
+
* Operation: PublicApiStageStatusController_list
|
|
511
|
+
*/
|
|
512
|
+
list: (params = {}, options = {}) => this.request('PublicApiStageStatusController_list', params, options),
|
|
513
|
+
},
|
|
514
|
+
tags: {
|
|
515
|
+
/**
|
|
516
|
+
* Retrieve all active tags (labels) configured. Use the optional `type` query parameter to filter by label type. Defaults to `job` if not specified. Supported types: job, scheduling, quote, customer, user, overheads, form, finance, system, work-order-system, account, contact, zone, work-categories, lead-source, lead, opportunity, opportunity-lost, project, project-type, payment-type, file, asset, item-location, task, phase, site, service-type, subscriptions, agreement, work, integration-types, flag-category.
|
|
517
|
+
* Operation: PublicApiTagController_list
|
|
518
|
+
*/
|
|
519
|
+
list: (params = {}, options = {}) => this.request('PublicApiTagController_list', params, options),
|
|
520
|
+
},
|
|
521
|
+
zones: {
|
|
522
|
+
/**
|
|
523
|
+
* Retrieve all active zones configured for the tenant. Zones represent geographic regions used for job assignment, routing, and resource allocation.
|
|
524
|
+
* Operation: PublicApiZoneController_list
|
|
525
|
+
*/
|
|
526
|
+
list: (params = {}, options = {}) => this.request('PublicApiZoneController_list', params, options),
|
|
527
|
+
},
|
|
528
|
+
workTypes: {
|
|
529
|
+
/**
|
|
530
|
+
* Retrieve all active work types configured for the tenant (e.g., Labour, Travel, Administration) for time tracking and billing purposes.
|
|
531
|
+
* Operation: PublicApiWorkTypeController_list
|
|
532
|
+
*/
|
|
533
|
+
list: (params = {}, options = {}) => this.request('PublicApiWorkTypeController_list', params, options),
|
|
534
|
+
},
|
|
535
|
+
templates: {
|
|
536
|
+
email: {
|
|
537
|
+
/**
|
|
538
|
+
* Retrieve all active email templates for the specified entity type (job or stage).
|
|
539
|
+
* Operation: PublicApiTemplateController_listEmailTemplates
|
|
540
|
+
*/
|
|
541
|
+
listEmailTemplates: (params = {}, options = {}) =>
|
|
542
|
+
this.request('PublicApiTemplateController_listEmailTemplates', params, options),
|
|
543
|
+
},
|
|
544
|
+
sms: {
|
|
545
|
+
/**
|
|
546
|
+
* Retrieve all active SMS templates for the specified entity type (job or stage).
|
|
547
|
+
* Operation: PublicApiTemplateController_listSmsTemplates
|
|
548
|
+
*/
|
|
549
|
+
listSmsTemplates: (params = {}, options = {}) =>
|
|
550
|
+
this.request('PublicApiTemplateController_listSmsTemplates', params, options),
|
|
551
|
+
},
|
|
552
|
+
},
|
|
553
|
+
items: {
|
|
554
|
+
/**
|
|
555
|
+
* Retrieve paginated editable settings items.
|
|
556
|
+
* Operation: PublicApiItemController_list
|
|
557
|
+
*/
|
|
558
|
+
list: (params = {}, options = {}) => this.request('PublicApiItemController_list', params, options),
|
|
559
|
+
/**
|
|
560
|
+
* Create a settings item. This endpoint does not upsert.
|
|
561
|
+
* Operation: PublicApiItemController_create
|
|
562
|
+
*/
|
|
563
|
+
create: (params = {}, options = {}) => this.request('PublicApiItemController_create', params, options),
|
|
564
|
+
/**
|
|
565
|
+
* Retrieve a settings item by ID.
|
|
566
|
+
* Operation: PublicApiItemController_getById
|
|
567
|
+
*/
|
|
568
|
+
get: (params = {}, options = {}) => this.request('PublicApiItemController_getById', params, options),
|
|
569
|
+
/**
|
|
570
|
+
* Update a settings item by ID.
|
|
571
|
+
* Operation: PublicApiItemController_update
|
|
572
|
+
*/
|
|
573
|
+
update: (params = {}, options = {}) => this.request('PublicApiItemController_update', params, options),
|
|
574
|
+
/**
|
|
575
|
+
* Deactivate a settings item by ID.
|
|
576
|
+
* Operation: PublicApiItemController_delete
|
|
577
|
+
*/
|
|
578
|
+
delete: (params = {}, options = {}) => this.request('PublicApiItemController_delete', params, options),
|
|
579
|
+
/**
|
|
580
|
+
* Create or update a settings item using integrationId or name as the match key.
|
|
581
|
+
* Operation: PublicApiItemController_upsert
|
|
582
|
+
*/
|
|
583
|
+
upsert: (params = {}, options = {}) => this.request('PublicApiItemController_upsert', params, options),
|
|
584
|
+
},
|
|
585
|
+
itemCategories: {
|
|
586
|
+
/**
|
|
587
|
+
* Retrieve active item categories and sub-categories.
|
|
588
|
+
* Operation: PublicApiItemCategoryController_list
|
|
589
|
+
*/
|
|
590
|
+
list: (params = {}, options = {}) => this.request('PublicApiItemCategoryController_list', params, options),
|
|
591
|
+
/**
|
|
592
|
+
* Create a category/sub-category pair if it does not already exist.
|
|
593
|
+
* Operation: PublicApiItemCategoryController_upsert
|
|
594
|
+
*/
|
|
595
|
+
upsert: (params = {}, options = {}) => this.request('PublicApiItemCategoryController_upsert', params, options),
|
|
596
|
+
},
|
|
597
|
+
uoms: {
|
|
598
|
+
/**
|
|
599
|
+
* Retrieve active units of measure for item create/update.
|
|
600
|
+
* Operation: PublicApiUoMController_list
|
|
601
|
+
*/
|
|
602
|
+
list: (params = {}, options = {}) => this.request('PublicApiUoMController_list', params, options),
|
|
603
|
+
},
|
|
604
|
+
};
|
|
605
|
+
|
|
606
|
+
this.attachments = {
|
|
607
|
+
/**
|
|
608
|
+
* Creates an upload session and returns a SAS URL for direct upload to Azure Blob Storage.
|
|
609
|
+
|
|
610
|
+
**Upload Flow:**
|
|
611
|
+
1. POST to this endpoint with file metadata
|
|
612
|
+
2. Use the returned `uploadUrl` to PUT your file directly to blob storage
|
|
613
|
+
3. Include the required headers from the response in your PUT request
|
|
614
|
+
4. Store the `attachment.id` for later reference
|
|
615
|
+
|
|
616
|
+
**Constraints:**
|
|
617
|
+
- Maximum file size: 50MB
|
|
618
|
+
- Allowed content types: application/msword, application/vnd.openxmlformats-officedocument.wordprocessingml.document, application/pdf, text/plain, application/vnd.ms-excel.sheet.macroEnabled.12...
|
|
619
|
+
- Allowed extensions: .doc, .docx, .pdf, .txt, .xlsx, .xls, .xlsm, .csv, .json, .xml...
|
|
620
|
+
- Upload URL expires in 20 minutes
|
|
621
|
+
* Operation: PublicAttachmentController_createUploadSession
|
|
622
|
+
*/
|
|
623
|
+
createUploadSession: (params = {}, options = {}) =>
|
|
624
|
+
this.request('PublicAttachmentController_createUploadSession', params, options),
|
|
625
|
+
/**
|
|
626
|
+
* Downloads an attachment by redirecting to a time-limited SAS URL.
|
|
627
|
+
|
|
628
|
+
**Response:**
|
|
629
|
+
- 302 redirect to Azure Blob Storage with SAS token
|
|
630
|
+
- Content-Disposition header set for proper filename
|
|
631
|
+
|
|
632
|
+
**Note:** The SAS URL expires after 20 minutes. If expired, request a new download.
|
|
633
|
+
* Operation: PublicAttachmentController_download
|
|
634
|
+
*/
|
|
635
|
+
download: (params = {}, options = {}) => this.request('PublicAttachmentController_download', params, options),
|
|
636
|
+
};
|
|
637
|
+
|
|
638
|
+
this.crm = {
|
|
639
|
+
customers: {
|
|
640
|
+
contacts: {
|
|
641
|
+
/**
|
|
642
|
+
* List contacts for customer
|
|
643
|
+
* Operation: PublicCrmCustomerController_listContacts
|
|
644
|
+
*/
|
|
645
|
+
list: (params = {}, options = {}) =>
|
|
646
|
+
this.request('PublicCrmCustomerController_listContacts', params, options),
|
|
647
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
648
|
+
all: (params = {}, options = {}) =>
|
|
649
|
+
this.paginate('PublicCrmCustomerController_listContacts', params, options),
|
|
650
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
651
|
+
pages: (params = {}, options = {}) =>
|
|
652
|
+
this.paginatePages('PublicCrmCustomerController_listContacts', params, options),
|
|
653
|
+
},
|
|
654
|
+
sites: {
|
|
655
|
+
/**
|
|
656
|
+
* List sites for customer
|
|
657
|
+
* Operation: PublicCrmCustomerController_listSites
|
|
658
|
+
*/
|
|
659
|
+
list: (params = {}, options = {}) => this.request('PublicCrmCustomerController_listSites', params, options),
|
|
660
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
661
|
+
all: (params = {}, options = {}) => this.paginate('PublicCrmCustomerController_listSites', params, options),
|
|
662
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
663
|
+
pages: (params = {}, options = {}) =>
|
|
664
|
+
this.paginatePages('PublicCrmCustomerController_listSites', params, options),
|
|
665
|
+
},
|
|
666
|
+
/**
|
|
667
|
+
* List customers
|
|
668
|
+
* Operation: PublicCrmCustomerController_list
|
|
669
|
+
*/
|
|
670
|
+
list: (params = {}, options = {}) => this.request('PublicCrmCustomerController_list', params, options),
|
|
671
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
672
|
+
all: (params = {}, options = {}) => this.paginate('PublicCrmCustomerController_list', params, options),
|
|
673
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
674
|
+
pages: (params = {}, options = {}) => this.paginatePages('PublicCrmCustomerController_list', params, options),
|
|
675
|
+
/**
|
|
676
|
+
* Create customer
|
|
677
|
+
* Operation: PublicCrmCustomerController_create
|
|
678
|
+
*/
|
|
679
|
+
create: (params = {}, options = {}) => this.request('PublicCrmCustomerController_create', params, options),
|
|
680
|
+
/**
|
|
681
|
+
* Get customer by ID
|
|
682
|
+
* Operation: PublicCrmCustomerController_getById
|
|
683
|
+
*/
|
|
684
|
+
get: (params = {}, options = {}) => this.request('PublicCrmCustomerController_getById', params, options),
|
|
685
|
+
/**
|
|
686
|
+
* Update customer
|
|
687
|
+
* Operation: PublicCrmCustomerController_update
|
|
688
|
+
*/
|
|
689
|
+
update: (params = {}, options = {}) => this.request('PublicCrmCustomerController_update', params, options),
|
|
690
|
+
},
|
|
691
|
+
employees: {
|
|
692
|
+
/**
|
|
693
|
+
* List employees
|
|
694
|
+
* Operation: PublicCrmEmployeeController_list
|
|
695
|
+
*/
|
|
696
|
+
list: (params = {}, options = {}) => this.request('PublicCrmEmployeeController_list', params, options),
|
|
697
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
698
|
+
all: (params = {}, options = {}) => this.paginate('PublicCrmEmployeeController_list', params, options),
|
|
699
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
700
|
+
pages: (params = {}, options = {}) => this.paginatePages('PublicCrmEmployeeController_list', params, options),
|
|
701
|
+
/**
|
|
702
|
+
* Get employee by ID
|
|
703
|
+
* Operation: PublicCrmEmployeeController_getById
|
|
704
|
+
*/
|
|
705
|
+
get: (params = {}, options = {}) => this.request('PublicCrmEmployeeController_getById', params, options),
|
|
706
|
+
},
|
|
707
|
+
contractors: {
|
|
708
|
+
/**
|
|
709
|
+
* List contractors
|
|
710
|
+
* Operation: PublicCrmContractorController_list
|
|
711
|
+
*/
|
|
712
|
+
list: (params = {}, options = {}) => this.request('PublicCrmContractorController_list', params, options),
|
|
713
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
714
|
+
all: (params = {}, options = {}) => this.paginate('PublicCrmContractorController_list', params, options),
|
|
715
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
716
|
+
pages: (params = {}, options = {}) => this.paginatePages('PublicCrmContractorController_list', params, options),
|
|
717
|
+
/**
|
|
718
|
+
* Create contractor
|
|
719
|
+
* Operation: PublicCrmContractorController_create
|
|
720
|
+
*/
|
|
721
|
+
create: (params = {}, options = {}) => this.request('PublicCrmContractorController_create', params, options),
|
|
722
|
+
/**
|
|
723
|
+
* Get contractor by ID
|
|
724
|
+
* Operation: PublicCrmContractorController_getById
|
|
725
|
+
*/
|
|
726
|
+
get: (params = {}, options = {}) => this.request('PublicCrmContractorController_getById', params, options),
|
|
727
|
+
/**
|
|
728
|
+
* Update contractor
|
|
729
|
+
* Operation: PublicCrmContractorController_update
|
|
730
|
+
*/
|
|
731
|
+
update: (params = {}, options = {}) => this.request('PublicCrmContractorController_update', params, options),
|
|
732
|
+
},
|
|
733
|
+
suppliers: {
|
|
734
|
+
/**
|
|
735
|
+
* List suppliers
|
|
736
|
+
* Operation: PublicCrmSupplierController_list
|
|
737
|
+
*/
|
|
738
|
+
list: (params = {}, options = {}) => this.request('PublicCrmSupplierController_list', params, options),
|
|
739
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
740
|
+
all: (params = {}, options = {}) => this.paginate('PublicCrmSupplierController_list', params, options),
|
|
741
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
742
|
+
pages: (params = {}, options = {}) => this.paginatePages('PublicCrmSupplierController_list', params, options),
|
|
743
|
+
/**
|
|
744
|
+
* Create supplier
|
|
745
|
+
* Operation: PublicCrmSupplierController_create
|
|
746
|
+
*/
|
|
747
|
+
create: (params = {}, options = {}) => this.request('PublicCrmSupplierController_create', params, options),
|
|
748
|
+
/**
|
|
749
|
+
* Get supplier by ID
|
|
750
|
+
* Operation: PublicCrmSupplierController_getById
|
|
751
|
+
*/
|
|
752
|
+
get: (params = {}, options = {}) => this.request('PublicCrmSupplierController_getById', params, options),
|
|
753
|
+
/**
|
|
754
|
+
* Update supplier
|
|
755
|
+
* Operation: PublicCrmSupplierController_update
|
|
756
|
+
*/
|
|
757
|
+
update: (params = {}, options = {}) => this.request('PublicCrmSupplierController_update', params, options),
|
|
758
|
+
},
|
|
759
|
+
companies: {
|
|
760
|
+
/**
|
|
761
|
+
* List companies
|
|
762
|
+
* Operation: PublicCrmCompanyController_list
|
|
763
|
+
*/
|
|
764
|
+
list: (params = {}, options = {}) => this.request('PublicCrmCompanyController_list', params, options),
|
|
765
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
766
|
+
all: (params = {}, options = {}) => this.paginate('PublicCrmCompanyController_list', params, options),
|
|
767
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
768
|
+
pages: (params = {}, options = {}) => this.paginatePages('PublicCrmCompanyController_list', params, options),
|
|
769
|
+
/**
|
|
770
|
+
* Get company by ID
|
|
771
|
+
* Operation: PublicCrmCompanyController_getById
|
|
772
|
+
*/
|
|
773
|
+
get: (params = {}, options = {}) => this.request('PublicCrmCompanyController_getById', params, options),
|
|
774
|
+
},
|
|
775
|
+
externalUsers: {
|
|
776
|
+
/**
|
|
777
|
+
* List external users
|
|
778
|
+
* Operation: PublicCrmExternalUserController_list
|
|
779
|
+
*/
|
|
780
|
+
list: (params = {}, options = {}) => this.request('PublicCrmExternalUserController_list', params, options),
|
|
781
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
782
|
+
all: (params = {}, options = {}) => this.paginate('PublicCrmExternalUserController_list', params, options),
|
|
783
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
784
|
+
pages: (params = {}, options = {}) =>
|
|
785
|
+
this.paginatePages('PublicCrmExternalUserController_list', params, options),
|
|
786
|
+
/**
|
|
787
|
+
* Get external user by ID
|
|
788
|
+
* Operation: PublicCrmExternalUserController_getById
|
|
789
|
+
*/
|
|
790
|
+
get: (params = {}, options = {}) => this.request('PublicCrmExternalUserController_getById', params, options),
|
|
791
|
+
},
|
|
792
|
+
contacts: {
|
|
793
|
+
/**
|
|
794
|
+
* List contacts (Basic and Login contacts)
|
|
795
|
+
* Operation: PublicCrmContactController_list
|
|
796
|
+
*/
|
|
797
|
+
list: (params = {}, options = {}) => this.request('PublicCrmContactController_list', params, options),
|
|
798
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
799
|
+
all: (params = {}, options = {}) => this.paginate('PublicCrmContactController_list', params, options),
|
|
800
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
801
|
+
pages: (params = {}, options = {}) => this.paginatePages('PublicCrmContactController_list', params, options),
|
|
802
|
+
/**
|
|
803
|
+
* Get contact by ID
|
|
804
|
+
* Operation: PublicCrmContactController_getById
|
|
805
|
+
*/
|
|
806
|
+
get: (params = {}, options = {}) => this.request('PublicCrmContactController_getById', params, options),
|
|
807
|
+
},
|
|
808
|
+
invites: {
|
|
809
|
+
/**
|
|
810
|
+
* List pending invites
|
|
811
|
+
* Operation: PublicCrmInviteController_list
|
|
812
|
+
*/
|
|
813
|
+
list: (params = {}, options = {}) => this.request('PublicCrmInviteController_list', params, options),
|
|
814
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
815
|
+
all: (params = {}, options = {}) => this.paginate('PublicCrmInviteController_list', params, options),
|
|
816
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
817
|
+
pages: (params = {}, options = {}) => this.paginatePages('PublicCrmInviteController_list', params, options),
|
|
818
|
+
/**
|
|
819
|
+
* Get invite by ID
|
|
820
|
+
* Operation: PublicCrmInviteController_getById
|
|
821
|
+
*/
|
|
822
|
+
get: (params = {}, options = {}) => this.request('PublicCrmInviteController_getById', params, options),
|
|
823
|
+
},
|
|
824
|
+
sites: {
|
|
825
|
+
/**
|
|
826
|
+
* List all sites
|
|
827
|
+
* Operation: PublicCrmSiteController_list
|
|
828
|
+
*/
|
|
829
|
+
list: (params = {}, options = {}) => this.request('PublicCrmSiteController_list', params, options),
|
|
830
|
+
/** Iterate all items by following cursor pagination for list(). */
|
|
831
|
+
all: (params = {}, options = {}) => this.paginate('PublicCrmSiteController_list', params, options),
|
|
832
|
+
/** Iterate raw pages by following cursor pagination for list(). */
|
|
833
|
+
pages: (params = {}, options = {}) => this.paginatePages('PublicCrmSiteController_list', params, options),
|
|
834
|
+
/**
|
|
835
|
+
* Get site by ID
|
|
836
|
+
* Operation: PublicCrmSiteController_getById
|
|
837
|
+
*/
|
|
838
|
+
get: (params = {}, options = {}) => this.request('PublicCrmSiteController_getById', params, options),
|
|
839
|
+
},
|
|
840
|
+
};
|
|
841
|
+
|
|
842
|
+
this.webhooks = {
|
|
843
|
+
entities: {
|
|
844
|
+
events: {
|
|
845
|
+
/**
|
|
846
|
+
* List the webhook events available for a given entity type
|
|
847
|
+
* Operation: PublicApiWebhookV2Controller_listEntityEvents
|
|
848
|
+
*/
|
|
849
|
+
list: (params = {}, options = {}) =>
|
|
850
|
+
this.request('PublicApiWebhookV2Controller_listEntityEvents', params, options),
|
|
851
|
+
},
|
|
852
|
+
filters: {
|
|
853
|
+
/**
|
|
854
|
+
* List the filter fields available when subscribing to a given entity type
|
|
855
|
+
* Operation: PublicApiWebhookV2Controller_listEntityFilters
|
|
856
|
+
*/
|
|
857
|
+
list: (params = {}, options = {}) =>
|
|
858
|
+
this.request('PublicApiWebhookV2Controller_listEntityFilters', params, options),
|
|
859
|
+
},
|
|
860
|
+
/**
|
|
861
|
+
* List webhook-supported entity types and their available events
|
|
862
|
+
* Operation: PublicApiWebhookV2Controller_listEntities
|
|
863
|
+
*/
|
|
864
|
+
list: (params = {}, options = {}) => this.request('PublicApiWebhookV2Controller_listEntities', params, options),
|
|
865
|
+
},
|
|
866
|
+
regenerateSecret: {
|
|
867
|
+
/**
|
|
868
|
+
* Regenerate the signing secret for a webhook subscription
|
|
869
|
+
* Operation: PublicApiWebhookV2Controller_regenerateSecret
|
|
870
|
+
*/
|
|
871
|
+
regenerateSecret: (params = {}, options = {}) =>
|
|
872
|
+
this.request('PublicApiWebhookV2Controller_regenerateSecret', params, options),
|
|
873
|
+
},
|
|
874
|
+
test: {
|
|
875
|
+
/**
|
|
876
|
+
* Send a test event to a webhook subscription
|
|
877
|
+
* Operation: PublicApiWebhookV2Controller_test
|
|
878
|
+
*/
|
|
879
|
+
test: (params = {}, options = {}) => this.request('PublicApiWebhookV2Controller_test', params, options),
|
|
880
|
+
},
|
|
881
|
+
deliveries: {
|
|
882
|
+
/**
|
|
883
|
+
* List recent delivery attempts for a webhook subscription
|
|
884
|
+
* Operation: PublicApiWebhookV2Controller_listDeliveries
|
|
885
|
+
*/
|
|
886
|
+
list: (params = {}, options = {}) =>
|
|
887
|
+
this.request('PublicApiWebhookV2Controller_listDeliveries', params, options),
|
|
888
|
+
},
|
|
889
|
+
/**
|
|
890
|
+
* List webhook subscriptions
|
|
891
|
+
* Operation: PublicApiWebhookV2Controller_list
|
|
892
|
+
*/
|
|
893
|
+
list: (params = {}, options = {}) => this.request('PublicApiWebhookV2Controller_list', params, options),
|
|
894
|
+
/**
|
|
895
|
+
* Create a webhook subscription
|
|
896
|
+
* Operation: PublicApiWebhookV2Controller_create
|
|
897
|
+
*/
|
|
898
|
+
create: (params = {}, options = {}) => this.request('PublicApiWebhookV2Controller_create', params, options),
|
|
899
|
+
/**
|
|
900
|
+
* Get a webhook subscription by ID
|
|
901
|
+
* Operation: PublicApiWebhookV2Controller_get
|
|
902
|
+
*/
|
|
903
|
+
get: (params = {}, options = {}) => this.request('PublicApiWebhookV2Controller_get', params, options),
|
|
904
|
+
/**
|
|
905
|
+
* Update a webhook subscription
|
|
906
|
+
* Operation: PublicApiWebhookV2Controller_update
|
|
907
|
+
*/
|
|
908
|
+
update: (params = {}, options = {}) => this.request('PublicApiWebhookV2Controller_update', params, options),
|
|
909
|
+
/**
|
|
910
|
+
* Delete a webhook subscription
|
|
911
|
+
* Operation: PublicApiWebhookV2Controller_delete
|
|
912
|
+
*/
|
|
913
|
+
delete: (params = {}, options = {}) => this.request('PublicApiWebhookV2Controller_delete', params, options),
|
|
914
|
+
};
|
|
915
|
+
|
|
916
|
+
this.exports = {
|
|
917
|
+
/**
|
|
918
|
+
* Bulk export data from a MongoDB view. Returns raw view documents with pagination. Financial fields are stripped unless the token has the jobs:financial scope.
|
|
919
|
+
* Operation: PublicExportController_export
|
|
920
|
+
*/
|
|
921
|
+
export: (params = {}, options = {}) => this.request('PublicExportController_export', params, options),
|
|
922
|
+
};
|
|
923
|
+
|
|
924
|
+
this.agentHarness = {
|
|
925
|
+
runs: {
|
|
926
|
+
events: {
|
|
927
|
+
/**
|
|
928
|
+
* Used by an external agent to report progress, action-required, completed, failed, heartbeat, or message events for an existing run.
|
|
929
|
+
* Operation: PublicApiAgentHarnessController_ingestEvent
|
|
930
|
+
*/
|
|
931
|
+
ingestEvent: (params = {}, options = {}) =>
|
|
932
|
+
this.request('PublicApiAgentHarnessController_ingestEvent', params, options),
|
|
933
|
+
},
|
|
934
|
+
actionResolved: {
|
|
935
|
+
/**
|
|
936
|
+
* Used by an external agent to post the resolution payload for a run that previously entered action-required state.
|
|
937
|
+
* Operation: PublicApiAgentHarnessController_resolveAction
|
|
938
|
+
*/
|
|
939
|
+
resolveAction: (params = {}, options = {}) =>
|
|
940
|
+
this.request('PublicApiAgentHarnessController_resolveAction', params, options),
|
|
941
|
+
},
|
|
942
|
+
},
|
|
943
|
+
};
|
|
944
|
+
|
|
945
|
+
this.flags = {
|
|
946
|
+
close: {
|
|
947
|
+
/**
|
|
948
|
+
* Close a flag
|
|
949
|
+
* Operation: PublicApiFlagController_close
|
|
950
|
+
*/
|
|
951
|
+
close: (params = {}, options = {}) => this.request('PublicApiFlagController_close', params, options),
|
|
952
|
+
},
|
|
953
|
+
entity: {
|
|
954
|
+
/**
|
|
955
|
+
* List flags for an entity
|
|
956
|
+
* Operation: PublicApiFlagController_listByEntity
|
|
957
|
+
*/
|
|
958
|
+
list: (params = {}, options = {}) => this.request('PublicApiFlagController_listByEntity', params, options),
|
|
959
|
+
},
|
|
960
|
+
/**
|
|
961
|
+
* Create a flag on an entity
|
|
962
|
+
* Operation: PublicApiFlagController_create
|
|
963
|
+
*/
|
|
964
|
+
create: (params = {}, options = {}) => this.request('PublicApiFlagController_create', params, options),
|
|
965
|
+
};
|
|
966
|
+
|
|
967
|
+
this.mcp = {
|
|
968
|
+
/**
|
|
969
|
+
* Returns 405 — server-initiated SSE is not supported.
|
|
970
|
+
* Operation: McpV3StreamableController_handleGet
|
|
971
|
+
*/
|
|
972
|
+
list: (params = {}, options = {}) => this.request('McpV3StreamableController_handleGet', params, options),
|
|
973
|
+
/**
|
|
974
|
+
* Handles MCP JSON-RPC 2.0 requests against the collapsed tool set.
|
|
975
|
+
* Operation: McpV3StreamableController_handlePost
|
|
976
|
+
*/
|
|
977
|
+
create: (params = {}, options = {}) => this.request('McpV3StreamableController_handlePost', params, options),
|
|
978
|
+
/**
|
|
979
|
+
* Returns 405 — stateless server, no sessions to terminate.
|
|
980
|
+
* Operation: McpV3StreamableController_handleDelete
|
|
981
|
+
*/
|
|
982
|
+
delete: (params = {}, options = {}) => this.request('McpV3StreamableController_handleDelete', params, options),
|
|
983
|
+
};
|
|
984
|
+
}
|
|
985
|
+
|
|
986
|
+
async request(operationId, params = {}, options = {}) {
|
|
987
|
+
const operation = operationMap[operationId];
|
|
988
|
+
if (!operation) {
|
|
989
|
+
throw new Error('Unknown WorkBuddy operation: ' + operationId);
|
|
990
|
+
}
|
|
991
|
+
|
|
992
|
+
return this.execute(operation, params, options);
|
|
993
|
+
}
|
|
994
|
+
|
|
995
|
+
async *paginatePages(operationId, params = {}, options = {}) {
|
|
996
|
+
let cursor = params.cursor;
|
|
997
|
+
|
|
998
|
+
while (true) {
|
|
999
|
+
const page = await this.request(operationId, { ...params, cursor }, options);
|
|
1000
|
+
yield page;
|
|
1001
|
+
|
|
1002
|
+
const nextCursor = page?.pagination?.nextCursor;
|
|
1003
|
+
if (!page?.pagination?.hasMore || !nextCursor) {
|
|
1004
|
+
break;
|
|
1005
|
+
}
|
|
1006
|
+
|
|
1007
|
+
cursor = nextCursor;
|
|
1008
|
+
}
|
|
1009
|
+
}
|
|
1010
|
+
|
|
1011
|
+
async *paginate(operationId, params = {}, options = {}) {
|
|
1012
|
+
for await (const page of this.paginatePages(operationId, params, options)) {
|
|
1013
|
+
const items = Array.isArray(page?.items) ? page.items : Array.isArray(page?.data) ? page.data : [];
|
|
1014
|
+
for (const item of items) {
|
|
1015
|
+
yield item;
|
|
1016
|
+
}
|
|
1017
|
+
}
|
|
1018
|
+
}
|
|
1019
|
+
|
|
1020
|
+
async execute(operation, params, options) {
|
|
1021
|
+
const pathParams = params.path ?? {};
|
|
1022
|
+
const queryParams = params.query ?? {};
|
|
1023
|
+
let requestPath = operation.path;
|
|
1024
|
+
|
|
1025
|
+
for (const name of operation.pathParams) {
|
|
1026
|
+
const value = params[name] ?? pathParams[name];
|
|
1027
|
+
if (value === undefined || value === null || value === '') {
|
|
1028
|
+
throw new Error('Missing required path parameter: ' + name);
|
|
1029
|
+
}
|
|
1030
|
+
requestPath = requestPath.replace('{' + name + '}', encodeURIComponent(String(value)));
|
|
1031
|
+
}
|
|
1032
|
+
|
|
1033
|
+
const url = new URL(PUBLIC_API_BASE_PATH + requestPath, this.baseUrl);
|
|
1034
|
+
for (const name of operation.queryParams) {
|
|
1035
|
+
const value = params[name] ?? queryParams[name];
|
|
1036
|
+
appendQueryValue(url.searchParams, name, value);
|
|
1037
|
+
}
|
|
1038
|
+
|
|
1039
|
+
const headers = {
|
|
1040
|
+
Accept: 'application/json',
|
|
1041
|
+
'X-WorkBuddy-Version': this.apiVersion,
|
|
1042
|
+
...this.defaultHeaders,
|
|
1043
|
+
...(options.headers ?? {}),
|
|
1044
|
+
};
|
|
1045
|
+
|
|
1046
|
+
const token = options.accessToken ?? this.accessToken ?? (await this.getAccessToken());
|
|
1047
|
+
if (token) {
|
|
1048
|
+
headers.Authorization = 'Bearer ' + token;
|
|
1049
|
+
}
|
|
1050
|
+
|
|
1051
|
+
const init = {
|
|
1052
|
+
...options,
|
|
1053
|
+
method: operation.method,
|
|
1054
|
+
headers,
|
|
1055
|
+
};
|
|
1056
|
+
delete init.accessToken;
|
|
1057
|
+
|
|
1058
|
+
const body = resolveBody(operation, params);
|
|
1059
|
+
if (body !== undefined) {
|
|
1060
|
+
const isFormData = typeof FormData !== 'undefined' && body instanceof FormData;
|
|
1061
|
+
if (!isFormData) {
|
|
1062
|
+
headers['Content-Type'] ??= 'application/json';
|
|
1063
|
+
}
|
|
1064
|
+
init.body = typeof body === 'string' || isFormData ? body : JSON.stringify(body);
|
|
1065
|
+
}
|
|
1066
|
+
|
|
1067
|
+
const response = await this.fetch(url, init);
|
|
1068
|
+
const data = await parseResponse(response);
|
|
1069
|
+
if (!response.ok) {
|
|
1070
|
+
throw new WorkBuddyApiError(buildErrorMessage(response, data), response, data);
|
|
1071
|
+
}
|
|
1072
|
+
|
|
1073
|
+
return data;
|
|
1074
|
+
}
|
|
1075
|
+
|
|
1076
|
+
async getAccessToken() {
|
|
1077
|
+
if (this.accessTokenProvider) {
|
|
1078
|
+
const token = await this.accessTokenProvider();
|
|
1079
|
+
if (token) {
|
|
1080
|
+
return token;
|
|
1081
|
+
}
|
|
1082
|
+
}
|
|
1083
|
+
|
|
1084
|
+
if (this.token && this.token.expiresAt > Date.now() + 30000) {
|
|
1085
|
+
return this.token.accessToken;
|
|
1086
|
+
}
|
|
1087
|
+
|
|
1088
|
+
if (!this.clientId || !this.clientSecret) {
|
|
1089
|
+
return undefined;
|
|
1090
|
+
}
|
|
1091
|
+
|
|
1092
|
+
const tokenUrl = new URL(this.tokenUrl, this.baseUrl);
|
|
1093
|
+
const body = new URLSearchParams({
|
|
1094
|
+
grant_type: 'client_credentials',
|
|
1095
|
+
client_id: this.clientId,
|
|
1096
|
+
client_secret: this.clientSecret,
|
|
1097
|
+
scope: '*',
|
|
1098
|
+
});
|
|
1099
|
+
|
|
1100
|
+
const response = await this.fetch(tokenUrl, {
|
|
1101
|
+
method: 'POST',
|
|
1102
|
+
headers: {
|
|
1103
|
+
Accept: 'application/json',
|
|
1104
|
+
'Content-Type': 'application/x-www-form-urlencoded',
|
|
1105
|
+
},
|
|
1106
|
+
body,
|
|
1107
|
+
});
|
|
1108
|
+
const data = await parseResponse(response);
|
|
1109
|
+
if (!response.ok) {
|
|
1110
|
+
throw new WorkBuddyApiError(buildErrorMessage(response, data), response, data);
|
|
1111
|
+
}
|
|
1112
|
+
|
|
1113
|
+
this.token = {
|
|
1114
|
+
accessToken: data.access_token,
|
|
1115
|
+
expiresAt: Date.now() + (data.expires_in ?? 3600) * 1000,
|
|
1116
|
+
};
|
|
1117
|
+
|
|
1118
|
+
return this.token.accessToken;
|
|
1119
|
+
}
|
|
1120
|
+
}
|
|
1121
|
+
|
|
1122
|
+
function resolveBody(operation, params) {
|
|
1123
|
+
if (!operation.hasRequestBody) {
|
|
1124
|
+
return undefined;
|
|
1125
|
+
}
|
|
1126
|
+
|
|
1127
|
+
if (params.body !== undefined) {
|
|
1128
|
+
return params.body;
|
|
1129
|
+
}
|
|
1130
|
+
|
|
1131
|
+
if (params.data !== undefined) {
|
|
1132
|
+
return params.data;
|
|
1133
|
+
}
|
|
1134
|
+
|
|
1135
|
+
const ignored = new Set([...operation.pathParams, ...operation.queryParams, 'path', 'query', 'body', 'data']);
|
|
1136
|
+
const body = {};
|
|
1137
|
+
for (const [key, value] of Object.entries(params)) {
|
|
1138
|
+
if (!ignored.has(key) && value !== undefined) {
|
|
1139
|
+
body[key] = value;
|
|
1140
|
+
}
|
|
1141
|
+
}
|
|
1142
|
+
|
|
1143
|
+
return Object.keys(body).length > 0 ? body : undefined;
|
|
1144
|
+
}
|
|
1145
|
+
|
|
1146
|
+
function appendQueryValue(searchParams, name, value) {
|
|
1147
|
+
if (value === undefined || value === null || value === '') {
|
|
1148
|
+
return;
|
|
1149
|
+
}
|
|
1150
|
+
|
|
1151
|
+
searchParams.append(name, serializeQueryValue(value));
|
|
1152
|
+
}
|
|
1153
|
+
|
|
1154
|
+
function serializeQueryValue(value) {
|
|
1155
|
+
if (Array.isArray(value) || (typeof value === 'object' && value !== null)) {
|
|
1156
|
+
return JSON.stringify(value);
|
|
1157
|
+
}
|
|
1158
|
+
return String(value);
|
|
1159
|
+
}
|
|
1160
|
+
|
|
1161
|
+
async function parseResponse(response) {
|
|
1162
|
+
if (response.status === 204) {
|
|
1163
|
+
return undefined;
|
|
1164
|
+
}
|
|
1165
|
+
|
|
1166
|
+
const contentType = response.headers.get('content-type') ?? '';
|
|
1167
|
+
if (contentType.includes('application/json')) {
|
|
1168
|
+
const text = await response.text();
|
|
1169
|
+
return text ? JSON.parse(text) : null;
|
|
1170
|
+
}
|
|
1171
|
+
|
|
1172
|
+
if (contentType.startsWith('text/')) {
|
|
1173
|
+
return response.text();
|
|
1174
|
+
}
|
|
1175
|
+
|
|
1176
|
+
return response.arrayBuffer();
|
|
1177
|
+
}
|
|
1178
|
+
|
|
1179
|
+
function buildErrorMessage(response, data) {
|
|
1180
|
+
const detail = data?.error?.message ?? data?.error?.code ?? data?.message ?? data?.details;
|
|
1181
|
+
return detail
|
|
1182
|
+
? 'WorkBuddy API request failed with status ' + response.status + ': ' + detail
|
|
1183
|
+
: 'WorkBuddy API request failed with status ' + response.status;
|
|
1184
|
+
}
|
|
1185
|
+
|
|
1186
|
+
export const operations = [
|
|
1187
|
+
{
|
|
1188
|
+
operationId: 'PublicApiJobController_search',
|
|
1189
|
+
resourcePath: ['jobs'],
|
|
1190
|
+
actionName: 'search',
|
|
1191
|
+
paginatedItemsActionName: 'all',
|
|
1192
|
+
paginatedPagesActionName: 'pages',
|
|
1193
|
+
displayName: 'Search jobs or stages with complex filters',
|
|
1194
|
+
description:
|
|
1195
|
+
"Advanced search endpoint for complex queries. Use mode='jobs' (default) to search jobs, or mode='stages' to search stages with embedded job context. Supports multiple filters, date ranges, and field projection via JSON body.",
|
|
1196
|
+
method: 'POST',
|
|
1197
|
+
path: '/jobs/search',
|
|
1198
|
+
pathParams: [],
|
|
1199
|
+
queryParams: [],
|
|
1200
|
+
hasRequestBody: true,
|
|
1201
|
+
},
|
|
1202
|
+
{
|
|
1203
|
+
operationId: 'PublicApiJobController_get',
|
|
1204
|
+
resourcePath: ['jobs'],
|
|
1205
|
+
actionName: 'get',
|
|
1206
|
+
displayName: 'Get job by ID or job number',
|
|
1207
|
+
description: 'Retrieve a single job by its ID, human-readable job number, or external integration ID.',
|
|
1208
|
+
method: 'GET',
|
|
1209
|
+
path: '/jobs/{identifier}',
|
|
1210
|
+
pathParams: ['identifier'],
|
|
1211
|
+
queryParams: [],
|
|
1212
|
+
hasRequestBody: false,
|
|
1213
|
+
},
|
|
1214
|
+
{
|
|
1215
|
+
operationId: 'PublicApiJobController_delete',
|
|
1216
|
+
resourcePath: ['jobs'],
|
|
1217
|
+
actionName: 'delete',
|
|
1218
|
+
displayName: 'Cancel a job',
|
|
1219
|
+
description:
|
|
1220
|
+
"Cancel a job by ID or job number. Jobs cannot be permanently deleted, only cancelled. This changes the job status to 'cancelled'. A reason must be provided.",
|
|
1221
|
+
method: 'DELETE',
|
|
1222
|
+
path: '/jobs/{identifier}',
|
|
1223
|
+
pathParams: ['identifier'],
|
|
1224
|
+
queryParams: [],
|
|
1225
|
+
hasRequestBody: true,
|
|
1226
|
+
},
|
|
1227
|
+
{
|
|
1228
|
+
operationId: 'PublicApiJobController_create',
|
|
1229
|
+
resourcePath: ['jobs'],
|
|
1230
|
+
actionName: 'create',
|
|
1231
|
+
displayName: 'Create a new job',
|
|
1232
|
+
description: 'Create a new job with the specified details. Requires either customerId or inline customer object.',
|
|
1233
|
+
method: 'POST',
|
|
1234
|
+
path: '/jobs',
|
|
1235
|
+
pathParams: [],
|
|
1236
|
+
queryParams: [],
|
|
1237
|
+
hasRequestBody: true,
|
|
1238
|
+
},
|
|
1239
|
+
{
|
|
1240
|
+
operationId: 'PublicApiJobController_update',
|
|
1241
|
+
resourcePath: ['jobs'],
|
|
1242
|
+
actionName: 'update',
|
|
1243
|
+
displayName: 'Update a job',
|
|
1244
|
+
description: 'Partially update a job. Only provided fields will be modified.',
|
|
1245
|
+
method: 'PATCH',
|
|
1246
|
+
path: '/jobs/{id}',
|
|
1247
|
+
pathParams: ['id'],
|
|
1248
|
+
queryParams: [],
|
|
1249
|
+
hasRequestBody: true,
|
|
1250
|
+
},
|
|
1251
|
+
{
|
|
1252
|
+
operationId: 'PublicApiJobController_dispatch',
|
|
1253
|
+
resourcePath: ['jobs'],
|
|
1254
|
+
actionName: 'dispatch',
|
|
1255
|
+
displayName: 'Dispatch a job',
|
|
1256
|
+
description: 'Change job status to dispatched, making it ready for field work.',
|
|
1257
|
+
method: 'POST',
|
|
1258
|
+
path: '/jobs/{id}/dispatch',
|
|
1259
|
+
pathParams: ['id'],
|
|
1260
|
+
queryParams: [],
|
|
1261
|
+
hasRequestBody: false,
|
|
1262
|
+
},
|
|
1263
|
+
{
|
|
1264
|
+
operationId: 'PublicApiJobController_getJobStages',
|
|
1265
|
+
resourcePath: ['jobs', 'stages'],
|
|
1266
|
+
actionName: 'list',
|
|
1267
|
+
paginatedItemsActionName: 'all',
|
|
1268
|
+
paginatedPagesActionName: 'pages',
|
|
1269
|
+
displayName: 'List job stages',
|
|
1270
|
+
description: 'Get all stages (work orders) for a job.',
|
|
1271
|
+
method: 'GET',
|
|
1272
|
+
path: '/jobs/{id}/stages',
|
|
1273
|
+
pathParams: ['id'],
|
|
1274
|
+
queryParams: ['cursor', 'limit'],
|
|
1275
|
+
hasRequestBody: false,
|
|
1276
|
+
},
|
|
1277
|
+
{
|
|
1278
|
+
operationId: 'PublicApiJobController_getJobStage',
|
|
1279
|
+
resourcePath: ['jobs', 'stages'],
|
|
1280
|
+
actionName: 'getJobStage',
|
|
1281
|
+
displayName: 'Get job stage',
|
|
1282
|
+
description: 'Get a specific stage within a job.',
|
|
1283
|
+
method: 'GET',
|
|
1284
|
+
path: '/jobs/{id}/stages/{stageId}',
|
|
1285
|
+
pathParams: ['id', 'stageId'],
|
|
1286
|
+
queryParams: [],
|
|
1287
|
+
hasRequestBody: false,
|
|
1288
|
+
},
|
|
1289
|
+
{
|
|
1290
|
+
operationId: 'PublicApiJobController_getStageItems',
|
|
1291
|
+
resourcePath: ['jobs', 'stages', 'items'],
|
|
1292
|
+
actionName: 'list',
|
|
1293
|
+
paginatedItemsActionName: 'all',
|
|
1294
|
+
paginatedPagesActionName: 'pages',
|
|
1295
|
+
displayName: 'List stage items',
|
|
1296
|
+
description: 'Get all items (line items) for a stage.',
|
|
1297
|
+
method: 'GET',
|
|
1298
|
+
path: '/jobs/{id}/stages/{stageId}/items',
|
|
1299
|
+
pathParams: ['id', 'stageId'],
|
|
1300
|
+
queryParams: ['cursor', 'limit'],
|
|
1301
|
+
hasRequestBody: false,
|
|
1302
|
+
},
|
|
1303
|
+
{
|
|
1304
|
+
operationId: 'PublicApiJobController_getStageItem',
|
|
1305
|
+
resourcePath: ['jobs', 'stages', 'items'],
|
|
1306
|
+
actionName: 'getStageItem',
|
|
1307
|
+
displayName: 'Get stage item',
|
|
1308
|
+
description: 'Get a specific item within a stage.',
|
|
1309
|
+
method: 'GET',
|
|
1310
|
+
path: '/jobs/{id}/stages/{stageId}/items/{itemId}',
|
|
1311
|
+
pathParams: ['id', 'stageId', 'itemId'],
|
|
1312
|
+
queryParams: [],
|
|
1313
|
+
hasRequestBody: false,
|
|
1314
|
+
},
|
|
1315
|
+
{
|
|
1316
|
+
operationId: 'PublicJobStageController_create',
|
|
1317
|
+
resourcePath: ['stages'],
|
|
1318
|
+
actionName: 'create',
|
|
1319
|
+
displayName: 'Create a new stage',
|
|
1320
|
+
description: 'Create a new stage (work order) within a job. Stages represent discrete phases of work.',
|
|
1321
|
+
method: 'POST',
|
|
1322
|
+
path: '/stages',
|
|
1323
|
+
pathParams: [],
|
|
1324
|
+
queryParams: [],
|
|
1325
|
+
hasRequestBody: true,
|
|
1326
|
+
},
|
|
1327
|
+
{
|
|
1328
|
+
operationId: 'PublicJobStageController_update',
|
|
1329
|
+
resourcePath: ['stages'],
|
|
1330
|
+
actionName: 'update',
|
|
1331
|
+
displayName: 'Update a stage',
|
|
1332
|
+
description: 'Partially update a stage. Only provided fields will be modified.',
|
|
1333
|
+
method: 'PATCH',
|
|
1334
|
+
path: '/stages/{id}',
|
|
1335
|
+
pathParams: ['id'],
|
|
1336
|
+
queryParams: [],
|
|
1337
|
+
hasRequestBody: true,
|
|
1338
|
+
},
|
|
1339
|
+
{
|
|
1340
|
+
operationId: 'PublicJobStageController_delete',
|
|
1341
|
+
resourcePath: ['stages'],
|
|
1342
|
+
actionName: 'delete',
|
|
1343
|
+
displayName: 'Delete a stage',
|
|
1344
|
+
description: 'Permanently delete a stage and all associated items/resources. This action cannot be undone.',
|
|
1345
|
+
method: 'DELETE',
|
|
1346
|
+
path: '/stages/{id}',
|
|
1347
|
+
pathParams: ['id'],
|
|
1348
|
+
queryParams: [],
|
|
1349
|
+
hasRequestBody: false,
|
|
1350
|
+
},
|
|
1351
|
+
{
|
|
1352
|
+
operationId: 'PublicJobStageController_dispatch',
|
|
1353
|
+
resourcePath: ['stages'],
|
|
1354
|
+
actionName: 'dispatch',
|
|
1355
|
+
displayName: 'Dispatch a stage',
|
|
1356
|
+
description: 'Change stage status to dispatched, making it ready for field work.',
|
|
1357
|
+
method: 'POST',
|
|
1358
|
+
path: '/stages/{id}/dispatch',
|
|
1359
|
+
pathParams: ['id'],
|
|
1360
|
+
queryParams: [],
|
|
1361
|
+
hasRequestBody: false,
|
|
1362
|
+
},
|
|
1363
|
+
{
|
|
1364
|
+
operationId: 'PublicJobStageController_complete',
|
|
1365
|
+
resourcePath: ['stages', 'complete'],
|
|
1366
|
+
actionName: 'complete',
|
|
1367
|
+
displayName: 'Complete a stage',
|
|
1368
|
+
description: 'Mark a stage as completed. Field work is done but stage may still need finalisation/billing.',
|
|
1369
|
+
method: 'POST',
|
|
1370
|
+
path: '/stages/{id}/complete',
|
|
1371
|
+
pathParams: ['id'],
|
|
1372
|
+
queryParams: [],
|
|
1373
|
+
hasRequestBody: true,
|
|
1374
|
+
},
|
|
1375
|
+
{
|
|
1376
|
+
operationId: 'PublicJobStageController_finalise',
|
|
1377
|
+
resourcePath: ['stages', 'finalise'],
|
|
1378
|
+
actionName: 'finalise',
|
|
1379
|
+
displayName: 'Finalise a stage',
|
|
1380
|
+
description: 'Finalise a completed stage. This typically indicates billing/invoicing is complete.',
|
|
1381
|
+
method: 'POST',
|
|
1382
|
+
path: '/stages/{id}/finalise',
|
|
1383
|
+
pathParams: ['id'],
|
|
1384
|
+
queryParams: [],
|
|
1385
|
+
hasRequestBody: true,
|
|
1386
|
+
},
|
|
1387
|
+
{
|
|
1388
|
+
operationId: 'PublicJobStageController_cancel',
|
|
1389
|
+
resourcePath: ['stages', 'cancel'],
|
|
1390
|
+
actionName: 'cancel',
|
|
1391
|
+
displayName: 'Cancel a stage',
|
|
1392
|
+
description: 'Cancel a stage. Provide a reason/note for the cancellation.',
|
|
1393
|
+
method: 'POST',
|
|
1394
|
+
path: '/stages/{id}/cancel',
|
|
1395
|
+
pathParams: ['id'],
|
|
1396
|
+
queryParams: [],
|
|
1397
|
+
hasRequestBody: true,
|
|
1398
|
+
},
|
|
1399
|
+
{
|
|
1400
|
+
operationId: 'PublicJobStageController_reverse',
|
|
1401
|
+
resourcePath: ['stages', 'reverse'],
|
|
1402
|
+
actionName: 'reverse',
|
|
1403
|
+
displayName: 'Reverse stage status',
|
|
1404
|
+
description:
|
|
1405
|
+
'Reverse (reopen) a stage to a previous status. This is an admin action that bypasses normal transition rules and clears fields appropriate to the target status.',
|
|
1406
|
+
method: 'POST',
|
|
1407
|
+
path: '/stages/{id}/reverse',
|
|
1408
|
+
pathParams: ['id'],
|
|
1409
|
+
queryParams: [],
|
|
1410
|
+
hasRequestBody: true,
|
|
1411
|
+
},
|
|
1412
|
+
{
|
|
1413
|
+
operationId: 'PublicJobStageController_reissue',
|
|
1414
|
+
resourcePath: ['stages', 'reissue'],
|
|
1415
|
+
actionName: 'reissue',
|
|
1416
|
+
displayName: 'Reissue dispatch notifications',
|
|
1417
|
+
description: 'Resend dispatch notifications to all resources and contractor assigned to this stage.',
|
|
1418
|
+
method: 'POST',
|
|
1419
|
+
path: '/stages/{id}/reissue',
|
|
1420
|
+
pathParams: ['id'],
|
|
1421
|
+
queryParams: [],
|
|
1422
|
+
hasRequestBody: false,
|
|
1423
|
+
},
|
|
1424
|
+
{
|
|
1425
|
+
operationId: 'PublicJobStageResourceController_list',
|
|
1426
|
+
resourcePath: ['jobs', 'stages', 'resources'],
|
|
1427
|
+
actionName: 'list',
|
|
1428
|
+
paginatedItemsActionName: 'all',
|
|
1429
|
+
paginatedPagesActionName: 'pages',
|
|
1430
|
+
displayName: 'List stage resources',
|
|
1431
|
+
description: 'Get all assigned resources for a stage.',
|
|
1432
|
+
method: 'GET',
|
|
1433
|
+
path: '/jobs/{jobId}/stages/{stageId}/resources',
|
|
1434
|
+
pathParams: ['jobId', 'stageId'],
|
|
1435
|
+
queryParams: ['cursor', 'limit'],
|
|
1436
|
+
hasRequestBody: false,
|
|
1437
|
+
},
|
|
1438
|
+
{
|
|
1439
|
+
operationId: 'PublicJobStageResourceController_assign',
|
|
1440
|
+
resourcePath: ['jobs', 'stages', 'resources'],
|
|
1441
|
+
actionName: 'assign',
|
|
1442
|
+
displayName: 'Assign resource to stage',
|
|
1443
|
+
description: 'Assign a technician or contractor.',
|
|
1444
|
+
method: 'POST',
|
|
1445
|
+
path: '/jobs/{jobId}/stages/{stageId}/resources',
|
|
1446
|
+
pathParams: ['jobId', 'stageId'],
|
|
1447
|
+
queryParams: [],
|
|
1448
|
+
hasRequestBody: true,
|
|
1449
|
+
},
|
|
1450
|
+
{
|
|
1451
|
+
operationId: 'PublicJobStageResourceController_get',
|
|
1452
|
+
resourcePath: ['jobs', 'stages', 'resources'],
|
|
1453
|
+
actionName: 'get',
|
|
1454
|
+
displayName: 'Get stage resource',
|
|
1455
|
+
description: 'Get a specific resource assignment.',
|
|
1456
|
+
method: 'GET',
|
|
1457
|
+
path: '/jobs/{jobId}/stages/{stageId}/resources/{resourceId}',
|
|
1458
|
+
pathParams: ['jobId', 'stageId', 'resourceId'],
|
|
1459
|
+
queryParams: [],
|
|
1460
|
+
hasRequestBody: false,
|
|
1461
|
+
},
|
|
1462
|
+
{
|
|
1463
|
+
operationId: 'PublicJobStageResourceController_unassign',
|
|
1464
|
+
resourcePath: ['jobs', 'stages', 'resources'],
|
|
1465
|
+
actionName: 'unassign',
|
|
1466
|
+
displayName: 'Unassign resource from stage',
|
|
1467
|
+
description: 'Unassign resource from stage',
|
|
1468
|
+
method: 'DELETE',
|
|
1469
|
+
path: '/jobs/{jobId}/stages/{stageId}/resources/{resourceId}',
|
|
1470
|
+
pathParams: ['jobId', 'stageId', 'resourceId'],
|
|
1471
|
+
queryParams: [],
|
|
1472
|
+
hasRequestBody: false,
|
|
1473
|
+
},
|
|
1474
|
+
{
|
|
1475
|
+
operationId: 'PublicJobStageResourceController_reissue',
|
|
1476
|
+
resourcePath: ['jobs', 'stages', 'resources', 'reissue'],
|
|
1477
|
+
actionName: 'reissue',
|
|
1478
|
+
displayName: 'Reissue dispatch notification',
|
|
1479
|
+
description: 'Reissue dispatch notification',
|
|
1480
|
+
method: 'POST',
|
|
1481
|
+
path: '/jobs/{jobId}/stages/{stageId}/resources/{resourceId}/reissue',
|
|
1482
|
+
pathParams: ['jobId', 'stageId', 'resourceId'],
|
|
1483
|
+
queryParams: [],
|
|
1484
|
+
hasRequestBody: false,
|
|
1485
|
+
},
|
|
1486
|
+
{
|
|
1487
|
+
operationId: 'PublicJobStageResourceController_updateStatus',
|
|
1488
|
+
resourcePath: ['jobs', 'stages', 'resources', 'status'],
|
|
1489
|
+
actionName: 'updateStatus',
|
|
1490
|
+
displayName: 'Update resource status',
|
|
1491
|
+
description: 'Update status (enroute, onsite, checkedout, completed, onhold).',
|
|
1492
|
+
method: 'POST',
|
|
1493
|
+
path: '/jobs/{jobId}/stages/{stageId}/resources/{resourceId}/status',
|
|
1494
|
+
pathParams: ['jobId', 'stageId', 'resourceId'],
|
|
1495
|
+
queryParams: [],
|
|
1496
|
+
hasRequestBody: true,
|
|
1497
|
+
},
|
|
1498
|
+
{
|
|
1499
|
+
operationId: 'PublicApiEntityStatusController_list',
|
|
1500
|
+
resourcePath: ['settings', 'entityStatuses'],
|
|
1501
|
+
actionName: 'list',
|
|
1502
|
+
displayName: 'List entity statuses',
|
|
1503
|
+
description:
|
|
1504
|
+
'Retrieve all active statuses for a given entity type. Supported entities: customer, contractor, supplier',
|
|
1505
|
+
method: 'GET',
|
|
1506
|
+
path: '/settings/entity-statuses/{entity}',
|
|
1507
|
+
pathParams: ['entity'],
|
|
1508
|
+
queryParams: [],
|
|
1509
|
+
hasRequestBody: false,
|
|
1510
|
+
},
|
|
1511
|
+
{
|
|
1512
|
+
operationId: 'PublicApiJobStatusController_list',
|
|
1513
|
+
resourcePath: ['settings', 'jobStatuses'],
|
|
1514
|
+
actionName: 'list',
|
|
1515
|
+
displayName: 'List job statuses',
|
|
1516
|
+
description:
|
|
1517
|
+
'Retrieve all possible job statuses. These are system-defined status values that represent the aggregated state of a job based on its stages.',
|
|
1518
|
+
method: 'GET',
|
|
1519
|
+
path: '/settings/job-statuses',
|
|
1520
|
+
pathParams: [],
|
|
1521
|
+
queryParams: [],
|
|
1522
|
+
hasRequestBody: false,
|
|
1523
|
+
},
|
|
1524
|
+
{
|
|
1525
|
+
operationId: 'PublicApiJobTypeController_list',
|
|
1526
|
+
resourcePath: ['settings', 'jobTypes'],
|
|
1527
|
+
actionName: 'list',
|
|
1528
|
+
displayName: 'List job types',
|
|
1529
|
+
description:
|
|
1530
|
+
'Retrieve all active job types configured for the tenant. Job types categorize jobs by the type of work being performed (e.g., Maintenance, Installation, Repair).',
|
|
1531
|
+
method: 'GET',
|
|
1532
|
+
path: '/settings/job-types',
|
|
1533
|
+
pathParams: [],
|
|
1534
|
+
queryParams: [],
|
|
1535
|
+
hasRequestBody: false,
|
|
1536
|
+
},
|
|
1537
|
+
{
|
|
1538
|
+
operationId: 'PublicApiPriorityController_list',
|
|
1539
|
+
resourcePath: ['settings', 'priorities'],
|
|
1540
|
+
actionName: 'list',
|
|
1541
|
+
displayName: 'List priorities',
|
|
1542
|
+
description:
|
|
1543
|
+
'Retrieve all active priority levels configured for the tenant. Priorities indicate the urgency of jobs (e.g., Critical, High, Medium, Low).',
|
|
1544
|
+
method: 'GET',
|
|
1545
|
+
path: '/settings/priorities',
|
|
1546
|
+
pathParams: [],
|
|
1547
|
+
queryParams: [],
|
|
1548
|
+
hasRequestBody: false,
|
|
1549
|
+
},
|
|
1550
|
+
{
|
|
1551
|
+
operationId: 'PublicApiStageStatusController_list',
|
|
1552
|
+
resourcePath: ['settings', 'stageStatuses'],
|
|
1553
|
+
actionName: 'list',
|
|
1554
|
+
displayName: 'List stage statuses',
|
|
1555
|
+
description:
|
|
1556
|
+
'Retrieve all stage statuses configured for the tenant. Stage statuses represent the workflow states a stage (work order) can transition through (e.g., New, Dispatched, En Route, On Site, Completed, Finalised).',
|
|
1557
|
+
method: 'GET',
|
|
1558
|
+
path: '/settings/stage-statuses',
|
|
1559
|
+
pathParams: [],
|
|
1560
|
+
queryParams: [],
|
|
1561
|
+
hasRequestBody: false,
|
|
1562
|
+
},
|
|
1563
|
+
{
|
|
1564
|
+
operationId: 'PublicApiTagController_list',
|
|
1565
|
+
resourcePath: ['settings', 'tags'],
|
|
1566
|
+
actionName: 'list',
|
|
1567
|
+
displayName: 'List tags',
|
|
1568
|
+
description:
|
|
1569
|
+
'Retrieve all active tags (labels) configured. Use the optional `type` query parameter to filter by label type. Defaults to `job` if not specified. Supported types: job, scheduling, quote, customer, user, overheads, form, finance, system, work-order-system, account, contact, zone, work-categories, lead-source, lead, opportunity, opportunity-lost, project, project-type, payment-type, file, asset, item-location, task, phase, site, service-type, subscriptions, agreement, work, integration-types, flag-category.',
|
|
1570
|
+
method: 'GET',
|
|
1571
|
+
path: '/settings/tags',
|
|
1572
|
+
pathParams: [],
|
|
1573
|
+
queryParams: [],
|
|
1574
|
+
hasRequestBody: false,
|
|
1575
|
+
},
|
|
1576
|
+
{
|
|
1577
|
+
operationId: 'PublicApiZoneController_list',
|
|
1578
|
+
resourcePath: ['settings', 'zones'],
|
|
1579
|
+
actionName: 'list',
|
|
1580
|
+
displayName: 'List zones',
|
|
1581
|
+
description:
|
|
1582
|
+
'Retrieve all active zones configured for the tenant. Zones represent geographic regions used for job assignment, routing, and resource allocation.',
|
|
1583
|
+
method: 'GET',
|
|
1584
|
+
path: '/settings/zones',
|
|
1585
|
+
pathParams: [],
|
|
1586
|
+
queryParams: [],
|
|
1587
|
+
hasRequestBody: false,
|
|
1588
|
+
},
|
|
1589
|
+
{
|
|
1590
|
+
operationId: 'PublicApiWorkTypeController_list',
|
|
1591
|
+
resourcePath: ['settings', 'workTypes'],
|
|
1592
|
+
actionName: 'list',
|
|
1593
|
+
displayName: 'List work types',
|
|
1594
|
+
description:
|
|
1595
|
+
'Retrieve all active work types configured for the tenant (e.g., Labour, Travel, Administration) for time tracking and billing purposes.',
|
|
1596
|
+
method: 'GET',
|
|
1597
|
+
path: '/settings/work-types',
|
|
1598
|
+
pathParams: [],
|
|
1599
|
+
queryParams: [],
|
|
1600
|
+
hasRequestBody: false,
|
|
1601
|
+
},
|
|
1602
|
+
{
|
|
1603
|
+
operationId: 'PublicApiTemplateController_listEmailTemplates',
|
|
1604
|
+
resourcePath: ['settings', 'templates', 'email'],
|
|
1605
|
+
actionName: 'listEmailTemplates',
|
|
1606
|
+
displayName: 'List email templates for entity type',
|
|
1607
|
+
description: 'Retrieve all active email templates for the specified entity type (job or stage).',
|
|
1608
|
+
method: 'GET',
|
|
1609
|
+
path: '/settings/templates/{entity}/email',
|
|
1610
|
+
pathParams: ['entity'],
|
|
1611
|
+
queryParams: [],
|
|
1612
|
+
hasRequestBody: false,
|
|
1613
|
+
},
|
|
1614
|
+
{
|
|
1615
|
+
operationId: 'PublicApiTemplateController_listSmsTemplates',
|
|
1616
|
+
resourcePath: ['settings', 'templates', 'sms'],
|
|
1617
|
+
actionName: 'listSmsTemplates',
|
|
1618
|
+
displayName: 'List SMS templates for entity type',
|
|
1619
|
+
description: 'Retrieve all active SMS templates for the specified entity type (job or stage).',
|
|
1620
|
+
method: 'GET',
|
|
1621
|
+
path: '/settings/templates/{entity}/sms',
|
|
1622
|
+
pathParams: ['entity'],
|
|
1623
|
+
queryParams: [],
|
|
1624
|
+
hasRequestBody: false,
|
|
1625
|
+
},
|
|
1626
|
+
{
|
|
1627
|
+
operationId: 'PublicApiItemController_list',
|
|
1628
|
+
resourcePath: ['settings', 'items'],
|
|
1629
|
+
actionName: 'list',
|
|
1630
|
+
displayName: 'List items',
|
|
1631
|
+
description: 'Retrieve paginated editable settings items.',
|
|
1632
|
+
method: 'GET',
|
|
1633
|
+
path: '/settings/items',
|
|
1634
|
+
pathParams: [],
|
|
1635
|
+
queryParams: [],
|
|
1636
|
+
hasRequestBody: false,
|
|
1637
|
+
},
|
|
1638
|
+
{
|
|
1639
|
+
operationId: 'PublicApiItemController_create',
|
|
1640
|
+
resourcePath: ['settings', 'items'],
|
|
1641
|
+
actionName: 'create',
|
|
1642
|
+
displayName: 'Create item',
|
|
1643
|
+
description: 'Create a settings item. This endpoint does not upsert.',
|
|
1644
|
+
method: 'POST',
|
|
1645
|
+
path: '/settings/items',
|
|
1646
|
+
pathParams: [],
|
|
1647
|
+
queryParams: [],
|
|
1648
|
+
hasRequestBody: true,
|
|
1649
|
+
},
|
|
1650
|
+
{
|
|
1651
|
+
operationId: 'PublicApiItemController_getById',
|
|
1652
|
+
resourcePath: ['settings', 'items'],
|
|
1653
|
+
actionName: 'get',
|
|
1654
|
+
displayName: 'Get item',
|
|
1655
|
+
description: 'Retrieve a settings item by ID.',
|
|
1656
|
+
method: 'GET',
|
|
1657
|
+
path: '/settings/items/{id}',
|
|
1658
|
+
pathParams: ['id'],
|
|
1659
|
+
queryParams: [],
|
|
1660
|
+
hasRequestBody: false,
|
|
1661
|
+
},
|
|
1662
|
+
{
|
|
1663
|
+
operationId: 'PublicApiItemController_update',
|
|
1664
|
+
resourcePath: ['settings', 'items'],
|
|
1665
|
+
actionName: 'update',
|
|
1666
|
+
displayName: 'Update item',
|
|
1667
|
+
description: 'Update a settings item by ID.',
|
|
1668
|
+
method: 'PATCH',
|
|
1669
|
+
path: '/settings/items/{id}',
|
|
1670
|
+
pathParams: ['id'],
|
|
1671
|
+
queryParams: [],
|
|
1672
|
+
hasRequestBody: true,
|
|
1673
|
+
},
|
|
1674
|
+
{
|
|
1675
|
+
operationId: 'PublicApiItemController_delete',
|
|
1676
|
+
resourcePath: ['settings', 'items'],
|
|
1677
|
+
actionName: 'delete',
|
|
1678
|
+
displayName: 'Delete item',
|
|
1679
|
+
description: 'Deactivate a settings item by ID.',
|
|
1680
|
+
method: 'DELETE',
|
|
1681
|
+
path: '/settings/items/{id}',
|
|
1682
|
+
pathParams: ['id'],
|
|
1683
|
+
queryParams: [],
|
|
1684
|
+
hasRequestBody: false,
|
|
1685
|
+
},
|
|
1686
|
+
{
|
|
1687
|
+
operationId: 'PublicApiItemController_upsert',
|
|
1688
|
+
resourcePath: ['settings', 'items'],
|
|
1689
|
+
actionName: 'upsert',
|
|
1690
|
+
displayName: 'Upsert item',
|
|
1691
|
+
description: 'Create or update a settings item using integrationId or name as the match key.',
|
|
1692
|
+
method: 'POST',
|
|
1693
|
+
path: '/settings/items/upsert',
|
|
1694
|
+
pathParams: [],
|
|
1695
|
+
queryParams: [],
|
|
1696
|
+
hasRequestBody: true,
|
|
1697
|
+
},
|
|
1698
|
+
{
|
|
1699
|
+
operationId: 'PublicApiItemCategoryController_list',
|
|
1700
|
+
resourcePath: ['settings', 'itemCategories'],
|
|
1701
|
+
actionName: 'list',
|
|
1702
|
+
displayName: 'List item categories',
|
|
1703
|
+
description: 'Retrieve active item categories and sub-categories.',
|
|
1704
|
+
method: 'GET',
|
|
1705
|
+
path: '/settings/item-categories',
|
|
1706
|
+
pathParams: [],
|
|
1707
|
+
queryParams: [],
|
|
1708
|
+
hasRequestBody: false,
|
|
1709
|
+
},
|
|
1710
|
+
{
|
|
1711
|
+
operationId: 'PublicApiItemCategoryController_upsert',
|
|
1712
|
+
resourcePath: ['settings', 'itemCategories'],
|
|
1713
|
+
actionName: 'upsert',
|
|
1714
|
+
displayName: 'Upsert item category',
|
|
1715
|
+
description: 'Create a category/sub-category pair if it does not already exist.',
|
|
1716
|
+
method: 'POST',
|
|
1717
|
+
path: '/settings/item-categories/upsert',
|
|
1718
|
+
pathParams: [],
|
|
1719
|
+
queryParams: [],
|
|
1720
|
+
hasRequestBody: true,
|
|
1721
|
+
},
|
|
1722
|
+
{
|
|
1723
|
+
operationId: 'PublicApiUoMController_list',
|
|
1724
|
+
resourcePath: ['settings', 'uoms'],
|
|
1725
|
+
actionName: 'list',
|
|
1726
|
+
displayName: 'List UOMs',
|
|
1727
|
+
description: 'Retrieve active units of measure for item create/update.',
|
|
1728
|
+
method: 'GET',
|
|
1729
|
+
path: '/settings/uoms',
|
|
1730
|
+
pathParams: [],
|
|
1731
|
+
queryParams: [],
|
|
1732
|
+
hasRequestBody: false,
|
|
1733
|
+
},
|
|
1734
|
+
{
|
|
1735
|
+
operationId: 'PublicAttachmentController_createUploadSession',
|
|
1736
|
+
resourcePath: ['attachments'],
|
|
1737
|
+
actionName: 'createUploadSession',
|
|
1738
|
+
displayName: 'Create upload session',
|
|
1739
|
+
description:
|
|
1740
|
+
'Creates an upload session and returns a SAS URL for direct upload to Azure Blob Storage.\n\n**Upload Flow:**\n1. POST to this endpoint with file metadata\n2. Use the returned `uploadUrl` to PUT your file directly to blob storage\n3. Include the required headers from the response in your PUT request\n4. Store the `attachment.id` for later reference\n\n**Constraints:**\n- Maximum file size: 50MB\n- Allowed content types: application/msword, application/vnd.openxmlformats-officedocument.wordprocessingml.document, application/pdf, text/plain, application/vnd.ms-excel.sheet.macroEnabled.12...\n- Allowed extensions: .doc, .docx, .pdf, .txt, .xlsx, .xls, .xlsm, .csv, .json, .xml...\n- Upload URL expires in 20 minutes',
|
|
1741
|
+
method: 'POST',
|
|
1742
|
+
path: '/attachments',
|
|
1743
|
+
pathParams: [],
|
|
1744
|
+
queryParams: [],
|
|
1745
|
+
hasRequestBody: true,
|
|
1746
|
+
},
|
|
1747
|
+
{
|
|
1748
|
+
operationId: 'PublicAttachmentController_download',
|
|
1749
|
+
resourcePath: ['attachments'],
|
|
1750
|
+
actionName: 'download',
|
|
1751
|
+
displayName: 'Download attachment',
|
|
1752
|
+
description:
|
|
1753
|
+
'Downloads an attachment by redirecting to a time-limited SAS URL.\n\n**Response:**\n- 302 redirect to Azure Blob Storage with SAS token\n- Content-Disposition header set for proper filename\n\n**Note:** The SAS URL expires after 20 minutes. If expired, request a new download.',
|
|
1754
|
+
method: 'GET',
|
|
1755
|
+
path: '/attachments/{encodedId}',
|
|
1756
|
+
pathParams: ['encodedId'],
|
|
1757
|
+
queryParams: [],
|
|
1758
|
+
hasRequestBody: false,
|
|
1759
|
+
},
|
|
1760
|
+
{
|
|
1761
|
+
operationId: 'PublicJobActivitiesController_list',
|
|
1762
|
+
resourcePath: ['jobs', 'activities'],
|
|
1763
|
+
actionName: 'list',
|
|
1764
|
+
displayName: 'List activities (Jobs)',
|
|
1765
|
+
description: 'List activities (Jobs)',
|
|
1766
|
+
method: 'GET',
|
|
1767
|
+
path: '/jobs/{jobId}/activities',
|
|
1768
|
+
pathParams: ['jobId'],
|
|
1769
|
+
queryParams: [],
|
|
1770
|
+
hasRequestBody: false,
|
|
1771
|
+
},
|
|
1772
|
+
{
|
|
1773
|
+
operationId: 'PublicJobActivitiesController_getById',
|
|
1774
|
+
resourcePath: ['jobs', 'activities'],
|
|
1775
|
+
actionName: 'get',
|
|
1776
|
+
displayName: 'Get activity by ID (Jobs)',
|
|
1777
|
+
description: 'Get activity by ID (Jobs)',
|
|
1778
|
+
method: 'GET',
|
|
1779
|
+
path: '/jobs/{jobId}/activities/{id}',
|
|
1780
|
+
pathParams: ['jobId', 'id'],
|
|
1781
|
+
queryParams: [],
|
|
1782
|
+
hasRequestBody: false,
|
|
1783
|
+
},
|
|
1784
|
+
{
|
|
1785
|
+
operationId: 'PublicJobActivitiesController_delete',
|
|
1786
|
+
resourcePath: ['jobs', 'activities'],
|
|
1787
|
+
actionName: 'delete',
|
|
1788
|
+
displayName: 'Delete activity (Jobs)',
|
|
1789
|
+
description: 'Delete activity (Jobs)',
|
|
1790
|
+
method: 'DELETE',
|
|
1791
|
+
path: '/jobs/{jobId}/activities/{id}',
|
|
1792
|
+
pathParams: ['jobId', 'id'],
|
|
1793
|
+
queryParams: [],
|
|
1794
|
+
hasRequestBody: false,
|
|
1795
|
+
},
|
|
1796
|
+
{
|
|
1797
|
+
operationId: 'PublicJobActivitiesController_createNote',
|
|
1798
|
+
resourcePath: ['jobs', 'activities', 'note'],
|
|
1799
|
+
actionName: 'createNote',
|
|
1800
|
+
displayName: 'Create note activity (Jobs)',
|
|
1801
|
+
description: 'Create note activity (Jobs)',
|
|
1802
|
+
method: 'POST',
|
|
1803
|
+
path: '/jobs/{jobId}/activities/note',
|
|
1804
|
+
pathParams: ['jobId'],
|
|
1805
|
+
queryParams: [],
|
|
1806
|
+
hasRequestBody: true,
|
|
1807
|
+
},
|
|
1808
|
+
{
|
|
1809
|
+
operationId: 'PublicJobActivitiesController_createEmail',
|
|
1810
|
+
resourcePath: ['jobs', 'activities', 'email'],
|
|
1811
|
+
actionName: 'createEmail',
|
|
1812
|
+
displayName: 'Create email activity (Jobs)',
|
|
1813
|
+
description: 'Create email activity (Jobs)',
|
|
1814
|
+
method: 'POST',
|
|
1815
|
+
path: '/jobs/{jobId}/activities/email',
|
|
1816
|
+
pathParams: ['jobId'],
|
|
1817
|
+
queryParams: [],
|
|
1818
|
+
hasRequestBody: true,
|
|
1819
|
+
},
|
|
1820
|
+
{
|
|
1821
|
+
operationId: 'PublicJobActivitiesController_createSms',
|
|
1822
|
+
resourcePath: ['jobs', 'activities', 'sms'],
|
|
1823
|
+
actionName: 'createSms',
|
|
1824
|
+
displayName: 'Create SMS activity (Jobs)',
|
|
1825
|
+
description: 'Create SMS activity (Jobs)',
|
|
1826
|
+
method: 'POST',
|
|
1827
|
+
path: '/jobs/{jobId}/activities/sms',
|
|
1828
|
+
pathParams: ['jobId'],
|
|
1829
|
+
queryParams: [],
|
|
1830
|
+
hasRequestBody: true,
|
|
1831
|
+
},
|
|
1832
|
+
{
|
|
1833
|
+
operationId: 'PublicJobActivitiesController_createPhone',
|
|
1834
|
+
resourcePath: ['jobs', 'activities', 'phone'],
|
|
1835
|
+
actionName: 'createPhone',
|
|
1836
|
+
displayName: 'Create phone activity (Jobs)',
|
|
1837
|
+
description: 'Create phone activity (Jobs)',
|
|
1838
|
+
method: 'POST',
|
|
1839
|
+
path: '/jobs/{jobId}/activities/phone',
|
|
1840
|
+
pathParams: ['jobId'],
|
|
1841
|
+
queryParams: [],
|
|
1842
|
+
hasRequestBody: true,
|
|
1843
|
+
},
|
|
1844
|
+
{
|
|
1845
|
+
operationId: 'PublicJobActivitiesController_createIntegration',
|
|
1846
|
+
resourcePath: ['jobs', 'activities', 'integration'],
|
|
1847
|
+
actionName: 'createIntegration',
|
|
1848
|
+
displayName: 'Create integration activity (Jobs)',
|
|
1849
|
+
description: 'Create integration activity (Jobs)',
|
|
1850
|
+
method: 'POST',
|
|
1851
|
+
path: '/jobs/{jobId}/activities/integration',
|
|
1852
|
+
pathParams: ['jobId'],
|
|
1853
|
+
queryParams: [],
|
|
1854
|
+
hasRequestBody: true,
|
|
1855
|
+
},
|
|
1856
|
+
{
|
|
1857
|
+
operationId: 'PublicJobActivitiesController_createThread',
|
|
1858
|
+
resourcePath: ['jobs', 'activities', 'thread'],
|
|
1859
|
+
actionName: 'createThread',
|
|
1860
|
+
displayName: 'Create thread activity (Jobs)',
|
|
1861
|
+
description: 'Create thread activity (Jobs)',
|
|
1862
|
+
method: 'POST',
|
|
1863
|
+
path: '/jobs/{jobId}/activities/thread',
|
|
1864
|
+
pathParams: ['jobId'],
|
|
1865
|
+
queryParams: [],
|
|
1866
|
+
hasRequestBody: true,
|
|
1867
|
+
},
|
|
1868
|
+
{
|
|
1869
|
+
operationId: 'PublicStageActivitiesController_list',
|
|
1870
|
+
resourcePath: ['jobs', 'stages', 'activities'],
|
|
1871
|
+
actionName: 'list',
|
|
1872
|
+
displayName: 'List activities (Stages)',
|
|
1873
|
+
description: 'List activities (Stages)',
|
|
1874
|
+
method: 'GET',
|
|
1875
|
+
path: '/jobs/{jobId}/stages/{stageId}/activities',
|
|
1876
|
+
pathParams: ['stageId', 'jobId'],
|
|
1877
|
+
queryParams: [],
|
|
1878
|
+
hasRequestBody: false,
|
|
1879
|
+
},
|
|
1880
|
+
{
|
|
1881
|
+
operationId: 'PublicStageActivitiesController_getById',
|
|
1882
|
+
resourcePath: ['jobs', 'stages', 'activities'],
|
|
1883
|
+
actionName: 'get',
|
|
1884
|
+
displayName: 'Get activity by ID (Stages)',
|
|
1885
|
+
description: 'Get activity by ID (Stages)',
|
|
1886
|
+
method: 'GET',
|
|
1887
|
+
path: '/jobs/{jobId}/stages/{stageId}/activities/{id}',
|
|
1888
|
+
pathParams: ['stageId', 'id', 'jobId'],
|
|
1889
|
+
queryParams: [],
|
|
1890
|
+
hasRequestBody: false,
|
|
1891
|
+
},
|
|
1892
|
+
{
|
|
1893
|
+
operationId: 'PublicStageActivitiesController_delete',
|
|
1894
|
+
resourcePath: ['jobs', 'stages', 'activities'],
|
|
1895
|
+
actionName: 'delete',
|
|
1896
|
+
displayName: 'Delete activity (Stages)',
|
|
1897
|
+
description: 'Delete activity (Stages)',
|
|
1898
|
+
method: 'DELETE',
|
|
1899
|
+
path: '/jobs/{jobId}/stages/{stageId}/activities/{id}',
|
|
1900
|
+
pathParams: ['stageId', 'id', 'jobId'],
|
|
1901
|
+
queryParams: [],
|
|
1902
|
+
hasRequestBody: false,
|
|
1903
|
+
},
|
|
1904
|
+
{
|
|
1905
|
+
operationId: 'PublicStageActivitiesController_createNote',
|
|
1906
|
+
resourcePath: ['jobs', 'stages', 'activities', 'note'],
|
|
1907
|
+
actionName: 'createNote',
|
|
1908
|
+
displayName: 'Create note activity (Stages)',
|
|
1909
|
+
description: 'Create note activity (Stages)',
|
|
1910
|
+
method: 'POST',
|
|
1911
|
+
path: '/jobs/{jobId}/stages/{stageId}/activities/note',
|
|
1912
|
+
pathParams: ['stageId', 'jobId'],
|
|
1913
|
+
queryParams: [],
|
|
1914
|
+
hasRequestBody: true,
|
|
1915
|
+
},
|
|
1916
|
+
{
|
|
1917
|
+
operationId: 'PublicStageActivitiesController_createEmail',
|
|
1918
|
+
resourcePath: ['jobs', 'stages', 'activities', 'email'],
|
|
1919
|
+
actionName: 'createEmail',
|
|
1920
|
+
displayName: 'Create email activity (Stages)',
|
|
1921
|
+
description: 'Create email activity (Stages)',
|
|
1922
|
+
method: 'POST',
|
|
1923
|
+
path: '/jobs/{jobId}/stages/{stageId}/activities/email',
|
|
1924
|
+
pathParams: ['stageId', 'jobId'],
|
|
1925
|
+
queryParams: [],
|
|
1926
|
+
hasRequestBody: true,
|
|
1927
|
+
},
|
|
1928
|
+
{
|
|
1929
|
+
operationId: 'PublicStageActivitiesController_createSms',
|
|
1930
|
+
resourcePath: ['jobs', 'stages', 'activities', 'sms'],
|
|
1931
|
+
actionName: 'createSms',
|
|
1932
|
+
displayName: 'Create SMS activity (Stages)',
|
|
1933
|
+
description: 'Create SMS activity (Stages)',
|
|
1934
|
+
method: 'POST',
|
|
1935
|
+
path: '/jobs/{jobId}/stages/{stageId}/activities/sms',
|
|
1936
|
+
pathParams: ['stageId', 'jobId'],
|
|
1937
|
+
queryParams: [],
|
|
1938
|
+
hasRequestBody: true,
|
|
1939
|
+
},
|
|
1940
|
+
{
|
|
1941
|
+
operationId: 'PublicStageActivitiesController_createPhone',
|
|
1942
|
+
resourcePath: ['jobs', 'stages', 'activities', 'phone'],
|
|
1943
|
+
actionName: 'createPhone',
|
|
1944
|
+
displayName: 'Create phone activity (Stages)',
|
|
1945
|
+
description: 'Create phone activity (Stages)',
|
|
1946
|
+
method: 'POST',
|
|
1947
|
+
path: '/jobs/{jobId}/stages/{stageId}/activities/phone',
|
|
1948
|
+
pathParams: ['stageId', 'jobId'],
|
|
1949
|
+
queryParams: [],
|
|
1950
|
+
hasRequestBody: true,
|
|
1951
|
+
},
|
|
1952
|
+
{
|
|
1953
|
+
operationId: 'PublicStageActivitiesController_createIntegration',
|
|
1954
|
+
resourcePath: ['jobs', 'stages', 'activities', 'integration'],
|
|
1955
|
+
actionName: 'createIntegration',
|
|
1956
|
+
displayName: 'Create integration activity (Stages)',
|
|
1957
|
+
description: 'Create integration activity (Stages)',
|
|
1958
|
+
method: 'POST',
|
|
1959
|
+
path: '/jobs/{jobId}/stages/{stageId}/activities/integration',
|
|
1960
|
+
pathParams: ['stageId', 'jobId'],
|
|
1961
|
+
queryParams: [],
|
|
1962
|
+
hasRequestBody: true,
|
|
1963
|
+
},
|
|
1964
|
+
{
|
|
1965
|
+
operationId: 'PublicStageActivitiesController_createThread',
|
|
1966
|
+
resourcePath: ['jobs', 'stages', 'activities', 'thread'],
|
|
1967
|
+
actionName: 'createThread',
|
|
1968
|
+
displayName: 'Create thread activity (Stages)',
|
|
1969
|
+
description: 'Create thread activity (Stages)',
|
|
1970
|
+
method: 'POST',
|
|
1971
|
+
path: '/jobs/{jobId}/stages/{stageId}/activities/thread',
|
|
1972
|
+
pathParams: ['stageId', 'jobId'],
|
|
1973
|
+
queryParams: [],
|
|
1974
|
+
hasRequestBody: true,
|
|
1975
|
+
},
|
|
1976
|
+
{
|
|
1977
|
+
operationId: 'PublicJobFilesController_list',
|
|
1978
|
+
resourcePath: ['jobs', 'files'],
|
|
1979
|
+
actionName: 'list',
|
|
1980
|
+
displayName: 'List files (Jobs)',
|
|
1981
|
+
description: 'List files (Jobs)',
|
|
1982
|
+
method: 'GET',
|
|
1983
|
+
path: '/jobs/{jobId}/files',
|
|
1984
|
+
pathParams: ['jobId'],
|
|
1985
|
+
queryParams: [],
|
|
1986
|
+
hasRequestBody: false,
|
|
1987
|
+
},
|
|
1988
|
+
{
|
|
1989
|
+
operationId: 'PublicJobFilesController_create',
|
|
1990
|
+
resourcePath: ['jobs', 'files'],
|
|
1991
|
+
actionName: 'create',
|
|
1992
|
+
displayName: 'Create file (Jobs)',
|
|
1993
|
+
description: 'Create file (Jobs)',
|
|
1994
|
+
method: 'POST',
|
|
1995
|
+
path: '/jobs/{jobId}/files',
|
|
1996
|
+
pathParams: ['jobId'],
|
|
1997
|
+
queryParams: [],
|
|
1998
|
+
hasRequestBody: false,
|
|
1999
|
+
},
|
|
2000
|
+
{
|
|
2001
|
+
operationId: 'PublicJobFilesController_getById',
|
|
2002
|
+
resourcePath: ['jobs', 'files'],
|
|
2003
|
+
actionName: 'get',
|
|
2004
|
+
displayName: 'Get file by ID (Jobs)',
|
|
2005
|
+
description: 'Get file by ID (Jobs)',
|
|
2006
|
+
method: 'GET',
|
|
2007
|
+
path: '/jobs/{jobId}/files/{id}',
|
|
2008
|
+
pathParams: ['jobId', 'id'],
|
|
2009
|
+
queryParams: [],
|
|
2010
|
+
hasRequestBody: false,
|
|
2011
|
+
},
|
|
2012
|
+
{
|
|
2013
|
+
operationId: 'PublicJobFilesController_delete',
|
|
2014
|
+
resourcePath: ['jobs', 'files'],
|
|
2015
|
+
actionName: 'delete',
|
|
2016
|
+
displayName: 'Delete file (Jobs)',
|
|
2017
|
+
description: 'Delete file (Jobs)',
|
|
2018
|
+
method: 'DELETE',
|
|
2019
|
+
path: '/jobs/{jobId}/files/{id}',
|
|
2020
|
+
pathParams: ['jobId', 'id'],
|
|
2021
|
+
queryParams: [],
|
|
2022
|
+
hasRequestBody: false,
|
|
2023
|
+
},
|
|
2024
|
+
{
|
|
2025
|
+
operationId: 'PublicStageFilesController_list',
|
|
2026
|
+
resourcePath: ['jobs', 'stages', 'files'],
|
|
2027
|
+
actionName: 'list',
|
|
2028
|
+
displayName: 'List files (Stages)',
|
|
2029
|
+
description: 'List files (Stages)',
|
|
2030
|
+
method: 'GET',
|
|
2031
|
+
path: '/jobs/{jobId}/stages/{stageId}/files',
|
|
2032
|
+
pathParams: ['stageId', 'jobId'],
|
|
2033
|
+
queryParams: [],
|
|
2034
|
+
hasRequestBody: false,
|
|
2035
|
+
},
|
|
2036
|
+
{
|
|
2037
|
+
operationId: 'PublicStageFilesController_create',
|
|
2038
|
+
resourcePath: ['jobs', 'stages', 'files'],
|
|
2039
|
+
actionName: 'create',
|
|
2040
|
+
displayName: 'Create file (Stages)',
|
|
2041
|
+
description: 'Create file (Stages)',
|
|
2042
|
+
method: 'POST',
|
|
2043
|
+
path: '/jobs/{jobId}/stages/{stageId}/files',
|
|
2044
|
+
pathParams: ['stageId', 'jobId'],
|
|
2045
|
+
queryParams: [],
|
|
2046
|
+
hasRequestBody: false,
|
|
2047
|
+
},
|
|
2048
|
+
{
|
|
2049
|
+
operationId: 'PublicStageFilesController_getById',
|
|
2050
|
+
resourcePath: ['jobs', 'stages', 'files'],
|
|
2051
|
+
actionName: 'get',
|
|
2052
|
+
displayName: 'Get file by ID (Stages)',
|
|
2053
|
+
description: 'Get file by ID (Stages)',
|
|
2054
|
+
method: 'GET',
|
|
2055
|
+
path: '/jobs/{jobId}/stages/{stageId}/files/{id}',
|
|
2056
|
+
pathParams: ['stageId', 'id', 'jobId'],
|
|
2057
|
+
queryParams: [],
|
|
2058
|
+
hasRequestBody: false,
|
|
2059
|
+
},
|
|
2060
|
+
{
|
|
2061
|
+
operationId: 'PublicStageFilesController_delete',
|
|
2062
|
+
resourcePath: ['jobs', 'stages', 'files'],
|
|
2063
|
+
actionName: 'delete',
|
|
2064
|
+
displayName: 'Delete file (Stages)',
|
|
2065
|
+
description: 'Delete file (Stages)',
|
|
2066
|
+
method: 'DELETE',
|
|
2067
|
+
path: '/jobs/{jobId}/stages/{stageId}/files/{id}',
|
|
2068
|
+
pathParams: ['stageId', 'id', 'jobId'],
|
|
2069
|
+
queryParams: [],
|
|
2070
|
+
hasRequestBody: false,
|
|
2071
|
+
},
|
|
2072
|
+
{
|
|
2073
|
+
operationId: 'PublicJobTasksController_list',
|
|
2074
|
+
resourcePath: ['jobs', 'tasks'],
|
|
2075
|
+
actionName: 'list',
|
|
2076
|
+
displayName: 'List tasks (Jobs)',
|
|
2077
|
+
description: 'List tasks (Jobs)',
|
|
2078
|
+
method: 'GET',
|
|
2079
|
+
path: '/jobs/{jobId}/tasks',
|
|
2080
|
+
pathParams: ['jobId'],
|
|
2081
|
+
queryParams: [],
|
|
2082
|
+
hasRequestBody: false,
|
|
2083
|
+
},
|
|
2084
|
+
{
|
|
2085
|
+
operationId: 'PublicJobTasksController_create',
|
|
2086
|
+
resourcePath: ['jobs', 'tasks'],
|
|
2087
|
+
actionName: 'create',
|
|
2088
|
+
displayName: 'Create task (Jobs)',
|
|
2089
|
+
description: 'Create task (Jobs)',
|
|
2090
|
+
method: 'POST',
|
|
2091
|
+
path: '/jobs/{jobId}/tasks',
|
|
2092
|
+
pathParams: ['jobId'],
|
|
2093
|
+
queryParams: [],
|
|
2094
|
+
hasRequestBody: true,
|
|
2095
|
+
},
|
|
2096
|
+
{
|
|
2097
|
+
operationId: 'PublicJobTasksController_getById',
|
|
2098
|
+
resourcePath: ['jobs', 'tasks'],
|
|
2099
|
+
actionName: 'get',
|
|
2100
|
+
displayName: 'Get task by ID (Jobs)',
|
|
2101
|
+
description: 'Get task by ID (Jobs)',
|
|
2102
|
+
method: 'GET',
|
|
2103
|
+
path: '/jobs/{jobId}/tasks/{id}',
|
|
2104
|
+
pathParams: ['jobId', 'id'],
|
|
2105
|
+
queryParams: [],
|
|
2106
|
+
hasRequestBody: false,
|
|
2107
|
+
},
|
|
2108
|
+
{
|
|
2109
|
+
operationId: 'PublicJobTasksController_update',
|
|
2110
|
+
resourcePath: ['jobs', 'tasks'],
|
|
2111
|
+
actionName: 'update',
|
|
2112
|
+
displayName: 'Update task (Jobs)',
|
|
2113
|
+
description: 'Update task (Jobs)',
|
|
2114
|
+
method: 'PATCH',
|
|
2115
|
+
path: '/jobs/{jobId}/tasks/{id}',
|
|
2116
|
+
pathParams: ['jobId', 'id'],
|
|
2117
|
+
queryParams: [],
|
|
2118
|
+
hasRequestBody: true,
|
|
2119
|
+
},
|
|
2120
|
+
{
|
|
2121
|
+
operationId: 'PublicJobTasksController_delete',
|
|
2122
|
+
resourcePath: ['jobs', 'tasks'],
|
|
2123
|
+
actionName: 'delete',
|
|
2124
|
+
displayName: 'Delete task (Jobs)',
|
|
2125
|
+
description: 'Delete task (Jobs)',
|
|
2126
|
+
method: 'DELETE',
|
|
2127
|
+
path: '/jobs/{jobId}/tasks/{id}',
|
|
2128
|
+
pathParams: ['jobId', 'id'],
|
|
2129
|
+
queryParams: [],
|
|
2130
|
+
hasRequestBody: false,
|
|
2131
|
+
},
|
|
2132
|
+
{
|
|
2133
|
+
operationId: 'PublicJobTasksController_submitEvidence',
|
|
2134
|
+
resourcePath: ['jobs', 'tasks', 'evidence'],
|
|
2135
|
+
actionName: 'submitEvidence',
|
|
2136
|
+
displayName: 'Submit task evidence (Jobs)',
|
|
2137
|
+
description: 'Submit task evidence (Jobs)',
|
|
2138
|
+
method: 'POST',
|
|
2139
|
+
path: '/jobs/{jobId}/tasks/{id}/evidence',
|
|
2140
|
+
pathParams: ['jobId', 'id'],
|
|
2141
|
+
queryParams: [],
|
|
2142
|
+
hasRequestBody: true,
|
|
2143
|
+
},
|
|
2144
|
+
{
|
|
2145
|
+
operationId: 'PublicStageTasksController_list',
|
|
2146
|
+
resourcePath: ['jobs', 'stages', 'tasks'],
|
|
2147
|
+
actionName: 'list',
|
|
2148
|
+
displayName: 'List tasks (Stages)',
|
|
2149
|
+
description: 'List tasks (Stages)',
|
|
2150
|
+
method: 'GET',
|
|
2151
|
+
path: '/jobs/{jobId}/stages/{stageId}/tasks',
|
|
2152
|
+
pathParams: ['stageId', 'jobId'],
|
|
2153
|
+
queryParams: [],
|
|
2154
|
+
hasRequestBody: false,
|
|
2155
|
+
},
|
|
2156
|
+
{
|
|
2157
|
+
operationId: 'PublicStageTasksController_create',
|
|
2158
|
+
resourcePath: ['jobs', 'stages', 'tasks'],
|
|
2159
|
+
actionName: 'create',
|
|
2160
|
+
displayName: 'Create task (Stages)',
|
|
2161
|
+
description: 'Create task (Stages)',
|
|
2162
|
+
method: 'POST',
|
|
2163
|
+
path: '/jobs/{jobId}/stages/{stageId}/tasks',
|
|
2164
|
+
pathParams: ['stageId', 'jobId'],
|
|
2165
|
+
queryParams: [],
|
|
2166
|
+
hasRequestBody: true,
|
|
2167
|
+
},
|
|
2168
|
+
{
|
|
2169
|
+
operationId: 'PublicStageTasksController_getById',
|
|
2170
|
+
resourcePath: ['jobs', 'stages', 'tasks'],
|
|
2171
|
+
actionName: 'get',
|
|
2172
|
+
displayName: 'Get task by ID (Stages)',
|
|
2173
|
+
description: 'Get task by ID (Stages)',
|
|
2174
|
+
method: 'GET',
|
|
2175
|
+
path: '/jobs/{jobId}/stages/{stageId}/tasks/{id}',
|
|
2176
|
+
pathParams: ['stageId', 'id', 'jobId'],
|
|
2177
|
+
queryParams: [],
|
|
2178
|
+
hasRequestBody: false,
|
|
2179
|
+
},
|
|
2180
|
+
{
|
|
2181
|
+
operationId: 'PublicStageTasksController_update',
|
|
2182
|
+
resourcePath: ['jobs', 'stages', 'tasks'],
|
|
2183
|
+
actionName: 'update',
|
|
2184
|
+
displayName: 'Update task (Stages)',
|
|
2185
|
+
description: 'Update task (Stages)',
|
|
2186
|
+
method: 'PATCH',
|
|
2187
|
+
path: '/jobs/{jobId}/stages/{stageId}/tasks/{id}',
|
|
2188
|
+
pathParams: ['stageId', 'id', 'jobId'],
|
|
2189
|
+
queryParams: [],
|
|
2190
|
+
hasRequestBody: true,
|
|
2191
|
+
},
|
|
2192
|
+
{
|
|
2193
|
+
operationId: 'PublicStageTasksController_delete',
|
|
2194
|
+
resourcePath: ['jobs', 'stages', 'tasks'],
|
|
2195
|
+
actionName: 'delete',
|
|
2196
|
+
displayName: 'Delete task (Stages)',
|
|
2197
|
+
description: 'Delete task (Stages)',
|
|
2198
|
+
method: 'DELETE',
|
|
2199
|
+
path: '/jobs/{jobId}/stages/{stageId}/tasks/{id}',
|
|
2200
|
+
pathParams: ['stageId', 'id', 'jobId'],
|
|
2201
|
+
queryParams: [],
|
|
2202
|
+
hasRequestBody: false,
|
|
2203
|
+
},
|
|
2204
|
+
{
|
|
2205
|
+
operationId: 'PublicStageTasksController_submitEvidence',
|
|
2206
|
+
resourcePath: ['jobs', 'stages', 'tasks', 'evidence'],
|
|
2207
|
+
actionName: 'submitEvidence',
|
|
2208
|
+
displayName: 'Submit task evidence (Stages)',
|
|
2209
|
+
description: 'Submit task evidence (Stages)',
|
|
2210
|
+
method: 'POST',
|
|
2211
|
+
path: '/jobs/{jobId}/stages/{stageId}/tasks/{id}/evidence',
|
|
2212
|
+
pathParams: ['stageId', 'id', 'jobId'],
|
|
2213
|
+
queryParams: [],
|
|
2214
|
+
hasRequestBody: true,
|
|
2215
|
+
},
|
|
2216
|
+
{
|
|
2217
|
+
operationId: 'PublicJobContactsController_list',
|
|
2218
|
+
resourcePath: ['jobs', 'contacts'],
|
|
2219
|
+
actionName: 'list',
|
|
2220
|
+
displayName: 'List contact links',
|
|
2221
|
+
description: 'List contact links',
|
|
2222
|
+
method: 'GET',
|
|
2223
|
+
path: '/jobs/{jobId}/contacts',
|
|
2224
|
+
pathParams: ['jobId'],
|
|
2225
|
+
queryParams: [],
|
|
2226
|
+
hasRequestBody: false,
|
|
2227
|
+
},
|
|
2228
|
+
{
|
|
2229
|
+
operationId: 'PublicJobContactsController_create',
|
|
2230
|
+
resourcePath: ['jobs', 'contacts'],
|
|
2231
|
+
actionName: 'create',
|
|
2232
|
+
displayName: 'Create contact link',
|
|
2233
|
+
description: 'Create contact link',
|
|
2234
|
+
method: 'POST',
|
|
2235
|
+
path: '/jobs/{jobId}/contacts',
|
|
2236
|
+
pathParams: ['jobId'],
|
|
2237
|
+
queryParams: [],
|
|
2238
|
+
hasRequestBody: false,
|
|
2239
|
+
},
|
|
2240
|
+
{
|
|
2241
|
+
operationId: 'PublicJobContactsController_getById',
|
|
2242
|
+
resourcePath: ['jobs', 'contacts'],
|
|
2243
|
+
actionName: 'get',
|
|
2244
|
+
displayName: 'Get contact link by ID',
|
|
2245
|
+
description: 'Get contact link by ID',
|
|
2246
|
+
method: 'GET',
|
|
2247
|
+
path: '/jobs/{jobId}/contacts/{id}',
|
|
2248
|
+
pathParams: ['jobId', 'id'],
|
|
2249
|
+
queryParams: [],
|
|
2250
|
+
hasRequestBody: false,
|
|
2251
|
+
},
|
|
2252
|
+
{
|
|
2253
|
+
operationId: 'PublicJobContactsController_delete',
|
|
2254
|
+
resourcePath: ['jobs', 'contacts'],
|
|
2255
|
+
actionName: 'delete',
|
|
2256
|
+
displayName: 'Delete contact link',
|
|
2257
|
+
description: 'Delete contact link',
|
|
2258
|
+
method: 'DELETE',
|
|
2259
|
+
path: '/jobs/{jobId}/contacts/{id}',
|
|
2260
|
+
pathParams: ['jobId', 'id'],
|
|
2261
|
+
queryParams: [],
|
|
2262
|
+
hasRequestBody: false,
|
|
2263
|
+
},
|
|
2264
|
+
{
|
|
2265
|
+
operationId: 'PublicCrmCustomerController_list',
|
|
2266
|
+
resourcePath: ['crm', 'customers'],
|
|
2267
|
+
actionName: 'list',
|
|
2268
|
+
paginatedItemsActionName: 'all',
|
|
2269
|
+
paginatedPagesActionName: 'pages',
|
|
2270
|
+
displayName: 'List customers',
|
|
2271
|
+
description: 'List customers',
|
|
2272
|
+
method: 'GET',
|
|
2273
|
+
path: '/customers',
|
|
2274
|
+
pathParams: [],
|
|
2275
|
+
queryParams: ['status', 'cursor', 'limit'],
|
|
2276
|
+
hasRequestBody: false,
|
|
2277
|
+
},
|
|
2278
|
+
{
|
|
2279
|
+
operationId: 'PublicCrmCustomerController_create',
|
|
2280
|
+
resourcePath: ['crm', 'customers'],
|
|
2281
|
+
actionName: 'create',
|
|
2282
|
+
displayName: 'Create customer',
|
|
2283
|
+
description: 'Create customer',
|
|
2284
|
+
method: 'POST',
|
|
2285
|
+
path: '/customers',
|
|
2286
|
+
pathParams: [],
|
|
2287
|
+
queryParams: [],
|
|
2288
|
+
hasRequestBody: true,
|
|
2289
|
+
},
|
|
2290
|
+
{
|
|
2291
|
+
operationId: 'PublicCrmCustomerController_getById',
|
|
2292
|
+
resourcePath: ['crm', 'customers'],
|
|
2293
|
+
actionName: 'get',
|
|
2294
|
+
displayName: 'Get customer by ID',
|
|
2295
|
+
description: 'Get customer by ID',
|
|
2296
|
+
method: 'GET',
|
|
2297
|
+
path: '/customers/{id}',
|
|
2298
|
+
pathParams: ['id'],
|
|
2299
|
+
queryParams: [],
|
|
2300
|
+
hasRequestBody: false,
|
|
2301
|
+
},
|
|
2302
|
+
{
|
|
2303
|
+
operationId: 'PublicCrmCustomerController_update',
|
|
2304
|
+
resourcePath: ['crm', 'customers'],
|
|
2305
|
+
actionName: 'update',
|
|
2306
|
+
displayName: 'Update customer',
|
|
2307
|
+
description: 'Update customer',
|
|
2308
|
+
method: 'PATCH',
|
|
2309
|
+
path: '/customers/{id}',
|
|
2310
|
+
pathParams: ['id'],
|
|
2311
|
+
queryParams: [],
|
|
2312
|
+
hasRequestBody: true,
|
|
2313
|
+
},
|
|
2314
|
+
{
|
|
2315
|
+
operationId: 'PublicCrmCustomerController_listContacts',
|
|
2316
|
+
resourcePath: ['crm', 'customers', 'contacts'],
|
|
2317
|
+
actionName: 'list',
|
|
2318
|
+
paginatedItemsActionName: 'all',
|
|
2319
|
+
paginatedPagesActionName: 'pages',
|
|
2320
|
+
displayName: 'List contacts for customer',
|
|
2321
|
+
description: 'List contacts for customer',
|
|
2322
|
+
method: 'GET',
|
|
2323
|
+
path: '/customers/{customerId}/contacts',
|
|
2324
|
+
pathParams: ['customerId'],
|
|
2325
|
+
queryParams: ['cursor', 'limit'],
|
|
2326
|
+
hasRequestBody: false,
|
|
2327
|
+
},
|
|
2328
|
+
{
|
|
2329
|
+
operationId: 'PublicCrmCustomerController_listSites',
|
|
2330
|
+
resourcePath: ['crm', 'customers', 'sites'],
|
|
2331
|
+
actionName: 'list',
|
|
2332
|
+
paginatedItemsActionName: 'all',
|
|
2333
|
+
paginatedPagesActionName: 'pages',
|
|
2334
|
+
displayName: 'List sites for customer',
|
|
2335
|
+
description: 'List sites for customer',
|
|
2336
|
+
method: 'GET',
|
|
2337
|
+
path: '/customers/{customerId}/sites',
|
|
2338
|
+
pathParams: ['customerId'],
|
|
2339
|
+
queryParams: ['cursor', 'limit'],
|
|
2340
|
+
hasRequestBody: false,
|
|
2341
|
+
},
|
|
2342
|
+
{
|
|
2343
|
+
operationId: 'PublicCrmEmployeeController_list',
|
|
2344
|
+
resourcePath: ['crm', 'employees'],
|
|
2345
|
+
actionName: 'list',
|
|
2346
|
+
paginatedItemsActionName: 'all',
|
|
2347
|
+
paginatedPagesActionName: 'pages',
|
|
2348
|
+
displayName: 'List employees',
|
|
2349
|
+
description: 'List employees',
|
|
2350
|
+
method: 'GET',
|
|
2351
|
+
path: '/employees',
|
|
2352
|
+
pathParams: [],
|
|
2353
|
+
queryParams: ['cursor', 'limit'],
|
|
2354
|
+
hasRequestBody: false,
|
|
2355
|
+
},
|
|
2356
|
+
{
|
|
2357
|
+
operationId: 'PublicCrmEmployeeController_getById',
|
|
2358
|
+
resourcePath: ['crm', 'employees'],
|
|
2359
|
+
actionName: 'get',
|
|
2360
|
+
displayName: 'Get employee by ID',
|
|
2361
|
+
description: 'Get employee by ID',
|
|
2362
|
+
method: 'GET',
|
|
2363
|
+
path: '/employees/{id}',
|
|
2364
|
+
pathParams: ['id'],
|
|
2365
|
+
queryParams: [],
|
|
2366
|
+
hasRequestBody: false,
|
|
2367
|
+
},
|
|
2368
|
+
{
|
|
2369
|
+
operationId: 'PublicCrmContractorController_list',
|
|
2370
|
+
resourcePath: ['crm', 'contractors'],
|
|
2371
|
+
actionName: 'list',
|
|
2372
|
+
paginatedItemsActionName: 'all',
|
|
2373
|
+
paginatedPagesActionName: 'pages',
|
|
2374
|
+
displayName: 'List contractors',
|
|
2375
|
+
description: 'List contractors',
|
|
2376
|
+
method: 'GET',
|
|
2377
|
+
path: '/contractors',
|
|
2378
|
+
pathParams: [],
|
|
2379
|
+
queryParams: ['cursor', 'limit'],
|
|
2380
|
+
hasRequestBody: false,
|
|
2381
|
+
},
|
|
2382
|
+
{
|
|
2383
|
+
operationId: 'PublicCrmContractorController_create',
|
|
2384
|
+
resourcePath: ['crm', 'contractors'],
|
|
2385
|
+
actionName: 'create',
|
|
2386
|
+
displayName: 'Create contractor',
|
|
2387
|
+
description: 'Create contractor',
|
|
2388
|
+
method: 'POST',
|
|
2389
|
+
path: '/contractors',
|
|
2390
|
+
pathParams: [],
|
|
2391
|
+
queryParams: [],
|
|
2392
|
+
hasRequestBody: true,
|
|
2393
|
+
},
|
|
2394
|
+
{
|
|
2395
|
+
operationId: 'PublicCrmContractorController_getById',
|
|
2396
|
+
resourcePath: ['crm', 'contractors'],
|
|
2397
|
+
actionName: 'get',
|
|
2398
|
+
displayName: 'Get contractor by ID',
|
|
2399
|
+
description: 'Get contractor by ID',
|
|
2400
|
+
method: 'GET',
|
|
2401
|
+
path: '/contractors/{id}',
|
|
2402
|
+
pathParams: ['id'],
|
|
2403
|
+
queryParams: [],
|
|
2404
|
+
hasRequestBody: false,
|
|
2405
|
+
},
|
|
2406
|
+
{
|
|
2407
|
+
operationId: 'PublicCrmContractorController_update',
|
|
2408
|
+
resourcePath: ['crm', 'contractors'],
|
|
2409
|
+
actionName: 'update',
|
|
2410
|
+
displayName: 'Update contractor',
|
|
2411
|
+
description: 'Update contractor',
|
|
2412
|
+
method: 'PATCH',
|
|
2413
|
+
path: '/contractors/{id}',
|
|
2414
|
+
pathParams: ['id'],
|
|
2415
|
+
queryParams: [],
|
|
2416
|
+
hasRequestBody: true,
|
|
2417
|
+
},
|
|
2418
|
+
{
|
|
2419
|
+
operationId: 'PublicCrmSupplierController_list',
|
|
2420
|
+
resourcePath: ['crm', 'suppliers'],
|
|
2421
|
+
actionName: 'list',
|
|
2422
|
+
paginatedItemsActionName: 'all',
|
|
2423
|
+
paginatedPagesActionName: 'pages',
|
|
2424
|
+
displayName: 'List suppliers',
|
|
2425
|
+
description: 'List suppliers',
|
|
2426
|
+
method: 'GET',
|
|
2427
|
+
path: '/suppliers',
|
|
2428
|
+
pathParams: [],
|
|
2429
|
+
queryParams: ['cursor', 'limit'],
|
|
2430
|
+
hasRequestBody: false,
|
|
2431
|
+
},
|
|
2432
|
+
{
|
|
2433
|
+
operationId: 'PublicCrmSupplierController_create',
|
|
2434
|
+
resourcePath: ['crm', 'suppliers'],
|
|
2435
|
+
actionName: 'create',
|
|
2436
|
+
displayName: 'Create supplier',
|
|
2437
|
+
description: 'Create supplier',
|
|
2438
|
+
method: 'POST',
|
|
2439
|
+
path: '/suppliers',
|
|
2440
|
+
pathParams: [],
|
|
2441
|
+
queryParams: [],
|
|
2442
|
+
hasRequestBody: true,
|
|
2443
|
+
},
|
|
2444
|
+
{
|
|
2445
|
+
operationId: 'PublicCrmSupplierController_getById',
|
|
2446
|
+
resourcePath: ['crm', 'suppliers'],
|
|
2447
|
+
actionName: 'get',
|
|
2448
|
+
displayName: 'Get supplier by ID',
|
|
2449
|
+
description: 'Get supplier by ID',
|
|
2450
|
+
method: 'GET',
|
|
2451
|
+
path: '/suppliers/{id}',
|
|
2452
|
+
pathParams: ['id'],
|
|
2453
|
+
queryParams: [],
|
|
2454
|
+
hasRequestBody: false,
|
|
2455
|
+
},
|
|
2456
|
+
{
|
|
2457
|
+
operationId: 'PublicCrmSupplierController_update',
|
|
2458
|
+
resourcePath: ['crm', 'suppliers'],
|
|
2459
|
+
actionName: 'update',
|
|
2460
|
+
displayName: 'Update supplier',
|
|
2461
|
+
description: 'Update supplier',
|
|
2462
|
+
method: 'PATCH',
|
|
2463
|
+
path: '/suppliers/{id}',
|
|
2464
|
+
pathParams: ['id'],
|
|
2465
|
+
queryParams: [],
|
|
2466
|
+
hasRequestBody: true,
|
|
2467
|
+
},
|
|
2468
|
+
{
|
|
2469
|
+
operationId: 'PublicCrmCompanyController_list',
|
|
2470
|
+
resourcePath: ['crm', 'companies'],
|
|
2471
|
+
actionName: 'list',
|
|
2472
|
+
paginatedItemsActionName: 'all',
|
|
2473
|
+
paginatedPagesActionName: 'pages',
|
|
2474
|
+
displayName: 'List companies',
|
|
2475
|
+
description: 'List companies',
|
|
2476
|
+
method: 'GET',
|
|
2477
|
+
path: '/companies',
|
|
2478
|
+
pathParams: [],
|
|
2479
|
+
queryParams: ['cursor', 'limit'],
|
|
2480
|
+
hasRequestBody: false,
|
|
2481
|
+
},
|
|
2482
|
+
{
|
|
2483
|
+
operationId: 'PublicCrmCompanyController_getById',
|
|
2484
|
+
resourcePath: ['crm', 'companies'],
|
|
2485
|
+
actionName: 'get',
|
|
2486
|
+
displayName: 'Get company by ID',
|
|
2487
|
+
description: 'Get company by ID',
|
|
2488
|
+
method: 'GET',
|
|
2489
|
+
path: '/companies/{id}',
|
|
2490
|
+
pathParams: ['id'],
|
|
2491
|
+
queryParams: [],
|
|
2492
|
+
hasRequestBody: false,
|
|
2493
|
+
},
|
|
2494
|
+
{
|
|
2495
|
+
operationId: 'PublicCrmExternalUserController_list',
|
|
2496
|
+
resourcePath: ['crm', 'externalUsers'],
|
|
2497
|
+
actionName: 'list',
|
|
2498
|
+
paginatedItemsActionName: 'all',
|
|
2499
|
+
paginatedPagesActionName: 'pages',
|
|
2500
|
+
displayName: 'List external users',
|
|
2501
|
+
description: 'List external users',
|
|
2502
|
+
method: 'GET',
|
|
2503
|
+
path: '/external-users',
|
|
2504
|
+
pathParams: [],
|
|
2505
|
+
queryParams: ['cursor', 'limit'],
|
|
2506
|
+
hasRequestBody: false,
|
|
2507
|
+
},
|
|
2508
|
+
{
|
|
2509
|
+
operationId: 'PublicCrmExternalUserController_getById',
|
|
2510
|
+
resourcePath: ['crm', 'externalUsers'],
|
|
2511
|
+
actionName: 'get',
|
|
2512
|
+
displayName: 'Get external user by ID',
|
|
2513
|
+
description: 'Get external user by ID',
|
|
2514
|
+
method: 'GET',
|
|
2515
|
+
path: '/external-users/{id}',
|
|
2516
|
+
pathParams: ['id'],
|
|
2517
|
+
queryParams: [],
|
|
2518
|
+
hasRequestBody: false,
|
|
2519
|
+
},
|
|
2520
|
+
{
|
|
2521
|
+
operationId: 'PublicCrmContactController_list',
|
|
2522
|
+
resourcePath: ['crm', 'contacts'],
|
|
2523
|
+
actionName: 'list',
|
|
2524
|
+
paginatedItemsActionName: 'all',
|
|
2525
|
+
paginatedPagesActionName: 'pages',
|
|
2526
|
+
displayName: 'List contacts (Basic and Login contacts)',
|
|
2527
|
+
description: 'List contacts (Basic and Login contacts)',
|
|
2528
|
+
method: 'GET',
|
|
2529
|
+
path: '/contacts',
|
|
2530
|
+
pathParams: [],
|
|
2531
|
+
queryParams: ['cursor', 'limit'],
|
|
2532
|
+
hasRequestBody: false,
|
|
2533
|
+
},
|
|
2534
|
+
{
|
|
2535
|
+
operationId: 'PublicCrmContactController_getById',
|
|
2536
|
+
resourcePath: ['crm', 'contacts'],
|
|
2537
|
+
actionName: 'get',
|
|
2538
|
+
displayName: 'Get contact by ID',
|
|
2539
|
+
description: 'Get contact by ID',
|
|
2540
|
+
method: 'GET',
|
|
2541
|
+
path: '/contacts/{id}',
|
|
2542
|
+
pathParams: ['id'],
|
|
2543
|
+
queryParams: [],
|
|
2544
|
+
hasRequestBody: false,
|
|
2545
|
+
},
|
|
2546
|
+
{
|
|
2547
|
+
operationId: 'PublicCrmInviteController_list',
|
|
2548
|
+
resourcePath: ['crm', 'invites'],
|
|
2549
|
+
actionName: 'list',
|
|
2550
|
+
paginatedItemsActionName: 'all',
|
|
2551
|
+
paginatedPagesActionName: 'pages',
|
|
2552
|
+
displayName: 'List pending invites',
|
|
2553
|
+
description: 'List pending invites',
|
|
2554
|
+
method: 'GET',
|
|
2555
|
+
path: '/invites',
|
|
2556
|
+
pathParams: [],
|
|
2557
|
+
queryParams: ['cursor', 'limit'],
|
|
2558
|
+
hasRequestBody: false,
|
|
2559
|
+
},
|
|
2560
|
+
{
|
|
2561
|
+
operationId: 'PublicCrmInviteController_getById',
|
|
2562
|
+
resourcePath: ['crm', 'invites'],
|
|
2563
|
+
actionName: 'get',
|
|
2564
|
+
displayName: 'Get invite by ID',
|
|
2565
|
+
description: 'Get invite by ID',
|
|
2566
|
+
method: 'GET',
|
|
2567
|
+
path: '/invites/{id}',
|
|
2568
|
+
pathParams: ['id'],
|
|
2569
|
+
queryParams: [],
|
|
2570
|
+
hasRequestBody: false,
|
|
2571
|
+
},
|
|
2572
|
+
{
|
|
2573
|
+
operationId: 'PublicCrmSiteController_list',
|
|
2574
|
+
resourcePath: ['crm', 'sites'],
|
|
2575
|
+
actionName: 'list',
|
|
2576
|
+
paginatedItemsActionName: 'all',
|
|
2577
|
+
paginatedPagesActionName: 'pages',
|
|
2578
|
+
displayName: 'List all sites',
|
|
2579
|
+
description: 'List all sites',
|
|
2580
|
+
method: 'GET',
|
|
2581
|
+
path: '/sites',
|
|
2582
|
+
pathParams: [],
|
|
2583
|
+
queryParams: ['status', 'cursor', 'limit'],
|
|
2584
|
+
hasRequestBody: false,
|
|
2585
|
+
},
|
|
2586
|
+
{
|
|
2587
|
+
operationId: 'PublicCrmSiteController_getById',
|
|
2588
|
+
resourcePath: ['crm', 'sites'],
|
|
2589
|
+
actionName: 'get',
|
|
2590
|
+
displayName: 'Get site by ID',
|
|
2591
|
+
description: 'Get site by ID',
|
|
2592
|
+
method: 'GET',
|
|
2593
|
+
path: '/sites/{id}',
|
|
2594
|
+
pathParams: ['id'],
|
|
2595
|
+
queryParams: [],
|
|
2596
|
+
hasRequestBody: false,
|
|
2597
|
+
},
|
|
2598
|
+
{
|
|
2599
|
+
operationId: 'PublicApiWebhookV2Controller_listEntities',
|
|
2600
|
+
resourcePath: ['webhooks', 'entities'],
|
|
2601
|
+
actionName: 'list',
|
|
2602
|
+
displayName: 'List webhook-supported entity types and their available events',
|
|
2603
|
+
description: 'List webhook-supported entity types and their available events',
|
|
2604
|
+
method: 'GET',
|
|
2605
|
+
path: '/webhooks/entities',
|
|
2606
|
+
pathParams: [],
|
|
2607
|
+
queryParams: [],
|
|
2608
|
+
hasRequestBody: false,
|
|
2609
|
+
},
|
|
2610
|
+
{
|
|
2611
|
+
operationId: 'PublicApiWebhookV2Controller_listEntityEvents',
|
|
2612
|
+
resourcePath: ['webhooks', 'entities', 'events'],
|
|
2613
|
+
actionName: 'list',
|
|
2614
|
+
displayName: 'List the webhook events available for a given entity type',
|
|
2615
|
+
description: 'List the webhook events available for a given entity type',
|
|
2616
|
+
method: 'GET',
|
|
2617
|
+
path: '/webhooks/entities/{entity}/events',
|
|
2618
|
+
pathParams: ['entity'],
|
|
2619
|
+
queryParams: [],
|
|
2620
|
+
hasRequestBody: false,
|
|
2621
|
+
},
|
|
2622
|
+
{
|
|
2623
|
+
operationId: 'PublicApiWebhookV2Controller_listEntityFilters',
|
|
2624
|
+
resourcePath: ['webhooks', 'entities', 'filters'],
|
|
2625
|
+
actionName: 'list',
|
|
2626
|
+
displayName: 'List the filter fields available when subscribing to a given entity type',
|
|
2627
|
+
description: 'List the filter fields available when subscribing to a given entity type',
|
|
2628
|
+
method: 'GET',
|
|
2629
|
+
path: '/webhooks/entities/{entity}/filters',
|
|
2630
|
+
pathParams: ['entity'],
|
|
2631
|
+
queryParams: [],
|
|
2632
|
+
hasRequestBody: false,
|
|
2633
|
+
},
|
|
2634
|
+
{
|
|
2635
|
+
operationId: 'PublicApiWebhookV2Controller_list',
|
|
2636
|
+
resourcePath: ['webhooks'],
|
|
2637
|
+
actionName: 'list',
|
|
2638
|
+
displayName: 'List webhook subscriptions',
|
|
2639
|
+
description: 'List webhook subscriptions',
|
|
2640
|
+
method: 'GET',
|
|
2641
|
+
path: '/webhooks',
|
|
2642
|
+
pathParams: [],
|
|
2643
|
+
queryParams: [],
|
|
2644
|
+
hasRequestBody: false,
|
|
2645
|
+
},
|
|
2646
|
+
{
|
|
2647
|
+
operationId: 'PublicApiWebhookV2Controller_create',
|
|
2648
|
+
resourcePath: ['webhooks'],
|
|
2649
|
+
actionName: 'create',
|
|
2650
|
+
displayName: 'Create a webhook subscription',
|
|
2651
|
+
description: 'Create a webhook subscription',
|
|
2652
|
+
method: 'POST',
|
|
2653
|
+
path: '/webhooks',
|
|
2654
|
+
pathParams: [],
|
|
2655
|
+
queryParams: [],
|
|
2656
|
+
hasRequestBody: false,
|
|
2657
|
+
},
|
|
2658
|
+
{
|
|
2659
|
+
operationId: 'PublicApiWebhookV2Controller_get',
|
|
2660
|
+
resourcePath: ['webhooks'],
|
|
2661
|
+
actionName: 'get',
|
|
2662
|
+
displayName: 'Get a webhook subscription by ID',
|
|
2663
|
+
description: 'Get a webhook subscription by ID',
|
|
2664
|
+
method: 'GET',
|
|
2665
|
+
path: '/webhooks/{id}',
|
|
2666
|
+
pathParams: ['id'],
|
|
2667
|
+
queryParams: [],
|
|
2668
|
+
hasRequestBody: false,
|
|
2669
|
+
},
|
|
2670
|
+
{
|
|
2671
|
+
operationId: 'PublicApiWebhookV2Controller_update',
|
|
2672
|
+
resourcePath: ['webhooks'],
|
|
2673
|
+
actionName: 'update',
|
|
2674
|
+
displayName: 'Update a webhook subscription',
|
|
2675
|
+
description: 'Update a webhook subscription',
|
|
2676
|
+
method: 'PATCH',
|
|
2677
|
+
path: '/webhooks/{id}',
|
|
2678
|
+
pathParams: ['id'],
|
|
2679
|
+
queryParams: [],
|
|
2680
|
+
hasRequestBody: false,
|
|
2681
|
+
},
|
|
2682
|
+
{
|
|
2683
|
+
operationId: 'PublicApiWebhookV2Controller_delete',
|
|
2684
|
+
resourcePath: ['webhooks'],
|
|
2685
|
+
actionName: 'delete',
|
|
2686
|
+
displayName: 'Delete a webhook subscription',
|
|
2687
|
+
description: 'Delete a webhook subscription',
|
|
2688
|
+
method: 'DELETE',
|
|
2689
|
+
path: '/webhooks/{id}',
|
|
2690
|
+
pathParams: ['id'],
|
|
2691
|
+
queryParams: [],
|
|
2692
|
+
hasRequestBody: false,
|
|
2693
|
+
},
|
|
2694
|
+
{
|
|
2695
|
+
operationId: 'PublicApiWebhookV2Controller_regenerateSecret',
|
|
2696
|
+
resourcePath: ['webhooks', 'regenerateSecret'],
|
|
2697
|
+
actionName: 'regenerateSecret',
|
|
2698
|
+
displayName: 'Regenerate the signing secret for a webhook subscription',
|
|
2699
|
+
description: 'Regenerate the signing secret for a webhook subscription',
|
|
2700
|
+
method: 'POST',
|
|
2701
|
+
path: '/webhooks/{id}/regenerate-secret',
|
|
2702
|
+
pathParams: ['id'],
|
|
2703
|
+
queryParams: [],
|
|
2704
|
+
hasRequestBody: false,
|
|
2705
|
+
},
|
|
2706
|
+
{
|
|
2707
|
+
operationId: 'PublicApiWebhookV2Controller_test',
|
|
2708
|
+
resourcePath: ['webhooks', 'test'],
|
|
2709
|
+
actionName: 'test',
|
|
2710
|
+
displayName: 'Send a test event to a webhook subscription',
|
|
2711
|
+
description: 'Send a test event to a webhook subscription',
|
|
2712
|
+
method: 'POST',
|
|
2713
|
+
path: '/webhooks/{id}/test',
|
|
2714
|
+
pathParams: ['id'],
|
|
2715
|
+
queryParams: [],
|
|
2716
|
+
hasRequestBody: false,
|
|
2717
|
+
},
|
|
2718
|
+
{
|
|
2719
|
+
operationId: 'PublicApiWebhookV2Controller_listDeliveries',
|
|
2720
|
+
resourcePath: ['webhooks', 'deliveries'],
|
|
2721
|
+
actionName: 'list',
|
|
2722
|
+
displayName: 'List recent delivery attempts for a webhook subscription',
|
|
2723
|
+
description: 'List recent delivery attempts for a webhook subscription',
|
|
2724
|
+
method: 'GET',
|
|
2725
|
+
path: '/webhooks/{id}/deliveries',
|
|
2726
|
+
pathParams: ['id'],
|
|
2727
|
+
queryParams: [],
|
|
2728
|
+
hasRequestBody: false,
|
|
2729
|
+
},
|
|
2730
|
+
{
|
|
2731
|
+
operationId: 'PublicExportController_export',
|
|
2732
|
+
resourcePath: ['exports'],
|
|
2733
|
+
actionName: 'export',
|
|
2734
|
+
displayName: 'Export entity data',
|
|
2735
|
+
description:
|
|
2736
|
+
'Bulk export data from a MongoDB view. Returns raw view documents with pagination. Financial fields are stripped unless the token has the jobs:financial scope.',
|
|
2737
|
+
method: 'GET',
|
|
2738
|
+
path: '/exports/{entity}',
|
|
2739
|
+
pathParams: ['entity'],
|
|
2740
|
+
queryParams: ['lastModifiedOn', 'pageSize', 'page'],
|
|
2741
|
+
hasRequestBody: false,
|
|
2742
|
+
},
|
|
2743
|
+
{
|
|
2744
|
+
operationId: 'PublicApiAgentHarnessController_ingestEvent',
|
|
2745
|
+
resourcePath: ['agentHarness', 'runs', 'events'],
|
|
2746
|
+
actionName: 'ingestEvent',
|
|
2747
|
+
displayName: 'Write an agent run event',
|
|
2748
|
+
description:
|
|
2749
|
+
'Used by an external agent to report progress, action-required, completed, failed, heartbeat, or message events for an existing run.',
|
|
2750
|
+
method: 'POST',
|
|
2751
|
+
path: '/agent-harness/runs/{runId}/events',
|
|
2752
|
+
pathParams: ['runId'],
|
|
2753
|
+
queryParams: [],
|
|
2754
|
+
hasRequestBody: true,
|
|
2755
|
+
},
|
|
2756
|
+
{
|
|
2757
|
+
operationId: 'PublicApiAgentHarnessController_resolveAction',
|
|
2758
|
+
resourcePath: ['agentHarness', 'runs', 'actionResolved'],
|
|
2759
|
+
actionName: 'resolveAction',
|
|
2760
|
+
displayName: 'Resolve an action-required run state',
|
|
2761
|
+
description:
|
|
2762
|
+
'Used by an external agent to post the resolution payload for a run that previously entered action-required state.',
|
|
2763
|
+
method: 'POST',
|
|
2764
|
+
path: '/agent-harness/runs/{runId}/action-resolved',
|
|
2765
|
+
pathParams: ['runId'],
|
|
2766
|
+
queryParams: [],
|
|
2767
|
+
hasRequestBody: true,
|
|
2768
|
+
},
|
|
2769
|
+
{
|
|
2770
|
+
operationId: 'PublicApiFlagController_create',
|
|
2771
|
+
resourcePath: ['flags'],
|
|
2772
|
+
actionName: 'create',
|
|
2773
|
+
displayName: 'Create a flag on an entity',
|
|
2774
|
+
description: 'Create a flag on an entity',
|
|
2775
|
+
method: 'POST',
|
|
2776
|
+
path: '/flags',
|
|
2777
|
+
pathParams: [],
|
|
2778
|
+
queryParams: [],
|
|
2779
|
+
hasRequestBody: true,
|
|
2780
|
+
},
|
|
2781
|
+
{
|
|
2782
|
+
operationId: 'PublicApiFlagController_close',
|
|
2783
|
+
resourcePath: ['flags', 'close'],
|
|
2784
|
+
actionName: 'close',
|
|
2785
|
+
displayName: 'Close a flag',
|
|
2786
|
+
description: 'Close a flag',
|
|
2787
|
+
method: 'PATCH',
|
|
2788
|
+
path: '/flags/{id}/close',
|
|
2789
|
+
pathParams: ['id'],
|
|
2790
|
+
queryParams: [],
|
|
2791
|
+
hasRequestBody: true,
|
|
2792
|
+
},
|
|
2793
|
+
{
|
|
2794
|
+
operationId: 'PublicApiFlagController_listByEntity',
|
|
2795
|
+
resourcePath: ['flags', 'entity'],
|
|
2796
|
+
actionName: 'list',
|
|
2797
|
+
displayName: 'List flags for an entity',
|
|
2798
|
+
description: 'List flags for an entity',
|
|
2799
|
+
method: 'GET',
|
|
2800
|
+
path: '/flags/entity/{entity}/{entityId}',
|
|
2801
|
+
pathParams: ['entity', 'entityId'],
|
|
2802
|
+
queryParams: ['status'],
|
|
2803
|
+
hasRequestBody: false,
|
|
2804
|
+
},
|
|
2805
|
+
{
|
|
2806
|
+
operationId: 'McpV3StreamableController_handleGet',
|
|
2807
|
+
resourcePath: ['mcp'],
|
|
2808
|
+
actionName: 'list',
|
|
2809
|
+
displayName: 'MCP SSE stream (not supported)',
|
|
2810
|
+
description: 'Returns 405 — server-initiated SSE is not supported.',
|
|
2811
|
+
method: 'GET',
|
|
2812
|
+
path: '/mcp',
|
|
2813
|
+
pathParams: [],
|
|
2814
|
+
queryParams: [],
|
|
2815
|
+
hasRequestBody: false,
|
|
2816
|
+
},
|
|
2817
|
+
{
|
|
2818
|
+
operationId: 'McpV3StreamableController_handlePost',
|
|
2819
|
+
resourcePath: ['mcp'],
|
|
2820
|
+
actionName: 'create',
|
|
2821
|
+
displayName: 'MCP v3 Streamable HTTP endpoint',
|
|
2822
|
+
description: 'Handles MCP JSON-RPC 2.0 requests against the collapsed tool set.',
|
|
2823
|
+
method: 'POST',
|
|
2824
|
+
path: '/mcp',
|
|
2825
|
+
pathParams: [],
|
|
2826
|
+
queryParams: [],
|
|
2827
|
+
hasRequestBody: true,
|
|
2828
|
+
},
|
|
2829
|
+
{
|
|
2830
|
+
operationId: 'McpV3StreamableController_handleDelete',
|
|
2831
|
+
resourcePath: ['mcp'],
|
|
2832
|
+
actionName: 'delete',
|
|
2833
|
+
displayName: 'MCP session termination (not supported)',
|
|
2834
|
+
description: 'Returns 405 — stateless server, no sessions to terminate.',
|
|
2835
|
+
method: 'DELETE',
|
|
2836
|
+
path: '/mcp',
|
|
2837
|
+
pathParams: [],
|
|
2838
|
+
queryParams: [],
|
|
2839
|
+
hasRequestBody: false,
|
|
2840
|
+
},
|
|
2841
|
+
];
|
|
2842
|
+
export const operationMap = Object.fromEntries(operations.map((operation) => [operation.operationId, operation]));
|