@k-msg/core 0.1.5 → 0.1.6

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.
@@ -0,0 +1,20 @@
1
+ import type { BaseProvider, ProviderHealthStatus, StandardRequest, StandardResult } from "../types/index";
2
+ /**
3
+ * Round-robin router provider that forwards requests to upstream providers.
4
+ * Useful for simple load distribution or provider rotation strategies.
5
+ */
6
+ export declare class RoundRobinRouterProvider implements BaseProvider<StandardRequest, StandardResult> {
7
+ readonly id: string;
8
+ readonly name: string;
9
+ readonly type: "messaging";
10
+ readonly version = "1.0.0";
11
+ private readonly providers;
12
+ private idx;
13
+ constructor(params: {
14
+ id: string;
15
+ name?: string;
16
+ providers: BaseProvider<StandardRequest, StandardResult>[];
17
+ });
18
+ healthCheck(): Promise<ProviderHealthStatus>;
19
+ send<T extends StandardRequest = StandardRequest, R extends StandardResult = StandardResult>(request: T): Promise<R>;
20
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@k-msg/core",
3
- "version": "0.1.5",
3
+ "version": "0.1.6",
4
4
  "packageManager": "bun@1.3.8",
5
5
  "description": "Core types and interfaces for K-Message platform",
6
6
  "type": "module",