@epilot/sdk 2.2.0 → 2.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (225) hide show
  1. package/definitions/access-token-runtime.json +1 -0
  2. package/definitions/access-token.json +663 -0
  3. package/definitions/address-runtime.json +1 -0
  4. package/definitions/address-suggestions-runtime.json +1 -0
  5. package/definitions/address-suggestions.json +582 -0
  6. package/definitions/address.json +578 -0
  7. package/definitions/ai-agents-runtime.json +1 -0
  8. package/definitions/ai-agents.json +1711 -0
  9. package/definitions/app-runtime.json +1 -0
  10. package/definitions/app.json +4493 -0
  11. package/definitions/audit-logs-runtime.json +1 -0
  12. package/definitions/audit-logs.json +305 -0
  13. package/definitions/automation-runtime.json +1 -0
  14. package/definitions/automation.json +4819 -0
  15. package/definitions/billing-runtime.json +1 -0
  16. package/definitions/billing.json +837 -0
  17. package/definitions/blueprint-manifest-runtime.json +1 -0
  18. package/definitions/blueprint-manifest.json +3490 -0
  19. package/definitions/consent-runtime.json +1 -0
  20. package/definitions/consent.json +344 -0
  21. package/definitions/customer-portal-runtime.json +1 -0
  22. package/definitions/customer-portal.json +15676 -0
  23. package/definitions/dashboard-runtime.json +1 -0
  24. package/definitions/dashboard.json +484 -0
  25. package/definitions/data-management-runtime.json +1 -0
  26. package/definitions/data-management.json +972 -0
  27. package/definitions/deduplication-runtime.json +1 -0
  28. package/definitions/deduplication.json +183 -0
  29. package/definitions/design-runtime.json +1 -0
  30. package/definitions/design.json +1423 -0
  31. package/definitions/document-runtime.json +1 -0
  32. package/definitions/document.json +758 -0
  33. package/definitions/email-settings-runtime.json +1 -0
  34. package/definitions/email-settings.json +2748 -0
  35. package/definitions/email-template-runtime.json +1 -0
  36. package/definitions/email-template.json +1441 -0
  37. package/definitions/entity-mapping-runtime.json +1 -0
  38. package/definitions/entity-mapping.json +1642 -0
  39. package/definitions/entity-runtime.json +1 -0
  40. package/definitions/entity.json +10404 -0
  41. package/definitions/environments-runtime.json +1 -0
  42. package/definitions/environments.json +363 -0
  43. package/definitions/erp-integration-runtime.json +1 -0
  44. package/definitions/erp-integration.json +6780 -0
  45. package/definitions/event-catalog-runtime.json +1 -0
  46. package/definitions/event-catalog.json +1051 -0
  47. package/definitions/file-runtime.json +1 -0
  48. package/definitions/file.json +2842 -0
  49. package/definitions/iban-runtime.json +1 -0
  50. package/definitions/iban.json +132 -0
  51. package/definitions/journey-runtime.json +1 -0
  52. package/definitions/journey.json +2603 -0
  53. package/definitions/kanban-runtime.json +1 -0
  54. package/definitions/kanban.json +1505 -0
  55. package/definitions/message-runtime.json +1 -0
  56. package/definitions/message.json +2660 -0
  57. package/definitions/metering-runtime.json +1 -0
  58. package/definitions/metering.json +2321 -0
  59. package/definitions/notes-runtime.json +1 -0
  60. package/definitions/notes.json +1531 -0
  61. package/definitions/notification-runtime.json +1 -0
  62. package/definitions/notification.json +1425 -0
  63. package/definitions/organization-runtime.json +1 -0
  64. package/definitions/organization.json +1192 -0
  65. package/definitions/partner-directory-runtime.json +1 -0
  66. package/definitions/partner-directory.json +2284 -0
  67. package/definitions/permissions-runtime.json +1 -0
  68. package/definitions/permissions.json +1515 -0
  69. package/definitions/pricing-runtime.json +1 -0
  70. package/definitions/pricing-tier-runtime.json +1 -0
  71. package/definitions/pricing-tier.json +105 -0
  72. package/definitions/pricing.json +9884 -0
  73. package/definitions/purpose-runtime.json +1 -0
  74. package/definitions/purpose.json +524 -0
  75. package/definitions/sandbox-runtime.json +1 -0
  76. package/definitions/sandbox.json +453 -0
  77. package/definitions/submission-runtime.json +1 -0
  78. package/definitions/submission.json +313 -0
  79. package/definitions/targeting-runtime.json +1 -0
  80. package/definitions/targeting.json +1474 -0
  81. package/definitions/template-variables-runtime.json +1 -0
  82. package/definitions/template-variables.json +1408 -0
  83. package/definitions/user-runtime.json +1 -0
  84. package/definitions/user.json +2408 -0
  85. package/definitions/validation-rules-runtime.json +1 -0
  86. package/definitions/validation-rules.json +1491 -0
  87. package/definitions/webhooks-runtime.json +1 -0
  88. package/definitions/webhooks.json +1634 -0
  89. package/definitions/workflow-definition-runtime.json +1 -0
  90. package/definitions/workflow-definition.json +3417 -0
  91. package/definitions/workflow-runtime.json +1 -0
  92. package/definitions/workflow.json +4146 -0
  93. package/dist/apis/access-token.cjs +6 -6
  94. package/dist/apis/access-token.js +1 -1
  95. package/dist/apis/address-suggestions.cjs +6 -6
  96. package/dist/apis/address-suggestions.js +1 -1
  97. package/dist/apis/address.cjs +6 -6
  98. package/dist/apis/address.js +1 -1
  99. package/dist/apis/ai-agents.cjs +6 -6
  100. package/dist/apis/ai-agents.js +1 -1
  101. package/dist/apis/app.cjs +6 -6
  102. package/dist/apis/app.js +1 -1
  103. package/dist/apis/audit-logs.cjs +6 -6
  104. package/dist/apis/audit-logs.js +1 -1
  105. package/dist/apis/automation.cjs +6 -6
  106. package/dist/apis/automation.d.cts +2 -2
  107. package/dist/apis/automation.d.ts +2 -2
  108. package/dist/apis/automation.js +1 -1
  109. package/dist/apis/billing.cjs +6 -6
  110. package/dist/apis/billing.js +1 -1
  111. package/dist/apis/blueprint-manifest.cjs +6 -6
  112. package/dist/apis/blueprint-manifest.js +1 -1
  113. package/dist/apis/consent.cjs +6 -6
  114. package/dist/apis/consent.js +1 -1
  115. package/dist/apis/customer-portal.cjs +6 -6
  116. package/dist/apis/customer-portal.js +1 -1
  117. package/dist/apis/dashboard.cjs +6 -6
  118. package/dist/apis/dashboard.js +1 -1
  119. package/dist/apis/data-management.cjs +6 -6
  120. package/dist/apis/data-management.js +1 -1
  121. package/dist/apis/deduplication.cjs +6 -6
  122. package/dist/apis/deduplication.js +1 -1
  123. package/dist/apis/design.cjs +6 -6
  124. package/dist/apis/design.js +1 -1
  125. package/dist/apis/document.cjs +6 -6
  126. package/dist/apis/document.js +1 -1
  127. package/dist/apis/email-settings.cjs +6 -6
  128. package/dist/apis/email-settings.js +1 -1
  129. package/dist/apis/email-template.cjs +6 -6
  130. package/dist/apis/email-template.js +1 -1
  131. package/dist/apis/entity-mapping.cjs +6 -6
  132. package/dist/apis/entity-mapping.js +1 -1
  133. package/dist/apis/entity.cjs +8 -8
  134. package/dist/apis/entity.d.cts +2 -2
  135. package/dist/apis/entity.d.ts +2 -2
  136. package/dist/apis/entity.js +2 -2
  137. package/dist/apis/environments.cjs +6 -6
  138. package/dist/apis/environments.js +1 -1
  139. package/dist/apis/erp-integration.cjs +8 -8
  140. package/dist/apis/erp-integration.d.cts +2 -2
  141. package/dist/apis/erp-integration.d.ts +2 -2
  142. package/dist/apis/erp-integration.js +2 -2
  143. package/dist/apis/event-catalog.cjs +6 -6
  144. package/dist/apis/event-catalog.js +1 -1
  145. package/dist/apis/file.cjs +6 -6
  146. package/dist/apis/file.js +1 -1
  147. package/dist/apis/iban.cjs +6 -6
  148. package/dist/apis/iban.js +1 -1
  149. package/dist/apis/journey.cjs +6 -6
  150. package/dist/apis/journey.js +1 -1
  151. package/dist/apis/kanban.cjs +6 -6
  152. package/dist/apis/kanban.js +1 -1
  153. package/dist/apis/message.cjs +6 -6
  154. package/dist/apis/message.js +1 -1
  155. package/dist/apis/metering.cjs +6 -6
  156. package/dist/apis/metering.js +1 -1
  157. package/dist/apis/notes.cjs +6 -6
  158. package/dist/apis/notes.js +1 -1
  159. package/dist/apis/notification.cjs +6 -6
  160. package/dist/apis/notification.js +1 -1
  161. package/dist/apis/organization.cjs +6 -6
  162. package/dist/apis/organization.js +1 -1
  163. package/dist/apis/partner-directory.cjs +6 -6
  164. package/dist/apis/partner-directory.js +1 -1
  165. package/dist/apis/permissions.cjs +6 -6
  166. package/dist/apis/permissions.js +1 -1
  167. package/dist/apis/pricing-tier.cjs +6 -6
  168. package/dist/apis/pricing-tier.js +1 -1
  169. package/dist/apis/pricing.cjs +6 -6
  170. package/dist/apis/pricing.js +1 -1
  171. package/dist/apis/purpose.cjs +6 -6
  172. package/dist/apis/purpose.js +1 -1
  173. package/dist/apis/sandbox.cjs +6 -6
  174. package/dist/apis/sandbox.js +1 -1
  175. package/dist/apis/submission.cjs +6 -6
  176. package/dist/apis/submission.js +1 -1
  177. package/dist/apis/targeting.cjs +6 -6
  178. package/dist/apis/targeting.js +1 -1
  179. package/dist/apis/template-variables.cjs +6 -6
  180. package/dist/apis/template-variables.js +1 -1
  181. package/dist/apis/user.cjs +6 -6
  182. package/dist/apis/user.js +1 -1
  183. package/dist/apis/validation-rules.cjs +6 -6
  184. package/dist/apis/validation-rules.js +1 -1
  185. package/dist/apis/webhooks.cjs +6 -6
  186. package/dist/apis/webhooks.js +1 -1
  187. package/dist/apis/workflow-definition.cjs +6 -6
  188. package/dist/apis/workflow-definition.js +1 -1
  189. package/dist/apis/workflow.cjs +6 -6
  190. package/dist/apis/workflow.js +1 -1
  191. package/dist/{automation.d-KOiZ6ru5.d.cts → automation.d-D7BzN7Gq.d.cts} +4 -0
  192. package/dist/{automation.d-KOiZ6ru5.d.ts → automation.d-D7BzN7Gq.d.ts} +4 -0
  193. package/dist/bin/cli.js +31 -1
  194. package/dist/{chunk-G33CBNJD.js → chunk-K7HKCNT2.js} +4 -4
  195. package/dist/{chunk-TPA4HEAO.js → chunk-LHVRAAFH.js} +1 -1
  196. package/dist/{chunk-IGVVJMX7.cjs → chunk-ODD4JQVS.cjs} +1 -1
  197. package/dist/chunk-RKSUIRD2.js +14 -0
  198. package/dist/{chunk-6TKKEGYU.cjs → chunk-TG2P4RWZ.cjs} +4 -4
  199. package/dist/chunk-XLQ4ZRBF.cjs +14 -0
  200. package/dist/entity-RCWJZZXM.cjs +7 -0
  201. package/dist/entity-X374X6EQ.js +7 -0
  202. package/dist/{entity-runtime-QSFVEFJ6.js → entity-runtime-CWQUEFCS.js} +1 -1
  203. package/dist/entity-runtime-EOWSEXC7.cjs +5 -0
  204. package/dist/{entity.d-DtiajmaY.d.cts → entity.d-t9R21446.d.cts} +140 -4
  205. package/dist/{entity.d-DtiajmaY.d.ts → entity.d-t9R21446.d.ts} +140 -4
  206. package/dist/erp-integration-6I4B4BIU.cjs +7 -0
  207. package/dist/erp-integration-G54BMGGE.js +7 -0
  208. package/dist/{erp-integration-runtime-FNJXDO75.js → erp-integration-runtime-6SBLYZ34.js} +1 -1
  209. package/dist/{erp-integration-runtime-WXZIQCLJ.cjs → erp-integration-runtime-HZI2P4X7.cjs} +2 -2
  210. package/dist/{erp-integration.d-DOhxy4P5.d.cts → erp-integration.d-BV3Rv9e6.d.cts} +479 -14
  211. package/dist/{erp-integration.d-DOhxy4P5.d.ts → erp-integration.d-BV3Rv9e6.d.ts} +479 -14
  212. package/dist/index.cjs +12 -12
  213. package/dist/index.d.cts +3 -3
  214. package/dist/index.d.ts +3 -3
  215. package/dist/index.js +3 -3
  216. package/docs/entity.md +337 -5
  217. package/docs/erp-integration.md +643 -16
  218. package/package.json +1 -1
  219. package/dist/chunk-24T6CJTG.js +0 -14
  220. package/dist/chunk-TTNPMFXL.cjs +0 -14
  221. package/dist/entity-FA6PZX6S.js +0 -7
  222. package/dist/entity-IX5NSHPX.cjs +0 -7
  223. package/dist/entity-runtime-XSAICIVR.cjs +0 -5
  224. package/dist/erp-integration-EP2XFEH5.js +0 -7
  225. package/dist/erp-integration-NNV72VFI.cjs +0 -7
