@omnicross/core 0.1.2 → 0.1.4

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.
Files changed (184) hide show
  1. package/LICENSE +21 -21
  2. package/NOTICE +57 -57
  3. package/README.md +15 -15
  4. package/dist/auth/GeminiCodeAssistProjectResolver.cjs +6 -1
  5. package/dist/auth/GeminiCodeAssistProjectResolver.js +6 -1
  6. package/dist/chunk-3QFXFCHG.js +33 -0
  7. package/dist/chunk-4IH4EL7M.cjs +9 -0
  8. package/dist/chunk-4YINUUKQ.cjs +33 -0
  9. package/dist/chunk-5ENKBSWO.js +311 -0
  10. package/dist/chunk-6RPZADX3.cjs +92 -0
  11. package/dist/chunk-7Y47UCF2.js +142 -0
  12. package/dist/chunk-AEOZIDEB.cjs +32 -0
  13. package/dist/chunk-APYG5QD7.cjs +50 -0
  14. package/dist/{chunk-MNYKI4CI.js → chunk-BPKCU575.js} +29 -0
  15. package/dist/{chunk-SN3YWBX7.cjs → chunk-DKPXN34V.cjs} +2108 -538
  16. package/dist/{chunk-4NBS6KPV.cjs → chunk-DQ5VAYZ6.cjs} +7 -8
  17. package/dist/chunk-E3UCVHLP.cjs +142 -0
  18. package/dist/chunk-FCR77GYM.cjs +33 -0
  19. package/dist/{chunk-74TMJA7Z.js → chunk-HRRYG2AX.js} +8 -4
  20. package/dist/chunk-HUZZZ3JL.js +32 -0
  21. package/dist/{chunk-KUU2RNG6.cjs → chunk-HYN75H6G.cjs} +3 -0
  22. package/dist/{chunk-QOCNX236.js → chunk-IAXWICZU.js} +24 -1
  23. package/dist/{chunk-JO5NLTLY.js → chunk-IK3KE3AU.js} +3 -0
  24. package/dist/{chunk-V5KPWNYX.cjs → chunk-JMJBSACD.cjs} +3 -3
  25. package/dist/chunk-K5NM7VAH.js +33 -0
  26. package/dist/{chunk-N3V2J5ZO.cjs → chunk-KFI44N2R.cjs} +8 -4
  27. package/dist/chunk-L74VDN4A.cjs +32 -0
  28. package/dist/chunk-OCEUVQHW.cjs +112 -0
  29. package/dist/chunk-OE6TDIWW.js +22 -0
  30. package/dist/chunk-OZFM4X3S.js +18 -0
  31. package/dist/{chunk-LKZJEL6E.cjs → chunk-Q27JY5RG.cjs} +6 -4
  32. package/dist/{chunk-SPVWWUHX.cjs → chunk-QWBWGODS.cjs} +24 -1
  33. package/dist/{chunk-2FEVTJWG.js → chunk-QYTT6GE3.js} +1929 -359
  34. package/dist/{chunk-UYPEN5XE.cjs → chunk-RGTR7CIO.cjs} +6 -6
  35. package/dist/chunk-RPII3E6Z.cjs +145 -0
  36. package/dist/{chunk-XBSYYZIY.cjs → chunk-SNYBEXLB.cjs} +31 -2
  37. package/dist/{chunk-2DCNB7DF.cjs → chunk-SU2GCLAC.cjs} +30 -10
  38. package/dist/{chunk-5HTVET6E.js → chunk-TIER4SUC.js} +24 -4
  39. package/dist/chunk-TKJMZBAH.js +32 -0
  40. package/dist/{chunk-ZSVQT3PW.js → chunk-UBWEBKRC.js} +5 -6
  41. package/dist/chunk-UHGVBFU3.js +385 -0
  42. package/dist/chunk-UIBD2YY5.cjs +22 -0
  43. package/dist/chunk-UNEFIWXI.cjs +32 -0
  44. package/dist/chunk-VACWOIRE.cjs +385 -0
  45. package/dist/{chunk-O466Y272.js → chunk-VPBAUQ2M.js} +7 -7
  46. package/dist/chunk-VQY5W4YW.cjs +311 -0
  47. package/dist/chunk-WLYIIEAF.js +50 -0
  48. package/dist/chunk-WNY4WMRF.js +32 -0
  49. package/dist/chunk-XEKD23J5.js +9 -0
  50. package/dist/chunk-XK5CIRMQ.js +112 -0
  51. package/dist/chunk-XSVNC2UD.cjs +18 -0
  52. package/dist/chunk-XTEI64OU.js +145 -0
  53. package/dist/chunk-XX6NQJMA.js +92 -0
  54. package/dist/{chunk-745DV5FL.js → chunk-Y7FO65VT.js} +3 -3
  55. package/dist/{chunk-PXUJF5HS.js → chunk-ZY6KU6P3.js} +4 -2
  56. package/dist/completion/CompletionService.cjs +30 -17
  57. package/dist/completion/CompletionService.js +29 -16
  58. package/dist/completion/NativeSearchInjector.cjs +3 -3
  59. package/dist/completion/NativeSearchInjector.js +2 -2
  60. package/dist/completion/openrouter-headers.cjs +3 -6
  61. package/dist/completion/openrouter-headers.d.cts +9 -12
  62. package/dist/completion/openrouter-headers.d.ts +9 -12
  63. package/dist/completion/openrouter-headers.js +2 -5
  64. package/dist/completion/openrouter-models.cjs +4 -3
  65. package/dist/completion/openrouter-models.js +2 -1
  66. package/dist/completion.cjs +30 -17
  67. package/dist/completion.js +29 -16
  68. package/dist/index.cjs +151 -20
  69. package/dist/index.d.cts +44 -10
  70. package/dist/index.d.ts +44 -10
  71. package/dist/index.js +160 -29
  72. package/dist/keyPolicy-Cp0FntZl.d.cts +90 -0
  73. package/dist/keyPolicy-Cp0FntZl.d.ts +90 -0
  74. package/dist/outbound-api/auditCapture.cjs +9 -0
  75. package/dist/outbound-api/auditCapture.d.cts +52 -0
  76. package/dist/outbound-api/auditCapture.d.ts +52 -0
  77. package/dist/outbound-api/auditCapture.js +9 -0
  78. package/dist/outbound-api/auditRedact.cjs +8 -0
  79. package/dist/outbound-api/auditRedact.d.cts +30 -0
  80. package/dist/outbound-api/auditRedact.d.ts +30 -0
  81. package/dist/outbound-api/auditRedact.js +8 -0
  82. package/dist/outbound-api/billingCapture.cjs +8 -0
  83. package/dist/outbound-api/billingCapture.d.cts +61 -0
  84. package/dist/outbound-api/billingCapture.d.ts +61 -0
  85. package/dist/outbound-api/billingCapture.js +8 -0
  86. package/dist/outbound-api/quotaWarn.cjs +12 -0
  87. package/dist/outbound-api/quotaWarn.d.cts +43 -0
  88. package/dist/outbound-api/quotaWarn.d.ts +43 -0
  89. package/dist/outbound-api/quotaWarn.js +12 -0
  90. package/dist/outbound-api/routeResolver.cjs +5 -2
  91. package/dist/outbound-api/routeResolver.d.cts +9 -2
  92. package/dist/outbound-api/routeResolver.d.ts +9 -2
  93. package/dist/outbound-api/routeResolver.js +4 -1
  94. package/dist/outbound-api/types.cjs +6 -1
  95. package/dist/outbound-api/types.d.cts +12 -144
  96. package/dist/outbound-api/types.d.ts +12 -144
  97. package/dist/outbound-api/types.js +6 -0
  98. package/dist/outbound-api.cjs +144 -17
  99. package/dist/outbound-api.d.cts +655 -25
  100. package/dist/outbound-api.d.ts +655 -25
  101. package/dist/outbound-api.js +148 -21
  102. package/dist/pipeline/AuthSource.d.cts +29 -1
  103. package/dist/pipeline/AuthSource.d.ts +29 -1
  104. package/dist/pipeline/LlmConfigProviderAuth.cjs +3 -3
  105. package/dist/pipeline/LlmConfigProviderAuth.js +2 -2
  106. package/dist/pipeline/SubscriptionAccountHealth.cjs +22 -0
  107. package/dist/pipeline/SubscriptionAccountHealth.d.cts +235 -0
  108. package/dist/pipeline/SubscriptionAccountHealth.d.ts +235 -0
  109. package/dist/pipeline/SubscriptionAccountHealth.js +22 -0
  110. package/dist/pipeline/SubscriptionAuthSource.cjs +2 -2
  111. package/dist/pipeline/SubscriptionAuthSource.d.cts +3 -2
  112. package/dist/pipeline/SubscriptionAuthSource.d.ts +3 -2
  113. package/dist/pipeline/SubscriptionAuthSource.js +1 -1
  114. package/dist/pipeline/SubscriptionAuthStrategy.d.cts +30 -1
  115. package/dist/pipeline/SubscriptionAuthStrategy.d.ts +30 -1
  116. package/dist/pipeline/auditSink.cjs +14 -0
  117. package/dist/pipeline/auditSink.d.cts +48 -0
  118. package/dist/pipeline/auditSink.d.ts +48 -0
  119. package/dist/pipeline/auditSink.js +14 -0
  120. package/dist/pipeline/auditUsageStash.cjs +10 -0
  121. package/dist/pipeline/auditUsageStash.d.cts +37 -0
  122. package/dist/pipeline/auditUsageStash.d.ts +37 -0
  123. package/dist/pipeline/auditUsageStash.js +10 -0
  124. package/dist/pipeline/billingEmit.cjs +14 -0
  125. package/dist/pipeline/billingEmit.d.cts +49 -0
  126. package/dist/pipeline/billingEmit.d.ts +49 -0
  127. package/dist/pipeline/billingEmit.js +14 -0
  128. package/dist/pipeline/executeProviderCall.cjs +2 -2
  129. package/dist/pipeline/executeProviderCall.js +1 -1
  130. package/dist/pipeline/upstreamFetch.cjs +14 -0
  131. package/dist/pipeline/upstreamFetch.d.cts +83 -0
  132. package/dist/pipeline/upstreamFetch.d.ts +83 -0
  133. package/dist/pipeline/upstreamFetch.js +14 -0
  134. package/dist/pipeline/webhookEmit.cjs +10 -0
  135. package/dist/pipeline/webhookEmit.d.cts +36 -0
  136. package/dist/pipeline/webhookEmit.d.ts +36 -0
  137. package/dist/pipeline/webhookEmit.js +10 -0
  138. package/dist/ports/usage-event-store.d.cts +26 -1
  139. package/dist/ports/usage-event-store.d.ts +26 -1
  140. package/dist/ports.d.cts +8 -1
  141. package/dist/ports.d.ts +8 -1
  142. package/dist/provider-proxy/ProviderProxy.cjs +30 -17
  143. package/dist/provider-proxy/ProviderProxy.js +29 -16
  144. package/dist/provider-proxy/identity/SubscriptionIdentityStore.cjs +15 -0
  145. package/dist/provider-proxy/identity/SubscriptionIdentityStore.d.cts +121 -0
  146. package/dist/provider-proxy/identity/SubscriptionIdentityStore.d.ts +121 -0
  147. package/dist/provider-proxy/identity/SubscriptionIdentityStore.js +15 -0
  148. package/dist/provider-proxy/identity/fingerprintHeaders.cjs +20 -0
  149. package/dist/provider-proxy/identity/fingerprintHeaders.d.cts +89 -0
  150. package/dist/provider-proxy/identity/fingerprintHeaders.d.ts +89 -0
  151. package/dist/provider-proxy/identity/fingerprintHeaders.js +20 -0
  152. package/dist/provider-proxy/ingress/providerProxyShared.cjs +30 -17
  153. package/dist/provider-proxy/ingress/providerProxyShared.d.cts +11 -2
  154. package/dist/provider-proxy/ingress/providerProxyShared.d.ts +11 -2
  155. package/dist/provider-proxy/ingress/providerProxyShared.js +29 -16
  156. package/dist/provider-proxy/matchText.cjs +4 -2
  157. package/dist/provider-proxy/matchText.d.cts +14 -1
  158. package/dist/provider-proxy/matchText.d.ts +14 -1
  159. package/dist/provider-proxy/matchText.js +3 -1
  160. package/dist/provider-proxy/types.d.cts +30 -0
  161. package/dist/provider-proxy/types.d.ts +30 -0
  162. package/dist/provider-proxy.cjs +30 -17
  163. package/dist/provider-proxy.js +29 -16
  164. package/dist/{routeResolver-HE-ZO0fO.d.ts → routeResolver-C4T7yClx.d.ts} +36 -10
  165. package/dist/{routeResolver-BrbK6ja9.d.cts → routeResolver-CB3tvJKy.d.cts} +36 -10
  166. package/dist/transformer/transformers/OpenAIResponseTransformer.cjs +2 -2
  167. package/dist/transformer/transformers/OpenAIResponseTransformer.js +1 -1
  168. package/dist/transformer/transformers.cjs +7 -7
  169. package/dist/transformer/transformers.js +8 -8
  170. package/dist/transformer.cjs +9 -9
  171. package/dist/transformer.js +8 -8
  172. package/dist/types-B8Arpxn0.d.cts +754 -0
  173. package/dist/types-lgPYQuZS.d.ts +754 -0
  174. package/dist/usage/usage-recorder.cjs +3 -2
  175. package/dist/usage/usage-recorder.d.cts +19 -1
  176. package/dist/usage/usage-recorder.d.ts +19 -1
  177. package/dist/usage/usage-recorder.js +2 -1
  178. package/dist/usage.cjs +3 -2
  179. package/dist/usage.js +2 -1
  180. package/package.json +64 -62
  181. package/dist/chunk-3MEACFK3.js +0 -193
  182. package/dist/chunk-6VIXXLMX.cjs +0 -14
  183. package/dist/chunk-E3WHL7CO.js +0 -14
  184. package/dist/chunk-G2FUJNA2.cjs +0 -193
