@epilot/sdk 2.7.10 → 2.7.12
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/LICENSE +21 -0
- package/definitions/event-catalog-runtime.json +1 -1
- package/definitions/event-catalog.json +168 -12
- package/definitions/webhooks.json +31 -0
- package/dist/apis/access-token.cjs +6 -6
- package/dist/apis/access-token.js +1 -1
- package/dist/apis/address-suggestions.cjs +6 -6
- package/dist/apis/address-suggestions.js +1 -1
- package/dist/apis/address.cjs +6 -6
- package/dist/apis/address.js +1 -1
- package/dist/apis/ai-agents.cjs +6 -6
- package/dist/apis/ai-agents.js +1 -1
- package/dist/apis/app.cjs +6 -6
- package/dist/apis/app.js +1 -1
- package/dist/apis/audit-logs.cjs +6 -6
- package/dist/apis/audit-logs.js +1 -1
- package/dist/apis/automation.cjs +6 -6
- package/dist/apis/automation.js +1 -1
- package/dist/apis/billing.cjs +6 -6
- package/dist/apis/billing.js +1 -1
- package/dist/apis/blueprint-manifest.cjs +6 -6
- package/dist/apis/blueprint-manifest.js +1 -1
- package/dist/apis/calendar.cjs +6 -6
- package/dist/apis/calendar.js +1 -1
- package/dist/apis/configuration-hub.cjs +6 -6
- package/dist/apis/configuration-hub.js +1 -1
- package/dist/apis/consent.cjs +6 -6
- package/dist/apis/consent.js +1 -1
- package/dist/apis/customer-portal.cjs +6 -6
- package/dist/apis/customer-portal.js +1 -1
- package/dist/apis/dashboard.cjs +6 -6
- package/dist/apis/dashboard.js +1 -1
- package/dist/apis/data-governance.cjs +6 -6
- package/dist/apis/data-governance.js +1 -1
- package/dist/apis/deduplication.cjs +6 -6
- package/dist/apis/deduplication.js +1 -1
- package/dist/apis/design.cjs +6 -6
- package/dist/apis/design.js +1 -1
- package/dist/apis/document.cjs +6 -6
- package/dist/apis/document.js +1 -1
- package/dist/apis/email-settings.cjs +6 -6
- package/dist/apis/email-settings.js +1 -1
- package/dist/apis/email-template.cjs +6 -6
- package/dist/apis/email-template.js +1 -1
- package/dist/apis/entity-mapping.cjs +6 -6
- package/dist/apis/entity-mapping.js +1 -1
- package/dist/apis/entity.cjs +6 -6
- package/dist/apis/entity.js +1 -1
- package/dist/apis/environments.cjs +6 -6
- package/dist/apis/environments.js +1 -1
- package/dist/apis/event-catalog.cjs +8 -8
- package/dist/apis/event-catalog.d.cts +2 -2
- package/dist/apis/event-catalog.d.ts +2 -2
- package/dist/apis/event-catalog.js +2 -2
- package/dist/apis/file.cjs +6 -6
- package/dist/apis/file.js +1 -1
- package/dist/apis/iban.cjs +6 -6
- package/dist/apis/iban.js +1 -1
- package/dist/apis/integration-toolkit.cjs +6 -6
- package/dist/apis/integration-toolkit.js +1 -1
- package/dist/apis/journey.cjs +6 -6
- package/dist/apis/journey.js +1 -1
- package/dist/apis/kanban.cjs +6 -6
- package/dist/apis/kanban.js +1 -1
- package/dist/apis/message.cjs +6 -6
- package/dist/apis/message.js +1 -1
- package/dist/apis/metering.cjs +6 -6
- package/dist/apis/metering.js +1 -1
- package/dist/apis/notes.cjs +6 -6
- package/dist/apis/notes.js +1 -1
- package/dist/apis/notification.cjs +6 -6
- package/dist/apis/notification.js +1 -1
- package/dist/apis/organization.cjs +6 -6
- package/dist/apis/organization.js +1 -1
- package/dist/apis/partner-directory.cjs +6 -6
- package/dist/apis/partner-directory.js +1 -1
- package/dist/apis/permissions.cjs +6 -6
- package/dist/apis/permissions.js +1 -1
- package/dist/apis/pricing-tier.cjs +6 -6
- package/dist/apis/pricing-tier.js +1 -1
- package/dist/apis/pricing.cjs +6 -6
- package/dist/apis/pricing.js +1 -1
- package/dist/apis/purpose.cjs +6 -6
- package/dist/apis/purpose.js +1 -1
- package/dist/apis/query.cjs +6 -6
- package/dist/apis/query.js +1 -1
- package/dist/apis/sandbox.cjs +6 -6
- package/dist/apis/sandbox.js +1 -1
- package/dist/apis/sharing.cjs +6 -6
- package/dist/apis/sharing.js +1 -1
- package/dist/apis/submission.cjs +6 -6
- package/dist/apis/submission.js +1 -1
- package/dist/apis/target.cjs +6 -6
- package/dist/apis/target.js +1 -1
- package/dist/apis/targeting.cjs +6 -6
- package/dist/apis/targeting.js +1 -1
- package/dist/apis/template-variables.cjs +6 -6
- package/dist/apis/template-variables.js +1 -1
- package/dist/apis/user.cjs +6 -6
- package/dist/apis/user.js +1 -1
- package/dist/apis/validation-rules.cjs +6 -6
- package/dist/apis/validation-rules.js +1 -1
- package/dist/apis/webhooks.cjs +6 -6
- package/dist/apis/webhooks.d.cts +2 -2
- package/dist/apis/webhooks.d.ts +2 -2
- package/dist/apis/webhooks.js +1 -1
- package/dist/apis/workflow-definition.cjs +6 -6
- package/dist/apis/workflow-definition.js +1 -1
- package/dist/apis/workflow.cjs +6 -6
- package/dist/apis/workflow.js +1 -1
- package/dist/{chunk-PFWNKA6K.js → chunk-5QPKSRW5.js} +3 -3
- package/dist/chunk-FDS727SL.cjs +14 -0
- package/dist/chunk-M4FO2MI4.js +14 -0
- package/dist/{chunk-YSMN2QWQ.cjs → chunk-SAMDHOZ5.cjs} +3 -3
- package/dist/event-catalog-3YOQ46ZW.js +7 -0
- package/dist/event-catalog-HLWUT7RM.cjs +7 -0
- package/dist/{event-catalog-runtime-N262TQ3Y.js → event-catalog-runtime-JUSLF3UR.js} +1 -1
- package/dist/{event-catalog-runtime-B2BPKQVG.cjs → event-catalog-runtime-RH7542GL.cjs} +2 -2
- package/dist/{event-catalog.d-mQJLSYUo.d.cts → event-catalog.d-CXbUn8T1.d.cts} +199 -36
- package/dist/{event-catalog.d-mQJLSYUo.d.ts → event-catalog.d-CXbUn8T1.d.ts} +199 -36
- package/dist/index.cjs +10 -10
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -2
- package/dist/js-yaml-DLCVPJ7G.js +0 -0
- package/dist/webhooks-6CUXSTPH.cjs +7 -0
- package/dist/webhooks-DTNKNJEN.js +7 -0
- package/dist/{webhooks.d-ByePoUWs.d.ts → webhooks.d-DKZOMj1P.d.cts} +37 -0
- package/dist/{webhooks.d-ByePoUWs.d.cts → webhooks.d-DKZOMj1P.d.ts} +37 -0
- package/docs/event-catalog.md +126 -13
- package/docs/webhooks.md +11 -2
- package/package.json +11 -12
- package/definitions/focus-pocus-runtime.json +0 -1
- package/definitions/focus-pocus.json +0 -757
- package/dist/chunk-CBDKPGO5.cjs +0 -14
- package/dist/chunk-OCMIXJWC.js +0 -14
- package/dist/event-catalog-37B6JC7G.js +0 -7
- package/dist/event-catalog-5JBHJJ2I.cjs +0 -7
- package/dist/webhooks-NZHJBT64.js +0 -7
- package/dist/webhooks-SK2STDKR.cjs +0 -7
|
@@ -132,7 +132,7 @@ declare namespace Components {
|
|
|
132
132
|
* "_event_time": "2024-01-01T12:00:00Z",
|
|
133
133
|
* "_event_id": "01FZ4Z5FZ5FZ5FZ5FZ5FZ5FZ5F",
|
|
134
134
|
* "_event_name": "MeterReading",
|
|
135
|
-
* "_event_version": "1.0
|
|
135
|
+
* "_event_version": "1.0",
|
|
136
136
|
* "_event_source": "api",
|
|
137
137
|
* "_trigger_source_type": "api",
|
|
138
138
|
* "_trigger_source": "user_123456",
|
|
@@ -170,9 +170,9 @@ declare namespace Components {
|
|
|
170
170
|
*/
|
|
171
171
|
_event_name: string;
|
|
172
172
|
/**
|
|
173
|
-
* Event version (
|
|
173
|
+
* Event payload version (MAJOR.MINOR)
|
|
174
174
|
* example:
|
|
175
|
-
* 1.0
|
|
175
|
+
* 1.0
|
|
176
176
|
*/
|
|
177
177
|
_event_version: string;
|
|
178
178
|
/**
|
|
@@ -268,9 +268,9 @@ declare namespace Components {
|
|
|
268
268
|
*/
|
|
269
269
|
event_description?: string;
|
|
270
270
|
/**
|
|
271
|
-
* Event version (
|
|
271
|
+
* Event payload version (MAJOR.MINOR)
|
|
272
272
|
* example:
|
|
273
|
-
* 1.0
|
|
273
|
+
* 1.0
|
|
274
274
|
*/
|
|
275
275
|
event_version: string;
|
|
276
276
|
/**
|
|
@@ -418,9 +418,9 @@ declare namespace Components {
|
|
|
418
418
|
*/
|
|
419
419
|
event_description?: string;
|
|
420
420
|
/**
|
|
421
|
-
* Event version (
|
|
421
|
+
* Event payload version (MAJOR.MINOR)
|
|
422
422
|
* example:
|
|
423
|
-
* 1.0
|
|
423
|
+
* 1.0
|
|
424
424
|
*/
|
|
425
425
|
event_version?: string;
|
|
426
426
|
/**
|
|
@@ -570,7 +570,7 @@ declare namespace Components {
|
|
|
570
570
|
* },
|
|
571
571
|
* "_event_version": {
|
|
572
572
|
* "type": "string",
|
|
573
|
-
* "description": "Event version (
|
|
573
|
+
* "description": "Event payload version (MAJOR.MINOR)"
|
|
574
574
|
* },
|
|
575
575
|
* "_event_source": {
|
|
576
576
|
* "type": "string",
|
|
@@ -690,9 +690,11 @@ declare namespace Components {
|
|
|
690
690
|
* A lightweight event summary returned by the v2 history endpoint.
|
|
691
691
|
*
|
|
692
692
|
* Includes the standard `_*` metadata fields plus a projected subset of the
|
|
693
|
-
* event payload. Hydrated entity objects (values carrying `_schema` or `_id`
|
|
694
|
-
* and arrays of such objects
|
|
695
|
-
* `
|
|
693
|
+
* event payload. Hydrated entity objects (values carrying `_schema` or `_id`)
|
|
694
|
+
* — and arrays of such objects — are reduced to reference stubs
|
|
695
|
+
* `{_schema, _id, _title}` so consumers can identify and follow up on each
|
|
696
|
+
* entity without paying the cost of the full hydrated graph. Fetch
|
|
697
|
+
* `GET /v2/events/{event_name}/history/{event_id}` for the full hydration.
|
|
696
698
|
*
|
|
697
699
|
* Projected scalar payload fields appear as additional top-level properties.
|
|
698
700
|
*
|
|
@@ -716,9 +718,9 @@ declare namespace Components {
|
|
|
716
718
|
*/
|
|
717
719
|
_event_name: string;
|
|
718
720
|
/**
|
|
719
|
-
* Event version (
|
|
721
|
+
* Event payload version (MAJOR.MINOR)
|
|
720
722
|
* example:
|
|
721
|
-
* 1.0
|
|
723
|
+
* 1.0
|
|
722
724
|
*/
|
|
723
725
|
_event_version: string;
|
|
724
726
|
/**
|
|
@@ -744,6 +746,56 @@ declare namespace Components {
|
|
|
744
746
|
*/
|
|
745
747
|
_ack_id?: string;
|
|
746
748
|
}
|
|
749
|
+
/**
|
|
750
|
+
* Summary of an event's version timeline returned by
|
|
751
|
+
* `GET /v1/events/{event_name}/versions`.
|
|
752
|
+
*
|
|
753
|
+
*/
|
|
754
|
+
export interface EventVersionRegistrySummary {
|
|
755
|
+
/**
|
|
756
|
+
* example:
|
|
757
|
+
* MeterReadingAdded
|
|
758
|
+
*/
|
|
759
|
+
event_name: string;
|
|
760
|
+
/**
|
|
761
|
+
* The newest registered version.
|
|
762
|
+
* example:
|
|
763
|
+
* 1.0
|
|
764
|
+
*/
|
|
765
|
+
latest: string;
|
|
766
|
+
/**
|
|
767
|
+
* Full version timeline, ordered oldest → newest.
|
|
768
|
+
*/
|
|
769
|
+
versions: /* One entry of an event's version timeline. */ VersionMeta[];
|
|
770
|
+
}
|
|
771
|
+
/**
|
|
772
|
+
* A field-level change descriptor. Powers the declarative half of the
|
|
773
|
+
* version DSL.
|
|
774
|
+
*
|
|
775
|
+
*/
|
|
776
|
+
export interface FieldChange {
|
|
777
|
+
/**
|
|
778
|
+
* Name of the field affected by this change.
|
|
779
|
+
* example:
|
|
780
|
+
* reading
|
|
781
|
+
*/
|
|
782
|
+
field: string;
|
|
783
|
+
/**
|
|
784
|
+
* Kind of change. Renames are NOT a first-class op — represent them
|
|
785
|
+
* as a `removed` + `added` pair (semantic intent goes into
|
|
786
|
+
* `change_summary` / `change_notes`).
|
|
787
|
+
*
|
|
788
|
+
*/
|
|
789
|
+
op: "added" | "removed" | "type-changed";
|
|
790
|
+
/**
|
|
791
|
+
* Type label for the previous shape (for `removed` and `type-changed`).
|
|
792
|
+
*/
|
|
793
|
+
type_old?: string;
|
|
794
|
+
/**
|
|
795
|
+
* Type label for the new shape (for `added` and `type-changed`).
|
|
796
|
+
*/
|
|
797
|
+
type_new?: string;
|
|
798
|
+
}
|
|
747
799
|
/**
|
|
748
800
|
* List of entity fields to include or exclude in the response
|
|
749
801
|
*
|
|
@@ -1093,9 +1145,9 @@ declare namespace Components {
|
|
|
1093
1145
|
*/
|
|
1094
1146
|
event_description?: string;
|
|
1095
1147
|
/**
|
|
1096
|
-
* Event version (
|
|
1148
|
+
* Event payload version (MAJOR.MINOR)
|
|
1097
1149
|
* example:
|
|
1098
|
-
* 1.0
|
|
1150
|
+
* 1.0
|
|
1099
1151
|
*/
|
|
1100
1152
|
event_version?: string;
|
|
1101
1153
|
/**
|
|
@@ -1220,6 +1272,40 @@ declare namespace Components {
|
|
|
1220
1272
|
*/
|
|
1221
1273
|
automation_trigger?: boolean;
|
|
1222
1274
|
}
|
|
1275
|
+
/**
|
|
1276
|
+
* One entry of an event's version timeline.
|
|
1277
|
+
*/
|
|
1278
|
+
export interface VersionMeta {
|
|
1279
|
+
/**
|
|
1280
|
+
* MAJOR.MINOR version label.
|
|
1281
|
+
* example:
|
|
1282
|
+
* 1.0
|
|
1283
|
+
*/
|
|
1284
|
+
version: string;
|
|
1285
|
+
/**
|
|
1286
|
+
* ISO 8601 release timestamp.
|
|
1287
|
+
* example:
|
|
1288
|
+
* 2025-11-15
|
|
1289
|
+
*/
|
|
1290
|
+
released_at: string;
|
|
1291
|
+
/**
|
|
1292
|
+
* Required one-liner describing what changed in this version (≤280 chars).
|
|
1293
|
+
*/
|
|
1294
|
+
change_summary: string;
|
|
1295
|
+
/**
|
|
1296
|
+
* Optional longer-form prose (markdown).
|
|
1297
|
+
*/
|
|
1298
|
+
change_notes?: string;
|
|
1299
|
+
/**
|
|
1300
|
+
* Hand-authored list of field-level changes from the previous version. Empty for v1.
|
|
1301
|
+
*/
|
|
1302
|
+
changes: /**
|
|
1303
|
+
* A field-level change descriptor. Powers the declarative half of the
|
|
1304
|
+
* version DSL.
|
|
1305
|
+
*
|
|
1306
|
+
*/
|
|
1307
|
+
FieldChange[];
|
|
1308
|
+
}
|
|
1223
1309
|
}
|
|
1224
1310
|
}
|
|
1225
1311
|
declare namespace Paths {
|
|
@@ -1235,7 +1321,11 @@ declare namespace Paths {
|
|
|
1235
1321
|
}
|
|
1236
1322
|
}
|
|
1237
1323
|
namespace GetEventExample {
|
|
1324
|
+
export interface HeaderParameters {
|
|
1325
|
+
"Epilot-Event-Version"?: Parameters.EpilotEventVersion;
|
|
1326
|
+
}
|
|
1238
1327
|
namespace Parameters {
|
|
1328
|
+
export type EpilotEventVersion = string;
|
|
1239
1329
|
export type EventName = string;
|
|
1240
1330
|
}
|
|
1241
1331
|
export interface PathParameters {
|
|
@@ -1247,10 +1337,16 @@ declare namespace Paths {
|
|
|
1247
1337
|
*/
|
|
1248
1338
|
export interface $200 {
|
|
1249
1339
|
}
|
|
1340
|
+
export interface $404 {
|
|
1341
|
+
}
|
|
1250
1342
|
}
|
|
1251
1343
|
}
|
|
1252
1344
|
namespace GetEventJSONSchema {
|
|
1345
|
+
export interface HeaderParameters {
|
|
1346
|
+
"Epilot-Event-Version"?: Parameters.EpilotEventVersion;
|
|
1347
|
+
}
|
|
1253
1348
|
namespace Parameters {
|
|
1349
|
+
export type EpilotEventVersion = string;
|
|
1254
1350
|
export type EventName = string;
|
|
1255
1351
|
}
|
|
1256
1352
|
export interface PathParameters {
|
|
@@ -1282,7 +1378,7 @@ declare namespace Paths {
|
|
|
1282
1378
|
* },
|
|
1283
1379
|
* "_event_version": {
|
|
1284
1380
|
* "type": "string",
|
|
1285
|
-
* "description": "Event version (
|
|
1381
|
+
* "description": "Event payload version (MAJOR.MINOR)"
|
|
1286
1382
|
* },
|
|
1287
1383
|
* "_event_source": {
|
|
1288
1384
|
* "type": "string",
|
|
@@ -1397,6 +1493,8 @@ declare namespace Paths {
|
|
|
1397
1493
|
* }
|
|
1398
1494
|
*/
|
|
1399
1495
|
Components.Schemas.EventJsonSchema;
|
|
1496
|
+
export interface $404 {
|
|
1497
|
+
}
|
|
1400
1498
|
}
|
|
1401
1499
|
}
|
|
1402
1500
|
namespace GetHistoricalEvent {
|
|
@@ -1417,7 +1515,7 @@ declare namespace Paths {
|
|
|
1417
1515
|
* "_event_time": "2024-01-01T12:00:00Z",
|
|
1418
1516
|
* "_event_id": "01FZ4Z5FZ5FZ5FZ5FZ5FZ5FZ5F",
|
|
1419
1517
|
* "_event_name": "MeterReading",
|
|
1420
|
-
* "_event_version": "1.0
|
|
1518
|
+
* "_event_version": "1.0",
|
|
1421
1519
|
* "_event_source": "api",
|
|
1422
1520
|
* "_trigger_source_type": "api",
|
|
1423
1521
|
* "_trigger_source": "user_123456",
|
|
@@ -1441,6 +1539,24 @@ declare namespace Paths {
|
|
|
1441
1539
|
}
|
|
1442
1540
|
}
|
|
1443
1541
|
}
|
|
1542
|
+
namespace ListEventVersions {
|
|
1543
|
+
namespace Parameters {
|
|
1544
|
+
export type EventName = string;
|
|
1545
|
+
}
|
|
1546
|
+
export interface PathParameters {
|
|
1547
|
+
event_name: Parameters.EventName;
|
|
1548
|
+
}
|
|
1549
|
+
namespace Responses {
|
|
1550
|
+
export type $200 = /**
|
|
1551
|
+
* Summary of an event's version timeline returned by
|
|
1552
|
+
* `GET /v1/events/{event_name}/versions`.
|
|
1553
|
+
*
|
|
1554
|
+
*/
|
|
1555
|
+
Components.Schemas.EventVersionRegistrySummary;
|
|
1556
|
+
export interface $404 {
|
|
1557
|
+
}
|
|
1558
|
+
}
|
|
1559
|
+
}
|
|
1444
1560
|
namespace ListEvents {
|
|
1445
1561
|
namespace Responses {
|
|
1446
1562
|
export interface $200 {
|
|
@@ -1486,7 +1602,7 @@ declare namespace Paths {
|
|
|
1486
1602
|
* "_event_time": "2024-01-01T12:00:00Z",
|
|
1487
1603
|
* "_event_id": "01FZ4Z5FZ5FZ5FZ5FZ5FZ5FZ5F",
|
|
1488
1604
|
* "_event_name": "MeterReading",
|
|
1489
|
-
* "_event_version": "1.0
|
|
1605
|
+
* "_event_version": "1.0",
|
|
1490
1606
|
* "_event_source": "api",
|
|
1491
1607
|
* "_trigger_source_type": "api",
|
|
1492
1608
|
* "_trigger_source": "user_123456",
|
|
@@ -1551,9 +1667,11 @@ declare namespace Paths {
|
|
|
1551
1667
|
* A lightweight event summary returned by the v2 history endpoint.
|
|
1552
1668
|
*
|
|
1553
1669
|
* Includes the standard `_*` metadata fields plus a projected subset of the
|
|
1554
|
-
* event payload. Hydrated entity objects (values carrying `_schema` or `_id`
|
|
1555
|
-
* and arrays of such objects
|
|
1556
|
-
* `
|
|
1670
|
+
* event payload. Hydrated entity objects (values carrying `_schema` or `_id`)
|
|
1671
|
+
* — and arrays of such objects — are reduced to reference stubs
|
|
1672
|
+
* `{_schema, _id, _title}` so consumers can identify and follow up on each
|
|
1673
|
+
* entity without paying the cost of the full hydrated graph. Fetch
|
|
1674
|
+
* `GET /v2/events/{event_name}/history/{event_id}` for the full hydration.
|
|
1557
1675
|
*
|
|
1558
1676
|
* Projected scalar payload fields appear as additional top-level properties.
|
|
1559
1677
|
*
|
|
@@ -1634,23 +1752,42 @@ interface OperationMethods {
|
|
|
1634
1752
|
/**
|
|
1635
1753
|
* getEventJSONSchema - getEventJSONSchema
|
|
1636
1754
|
*
|
|
1637
|
-
* Retrieve the JSON Schema of a specific business event
|
|
1755
|
+
* Retrieve the JSON Schema of a specific business event. Pass an optional
|
|
1756
|
+
* `Epilot-Event-Version` header to retrieve a specific version's schema;
|
|
1757
|
+
* when omitted, the event's latest version is returned.
|
|
1758
|
+
*
|
|
1638
1759
|
*/
|
|
1639
1760
|
'getEventJSONSchema'(
|
|
1640
|
-
parameters?: Parameters<Paths.GetEventJSONSchema.PathParameters> | null,
|
|
1761
|
+
parameters?: Parameters<Paths.GetEventJSONSchema.HeaderParameters & Paths.GetEventJSONSchema.PathParameters> | null,
|
|
1641
1762
|
data?: any,
|
|
1642
1763
|
config?: AxiosRequestConfig
|
|
1643
1764
|
): OperationResponse<Paths.GetEventJSONSchema.Responses.$200>
|
|
1644
1765
|
/**
|
|
1645
1766
|
* getEventExample - getEventExample
|
|
1646
1767
|
*
|
|
1647
|
-
* Generate a sample event payload based on the event's JSON Schema
|
|
1768
|
+
* Generate a sample event payload based on the event's JSON Schema. Pass an
|
|
1769
|
+
* optional `Epilot-Event-Version` header to generate the example for a
|
|
1770
|
+
* specific version; when omitted, the event's latest version is used.
|
|
1771
|
+
*
|
|
1648
1772
|
*/
|
|
1649
1773
|
'getEventExample'(
|
|
1650
|
-
parameters?: Parameters<Paths.GetEventExample.PathParameters> | null,
|
|
1774
|
+
parameters?: Parameters<Paths.GetEventExample.HeaderParameters & Paths.GetEventExample.PathParameters> | null,
|
|
1651
1775
|
data?: any,
|
|
1652
1776
|
config?: AxiosRequestConfig
|
|
1653
1777
|
): OperationResponse<Paths.GetEventExample.Responses.$200>
|
|
1778
|
+
/**
|
|
1779
|
+
* listEventVersions - listEventVersions
|
|
1780
|
+
*
|
|
1781
|
+
* List every known version of an event, along with the `latest`
|
|
1782
|
+
* and the set of currently `active` versions. See §3.2 of the
|
|
1783
|
+
* Event Payload Versioning RFC.
|
|
1784
|
+
*
|
|
1785
|
+
*/
|
|
1786
|
+
'listEventVersions'(
|
|
1787
|
+
parameters?: Parameters<Paths.ListEventVersions.PathParameters> | null,
|
|
1788
|
+
data?: any,
|
|
1789
|
+
config?: AxiosRequestConfig
|
|
1790
|
+
): OperationResponse<Paths.ListEventVersions.Responses.$200>
|
|
1654
1791
|
/**
|
|
1655
1792
|
* searchEventHistory - searchEventHistory
|
|
1656
1793
|
*
|
|
@@ -1667,9 +1804,10 @@ interface OperationMethods {
|
|
|
1667
1804
|
* Paginated history of events with projected/lightweight payload (v2).
|
|
1668
1805
|
*
|
|
1669
1806
|
* Returns `EventSummary` objects instead of fully hydrated `Event` objects:
|
|
1670
|
-
*
|
|
1671
|
-
*
|
|
1672
|
-
*
|
|
1807
|
+
* hydrated entity objects (values carrying `_schema`/`_id`) are reduced to
|
|
1808
|
+
* reference stubs `{_schema, _id, _title}` — the full entity is recoverable
|
|
1809
|
+
* via GET /v2/events/{event_name}/history/{event_id} or by hitting
|
|
1810
|
+
* entity-api directly with the `_id`.
|
|
1673
1811
|
*
|
|
1674
1812
|
*/
|
|
1675
1813
|
'searchEventHistoryV2'(
|
|
@@ -1745,10 +1883,13 @@ interface PathsDictionary {
|
|
|
1745
1883
|
/**
|
|
1746
1884
|
* getEventJSONSchema - getEventJSONSchema
|
|
1747
1885
|
*
|
|
1748
|
-
* Retrieve the JSON Schema of a specific business event
|
|
1886
|
+
* Retrieve the JSON Schema of a specific business event. Pass an optional
|
|
1887
|
+
* `Epilot-Event-Version` header to retrieve a specific version's schema;
|
|
1888
|
+
* when omitted, the event's latest version is returned.
|
|
1889
|
+
*
|
|
1749
1890
|
*/
|
|
1750
1891
|
'get'(
|
|
1751
|
-
parameters?: Parameters<Paths.GetEventJSONSchema.PathParameters> | null,
|
|
1892
|
+
parameters?: Parameters<Paths.GetEventJSONSchema.HeaderParameters & Paths.GetEventJSONSchema.PathParameters> | null,
|
|
1752
1893
|
data?: any,
|
|
1753
1894
|
config?: AxiosRequestConfig
|
|
1754
1895
|
): OperationResponse<Paths.GetEventJSONSchema.Responses.$200>
|
|
@@ -1757,14 +1898,32 @@ interface PathsDictionary {
|
|
|
1757
1898
|
/**
|
|
1758
1899
|
* getEventExample - getEventExample
|
|
1759
1900
|
*
|
|
1760
|
-
* Generate a sample event payload based on the event's JSON Schema
|
|
1901
|
+
* Generate a sample event payload based on the event's JSON Schema. Pass an
|
|
1902
|
+
* optional `Epilot-Event-Version` header to generate the example for a
|
|
1903
|
+
* specific version; when omitted, the event's latest version is used.
|
|
1904
|
+
*
|
|
1761
1905
|
*/
|
|
1762
1906
|
'get'(
|
|
1763
|
-
parameters?: Parameters<Paths.GetEventExample.PathParameters> | null,
|
|
1907
|
+
parameters?: Parameters<Paths.GetEventExample.HeaderParameters & Paths.GetEventExample.PathParameters> | null,
|
|
1764
1908
|
data?: any,
|
|
1765
1909
|
config?: AxiosRequestConfig
|
|
1766
1910
|
): OperationResponse<Paths.GetEventExample.Responses.$200>
|
|
1767
1911
|
}
|
|
1912
|
+
['/v1/events/{event_name}/versions']: {
|
|
1913
|
+
/**
|
|
1914
|
+
* listEventVersions - listEventVersions
|
|
1915
|
+
*
|
|
1916
|
+
* List every known version of an event, along with the `latest`
|
|
1917
|
+
* and the set of currently `active` versions. See §3.2 of the
|
|
1918
|
+
* Event Payload Versioning RFC.
|
|
1919
|
+
*
|
|
1920
|
+
*/
|
|
1921
|
+
'get'(
|
|
1922
|
+
parameters?: Parameters<Paths.ListEventVersions.PathParameters> | null,
|
|
1923
|
+
data?: any,
|
|
1924
|
+
config?: AxiosRequestConfig
|
|
1925
|
+
): OperationResponse<Paths.ListEventVersions.Responses.$200>
|
|
1926
|
+
}
|
|
1768
1927
|
['/v1/events/{event_name}:history']: {
|
|
1769
1928
|
/**
|
|
1770
1929
|
* searchEventHistory - searchEventHistory
|
|
@@ -1784,9 +1943,10 @@ interface PathsDictionary {
|
|
|
1784
1943
|
* Paginated history of events with projected/lightweight payload (v2).
|
|
1785
1944
|
*
|
|
1786
1945
|
* Returns `EventSummary` objects instead of fully hydrated `Event` objects:
|
|
1787
|
-
*
|
|
1788
|
-
*
|
|
1789
|
-
*
|
|
1946
|
+
* hydrated entity objects (values carrying `_schema`/`_id`) are reduced to
|
|
1947
|
+
* reference stubs `{_schema, _id, _title}` — the full entity is recoverable
|
|
1948
|
+
* via GET /v2/events/{event_name}/history/{event_id} or by hitting
|
|
1949
|
+
* entity-api directly with the `_id`.
|
|
1790
1950
|
*
|
|
1791
1951
|
*/
|
|
1792
1952
|
'post'(
|
|
@@ -1841,6 +2001,8 @@ type EventConfig = Components.Schemas.EventConfig;
|
|
|
1841
2001
|
type EventConfigBase = Components.Schemas.EventConfigBase;
|
|
1842
2002
|
type EventJsonSchema = Components.Schemas.EventJsonSchema;
|
|
1843
2003
|
type EventSummary = Components.Schemas.EventSummary;
|
|
2004
|
+
type EventVersionRegistrySummary = Components.Schemas.EventVersionRegistrySummary;
|
|
2005
|
+
type FieldChange = Components.Schemas.FieldChange;
|
|
1844
2006
|
type FieldsParam = Components.Schemas.FieldsParam;
|
|
1845
2007
|
type GraphDefinition = Components.Schemas.GraphDefinition;
|
|
1846
2008
|
type GraphEdge = Components.Schemas.GraphEdge;
|
|
@@ -1852,5 +2014,6 @@ type SearchOptionsV2 = Components.Schemas.SearchOptionsV2;
|
|
|
1852
2014
|
type TriggerEventPayload = Components.Schemas.TriggerEventPayload;
|
|
1853
2015
|
type TriggerEventResponse = Components.Schemas.TriggerEventResponse;
|
|
1854
2016
|
type UpdateEventPayload = Components.Schemas.UpdateEventPayload;
|
|
2017
|
+
type VersionMeta = Components.Schemas.VersionMeta;
|
|
1855
2018
|
|
|
1856
|
-
export { type AttachmentField as A, type Client as C, type EntityOperationTrigger as E, type
|
|
2019
|
+
export { type AttachmentField as A, type Client as C, type EntityOperationTrigger as E, type FieldChange as F, type GraphDefinition as G, type OperationMethods as O, Paths as P, type SchemaField as S, type TriggerEventPayload as T, type UpdateEventPayload as U, type VersionMeta as V, Components as a, type PathsDictionary as b, type CommonEventMetadata as c, type ContextEntity as d, type Event as e, type EventAttachment as f, type EventConfig as g, type EventConfigBase as h, type EventJsonSchema as i, type EventSummary as j, type EventVersionRegistrySummary as k, type FieldsParam as l, type GraphEdge as m, type GraphNode as n, type PrimitiveField as o, type SearchOptions as p, type SearchOptionsV2 as q, type TriggerEventResponse as r };
|
package/dist/index.cjs
CHANGED
|
@@ -57,7 +57,7 @@ var _chunkKP7H52BFcjs = require('./chunk-KP7H52BF.cjs');
|
|
|
57
57
|
var _chunkWQBBB6BNcjs = require('./chunk-WQBBB6BN.cjs');
|
|
58
58
|
|
|
59
59
|
|
|
60
|
-
var
|
|
60
|
+
var _chunkFDS727SLcjs = require('./chunk-FDS727SL.cjs');
|
|
61
61
|
|
|
62
62
|
|
|
63
63
|
var _chunk4M5V6BITcjs = require('./chunk-4M5V6BIT.cjs');
|
|
@@ -155,7 +155,7 @@ var _chunkDVM27A7Ecjs = require('./chunk-DVM27A7E.cjs');
|
|
|
155
155
|
|
|
156
156
|
|
|
157
157
|
|
|
158
|
-
var
|
|
158
|
+
var _chunkSAMDHOZ5cjs = require('./chunk-SAMDHOZ5.cjs');
|
|
159
159
|
|
|
160
160
|
|
|
161
161
|
var _chunkNJK5F5TFcjs = require('./chunk-NJK5F5TF.cjs');
|
|
@@ -222,7 +222,7 @@ var resolveClient = (params) => {
|
|
|
222
222
|
}
|
|
223
223
|
if (!entry.instance) {
|
|
224
224
|
const definition = entry.loader();
|
|
225
|
-
entry.instance =
|
|
225
|
+
entry.instance = _chunkSAMDHOZ5cjs.createApiClient.call(void 0, {
|
|
226
226
|
definition,
|
|
227
227
|
token: state.token,
|
|
228
228
|
headers: state.globalHeaders,
|
|
@@ -255,7 +255,7 @@ var resetAllClients = (registry) => {
|
|
|
255
255
|
};
|
|
256
256
|
|
|
257
257
|
// src/apis/_registry.ts
|
|
258
|
-
var expandDef = (mod) =>
|
|
258
|
+
var expandDef = (mod) => _chunkSAMDHOZ5cjs.expand.call(void 0, _nullishCoalesce(mod.default, () => ( mod)));
|
|
259
259
|
var registerBuiltinApis = (registry) => {
|
|
260
260
|
registerApi({
|
|
261
261
|
registry,
|
|
@@ -375,7 +375,7 @@ var registerBuiltinApis = (registry) => {
|
|
|
375
375
|
registerApi({
|
|
376
376
|
registry,
|
|
377
377
|
name: "eventCatalog",
|
|
378
|
-
loader: () => expandDef(
|
|
378
|
+
loader: () => expandDef(_chunkFDS727SLcjs.require_event_catalog_runtime.call(void 0, ))
|
|
379
379
|
});
|
|
380
380
|
registerApi({
|
|
381
381
|
registry,
|
|
@@ -593,9 +593,9 @@ var createSDK = () => {
|
|
|
593
593
|
const available = [...registry.keys()].join(", ");
|
|
594
594
|
throw new Error(`Unknown API: "${name}". Available: ${available}`);
|
|
595
595
|
}
|
|
596
|
-
return
|
|
596
|
+
return _chunkSAMDHOZ5cjs.createApiHandle.call(void 0, {
|
|
597
597
|
resolveClient: () => resolveClient({ registry, name, state }),
|
|
598
|
-
createClient: () =>
|
|
598
|
+
createClient: () => _chunkSAMDHOZ5cjs.createApiClient.call(void 0, { definition: entry.loader(), apiName: name }),
|
|
599
599
|
apiName: name
|
|
600
600
|
});
|
|
601
601
|
};
|
|
@@ -643,9 +643,9 @@ var createSDK = () => {
|
|
|
643
643
|
return interceptorUse;
|
|
644
644
|
}
|
|
645
645
|
case "help":
|
|
646
|
-
return (apiName) =>
|
|
646
|
+
return (apiName) => _chunkSAMDHOZ5cjs.help.call(void 0, apiName);
|
|
647
647
|
case "openapi":
|
|
648
|
-
return (apiName) =>
|
|
648
|
+
return (apiName) => _chunkSAMDHOZ5cjs.openapi.call(void 0, apiName);
|
|
649
649
|
case "then":
|
|
650
650
|
case "catch":
|
|
651
651
|
case "finally":
|
|
@@ -675,4 +675,4 @@ var epilot = createSDK();
|
|
|
675
675
|
|
|
676
676
|
|
|
677
677
|
|
|
678
|
-
exports.applyLargeResponseInterceptor = applyLargeResponseInterceptor; exports.applyRetryInterceptor = applyRetryInterceptor; exports.authorize =
|
|
678
|
+
exports.applyLargeResponseInterceptor = applyLargeResponseInterceptor; exports.applyRetryInterceptor = applyRetryInterceptor; exports.authorize = _chunkSAMDHOZ5cjs.authorize; exports.createSDK = createSDK; exports.epilot = epilot; exports.help = _chunkSAMDHOZ5cjs.help; exports.openapi = _chunkSAMDHOZ5cjs.openapi;
|
package/dist/index.d.cts
CHANGED
|
@@ -26,7 +26,7 @@ import { C as Client$j } from './email-template.d-gtQkdaXM.cjs';
|
|
|
26
26
|
import { C as Client$k } from './entity.d-fospShiN.cjs';
|
|
27
27
|
import { C as Client$l } from './entity-mapping.d-DKSW3sfy.cjs';
|
|
28
28
|
import { C as Client$m } from './environments.d-BvqvN-PD.cjs';
|
|
29
|
-
import { C as Client$n } from './event-catalog.d-
|
|
29
|
+
import { C as Client$n } from './event-catalog.d-CXbUn8T1.cjs';
|
|
30
30
|
import { C as Client$o } from './file.d-Rq_mbdOo.cjs';
|
|
31
31
|
import { C as Client$p } from './iban.d-BwdiGbxi.cjs';
|
|
32
32
|
import { C as Client$q } from './integration-toolkit.d-CDcHwmoI.cjs';
|
|
@@ -50,7 +50,7 @@ import { C as Client$H } from './targeting.d-BkPe5NmP.cjs';
|
|
|
50
50
|
import { C as Client$I } from './template-variables.d-Ble9TSBa.cjs';
|
|
51
51
|
import { C as Client$J } from './user.d-D18fe97W.cjs';
|
|
52
52
|
import { C as Client$K } from './validation-rules.d-Db5c5zTf.cjs';
|
|
53
|
-
import { C as Client$L } from './webhooks.d-
|
|
53
|
+
import { C as Client$L } from './webhooks.d-DKZOMj1P.cjs';
|
|
54
54
|
import { C as Client$M } from './workflow.d-CMSKt8oN.cjs';
|
|
55
55
|
import { C as Client$N } from './workflow-definition.d-DOeb0KVV.cjs';
|
|
56
56
|
|
package/dist/index.d.ts
CHANGED
|
@@ -26,7 +26,7 @@ import { C as Client$j } from './email-template.d-gtQkdaXM.js';
|
|
|
26
26
|
import { C as Client$k } from './entity.d-fospShiN.js';
|
|
27
27
|
import { C as Client$l } from './entity-mapping.d-DKSW3sfy.js';
|
|
28
28
|
import { C as Client$m } from './environments.d-BvqvN-PD.js';
|
|
29
|
-
import { C as Client$n } from './event-catalog.d-
|
|
29
|
+
import { C as Client$n } from './event-catalog.d-CXbUn8T1.js';
|
|
30
30
|
import { C as Client$o } from './file.d-Rq_mbdOo.js';
|
|
31
31
|
import { C as Client$p } from './iban.d-BwdiGbxi.js';
|
|
32
32
|
import { C as Client$q } from './integration-toolkit.d-CDcHwmoI.js';
|
|
@@ -50,7 +50,7 @@ import { C as Client$H } from './targeting.d-BkPe5NmP.js';
|
|
|
50
50
|
import { C as Client$I } from './template-variables.d-Ble9TSBa.js';
|
|
51
51
|
import { C as Client$J } from './user.d-D18fe97W.js';
|
|
52
52
|
import { C as Client$K } from './validation-rules.d-Db5c5zTf.js';
|
|
53
|
-
import { C as Client$L } from './webhooks.d-
|
|
53
|
+
import { C as Client$L } from './webhooks.d-DKZOMj1P.js';
|
|
54
54
|
import { C as Client$M } from './workflow.d-CMSKt8oN.js';
|
|
55
55
|
import { C as Client$N } from './workflow-definition.d-DOeb0KVV.js';
|
|
56
56
|
|
package/dist/index.js
CHANGED
|
@@ -57,7 +57,7 @@ import {
|
|
|
57
57
|
} from "./chunk-D7Q4JGN7.js";
|
|
58
58
|
import {
|
|
59
59
|
require_event_catalog_runtime
|
|
60
|
-
} from "./chunk-
|
|
60
|
+
} from "./chunk-M4FO2MI4.js";
|
|
61
61
|
import {
|
|
62
62
|
require_file_runtime
|
|
63
63
|
} from "./chunk-RDVFQOCQ.js";
|
|
@@ -155,7 +155,7 @@ import {
|
|
|
155
155
|
expand,
|
|
156
156
|
help,
|
|
157
157
|
openapi
|
|
158
|
-
} from "./chunk-
|
|
158
|
+
} from "./chunk-5QPKSRW5.js";
|
|
159
159
|
import {
|
|
160
160
|
__require
|
|
161
161
|
} from "./chunk-YPSWSI3M.js";
|
package/dist/js-yaml-DLCVPJ7G.js
CHANGED
|
File without changes
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});require('./chunk-NJK5F5TF.cjs');
|
|
2
|
+
|
|
3
|
+
// src/docs/webhooks.json
|
|
4
|
+
var webhooks_default = '# Webhooks\n\n- **Base URL:** `https://webhooks.sls.epilot.io`\n- **Full API Docs:** [https://docs.epilot.io/api/webhooks](https://docs.epilot.io/api/webhooks)\n\n## Usage\n\n```ts\nimport { epilot } from \'@epilot/sdk\'\n\nepilot.authorize(() => \'<token>\')\nconst { data } = await epilot.webhooks.getPublicKey(...)\n```\n\n### Tree-shakeable import\n\n```ts\nimport { getClient, authorize } from \'@epilot/sdk/webhooks\'\n\nconst webhooksClient = getClient()\nauthorize(webhooksClient, () => \'<token>\')\nconst { data } = await webhooksClient.getPublicKey(...)\n```\n\n## Operations\n\n**webhooks**\n- [`getPublicKey`](#getpublickey)\n- [`getConfiguredEvents`](#getconfiguredevents)\n- [`getConfigs`](#getconfigs)\n- [`createConfig`](#createconfig)\n- [`getConfig`](#getconfig)\n- [`updateConfig`](#updateconfig)\n- [`deleteConfig`](#deleteconfig)\n- [`testOAuth`](#testoauth)\n- [`triggerWebhook`](#triggerwebhook)\n- [`batchReplayEvents`](#batchreplayevents)\n- [`getEventById`](#geteventbyid)\n- [`replayEvent`](#replayevent)\n- [`getWebhookExample`](#getwebhookexample)\n\n**Events**\n- [`getWebhookEventsV2`](#getwebhookeventsv2)\n\n**Schemas**\n- [`PublicKeyResponse`](#publickeyresponse)\n- [`SearchOptions`](#searchoptions)\n- [`EventListResponse`](#eventlistresponse)\n- [`HttpMethod`](#httpmethod)\n- [`AuthType`](#authtype)\n- [`Filter`](#filter)\n- [`WebhookCondition`](#webhookcondition)\n- [`WebhookConditionGroup`](#webhookconditiongroup)\n- [`Auth`](#auth)\n- [`BasicAuthConfig`](#basicauthconfig)\n- [`OAuthConfig`](#oauthconfig)\n- [`ApiKeyConfig`](#apikeyconfig)\n- [`WebhookConfig`](#webhookconfig)\n- [`EventConfigResp`](#eventconfigresp)\n- [`EventConfigEntry`](#eventconfigentry)\n- [`ErrorResp`](#errorresp)\n- [`TriggerWebhookResp`](#triggerwebhookresp)\n- [`PayloadConfiguration`](#payloadconfiguration)\n- [`CustomHeader`](#customheader)\n- [`CustomOAuthParameter`](#customoauthparameter)\n- [`Metadata`](#metadata)\n- [`ExecutionPayload`](#executionpayload)\n- [`WebhookEvent`](#webhookevent)\n- [`ExampleRequest`](#examplerequest)\n- [`ExampleResponse`](#exampleresponse)\n- [`TestOAuthResponse`](#testoauthresponse)\n- [`BatchReplayRequest`](#batchreplayrequest)\n\n### `getPublicKey`\n\nReturns the platform-level Ed25519 public key used to verify\nasymmetric (v1a) webhook signatures. This endpoint is unauthenticated since the public key is not a secret, but the orgId parameter is requ\n\n`GET /v1/webhooks/.well-known/public-key`\n\n```ts\nconst { data } = await client.getPublicKey({\n orgId: \'example\',\n})\n```\n\n<details>\n<summary>Response</summary>\n\n```json\n{\n "public_key": "-----BEGIN PUBLIC KEY-----\\nMCowBQYDK2VwAyEA...\\n-----END PUBLIC KEY-----\\n",\n "algorithm": "ed25519",\n "issuer": "epilot"\n}\n```\n\n</details>\n\n---\n\n### `getConfiguredEvents`\n\nRetrieve events that can trigger webhooks\n\n`GET /v1/webhooks/configured-events`\n\n```ts\nconst { data } = await client.getConfiguredEvents()\n```\n\n<details>\n<summary>Response</summary>\n\n```json\n[\n {\n "eventName": "customer_request_created",\n "eventLabel": "Customer Request Created"\n }\n]\n```\n\n</details>\n\n---\n\n### `getConfigs`\n\nSearch Webhook Client Configs\n\n`GET /v1/webhooks/configs`\n\n```ts\nconst { data } = await client.getConfigs({\n eventName: \'example\',\n})\n```\n\n<details>\n<summary>Response</summary>\n\n```json\n[\n {\n "eventName": "CustomerRequest_Created",\n "url": "https://my-partner-service.api.com",\n "httpMethod": "POST",\n "enabled": true,\n "auth": {\n "authType": "BASIC",\n "basicAuthConfig": {\n "username": "secretUsername",\n "password": "secret7825@!"\n }\n },\n "filter": {\n "keyToFilter": "customer_request.productId",\n "supportedValues": ["2324245", "5253642"]\n }\n }\n]\n```\n\n</details>\n\n---\n\n### `createConfig`\n\nCreate Webhook Client Config\n\n`POST /v1/webhooks/configs`\n\n```ts\nconst { data } = await client.createConfig(\n null,\n {\n eventName: \'CustomerRequest_Created\',\n url: \'https://my-partner-service.api.com\',\n httpMethod: \'POST\',\n enabled: true,\n auth: {\n authType: \'BASIC\',\n basicAuthConfig: {\n username: \'secretUsername\',\n password: \'secret7825@!\'\n }\n },\n filter: {\n keyToFilter: \'customer_request.productId\',\n supportedValues: [\'2324245\', \'5253642\']\n }\n },\n)\n```\n\n<details>\n<summary>Response</summary>\n\n```json\n{\n "eventName": "CustomerRequest_Created",\n "url": "https://my-partner-service.api.com",\n "httpMethod": "POST",\n "enabled": true,\n "auth": {\n "authType": "BASIC",\n "basicAuthConfig": {\n "username": "secretUsername",\n "password": "secret7825@!"\n }\n },\n "filter": {\n "keyToFilter": "customer_request.productId",\n "supportedValues": ["2324245", "5253642"]\n }\n}\n```\n\n</details>\n\n---\n\n### `getConfig`\n\nGet webhook config by id\n\n`GET /v1/webhooks/configs/{configId}`\n\n```ts\nconst { data } = await client.getConfig({\n configId: \'example\',\n})\n```\n\n<details>\n<summary>Response</summary>\n\n```json\n{\n "eventName": "CustomerRequest_Created",\n "url": "https://my-partner-service.api.com",\n "httpMethod": "POST",\n "enabled": true,\n "auth": {\n "authType": "BASIC",\n "basicAuthConfig": {\n "username": "secretUsername",\n "password": "secret7825@!"\n }\n },\n "filter": {\n "keyToFilter": "customer_request.productId",\n "supportedValues": ["2324245", "5253642"]\n }\n}\n```\n\n</details>\n\n---\n\n### `updateConfig`\n\nUpdate Webhook Client Config\n\n`PUT /v1/webhooks/configs/{configId}`\n\n```ts\nconst { data } = await client.updateConfig(\n {\n configId: \'example\',\n },\n {\n eventName: \'CustomerRequest_Created\',\n url: \'https://my-partner-service.api.com\',\n httpMethod: \'POST\',\n enabled: true,\n auth: {\n authType: \'BASIC\',\n basicAuthConfig: {\n username: \'secretUsername\',\n password: \'secret7825@!\'\n }\n },\n filter: {\n keyToFilter: \'customer_request.productId\',\n supportedValues: [\'2324245\', \'5253642\']\n }\n },\n)\n```\n\n<details>\n<summary>Response</summary>\n\n```json\n{\n "eventName": "CustomerRequest_Created",\n "url": "https://my-partner-service.api.com",\n "httpMethod": "POST",\n "enabled": true,\n "auth": {\n "authType": "BASIC",\n "basicAuthConfig": {\n "username": "secretUsername",\n "password": "secret7825@!"\n }\n },\n "filter": {\n "keyToFilter": "customer_request.productId",\n "supportedValues": ["2324245", "5253642"]\n }\n}\n```\n\n</details>\n\n---\n\n### `deleteConfig`\n\nDelete Webhook Client Config\n\n`DELETE /v1/webhooks/configs/{configId}`\n\n```ts\nconst { data } = await client.deleteConfig({\n configId: \'example\',\n})\n```\n\n---\n\n### `testOAuth`\n\nTest OAuth connection\n\n`POST /v1/webhooks/configs/{configId}/test-oauth`\n\n```ts\nconst { data } = await client.testOAuth({\n configId: \'example\',\n})\n```\n\n<details>\n<summary>Response</summary>\n\n```json\n{\n "success": true,\n "expires_in": 3600,\n "token_type": "Bearer",\n "message": "OAuth token exchange successful"\n}\n```\n\n</details>\n\n---\n\n### `triggerWebhook`\n\ntriggers a webhook event either async or sync\n\n`POST /v1/webhooks/configs/{configId}/trigger`\n\n```ts\nconst { data } = await client.triggerWebhook(\n {\n sync: true,\n configId: \'example\',\n },\n {\n metadata: {\n action: \'Manual triggered by user with id 123456\',\n origin: \'string\',\n creation_timestamp: \'string\',\n webhook_id: \'string\',\n webhook_name: \'string\',\n automation_name: \'string\',\n organization_id: \'string\',\n user_id: \'string\',\n correlation_id: \'string\',\n execution_id: \'string\',\n action_id: \'string\'\n }\n },\n)\n```\n\n<details>\n<summary>Response</summary>\n\n```json\n{\n "status_code": "string",\n "message": "string",\n "body": {},\n "code": "string",\n "status": "succeeded",\n "start_date": "string",\n "end_date": "string",\n "event_id": "string"\n}\n```\n\n</details>\n\n---\n\n### `batchReplayEvents`\n\nReplay a batch of webhook events\n\n`POST /v1/webhooks/configs/{configId}/events/replay-batch`\n\n```ts\nconst { data } = await client.batchReplayEvents(\n {\n configId: \'example\',\n },\n {\n eventIds: [\'2f1b7cf8-ff55-4359-966f-e56f39a52c94\', \'48c984bf-466b-470b-b743-d07cea168243\']\n },\n)\n```\n\n---\n\n### `getEventById`\n\nGet a webhook event by its id\n\n`GET /v1/webhooks/configs/{configId}/events/{eventId}`\n\n```ts\nconst { data } = await client.getEventById({\n configId: \'example\',\n eventId: \'example\',\n})\n```\n\n<details>\n<summary>Response</summary>\n\n```json\n{\n "event_id": "string",\n "org_id": "string",\n "webhook_config_id": "string",\n "url": "string",\n "created_at": "2021-04-27T12:01:13.000Z",\n "event_name": "string",\n "http_response": {\n "status_code": 0,\n "message": "string",\n "body": {},\n "code": "string"\n },\n "metadata": {\n "action": "Manual triggered by user with id 123456",\n "origin": "string",\n "creation_timestamp": "string",\n "webhook_id": "string",\n "webhook_name": "string",\n "automation_name": "string",\n "organization_id": "string",\n "user_id": "string",\n "correlation_id": "string",\n "execution_id": "string",\n "action_id": "string"\n },\n "status": "succeeded",\n "http_method": "GET",\n "payload": "string",\n "retry_attempt": 0\n}\n```\n\n</details>\n\n---\n\n### `replayEvent`\n\nReplay a webhook event\n\n`POST /v1/webhooks/configs/{configId}/events/{eventId}/replay`\n\n```ts\nconst { data } = await client.replayEvent({\n configId: \'example\',\n eventId: \'example\',\n})\n```\n\n---\n\n### `getWebhookExample`\n\nGenerate an example payload for a webhook configuration based on trigger type\n\n`POST /v1/webhooks/configs/{configId}/example`\n\n```ts\nconst { data } = await client.getWebhookExample(\n {\n configId: \'example\',\n },\n {\n automation_id: \'automation_123\'\n },\n)\n```\n\n<details>\n<summary>Response</summary>\n\n```json\n{\n "metadata": {\n "action": "Manual triggered by user with id 123456",\n "origin": "string",\n "creation_timestamp": "string",\n "webhook_id": "string",\n "webhook_name": "string",\n "automation_name": "string",\n "organization_id": "string",\n "user_id": "string",\n "correlation_id": "string",\n "execution_id": "string",\n "action_id": "string"\n },\n "entity": {},\n "relations": [\n {}\n ]\n}\n```\n\n</details>\n\n---\n\n### `getWebhookEventsV2`\n\nList webhook events and filter them by status, timestamp, etc.\n\n`POST /v2/webhooks/configs/{configId}/events`\n\n```ts\nconst { data } = await client.getWebhookEventsV2(\n {\n configId: \'example\',\n },\n {\n limit: 25,\n cursor: {\n created_at: \'2025-10-31T12:34:56Z\',\n event_id: \'evt_1234567890abcdef\'\n },\n timestamp: {\n from: \'2025-10-01T00:00:00Z\',\n to: \'2025-10-31T23:59:59Z\'\n },\n event_id: \'evt_1234567890abcdef\',\n status: \'succeeded\'\n },\n)\n```\n\n<details>\n<summary>Response</summary>\n\n```json\n{\n "data": [\n {\n "event_id": "string",\n "org_id": "string",\n "webhook_config_id": "string",\n "url": "string",\n "created_at": "2021-04-27T12:01:13.000Z",\n "event_name": "string",\n "http_response": {\n "status_code": 0,\n "message": "string",\n "body": {},\n "code": "string"\n },\n "metadata": {\n "action": "Manual triggered by user with id 123456",\n "origin": "string",\n "creation_timestamp": "string",\n "webhook_id": "string",\n "webhook_name": "string",\n "automation_name": "string",\n "organization_id": "string",\n "user_id": "string",\n "correlation_id": "string",\n "execution_id": "string",\n "action_id": "string"\n },\n "status": "succeeded",\n "http_method": "GET",\n "payload": "string",\n "retry_attempt": 0\n }\n ],\n "next_cursor": {\n "created_at": "2025-10-31T12:34:56Z",\n "event_id": "evt_1234567890abcdef"\n },\n "has_more": true\n}\n```\n\n</details>\n\n---\n\n## Schemas\n\n### `PublicKeyResponse`\n\n```ts\ntype PublicKeyResponse = {\n public_key: string\n algorithm: string\n issuer?: string\n}\n```\n\n### `SearchOptions`\n\n```ts\ntype SearchOptions = {\n limit?: number\n cursor?: {\n created_at?: string // date-time\n event_id?: string\n }\n timestamp?: {\n from?: string // date-time\n to?: string // date-time\n }\n event_id?: string\n status?: "succeeded" | "failed" | "skipped"\n}\n```\n\n### `EventListResponse`\n\n```ts\ntype EventListResponse = {\n data?: Array<{\n event_id: string\n org_id: string\n webhook_config_id: string\n url?: string\n created_at?: string\n event_name?: string\n http_response?: {\n status_code?: { ... }\n message?: { ... }\n body?: { ... }\n code?: { ... }\n }\n metadata?: {\n action?: { ... }\n origin?: { ... }\n creation_timestamp?: { ... }\n webhook_id?: { ... }\n webhook_name?: { ... }\n automation_name?: { ... }\n organization_id: { ... }\n user_id?: { ... }\n correlation_id?: { ... }\n execution_id?: { ... }\n action_id?: { ... }\n }\n status?: "succeeded" | "failed" | "in_progress" | "skipped"\n http_method?: "GET" | "POST" | "PUT"\n payload?: string\n retry_attempt?: number\n }>\n next_cursor?: {\n created_at?: string // date-time\n event_id?: string\n }\n has_more?: boolean\n}\n```\n\n### `HttpMethod`\n\n```ts\ntype HttpMethod = "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "OPTIONS" | "HEAD"\n```\n\n### `AuthType`\n\n```ts\ntype AuthType = "BASIC" | "OAUTH_CLIENT_CREDENTIALS" | "API_KEY" | "NONE"\n```\n\n### `Filter`\n\n```ts\ntype Filter = {\n keyToFilter: string\n supportedValues: string[]\n}\n```\n\n### `WebhookCondition`\n\nA condition that must be met for the webhook to fire.\n\n```ts\ntype WebhookCondition = {\n field: string\n operation: "equals" | "not_equals" | "any_of" | "none_of" | "contains" | "not_contains" | "starts_with" | "ends_with" | "greater_than" | "less_than" | "greater_than_or_equals" | "less_than_or_equals" | "is_empty" | "is_not_empty"\n values?: string[]\n field_type?: "string" | "number" | "boolean" | "date" | "datetime"\n is_array_field?: boolean\n repeatable_item_op?: boolean\n}\n```\n\n### `WebhookConditionGroup`\n\nA group of conditions with a logical operator. Multiple conditions are AND-ed by default.\n\n```ts\ntype WebhookConditionGroup = {\n conditions?: Array<{\n field: string\n operation: "equals" | "not_equals" | "any_of" | "none_of" | "contains" | "not_contains" | "starts_with" | "ends_with" | "greater_than" | "less_than" | "greater_than_or_equals" | "less_than_or_equals" | "is_empty" | "is_not_empty"\n values?: string[]\n field_type?: "string" | "number" | "boolean" | "date" | "datetime"\n is_array_field?: boolean\n repeatable_item_op?: boolean\n }>\n logical_operator?: "AND" | "OR"\n}\n```\n\n### `Auth`\n\n```ts\ntype Auth = {\n authType: "BASIC" | "OAUTH_CLIENT_CREDENTIALS" | "API_KEY" | "NONE"\n basicAuthConfig?: {\n username: string\n password?: string\n passwordIsEnvVar?: boolean\n }\n oauthConfig?: {\n clientId: string\n clientSecret?: string\n clientSecretIsEnvVar?: boolean\n endpoint: string\n httpMethod: "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "OPTIONS" | "HEAD"\n customParameterList?: Array<{\n type: { ... }\n key: { ... }\n value: { ... }\n }>\n }\n apiKeyConfig?: {\n keyName: string\n keyValue?: string\n keyValueIsEnvVar?: boolean\n }\n}\n```\n\n### `BasicAuthConfig`\n\nTo be sent only if authType is BASIC\n\n```ts\ntype BasicAuthConfig = {\n username: string\n password?: string\n passwordIsEnvVar?: boolean\n}\n```\n\n### `OAuthConfig`\n\nTo be sent only if authType is OAUTH_CLIENT_CREDENTIALS\n\n```ts\ntype OAuthConfig = {\n clientId: string\n clientSecret?: string\n clientSecretIsEnvVar?: boolean\n endpoint: string\n httpMethod: "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "OPTIONS" | "HEAD"\n customParameterList?: Array<{\n type: "body" | "query" | "header"\n key: string\n value: string\n }>\n}\n```\n\n### `ApiKeyConfig`\n\nTo be sent only if authType is API_KEY\n\n```ts\ntype ApiKeyConfig = {\n keyName: string\n keyValue?: string\n keyValueIsEnvVar?: boolean\n}\n```\n\n### `WebhookConfig`\n\n```ts\ntype WebhookConfig = {\n id?: string\n name: string\n eventName: string\n eventVersion?: string\n url?: string\n creationTime?: string\n updatedTime?: string\n httpMethod?: "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "OPTIONS" | "HEAD"\n enabled?: boolean\n auth?: {\n authType: "BASIC" | "OAUTH_CLIENT_CREDENTIALS" | "API_KEY" | "NONE"\n basicAuthConfig?: {\n username: { ... }\n password?: { ... }\n passwordIsEnvVar?: { ... }\n }\n oauthConfig?: {\n clientId: { ... }\n clientSecret?: { ... }\n clientSecretIsEnvVar?: { ... }\n endpoint: { ... }\n httpMethod: { ... }\n customParameterList?: { ... }\n }\n apiKeyConfig?: {\n keyName: { ... }\n keyValue?: { ... }\n keyValueIsEnvVar?: { ... }\n }\n }\n filter?: {\n keyToFilter: string\n supportedValues: string[]\n }\n payloadConfiguration?: {\n hydrate_entity?: boolean\n include_relations?: boolean\n include_activity?: boolean\n include_changed_attributes?: boolean\n apply_changesets?: boolean\n custom_headers?: Record<string, string>\n }\n enableStaticIP?: boolean\n protected?: boolean\n secureProxy?: {\n integration_id: string // uuid\n use_case_slug: string\n }\n status?: "active" | "inactive" | "incomplete"\n jsonataExpression?: string\n deliveryMode?: "json_base64" | "binary_multipart"\n multipartConfig?: {\n fileFieldName?: string\n fileFieldStrategy?: "single" | "multi"\n fileSource?: string\n extraFields?: Record<string, string>\n }\n retryPolicy?: {\n enabled: boolean\n maxAttempts?: number\n }\n filterConditions?: {\n conditions?: Array<{\n field: { ... }\n operation: { ... }\n values?: { ... }\n field_type?: { ... }\n is_array_field?: { ... }\n repeatable_item_op?: { ... }\n }>\n logical_operator?: "AND" | "OR"\n }\n _manifest?: string // uuid[]\n signingSecret?: string\n}\n```\n\n### `EventConfigResp`\n\n```ts\ntype EventConfigResp = Array<{\n eventName?: string\n eventLabel?: string\n}>\n```\n\n### `EventConfigEntry`\n\n```ts\ntype EventConfigEntry = {\n eventName?: string\n eventLabel?: string\n}\n```\n\n### `ErrorResp`\n\n```ts\ntype ErrorResp = {\n message?: string\n}\n```\n\n### `TriggerWebhookResp`\n\n```ts\ntype TriggerWebhookResp = {\n status_code?: string\n message?: string\n body?: object\n code?: string\n status?: "succeeded" | "failed"\n start_date?: string\n end_date?: string\n event_id: string\n}\n```\n\n### `PayloadConfiguration`\n\nConfiguration for the webhook payload\n\n```ts\ntype PayloadConfiguration = {\n hydrate_entity?: boolean\n include_relations?: boolean\n include_activity?: boolean\n include_changed_attributes?: boolean\n apply_changesets?: boolean\n custom_headers?: Record<string, string>\n}\n```\n\n### `CustomHeader`\n\nObject representing custom headers as key-value pairs.\n\n```ts\ntype CustomHeader = Record<string, string>\n```\n\n### `CustomOAuthParameter`\n\nCustom key/value pair of either type body, query or header\n\n```ts\ntype CustomOAuthParameter = {\n type: "body" | "query" | "header"\n key: string\n value: string\n}\n```\n\n### `Metadata`\n\nContains the metadata about the configured event\n\n```ts\ntype Metadata = {\n action?: string\n origin?: string\n creation_timestamp?: string\n webhook_id?: string\n webhook_name?: string\n automation_name?: string\n organization_id: string\n user_id?: string\n correlation_id?: string\n execution_id?: string\n action_id?: string\n}\n```\n\n### `ExecutionPayload`\n\nPayload for triggering a webhook\n\n```ts\ntype ExecutionPayload = {\n metadata: {\n action?: string\n origin?: string\n creation_timestamp?: string\n webhook_id?: string\n webhook_name?: string\n automation_name?: string\n organization_id: string\n user_id?: string\n correlation_id?: string\n execution_id?: string\n action_id?: string\n }\n}\n```\n\n### `WebhookEvent`\n\n```ts\ntype WebhookEvent = {\n event_id: string\n org_id: string\n webhook_config_id: string\n url?: string\n created_at?: string\n event_name?: string\n http_response?: {\n status_code?: number\n message?: string\n body?: object\n code?: string\n }\n metadata?: {\n action?: string\n origin?: string\n creation_timestamp?: string\n webhook_id?: string\n webhook_name?: string\n automation_name?: string\n organization_id: string\n user_id?: string\n correlation_id?: string\n execution_id?: string\n action_id?: string\n }\n status?: "succeeded" | "failed" | "in_progress" | "skipped"\n http_method?: "GET" | "POST" | "PUT"\n payload?: string\n retry_attempt?: number\n}\n```\n\n### `ExampleRequest`\n\n```ts\ntype ExampleRequest = {\n automation_id?: string\n}\n```\n\n### `ExampleResponse`\n\n```ts\ntype ExampleResponse = {\n metadata?: {\n action?: string\n origin?: string\n creation_timestamp?: string\n webhook_id?: string\n webhook_name?: string\n automation_name?: string\n organization_id: string\n user_id?: string\n correlation_id?: string\n execution_id?: string\n action_id?: string\n }\n entity?: Record<string, unknown>\n relations?: Record<string, unknown>[]\n}\n```\n\n### `TestOAuthResponse`\n\n```ts\ntype TestOAuthResponse = {\n success: boolean\n expires_in?: number\n token_type?: string\n message: string\n}\n```\n\n### `BatchReplayRequest`\n\n```ts\ntype BatchReplayRequest = {\n eventIds: string[]\n}\n```\n';
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
exports.default = webhooks_default;
|