@@ -0,0 +1,972 @@
1
+ {
2
+ "openapi": "3.0.3",
3
+ "info": {
4
+ "title": "Data Management API",
5
+ "version": "1.2.0"
6
+ },
7
+ "tags": [
8
+ {
9
+ "name": "Data Management",
10
+ "description": "Data Management endpoints"
11
+ }
12
+ ],
13
+ "security": [
14
+ {
15
+ "EpilotAuth": []
16
+ },
17
+ {
18
+ "EpilotOrg": []
19
+ }
20
+ ],
21
+ "paths": {
22
+ "/data-management/v1/{entity_schema}/query": {
23
+ "post": {
24
+ "operationId": "queryEntities",
25
+ "summary": "Query entities using a saved view with additional data filters",
26
+ "description": "Executes a query against the specified entity schema using the saved view definition, optionally combined with additional filters. Returns the entities matching the composed query.\n",
27
+ "tags": [
28
+ "Data Management"
29
+ ],
30
+ "parameters": [
31
+ {
32
+ "name": "entity_schema",
33
+ "in": "path",
34
+ "required": true,
35
+ "description": "Target entity schema to query (for example: \"contact\", \"opportunity\", \"order\").\n",
36
+ "schema": {
37
+ "type": "string"
38
+ }
39
+ }
40
+ ],
41
+ "requestBody": {
42
+ "required": true,
43
+ "content": {
44
+ "application/json": {
45
+ "schema": {
46
+ "$ref": "#/components/schemas/QueryEntitiesRequest"
47
+ }
48
+ }
49
+ }
50
+ },
51
+ "responses": {
52
+ "200": {
53
+ "description": "Query results",
54
+ "content": {
55
+ "application/json": {
56
+ "schema": {
57
+ "$ref": "#/components/schemas/QueryEntitiesResult"
58
+ }
59
+ }
60
+ }
61
+ }
62
+ }
63
+ }
64
+ },
65
+ "/data-management/v1/{entity_schema}/jobs": {
66
+ "post": {
67
+ "operationId": "createJob",
68
+ "summary": "Create a new job run",
69
+ "tags": [
70
+ "Data Management"
71
+ ],
72
+ "parameters": [
73
+ {
74
+ "name": "entity_schema",
75
+ "in": "path",
76
+ "required": true,
77
+ "schema": {
78
+ "type": "string"
79
+ }
80
+ }
81
+ ],
82
+ "requestBody": {
83
+ "required": true,
84
+ "content": {
85
+ "application/json": {
86
+ "schema": {
87
+ "$ref": "#/components/schemas/CreateJobRequest"
88
+ }
89
+ }
90
+ }
91
+ },
92
+ "responses": {
93
+ "201": {
94
+ "description": "Job created",
95
+ "content": {
96
+ "application/json": {
97
+ "schema": {
98
+ "$ref": "#/components/schemas/Job"
99
+ }
100
+ }
101
+ }
102
+ }
103
+ }
104
+ }
105
+ },
106
+ "/data-management/v1/{entity_schema}/jobs/{job_id}": {
107
+ "patch": {
108
+ "operationId": "updateJob",
109
+ "summary": "Update an existing job run",
110
+ "tags": [
111
+ "Data Management"
112
+ ],
113
+ "parameters": [
114
+ {
115
+ "name": "entity_schema",
116
+ "in": "path",
117
+ "required": true,
118
+ "schema": {
119
+ "type": "string"
120
+ }
121
+ },
122
+ {
123
+ "name": "job_id",
124
+ "in": "path",
125
+ "required": true,
126
+ "schema": {
127
+ "type": "string"
128
+ }
129
+ }
130
+ ],
131
+ "requestBody": {
132
+ "required": true,
133
+ "content": {
134
+ "application/json": {
135
+ "schema": {
136
+ "$ref": "#/components/schemas/UpdateJobRequest"
137
+ }
138
+ }
139
+ }
140
+ },
141
+ "responses": {
142
+ "200": {
143
+ "description": "Job updated",
144
+ "content": {
145
+ "application/json": {
146
+ "schema": {
147
+ "$ref": "#/components/schemas/Job"
148
+ }
149
+ }
150
+ }
151
+ },
152
+ "404": {
153
+ "description": "Job not found"
154
+ }
155
+ }
156
+ }
157
+ },
158
+ "/data-management/v1/jobs/{job_id}": {
159
+ "get": {
160
+ "operationId": "getJob",
161
+ "summary": "Get a job by id",
162
+ "description": "Returns details of a single job run.\n",
163
+ "tags": [
164
+ "Data Management"
165
+ ],
166
+ "parameters": [
167
+ {
168
+ "name": "job_id",
169
+ "in": "path",
170
+ "required": true,
171
+ "schema": {
172
+ "type": "string"
173
+ }
174
+ }
175
+ ],
176
+ "responses": {
177
+ "200": {
178
+ "description": "Job",
179
+ "content": {
180
+ "application/json": {
181
+ "schema": {
182
+ "$ref": "#/components/schemas/Job"
183
+ }
184
+ }
185
+ }
186
+ },
187
+ "404": {
188
+ "description": "Job not found"
189
+ }
190
+ }
191
+ }
192
+ },
193
+ "/data-management/v1/jobs/{job_id}/report-url": {
194
+ "get": {
195
+ "operationId": "getJobReportUrl",
196
+ "summary": "Get report download URL for a job",
197
+ "description": "Returns a short-lived, pre-signed URL to download the report file for the given job.\n",
198
+ "tags": [
199
+ "Data Management"
200
+ ],
201
+ "parameters": [
202
+ {
203
+ "name": "job_id",
204
+ "in": "path",
205
+ "required": true,
206
+ "schema": {
207
+ "type": "string"
208
+ }
209
+ }
210
+ ],
211
+ "responses": {
212
+ "200": {
213
+ "description": "Pre-signed report download URL",
214
+ "content": {
215
+ "application/json": {
216
+ "schema": {
217
+ "$ref": "#/components/schemas/JobReportUrlResponse"
218
+ }
219
+ }
220
+ }
221
+ },
222
+ "404": {
223
+ "description": "Job or report not found"
224
+ }
225
+ }
226
+ }
227
+ },
228
+ "/data-management/v1/configs/{config_id}": {
229
+ "get": {
230
+ "operationId": "getConfig",
231
+ "summary": "Get a config by id",
232
+ "description": "Returns a data management config by its id.\n",
233
+ "tags": [
234
+ "Data Management"
235
+ ],
236
+ "parameters": [
237
+ {
238
+ "name": "config_id",
239
+ "in": "path",
240
+ "required": true,
241
+ "schema": {
242
+ "type": "string"
243
+ }
244
+ }
245
+ ],
246
+ "responses": {
247
+ "200": {
248
+ "description": "Config",
249
+ "content": {
250
+ "application/json": {
251
+ "schema": {
252
+ "$ref": "#/components/schemas/Config"
253
+ }
254
+ }
255
+ }
256
+ },
257
+ "404": {
258
+ "description": "Config not found"
259
+ }
260
+ }
261
+ }
262
+ },
263
+ "/data-management/v1/configs/{config_id}/jobs": {
264
+ "post": {
265
+ "operationId": "createJobForConfig",
266
+ "summary": "Trigger a manual job run for a config",
267
+ "description": "Creates a job run for the given config and triggers asynchronous execution. Returns a job id which can be used to poll job status.\n",
268
+ "tags": [
269
+ "Data Management"
270
+ ],
271
+ "parameters": [
272
+ {
273
+ "name": "config_id",
274
+ "in": "path",
275
+ "required": true,
276
+ "schema": {
277
+ "type": "string"
278
+ }
279
+ }
280
+ ],
281
+ "responses": {
282
+ "201": {
283
+ "description": "Job created and queued",
284
+ "content": {
285
+ "application/json": {
286
+ "schema": {
287
+ "$ref": "#/components/schemas/Job"
288
+ }
289
+ }
290
+ }
291
+ },
292
+ "404": {
293
+ "description": "Config not found"
294
+ }
295
+ }
296
+ }
297
+ },
298
+ "/data-management/v1/{entity_schema}/configs": {
299
+ "post": {
300
+ "operationId": "upsertConfig",
301
+ "summary": "Upsert config",
302
+ "description": "Creates or updates a config for the given entity schema. The config is later used by a scheduled background process to periodically query and act on matching entities (for example, deletion).\n",
303
+ "tags": [
304
+ "Data Management"
305
+ ],
306
+ "parameters": [
307
+ {
308
+ "name": "entity_schema",
309
+ "in": "path",
310
+ "required": true,
311
+ "description": "Target entity schema for the config\n",
312
+ "schema": {
313
+ "type": "string"
314
+ }
315
+ }
316
+ ],
317
+ "requestBody": {
318
+ "required": true,
319
+ "content": {
320
+ "application/json": {
321
+ "schema": {
322
+ "$ref": "#/components/schemas/UpsertConfigRequest"
323
+ }
324
+ }
325
+ }
326
+ },
327
+ "responses": {
328
+ "200": {
329
+ "description": "Config updated",
330
+ "content": {
331
+ "application/json": {
332
+ "schema": {
333
+ "$ref": "#/components/schemas/Config"
334
+ }
335
+ }
336
+ }
337
+ },
338
+ "201": {
339
+ "description": "Config created",
340
+ "content": {
341
+ "application/json": {
342
+ "schema": {
343
+ "$ref": "#/components/schemas/Config"
344
+ }
345
+ }
346
+ }
347
+ }
348
+ }
349
+ }
350
+ },
351
+ "/data-management/v1/configs": {
352
+ "get": {
353
+ "operationId": "listConfigs",
354
+ "summary": "List configs",
355
+ "description": "Returns a paginated list of configs\n",
356
+ "tags": [
357
+ "Data Management"
358
+ ],
359
+ "parameters": [
360
+ {
361
+ "name": "limit",
362
+ "in": "query",
363
+ "required": false,
364
+ "schema": {
365
+ "type": "integer",
366
+ "default": 25
367
+ }
368
+ },
369
+ {
370
+ "name": "cursor",
371
+ "in": "query",
372
+ "required": false,
373
+ "schema": {
374
+ "type": "string"
375
+ }
376
+ },
377
+ {
378
+ "name": "entity_schema",
379
+ "in": "query",
380
+ "required": false,
381
+ "description": "Optional entity schema to filter configs.",
382
+ "schema": {
383
+ "type": "string"
384
+ }
385
+ },
386
+ {
387
+ "name": "type",
388
+ "in": "query",
389
+ "required": false,
390
+ "description": "Optional config type to filter configs.",
391
+ "schema": {
392
+ "$ref": "#/components/schemas/ConfigType"
393
+ }
394
+ },
395
+ {
396
+ "name": "next_run_at",
397
+ "in": "query",
398
+ "required": false,
399
+ "description": "Optional next run date (YYYY-MM-DD) to filter configs.",
400
+ "schema": {
401
+ "type": "string",
402
+ "format": "date"
403
+ }
404
+ },
405
+ {
406
+ "name": "enabled",
407
+ "in": "query",
408
+ "required": false,
409
+ "description": "Optional enabled status to filter configs.",
410
+ "schema": {
411
+ "type": "boolean"
412
+ }
413
+ }
414
+ ],
415
+ "responses": {
416
+ "200": {
417
+ "description": "List of configs",
418
+ "content": {
419
+ "application/json": {
420
+ "schema": {
421
+ "$ref": "#/components/schemas/ListConfigsResponse"
422
+ }
423
+ }
424
+ }
425
+ }
426
+ }
427
+ }
428
+ },
429
+ "/data-management/v1/jobs": {
430
+ "get": {
431
+ "operationId": "listJobs",
432
+ "summary": "List jobs",
433
+ "description": "Returns a paginated list of jobs\n",
434
+ "tags": [
435
+ "Data Management"
436
+ ],
437
+ "parameters": [
438
+ {
439
+ "name": "limit",
440
+ "in": "query",
441
+ "required": false,
442
+ "schema": {
443
+ "type": "integer",
444
+ "default": 25
445
+ }
446
+ },
447
+ {
448
+ "name": "cursor",
449
+ "in": "query",
450
+ "required": false,
451
+ "schema": {
452
+ "type": "string"
453
+ }
454
+ },
455
+ {
456
+ "name": "entity_schema",
457
+ "in": "query",
458
+ "required": false,
459
+ "description": "Optional entity schema to filter jobs.",
460
+ "schema": {
461
+ "type": "string"
462
+ }
463
+ },
464
+ {
465
+ "name": "type",
466
+ "in": "query",
467
+ "required": false,
468
+ "description": "Optional job type to filter jobs.",
469
+ "schema": {
470
+ "$ref": "#/components/schemas/ConfigType"
471
+ }
472
+ },
473
+ {
474
+ "name": "status",
475
+ "in": "query",
476
+ "required": false,
477
+ "description": "Optional job status to filter jobs.",
478
+ "schema": {
479
+ "$ref": "#/components/schemas/JobStatus"
480
+ }
481
+ },
482
+ {
483
+ "name": "config_id",
484
+ "in": "query",
485
+ "required": false,
486
+ "description": "Optional config id to filter jobs.",
487
+ "schema": {
488
+ "type": "string"
489
+ }
490
+ }
491
+ ],
492
+ "responses": {
493
+ "200": {
494
+ "description": "List of jobs",
495
+ "content": {
496
+ "application/json": {
497
+ "schema": {
498
+ "$ref": "#/components/schemas/ListJobsResponse"
499
+ }
500
+ }
501
+ }
502
+ }
503
+ }
504
+ }
505
+ }
506
+ },
507
+ "components": {
508
+ "securitySchemes": {
509
+ "EpilotAuth": {
510
+ "type": "http",
511
+ "scheme": "bearer",
512
+ "description": "Authorization header with epilot OAuth2 bearer token",
513
+ "bearerFormat": "JWT"
514
+ },
515
+ "EpilotOrg": {
516
+ "description": "Overrides the target organization to allow shared tenantaccess",
517
+ "name": "x-epilot-org-id",
518
+ "in": "header",
519
+ "type": "apiKey"
520
+ }
521
+ },
522
+ "schemas": {
523
+ "ConfigType": {
524
+ "type": "string",
525
+ "description": "Type of configuration (e.g. deletion)",
526
+ "enum": [
527
+ "deletion"
528
+ ]
529
+ },
530
+ "JobStatus": {
531
+ "type": "string",
532
+ "enum": [
533
+ "in_progress",
534
+ "success",
535
+ "failed"
536
+ ]
537
+ },
538
+ "JobTrigger": {
539
+ "type": "string",
540
+ "enum": [
541
+ "schedule",
542
+ "manual"
543
+ ]
544
+ },
545
+ "JobReportFormat": {
546
+ "type": "string",
547
+ "enum": [
548
+ "csv"
549
+ ]
550
+ },
551
+ "JobReport": {
552
+ "type": "object",
553
+ "additionalProperties": false,
554
+ "properties": {
555
+ "bucket": {
556
+ "type": "string"
557
+ },
558
+ "key": {
559
+ "type": "string"
560
+ },
561
+ "format": {
562
+ "$ref": "#/components/schemas/JobReportFormat"
563
+ }
564
+ }
565
+ },
566
+ "CreateJobRequest": {
567
+ "type": "object",
568
+ "additionalProperties": false,
569
+ "required": [
570
+ "type",
571
+ "config_id",
572
+ "scheduled_for"
573
+ ],
574
+ "properties": {
575
+ "type": {
576
+ "$ref": "#/components/schemas/ConfigType"
577
+ },
578
+ "config_id": {
579
+ "type": "string"
580
+ },
581
+ "scheduled_for": {
582
+ "type": "string",
583
+ "format": "date"
584
+ },
585
+ "status": {
586
+ "$ref": "#/components/schemas/JobStatus",
587
+ "default": "in_progress"
588
+ },
589
+ "started_at": {
590
+ "type": "string",
591
+ "format": "date-time"
592
+ }
593
+ }
594
+ },
595
+ "JobDetails": {
596
+ "type": "object",
597
+ "description": "Generic, type-specific job details payload (e.g. matched count, deleted count, failed count, etc.).",
598
+ "additionalProperties": true
599
+ },
600
+ "UpdateJobRequest": {
601
+ "type": "object",
602
+ "additionalProperties": false,
603
+ "properties": {
604
+ "status": {
605
+ "$ref": "#/components/schemas/JobStatus"
606
+ },
607
+ "details": {
608
+ "$ref": "#/components/schemas/JobDetails"
609
+ },
610
+ "completed_at": {
611
+ "type": "string",
612
+ "format": "date-time"
613
+ },
614
+ "error": {
615
+ "type": "string"
616
+ },
617
+ "report": {
618
+ "$ref": "#/components/schemas/JobReport"
619
+ }
620
+ }
621
+ },
622
+ "Job": {
623
+ "type": "object",
624
+ "additionalProperties": false,
625
+ "required": [
626
+ "id",
627
+ "type",
628
+ "config_id",
629
+ "entity_schema",
630
+ "scheduled_for",
631
+ "status",
632
+ "created_at",
633
+ "last_updated_at"
634
+ ],
635
+ "properties": {
636
+ "id": {
637
+ "type": "string"
638
+ },
639
+ "type": {
640
+ "$ref": "#/components/schemas/ConfigType"
641
+ },
642
+ "config_id": {
643
+ "type": "string"
644
+ },
645
+ "entity_schema": {
646
+ "type": "string"
647
+ },
648
+ "scheduled_for": {
649
+ "type": "string",
650
+ "format": "date"
651
+ },
652
+ "status": {
653
+ "$ref": "#/components/schemas/JobStatus"
654
+ },
655
+ "details": {
656
+ "$ref": "#/components/schemas/JobDetails"
657
+ },
658
+ "started_at": {
659
+ "type": "string",
660
+ "format": "date-time"
661
+ },
662
+ "completed_at": {
663
+ "type": "string",
664
+ "format": "date-time"
665
+ },
666
+ "error": {
667
+ "type": "string"
668
+ },
669
+ "report": {
670
+ "$ref": "#/components/schemas/JobReport"
671
+ },
672
+ "created_at": {
673
+ "type": "string",
674
+ "format": "date-time"
675
+ },
676
+ "last_updated_at": {
677
+ "type": "string",
678
+ "format": "date-time"
679
+ },
680
+ "trigger": {
681
+ "$ref": "#/components/schemas/JobTrigger"
682
+ },
683
+ "triggered_by": {
684
+ "type": "string",
685
+ "nullable": true
686
+ }
687
+ }
688
+ },
689
+ "ListJobsResponse": {
690
+ "type": "object",
691
+ "properties": {
692
+ "jobs": {
693
+ "type": "array",
694
+ "items": {
695
+ "$ref": "#/components/schemas/Job"
696
+ }
697
+ },
698
+ "cursor": {
699
+ "type": "string",
700
+ "nullable": true
701
+ }
702
+ }
703
+ },
704
+ "JobReportUrlResponse": {
705
+ "type": "object",
706
+ "properties": {
707
+ "url": {
708
+ "type": "string"
709
+ },
710
+ "expires_in": {
711
+ "type": "integer"
712
+ }
713
+ }
714
+ },
715
+ "QueryFilterType": {
716
+ "type": "string",
717
+ "enum": [
718
+ "entity_workflows_only_in_closed_or_cancelled_status",
719
+ "no_related_entities",
720
+ "related_entities_all_in_closed_or_cancelled_status",
721
+ "related_entities_workflows_only_in_closed_or_cancelled_status",
722
+ "no_email_communication_since"
723
+ ]
724
+ },
725
+ "QueryFilter": {
726
+ "type": "object",
727
+ "required": [
728
+ "type"
729
+ ],
730
+ "properties": {
731
+ "type": {
732
+ "$ref": "#/components/schemas/QueryFilterType"
733
+ },
734
+ "related_entity_schemas": {
735
+ "type": "array",
736
+ "items": {
737
+ "type": "string"
738
+ }
739
+ },
740
+ "lookback_period_days": {
741
+ "type": "integer"
742
+ },
743
+ "message_type": {
744
+ "type": "array",
745
+ "items": {
746
+ "type": "string",
747
+ "enum": [
748
+ "SENT",
749
+ "RECEIVED"
750
+ ]
751
+ }
752
+ }
753
+ }
754
+ },
755
+ "QueryConfig": {
756
+ "type": "object",
757
+ "required": [
758
+ "saved_view_id"
759
+ ],
760
+ "properties": {
761
+ "saved_view_id": {
762
+ "type": "string"
763
+ },
764
+ "include_deleted": {
765
+ "type": "string",
766
+ "enum": [
767
+ "true",
768
+ "false",
769
+ "only"
770
+ ]
771
+ },
772
+ "filters": {
773
+ "type": "array",
774
+ "items": {
775
+ "$ref": "#/components/schemas/QueryFilter"
776
+ }
777
+ }
778
+ }
779
+ },
780
+ "QueryEntitiesRequest": {
781
+ "allOf": [
782
+ {
783
+ "$ref": "#/components/schemas/QueryConfig"
784
+ },
785
+ {
786
+ "type": "object",
787
+ "properties": {
788
+ "from": {
789
+ "type": "integer"
790
+ },
791
+ "size": {
792
+ "type": "integer"
793
+ },
794
+ "hydrate": {
795
+ "type": "boolean"
796
+ },
797
+ "fields": {
798
+ "type": "array",
799
+ "items": {
800
+ "type": "string"
801
+ }
802
+ }
803
+ }
804
+ }
805
+ ]
806
+ },
807
+ "QueryEntitiesResult": {
808
+ "type": "object",
809
+ "properties": {
810
+ "hits": {
811
+ "type": "number"
812
+ },
813
+ "results": {
814
+ "type": "array",
815
+ "items": {
816
+ "type": "object",
817
+ "additionalProperties": true
818
+ }
819
+ }
820
+ }
821
+ },
822
+ "ConfigSchedule": {
823
+ "$ref": "#/components/schemas/IntervalConfigSchedule"
824
+ },
825
+ "IntervalConfigSchedule": {
826
+ "type": "object",
827
+ "required": [
828
+ "frequency",
829
+ "interval_days"
830
+ ],
831
+ "properties": {
832
+ "frequency": {
833
+ "type": "string",
834
+ "enum": [
835
+ "interval"
836
+ ]
837
+ },
838
+ "interval_days": {
839
+ "type": "integer",
840
+ "minimum": 1,
841
+ "description": "Interval in days between executions"
842
+ },
843
+ "start_date": {
844
+ "type": "string",
845
+ "format": "date"
846
+ },
847
+ "end_date": {
848
+ "type": "string",
849
+ "format": "date"
850
+ }
851
+ }
852
+ },
853
+ "UpsertConfigRequest": {
854
+ "type": "object",
855
+ "required": [
856
+ "type",
857
+ "query",
858
+ "schedule"
859
+ ],
860
+ "properties": {
861
+ "type": {
862
+ "$ref": "#/components/schemas/ConfigType"
863
+ },
864
+ "query": {
865
+ "$ref": "#/components/schemas/QueryConfig"
866
+ },
867
+ "schedule": {
868
+ "$ref": "#/components/schemas/ConfigSchedule"
869
+ },
870
+ "relations_for_deletion": {
871
+ "type": "array",
872
+ "items": {
873
+ "$ref": "#/components/schemas/DeletionRelationEntitySchema"
874
+ }
875
+ },
876
+ "enabled": {
877
+ "type": "boolean",
878
+ "default": true,
879
+ "description": "Whether this configuration is active"
880
+ }
881
+ }
882
+ },
883
+ "Config": {
884
+ "type": "object",
885
+ "required": [
886
+ "id",
887
+ "entity_schema",
888
+ "query",
889
+ "type"
890
+ ],
891
+ "properties": {
892
+ "id": {
893
+ "type": "string"
894
+ },
895
+ "type": {
896
+ "$ref": "#/components/schemas/ConfigType",
897
+ "description": "Type of configuration. Currently only 'deletion' is supported."
898
+ },
899
+ "entity_schema": {
900
+ "type": "string"
901
+ },
902
+ "query": {
903
+ "$ref": "#/components/schemas/QueryConfig"
904
+ },
905
+ "schedule": {
906
+ "$ref": "#/components/schemas/ConfigSchedule"
907
+ },
908
+ "enabled": {
909
+ "type": "boolean"
910
+ },
911
+ "created_at": {
912
+ "type": "string",
913
+ "format": "date-time"
914
+ },
915
+ "last_updated_at": {
916
+ "type": "string",
917
+ "format": "date-time"
918
+ },
919
+ "next_run_at": {
920
+ "type": "string",
921
+ "format": "date"
922
+ },
923
+ "relations_for_deletion": {
924
+ "type": "array",
925
+ "items": {
926
+ "$ref": "#/components/schemas/DeletionRelationEntitySchema"
927
+ }
928
+ },
929
+ "last_run_at": {
930
+ "type": "string",
931
+ "format": "date-time"
932
+ }
933
+ }
934
+ },
935
+ "DeletionRelationEntitySchema": {
936
+ "type": "string",
937
+ "enum": [
938
+ "contact",
939
+ "file",
940
+ "opportunity",
941
+ "order",
942
+ "meter",
943
+ "ticket",
944
+ "message",
945
+ "account",
946
+ "submission",
947
+ "contract"
948
+ ]
949
+ },
950
+ "ListConfigsResponse": {
951
+ "type": "object",
952
+ "properties": {
953
+ "configs": {
954
+ "type": "array",
955
+ "items": {
956
+ "$ref": "#/components/schemas/Config"
957
+ }
958
+ },
959
+ "cursor": {
960
+ "type": "string",
961
+ "nullable": true
962
+ }
963
+ }
964
+ }
965
+ }
966
+ },
967
+ "servers": [
968
+ {
969
+ "url": "https://data-management.sls.epilot.io"
970
+ }
971
+ ]
972
+ }