package/dist/index.cjs CHANGED
@@ -32,48 +32,97 @@
32
32
 
33
33
 
34
34
 
35
- var _chunkSN3YWBX7cjs = require('./chunk-SN3YWBX7.cjs');
36
- require('./chunk-SPVWWUHX.cjs');
37
35
 
38
36
 
39
37
 
40
- var _chunkHQP3K7PUcjs = require('./chunk-HQP3K7PU.cjs');
41
- require('./chunk-FZ46M34D.cjs');
42
38
 
43
39
 
44
- var _chunk46ZIFWYGcjs = require('./chunk-46ZIFWYG.cjs');
45
- require('./chunk-GBHYAGX3.cjs');
40
+
41
+
42
+
43
+
44
+
45
+
46
+
47
+
48
+
49
+
50
+
51
+
52
+
53
+
54
+
55
+
56
+
57
+
58
+
59
+
60
+
61
+
62
+
63
+
64
+
65
+
66
+
67
+
68
+
69
+
70
+
71
+
72
+
73
+
74
+ var _chunkDKPXN34Vcjs = require('./chunk-DKPXN34V.cjs');
75
+
76
+
77
+
78
+ var _chunkHQP3K7PUcjs = require('./chunk-HQP3K7PU.cjs');
79
+ require('./chunk-FZ46M34D.cjs');
46
80
 
47
81
 
48
82
  var _chunk3OPYJG76cjs = require('./chunk-3OPYJG76.cjs');
49
83
 
50
84
 
51
- var _chunkUYPEN5XEcjs = require('./chunk-UYPEN5XE.cjs');
52
- require('./chunk-7YN22L2H.cjs');
53
- require('./chunk-2DCNB7DF.cjs');
54
- require('./chunk-C72S6TTV.cjs');
85
+ var _chunkRGTR7CIOcjs = require('./chunk-RGTR7CIO.cjs');
55
86
  require('./chunk-DWKQZ2SK.cjs');
56
87
  require('./chunk-4VAVYUZS.cjs');
88
+ require('./chunk-7YN22L2H.cjs');
89
+ require('./chunk-SU2GCLAC.cjs');
90
+ require('./chunk-C72S6TTV.cjs');
57
91
  require('./chunk-EYZYXJTJ.cjs');
58
92
 
59
93
 
60
94
  var _chunkYMFAJFQTcjs = require('./chunk-YMFAJFQT.cjs');
61
95
 
62
96
 
63
- var _chunkXBSYYZIYcjs = require('./chunk-XBSYYZIY.cjs');
97
+ var _chunkSNYBEXLBcjs = require('./chunk-SNYBEXLB.cjs');
98
+
99
+
100
+ var _chunk46ZIFWYGcjs = require('./chunk-46ZIFWYG.cjs');
101
+ require('./chunk-GBHYAGX3.cjs');
102
+ require('./chunk-RPII3E6Z.cjs');
103
+ require('./chunk-6RPZADX3.cjs');
104
+ require('./chunk-QWBWGODS.cjs');
105
+ require('./chunk-UIBD2YY5.cjs');
64
106
  require('./chunk-R3HK6R4B.cjs');
