@crvouga/mockingbird-service-slack 3.2.0 → 3.3.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/dist/index.d.ts CHANGED
@@ -172,6 +172,11 @@ type ProviderOptions = APIOptions$1 & {
172
172
  fallbackUser?: AuthFallback;
173
173
  publicNamespace?: string;
174
174
  adminPrefix?: string;
175
+ /**
176
+ * A seeded stream of `[0, 1)` that ids and tokens are minted from, so a run replays from
177
+ * its seed. Default: the platform's randomness.
178
+ */
179
+ random?: () => number;
175
180
  };
176
181
 
177
182
  type MountedAPI = FetchAPI & {
@@ -373,7 +378,7 @@ type ClockState = {
373
378
  now: number;
374
379
  /** True while time does not advance on its own. */
375
380
  frozen: boolean;
376
- /** Milliseconds this clock adds to its underlying source. */
381
+ /** Milliseconds a running clock adds to its underlying source. `0` while frozen. */
377
382
  offsetMs: number;
378
383
  };
379
384
  type Clock = {
@@ -409,7 +414,10 @@ type Rng = {
409
414
  state(): number;
410
415
  /** Restore a state previously returned by {@link state}. */
411
416
  setState(state: number): void;
412
- seed: number;
417
+ /** Restart the stream from a new seed. `reset` then returns to this seed. */
418
+ reseed(seed: number | string): void;
419
+ /** The seed the stream currently starts from. */
420
+ readonly seed: number;
413
421
  };
414
422
 
415
423
  /**
@@ -418,44 +426,83 @@ type Rng = {
418
426
  * This is how a suite reaches the vendor's failure modes without the vendor: the
419
427
  * quota error that only appears when a shared sandbox is full, the 429 that only
420
428
  * appears under load, the 5xx that proves a retry path works.
429
+ *
430
+ * A rule has three parts. What it **matches** (`operationId`, `method`, `path`, …), **when**
431
+ * it fires among the matching requests (`after`, `every`, `count`, `rate`, `from`, `until`),
432
+ * and what it **does** (`status`, `delay`, `timeout`, `drop`, `truncate`, `effect`).
421
433
  */
422
434
  type FaultRule = {
423
- /** Stable id, so a suite can retire exactly the rule it added. */
435
+ /** Stable id, so a suite can retire exactly the rule it added. Unique within a namespace. */
424
436
  id: string;
425
437
  /** Fault only this operation. Omit to match every operation. */
426
438
  operationId?: string;
427
439
  /** Fault only this HTTP method, case-insensitive. Omit to match every method. */
428
440
  method?: string;
441
+ /** Fault only this exact path. */
442
+ path?: string;
429
443
  /** Fault only paths starting with this prefix. Omit to match every path. */
430
444
  pathPrefix?: string;
445
+ /** Fault only paths matching this regular expression (JavaScript syntax, unanchored). */
446
+ pathPattern?: string;
447
+ /** Fault only requests carrying these headers. `"*"` matches any value. */
448
+ requestHeaders?: Record<string, string>;
449
+ /** Fault only requests carrying these query parameters. `"*"` matches any value. */
450
+ query?: Record<string, string>;
431
451
  /**
432
452
  * Fault only this namespace. Omit (or `"*"`) to fault every namespace — which is what
433
453
  * an in-process caller usually wants, and what a parallel worker usually does not:
434
454
  * rules added through `POST /__admin/faults` default to the calling namespace.
435
455
  */
436
456
  namespace?: string;
457
+ /** Let this many matching requests through first. */
458
+ after?: number;
459
+ /** Then fault only every nth matching request: `3` faults the 3rd, 6th, 9th. */
460
+ every?: number;
461
+ /** Retire the rule after this many faults. Omit to keep it until removed. */
462
+ count?: number;
463
+ /** Fault this fraction of the remaining requests, `0`–`1`, drawn from the seed. Default `1`. */
464
+ rate?: number;
437
465
  /**
438
- * Status of the injected response. Omit for a rule that only delays (`delayMs` /
439
- * `latencyMs`), only drops the connection (`drop`), or only switches on an `effect`:
440
- * the request then still reaches the service.
466
+ * Fault only from this instant on the namespace clock. A duration (`"5m"`) counts from the
467
+ * clock when the rule was added. Listed as epoch ms.
468
+ */
469
+ from?: Instant | Duration;
470
+ /** Stop faulting at this instant on the namespace clock. A duration counts from when added. */
471
+ until?: Instant | Duration;
472
+ /**
473
+ * Status of the injected response. Omit for a rule that only delays, times out, drops,
474
+ * truncates, or switches on an `effect`: the request then still reaches the service.
441
475
  */
442
476
  status?: number;
443
477
  /** Response body, serialized as JSON. A string is sent as-is. */
444
478
  body?: unknown;
479
+ /** Response headers. */
445
480
  headers?: Record<string, string>;
446
- /** Retire the rule after this many faults. Omit to keep it until removed. */
447
- count?: number;
448
- /** Fault this fraction of matching requests, `0`–`1`. Default `1`. */
449
- rate?: number;
450
- /** Hold the response back this long, to exercise timeouts. */
481
+ /** Hold the response back this long. Listed as `delayMs`. */
482
+ delay?: Duration;
483
+ /** `delay`, in milliseconds. */
451
484
  delayMs?: number;
452
485
  /** Alias of `delayMs`. */
453
486
  latencyMs?: number;
487
+ /** Extra seeded delay in `[0, jitter]`. Listed as `jitterMs`. */
488
+ jitter?: Duration;
489
+ jitterMs?: number;
490
+ /**
491
+ * Never answer: hold the request this long, then drop the connection. Listed as
492
+ * `timeoutMs`. With virtual time the wait is spent on the mock clock.
493
+ */
494
+ timeout?: Duration;
495
+ timeoutMs?: number;
454
496
  /**
455
497
  * Drop the connection instead of answering: an in-process `fetch` rejects with a
456
498
  * `TypeError`, and a served mock destroys the socket. Models "unknown outcome" failures.
457
499
  */
458
500
  drop?: boolean;
501
+ /**
502
+ * Cut the response body off after this many bytes: the status and headers arrive, then
503
+ * the connection dies mid-body.
504
+ */
505
+ truncate?: number;
459
506
  /**
460
507
  * A named service behaviour to switch on for the matching request instead of (or
461
508
  * before) a canned response, e.g. `created_but_500` or `numeric_tracking_id`. Services
@@ -464,8 +511,8 @@ type FaultRule = {
464
511
  effect?: string;
465
512
  /** Parameters for `effect`. */
466
513
  params?: Record<string, unknown>;
467
- /** From the preset this rule was expanded from, if any. */
468
- preset?: string;
514
+ /** The preset this rule was expanded from, if any. */
515
+ fromPreset?: string;
469
516
  };
470
517
  /** A fault that fired for one request. */
471
518
  type FaultHit = {
@@ -473,6 +520,10 @@ type FaultHit = {
473
520
  /** The injected response; absent when the rule only delays, drops, or sets an effect. */
474
521
  response?: Response;
475
522
  drop?: boolean;
523
+ /** Set with `drop` when the rule held the request for its `timeout` first. */
524
+ timeout?: boolean;
525
+ /** Bytes of response body to let through before the connection dies. */
526
+ truncate?: number;
476
527
  effect?: {
477
528
  name: string;
478
529
  params: Record<string, unknown>;
@@ -497,38 +548,200 @@ type FaultCandidate = {
497
548
  method: string;
498
549
  path: string;
499
550
  namespace: string;
551
+ /** Request headers and query, for rules that match on them. */
552
+ headers?: Headers;
553
+ query?: URLSearchParams;
554
+ /** The namespace clock, for `from` / `until`. Rules with a window are skipped without it. */
555
+ now?: number;
556
+ /** How to spend a delay for this request. Default: the registry's own sleep. */
557
+ wait?: (ms: number) => Promise<void>;
558
+ };
559
+ /** A stored rule and how often it was consulted. */
560
+ type FaultListing = FaultRule & {
561
+ /** Faults left before the rule retires. `null` when it has no `count`. */
562
+ remaining: number | null;
563
+ /** Times the rule faulted a request. */
564
+ hits: number;
565
+ /** Requests that matched the rule, faulted or not. */
566
+ seen: number;
567
+ };
568
+ /** A namespace's own rules, with their counters, in the order they are tried. */
569
+ type FaultSnapshot = {
570
+ /**
571
+ * `position` is how many `"*"` rules are tried before the rule, which is what its place
572
+ * in the order means to a request and holds in any process.
573
+ */
574
+ rules: (FaultListing & {
575
+ position?: number;
576
+ })[];
577
+ /** How many `fault_<n>` ids the namespace has handed out. */
578
+ nextId?: number;
500
579
  };
501
580
  type FaultRegistry = {
502
- isolateNamespaces(): void;
503
- snapshot(namespace: string): {
504
- rules: (FaultRule & {
505
- remaining: number | null;
506
- hits: number;
507
- position: number;
508
- })[];
509
- rngState: number;
510
- };
581
+ snapshot(namespace: string): FaultSnapshot;
582
+ /** Add a rule, or replace the rule with the same id in the same namespace. */
511
583
  add(rule: FaultRule): FaultRule;
512
- list(): (FaultRule & {
513
- remaining: number | null;
514
- hits: number;
515
- })[];
516
- remove(id: string): boolean;
517
- clear(): void;
518
- restore(namespace: string, state: {
519
- rules: (FaultRule & {
520
- remaining: number | null;
521
- hits: number;
522
- position: number;
523
- })[];
524
- rngState: number;
525
- }): void;
584
+ /** The next unused `fault_<n>` id in `namespace`. */
585
+ nextId(namespace: string): string;
586
+ /** Every rule, or the rules a namespace's requests can hit: its own and the global ones. */
587
+ list(namespace?: string): FaultListing[];
588
+ get(id: string, namespace?: string): FaultListing | undefined;
589
+ /** Remove a rule by id: from `namespace` (its own, then a global one), or wherever it is. */
590
+ remove(id: string, namespace?: string): boolean;
591
+ /** Remove every rule, or one namespace's own rules. */
592
+ clear(namespace?: string): void;
593
+ /** Replace a namespace's own rules with a snapshot's, wherever the snapshot was taken. */
594
+ restore(namespace: string, state: FaultSnapshot): void;
526
595
  /**
527
596
  * Every fault this request should get, in rule order, stopping at the first that answers
528
597
  * or drops (effect-only and delay-only rules let later rules match too). Consumes one of
529
598
  * each matching rule's remaining uses.
530
599
  */
531
600
  take(candidate: FaultCandidate): Promise<FaultHit[]>;
601
+ /**
602
+ * Fire these rules at one request without storing them: no matching, no schedule, in order,
603
+ * stopping at the first that answers or drops. Jitter draws from the namespace's stream.
604
+ */
605
+ fire(rules: readonly FaultRule[], candidate: FaultCandidate): Promise<FaultHit[]>;
606
+ };
607
+
608
+ /**
609
+ * The admin controls every mock shares, as one document.
610
+ *
611
+ * The same shape is accepted in three places, and means the same thing in each:
612
+ *
613
+ * - at boot: `createRuntime({ adminControls })`, `serve --admin-controls`,
614
+ * `MOCKINGBIRD_ADMIN_CONTROLS`
615
+ * - over HTTP: `PUT /__admin/controls`
616
+ * - per request: the `x-mockingbird-*` headers in {@link CONTROL_HEADERS}
617
+ *
618
+ * Every control is deterministic: given the same seed, clock and requests, a mock answers
619
+ * the same bytes. Nothing here reads the wall clock or `Math.random`.
620
+ */
621
+ /** Milliseconds, or a string like `"250ms"`, `"2s"`, `"15m"`, `"1h"`, `"3d"`. */
622
+ type Duration = number | string;
623
+ /** Epoch milliseconds, or an ISO-8601 string. */
624
+ type Instant = number | string;
625
+ type ClockControls = {
626
+ /** Move the clock to this instant. */
627
+ now?: Instant;
628
+ /** Stop time. A frozen clock moves only when told to, so timestamps replay exactly. */
629
+ frozen?: boolean;
630
+ /**
631
+ * Step the clock forward by this much before every vendor request. With a frozen clock
632
+ * each request still gets its own, reproducible timestamp.
633
+ */
634
+ autoAdvance?: Duration;
635
+ };
636
+ /** How long a response takes: a fixed delay plus seeded jitter in `[0, jitter]`. */
637
+ type LatencyRuleInput = {
638
+ delay?: Duration;
639
+ jitter?: Duration;
640
+ };
641
+ type LatencyControls = LatencyRuleInput & {
642
+ /** Per-operation overrides, keyed by operationId. A bare duration is its `delay`. */
643
+ operations?: Record<string, Duration | LatencyRuleInput>;
644
+ };
645
+ /** A fault to add: a rule (the id is assigned when omitted), or a named preset with overrides. */
646
+ type FaultInput = (Omit<FaultRule, "id"> & {
647
+ id?: string;
648
+ }) | ({
649
+ preset: string;
650
+ } & Partial<FaultRule>);
651
+ /** Identifies a {@link SnapshotDocument}. */
652
+ declare const SNAPSHOT_FORMAT = "mockingbird.snapshot/v1";
653
+ /**
654
+ * A namespace, as portable JSON: what `GET /__admin/snapshots/:id` returns and what
655
+ * `PUT /__admin/snapshots/:id` and the boot `snapshot` control accept. Only `format` and
656
+ * `records` are required, so a hand-written seed file is a valid snapshot.
657
+ */
658
+ type SnapshotDocument = {
659
+ format: typeof SNAPSHOT_FORMAT;
660
+ /** The service that wrote it. A snapshot is rejected by any other service. */
661
+ service?: string;
662
+ /**
663
+ * Stored rows. `seq` orders a collection; omitted, rows keep their listed order. `raw` is
664
+ * the stored text of a row that is not a plain record, and replaces `value` when present.
665
+ */
666
+ records: {
667
+ collection: string;
668
+ id: string;
669
+ seq?: number;
670
+ value?: unknown;
671
+ raw?: string;
672
+ }[];
673
+ /** Id counters, so the next generated id continues where the snapshot left off. */
674
+ sequences?: {
675
+ name: string;
676
+ kind: string;
677
+ value: number;
678
+ }[];
679
+ clock?: {
680
+ now: number;
681
+ frozen: boolean;
682
+ autoAdvanceMs?: number;
683
+ };
684
+ seed?: number | string;
685
+ /** Positions of the seeded random streams. */
686
+ rng?: {
687
+ state: number;
688
+ faults?: number;
689
+ latency?: number;
690
+ };
691
+ faults?: unknown;
692
+ latency?: unknown;
693
+ virtualTime?: boolean;
694
+ };
695
+ /** Controls for one namespace. */
696
+ type NamespaceControls = {
697
+ /** Seeds every random choice: fault rates, jitter, and whatever the service invents. */
698
+ seed?: number | string;
699
+ clock?: ClockControls;
700
+ /**
701
+ * Spend injected waits (latency, fault delays, timeouts) on the mock clock instead of the
702
+ * wall clock: the request returns at once, the clock has moved, and the journal records
703
+ * the wait exactly. Default `false`: waits are real, so a client's own timeout can fire.
704
+ */
705
+ virtualTime?: boolean;
706
+ /** Baseline response time for every vendor request. A bare duration is its `delay`. */
707
+ latency?: Duration | LatencyControls;
708
+ faults?: readonly FaultInput[];
709
+ /** Start from this state instead of the service's own seed data. */
710
+ snapshot?: SnapshotDocument;
711
+ };
712
+ /** {@link NamespaceControls} for every namespace, with per-namespace overrides. */
713
+ type MockControls = NamespaceControls & {
714
+ /** Vendor credential → namespace, for SDKs that cannot send a namespace header. */
715
+ credentials?: Record<string, string>;
716
+ /** Overrides for named namespaces. A key given here replaces the shared value. */
717
+ namespaces?: Record<string, NamespaceControls>;
718
+ };
719
+ /** A latency rule in milliseconds. */
720
+ type LatencyRule = {
721
+ delayMs: number;
722
+ jitterMs: number;
723
+ };
724
+ /** Baseline latency for a namespace, normalized. */
725
+ type LatencyState = LatencyRule & {
726
+ operations: Record<string, LatencyRule>;
727
+ };
728
+ /** What {@link controlHeaders} turns into request headers. */
729
+ type ControlHeaderInput = {
730
+ namespace?: string;
731
+ adminKey?: string;
732
+ branch?: string;
733
+ at?: string;
734
+ reset?: boolean;
735
+ restore?: string;
736
+ seed?: number | string;
737
+ time?: Instant | Date;
738
+ advance?: Duration;
739
+ virtualTime?: boolean;
740
+ delay?: Duration;
741
+ timeout?: Duration;
742
+ /** A status, `"drop"`, a preset name, or a fault rule. */
743
+ fault?: number | string | Record<string, unknown>;
744
+ snapshot?: string;
532
745
  };
533
746
 
534
747
  /**
@@ -568,6 +781,8 @@ type RequestLog = {
568
781
  unmatched: boolean;
569
782
  /** Set when a fault rule produced the response. */
570
783
  faultId?: string;
784
+ /** Milliseconds of injected wait: latency, fault delays and timeouts. Absent when none. */
785
+ delayMs?: number;
571
786
  /** Resource ids the handler touched (`userId`, `orderId`, …), when the service reports them. */
572
787
  ids?: Record<string, string>;
573
788
  /** Set when the service created a resource the request referred to but that did not exist. */
@@ -613,6 +828,12 @@ type JournalQuery = {
613
828
  /** Only this namespace. Omit for every namespace, oldest first across all of them. */
614
829
  namespace?: string;
615
830
  operationId?: string;
831
+ /** Only this HTTP method, case-insensitive. */
832
+ method?: string;
833
+ /** Only this exact path. */
834
+ path?: string;
835
+ /** Only requests this fault rule answered or shaped. */
836
+ faultId?: string;
616
837
  status?: number;
617
838
  /** Only entries at or after this instant (epoch ms). */
618
839
  since?: number;
@@ -627,6 +848,50 @@ type Journal = {
627
848
  clear(namespace?: string): void;
628
849
  };
629
850
 
851
+ /**
852
+ * Baseline response time, per namespace: how long every vendor request takes before any
853
+ * fault is considered. Jitter draws from a stream the caller owns, one per namespace and
854
+ * separate from the fault stream, so adding latency never shifts which requests a `rate`
855
+ * fault hits.
856
+ */
857
+ type LatencyRegistry = {
858
+ get(namespace: string): LatencyState;
859
+ set(namespace: string, state: LatencyState): LatencyState;
860
+ /** Remove one namespace's latency, or every namespace's. */
861
+ clear(namespace?: string): void;
862
+ /** Milliseconds this request waits. Draws jitter, so call it once per request. */
863
+ take(namespace: string, operationId: string | undefined): number;
864
+ };
865
+
866
+ /** Clock state as the admin API reports it. */
867
+ type ControlClock = ClockState & {
868
+ /** `now`, as ISO-8601. */
869
+ iso: string;
870
+ /** Milliseconds the clock steps before every vendor request. */
871
+ autoAdvanceMs: number;
872
+ };
873
+ /** One namespace's controls: the body of `GET /__admin/controls`. */
874
+ type ControlState = {
875
+ namespace: string;
876
+ seed: number | string;
877
+ clock: ControlClock;
878
+ virtualTime: boolean;
879
+ latency: LatencyState;
880
+ faults: FaultListing[];
881
+ };
882
+
883
+ /** What `GET /__admin/snapshots` lists for each snapshot. */
884
+ type SnapshotInfo = {
885
+ id: string;
886
+ namespace: string;
887
+ /** Stored rows in the snapshot. */
888
+ records: number;
889
+ /** The namespace clock when it was taken, epoch ms. */
890
+ at: number;
891
+ /** Whether `GET /snapshots/:id` can return it as a {@link SnapshotDocument}. */
892
+ portable: boolean;
893
+ };
894
+
630
895
  /** Credential → namespace mapping behind `PUT /__admin/credentials`. */
631
896
  type CredentialRegistry = {
632
897
  set(credential: string, namespace: string): void;
@@ -781,7 +1046,10 @@ type ServiceInstance = FetchAPI & {
781
1046
  };
782
1047
  type ServiceTimelineState = Readonly<{
783
1048
  snapshot: NamespaceSnapshot;
784
- clock: Readonly<ReturnType<Clock["state"]>>;
1049
+ /** `pinned`: the namespace's clock was frozen itself, not just following a frozen base. */
1050
+ clock: Readonly<ClockState & {
1051
+ pinned?: boolean;
1052
+ }>;
785
1053
  rngState: number;
786
1054
  }>;
787
1055
  type ServiceCheckpoint = Checkpoint<ServiceTimelineState>;
@@ -794,14 +1062,18 @@ type ServiceRuntime<T extends ServiceInstance> = FetchAPI & {
794
1062
  readonly sqlite: SqliteClient$1;
795
1063
  readonly clock: Clock;
796
1064
  readonly faults: FaultRegistry;
1065
+ /** Baseline response time per namespace. */
1066
+ readonly latency: LatencyRegistry;
797
1067
  readonly metrics: Metrics;
798
1068
  readonly journal: Journal;
799
1069
  readonly rng: Rng;
800
1070
  readonly credentials: CredentialRegistry;
801
1071
  /** The webhook hub, when the service has outbound webhooks. */
802
1072
  readonly webhooks: WebhookHub | undefined;
803
- /** Enable independent namespace clocks and PRNGs before serving a fleet. */
804
- isolateNamespaces(): void;
1073
+ /**
1074
+ * A namespace's clock. Each follows the base clock, {@link ServiceRuntime.clock}, with an
1075
+ * offset and a freeze of its own, so moving one never moves another.
1076
+ */
805
1077
  namespaceClock(namespace?: string): Clock;
806
1078
  namespaceOf(request: Request): string;
807
1079
  /** Opaque in-process checkpoint including records, controls and webhook history. */
@@ -813,8 +1085,38 @@ type ServiceRuntime<T extends ServiceInstance> = FetchAPI & {
813
1085
  instance(namespace?: string): T;
814
1086
  /** Public names of every namespace created so far. */
815
1087
  namespaces(): string[];
816
- /** Reset one namespace, or every namespace with `"*"`. */
1088
+ /** Return one namespace to its boot state, or every namespace with `"*"`. */
817
1089
  reset(namespace?: string): Promise<void>;
1090
+ /** Reset a namespace and forget it, releasing everything it held. */
1091
+ dropNamespace(namespace: string): Promise<void>;
1092
+ /** A namespace's controls: seed, clock, virtual time, latency, faults and snapshots. */
1093
+ controls(namespace?: string): ControlState & {
1094
+ snapshots: SnapshotInfo[];
1095
+ };
1096
+ /** Apply a control document to a namespace. A given key replaces that control. */
1097
+ configure(controls: NamespaceControls, namespace?: string): ControlState & {
1098
+ snapshots: SnapshotInfo[];
1099
+ };
1100
+ /** Named snapshots of a namespace: records, clock, random streams, faults and latency. */
1101
+ readonly snapshots: {
1102
+ /** Capture the namespace now. Reusing a name replaces that snapshot. */
1103
+ create(options?: {
1104
+ name?: string;
1105
+ namespace?: string;
1106
+ }): SnapshotInfo;
1107
+ list(namespace?: string): SnapshotInfo[];
1108
+ /** The snapshot as portable JSON, to commit beside a suite or boot another mock from. */
1109
+ export(id: string, namespace?: string): SnapshotDocument;
1110
+ /** Store a document as a snapshot without restoring it. */
1111
+ import(document: SnapshotDocument, options?: {
1112
+ name?: string;
1113
+ namespace?: string;
1114
+ }): SnapshotInfo;
1115
+ restore(id: string, namespace?: string): void;
1116
+ delete(id: string, namespace?: string): boolean;
1117
+ };
1118
+ /** Request headers that carry controls, checked: spread them into a `fetch` or an SDK's defaults. */
1119
+ headers(input: ControlHeaderInput): Record<string, string>;
818
1120
  snapshot(namespace?: string): NamespaceSnapshot;
819
1121
  restore(snapshot: NamespaceSnapshot, namespace?: string): void;
820
1122
  /** Capture the current branch. Mutating HTTP calls do this automatically. */
@@ -1214,6 +1516,8 @@ type SlackRuntimeOptions = Pick<SlackAPIOptions, "fixtures" | "baseUrl" | "token
1214
1516
  seed?: number | string;
1215
1517
  adminPrefix?: string;
1216
1518
  adminKey?: string;
1519
+ /** Admin controls to boot with: clock, latency, faults, seed, a starting snapshot. */
1520
+ adminControls?: MockControls;
1217
1521
  onLog?: (entry: RequestLog) => void;
1218
1522
  settings?: Partial<Settings>;
1219
1523
  };
@@ -1226,7 +1530,7 @@ type SlackRuntime = ServiceRuntime<SlackAPI>;
1226
1530
  declare const createRuntime: (options?: SlackRuntimeOptions) => SlackRuntime;
1227
1531
 
1228
1532
  declare const SLACK_NAMESPACE = "slack";
1229
- type SlackAPIOptions = APIOptions & Pick<ProviderOptions, "tokens" | "baseUrl" | "publicNamespace" | "adminPrefix"> & {
1533
+ type SlackAPIOptions = APIOptions & Pick<ProviderOptions, "tokens" | "baseUrl" | "publicNamespace" | "adminPrefix" | "random"> & {
1230
1534
  fixtures?: SlackSeedConfig;
1231
1535
  /** Initial per-namespace settings (workspace identity, accepted tokens, strict channels). */
1232
1536
  settings?: Partial<Settings>;
package/dist/index.js CHANGED
@@ -11,8 +11,8 @@ import {
11
11
  operationIds,
12
12
  slackCredential,
13
13
  supportedOperationIds
14
- } from "./chunk-B4MV67Z4.js";
15
- import "./chunk-M73LWCCP.js";
14
+ } from "./chunk-6MIIKZZB.js";
15
+ import "./chunk-6Z2MR3PO.js";
16
16
  export {
17
17
  DEFAULT_CHANNELS,
18
18
  DEFAULT_FILES,