@crvouga/mockingbird-service-slack 3.3.0 → 3.5.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/CHANGELOG.md +18 -4
- package/dist/{chunk-6MIIKZZB.js → chunk-4JPRLFNZ.js} +108 -5
- package/dist/chunk-4JPRLFNZ.js.map +7 -0
- package/dist/chunk-DHAINBRN.js +5113 -0
- package/dist/chunk-DHAINBRN.js.map +7 -0
- package/dist/cli.js +2 -2
- package/dist/index.d.ts +15 -1
- package/dist/index.js +1 -1
- package/dist/server.d.ts +31 -2
- package/dist/server.js +2 -2
- package/package.json +1 -1
- package/dist/chunk-6MIIKZZB.js.map +0 -7
- package/dist/chunk-ZFHCM6E3.js +0 -1305
- package/dist/chunk-ZFHCM6E3.js.map +0 -7
package/dist/cli.js
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -691,6 +691,8 @@ type SnapshotDocument = {
|
|
|
691
691
|
faults?: unknown;
|
|
692
692
|
latency?: unknown;
|
|
693
693
|
virtualTime?: boolean;
|
|
694
|
+
/** Quiescent webhook endpoints, delivery history and fault state. Contains private configuration. */
|
|
695
|
+
webhooks?: unknown;
|
|
694
696
|
};
|
|
695
697
|
/** Controls for one namespace. */
|
|
696
698
|
type NamespaceControls = {
|
|
@@ -904,6 +906,8 @@ type CredentialRegistry = {
|
|
|
904
906
|
}[];
|
|
905
907
|
};
|
|
906
908
|
|
|
909
|
+
type OwnedTransport = (request: Request, namespace: string, send: typeof fetch) => Promise<Response>;
|
|
910
|
+
|
|
907
911
|
/**
|
|
908
912
|
* A point-in-time copy of everything a service namespace holds.
|
|
909
913
|
*
|
|
@@ -1021,8 +1025,16 @@ type PublishInput = {
|
|
|
1021
1025
|
id?: string;
|
|
1022
1026
|
};
|
|
1023
1027
|
type WebhookHub = {
|
|
1028
|
+
observeDeliveries(listener: (event: {
|
|
1029
|
+
namespace: string;
|
|
1030
|
+
state: string;
|
|
1031
|
+
deliveryId: string;
|
|
1032
|
+
}) => void): () => void;
|
|
1033
|
+
setTransportPolicy(policy: OwnedTransport): void;
|
|
1024
1034
|
pending(namespace: string): number;
|
|
1025
1035
|
snapshot(namespace: string): unknown;
|
|
1036
|
+
exportSnapshot(handle: unknown): unknown;
|
|
1037
|
+
importSnapshot(namespace: string, document: unknown): unknown;
|
|
1026
1038
|
restore(namespace: string, snapshot: unknown): void;
|
|
1027
1039
|
publish(input: PublishInput): WebhookMessage;
|
|
1028
1040
|
/** Replace a namespace's own endpoints (`PUT /__admin/webhook-endpoints`). */
|
|
@@ -1035,7 +1047,7 @@ type WebhookHub = {
|
|
|
1035
1047
|
/** Run every pending retry (and release held reordered messages) now, and every retry those attempts schedule, until nothing is pending. */
|
|
1036
1048
|
flush(): Promise<void>;
|
|
1037
1049
|
/** Resolve once nothing is in flight. */
|
|
1038
|
-
idle(): Promise<void>;
|
|
1050
|
+
idle(namespace?: string): Promise<void>;
|
|
1039
1051
|
fault(namespace: string, fault: WebhookFault): void;
|
|
1040
1052
|
clear(namespace?: string): void;
|
|
1041
1053
|
};
|
|
@@ -1079,6 +1091,8 @@ type ServiceRuntime<T extends ServiceInstance> = FetchAPI & {
|
|
|
1079
1091
|
/** Opaque in-process checkpoint including records, controls and webhook history. */
|
|
1080
1092
|
fleetSnapshot(namespace: string): object;
|
|
1081
1093
|
fleetRestore(snapshot: unknown, namespace: string): void;
|
|
1094
|
+
fleetExport(snapshot: unknown): SnapshotDocument;
|
|
1095
|
+
fleetImport(namespace: string, document: unknown): object;
|
|
1082
1096
|
/** Expand a named preset into fault rules (and webhook faults) for `namespace`. */
|
|
1083
1097
|
applyPreset(name: string, namespace?: string, overrides?: Partial<FaultRule>): FaultRule[];
|
|
1084
1098
|
/** The instance behind `namespace` (the default one when omitted), created on first use. */
|
package/dist/index.js
CHANGED
package/dist/server.d.ts
CHANGED
|
@@ -445,6 +445,8 @@ type SnapshotDocument$1 = {
|
|
|
445
445
|
faults?: unknown;
|
|
446
446
|
latency?: unknown;
|
|
447
447
|
virtualTime?: boolean;
|
|
448
|
+
/** Quiescent webhook endpoints, delivery history and fault state. Contains private configuration. */
|
|
449
|
+
webhooks?: unknown;
|
|
448
450
|
};
|
|
449
451
|
/** Controls for one namespace. */
|
|
450
452
|
type NamespaceControls$1 = {
|
|
@@ -658,6 +660,8 @@ type CredentialRegistry$1 = {
|
|
|
658
660
|
}[];
|
|
659
661
|
};
|
|
660
662
|
|
|
663
|
+
type OwnedTransport$1 = (request: Request, namespace: string, send: typeof fetch) => Promise<Response>;
|
|
664
|
+
|
|
661
665
|
/**
|
|
662
666
|
* A point-in-time copy of everything a service namespace holds.
|
|
663
667
|
*
|
|
@@ -775,8 +779,16 @@ type PublishInput$1 = {
|
|
|
775
779
|
id?: string;
|
|
776
780
|
};
|
|
777
781
|
type WebhookHub$1 = {
|
|
782
|
+
observeDeliveries(listener: (event: {
|
|
783
|
+
namespace: string;
|
|
784
|
+
state: string;
|
|
785
|
+
deliveryId: string;
|
|
786
|
+
}) => void): () => void;
|
|
787
|
+
setTransportPolicy(policy: OwnedTransport$1): void;
|
|
778
788
|
pending(namespace: string): number;
|
|
779
789
|
snapshot(namespace: string): unknown;
|
|
790
|
+
exportSnapshot(handle: unknown): unknown;
|
|
791
|
+
importSnapshot(namespace: string, document: unknown): unknown;
|
|
780
792
|
restore(namespace: string, snapshot: unknown): void;
|
|
781
793
|
publish(input: PublishInput$1): WebhookMessage$1;
|
|
782
794
|
/** Replace a namespace's own endpoints (`PUT /__admin/webhook-endpoints`). */
|
|
@@ -789,7 +801,7 @@ type WebhookHub$1 = {
|
|
|
789
801
|
/** Run every pending retry (and release held reordered messages) now, and every retry those attempts schedule, until nothing is pending. */
|
|
790
802
|
flush(): Promise<void>;
|
|
791
803
|
/** Resolve once nothing is in flight. */
|
|
792
|
-
idle(): Promise<void>;
|
|
804
|
+
idle(namespace?: string): Promise<void>;
|
|
793
805
|
fault(namespace: string, fault: WebhookFault$1): void;
|
|
794
806
|
clear(namespace?: string): void;
|
|
795
807
|
};
|
|
@@ -833,6 +845,8 @@ type ServiceRuntime$1<T extends ServiceInstance$1> = FetchAPI$2 & {
|
|
|
833
845
|
/** Opaque in-process checkpoint including records, controls and webhook history. */
|
|
834
846
|
fleetSnapshot(namespace: string): object;
|
|
835
847
|
fleetRestore(snapshot: unknown, namespace: string): void;
|
|
848
|
+
fleetExport(snapshot: unknown): SnapshotDocument$1;
|
|
849
|
+
fleetImport(namespace: string, document: unknown): object;
|
|
836
850
|
/** Expand a named preset into fault rules (and webhook faults) for `namespace`. */
|
|
837
851
|
applyPreset(name: string, namespace?: string, overrides?: Partial<FaultRule$1>): FaultRule$1[];
|
|
838
852
|
/** The instance behind `namespace` (the default one when omitted), created on first use. */
|
|
@@ -925,6 +939,7 @@ type CommonServeOptions = {
|
|
|
925
939
|
* `serveTarget`, which is also how `serve --config` finds services by name.
|
|
926
940
|
*/
|
|
927
941
|
type ServeTarget = {
|
|
942
|
+
packageVersion?: string;
|
|
928
943
|
name: string;
|
|
929
944
|
defaultPort: number;
|
|
930
945
|
/** Serve flags beyond the common ones. */
|
|
@@ -1435,6 +1450,8 @@ type SnapshotDocument = {
|
|
|
1435
1450
|
faults?: unknown;
|
|
1436
1451
|
latency?: unknown;
|
|
1437
1452
|
virtualTime?: boolean;
|
|
1453
|
+
/** Quiescent webhook endpoints, delivery history and fault state. Contains private configuration. */
|
|
1454
|
+
webhooks?: unknown;
|
|
1438
1455
|
};
|
|
1439
1456
|
/** Controls for one namespace. */
|
|
1440
1457
|
type NamespaceControls = {
|
|
@@ -1648,6 +1665,8 @@ type CredentialRegistry = {
|
|
|
1648
1665
|
}[];
|
|
1649
1666
|
};
|
|
1650
1667
|
|
|
1668
|
+
type OwnedTransport = (request: Request, namespace: string, send: typeof fetch) => Promise<Response>;
|
|
1669
|
+
|
|
1651
1670
|
/**
|
|
1652
1671
|
* A point-in-time copy of everything a service namespace holds.
|
|
1653
1672
|
*
|
|
@@ -1765,8 +1784,16 @@ type PublishInput = {
|
|
|
1765
1784
|
id?: string;
|
|
1766
1785
|
};
|
|
1767
1786
|
type WebhookHub = {
|
|
1787
|
+
observeDeliveries(listener: (event: {
|
|
1788
|
+
namespace: string;
|
|
1789
|
+
state: string;
|
|
1790
|
+
deliveryId: string;
|
|
1791
|
+
}) => void): () => void;
|
|
1792
|
+
setTransportPolicy(policy: OwnedTransport): void;
|
|
1768
1793
|
pending(namespace: string): number;
|
|
1769
1794
|
snapshot(namespace: string): unknown;
|
|
1795
|
+
exportSnapshot(handle: unknown): unknown;
|
|
1796
|
+
importSnapshot(namespace: string, document: unknown): unknown;
|
|
1770
1797
|
restore(namespace: string, snapshot: unknown): void;
|
|
1771
1798
|
publish(input: PublishInput): WebhookMessage;
|
|
1772
1799
|
/** Replace a namespace's own endpoints (`PUT /__admin/webhook-endpoints`). */
|
|
@@ -1779,7 +1806,7 @@ type WebhookHub = {
|
|
|
1779
1806
|
/** Run every pending retry (and release held reordered messages) now, and every retry those attempts schedule, until nothing is pending. */
|
|
1780
1807
|
flush(): Promise<void>;
|
|
1781
1808
|
/** Resolve once nothing is in flight. */
|
|
1782
|
-
idle(): Promise<void>;
|
|
1809
|
+
idle(namespace?: string): Promise<void>;
|
|
1783
1810
|
fault(namespace: string, fault: WebhookFault): void;
|
|
1784
1811
|
clear(namespace?: string): void;
|
|
1785
1812
|
};
|
|
@@ -1823,6 +1850,8 @@ type ServiceRuntime<T extends ServiceInstance> = FetchAPI$1 & {
|
|
|
1823
1850
|
/** Opaque in-process checkpoint including records, controls and webhook history. */
|
|
1824
1851
|
fleetSnapshot(namespace: string): object;
|
|
1825
1852
|
fleetRestore(snapshot: unknown, namespace: string): void;
|
|
1853
|
+
fleetExport(snapshot: unknown): SnapshotDocument;
|
|
1854
|
+
fleetImport(namespace: string, document: unknown): object;
|
|
1826
1855
|
/** Expand a named preset into fault rules (and webhook faults) for `namespace`. */
|
|
1827
1856
|
applyPreset(name: string, namespace?: string, overrides?: Partial<FaultRule>): FaultRule[];
|
|
1828
1857
|
/** The instance behind `namespace` (the default one when omitted), created on first use. */
|
package/dist/server.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@crvouga/mockingbird-service-slack",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.5.0",
|
|
4
4
|
"description": "Stateful emulator of Slack incoming webhooks, the Web API, and the Socket Mode control plane, with an outbox of every alert the app sent.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|