65
- require('./chunk-KUU2RNG6.cjs');
107
+ require('./chunk-HYN75H6G.cjs');
66
108
 
67
109
 
68
- var _chunkLKZJEL6Ecjs = require('./chunk-LKZJEL6E.cjs');
110
+ var _chunkQ27JY5RGcjs = require('./chunk-Q27JY5RG.cjs');
69
111
  require('./chunk-QXD4MV2X.cjs');
70
112
  require('./chunk-NYUNU75A.cjs');
71
- require('./chunk-N3V2J5ZO.cjs');
113
+ require('./chunk-VQY5W4YW.cjs');
114
+ require('./chunk-KFI44N2R.cjs');
72
115
 
73
116
 
74
117
  var _chunkSVNDB62Dcjs = require('./chunk-SVNDB62D.cjs');
75
118
 
76
119
 
120
+ var _chunkAPYG5QD7cjs = require('./chunk-APYG5QD7.cjs');
121
+ require('./chunk-L74VDN4A.cjs');
122
+ require('./chunk-4YINUUKQ.cjs');
123
+
124
+
125
+
77
126
 
78
127
 
79
128
 
@@ -82,16 +131,38 @@ var _chunkSVNDB62Dcjs = require('./chunk-SVNDB62D.cjs');
82
131
 
83
132
 
84
133
 
85
- var _chunkA2YMUCBTcjs = require('./chunk-A2YMUCBT.cjs');
86
134
 
87
135
 
88
136
 
89
137
 
90
138
 
91
- var _chunkG2FUJNA2cjs = require('./chunk-G2FUJNA2.cjs');
139
+ var _chunkVACWOIREcjs = require('./chunk-VACWOIRE.cjs');
92
140
  require('./chunk-QBZJ7P2T.cjs');
93
141
 
94
142
 
143
+ var _chunk4IH4EL7Mcjs = require('./chunk-4IH4EL7M.cjs');
144
+
145
+
146
+
147
+
148
+
149
+
150
+
151
+
152
+
153
+
154
+ var _chunkA2YMUCBTcjs = require('./chunk-A2YMUCBT.cjs');
155
+
156
+
157
+ var _chunkE3UCVHLPcjs = require('./chunk-E3UCVHLP.cjs');
158
+
159
+
160
+
161
+ var _chunkFCR77GYMcjs = require('./chunk-FCR77GYM.cjs');
162
+ require('./chunk-AEOZIDEB.cjs');
163
+ require('./chunk-XSVNC2UD.cjs');
164
+
165
+
95
166
 
96
167
 
97
168
 
@@ -104,6 +175,7 @@ require('./chunk-QBZJ7P2T.cjs');
104
175
  var _chunkSUEGJ75Dcjs = require('./chunk-SUEGJ75D.cjs');
105
176
  require('./chunk-RSJ3TWJQ.cjs');
106
177
  require('./chunk-YGXJGRFI.cjs');
178
+ require('./chunk-OCEUVQHW.cjs');
107
179
 
108
180
 
109
181
 
@@ -112,14 +184,73 @@ var _chunkNZYN7C3Pcjs = require('./chunk-NZYN7C3P.cjs');
112
184
 
113
185
 
114
186
 
115
- var _chunkV5KPWNYXcjs = require('./chunk-V5KPWNYX.cjs');
187
+ var _chunkJMJBSACDcjs = require('./chunk-JMJBSACD.cjs');
188
+
189
+
190
+ var _chunkGMMT7RVNcjs = require('./chunk-GMMT7RVN.cjs');
191
+
192
+
193
+
194
+
195
+
196
+ var _chunkUNEFIWXIcjs = require('./chunk-UNEFIWXI.cjs');
197
+
198
+
199
+
200
+
201
+
202
+
203
+
204
+
205
+
206
+
207
+
208
+
209
+
210
+
211
+
212
+
213
+
214
+
215
+
216
+
217
+
218
+
219
+
220
+
221
+
222
+
223
+
224
+
225
+
226
+
227
+
228
+
229
+
230
+
231
+
232
+
233
+
234
+
235
+
236
+
237
+
238
+
239
+
240
+
241
+
242
+
243
+
244
+
245
+
246
+
247
+
248
+
116
249
 
117
250
 
118
251
 
119
- var _chunk6VIXXLMXcjs = require('./chunk-6VIXXLMX.cjs');
120
252
 
121
253
 
122
- var _chunkGMMT7RVNcjs = require('./chunk-GMMT7RVN.cjs');
123
254
 
124
255
 
125
256
 
@@ -194,4 +325,4 @@ var _chunkGMMT7RVNcjs = require('./chunk-GMMT7RVN.cjs');
194
325
 
195
326
 
196
327
 
