@meistrari/chat-nuxt 4.3.0-rc.0 → 4.3.0-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.
package/dist/module.d.mts CHANGED
@@ -43,6 +43,14 @@ interface ChatNuxtModuleOptions {
43
43
  agentApiV5?: boolean;
44
44
  /** Opt in to the 24-hour server-side pre-wake lookup cache. Defaults to false. */
45
45
  preWakeCache?: boolean;
46
+ /**
47
+ * Opt this deployment into routing native Claude models through the Bifrost
48
+ * gateway: the server proxy adds `"route-claude-via-gateway": true` to the
49
+ * `x-chat-config` header, so a new session's wake/execute picks the gateway
50
+ * provider (continuations keep the provider they were created on). Defaults
51
+ * to `false`; also settable via `NUXT_CHAT_NUXT_ROUTE_CLAUDE_VIA_GATEWAY`.
52
+ */
53
+ routeClaudeViaGateway?: boolean;
46
54
  }
47
55
  declare const _default: any;
48
56
 
package/dist/module.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@meistrari/chat-nuxt",
3
3
  "configKey": "chatNuxt",
4
- "version": "4.3.0-rc.0",
4
+ "version": "4.3.0-rc.1",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "1.0.2",
7
7
  "unbuild": "unknown"
package/dist/module.mjs CHANGED
@@ -455,7 +455,10 @@ const module$1 = defineNuxtModule({
455
455
  // NUXT_CHAT_NUXT_SECRETLESS_EXECUTION env override can apply.
456
456
  secretlessExecution: options.secretlessExecution ?? existingChatNuxtRuntimeConfig?.secretlessExecution ?? false,
457
457
  preWakeCache: options.preWakeCache ?? existingChatNuxtRuntimeConfig?.preWakeCache ?? false,
458
- agentApiV5: options.agentApiV5 ?? existingChatNuxtRuntimeConfig?.agentApiV5 ?? false
458
+ agentApiV5: options.agentApiV5 ?? existingChatNuxtRuntimeConfig?.agentApiV5 ?? false,
459
+ // Explicit boolean default keeps the key in runtime config so the
460
+ // NUXT_CHAT_NUXT_ROUTE_CLAUDE_VIA_GATEWAY env override can apply.
461
+ routeClaudeViaGateway: options.routeClaudeViaGateway ?? existingChatNuxtRuntimeConfig?.routeClaudeViaGateway ?? false
459
462
  };
460
463
  if (hostAuthComposablePath && !rc.chatNuxt.authTokenCookie) {
461
464
  console.warn(
@@ -1,4 +1,4 @@
1
- import { AGENT_API_V5_CONFIG_KEY, PRE_WAKE_CACHE_CONFIG_KEY, CONVERSATION_V2_CONFIG_KEY, PREPARED_AGENT_RUNTIME_CONFIG_KEY, SECRETLESS_EXECUTION_CONFIG_KEY } from "../../types/schemas/chat/chat-config.js";
1
+ import { AGENT_API_V5_CONFIG_KEY, PRE_WAKE_CACHE_CONFIG_KEY, CONVERSATION_V2_CONFIG_KEY, PREPARED_AGENT_RUNTIME_CONFIG_KEY, ROUTE_CLAUDE_VIA_GATEWAY_CONFIG_KEY, SECRETLESS_EXECUTION_CONFIG_KEY } from "../../types/schemas/chat/chat-config.js";
2
2
  import { createError, defineEventHandler, getHeader, getRequestURL, getRouterParam, proxyRequest } from "h3";
3
3
  import { useRuntimeConfig } from "nitropack/runtime";
4
4
  import { resolveAuthToken } from "./auth-token.js";
@@ -83,6 +83,9 @@ function buildProxyHeaders(event) {
83
83
  if (config.chatNuxt?.agentApiV5) {
84
84
  chatConfig[AGENT_API_V5_CONFIG_KEY] = true;
85
85
  }
86
+ if (config.chatNuxt?.routeClaudeViaGateway) {
87
+ chatConfig[ROUTE_CLAUDE_VIA_GATEWAY_CONFIG_KEY] = true;
88
+ }
86
89
  const headers = {
87
90
  "authorization": `Bearer ${token}`,
88
91
  "x-chat-client": "chat-nuxt",
@@ -3,3 +3,4 @@ export declare const SECRETLESS_EXECUTION_CONFIG_KEY = "secretless-execution";
3
3
  export declare const AGENT_API_V5_CONFIG_KEY = "agent-api-v5";
4
4
  export declare const CONVERSATION_V2_CONFIG_KEY = "conversation-v2";
5
5
  export declare const PRE_WAKE_CACHE_CONFIG_KEY = "pre-wake-cache";
6
+ export declare const ROUTE_CLAUDE_VIA_GATEWAY_CONFIG_KEY = "route-claude-via-gateway";
@@ -3,3 +3,4 @@ export const SECRETLESS_EXECUTION_CONFIG_KEY = 'secretless-execution';
3
3
  export const AGENT_API_V5_CONFIG_KEY = 'agent-api-v5';
4
4
  export const CONVERSATION_V2_CONFIG_KEY = 'conversation-v2';
5
5
  export const PRE_WAKE_CACHE_CONFIG_KEY = 'pre-wake-cache';
6
+ export const ROUTE_CLAUDE_VIA_GATEWAY_CONFIG_KEY = 'route-claude-via-gateway';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@meistrari/chat-nuxt",
3
- "version": "4.3.0-rc.0",
3
+ "version": "4.3.0-rc.1",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {