@upstash/qstash 2.9.0 → 2.9.1-rc.1

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.
@@ -372,6 +372,43 @@ function decodeBase64(base64) {
372
372
  }
373
373
  }
374
374
  }
375
+ function buildBulkActionFilterPayload(request, options) {
376
+ const hasDlqIds = "dlqIds" in request && request.dlqIds !== void 0;
377
+ const hasAll = "all" in request && Boolean(request.all);
378
+ const filterKeys = Object.keys(request).filter((k) => k !== "dlqIds" && k !== "all");
379
+ const hasFilters = filterKeys.length > 0;
380
+ if (hasDlqIds && hasAll) {
381
+ throw new QstashError("dlqIds and all: true are mutually exclusive.");
382
+ }
383
+ if (hasDlqIds && hasFilters) {
384
+ throw new QstashError(
385
+ `dlqIds cannot be combined with filter fields: ${filterKeys.join(", ")}.`
386
+ );
387
+ }
388
+ if (hasAll && hasFilters) {
389
+ throw new QstashError(
390
+ `all: true cannot be combined with filter fields: ${filterKeys.join(", ")}.`
391
+ );
392
+ }
393
+ if (hasAll)
394
+ return {};
395
+ const { urlGroup, callerIp, ...rest } = request;
396
+ const payload = {
397
+ ...rest,
398
+ ...urlGroup === void 0 || typeof urlGroup !== "string" ? {} : { topicName: urlGroup },
399
+ ...callerIp === void 0 || typeof callerIp !== "string" ? {} : options?.callerIpCasing ? { callerIP: callerIp } : { callerIp }
400
+ };
401
+ if (Object.keys(payload).length === 0) {
402
+ throw new QstashError(
403
+ "No filters provided. Pass { all: true } to explicitly target all messages."
404
+ );
405
+ }
406
+ return payload;
407
+ }
408
+ function normalizeCursor(response) {
409
+ const cursor = response.cursor;
410
+ return { ...response, cursor: cursor || void 0 };
411
+ }
375
412
  function getRuntime() {
376
413
  if (typeof process === "object" && typeof process.versions == "object" && process.versions.bun)
377
414
  return `bun@${process.versions.bun}`;
@@ -601,17 +638,20 @@ var DLQ = class {
601
638
  /**
602
639
  * List messages in the dlq
603
640
  */
604
- async listMessages(options) {
641
+ async listMessages(options = {}) {
642
+ const { urlGroup, ...restFilter } = options.filter ?? {};
605
643
  const filterPayload = {
606
- ...options?.filter,
607
- topicName: options?.filter?.urlGroup
644
+ ...restFilter,
645
+ ...urlGroup === void 0 ? {} : { topicName: urlGroup }
608
646
  };
609
647
  const messagesPayload = await this.http.request({
610
648
  method: "GET",
611
649
  path: ["v2", "dlq"],
612
650
  query: {
613
- cursor: options?.cursor,
614
- count: options?.count,
651
+ cursor: options.cursor,
652
+ count: options.count,
653
+ order: options.order,
654
+ trimBody: options.trimBody,
615
655
  ...filterPayload
616
656
  }
617
657
  });
@@ -627,26 +667,70 @@ var DLQ = class {
627
667
  };
628
668
  }
629
669
  /**
630
- * Remove a message from the dlq using it's `dlqId`
670
+ * Remove messages from the dlq.
671
+ *
672
+ * Can be called with:
673
+ * - A single dlqId: `delete("id")`
674
+ * - An array of dlqIds: `delete(["id1", "id2"])`
675
+ * - An object with dlqIds: `delete({ dlqIds: ["id1", "id2"] })`
676
+ * - A filter object: `delete({ url: "https://example.com", label: "label" })`
677
+ * - All messages: `delete({ all: true })`
678
+ *
679
+ * Note: passing an empty array returns `{ deleted: 0 }` without making a request.
631
680
  */
632
- async delete(dlqMessageId) {
633
- return await this.http.request({
634
- method: "DELETE",
635
- path: ["v2", "dlq", dlqMessageId],
636
- parseResponseAsJson: false
637
- // there is no response
638
- });
681
+ async delete(request) {
682
+ if (typeof request === "string") {
683
+ await this.http.request({
684
+ method: "DELETE",
685
+ path: ["v2", "dlq", request],
686
+ parseResponseAsJson: false
687
+ });
688
+ return { deleted: 1 };
689
+ }
690
+ if (Array.isArray(request) && request.length === 0)
691
+ return { deleted: 0 };
692
+ const filters = Array.isArray(request) ? { dlqIds: request } : request;
693
+ return normalizeCursor(
694
+ await this.http.request({
695
+ method: "DELETE",
696
+ path: ["v2", "dlq"],
697
+ query: buildBulkActionFilterPayload(filters)
698
+ })
699
+ );
639
700
  }
640
701
  /**
641
702
  * Remove multiple messages from the dlq using their `dlqId`s
703
+ *
704
+ * @deprecated Use `delete` instead
642
705
  */
643
706
  async deleteMany(request) {
644
- return await this.http.request({
645
- method: "DELETE",
646
- path: ["v2", "dlq"],
647
- headers: { "Content-Type": "application/json" },
648
- body: JSON.stringify({ dlqIds: request.dlqIds })
649
- });
707
+ return await this.delete(request);
708
+ }
709
+ /**
710
+ * Retry messages from the dlq.
711
+ *
712
+ * Can be called with:
713
+ * - A single dlqId: `retry("id")`
714
+ * - An array of dlqIds: `retry(["id1", "id2"])`
715
+ * - An object with dlqIds: `retry({ dlqIds: ["id1", "id2"] })`
716
+ * - A filter object: `retry({ url: "https://example.com", label: "label" })`
717
+ * - All messages: `retry({ all: true })`
718
+ *
719
+ * Note: passing an empty array returns `{ responses: [] }` without making a request.
720
+ */
721
+ async retry(request) {
722
+ if (typeof request === "string")
723
+ request = [request];
724
+ if (Array.isArray(request) && request.length === 0)
725
+ return { responses: [] };
726
+ const filters = Array.isArray(request) ? { dlqIds: request } : request;
727
+ return normalizeCursor(
728
+ await this.http.request({
729
+ method: "POST",
730
+ path: ["v2", "dlq", "retry"],
731
+ query: buildBulkActionFilterPayload(filters)
732
+ })
733
+ );
650
734
  }
651
735
  };
652
736
 
@@ -747,7 +831,15 @@ var HttpClient = class {
747
831
  const url = new URL([request.baseUrl ?? this.baseUrl, ...request.path].join("/"));
748
832
  if (request.query) {
749
833
  for (const [key, value] of Object.entries(request.query)) {
750
- if (value !== void 0) {
834
+ if (value === void 0)
835
+ continue;
836
+ if (Array.isArray(value)) {
837
+ for (const item of value) {
838
+ url.searchParams.append(key, item);
839
+ }
840
+ } else if (value instanceof Date) {
841
+ url.searchParams.set(key, value.getTime().toString());
842
+ } else {
751
843
  url.searchParams.set(key, value.toString());
752
844
  }
753
845
  }
@@ -978,29 +1070,57 @@ var Messages = class {
978
1070
  return message;
979
1071
  }
980
1072
  /**
981
- * Cancel a message
1073
+ * Cancel messages.
1074
+ *
1075
+ * Can be called with:
1076
+ * - A single messageId: `cancel("id")`
1077
+ * - An array of messageIds: `cancel(["id1", "id2"])`
1078
+ * - A filter object: `cancel({ flowControlKey: "key", label: "label" })`
1079
+ * - All messages: `cancel({ all: true })`
982
1080
  */
983
- async delete(messageId) {
1081
+ async cancel(request) {
1082
+ if (typeof request === "string") {
1083
+ return await this.http.request({
1084
+ method: "DELETE",
1085
+ path: ["v2", "messages", request]
1086
+ });
1087
+ }
1088
+ if (Array.isArray(request) && request.length === 0)
1089
+ return { cancelled: 0 };
1090
+ const filters = Array.isArray(request) ? { messageIds: request } : request;
984
1091
  return await this.http.request({
1092
+ method: "DELETE",
1093
+ path: ["v2", "messages"],
1094
+ query: buildBulkActionFilterPayload(filters, { callerIpCasing: true })
1095
+ });
1096
+ }
1097
+ /**
1098
+ * Delete a message.
1099
+ *
1100
+ * @deprecated Use `cancel(messageId: string)` instead
1101
+ */
1102
+ async delete(messageId) {
1103
+ await this.http.request({
985
1104
  method: "DELETE",
986
1105
  path: ["v2", "messages", messageId],
987
1106
  parseResponseAsJson: false
988
1107
  });
989
1108
  }
1109
+ /**
1110
+ * Cancel multiple messages by their messageIds.
1111
+ *
1112
+ * @deprecated Use `cancel(messageIds: string[])` instead
1113
+ */
990
1114
  async deleteMany(messageIds) {
991
- const result = await this.http.request({
992
- method: "DELETE",
993
- path: ["v2", "messages"],
994
- headers: { "Content-Type": "application/json" },
995
- body: JSON.stringify({ messageIds })
996
- });
1115
+ const result = await this.cancel(messageIds);
997
1116
  return result.cancelled;
998
1117
  }
1118
+ /**
1119
+ * Cancel all messages
1120
+ * @deprecated Use `cancel({all: true})` to cancel all
1121
+ */
999
1122
  async deleteAll() {
1000
- const result = await this.http.request({
1001
- method: "DELETE",
1002
- path: ["v2", "messages"]
1003
- });
1123
+ const result = await this.cancel({ all: true });
1004
1124
  return result.cancelled;
1005
1125
  }
1006
1126
  };
@@ -1334,7 +1454,7 @@ var UrlGroups = class {
1334
1454
  };
1335
1455
 
1336
1456
  // version.ts
1337
- var VERSION = "v2.9.0";
1457
+ var VERSION = "v2.9.1-rc.1";
1338
1458
 
1339
1459
  // src/client/client.ts
1340
1460
  var Client = class {
@@ -1529,39 +1649,47 @@ var Client = class {
1529
1649
  * }
1530
1650
  * ```
1531
1651
  */
1532
- async logs(request) {
1533
- const query = {};
1534
- if (typeof request?.cursor === "number" && request.cursor > 0) {
1535
- query.cursor = request.cursor.toString();
1536
- } else if (typeof request?.cursor === "string" && request.cursor !== "") {
1537
- query.cursor = request.cursor;
1538
- }
1539
- for (const [key, value] of Object.entries(request?.filter ?? {})) {
1540
- if (typeof value === "number" && value < 0) {
1541
- continue;
1542
- }
1543
- if (key === "urlGroup") {
1544
- query.topicName = value.toString();
1545
- } else if (typeof value !== "undefined") {
1546
- query[key] = value.toString();
1547
- }
1548
- }
1652
+ async logs(request = {}) {
1653
+ const {
1654
+ urlGroup,
1655
+ // eslint-disable-next-line @typescript-eslint/no-deprecated
1656
+ topicName,
1657
+ fromDate,
1658
+ toDate,
1659
+ callerIp,
1660
+ messageIds,
1661
+ // eslint-disable-next-line @typescript-eslint/no-deprecated
1662
+ count: filterCount,
1663
+ ...restFilter
1664
+ } = request.filter ?? {};
1665
+ const filterPayload = {
1666
+ ...restFilter,
1667
+ topicName: urlGroup ?? topicName,
1668
+ fromDate,
1669
+ toDate,
1670
+ callerIp
1671
+ };
1672
+ let cursorString;
1673
+ if (typeof request.cursor === "number" && request.cursor > 0) {
1674
+ cursorString = request.cursor.toString();
1675
+ } else if (typeof request.cursor === "string" && request.cursor !== "") {
1676
+ cursorString = request.cursor;
1677
+ }
1678
+ const query = {
1679
+ cursor: cursorString,
1680
+ count: request.count ?? filterCount,
1681
+ order: request.order,
1682
+ trimBody: request.trimBody,
1683
+ messageIds,
1684
+ ...filterPayload
1685
+ };
1549
1686
  const responsePayload = await this.http.request({
1550
1687
  path: ["v2", "events"],
1551
1688
  method: "GET",
1552
1689
  query
1553
1690
  });
1554
- const logs = responsePayload.events.map((event) => {
1555
- return {
1556
- ...event,
1557
- urlGroup: event.topicName
1558
- };
1559
- });
1560
- return {
1561
- cursor: responsePayload.cursor,
1562
- logs,
1563
- events: logs
1564
- };
1691
+ const logs = responsePayload.events.map((event) => ({ ...event, urlGroup: event.topicName }));
1692
+ return { cursor: responsePayload.cursor, logs, events: logs };
1565
1693
  }
1566
1694
  /**
1567
1695
  * @deprecated Will be removed in the next major release. Use the `logs` method instead.
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  BaseProvider
3
- } from "./chunk-QYBCXZKB.mjs";
3
+ } from "./chunk-RUCOF5QZ.mjs";
4
4
 
5
5
  // src/client/api/email.ts
6
6
  var EmailProvider = class extends BaseProvider {
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  Receiver,
3
3
  serve
4
- } from "./chunk-QYBCXZKB.mjs";
4
+ } from "./chunk-RUCOF5QZ.mjs";
5
5
 
6
6
  // node_modules/defu/dist/defu.mjs
7
7
  function isPlainObject(value) {
@@ -103,7 +103,7 @@ type LogPayload = Omit<Log, "urlGroup"> & {
103
103
  topicName: string;
104
104
  };
105
105
  /**
106
- * Deprecated. Use the `EventPayload` type instead.
106
+ * Deprecated. Use the `LogPayload` type instead.
107
107
  *
108
108
  * @deprecated
109
109
  */
@@ -464,7 +464,7 @@ type UpstashRequest = {
464
464
  * A string to set request's method.
465
465
  */
466
466
  method?: HTTPMethods;
467
- query?: Record<string, string | number | boolean | undefined>;
467
+ query?: Record<string, string | number | boolean | Date | string[] | undefined>;
468
468
  /**
469
469
  * if enabled, call `res.json()`
470
470
  *
@@ -505,6 +505,81 @@ type RetryConfig = false | {
505
505
  backoff?: (retryCount: number) => number;
506
506
  };
507
507
 
508
+ type NeverAll<T> = {
509
+ [K in keyof T]?: never;
510
+ };
511
+ type RequireAtLeastOne<T> = {
512
+ [K in keyof T]-?: Required<Pick<T, K>>;
513
+ }[keyof T];
514
+ /**
515
+ * Three-way exclusive union: at-least-one-filter OR `{ all: true }` OR IDs.
516
+ * Exactly one branch can be satisfied at a time.
517
+ *
518
+ * The filter and all branches intentionally omit `NeverAll<Ids>` so that
519
+ * TypeScript's `"key" in request` narrowing correctly isolates the IDs branch.
520
+ * Excess-property checks on object literals still prevent mixing ID keys with filters.
521
+ */
522
+ type FilterAllOrIds<F extends Record<string, unknown>, Ids extends Record<string, unknown>> = (F & RequireAtLeastOne<F> & {
523
+ all?: never;
524
+ }) | ({
525
+ all: true;
526
+ } & NeverAll<F>) | (Ids & NeverAll<F> & {
527
+ all?: never;
528
+ });
529
+ /** Shared filter fields accepted by every qstash & workflow endpoint. */
530
+ type UniversalFilterFields = {
531
+ /**
532
+ * aslkdjasd
533
+ */
534
+ fromDate?: Date | number;
535
+ toDate?: Date | number;
536
+ callerIp?: string;
537
+ label?: string;
538
+ flowControlKey?: string;
539
+ };
540
+ /** QStash-specific identity filters (DLQ + message endpoints). */
541
+ type QStashIdentityFields = {
542
+ messageId?: string;
543
+ url?: string;
544
+ urlGroup?: string;
545
+ scheduleId?: string;
546
+ queueName?: string;
547
+ };
548
+ /** DLQ-specific response filter. */
549
+ type DLQResponseFields = {
550
+ responseStatus?: number;
551
+ };
552
+ /** Logs-specific filter fields exclusive to log endpoints. */
553
+ type LogsFilterFields = {
554
+ state?: State;
555
+ messageIds?: string[];
556
+ };
557
+ /**
558
+ * Doesn't allow a single messageId because this is a bulk action
559
+ */
560
+ type MessageCancelFilters = FilterAllOrIds<UniversalFilterFields & Omit<QStashIdentityFields, "messageId">, {
561
+ messageIds: string[];
562
+ }>;
563
+ type DLQBulkActionFilters = FilterAllOrIds<UniversalFilterFields & QStashIdentityFields & DLQResponseFields, {
564
+ dlqIds: string | string[];
565
+ }>;
566
+ type DLQListFilters = UniversalFilterFields & QStashIdentityFields & DLQResponseFields;
567
+ type LogsListFilters = UniversalFilterFields & QStashIdentityFields & LogsFilterFields & {
568
+ /**
569
+ * @deprecated use `urlGroup` instead
570
+ */
571
+ topicName?: string;
572
+ /**
573
+ * @deprecated use `count` option in the root instead of the `filter` object
574
+ *
575
+ * Example:
576
+ * ```ts
577
+ * await client.logs({ count: 50 })
578
+ * ```
579
+ */
580
+ count?: number;
581
+ };
582
+
508
583
  type Message = {
509
584
  /**
510
585
  * A unique identifier for this message.
@@ -627,10 +702,33 @@ declare class Messages {
627
702
  */
628
703
  get(messageId: string): Promise<Message>;
629
704
  /**
630
- * Cancel a message
705
+ * Cancel messages.
706
+ *
707
+ * Can be called with:
708
+ * - A single messageId: `cancel("id")`
709
+ * - An array of messageIds: `cancel(["id1", "id2"])`
710
+ * - A filter object: `cancel({ flowControlKey: "key", label: "label" })`
711
+ * - All messages: `cancel({ all: true })`
712
+ */
713
+ cancel(request: string | string[] | MessageCancelFilters): Promise<{
714
+ cancelled: number;
715
+ }>;
716
+ /**
717
+ * Delete a message.
718
+ *
719
+ * @deprecated Use `cancel(messageId: string)` instead
631
720
  */
632
721
  delete(messageId: string): Promise<void>;
722
+ /**
723
+ * Cancel multiple messages by their messageIds.
724
+ *
725
+ * @deprecated Use `cancel(messageIds: string[])` instead
726
+ */
633
727
  deleteMany(messageIds: string[]): Promise<number>;
728
+ /**
729
+ * Cancel all messages
730
+ * @deprecated Use `cancel({all: true})` to cancel all
731
+ */
634
732
  deleteAll(): Promise<number>;
635
733
  }
636
734
 
@@ -658,52 +756,6 @@ type DlqMessage = Message & {
658
756
  */
659
757
  responseBodyBase64?: string;
660
758
  };
661
- type DLQFilter = {
662
- /**
663
- * Filter DLQ entries by message id
664
- */
665
- messageId?: string;
666
- /**
667
- * Filter DLQ entries by url
668
- */
669
- url?: string;
670
- /**
671
- * Filter DLQ entries by url group name
672
- */
673
- urlGroup?: string;
674
- /**
675
- * Filter DLQ entries by api name
676
- */
677
- api?: string;
678
- /**
679
- * Filter DLQ entries by queue name
680
- */
681
- queueName?: string;
682
- /**
683
- * Filter DLQ entries by schedule id
684
- */
685
- scheduleId?: string;
686
- /**
687
- * Filter DLQ entries by starting time, in milliseconds
688
- */
689
- fromDate?: number;
690
- /**
691
- * Filter DLQ entries by ending time, in milliseconds
692
- */
693
- toDate?: number;
694
- /**
695
- * Filter DLQ entries by label
696
- */
697
- label?: string;
698
- /**
699
- * Filter DLQ entries by HTTP status of the response
700
- */
701
- responseStatus?: number;
702
- /**
703
- * Filter DLQ entries by IP address of the publisher of the message
704
- */
705
- callerIp?: string;
706
- };
707
759
  declare class DLQ {
708
760
  private readonly http;
709
761
  constructor(http: Requester);
@@ -713,22 +765,58 @@ declare class DLQ {
713
765
  listMessages(options?: {
714
766
  cursor?: string;
715
767
  count?: number;
716
- filter?: DLQFilter;
768
+ /** Defaults to `latestFirst` */
769
+ order?: "earliestFirst" | "latestFirst";
770
+ trimBody?: number;
771
+ filter?: DLQListFilters;
717
772
  }): Promise<{
718
773
  messages: DlqMessage[];
719
774
  cursor?: string;
720
775
  }>;
721
776
  /**
722
- * Remove a message from the dlq using it's `dlqId`
777
+ * Remove messages from the dlq.
778
+ *
779
+ * Can be called with:
780
+ * - A single dlqId: `delete("id")`
781
+ * - An array of dlqIds: `delete(["id1", "id2"])`
782
+ * - An object with dlqIds: `delete({ dlqIds: ["id1", "id2"] })`
783
+ * - A filter object: `delete({ url: "https://example.com", label: "label" })`
784
+ * - All messages: `delete({ all: true })`
785
+ *
786
+ * Note: passing an empty array returns `{ deleted: 0 }` without making a request.
723
787
  */
724
- delete(dlqMessageId: string): Promise<void>;
788
+ delete(request: string | string[] | DLQBulkActionFilters): Promise<{
789
+ deleted: number;
790
+ cursor?: string;
791
+ }>;
725
792
  /**
726
793
  * Remove multiple messages from the dlq using their `dlqId`s
794
+ *
795
+ * @deprecated Use `delete` instead
727
796
  */
728
797
  deleteMany(request: {
729
798
  dlqIds: string[];
730
799
  }): Promise<{
731
800
  deleted: number;
801
+ cursor?: string;
802
+ }>;
803
+ /**
804
+ * Retry messages from the dlq.
805
+ *
806
+ * Can be called with:
807
+ * - A single dlqId: `retry("id")`
808
+ * - An array of dlqIds: `retry(["id1", "id2"])`
809
+ * - An object with dlqIds: `retry({ dlqIds: ["id1", "id2"] })`
810
+ * - A filter object: `retry({ url: "https://example.com", label: "label" })`
811
+ * - All messages: `retry({ all: true })`
812
+ *
813
+ * Note: passing an empty array returns `{ responses: [] }` without making a request.
814
+ */
815
+ retry(request: string | string[] | DLQBulkActionFilters): Promise<{
816
+ cursor?: string;
817
+ responses: {
818
+ messageId: string;
819
+ }[];
732
820
  }>;
733
821
  }
734
822
 
@@ -2034,7 +2122,12 @@ type PublishJsonRequest = Omit<PublishRequest, "body"> & {
2034
2122
  };
2035
2123
  type LogsRequest = {
2036
2124
  cursor?: string | number;
2037
- filter?: LogsRequestFilter;
2125
+ /** Max 1000. Defaults to 10 when `groupBy` is used. */
2126
+ count?: number;
2127
+ /** Defaults to `latestFirst` */
2128
+ order?: "earliestFirst" | "latestFirst";
2129
+ trimBody?: number;
2130
+ filter?: LogsListFilters;
2038
2131
  };
2039
2132
  /**
2040
2133
  * Deprecated. Use `LogsRequest` instead.
@@ -2042,20 +2135,6 @@ type LogsRequest = {
2042
2135
  * @deprecated
2043
2136
  */
2044
2137
  type EventsRequest = LogsRequest;
2045
- type LogsRequestFilter = {
2046
- messageId?: string;
2047
- state?: State;
2048
- url?: string;
2049
- urlGroup?: string;
2050
- topicName?: string;
2051
- api?: string;
2052
- scheduleId?: string;
2053
- queueName?: string;
2054
- fromDate?: number;
2055
- toDate?: number;
2056
- count?: number;
2057
- label?: string;
2058
- };
2059
2138
  type GetLogsResponse = {
2060
2139
  cursor?: string;
2061
2140
  logs: Log[];
@@ -2206,4 +2285,4 @@ type PublishResponse<TRequest> = TRequest extends {
2206
2285
  urlGroup: string;
2207
2286
  } ? PublishToUrlGroupsResponse : PublishToApiResponse;
2208
2287
 
2209
- export { type StreamEnabled as $, type AddEndpointsRequest as A, BaseProvider as B, type ChatRateLimit as C, type EventPayload as D, type EmailOwner as E, type FailureFunctionPayload as F, type GetLogsResponse as G, type HTTPMethods as H, type GetLogsPayload as I, type GetEventsPayload as J, type BodyInit as K, type LLMOwner as L, type Message as M, type HeadersInit as N, type RequestOptions as O, type ProviderInfo as P, type QueueRequest as Q, type RateLimit as R, type Step as S, type FlowControl as T, type UrlGroup as U, type VerifyRequest as V, type WithCursor as W, Chat as X, type ChatCompletionMessage as Y, type ChatCompletion as Z, type ChatCompletionChunk as _, type ReceiverConfig as a, type StreamDisabled as a0, type StreamParameter as a1, type OpenAIChatModel as a2, type PromptChatRequest as a3, type ChatRequest as a4, upstash as a5, openai as a6, anthropic as a7, custom as a8, type RouteFunction as a9, type WorkflowServeOptions as aa, Workflow as ab, processOptions as ac, serve as ad, WorkflowContext as ae, DisabledWorkflowContext as af, type WorkflowClient as ag, type WorkflowReceiver as ah, StepTypes as ai, type StepType as aj, type RawStep as ak, type SyncStepFunction as al, type AsyncStepFunction as am, type StepFunction as an, type ParallelCallState as ao, type FinishCondition as ap, type RequiredExceptFields as aq, type LogLevel as ar, type WorkflowLoggerOptions as as, WorkflowLogger as at, SignatureError as b, Receiver as c, type PublishBatchRequest as d, type PublishRequest as e, type PublishJsonRequest as f, type LogsRequest as g, type EventsRequest as h, type GetEventsResponse as i, Client as j, type PublishToApiResponse as k, type PublishToUrlResponse as l, type PublishToUrlGroupsResponse as m, type PublishResponse as n, type MessagePayload as o, Messages as p, type Schedule as q, type CreateScheduleRequest as r, Schedules as s, type Endpoint as t, type RemoveEndpointsRequest as u, UrlGroups as v, type State as w, type Log as x, type Event as y, type LogPayload as z };
2288
+ export { type ChatCompletionChunk as $, type AddEndpointsRequest as A, BaseProvider as B, type ChatRateLimit as C, type LogPayload as D, type EmailOwner as E, type FailureFunctionPayload as F, type GetLogsResponse as G, type HTTPMethods as H, type EventPayload as I, type GetLogsPayload as J, type GetEventsPayload as K, type LLMOwner as L, type Message as M, type BodyInit as N, type HeadersInit as O, type ProviderInfo as P, type QueueRequest as Q, type RateLimit as R, type Step as S, type RequestOptions as T, type UniversalFilterFields as U, type VerifyRequest as V, type WithCursor as W, type FlowControl as X, Chat as Y, type ChatCompletionMessage as Z, type ChatCompletion as _, type ReceiverConfig as a, type StreamEnabled as a0, type StreamDisabled as a1, type StreamParameter as a2, type OpenAIChatModel as a3, type PromptChatRequest as a4, type ChatRequest as a5, upstash as a6, openai as a7, anthropic as a8, custom as a9, type RouteFunction as aa, type WorkflowServeOptions as ab, Workflow as ac, processOptions as ad, serve as ae, WorkflowContext as af, DisabledWorkflowContext as ag, type WorkflowClient as ah, type WorkflowReceiver as ai, StepTypes as aj, type StepType as ak, type RawStep as al, type SyncStepFunction as am, type AsyncStepFunction as an, type StepFunction as ao, type ParallelCallState as ap, type FinishCondition as aq, type RequiredExceptFields as ar, type LogLevel as as, type WorkflowLoggerOptions as at, WorkflowLogger as au, SignatureError as b, Receiver as c, type PublishBatchRequest as d, type PublishRequest as e, type PublishJsonRequest as f, type LogsRequest as g, type EventsRequest as h, type GetEventsResponse as i, Client as j, type PublishToApiResponse as k, type PublishToUrlResponse as l, type PublishToUrlGroupsResponse as m, type PublishResponse as n, type MessagePayload as o, Messages as p, type Schedule as q, type CreateScheduleRequest as r, Schedules as s, type Endpoint as t, type RemoveEndpointsRequest as u, type UrlGroup as v, UrlGroups as w, type State as x, type Log as y, type Event as z };