197
- exports.BuiltinToolExecutor = _chunkNZYN7C3Pcjs.BuiltinToolExecutor; exports.CompletionService = _chunkSN3YWBX7cjs.CompletionService; exports.DEFAULT_OUTBOUND_PORT = _chunkSN3YWBX7cjs.DEFAULT_OUTBOUND_PORT; exports.DEFAULT_ROUTE_IDLE_MS = _chunkSN3YWBX7cjs.DEFAULT_ROUTE_IDLE_MS; exports.NATIVE_SEARCH_TOOL_NAMES = _chunkGMMT7RVNcjs.NATIVE_SEARCH_TOOL_NAMES; exports.OPENROUTER_APP_HEADERS = _chunk6VIXXLMXcjs.OPENROUTER_APP_HEADERS; exports.OUTBOUND_API_SERVER_CONFIG_KEY = _chunkSN3YWBX7cjs.OUTBOUND_API_SERVER_CONFIG_KEY; exports.OutboundApiServer = _chunkSN3YWBX7cjs.OutboundApiServer; exports.OutboundRateLimiter = _chunkSN3YWBX7cjs.OutboundRateLimiter; exports.PricingEngine = _chunkYMFAJFQTcjs.PricingEngine; exports.ProviderProxy = _chunkSN3YWBX7cjs.ProviderProxy; exports.ProviderProxyRouteMap = _chunkSN3YWBX7cjs.ProviderProxyRouteMap; exports.SUBSCRIPTION_PROVIDER_IDS = _chunkG2FUJNA2cjs.SUBSCRIPTION_PROVIDER_IDS; exports.TransformerChainExecutor = _chunk46ZIFWYGcjs.TransformerChainExecutor; exports.TransformerService = _chunk3OPYJG76cjs.TransformerService; exports.UsageRecorder = _chunkXBSYYZIYcjs.UsageRecorder; exports.__resetOutboundApiServerForTests = _chunkSN3YWBX7cjs.__resetOutboundApiServerForTests; exports.__resetProviderProxyForTests = _chunkSN3YWBX7cjs.__resetProviderProxyForTests; exports.addOpenRouterProviderToRequest = _chunkSN3YWBX7cjs.addOpenRouterProviderToRequest; exports.applyAugmentation = _chunkV5KPWNYXcjs.applyAugmentation; exports.attachStreamEventBuffer = _chunkSN3YWBX7cjs.attach; exports.buildAnthropicApiUrl = _chunkA2YMUCBTcjs.buildAnthropicApiUrl; exports.buildAzureOpenAIApiUrl = _chunkA2YMUCBTcjs.buildAzureOpenAIApiUrl; exports.buildGeminiApiUrl = _chunkA2YMUCBTcjs.buildGeminiApiUrl; exports.buildNativeSearchAugmentation = _chunkV5KPWNYXcjs.buildNativeSearchAugmentation; exports.buildOpenAIApiUrl = _chunkA2YMUCBTcjs.buildOpenAIApiUrl; exports.buildOpenAIResponseApiUrl = _chunkA2YMUCBTcjs.buildOpenAIResponseApiUrl; exports.buildProviderApiUrl = _chunkA2YMUCBTcjs.buildProviderApiUrl; exports.convertAnthropicRequestToOpenAI = _chunkSUEGJ75Dcjs.convertAnthropicRequestToOpenAI; exports.convertAnthropicStreamToOpenAI = _chunkSUEGJ75Dcjs.convertAnthropicStreamToOpenAI; exports.convertAnthropicToOpenAI = _chunkSUEGJ75Dcjs.convertAnthropicToOpenAI; exports.convertAnthropicToOpenAIWithThinking = _chunkSUEGJ75Dcjs.convertAnthropicToOpenAIWithThinking; exports.convertMessageToAnthropic = _chunkSN3YWBX7cjs.convertMessageToAnthropic; exports.convertMessageToGemini = _chunkSN3YWBX7cjs.convertMessageToGemini; exports.convertMessageToOpenAI = _chunkSN3YWBX7cjs.convertMessageToOpenAI; exports.convertOpenAIResponseToAnthropic = _chunkSUEGJ75Dcjs.convertOpenAIResponseToAnthropic; exports.convertOpenAIStreamToAnthropic = _chunkSUEGJ75Dcjs.convertOpenAIStreamToAnthropic; exports.convertOpenAIToAnthropic = _chunkSUEGJ75Dcjs.convertOpenAIToAnthropic; exports.convertOpenAIToAnthropicWithThinking = _chunkSUEGJ75Dcjs.convertOpenAIToAnthropicWithThinking; exports.createNamedKey = _chunkSN3YWBX7cjs.createNamedKey; exports.createSSEParser = _chunkHQP3K7PUcjs.createSSEParser; exports.defaultServerConfig = _chunkSN3YWBX7cjs.defaultServerConfig; exports.detectNativeSearch = _chunkV5KPWNYXcjs.detectNativeSearch; exports.detectRequestRole = _chunkSN3YWBX7cjs.detectRequestRole; exports.emitStreamEvent = _chunkSN3YWBX7cjs.emit; exports.endpointSupportsSubscription = _chunkG2FUJNA2cjs.endpointSupportsSubscription; exports.endpointToIngressFormat = _chunkSN3YWBX7cjs.endpointToIngressFormat; exports.extractRouteToken = _chunkSN3YWBX7cjs.extractRouteToken; exports.formatUrls = _chunkSN3YWBX7cjs.formatUrls; exports.getBuiltinSearchTools = _chunkNZYN7C3Pcjs.getBuiltinSearchTools; exports.getOpenRouterProviderConfig = _chunkSN3YWBX7cjs.getOpenRouterProviderConfig; exports.getOutboundApiServer = _chunkSN3YWBX7cjs.getOutboundApiServer; exports.getProviderHeaders = _chunkLKZJEL6Ecjs.getProviderHeaders; exports.getProviderProxy = _chunkSN3YWBX7cjs.getProviderProxy; exports.hasImageContent = _chunkSUEGJ75Dcjs.hasImageContent; exports.hasThinkingEnabled = _chunkSUEGJ75Dcjs.hasThinkingEnabled; exports.hashKey = _chunkSN3YWBX7cjs.hashKey; exports.isOpenRouterProvider = _chunk6VIXXLMXcjs.isOpenRouterProvider; exports.isSubscriptionProviderId = _chunkG2FUJNA2cjs.isSubscriptionProviderId; exports.loadServerConfig = _chunkSN3YWBX7cjs.loadServerConfig; exports.mergeServerConfig = _chunkSN3YWBX7cjs.mergeServerConfig; exports.normalizeAzureEndpoint = _chunkA2YMUCBTcjs.normalizeAzureEndpoint; exports.normalizeServerConfig = _chunkSN3YWBX7cjs.normalizeServerConfig; exports.registerBuiltinTransformers = _chunkUYPEN5XEcjs.registerBuiltinTransformers; exports.registerStreamEventBuffer = _chunkSN3YWBX7cjs.register; exports.releaseStreamEventBuffer = _chunkSN3YWBX7cjs.release; exports.resolveApiFormat = _chunkA2YMUCBTcjs.resolveApiFormat; exports.resolveProviderEndpoint = _chunkA2YMUCBTcjs.resolveProviderEndpoint; exports.resolveRoute = _chunkG2FUJNA2cjs.resolveRoute; exports.saveServerConfig = _chunkSN3YWBX7cjs.saveServerConfig; exports.serializeError = _chunkSVNDB62Dcjs.serializeError; exports.streamSSEResponse = _chunkHQP3K7PUcjs.streamSSEResponse; exports.verifyPresentedKey = _chunkSN3YWBX7cjs.verifyPresentedKey;
328
+ exports.AUDIT_REDACTED = _chunkFCR77GYMcjs.AUDIT_REDACTED; exports.BuiltinToolExecutor = _chunkNZYN7C3Pcjs.BuiltinToolExecutor; exports.CompletionService = _chunkDKPXN34Vcjs.CompletionService; exports.ConcurrencyQueueFullError = _chunkDKPXN34Vcjs.ConcurrencyQueueFullError; exports.ConcurrencyWaitCancelledError = _chunkDKPXN34Vcjs.ConcurrencyWaitCancelledError; exports.ConcurrencyWaitTimeoutError = _chunkDKPXN34Vcjs.ConcurrencyWaitTimeoutError; exports.DEFAULT_ACCOUNT_PROBE = _chunkDKPXN34Vcjs.DEFAULT_ACCOUNT_PROBE; exports.DEFAULT_CONCURRENCY_QUEUE = _chunkDKPXN34Vcjs.DEFAULT_CONCURRENCY_QUEUE; exports.DEFAULT_FINGERPRINT = _chunkDKPXN34Vcjs.DEFAULT_FINGERPRINT; exports.DEFAULT_OUTBOUND_PORT = _chunkDKPXN34Vcjs.DEFAULT_OUTBOUND_PORT; exports.DEFAULT_ROUTE_IDLE_MS = _chunkDKPXN34Vcjs.DEFAULT_ROUTE_IDLE_MS; exports.DEFAULT_USER_MESSAGE_QUEUE = _chunkDKPXN34Vcjs.DEFAULT_USER_MESSAGE_QUEUE; exports.ENDPOINT_MODEL_KINDS = _chunk4IH4EL7Mcjs.ENDPOINT_MODEL_KINDS; exports.KeySpendTracker = _chunkDKPXN34Vcjs.KeySpendTracker; exports.KeyedMutex = _chunkDKPXN34Vcjs.KeyedMutex; exports.NATIVE_SEARCH_TOOL_NAMES = _chunkGMMT7RVNcjs.NATIVE_SEARCH_TOOL_NAMES; exports.OPENROUTER_APP_HEADERS = _chunkUNEFIWXIcjs.OPENROUTER_APP_HEADERS; exports.OUTBOUND_API_SERVER_CONFIG_KEY = _chunkDKPXN34Vcjs.OUTBOUND_API_SERVER_CONFIG_KEY; exports.OutboundApiConfigError = _chunkDKPXN34Vcjs.OutboundApiConfigError; exports.OutboundApiServer = _chunkDKPXN34Vcjs.OutboundApiServer; exports.OutboundConcurrencyGate = _chunkDKPXN34Vcjs.OutboundConcurrencyGate; exports.OutboundRateLimiter = _chunkDKPXN34Vcjs.OutboundRateLimiter; exports.PricingEngine = _chunkYMFAJFQTcjs.PricingEngine; exports.ProviderProxy = _chunkDKPXN34Vcjs.ProviderProxy; exports.ProviderProxyRouteMap = _chunkDKPXN34Vcjs.ProviderProxyRouteMap; exports.SUBSCRIPTION_PROVIDER_IDS = _chunkVACWOIREcjs.SUBSCRIPTION_PROVIDER_IDS; exports.SerialQueueTimeoutError = _chunkDKPXN34Vcjs.SerialQueueTimeoutError; exports.TransformerChainExecutor = _chunk46ZIFWYGcjs.TransformerChainExecutor; exports.TransformerService = _chunk3OPYJG76cjs.TransformerService; exports.UsageRecorder = _chunkSNYBEXLBcjs.UsageRecorder; exports.UserMessageSerialQueue = _chunkDKPXN34Vcjs.UserMessageSerialQueue; exports.__resetOutboundApiServerForTests = _chunkDKPXN34Vcjs.__resetOutboundApiServerForTests; exports.__resetProviderProxyForTests = _chunkDKPXN34Vcjs.__resetProviderProxyForTests; exports.addOpenRouterProviderToRequest = _chunkDKPXN34Vcjs.addOpenRouterProviderToRequest; exports.applyAugmentation = _chunkJMJBSACDcjs.applyAugmentation; exports.attachStreamEventBuffer = _chunkDKPXN34Vcjs.attach; exports.beginAuditCapture = _chunkE3UCVHLPcjs.beginAuditCapture; exports.beginBillingCapture = _chunkAPYG5QD7cjs.beginBillingCapture; exports.buildAnthropicApiUrl = _chunkA2YMUCBTcjs.buildAnthropicApiUrl; exports.buildAzureOpenAIApiUrl = _chunkA2YMUCBTcjs.buildAzureOpenAIApiUrl; exports.buildGeminiApiUrl = _chunkA2YMUCBTcjs.buildGeminiApiUrl; exports.buildNativeSearchAugmentation = _chunkJMJBSACDcjs.buildNativeSearchAugmentation; exports.buildOpenAIApiUrl = _chunkA2YMUCBTcjs.buildOpenAIApiUrl; exports.buildOpenAIResponseApiUrl = _chunkA2YMUCBTcjs.buildOpenAIResponseApiUrl; exports.buildProviderApiUrl = _chunkA2YMUCBTcjs.buildProviderApiUrl; exports.checkKeyQuota = _chunkDKPXN34Vcjs.checkKeyQuota; exports.classifyModelPrefix = _chunkVACWOIREcjs.classifyModelPrefix; exports.computeKeyExpiry = _chunkDKPXN34Vcjs.computeKeyExpiry; exports.computeVoucherGrant = _chunkDKPXN34Vcjs.computeVoucherGrant; exports.convertAnthropicRequestToOpenAI = _chunkSUEGJ75Dcjs.convertAnthropicRequestToOpenAI; exports.convertAnthropicStreamToOpenAI = _chunkSUEGJ75Dcjs.convertAnthropicStreamToOpenAI; exports.convertAnthropicToOpenAI = _chunkSUEGJ75Dcjs.convertAnthropicToOpenAI; exports.convertAnthropicToOpenAIWithThinking = _chunkSUEGJ75Dcjs.convertAnthropicToOpenAIWithThinking; exports.convertMessageToAnthropic = _chunkDKPXN34Vcjs.convertMessageToAnthropic; exports.convertMessageToGemini = _chunkDKPXN34Vcjs.convertMessageToGemini; exports.convertMessageToOpenAI = _chunkDKPXN34Vcjs.convertMessageToOpenAI; exports.convertOpenAIResponseToAnthropic = _chunkSUEGJ75Dcjs.convertOpenAIResponseToAnthropic; exports.convertOpenAIStreamToAnthropic = _chunkSUEGJ75Dcjs.convertOpenAIStreamToAnthropic; exports.convertOpenAIToAnthropic = _chunkSUEGJ75Dcjs.convertOpenAIToAnthropic; exports.convertOpenAIToAnthropicWithThinking = _chunkSUEGJ75Dcjs.convertOpenAIToAnthropicWithThinking; exports.createNamedKey = _chunkDKPXN34Vcjs.createNamedKey; exports.createSSEParser = _chunkHQP3K7PUcjs.createSSEParser; exports.defaultServerConfig = _chunkDKPXN34Vcjs.defaultServerConfig; exports.detectModelKind = _chunkVACWOIREcjs.detectModelKind; exports.detectNativeSearch = _chunkJMJBSACDcjs.detectNativeSearch; exports.detectRequestRole = _chunkVACWOIREcjs.detectRequestRole; exports.emitStreamEvent = _chunkDKPXN34Vcjs.emit; exports.endpointSupportsSubscription = _chunkVACWOIREcjs.endpointSupportsSubscription; exports.endpointToIngressFormat = _chunkVACWOIREcjs.endpointToIngressFormat; exports.extractRouteToken = _chunkDKPXN34Vcjs.extractRouteToken; exports.formatUrls = _chunkDKPXN34Vcjs.formatUrls; exports.generateVoucherCode = _chunkDKPXN34Vcjs.generateVoucherCode; exports.getBuiltinSearchTools = _chunkNZYN7C3Pcjs.getBuiltinSearchTools; exports.getOpenRouterAppIdentity = _chunkUNEFIWXIcjs.getOpenRouterAppIdentity; exports.getOpenRouterProviderConfig = _chunkDKPXN34Vcjs.getOpenRouterProviderConfig; exports.getOutboundApiServer = _chunkDKPXN34Vcjs.getOutboundApiServer; exports.getProviderHeaders = _chunkQ27JY5RGcjs.getProviderHeaders; exports.getProviderProxy = _chunkDKPXN34Vcjs.getProviderProxy; exports.handleVoucherRedeem = _chunkDKPXN34Vcjs.handleVoucherRedeem; exports.hasImageContent = _chunkSUEGJ75Dcjs.hasImageContent; exports.hasThinkingEnabled = _chunkSUEGJ75Dcjs.hasThinkingEnabled; exports.hashKey = _chunkDKPXN34Vcjs.hashKey; exports.hashVoucherCode = _chunkDKPXN34Vcjs.hashVoucherCode; exports.isConcurrencyRejection = _chunkDKPXN34Vcjs.isConcurrencyRejection; exports.isKindMappedEndpoint = _chunkVACWOIREcjs.isKindMappedEndpoint; exports.isOpenRouterProvider = _chunkUNEFIWXIcjs.isOpenRouterProvider; exports.isRedeemRequest = _chunkDKPXN34Vcjs.isRedeemRequest; exports.isSerialQueueTimeout = _chunkDKPXN34Vcjs.isSerialQueueTimeout; exports.isSubscriptionProviderId = _chunkVACWOIREcjs.isSubscriptionProviderId; exports.isUserMessageRequest = _chunkDKPXN34Vcjs.isUserMessageRequest; exports.loadServerConfig = _chunkDKPXN34Vcjs.loadServerConfig; exports.mergeServerConfig = _chunkDKPXN34Vcjs.mergeServerConfig; exports.modelKindsForEndpoint = _chunkVACWOIREcjs.modelKindsForEndpoint; exports.newVoucherId = _chunkDKPXN34Vcjs.newVoucherId; exports.normalizeAccountProbe = _chunkDKPXN34Vcjs.normalizeAccountProbe; exports.normalizeAudit = _chunkDKPXN34Vcjs.normalizeAudit; exports.normalizeAzureEndpoint = _chunkA2YMUCBTcjs.normalizeAzureEndpoint; exports.normalizeBilling = _chunkDKPXN34Vcjs.normalizeBilling; exports.normalizeFingerprint = _chunkDKPXN34Vcjs.normalizeFingerprint; exports.normalizePrefixTargets = _chunkDKPXN34Vcjs.normalizePrefixTargets; exports.normalizeProxyConfig = _chunkDKPXN34Vcjs.normalizeProxyConfig; exports.normalizeProxySegment = _chunkDKPXN34Vcjs.normalizeProxySegment; exports.normalizeQueueSegments = _chunkDKPXN34Vcjs.normalizeQueueSegments; exports.normalizeServerConfig = _chunkDKPXN34Vcjs.normalizeServerConfig; exports.normalizeVoucher = _chunkDKPXN34Vcjs.normalizeVoucher; exports.normalizeWebhookDestination = _chunkDKPXN34Vcjs.normalizeWebhookDestination; exports.normalizeWebhookSegment = _chunkDKPXN34Vcjs.normalizeWebhookSegment; exports.parseModelRef = _chunkVACWOIREcjs.parseModelRef; exports.pickModelRefFromList = _chunkVACWOIREcjs.pickModelRefFromList; exports.randomBase62 = _chunkDKPXN34Vcjs.randomBase62; exports.redactAuditText = _chunkFCR77GYMcjs.redactAuditText; exports.registerBuiltinTransformers = _chunkRGTR7CIOcjs.registerBuiltinTransformers; exports.registerStreamEventBuffer = _chunkDKPXN34Vcjs.register; exports.releaseStreamEventBuffer = _chunkDKPXN34Vcjs.release; exports.resolveApiFormat = _chunkA2YMUCBTcjs.resolveApiFormat; exports.resolvePrefixTarget = _chunkVACWOIREcjs.resolvePrefixTarget; exports.resolveProviderEndpoint = _chunkA2YMUCBTcjs.resolveProviderEndpoint; exports.resolveRoute = _chunkVACWOIREcjs.resolveRoute; exports.saveServerConfig = _chunkDKPXN34Vcjs.saveServerConfig; exports.serializeError = _chunkSVNDB62Dcjs.serializeError; exports.setOpenRouterAppIdentity = _chunkUNEFIWXIcjs.setOpenRouterAppIdentity; exports.startOfLocalDay = _chunkDKPXN34Vcjs.startOfLocalDay; exports.startOfLocalWeek = _chunkDKPXN34Vcjs.startOfLocalWeek; exports.streamSSEResponse = _chunkHQP3K7PUcjs.streamSSEResponse; exports.toVoucherInfo = _chunkDKPXN34Vcjs.toVoucherInfo; exports.validateEndpointModelConfig = _chunkVACWOIREcjs.validateEndpointModelConfig; exports.validateServerModelConfig = _chunkVACWOIREcjs.validateServerModelConfig; exports.verifyKey = _chunkDKPXN34Vcjs.verifyKey; exports.verifyPresentedKey = _chunkDKPXN34Vcjs.verifyPresentedKey; exports.voucherCodePrefix = _chunkDKPXN34Vcjs.voucherCodePrefix;
package/dist/index.d.cts CHANGED
@@ -9,7 +9,7 @@ export { ProviderConfigSource } from './ports/provider-config-source.cjs';
9
9
  export { UsageEventStore } from './ports/usage-event-store.cjs';
