@askalf/dario 3.37.9 → 3.37.10

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 (2) hide show
  1. package/dist/proxy.js +7 -4
  2. package/package.json +1 -1
package/dist/proxy.js CHANGED
@@ -125,8 +125,9 @@ function loadClaudeIdentity() {
125
125
  }
126
126
  // Model shortcuts — users can pass short names
127
127
  const MODEL_ALIASES = {
128
- 'opus': 'claude-opus-4-6',
129
- 'opus1m': 'claude-opus-4-6[1m]',
128
+ 'opus': 'claude-opus-4-7',
129
+ 'opus46': 'claude-opus-4-6',
130
+ 'opus1m': 'claude-opus-4-7[1m]',
130
131
  'sonnet': 'claude-sonnet-4-6',
131
132
  'sonnet1m': 'claude-sonnet-4-6[1m]',
132
133
  'haiku': 'claude-haiku-4-5',
@@ -358,7 +359,7 @@ function translateStreamChunk(line) {
358
359
  catch { }
359
360
  return null;
360
361
  }
361
- const OPENAI_MODELS_LIST = { object: 'list', data: ['claude-opus-4-6', 'claude-sonnet-4-6', 'claude-haiku-4-5'].map(id => ({ id, object: 'model', created: 1700000000, owned_by: 'anthropic' })) };
362
+ const OPENAI_MODELS_LIST = { object: 'list', data: ['claude-opus-4-7', 'claude-opus-4-6', 'claude-sonnet-4-6', 'claude-haiku-4-5'].map(id => ({ id, object: 'model', created: 1700000000, owned_by: 'anthropic' })) };
362
363
  /**
363
364
  * Append a JSON-ND line to the proxy log file. No-op when stream is
364
365
  * null (logFile not configured). Errors are swallowed — log writes
@@ -768,7 +769,9 @@ export async function startProxy(opts = {}) {
768
769
  const CORS_HEADERS = {
769
770
  'Access-Control-Allow-Origin': corsOrigin,
770
771
  'Access-Control-Allow-Methods': 'GET, POST, OPTIONS',
771
- 'Access-Control-Allow-Headers': 'Content-Type, Authorization, x-api-key, anthropic-version, anthropic-beta',
772
+ // *-wildcard covers custom headers in non-credentialed mode, except
773
+ // Authorization, which is a CORS non-wildcard request-header name.
774
+ 'Access-Control-Allow-Headers': '*, Authorization',
772
775
  'Access-Control-Max-Age': '86400',
773
776
  ...SECURITY_HEADERS,
774
777
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@askalf/dario",
3
- "version": "3.37.9",
3
+ "version": "3.37.10",
4
4
  "description": "A local LLM router. One endpoint, every provider — Claude subscriptions, OpenAI, OpenRouter, Groq, local LiteLLM, any OpenAI-compat endpoint — your tools don't need to change.",
5
5
  "type": "module",
6
6
  "bin": {