10
10
  export { WebSearchBackend } from './ports/web-search-backend.cjs';
11
11
  export { AnthropicIngressHandler, AnthropicIngressHandlerFactory, AnthropicRouteHandlerParams, AnthropicSdkHints, ExtendedContextHint, IngressFormat, ProviderProxyDeps, ProxyAttribution, RetryCallback, RouteAuthMode, RouteContext, StreamEventCallback, SubscriptionDispatchProfile, SubscriptionRequestSummary, TargetProviderFormat, UsageRecorderImport, UsageRecorderImport as UsageSink } from './provider-proxy/types.cjs';
12
- export { EndpointRoutingConfig, OutboundApiDeps, OutboundApiKeyCreated, OutboundApiKeyInfo, OutboundApiServerConfig, OutboundApiServerStatus, OutboundKeyDb as OutboundCredentialStore, OutboundEndpoint, OutboundFormatUrls, OutboundKeyDb, OutboundKeyDbRow, RequestRole } from './outbound-api/types.cjs';
12
+ export { A as AccountProbeConfig, C as ChatDispatchMode, a as ConcurrencyQueueConfig, E as ENDPOINT_MODEL_KINDS, b as EndpointRoutingConfig, F as FingerprintConfig, K as KeySpendReader, c as KeySpendSeeder, d as KeySpendTracker, e as KindMappedEndpoint, M as MessagesModelKind, f as ModelKind, g as ModelPrefixTargets, h as OutboundApiDeps, i as OutboundApiKeyCreated, j as OutboundApiKeyInfo, k as OutboundApiServerConfig, l as OutboundApiServerStatus, O as OutboundCredentialStore, m as OutboundEndpoint, n as OutboundFormatUrls, o as OutboundKeyActivationMode, O as OutboundKeyDb, p as OutboundKeyDbRow, q as OutboundKeyPolicy, r as OutboundProxyConfig, R as RequestRole, s as ResponsesModelKind, U as UserMessageQueueConfig, V as VoucherCreateInput, t as VoucherDb, u as computeVoucherGrant, v as generateVoucherCode, w as hashVoucherCode, x as newVoucherId, y as startOfLocalDay, z as startOfLocalWeek, B as toVoucherInfo, D as voucherCodePrefix } from './types-B8Arpxn0.cjs';
13
13
  export { CostCalculation, PricingEngine, PricingEngineOptions } from './usage/pricing-engine.cjs';
14
14
  export { UsageRecordInput, UsageRecorder, UsageRecorderOptions } from './usage/usage-recorder.cjs';
15
15
  export { A as ApiFormat, C as CompletionOptions, a as CompletionResult, N as NATIVE_SEARCH_TOOL_NAMES, b as NativeSearchAugmentation, c as NativeSearchDetectionResult, d as NativeSearchProvider, e as NativeSearchUserConfig, S as StreamCallbacks } from './types-BScIHmPr.cjs';
@@ -18,14 +18,18 @@ export { SimpleChatGeminiMessage, SimpleChatGeminiPart, StreamEvent, StreamEvent
18
18
  export { buildAnthropicApiUrl, buildAzureOpenAIApiUrl, buildGeminiApiUrl, buildOpenAIApiUrl, buildOpenAIResponseApiUrl, buildProviderApiUrl, normalizeAzureEndpoint, resolveApiFormat, resolveProviderEndpoint } from './completion/url-builder.cjs';
19
19
  export { applyAugmentation, buildNativeSearchAugmentation, detectNativeSearch } from './completion/NativeSearchInjector.cjs';
20
20
  export { __resetProviderProxyForTests, extractRouteToken, getProviderProxy } from './provider-proxy.cjs';
21
- export { ApiServerSettingsStore, ApplyConfigInput, DEFAULT_OUTBOUND_PORT, OUTBOUND_API_SERVER_CONFIG_KEY, OutboundApiServer, OutboundRateLimiter, __resetOutboundApiServerForTests, createNamedKey, defaultServerConfig, detectRequestRole, endpointToIngressFormat, formatUrls, getOutboundApiServer, hashKey, loadServerConfig, mergeServerConfig, normalizeServerConfig, saveServerConfig, verifyPresentedKey } from './outbound-api.cjs';
21
+ export { ApiServerSettingsStore, ApplyConfigInput, ConcurrencyQueueFullError, ConcurrencyWaitCancelledError, ConcurrencyWaitTimeoutError, DEFAULT_ACCOUNT_PROBE, DEFAULT_CONCURRENCY_QUEUE, DEFAULT_FINGERPRINT, DEFAULT_OUTBOUND_PORT, DEFAULT_USER_MESSAGE_QUEUE, EndpointModelConfigError, GateAcquireOptions, GateAcquisition, GateSlot, GateStatusEntry, KeyVerification, KeyedMutex, ModelPrefixKind, OUTBOUND_API_SERVER_CONFIG_KEY, OutboundApiConfigError, OutboundApiServer, OutboundConcurrencyGate, OutboundRateLimiter, SerialAcquireOptions, SerialQueueStatusEntry, SerialQueueTimeoutError, SerialSlot, UserMessageSerialQueue, VerifiedKey, __resetOutboundApiServerForTests, classifyModelPrefix, createNamedKey, defaultServerConfig, detectModelKind, detectRequestRole, endpointToIngressFormat, formatUrls, getOutboundApiServer, handleVoucherRedeem, hashKey, isConcurrencyRejection, isKindMappedEndpoint, isRedeemRequest, isSerialQueueTimeout, isUserMessageRequest, loadServerConfig, mergeServerConfig, modelKindsForEndpoint, normalizeAccountProbe, normalizeAudit, normalizeBilling, normalizeFingerprint, normalizePrefixTargets, normalizeProxyConfig, normalizeProxySegment, normalizeQueueSegments, normalizeServerConfig, normalizeVoucher, normalizeWebhookDestination, normalizeWebhookSegment, randomBase62, resolvePrefixTarget, saveServerConfig, validateEndpointModelConfig, validateServerModelConfig, verifyKey, verifyPresentedKey } from './outbound-api.cjs';
22
22
  export { convertAnthropicRequestToOpenAI, convertAnthropicStreamToOpenAI, convertAnthropicToOpenAI, convertAnthropicToOpenAIWithThinking, convertOpenAIResponseToAnthropic, convertOpenAIStreamToAnthropic, convertOpenAIToAnthropic, convertOpenAIToAnthropicWithThinking, hasImageContent, hasThinkingEnabled } from './ApiConverter.cjs';
23
23
  export { ChainExecutionOptions, TransformerChainExecutor } from './transformer/TransformerChainExecutor.cjs';
24
24
  export { TransformerService } from './transformer/TransformerService.cjs';
25
25
  export { registerBuiltinTransformers } from './transformer/transformers.cjs';
26
26
  export { Annotation, ImageContent, MessageContent, ModelRoute, ModelTransformerConfig, ReasoningConfig, RequestConfig, RequestRouteInfo, ResolvedTransformerChain, StreamChunk, TextContent, ThinkLevel, ThinkingContent, ToolCall, ToolChoice, ToolParameterSchema, TransformRequestResult, Transformer, TransformerChainConfig, TransformerConfigEntry, TransformerConstructor, TransformerContext, TransformerLogger, TransformerOptions, TransformerReference, TransformerServiceConfig, UnifiedChatRequest, UnifiedChatResponse, UnifiedMessage, UnifiedTool, UrlCitation } from './transformer/types.cjs';
27
+ export { AUDIT_REDACTED, redactAuditText } from './outbound-api/auditRedact.cjs';
28
+ export { AuditCaptureContext, beginAuditCapture } from './outbound-api/auditCapture.cjs';
29
+ export { BillingCaptureContext, beginBillingCapture } from './outbound-api/billingCapture.cjs';
27
30
  export { D as DEFAULT_ROUTE_IDLE_MS, P as ProviderProxy, a as ProviderProxyRouteMap } from './ProviderProxy-CnMQYN59.cjs';
28
- export { S as SUBSCRIPTION_PROVIDER_IDS, e as endpointSupportsSubscription, i as isSubscriptionProviderId, r as resolveRoute } from './routeResolver-BrbK6ja9.cjs';
31
+ export { K as KeyCostLimits, a as KeyExpiryInput, b as KeyExpiryResult, c as KeySpend, Q as QuotaDecision, d as checkKeyQuota, e as computeKeyExpiry } from './keyPolicy-Cp0FntZl.cjs';
32
+ export { S as SUBSCRIPTION_PROVIDER_IDS, e as endpointSupportsSubscription, i as isSubscriptionProviderId, p as parseModelRef, a as pickModelRefFromList, r as resolveRoute } from './routeResolver-CB3tvJKy.cjs';
29
33
  import '@omnicross/contracts/message-blocks';
30
34
  import '@omnicross/contracts/completion-types';
31
35
  import '@omnicross/contracts/mcp-types';
@@ -39,6 +43,12 @@ import './completion/ApiKeyPoolService.cjs';
39
43
  import './pipeline/AuthSource.cjs';
40
44
  import './pipeline/SubscriptionAuthSource.cjs';
41
45
  import './pipeline/SubscriptionAuthStrategy.cjs';
46
+ import '@omnicross/contracts/account-tokens-types';
47
+ import '@omnicross/contracts/audit-types';
48
+ import '@omnicross/contracts/billing-types';
49
+ import '@omnicross/contracts/health-logging-types';
50
+ import '@omnicross/contracts/voucher-types';
51
+ import '@omnicross/contracts/webhook-types';
42
52
  import '@omnicross/contracts/endpoint-resolver';
43
53
  import './transformer/transformers/AnthropicTransformer.cjs';
44
54
  import './transformer/transformers/GeminiCodeAssistTransformer.cjs';
@@ -61,12 +71,36 @@ import './transformer/transformers/ReasoningTransformer.cjs';
61
71
  */
62
72
  declare function isOpenRouterProvider(provider: LLMProvider): boolean;
63
73
  /**
64
- * OpenRouter app attribution headers
65
- * See: https://openrouter.ai/docs/app-attribution
74
+ * OpenRouter "app attribution" identity — the `HTTP-Referer` (the app's URL,
75
+ * the primary attribution key) and `X-Title` (the app's display name) that
76
+ * OpenRouter uses to attribute usage to an app on its public daily/weekly/
77
+ * monthly rankings. See https://openrouter.ai/docs/app-attribution
66
78
  */
67
- declare const OPENROUTER_APP_HEADERS: {
68
- 'HTTP-Referer': string;
69
- 'X-Title': string;
70
- };
79
+ interface OpenRouterAppIdentity {
80
+ /** `HTTP-Referer` header — the app's URL. */
81
+ referer: string;
82
+ /** `X-Title` header — the app's display name on OpenRouter rankings. */
83
+ title: string;
84
+ }
85
+ /**
86
+ * The live OpenRouter app-attribution header set — the SINGLE source of truth
87
+ * for every OpenRouter request the serving core makes. Both the LLM path
88
+ * (`header-builder` / `TransformerHandler`) and the media path
89
+ * (`completion/openrouter-headers.ts` → `buildOpenRouterHeaders`) read this
90
+ * object. `setOpenRouterAppIdentity` mutates it in place; consumers spread it
91
+ * at request time, so a boot-time host override is reflected everywhere without
92
+ * re-importing.
93
+ */
94
+ declare const OPENROUTER_APP_HEADERS: Record<string, string>;
95
+ /**
96
+ * Override the OpenRouter app-attribution identity. Call once at host boot,
97
+ * before any OpenRouter request. Blank/whitespace-only fields are ignored (the
98
+ * existing value is kept), so a partial override is safe.
99
+ */
100
+ declare function setOpenRouterAppIdentity(identity: Partial<OpenRouterAppIdentity>): void;
101
+ /**
102
+ * Read the current OpenRouter app-attribution identity.
103
+ */
104
+ declare function getOpenRouterAppIdentity(): OpenRouterAppIdentity;
71
105
 
72
- export { OPENROUTER_APP_HEADERS, isOpenRouterProvider };
106
+ export { OPENROUTER_APP_HEADERS, type OpenRouterAppIdentity, getOpenRouterAppIdentity, isOpenRouterProvider, setOpenRouterAppIdentity };
package/dist/index.d.ts CHANGED
@@ -9,7 +9,7 @@ export { ProviderConfigSource } from './ports/provider-config-source.js';
9
9
  export { UsageEventStore } from './ports/usage-event-store.js';
10
10
  export { WebSearchBackend } from './ports/web-search-backend.js';
11
11
  export { AnthropicIngressHandler, AnthropicIngressHandlerFactory, AnthropicRouteHandlerParams, AnthropicSdkHints, ExtendedContextHint, IngressFormat, ProviderProxyDeps, ProxyAttribution, RetryCallback, RouteAuthMode, RouteContext, StreamEventCallback, SubscriptionDispatchProfile, SubscriptionRequestSummary, TargetProviderFormat, UsageRecorderImport, UsageRecorderImport as UsageSink } from './provider-proxy/types.js';
12
- export { EndpointRoutingConfig, OutboundApiDeps, OutboundApiKeyCreated, OutboundApiKeyInfo, OutboundApiServerConfig, OutboundApiServerStatus, OutboundKeyDb as OutboundCredentialStore, OutboundEndpoint, OutboundFormatUrls, OutboundKeyDb, OutboundKeyDbRow, RequestRole } from './outbound-api/types.js';
12
+ export { A as AccountProbeConfig, C as ChatDispatchMode, a as ConcurrencyQueueConfig, E as ENDPOINT_MODEL_KINDS, b as EndpointRoutingConfig, F as FingerprintConfig, K as KeySpendReader, c as KeySpendSeeder, d as KeySpendTracker, e as KindMappedEndpoint, M as MessagesModelKind, f as ModelKind, g as ModelPrefixTargets, h as OutboundApiDeps, i as OutboundApiKeyCreated, j as OutboundApiKeyInfo, k as OutboundApiServerConfig, l as OutboundApiServerStatus, O as OutboundCredentialStore, m as OutboundEndpoint, n as OutboundFormatUrls, o as OutboundKeyActivationMode, O as OutboundKeyDb, p as OutboundKeyDbRow, q as OutboundKeyPolicy, r as OutboundProxyConfig, R as RequestRole, s as ResponsesModelKind, U as UserMessageQueueConfig, V as VoucherCreateInput, t as VoucherDb, u as computeVoucherGrant, v as generateVoucherCode, w as hashVoucherCode, x as newVoucherId, y as startOfLocalDay, z as startOfLocalWeek, B as toVoucherInfo, D as voucherCodePrefix } from './types-lgPYQuZS.js';
13
13
  export { CostCalculation, PricingEngine, PricingEngineOptions } from './usage/pricing-engine.js';
14
14
  export { UsageRecordInput, UsageRecorder, UsageRecorderOptions } from './usage/usage-recorder.js';
15
15
  export { A as ApiFormat, C as CompletionOptions, a as CompletionResult, N as NATIVE_SEARCH_TOOL_NAMES, b as NativeSearchAugmentation, c as NativeSearchDetectionResult, d as NativeSearchProvider, e as NativeSearchUserConfig, S as StreamCallbacks } from './types-BScIHmPr.js';
@@ -18,14 +18,18 @@ export { SimpleChatGeminiMessage, SimpleChatGeminiPart, StreamEvent, StreamEvent
18
18
  export { buildAnthropicApiUrl, buildAzureOpenAIApiUrl, buildGeminiApiUrl, buildOpenAIApiUrl, buildOpenAIResponseApiUrl, buildProviderApiUrl, normalizeAzureEndpoint, resolveApiFormat, resolveProviderEndpoint } from './completion/url-builder.js';
19
19
  export { applyAugmentation, buildNativeSearchAugmentation, detectNativeSearch } from './completion/NativeSearchInjector.js';
20
20
  export { __resetProviderProxyForTests, extractRouteToken, getProviderProxy } from './provider-proxy.js';
21
- export { ApiServerSettingsStore, ApplyConfigInput, DEFAULT_OUTBOUND_PORT, OUTBOUND_API_SERVER_CONFIG_KEY, OutboundApiServer, OutboundRateLimiter, __resetOutboundApiServerForTests, createNamedKey, defaultServerConfig, detectRequestRole, endpointToIngressFormat, formatUrls, getOutboundApiServer, hashKey, loadServerConfig, mergeServerConfig, normalizeServerConfig, saveServerConfig, verifyPresentedKey } from './outbound-api.js';
21
+ export { ApiServerSettingsStore, ApplyConfigInput, ConcurrencyQueueFullError, ConcurrencyWaitCancelledError, ConcurrencyWaitTimeoutError, DEFAULT_ACCOUNT_PROBE, DEFAULT_CONCURRENCY_QUEUE, DEFAULT_FINGERPRINT, DEFAULT_OUTBOUND_PORT, DEFAULT_USER_MESSAGE_QUEUE, EndpointModelConfigError, GateAcquireOptions, GateAcquisition, GateSlot, GateStatusEntry, KeyVerification, KeyedMutex, ModelPrefixKind, OUTBOUND_API_SERVER_CONFIG_KEY, OutboundApiConfigError, OutboundApiServer, OutboundConcurrencyGate, OutboundRateLimiter, SerialAcquireOptions, SerialQueueStatusEntry, SerialQueueTimeoutError, SerialSlot, UserMessageSerialQueue, VerifiedKey, __resetOutboundApiServerForTests, classifyModelPrefix, createNamedKey, defaultServerConfig, detectModelKind, detectRequestRole, endpointToIngressFormat, formatUrls, getOutboundApiServer, handleVoucherRedeem, hashKey, isConcurrencyRejection, isKindMappedEndpoint, isRedeemRequest, isSerialQueueTimeout, isUserMessageRequest, loadServerConfig, mergeServerConfig, modelKindsForEndpoint, normalizeAccountProbe, normalizeAudit, normalizeBilling, normalizeFingerprint, normalizePrefixTargets, normalizeProxyConfig, normalizeProxySegment, normalizeQueueSegments, normalizeServerConfig, normalizeVoucher, normalizeWebhookDestination, normalizeWebhookSegment, randomBase62, resolvePrefixTarget, saveServerConfig, validateEndpointModelConfig, validateServerModelConfig, verifyKey, verifyPresentedKey } from './outbound-api.js';
22
22
  export { convertAnthropicRequestToOpenAI, convertAnthropicStreamToOpenAI, convertAnthropicToOpenAI, convertAnthropicToOpenAIWithThinking, convertOpenAIResponseToAnthropic, convertOpenAIStreamToAnthropic, convertOpenAIToAnthropic, convertOpenAIToAnthropicWithThinking, hasImageContent, hasThinkingEnabled } from './ApiConverter.js';
23
23
  export { ChainExecutionOptions, TransformerChainExecutor } from './transformer/TransformerChainExecutor.js';
24
24
  export { TransformerService } from './transformer/TransformerService.js';
25
25
  export { registerBuiltinTransformers } from './transformer/transformers.js';
26
26
  export { Annotation, ImageContent, MessageContent, ModelRoute, ModelTransformerConfig, ReasoningConfig, RequestConfig, RequestRouteInfo, ResolvedTransformerChain, StreamChunk, TextContent, ThinkLevel, ThinkingContent, ToolCall, ToolChoice, ToolParameterSchema, TransformRequestResult, Transformer, TransformerChainConfig, TransformerConfigEntry, TransformerConstructor, TransformerContext, TransformerLogger, TransformerOptions, TransformerReference, TransformerServiceConfig, UnifiedChatRequest, UnifiedChatResponse, UnifiedMessage, UnifiedTool, UrlCitation } from './transformer/types.js';
27
+ export { AUDIT_REDACTED, redactAuditText } from './outbound-api/auditRedact.js';
28
+ export { AuditCaptureContext, beginAuditCapture } from './outbound-api/auditCapture.js';
29
+ export { BillingCaptureContext, beginBillingCapture } from './outbound-api/billingCapture.js';
27
30
  export { D as DEFAULT_ROUTE_IDLE_MS, P as ProviderProxy, a as ProviderProxyRouteMap } from './ProviderProxy-C-xqrkKi.js';
28
- export { S as SUBSCRIPTION_PROVIDER_IDS, e as endpointSupportsSubscription, i as isSubscriptionProviderId, r as resolveRoute } from './routeResolver-HE-ZO0fO.js';
31
+ export { K as KeyCostLimits, a as KeyExpiryInput, b as KeyExpiryResult, c as KeySpend, Q as QuotaDecision, d as checkKeyQuota, e as computeKeyExpiry } from './keyPolicy-Cp0FntZl.js';
32
+ export { S as SUBSCRIPTION_PROVIDER_IDS, e as endpointSupportsSubscription, i as isSubscriptionProviderId, p as parseModelRef, a as pickModelRefFromList, r as resolveRoute } from './routeResolver-C4T7yClx.js';
29
33
  import '@omnicross/contracts/message-blocks';
30
34
  import '@omnicross/contracts/completion-types';
31
35
  import '@omnicross/contracts/mcp-types';
@@ -39,6 +43,12 @@ import './completion/ApiKeyPoolService.js';
39
43
  import './pipeline/AuthSource.js';
40
44
  import './pipeline/SubscriptionAuthSource.js';
41
45
  import './pipeline/SubscriptionAuthStrategy.js';
46
+ import '@omnicross/contracts/account-tokens-types';
47
+ import '@omnicross/contracts/audit-types';
48
+ import '@omnicross/contracts/billing-types';
49
+ import '@omnicross/contracts/health-logging-types';
50
+ import '@omnicross/contracts/voucher-types';
51
+ import '@omnicross/contracts/webhook-types';
42
52
  import '@omnicross/contracts/endpoint-resolver';
43
53
  import './transformer/transformers/AnthropicTransformer.js';
44
54
  import './transformer/transformers/GeminiCodeAssistTransformer.js';
@@ -61,12 +71,36 @@ import './transformer/transformers/ReasoningTransformer.js';
61
71
  */
62
72
  declare function isOpenRouterProvider(provider: LLMProvider): boolean;
63
73
  /**
64
- * OpenRouter app attribution headers
65
- * See: https://openrouter.ai/docs/app-attribution
74
+ * OpenRouter "app attribution" identity — the `HTTP-Referer` (the app's URL,
75
+ * the primary attribution key) and `X-Title` (the app's display name) that
76
+ * OpenRouter uses to attribute usage to an app on its public daily/weekly/
77
+ * monthly rankings. See https://openrouter.ai/docs/app-attribution
66
78
  */
67
- declare const OPENROUTER_APP_HEADERS: {
68
- 'HTTP-Referer': string;
69
- 'X-Title': string;
70
- };
79
+ interface OpenRouterAppIdentity {
80
+ /** `HTTP-Referer` header — the app's URL. */
81
+ referer: string;
82
+ /** `X-Title` header — the app's display name on OpenRouter rankings. */
83
+ title: string;
84
+ }
85
+ /**
86
+ * The live OpenRouter app-attribution header set — the SINGLE source of truth
87
+ * for every OpenRouter request the serving core makes. Both the LLM path
88
+ * (`header-builder` / `TransformerHandler`) and the media path
89
+ * (`completion/openrouter-headers.ts` → `buildOpenRouterHeaders`) read this
90
+ * object. `setOpenRouterAppIdentity` mutates it in place; consumers spread it
91
+ * at request time, so a boot-time host override is reflected everywhere without
92
+ * re-importing.
93
+ */
94
+ declare const OPENROUTER_APP_HEADERS: Record<string, string>;
95
+ /**
96
+ * Override the OpenRouter app-attribution identity. Call once at host boot,
97
+ * before any OpenRouter request. Blank/whitespace-only fields are ignored (the
98
+ * existing value is kept), so a partial override is safe.
99
+ */
100
+ declare function setOpenRouterAppIdentity(identity: Partial<OpenRouterAppIdentity>): void;
101
+ /**
102
+ * Read the current OpenRouter app-attribution identity.
103
+ */
104
+ declare function getOpenRouterAppIdentity(): OpenRouterAppIdentity;
71
105
 
72
- export { OPENROUTER_APP_HEADERS, isOpenRouterProvider };
106
+ export { OPENROUTER_APP_HEADERS, type OpenRouterAppIdentity, getOpenRouterAppIdentity, isOpenRouterProvider, setOpenRouterAppIdentity };