diff --git a/backend/.env.example b/backend/.env.example index 24bf71c..f6697b6 100644 --- a/backend/.env.example +++ b/backend/.env.example @@ -17,4 +17,7 @@ PIPER_URL= LLAMA_CPP_URL=https://ollama.epsem.aranroig.com/v1/chat/completitions LLAMA_PREAMBLE=./prompts/preamble.md -LLAMA_API_KEY=your_api_key \ No newline at end of file +LLAMA_API_KEY=your_api_key + +# MCP server (Python FastMCP) — SSH-tunelled from remote machine +MCP_URL=http://localhost:5001 \ No newline at end of file diff --git a/backend/run-mcp.sh b/backend/run-mcp.sh new file mode 100755 index 0000000..0a71cca --- /dev/null +++ b/backend/run-mcp.sh @@ -0,0 +1,10 @@ +#!/bin/bash +REMOTE_PORT=2223 +HOST=ollama.epsem.aranroig.com +PORT=5001 +REMOTE_USER=root +REMOTE_HOST=ollama.epsem.aranroig.com +ssh -p ${REMOTE_PORT} -N -R ${HOST}:${PORT}:localhost:${PORT} -o ServerAliveInterval=30 \ + -o ServerAliveCountMax=3 \ + -o ExitOnForwardFailure=yes \ + ${REMOTE_USER}@${REMOTE_HOST} \ No newline at end of file diff --git a/backend/src/controllers/audio.controller.ts b/backend/src/controllers/audio.controller.ts index d9fd146..bc39946 100644 --- a/backend/src/controllers/audio.controller.ts +++ b/backend/src/controllers/audio.controller.ts @@ -87,7 +87,7 @@ router.post('/upload', upload.single('file'), async (req, res) => { tmpTxt = txtPath; await writeFileAsync(txtPath, transcription); - const llmResponse = await llamacppService.chatWithPreamble(transcription).catch( + const llmResponse = await llamacppService.chatWithMcpTools(transcription).catch( (err: unknown) => { const msg = err instanceof Error ? err.message : String(err); console.error(`[audio] llama.cpp failed: ${msg}`); diff --git a/backend/src/index.ts b/backend/src/index.ts index a7e540d..8641c83 100644 --- a/backend/src/index.ts +++ b/backend/src/index.ts @@ -4,7 +4,7 @@ import router from './routes/router.js'; import { getAppPort, getConfig } from './config.js'; import { whisperService } from './services/whisper.service.js'; import { piperService as piperWorker } from './services/piper.service.js'; -import { mcpClient } from './services/mcpClient.service.js'; +import { mcpClient } from './services/mcp.service.js'; const app = express(); @@ -30,12 +30,9 @@ const server = app.listen(getAppPort(), async () => { console.log(`QuiBot backend listening on port ${getAppPort()}`); whisperService.spawn(); piperWorker.initWav().catch(() => { /* model may not exist yet → lazy init on first TTS call */ }); - try { - await mcpClient.start(); - console.log('[server] MCP client started'); - } catch (err) { - console.error(`[server] MCP client failed to start: ${err instanceof Error ? err.message : String(err)}`); - } + mcpClient.connect().catch((err) => { + console.error(`[mcp] Failed to start MCP client: ${err instanceof Error ? err.message : String(err)}`); + }); }); async function shutdown(signal: string) { diff --git a/backend/src/services/llama.service.ts b/backend/src/services/llama.service.ts index dd3b323..655514c 100644 --- a/backend/src/services/llama.service.ts +++ b/backend/src/services/llama.service.ts @@ -1,54 +1,171 @@ import { getLlamacppUrl, getLlamacppApiKey, getLlamacppPreamble } from '../config.js'; +import { mcpClient, McpToolDef } from './mcp.service.js'; -interface LlamaRequest { - messages: Array<{ role: string; content: string }>; +interface LlamaMessage { + role: string; + content?: string | null; + tool_call_id?: string; + tool_calls?: Array<{ + id: string; + type: string; + function: { name: string; arguments: string }; + }>; } -interface LlamaChatChoice { - message: { - content: string; +interface LlamaToolCallResult { + content: Array<{ + type: string; + text?: string; + }>; + isError?: boolean; +} + +interface LlamaToolDefinition { + type: 'function'; + function: { + name: string; + description: string; + parameters: object; + }; +} + +interface LlamaRequest { + messages: LlamaMessage[]; + tools?: LlamaToolDefinition[]; + tool_choice?: 'auto' | 'none'; +} + +interface LlamaResponseChoice { + message?: { + content?: string; + tool_calls?: Array<{ + id: string; + type: string; + function: { name: string; arguments: string }; + }>; }; } interface LlamaResponse { - choices?: LlamaChatChoice[]; + choices?: LlamaResponseChoice[]; } +const MAX_TOOL_ITERATIONS = 10; + export const llamacppService = { async chat(messages: Array<{ role: string; content: string }>): Promise { + let history: LlamaMessage[] = messages.map(m => ({ role: m.role, content: m.content })); + const apiUrl = getLlamacppUrl(); - if (!apiUrl) { - return ''; - } + if (!apiUrl) return ''; const apiKey = getLlamacppApiKey(); const headers: Record = { 'Content-Type': 'application/json' }; - if (apiKey) { - headers['Authorization'] = `Bearer ${apiKey}`; + if (apiKey) headers['Authorization'] = `Bearer ${apiKey}`; + + const request: LlamaRequest = { messages: history }; + const res = await fetch(apiUrl, { method: 'POST', headers, body: JSON.stringify(request) }); + + if (!res.ok) { + const text = await res.text().catch(() => ''); + throw new Error(`llama.cpp request failed (${res.status}): ${text.slice(0, 300)}`); } - const response = await fetch(apiUrl, { - method: 'POST', - headers, - body: JSON.stringify({ messages } satisfies LlamaRequest), - }); + const data = (await res.json()) as LlamaResponse; + const choice = data.choices?.[0]; - if (!response.ok) { - const text = await response.text().catch(() => ''); - throw new Error(`llama.cpp request failed (${response.status}): ${text.slice(0, 300)}`); + if (!choice?.message || !choice.message.content) { + return ''; } - const data = (await response.json()) as LlamaResponse; - const content = data.choices?.[0]?.message?.content?.trim() ?? ''; - return content; + return choice.message.content.trim(); }, async chatWithPreamble(userText: string): Promise { const preamble = getLlamacppPreamble(); - const messages = preamble ? [ - { role: 'system', content: preamble }, - { role: 'user', content: userText }, - ] : [{ role: 'user', content: userText }]; - return this.chat(messages); + const msgs = preamble + ? [{ role: 'system' as const, content: preamble }, { role: 'user' as const, content: userText }] + : [{ role: 'user' as const, content: userText }]; + return this.chat(msgs); + }, + + async chatWithMcpTools(userText: string): Promise { + const preamble = getLlamacppPreamble(); + const initialMessages: LlamaMessage[] = preamble + ? [{ role: 'system', content: preamble }, { role: 'user', content: userText }] + : [{ role: 'user', content: userText }]; + + if (!mcpClient.getReady()) { + console.log('[llama] MCP not ready, falling back to preamble-only chat'); + return this.chatWithPreamble(userText); + } + + const tools = mcpClient.getTools(); + const llamaTools: LlamaToolDefinition[] = tools.map((t) => ({ + type: 'function', + function: { + name: t.name, + description: t.description, + parameters: t.inputSchema, + }, + })); + + return this._chatWithTools(initialMessages, llamaTools); + }, + + async _chatWithTools(messages: LlamaMessage[], tools: LlamaToolDefinition[]): Promise { + const apiUrl = getLlamacppUrl(); + if (!apiUrl) return ''; + + let iter = 0; + const history: LlamaMessage[] = messages.map((m) => ({ ...m })); + + while (iter < MAX_TOOL_ITERATIONS) { + const apiKey = getLlamacppApiKey(); + const headers: Record = { 'Content-Type': 'application/json' }; + if (apiKey) headers['Authorization'] = `Bearer ${apiKey}`; + + const body: LlamaRequest = { messages: history, tools, tool_choice: 'auto' }; + const res = await fetch(apiUrl, { method: 'POST', headers, body: JSON.stringify(body) }); + + if (!res.ok) { + const text = await res.text().catch(() => ''); + throw new Error(`llama.cpp request failed (${res.status}): ${text.slice(0, 300)}`); + } + + const data = (await res.json()) as LlamaResponse; + const choice = data.choices?.[0]; + + if (!choice?.message) { + throw new Error('llama.cpp response has no message'); + } + + if (!choice.message.tool_calls || choice.message.tool_calls.length === 0) { + return choice.message.content?.trim() ?? ''; + } + + history.push({ role: 'assistant', ...choice.message }); + + for (const toolCall of choice.message.tool_calls) { + let resultText = ''; + try { + const args = JSON.parse(toolCall.function.arguments); + resultText = await mcpClient.callTool(toolCall.function.name, args); + } catch (err) { + const msg = err instanceof Error ? err.message : String(err); + resultText = `Error calling tool "${toolCall.function.name}": ${msg}`; + } + + history.push({ + role: 'tool', + content: resultText, + tool_call_id: toolCall.id, + }); + } + + iter++; + } + + throw new Error(`Exceeded max tool-call iterations (${MAX_TOOL_ITERATIONS})`); }, }; diff --git a/backend/src/services/mcp.http.service.ts b/backend/src/services/mcp.http.service.ts deleted file mode 100644 index 6873768..0000000 --- a/backend/src/services/mcp.http.service.ts +++ /dev/null @@ -1,74 +0,0 @@ -import { getMcpUrl } from '../config'; - -class McpHttpService { - private sessionId: string | null = null; - - async callTool(name: string, args: Record): Promise<{ text: string; isError?: boolean }> { - const baseUrl = getMcpUrl(); - if (!baseUrl) { - throw new Error('MCP HTTP service not configured (set MCP_URL env var)'); - } - - const url = `${baseUrl}/mcp`; - - if (!this.sessionId) { - const initRes = await fetch(url, { - method: 'POST', - headers: { 'Content-Type': 'application/json' }, - body: JSON.stringify({ - jsonrpc: '2.0', - id: 1, - method: 'initialize', - params: { - protocolVersion: '2025-03-26', - capabilities: {}, - clientInfo: { name: 'quibot-backend', version: '1.0.0' }, - }, - }), - }); - const initData = await initRes.json(); - this.sessionId = String(initData.sessionId || initData.result?.sessionId); - - await fetch(url, { - method: 'POST', - headers: { 'Content-Type': 'application/json' }, - body: JSON.stringify({ - jsonrpc: '2.0', - id: 2, - method: 'notifications/initialized', - }), - ...(this.sessionId && { headers: { 'Mcp-SessionId': this.sessionId } }), - }); - } - - const res = await fetch(url, { - method: 'POST', - headers: { - 'Content-Type': 'application/json', - ...(this.sessionId && { 'Mcp-SessionId': this.sessionId }), - }, - body: JSON.stringify({ - jsonrpc: '2.0', - id: Date.now(), - method: 'tools/call', - params: { name, arguments: args }, - }), - }); - - const data = await res.json(); - if (data.error) { - return { text: JSON.stringify(data.error), isError: true }; - } - const content = data.result?.content?.[0]; - if (!content?.text) { - throw new Error('MCP tool returned no content'); - } - return { text: content.text }; - } - - async shutdown(): Promise { - this.sessionId = null; - } -} - -export const mcpHttpService = new McpHttpService(); diff --git a/backend/src/services/mcp.service.ts b/backend/src/services/mcp.service.ts new file mode 100644 index 0000000..baad965 --- /dev/null +++ b/backend/src/services/mcp.service.ts @@ -0,0 +1,105 @@ +import { Client } from '@modelcontextprotocol/sdk/client/index.js'; +import { SSEClientTransport } from '@modelcontextprotocol/sdk/client/sse.js'; +import { getMcpUrl } from '../config.js'; + +export interface McpToolDef { + name: string; + description: string; + inputSchema: object; +} + +let mc: Client | null = null; +let cachedTools: McpToolDef[] = []; +let connected = false; +let connecting = false; + +async function connectInternal(): Promise { + if (connected) return; + if (connecting) throw new Error('MCP client connection already in progress'); + connecting = true; + + const rawUrl = getMcpUrl(); + if (!rawUrl) { + console.warn('[mcp] MCP_URL not configured, tools disabled'); + connecting = false; + return; + } + + // Ensure the URL points at the /sse endpoint (FastMCP default) + let connectUrl = rawUrl; + try { + const u = new URL(rawUrl); + if (u.pathname === '/' || u.pathname === '') { + u.pathname = '/sse'; + connectUrl = u.toString(); + } + } catch { + // not a valid URL, use as-is + } + + console.log(`[mcp] Connecting to ${connectUrl}...`); + + try { + mc = new Client( + { name: 'quibot-backend', version: '1.0.0' }, + { capabilities: {} }, + ); + + const transport = new SSEClientTransport(new URL(connectUrl)); + await mc.connect(transport); + + console.log('[mcp] Connected, listing tools...'); + const toolsResult = await mc.listTools(); + cachedTools = (toolsResult.tools ?? []).map((t) => ({ + name: t.name, + description: t.description ?? '', + inputSchema: t.inputSchema as object, + })); + + connected = true; + connecting = false; + console.log(`[mcp] Connected to MCP server with ${cachedTools.length} tool(s): ${cachedTools.map((t) => t.name).join(', ') || '(none)'}`); + } catch (err) { + const msg = err instanceof Error ? err.message : String(err); + connecting = false; + console.error(`[mcp] Connection failed: ${msg}`); + throw err; + } +} + +export const mcpClient = { + async connect(): Promise { + await connectInternal(); + }, + + getReady(): boolean { + return connected; + }, + + getTools(): readonly McpToolDef[] { + return cachedTools; + }, + + async callTool(name: string, args: Record): Promise { + if (!mc) throw new Error('MCP client not connected'); + const result = await mc.callTool({ name, arguments: args }); + const content = result.content as Array<{ type: string; text?: string }>; + const texts = content + .filter((c) => c.type === 'text') + .map((c) => c.text ?? ''); + return texts.join('\n') || '[MCP tool returned no text content]'; + }, + + async shutdown(): Promise { + if (mc) { + try { + await mc.close(); + } catch { + // ignore close errors on shutdown + } + mc = null; + } + connected = false; + cachedTools = []; + }, +}; diff --git a/backend/src/services/mcpClient.service.ts b/backend/src/services/mcpClient.service.ts deleted file mode 100644 index 8ed304e..0000000 --- a/backend/src/services/mcpClient.service.ts +++ /dev/null @@ -1,202 +0,0 @@ -import { spawn, ChildProcess } from 'child_process'; -import { join } from 'path'; -import { fileURLToPath } from 'url'; -import { getMcpUrl } from '../config'; -import { mcpHttpService } from './mcp.http.service'; - -const __filename = fileURLToPath(import.meta.url); -const __dirname = join(__filename, '..'); - -// Path to the compiled MCP server (two levels up from backend/src/) -const MCP_BIN = join(__dirname, '..', '..', 'mcp', 'dist', 'index.js'); - -let _proc: ChildProcess | null = null; -let nextId = 1; -let pending = new Map void; reject: (e: Error) => void }>(); - -function send(msg: Record): number { - const id = nextId++; - _proc!.stdin!.write(JSON.stringify({ jsonrpc: '2.0', id, ...msg }) + '\n'); - return id; -} - -export const mcpClient = { - async start(): Promise { - const hasMcpBin = (() => { - try { - require('fs').accessSync(MCP_BIN); - return true; - } catch { - return false; - } - })(); - - if (!hasMcpBin) { - const url = getMcpUrl(); - if (url) { - console.log('[mcp] Local MCP binary not found, using HTTP service at', url); - return; - } - throw new Error('MCP local binary and HTTP URL both unavailable'); - } - - if (_proc) return; - return new Promise((resolve, reject) => { - _proc = spawn('node', [MCP_BIN], { stdio: ['pipe', 'pipe', 'pipe'], env: { ...process.env } }); - - _proc.stdout!.on('data', (chunk: Buffer) => { - const text = chunk.toString(); - for (const line of text.split('\n')) { - if (!line.trim()) continue; - let parsed: { jsonrpc?: string; id?: number | string; method?: string; result?: unknown; error?: unknown }; - try { parsed = JSON.parse(line); } catch { continue; } - if (parsed.jsonrpc !== '2.0') continue; - if (parsed.method) { - // notifications or responses without matching id — ignore for now - continue; - } - if (!parsed.id) continue; - const p = pending.get(parsed.id); - if (!p) continue; - pending.delete(parsed.id); - if (parsed.error) { - p.reject(new Error(`MCP error: ${JSON.stringify(parsed.error)}`)); - } else { - p.resolve(parsed.result); - } - } - }); - - _proc.stderr!.on('data', (chunk: Buffer) => { - console.log(`[mcp-client] stderr: ${chunk.toString().trim()}`); - }); - - _proc.on('exit', (code, signal) => { - console.error(`[mcp-client] Exited code=${code} signal=${signal}`); - _proc = null; - for (const [, p] of pending) { - p.reject(new Error('MCP client process exited')); - } - pending.clear(); - }); - - _proc.on('error', (err: Error) => { - console.error(`[mcp-client] Error: ${err.message}`); - reject(err); - }); - - // Send initialize request - const initId = send({ - method: 'initialize', - params: { - protocolVersion: '2025-03-26', - capabilities: {}, - clientInfo: { name: 'quibot-backend', version: '1.0.0' }, - }, - }); - - pending.set(initId, { - resolve: () => { - // Send initialized notification - _proc!.stdin!.write( - JSON.stringify({ jsonrpc: '2.0', method: 'notifications/initialized' }) + '\n', - ); - resolve(); - }, - reject, - }); - - setTimeout(() => { - const p = pending.get(initId); - if (p) { - pending.delete(initId); - p.reject(new Error('MCP initialize timed out')); - } - }, 15_000); - }); - }, - - async callTool(name: string, args: Record): Promise<{ text: string; isError?: boolean }> { - if (!_proc) { - await this.start(); - } - - try { - return await this._callToolLocal(name, args); - } catch (localErr) { - const url = getMcpUrl(); - if (url) { - console.log(`[mcp] Local MCP failed: ${localErr instanceof Error ? localErr.message : localErr}. Falling back to HTTP service.`); - return await mcpHttpService.callTool(name, args); - } - throw localErr; - } - }, - - async _callToolLocal(name: string, args: Record): Promise<{ text: string; isError?: boolean }> { - if (!_proc?.stdin) { - throw new Error('MCP client not ready'); - } - - return new Promise((resolve, reject) => { - const id = send({ - method: 'tools/call', - params: { name, arguments: args }, - }); - - let cleared = false; - const timer = setTimeout(() => { - if (cleared) return; - cleared = true; - pending.delete(id); - reject(new Error(`MCP tool "${name}" timed out`)); - }, 180_000); - - pending.set(id, { - resolve: (result: unknown) => { - if (cleared) return; - cleared = true; - clearTimeout(timer); - pending.delete(id); - const res = result as { content?: Array<{ type: string; text?: string }> }; - if (res?.content?.[0]?.text !== undefined) { - resolve({ text: res.content[0].text }); - } else { - reject(new Error('MCP tool returned no content')); - } - }, - reject: (err: Error) => { - if (cleared) return; - cleared = true; - clearTimeout(timer); - reject(err); - }, - }); - }); - }, - - async shutdown(): Promise { - if (!_proc) return; - _proc.kill('SIGTERM'); - const current = _proc; - await new Promise((resolve) => { - let done = false; - const cleanup = () => { - if (done) return; - done = true; - _proc = null; - for (const [, p] of pending) { - p.reject(new Error('MCP client shut down')); - } - pending.clear(); - resolve(); - }; - current.once('exit', () => cleanup()); - setTimeout(() => { - const proc = _proc; - if (proc && !proc.killed) proc.kill('SIGKILL'); - cleanup(); - }, 3000); - }); - }, -}; diff --git a/backend/src/services/piper.service.ts b/backend/src/services/piper.service.ts index 2031cdf..5dc79a5 100644 --- a/backend/src/services/piper.service.ts +++ b/backend/src/services/piper.service.ts @@ -161,7 +161,10 @@ private resolveInitError(err: Error): void { // reject all pending (new format: {resolve, reject}) for (const [, entry] of this.respMap) entry.reject(new Error('piper process exited')); this.respMap.clear(); - if (this.pendingInit) { this.initReject(new Error('piper process exited')); this.pendingInit = null; } + if (this.pendingInit && this.initReject) { + this.initReject(new Error('piper process exited')); + this.pendingInit = null; + } }); // ── cleanup old WAV files every 5 min ── diff --git a/backend/src/services/whisper.service.ts b/backend/src/services/whisper.service.ts index 4a5a137..3b77015 100644 --- a/backend/src/services/whisper.service.ts +++ b/backend/src/services/whisper.service.ts @@ -10,7 +10,7 @@ const SCRIPT_DIR = join(__dirname, '..'); const PYTHON = join(SCRIPT_DIR, '..', '.venv', 'bin', 'python3'); -const whisperModel = process.env.WHISPER_MODEL ?? 'base'; +const whisperModel = process.env.WHISPER_MODEL ?? 'small'; const whisperLanguage = process.env.WHISPER_LANGUAGE ?? 'ca'; interface TranscriptResult { diff --git a/mcp/.gitignore b/mcp/.gitignore index b947077..0cafc1c 100644 --- a/mcp/.gitignore +++ b/mcp/.gitignore @@ -1,2 +1 @@ -node_modules/ -dist/ +.venv/ \ No newline at end of file diff --git a/mcp/mcp_server.py b/mcp/mcp_server.py new file mode 100644 index 0000000..81d6af5 --- /dev/null +++ b/mcp/mcp_server.py @@ -0,0 +1,46 @@ +from fastmcp import FastMCP +import requests +import threading + +mcp = FastMCP("Test MCP server") + +def fire_and_forget(url: str): + try: + requests.get(url, timeout=2) + except Exception: + pass # ignore all errors so it never affects the tool + +@mcp.tool() +def add(a: int, b: int) -> int: + """Add two numbers together""" + return a + b + +@mcp.tool() +def greet(name: str) -> str: + """Greet someome by its name""" + return f"Hello {name}! Welcome!" + +@mcp.tool() +def multiply(a: int, b: int) -> int: + """Multiply two numbers""" + return a * b + +@mcp.tool() +def get_time() -> str: + """Get the current time""" + from datetime import datetime + return datetime.now().strftime("%I:%M %p") + +@mcp.tool() +def moure_brac() -> str: + """Mou els braços""" + + url = "http://quibot.local:8000/greet" + + # start background request (non-blocking) + threading.Thread(target=fire_and_forget, args=(url,), daemon=True).start() + + return "Braços moguts" + +if __name__ == "__main__": + mcp.run(transport="sse", port=5001) \ No newline at end of file diff --git a/mcp/package-lock.json b/mcp/package-lock.json deleted file mode 100644 index afa9845..0000000 --- a/mcp/package-lock.json +++ /dev/null @@ -1,1895 +0,0 @@ -{ - "name": "quibot-mcp", - "version": "1.0.0", - "lockfileVersion": 3, - "requires": true, - "packages": { - "": { - "name": "quibot-mcp", - "version": "1.0.0", - "dependencies": { - "@cfworker/json-schema": "^4.1.1", - "@modelcontextprotocol/sdk": "^1.29.0", - "axios": "^1.7.0", - "form-data": "^4.0.0", - "zod": "^3.25" - }, - "bin": { - "quibot-mcp": "dist/index.js" - }, - "devDependencies": { - "@types/node": "^22.19.21", - "tsx": "^4.19.0", - "typescript": "^5.6.0" - } - }, - "node_modules/@cfworker/json-schema": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/@cfworker/json-schema/-/json-schema-4.1.1.tgz", - "integrity": "sha512-gAmrUZSGtKc3AiBL71iNWxDsyUC5uMaKKGdvzYsBoTW/xi42JQHl7eKV2OYzCUqvc+D2RCcf7EXY2iCyFIk6og==", - "license": "MIT" - }, - "node_modules/@esbuild/aix-ppc64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.28.1.tgz", - "integrity": "sha512-Svl7tq8k/08+p6CXPpRjQ1fKX+1odH/BQbb48fV6fj3CWHhsoIOoY87w1oHXm0qEpkIK3ZfVgp0hed3XBXzXMQ==", - "cpu": [ - "ppc64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "aix" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/android-arm": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.28.1.tgz", - "integrity": "sha512-0k2F129Xdio1TdJfzJ8sy1Q47vUD2NnwdhiAf7drUN1EBTfPf4hsFCtmMgu/6m8JSzsBrlmVjudMBQqOfG8usQ==", - "cpu": [ - "arm" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "android" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/android-arm64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.28.1.tgz", - "integrity": "sha512-34EGEbCIAgosYz6goLcopX6Mo7NyGv9tfwEM2/7Ce2VcVRk568iSvniGWcUXIy7wEDR1wzolcxcriFVrWYcwBg==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "android" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/android-x64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.28.1.tgz", - "integrity": "sha512-dbwY7ltSMDWsRatcRpCnES4F+im88OCUgGZjy52shC7GqHRE/cYlxNbB4Z4UpJswpcc4Qxd2oE/ufM0p61IKng==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "android" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/darwin-arm64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.28.1.tgz", - "integrity": "sha512-TZbWkQY7kvTAXbXUT7uVACR5cMHsDiSz9z7ZKAX/RTq/WJEk3QyRr0wZpNhBDX+/0CtdqUIJlOiodQcta6tY3Q==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/darwin-x64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.28.1.tgz", - "integrity": "sha512-zfdzgK9ACBNZLI/CyHTOx81SyNbM6YXn7rxSgX97VjyiPl9W1i4Ka4fgKECEoFCKGpvBj5qArWIGgQjOwkgskQ==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/freebsd-arm64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.28.1.tgz", - "integrity": "sha512-wG2EA8ENdEI0qhkSZMjfqrdY+ziCYCPMmtZjjIwOmXFjmyzEHn+UUxk5of+SYsjtfs3VpnlC7QLzSI5hY/rOAw==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/freebsd-x64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.28.1.tgz", - "integrity": "sha512-i7dZ9vQgnvSCzi/rYCXNgtF/U+eKZNJBzu3eTQbRgHnM7tNSizLOkRFAl3qzVc/Op/u5YkHHa4pf/3DOYHthLQ==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-arm": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.28.1.tgz", - "integrity": "sha512-qVXBOHQS+d5Y722GwJzJUtOLlX7km3CraOaGormF1pDtPd2C/l1SHRPgjLunLGe51Sh5YYWKMFDyV4SxgMQYTQ==", - "cpu": [ - "arm" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-arm64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.28.1.tgz", - "integrity": "sha512-yHs+0uc8+nvEAfAfxrWQKK5peSNzBc4PegcMO0EJ2hT71uA7vB8Ihg2e77R2P7SG5uYjPbHlLLmve4LLLRCf0g==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-ia32": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.28.1.tgz", - "integrity": "sha512-d1z4ZuP0ajrfz/FhGT4vv278rX8KnPPJx8i5+AtK7TYbx9Le9F1hyzurZpkEyjkGa9dUGhQow4C1NmeGvqxN2w==", - "cpu": [ - "ia32" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-loong64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.28.1.tgz", - "integrity": "sha512-M5sRjUVZrkm1OAPR3dlOYzNmN+loZKGVi1VUQGrwuqLcbR6qeAz+famMhjASeH3YVKvZz+zT1jlh/keC3Rj/lg==", - "cpu": [ - "loong64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-mips64el": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.28.1.tgz", - "integrity": "sha512-mRObBZeHh2OxcBFPWE/FjylkRgZdYuiTR3vaTozquCGOH14iP9oN4x4Ge81CoIDYQrXmIxpFumJBu5MtZpnQJQ==", - "cpu": [ - "mips64el" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-ppc64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.28.1.tgz", - "integrity": "sha512-slScBsMAb3GFDcdrCgLwZtPYRoH2H/youv10QiZyRjmsP48fznoveWytSgCI/R0ZcUgpc0ZhIUEx6LHts8yrfQ==", - "cpu": [ - "ppc64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-riscv64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.28.1.tgz", - "integrity": "sha512-kw0owk1o0GFETUJyW0jc0G4Yzs0BHZn0JDZ8JRT088vjJYX777BAs1fDGxAC+q831qOs2DTC96mNsG2opdfyyQ==", - "cpu": [ - "riscv64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-s390x": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.28.1.tgz", - "integrity": "sha512-/lAIjX8aYFRByhh6L5rYtPEDRqa9de/4V/juOXcta5frjvzXO4/sqEtyytse0g3zZFuWu5cDN0MkLz2qRDD2Ag==", - "cpu": [ - "s390x" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-x64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.28.1.tgz", - "integrity": "sha512-u/anNYF2mmVOEDwLtnQ1wOr3EZ9sTNGLWrsYGYwHWzGA3Si84IOkHXlbWTD1NB+9/1lcnweYKO54uhxZydNzfA==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/netbsd-arm64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.28.1.tgz", - "integrity": "sha512-oks0DYbLwWMmaakTsCb+zL4E+aHRVLom9IJZOAthMQEPiQmydXHkziYEsGYRx0uNV/IjEKGAV941JzH02pflqw==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/netbsd-x64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.28.1.tgz", - "integrity": "sha512-aeL6lAnN89Hz43Mlh1G8ARasbuoYvSITDEx0tHh5b7jJnHcssqgjy9Yx430GDpmCa6OyrKoS0aNRjKundRizGg==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/openbsd-arm64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.28.1.tgz", - "integrity": "sha512-MEFJe5C3R8pwXdZ5Y21oo6m7ePiS0d9pWucn99O/wvyJZChoIQKrQDxKrGeW8F5+T0okTHesAmDeiHDTIq0V/Q==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/openbsd-x64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.28.1.tgz", - "integrity": "sha512-i/ZLIOafE0Z8cI/XANJAixoJL/uRAoS2xOA3rb0xN+KK0K177cMAsQYkzHtBrtMXAKuAc7HGgcWiZ/sRC1Nxgw==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/openharmony-arm64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.28.1.tgz", - "integrity": "sha512-ge+Z7EXFNt2BO1oAMsVpiQ8EwndV9i1xXerAeTIK7AtPs3bKFXQM7nlRxDSIUIMeueR1CNXxqztLzdNeReKBJg==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openharmony" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/sunos-x64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.28.1.tgz", - "integrity": "sha512-BEjgtECkL3vY+SaSQ6nzVfiALUeFxpawyp8Jmf5PtYhf1Ug40N1h/hxlhts+f1FvSvarEigdxS3BlSMI2PJLcQ==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "sunos" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/win32-arm64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.28.1.tgz", - "integrity": "sha512-lCv9eK/H6ZJWbE7bh2nw54CZ9M2nupBxJcTsdk/QQnWkdSjKGuxmmH8/GWrlT1eMmZfn4dGcCjRte397WqfQXA==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/win32-ia32": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.28.1.tgz", - "integrity": "sha512-zvb/mB2bSCoJOpoCBgYKKpX6YM6mJBlBUVUtVj41DlZJVEB6/0CKlRYxP5wWl1C1ILiCoAU5wZZ4q1P3qeS6Eg==", - "cpu": [ - "ia32" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/win32-x64": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.28.1.tgz", - "integrity": "sha512-bm4Mowrv+GXMlpWX++EcXw/iLyd1o3+bJkC2DkWXYVvgZCqD/bSj9ctZeAMC3cIxgjRVR2Dufaiu4YPxr5gW1A==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@hono/node-server": { - "version": "1.19.14", - "resolved": "https://registry.npmjs.org/@hono/node-server/-/node-server-1.19.14.tgz", - "integrity": "sha512-GwtvgtXxnWsucXvbQXkRgqksiH2Qed37H9xHZocE5sA3N8O8O8/8FA3uclQXxXVzc9XBZuEOMK7+r02FmSpHtw==", - "license": "MIT", - "engines": { - "node": ">=18.14.1" - }, - "peerDependencies": { - "hono": "^4" - } - }, - "node_modules/@modelcontextprotocol/sdk": { - "version": "1.29.0", - "resolved": "https://registry.npmjs.org/@modelcontextprotocol/sdk/-/sdk-1.29.0.tgz", - "integrity": "sha512-zo37mZA9hJWpULgkRpowewez1y6ML5GsXJPY8FI0tBBCd77HEvza4jDqRKOXgHNn867PVGCyTdzqpz0izu5ZjQ==", - "license": "MIT", - "dependencies": { - "@hono/node-server": "^1.19.9", - "ajv": "^8.17.1", - "ajv-formats": "^3.0.1", - "content-type": "^1.0.5", - "cors": "^2.8.5", - "cross-spawn": "^7.0.5", - "eventsource": "^3.0.2", - "eventsource-parser": "^3.0.0", - "express": "^5.2.1", - "express-rate-limit": "^8.2.1", - "hono": "^4.11.4", - "jose": "^6.1.3", - "json-schema-typed": "^8.0.2", - "pkce-challenge": "^5.0.0", - "raw-body": "^3.0.0", - "zod": "^3.25 || ^4.0", - "zod-to-json-schema": "^3.25.1" - }, - "engines": { - "node": ">=18" - }, - "peerDependencies": { - "@cfworker/json-schema": "^4.1.1", - "zod": "^3.25 || ^4.0" - }, - "peerDependenciesMeta": { - "@cfworker/json-schema": { - "optional": true - }, - "zod": { - "optional": false - } - } - }, - "node_modules/@types/node": { - "version": "22.19.21", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.19.21.tgz", - "integrity": "sha512-VMeFBSCKQKmm2swI2kW51SFusDqekC6q9trBCvJ/JliDchFSuoYYKN7yVNjPthP1HKZcx3U1gI/wTcEBjEFKTA==", - "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.21.0" - } - }, - "node_modules/accepts": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/accepts/-/accepts-2.0.0.tgz", - "integrity": "sha512-5cvg6CtKwfgdmVqY1WIiXKc3Q1bkRqGLi+2W/6ao+6Y7gu/RCwRuAhGEzh5B4KlszSuTLgZYuqFqo5bImjNKng==", - "license": "MIT", - "dependencies": { - "mime-types": "^3.0.0", - "negotiator": "^1.0.0" - }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/agent-base": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz", - "integrity": "sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==", - "license": "MIT", - "dependencies": { - "debug": "4" - }, - "engines": { - "node": ">= 6.0.0" - } - }, - "node_modules/ajv": { - "version": "8.20.0", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.20.0.tgz", - "integrity": "sha512-Thbli+OlOj+iMPYFBVBfJ3OmCAnaSyNn4M1vz9T6Gka5Jt9ba/HIR56joy65tY6kx/FCF5VXNB819Y7/GUrBGA==", - "license": "MIT", - "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/ajv-formats": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/ajv-formats/-/ajv-formats-3.0.1.tgz", - "integrity": "sha512-8iUql50EUR+uUcdRQ3HDqa6EVyo3docL8g5WJ3FNcWmu62IbkGUue/pEyLBW8VGKKucTPgqeks4fIU1DA4yowQ==", - "license": "MIT", - "dependencies": { - "ajv": "^8.0.0" - }, - "peerDependencies": { - "ajv": "^8.0.0" - }, - "peerDependenciesMeta": { - "ajv": { - "optional": true - } - } - }, - "node_modules/asynckit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", - "license": "MIT" - }, - "node_modules/axios": { - "version": "1.18.0", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.18.0.tgz", - "integrity": "sha512-E32NzpYKp++W7XRe52rHiXV2ehxmh3wbdgO7MHeFM+vqxLBYHzt0ElkiImtOBxtOmyp0yoC8C6uESVV84Y2/hw==", - "license": "MIT", - "dependencies": { - "follow-redirects": "^1.16.0", - "form-data": "^4.0.5", - "https-proxy-agent": "^5.0.1", - "proxy-from-env": "^2.1.0" - } - }, - "node_modules/body-parser": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-2.3.0.tgz", - "integrity": "sha512-2cGmJupaNgg+QUwVLAucDuWuoMZ6EX9iHDRswZ5lsNYEmwPaRknMPCLZz07yTzVq/83p4o/wzbDZbBrTvGGTIw==", - "license": "MIT", - "dependencies": { - "bytes": "^3.1.2", - "content-type": "^2.0.0", - "debug": "^4.4.3", - "http-errors": "^2.0.1", - "iconv-lite": "^0.7.2", - "on-finished": "^2.4.1", - "qs": "^6.15.2", - "raw-body": "^3.0.2", - "type-is": "^2.1.0" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/body-parser/node_modules/content-type": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/content-type/-/content-type-2.0.0.tgz", - "integrity": "sha512-j/O/d7GcZCyNl7/hwZAb606rzqkyvaDctLmckbxLzHvFBzTJHuGEdodATcP3yIRoDrLHkIATJuvzbFlp/ki2cQ==", - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/bytes": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", - "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/call-bind-apply-helpers": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz", - "integrity": "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==", - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "function-bind": "^1.1.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/call-bound": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/call-bound/-/call-bound-1.0.4.tgz", - "integrity": "sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==", - "license": "MIT", - "dependencies": { - "call-bind-apply-helpers": "^1.0.2", - "get-intrinsic": "^1.3.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/combined-stream": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", - "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", - "license": "MIT", - "dependencies": { - "delayed-stream": "~1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/content-disposition": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-1.1.0.tgz", - "integrity": "sha512-5jRCH9Z/+DRP7rkvY83B+yGIGX96OYdJmzngqnw2SBSxqCFPd0w2km3s5iawpGX8krnwSGmF0FW5Nhr0Hfai3g==", - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/content-type": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.5.tgz", - "integrity": "sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==", - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/cookie": { - "version": "0.7.2", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.7.2.tgz", - "integrity": "sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==", - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/cookie-signature": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.2.2.tgz", - "integrity": "sha512-D76uU73ulSXrD1UXF4KE2TMxVVwhsnCgfAyTg9k8P6KGZjlXKrOLe4dJQKI3Bxi5wjesZoFXJWElNWBjPZMbhg==", - "license": "MIT", - "engines": { - "node": ">=6.6.0" - } - }, - "node_modules/cors": { - "version": "2.8.6", - "resolved": "https://registry.npmjs.org/cors/-/cors-2.8.6.tgz", - "integrity": "sha512-tJtZBBHA6vjIAaF6EnIaq6laBBP9aq/Y3ouVJjEfoHbRBcHBAHYcMh/w8LDrk2PvIMMq8gmopa5D4V8RmbrxGw==", - "license": "MIT", - "dependencies": { - "object-assign": "^4", - "vary": "^1" - }, - "engines": { - "node": ">= 0.10" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/cross-spawn": { - "version": "7.0.6", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", - "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", - "license": "MIT", - "dependencies": { - "path-key": "^3.1.0", - "shebang-command": "^2.0.0", - "which": "^2.0.1" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/debug": { - "version": "4.4.3", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.3.tgz", - "integrity": "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==", - "license": "MIT", - "dependencies": { - "ms": "^2.1.3" - }, - "engines": { - "node": ">=6.0" - }, - "peerDependenciesMeta": { - "supports-color": { - "optional": true - } - } - }, - "node_modules/delayed-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", - "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", - "license": "MIT", - "engines": { - "node": ">=0.4.0" - } - }, - "node_modules/depd": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", - "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/dunder-proto": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz", - "integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==", - "license": "MIT", - "dependencies": { - "call-bind-apply-helpers": "^1.0.1", - "es-errors": "^1.3.0", - "gopd": "^1.2.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/ee-first": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", - "integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==", - "license": "MIT" - }, - "node_modules/encodeurl": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", - "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/es-define-property": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz", - "integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==", - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-errors": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", - "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-object-atoms": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.2.tgz", - "integrity": "sha512-HWcBoN6NileqtSydK2FqHbS/LoDd2pqrnQHLyJzBj4kOp/ky2MWMN694xOfkK8/SnUsW2DH7EfyVlydKCsm1Zw==", - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-set-tostringtag": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.1.0.tgz", - "integrity": "sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA==", - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.6", - "has-tostringtag": "^1.0.2", - "hasown": "^2.0.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/esbuild": { - "version": "0.28.1", - "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.28.1.tgz", - "integrity": "sha512-HrJrvZv5ayxBzPfwphOoNzkzOIIlifzk0KJrGK2c8R4+LKpMtpYLQeUdjnwjWv/LZlkH2laZk+4w78pi99D4Vw==", - "dev": true, - "hasInstallScript": true, - "license": "MIT", - "bin": { - "esbuild": "bin/esbuild" - }, - "engines": { - "node": ">=18" - }, - "optionalDependencies": { - "@esbuild/aix-ppc64": "0.28.1", - "@esbuild/android-arm": "0.28.1", - "@esbuild/android-arm64": "0.28.1", - "@esbuild/android-x64": "0.28.1", - "@esbuild/darwin-arm64": "0.28.1", - "@esbuild/darwin-x64": "0.28.1", - "@esbuild/freebsd-arm64": "0.28.1", - "@esbuild/freebsd-x64": "0.28.1", - "@esbuild/linux-arm": "0.28.1", - "@esbuild/linux-arm64": "0.28.1", - "@esbuild/linux-ia32": "0.28.1", - "@esbuild/linux-loong64": "0.28.1", - "@esbuild/linux-mips64el": "0.28.1", - "@esbuild/linux-ppc64": "0.28.1", - "@esbuild/linux-riscv64": "0.28.1", - "@esbuild/linux-s390x": "0.28.1", - "@esbuild/linux-x64": "0.28.1", - "@esbuild/netbsd-arm64": "0.28.1", - "@esbuild/netbsd-x64": "0.28.1", - "@esbuild/openbsd-arm64": "0.28.1", - "@esbuild/openbsd-x64": "0.28.1", - "@esbuild/openharmony-arm64": "0.28.1", - "@esbuild/sunos-x64": "0.28.1", - "@esbuild/win32-arm64": "0.28.1", - "@esbuild/win32-ia32": "0.28.1", - "@esbuild/win32-x64": "0.28.1" - } - }, - "node_modules/escape-html": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", - "integrity": "sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==", - "license": "MIT" - }, - "node_modules/etag": { - "version": "1.8.1", - "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", - "integrity": "sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==", - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/eventsource": { - "version": "3.0.7", - "resolved": "https://registry.npmjs.org/eventsource/-/eventsource-3.0.7.tgz", - "integrity": "sha512-CRT1WTyuQoD771GW56XEZFQ/ZoSfWid1alKGDYMmkt2yl8UXrVR4pspqWNEcqKvVIzg6PAltWjxcSSPrboA4iA==", - "license": "MIT", - "dependencies": { - "eventsource-parser": "^3.0.1" - }, - "engines": { - "node": ">=18.0.0" - } - }, - "node_modules/eventsource-parser": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/eventsource-parser/-/eventsource-parser-3.1.0.tgz", - "integrity": "sha512-kJezFj9YFAMLeORyi7aCLxLbD5/qWMQnoMVlVPyHIll7lgRJCc3JVln9Vgl9nwQi0YkMnhdGTMNn7CkRRAptMg==", - "license": "MIT", - "engines": { - "node": ">=18.0.0" - } - }, - "node_modules/express": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/express/-/express-5.2.1.tgz", - "integrity": "sha512-hIS4idWWai69NezIdRt2xFVofaF4j+6INOpJlVOLDO8zXGpUVEVzIYk12UUi2JzjEzWL3IOAxcTubgz9Po0yXw==", - "license": "MIT", - "dependencies": { - "accepts": "^2.0.0", - "body-parser": "^2.2.1", - "content-disposition": "^1.0.0", - "content-type": "^1.0.5", - "cookie": "^0.7.1", - "cookie-signature": "^1.2.1", - "debug": "^4.4.0", - "depd": "^2.0.0", - "encodeurl": "^2.0.0", - "escape-html": "^1.0.3", - "etag": "^1.8.1", - "finalhandler": "^2.1.0", - "fresh": "^2.0.0", - "http-errors": "^2.0.0", - "merge-descriptors": "^2.0.0", - "mime-types": "^3.0.0", - "on-finished": "^2.4.1", - "once": "^1.4.0", - "parseurl": "^1.3.3", - "proxy-addr": "^2.0.7", - "qs": "^6.14.0", - "range-parser": "^1.2.1", - "router": "^2.2.0", - "send": "^1.1.0", - "serve-static": "^2.2.0", - "statuses": "^2.0.1", - "type-is": "^2.0.1", - "vary": "^1.1.2" - }, - "engines": { - "node": ">= 18" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/express-rate-limit": { - "version": "8.5.2", - "resolved": "https://registry.npmjs.org/express-rate-limit/-/express-rate-limit-8.5.2.tgz", - "integrity": "sha512-5Kb34ipNX694DH48vN9irak1Qx30nb0PLYHXfJgw4YEjiC3ZEmZJhwOp+VfiCYwFzvFTdB9QkArYS5kXa2cx2A==", - "license": "MIT", - "dependencies": { - "ip-address": "^10.2.0" - }, - "engines": { - "node": ">= 16" - }, - "funding": { - "url": "https://github.com/sponsors/express-rate-limit" - }, - "peerDependencies": { - "express": ">= 4.11" - } - }, - "node_modules/fast-deep-equal": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", - "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", - "license": "MIT" - }, - "node_modules/fast-uri": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.1.2.tgz", - "integrity": "sha512-rVjf7ArG3LTk+FS6Yw81V1DLuZl1bRbNrev6Tmd/9RaroeeRRJhAt7jg/6YFxbvAQXUCavSoZhPPj6oOx+5KjQ==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/fastify" - }, - { - "type": "opencollective", - "url": "https://opencollective.com/fastify" - } - ], - "license": "BSD-3-Clause" - }, - "node_modules/finalhandler": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-2.1.1.tgz", - "integrity": "sha512-S8KoZgRZN+a5rNwqTxlZZePjT/4cnm0ROV70LedRHZ0p8u9fRID0hJUZQpkKLzro8LfmC8sx23bY6tVNxv8pQA==", - "license": "MIT", - "dependencies": { - "debug": "^4.4.0", - "encodeurl": "^2.0.0", - "escape-html": "^1.0.3", - "on-finished": "^2.4.1", - "parseurl": "^1.3.3", - "statuses": "^2.0.1" - }, - "engines": { - "node": ">= 18.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/follow-redirects": { - "version": "1.16.0", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.16.0.tgz", - "integrity": "sha512-y5rN/uOsadFT/JfYwhxRS5R7Qce+g3zG97+JrtFZlC9klX/W5hD7iiLzScI4nZqUS7DNUdhPgw4xI8W2LuXlUw==", - "funding": [ - { - "type": "individual", - "url": "https://github.com/sponsors/RubenVerborgh" - } - ], - "license": "MIT", - "engines": { - "node": ">=4.0" - }, - "peerDependenciesMeta": { - "debug": { - "optional": true - } - } - }, - "node_modules/form-data": { - "version": "4.0.6", - "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.6.tgz", - "integrity": "sha512-vKatAh4SlVfgbv+YtmhiRjhEMJsYpsG1Y2rMQtR+SVSbytsSD1YGzDIcrAJmdFec88u/+VoGmxnl+80gL1tRCQ==", - "license": "MIT", - "dependencies": { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.8", - "es-set-tostringtag": "^2.1.0", - "hasown": "^2.0.4", - "mime-types": "^2.1.35" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/form-data/node_modules/mime-db": { - "version": "1.52.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", - "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/form-data/node_modules/mime-types": { - "version": "2.1.35", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", - "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", - "license": "MIT", - "dependencies": { - "mime-db": "1.52.0" - }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/forwarded": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz", - "integrity": "sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==", - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/fresh": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/fresh/-/fresh-2.0.0.tgz", - "integrity": "sha512-Rx/WycZ60HOaqLKAi6cHRKKI7zxWbJ31MhntmtwMoaTeF7XFH9hhBp8vITaMidfljRQ6eYWCKkaTK+ykVJHP2A==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/fsevents": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", - "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", - "dev": true, - "hasInstallScript": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": "^8.16.0 || ^10.6.0 || >=11.0.0" - } - }, - "node_modules/function-bind": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", - "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/get-intrinsic": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.3.0.tgz", - "integrity": "sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==", - "license": "MIT", - "dependencies": { - "call-bind-apply-helpers": "^1.0.2", - "es-define-property": "^1.0.1", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.1.1", - "function-bind": "^1.1.2", - "get-proto": "^1.0.1", - "gopd": "^1.2.0", - "has-symbols": "^1.1.0", - "hasown": "^2.0.2", - "math-intrinsics": "^1.1.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/get-proto": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz", - "integrity": "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==", - "license": "MIT", - "dependencies": { - "dunder-proto": "^1.0.1", - "es-object-atoms": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/gopd": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz", - "integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==", - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/has-symbols": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz", - "integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==", - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/has-tostringtag": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz", - "integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==", - "license": "MIT", - "dependencies": { - "has-symbols": "^1.0.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/hasown": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.4.tgz", - "integrity": "sha512-T2UbfbBEF32wiepXIsMlTW9+dDYC6wMh/t/vYA4tuOMKqWz/n3vr1NFSxQiyP+zk2mXsoMA/i/7qV6LKut1t1A==", - "license": "MIT", - "dependencies": { - "function-bind": "^1.1.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/hono": { - "version": "4.12.26", - "resolved": "https://registry.npmjs.org/hono/-/hono-4.12.26.tgz", - "integrity": "sha512-uyZtpnYxM9CmQ7QsQknM4zN8EftNqhON1qYeIKM0Se67CCEe2c44xyGURwB0axX2fBDu1dqHrHAc1hmNT8ITkw==", - "license": "MIT", - "engines": { - "node": ">=16.9.0" - } - }, - "node_modules/http-errors": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.1.tgz", - "integrity": "sha512-4FbRdAX+bSdmo4AUFuS0WNiPz8NgFt+r8ThgNWmlrjQjt1Q7ZR9+zTlce2859x4KSXrwIsaeTqDoKQmtP8pLmQ==", - "license": "MIT", - "dependencies": { - "depd": "~2.0.0", - "inherits": "~2.0.4", - "setprototypeof": "~1.2.0", - "statuses": "~2.0.2", - "toidentifier": "~1.0.1" - }, - "engines": { - "node": ">= 0.8" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/https-proxy-agent": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz", - "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==", - "license": "MIT", - "dependencies": { - "agent-base": "6", - "debug": "4" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/iconv-lite": { - "version": "0.7.2", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.7.2.tgz", - "integrity": "sha512-im9DjEDQ55s9fL4EYzOAv0yMqmMBSZp6G0VvFyTMPKWxiSBHUj9NW/qqLmXUwXrrM7AvqSlTCfvqRb0cM8yYqw==", - "license": "MIT", - "dependencies": { - "safer-buffer": ">= 2.1.2 < 3.0.0" - }, - "engines": { - "node": ">=0.10.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/inherits": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "license": "ISC" - }, - "node_modules/ip-address": { - "version": "10.2.0", - "resolved": "https://registry.npmjs.org/ip-address/-/ip-address-10.2.0.tgz", - "integrity": "sha512-/+S6j4E9AHvW9SWMSEY9Xfy66O5PWvVEJ08O0y5JGyEKQpojb0K0GKpz/v5HJ/G0vi3D2sjGK78119oXZeE0qA==", - "license": "MIT", - "engines": { - "node": ">= 12" - } - }, - "node_modules/ipaddr.js": { - "version": "1.9.1", - "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", - "integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==", - "license": "MIT", - "engines": { - "node": ">= 0.10" - } - }, - "node_modules/is-promise": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-4.0.0.tgz", - "integrity": "sha512-hvpoI6korhJMnej285dSg6nu1+e6uxs7zG3BYAm5byqDsgJNWwxzM6z6iZiAgQR4TJ30JmBTOwqZUw3WlyH3AQ==", - "license": "MIT" - }, - "node_modules/isexe": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", - "license": "ISC" - }, - "node_modules/jose": { - "version": "6.2.3", - "resolved": "https://registry.npmjs.org/jose/-/jose-6.2.3.tgz", - "integrity": "sha512-YYVDInQKFJfR/xa3ojUTl8c2KoTwiL1R5Wg9YCydwH0x0B9grbzlg5HC7mMjCtUJjbQ/YnGEZIhI5tCgfTb4Hw==", - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/panva" - } - }, - "node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "license": "MIT" - }, - "node_modules/json-schema-typed": { - "version": "8.0.2", - "resolved": "https://registry.npmjs.org/json-schema-typed/-/json-schema-typed-8.0.2.tgz", - "integrity": "sha512-fQhoXdcvc3V28x7C7BMs4P5+kNlgUURe2jmUT1T//oBRMDrqy1QPelJimwZGo7Hg9VPV3EQV5Bnq4hbFy2vetA==", - "license": "BSD-2-Clause" - }, - "node_modules/math-intrinsics": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz", - "integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==", - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/media-typer": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-1.1.0.tgz", - "integrity": "sha512-aisnrDP4GNe06UcKFnV5bfMNPBUw4jsLGaWwWfnH3v02GnBuXX2MCVn5RbrWo0j3pczUilYblq7fQ7Nw2t5XKw==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/merge-descriptors": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-2.0.0.tgz", - "integrity": "sha512-Snk314V5ayFLhp3fkUREub6WtjBfPdCPY1Ln8/8munuLuiYhsABgBVWsozAG+MWMbVEvcdcpbi9R7ww22l9Q3g==", - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/mime-db": { - "version": "1.54.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.54.0.tgz", - "integrity": "sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ==", - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/mime-types": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-3.0.2.tgz", - "integrity": "sha512-Lbgzdk0h4juoQ9fCKXW4by0UJqj+nOOrI9MJ1sSj4nI8aI2eo1qmvQEie4VD1glsS250n15LsWsYtCugiStS5A==", - "license": "MIT", - "dependencies": { - "mime-db": "^1.54.0" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/ms": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", - "license": "MIT" - }, - "node_modules/negotiator": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-1.0.0.tgz", - "integrity": "sha512-8Ofs/AUQh8MaEcrlq5xOX0CQ9ypTF5dl78mjlMNfOK08fzpgTHQRQPBxcPlEtIw0yRpws+Zo/3r+5WRby7u3Gg==", - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/object-assign": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", - "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/object-inspect": { - "version": "1.13.4", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.4.tgz", - "integrity": "sha512-W67iLl4J2EXEGTbfeHCffrjDfitvLANg0UlX3wFUUSTx92KXRFegMHUVgSqE+wvhAbi4WqjGg9czysTV2Epbew==", - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/on-finished": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.4.1.tgz", - "integrity": "sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg==", - "license": "MIT", - "dependencies": { - "ee-first": "1.1.1" - }, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/once": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", - "license": "ISC", - "dependencies": { - "wrappy": "1" - } - }, - "node_modules/parseurl": { - "version": "1.3.3", - "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", - "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/path-key": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", - "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/path-to-regexp": { - "version": "8.4.2", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-8.4.2.tgz", - "integrity": "sha512-qRcuIdP69NPm4qbACK+aDogI5CBDMi1jKe0ry5rSQJz8JVLsC7jV8XpiJjGRLLol3N+R5ihGYcrPLTno6pAdBA==", - "license": "MIT", - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/pkce-challenge": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/pkce-challenge/-/pkce-challenge-5.0.1.tgz", - "integrity": "sha512-wQ0b/W4Fr01qtpHlqSqspcj3EhBvimsdh0KlHhH8HRZnMsEa0ea2fTULOXOS9ccQr3om+GcGRk4e+isrZWV8qQ==", - "license": "MIT", - "engines": { - "node": ">=16.20.0" - } - }, - "node_modules/proxy-addr": { - "version": "2.0.7", - "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.7.tgz", - "integrity": "sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==", - "license": "MIT", - "dependencies": { - "forwarded": "0.2.0", - "ipaddr.js": "1.9.1" - }, - "engines": { - "node": ">= 0.10" - } - }, - "node_modules/proxy-from-env": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-2.1.0.tgz", - "integrity": "sha512-cJ+oHTW1VAEa8cJslgmUZrc+sjRKgAKl3Zyse6+PV38hZe/V6Z14TbCuXcan9F9ghlz4QrFr2c92TNF82UkYHA==", - "license": "MIT", - "engines": { - "node": ">=10" - } - }, - "node_modules/qs": { - "version": "6.15.2", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.15.2.tgz", - "integrity": "sha512-Rzq0KEyX/w/tEybncDgdkZrJgVUsUMk3xjh3t5bv3S1HTAtg+uOYt72+ZfwiQwKdysThkTBdL/rTi6HDmX9Ddw==", - "license": "BSD-3-Clause", - "dependencies": { - "side-channel": "^1.1.0" - }, - "engines": { - "node": ">=0.6" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/range-parser": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", - "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==", - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/raw-body": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-3.0.2.tgz", - "integrity": "sha512-K5zQjDllxWkf7Z5xJdV0/B0WTNqx6vxG70zJE4N0kBs4LovmEYWJzQGxC9bS9RAKu3bgM40lrd5zoLJ12MQ5BA==", - "license": "MIT", - "dependencies": { - "bytes": "~3.1.2", - "http-errors": "~2.0.1", - "iconv-lite": "~0.7.0", - "unpipe": "~1.0.0" - }, - "engines": { - "node": ">= 0.10" - } - }, - "node_modules/require-from-string": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", - "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/router": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/router/-/router-2.2.0.tgz", - "integrity": "sha512-nLTrUKm2UyiL7rlhapu/Zl45FwNgkZGaCpZbIHajDYgwlJCOzLSk+cIPAnsEqV955GjILJnKbdQC1nVPz+gAYQ==", - "license": "MIT", - "dependencies": { - "debug": "^4.4.0", - "depd": "^2.0.0", - "is-promise": "^4.0.0", - "parseurl": "^1.3.3", - "path-to-regexp": "^8.0.0" - }, - "engines": { - "node": ">= 18" - } - }, - "node_modules/safer-buffer": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", - "license": "MIT" - }, - "node_modules/send": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/send/-/send-1.2.1.tgz", - "integrity": "sha512-1gnZf7DFcoIcajTjTwjwuDjzuz4PPcY2StKPlsGAQ1+YH20IRVrBaXSWmdjowTJ6u8Rc01PoYOGHXfP1mYcZNQ==", - "license": "MIT", - "dependencies": { - "debug": "^4.4.3", - "encodeurl": "^2.0.0", - "escape-html": "^1.0.3", - "etag": "^1.8.1", - "fresh": "^2.0.0", - "http-errors": "^2.0.1", - "mime-types": "^3.0.2", - "ms": "^2.1.3", - "on-finished": "^2.4.1", - "range-parser": "^1.2.1", - "statuses": "^2.0.2" - }, - "engines": { - "node": ">= 18" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/serve-static": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-2.2.1.tgz", - "integrity": "sha512-xRXBn0pPqQTVQiC8wyQrKs2MOlX24zQ0POGaj0kultvoOCstBQM5yvOhAVSUwOMjQtTvsPWoNCHfPGwaaQJhTw==", - "license": "MIT", - "dependencies": { - "encodeurl": "^2.0.0", - "escape-html": "^1.0.3", - "parseurl": "^1.3.3", - "send": "^1.2.0" - }, - "engines": { - "node": ">= 18" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/setprototypeof": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", - "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", - "license": "ISC" - }, - "node_modules/shebang-command": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", - "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", - "license": "MIT", - "dependencies": { - "shebang-regex": "^3.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/shebang-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", - "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/side-channel": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.1.1.tgz", - "integrity": "sha512-6x6dK6zJdpTzF4sQeNYxwtvBzf6Eg4GtlesS94HOvTudUeyK2WXAaIfmDgsyslYrRBeFIlsi54AYsFGUuhmvrQ==", - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "object-inspect": "^1.13.4", - "side-channel-list": "^1.0.1", - "side-channel-map": "^1.0.1", - "side-channel-weakmap": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/side-channel-list": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/side-channel-list/-/side-channel-list-1.0.1.tgz", - "integrity": "sha512-mjn/0bi/oUURjc5Xl7IaWi/OJJJumuoJFQJfDDyO46+hBWsfaVM65TBHq2eoZBhzl9EchxOijpkbRC8SVBQU0w==", - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "object-inspect": "^1.13.4" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/side-channel-map": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/side-channel-map/-/side-channel-map-1.0.1.tgz", - "integrity": "sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==", - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.2", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.5", - "object-inspect": "^1.13.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/side-channel-weakmap": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/side-channel-weakmap/-/side-channel-weakmap-1.0.2.tgz", - "integrity": "sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==", - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.2", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.5", - "object-inspect": "^1.13.3", - "side-channel-map": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/statuses": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.2.tgz", - "integrity": "sha512-DvEy55V3DB7uknRo+4iOGT5fP1slR8wQohVdknigZPMpMstaKJQWhwiYBACJE3Ul2pTnATihhBYnRhZQHGBiRw==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/toidentifier": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.1.tgz", - "integrity": "sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==", - "license": "MIT", - "engines": { - "node": ">=0.6" - } - }, - "node_modules/tsx": { - "version": "4.22.4", - "resolved": "https://registry.npmjs.org/tsx/-/tsx-4.22.4.tgz", - "integrity": "sha512-X8EX+XV4QR5xCsrgxaED954zTDfY8KqlDtskKEL0cHhyS/P8b4IFOvGDQpsC9Q1XnLq915wEfwwY/zzskCtmhg==", - "dev": true, - "license": "MIT", - "dependencies": { - "esbuild": "~0.28.0" - }, - "bin": { - "tsx": "dist/cli.mjs" - }, - "engines": { - "node": ">=18.0.0" - }, - "optionalDependencies": { - "fsevents": "~2.3.3" - } - }, - "node_modules/type-is": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/type-is/-/type-is-2.1.0.tgz", - "integrity": "sha512-faYHw0anBbc/kWF3zFTEnxSFOAGUX9GFbOBthvDdLsIlEoWOFOtS0zgCiQYwIskL9iGXZL3kAXD8OoZ4GmMATA==", - "license": "MIT", - "dependencies": { - "content-type": "^2.0.0", - "media-typer": "^1.1.0", - "mime-types": "^3.0.0" - }, - "engines": { - "node": ">= 18" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/type-is/node_modules/content-type": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/content-type/-/content-type-2.0.0.tgz", - "integrity": "sha512-j/O/d7GcZCyNl7/hwZAb606rzqkyvaDctLmckbxLzHvFBzTJHuGEdodATcP3yIRoDrLHkIATJuvzbFlp/ki2cQ==", - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/express" - } - }, - "node_modules/typescript": { - "version": "5.9.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz", - "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", - "dev": true, - "license": "Apache-2.0", - "bin": { - "tsc": "bin/tsc", - "tsserver": "bin/tsserver" - }, - "engines": { - "node": ">=14.17" - } - }, - "node_modules/undici-types": { - "version": "6.21.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", - "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/unpipe": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", - "integrity": "sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/vary": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", - "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/which": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", - "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "license": "ISC", - "dependencies": { - "isexe": "^2.0.0" - }, - "bin": { - "node-which": "bin/node-which" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/wrappy": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", - "license": "ISC" - }, - "node_modules/zod": { - "version": "3.25.76", - "resolved": "https://registry.npmjs.org/zod/-/zod-3.25.76.tgz", - "integrity": "sha512-gzUt/qt81nXsFGKIFcC3YnfEAx5NkunCfnDlvuBSSFS02bcXu4Lmea0AFIUwbLWxWPx3d9p8S5QoaujKcNQxcQ==", - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/colinhacks" - } - }, - "node_modules/zod-to-json-schema": { - "version": "3.25.2", - "resolved": "https://registry.npmjs.org/zod-to-json-schema/-/zod-to-json-schema-3.25.2.tgz", - "integrity": "sha512-O/PgfnpT1xKSDeQYSCfRI5Gy3hPf91mKVDuYLUHZJMiDFptvP41MSnWofm8dnCm0256ZNfZIM7DSzuSMAFnjHA==", - "license": "ISC", - "peerDependencies": { - "zod": "^3.25.28 || ^4" - } - } - } -} diff --git a/mcp/package.json b/mcp/package.json deleted file mode 100644 index b7edf5c..0000000 --- a/mcp/package.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - "name": "quibot-mcp", - "version": "1.0.0", - "description": "QuiBot MCP server — exposes robot controls as MCP tools and resources", - "type": "module", - "bin": { - "quibot-mcp": "./dist/index.js" - }, - "scripts": { - "build": "tsc", - "start": "node dist/index.js", - "dev": "tsx src/index.ts" - }, - "dependencies": { - "@cfworker/json-schema": "^4.1.1", - "@modelcontextprotocol/sdk": "^1.29.0", - "axios": "^1.7.0", - "form-data": "^4.0.0", - "zod": "^3.25" - }, - "devDependencies": { - "@types/node": "^22.19.21", - "tsx": "^4.19.0", - "typescript": "^5.6.0" - } -} diff --git a/mcp/src/index.ts b/mcp/src/index.ts deleted file mode 100644 index c5e9670..0000000 --- a/mcp/src/index.ts +++ /dev/null @@ -1,581 +0,0 @@ -#!/usr/bin/env node -import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js"; -import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js"; -import axios, { AxiosError } from "axios"; -import * as z from "zod"; -import fs from "node:fs"; - -// --- Config from env (same as backend) --- -const RASPBERRY_PI_HOST = process.env.RASPBERRY_PI_HOST ?? "http://raspberrypi.local"; -const RASPBERRY_PI_PORT = Number(process.env.RASPBERRY_PI_PORT) || 8000; -const QUIBOT_TOKEN = process.env.QUIBOT_TOKEN ?? "MY_SECRET_TOKEN"; - -const RPI_URL = `${RASPBERRY_PI_HOST}:${RASPBERRY_PI_PORT}`; - -function rpiUrl(path: string, query?: Record): string { - const url = `${RPI_URL}${path}`; - if (!query) return url; - const q = new URLSearchParams({ token: QUIBOT_TOKEN, ...query }); - return `${url}?${q}`; -} - -// --- Helpers --- -async function rpiPost(path: string, query?: Record, body?: unknown): Promise { - try { - const res = await axios.post(rpiUrl(path, query), body, { timeout: 10000 }); - return res.data; - } catch (err) { - if (err instanceof AxiosError && err.response) { - throw new Error(`Pi error ${err.response.status}: ${JSON.stringify(err.response.data)}`); - } - throw err; - } -} - -async function rpiGet(path: string, query?: Record): Promise { - try { - const res = await axios.get(rpiUrl(path, query), { timeout: 10000 }); - return res.data; - } catch (err) { - if (err instanceof AxiosError && err.response) { - throw new Error(`Pi error ${err.response.status}: ${JSON.stringify(err.response.data)}`); - } - throw err; - } -} - -async function rpiPostMultipart(path: string, formData: FormData): Promise { - try { - const res = await axios.post(rpiUrl(path), formData, { - timeout: 30000, - headers: { "Content-Type": "multipart/form-data" }, - }); - return res.data; - } catch (err) { - if (err instanceof AxiosError && err.response) { - throw new Error(`Pi error ${err.response.status}: ${JSON.stringify(err.response.data)}`); - } - throw err; - } -} - -// --- MCP Server --- -const server = new McpServer({ - name: "quibot", - version: "1.0.0", -}); - -// === TOOLS === - -server.registerTool( - "motor_step", - { - description: "Move stepper motors in a direction (fire-and-forget — motor runs until stop)", - inputSchema: z.object({ - direction: z.enum(["forward", "backward", "left", "right"]), - }), - }, - async ({ direction }) => { - const piPath = direction === "backward" ? "/motor/step/backwards" : `/motor/step/${direction}`; - try { - const result = await rpiPost(piPath); - return { - content: [{ type: "text", text: JSON.stringify(result) }], - }; - } catch (err) { - const msg = err instanceof Error ? err.message : String(err); - return { - content: [{ type: "text", text: `Error: ${msg}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "motor_stop", - { - description: "Stop all stepper motors immediately (disables driver via GPIO EN)", - inputSchema: z.object({}), - }, - async () => { - try { - const result = await rpiPost("/motor/stop"); - return { content: [{ type: "text", text: JSON.stringify(result) }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "audio_upload_transcribe", - { - description: - "Upload an audio file to the Raspberry Pi and get transcription + LLM response. The Pi runs Whisper for transcription and llamacpp with preamble for response.", - inputSchema: z.object({ - audioBase64: z.string().describe("Base64-encoded audio file"), - format: z.string().describe("Audio format (wav, m4a, mp3, etc.)"), - }), - }, - async ({ audioBase64, format }) => { - try { - const buffer = Buffer.from(audioBase64, "base64"); - const formData = new FormData(); - const fname = `audio-upload-${Date.now()}.${format}`; - formData.append("file", new Blob([buffer]), fname); - - const result = await rpiPostMultipart("/transcribe", formData); - return { content: [{ type: "text", text: JSON.stringify(result) }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "motor_upload", - { - description: "Upload an audio file to the Raspberry Pi for processing", - inputSchema: z.object({ - filePath: z.string().describe("Path to audio file on local machine"), - format: z.string().describe("Audio format (wav, m4a, mp3, etc.)"), - }), - }, - async ({ filePath, format }) => { - try { - if (!fs.existsSync(filePath)) { - return { content: [{ type: "text", text: `File not found: ${filePath}` }], isError: true }; - } - const fd = new (await import("form-data")).default(); - fd.append("file", fs.createReadStream(filePath)); - fd.append("format", format); - await axios.post(`${RPI_URL}/audio/upload?format=${format}&token=${QUIBOT_TOKEN}`, fd, { - headers: fd.getHeaders(), - timeout: 30000, - }); - return { content: [{ type: "text", text: `Uploaded: ${filePath}` }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "audio_list", - { - description: "List incoming audio files on the Raspberry Pi", - inputSchema: z.object({}), - }, - async () => { - try { - const files = await rpiGet("/audio/incoming"); - return { content: [{ type: "text", text: JSON.stringify(files, null, 2) }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "audio_lifecycle", - { - description: "Manage audio file lifecycle: lock, unlock, cancel, or process a file", - inputSchema: z.object({ - filename: z.string().describe("Audio filename"), - action: z.enum(["lock", "unlock", "cancel", "process"]).describe("Lifecycle action to perform"), - }), - }, - async ({ filename, action }) => { - try { - const result = await rpiPost(`/audio/${action}/${filename}`); - return { content: [{ type: "text", text: JSON.stringify(result) }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "eye_set_shape", - { - description: "Set the LED eye shape on the robot's WS2811 matrix", - inputSchema: z.object({ - shape: z.enum(["EYES_OPEN", "EYES_FW", "EYES_DOWN", "EYES_GESTURE"]).describe("Eye shape pattern"), - }), - }, - async ({ shape }) => { - try { - const result = await rpiPost(`/eye/shape/${shape}`); - return { content: [{ type: "text", text: JSON.stringify(result) }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "eye_set_color", - { - description: "Set the LED eye color on the robot's WS2811 matrix", - inputSchema: z.object({ - color: z.enum(["RED", "GREEN", "BLUE", "YELLOW", "CYAN", "MAGENTA", "WHITE", "OFF", "ORANGE", "VIOLET", "DARK_RED"]).describe("Eye color name"), - }), - }, - async ({ color }) => { - try { - const result = await rpiPost(`/eye/color/${color}`); - return { content: [{ type: "text", text: JSON.stringify(result) }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "eye_toggle", - { - description: "Turn eyes on or off (enable/disable LED matrix breathing thread)", - inputSchema: z.object({ - state: z.enum(["on", "off"]).describe("Eye power state"), - }), - }, - async ({ state }) => { - try { - const result = await rpiPost(`/eye/${state}`); - return { content: [{ type: "text", text: JSON.stringify(result) }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "gesture_toggle_mode", - { - description: "Toggle between block mode and gesture mode on the robot", - inputSchema: z.object({}), - }, - async () => { - try { - const result = await rpiPost("/gesture/toggle"); - return { content: [{ type: "text", text: JSON.stringify(result) }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "gesture_on", - { - description: "Enable gesture sensor polling (PAJ7620U2)", - inputSchema: z.object({}), - }, - async () => { - try { - const result = await rpiPost("/gesture/on"); - return { content: [{ type: "text", text: JSON.stringify(result) }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "gesture_off", - { - description: "Disable gesture sensor polling", - inputSchema: z.object({}), - }, - async () => { - try { - const result = await rpiPost("/gesture/off"); - return { content: [{ type: "text", text: JSON.stringify(result) }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "run_command", - { - description: "Run a whitelisted system command on the Raspberry Pi", - inputSchema: z.object({ - task: z.enum(["restart_nginx", "uptime", "update"]).describe("Command to run"), - }), - }, - async ({ task }) => { - try { - const result = await rpiPost("/run", { task }); - return { content: [{ type: "text", text: JSON.stringify(result) }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -server.registerTool( - "tts_speak", - { - description: "Synthesize speech via Piper TTS and play it on the Raspberry Pi", - inputSchema: z.object({ - text: z.string().describe("Text to speak"), - lang: z.string().default("ca").describe("Language code (ca, es, en)"), - }), - }, - async ({ text, lang }) => { - try { - const result = await rpiGet("/tts", { text, lang: lang || "ca" }); - return { content: [{ type: "text", text: JSON.stringify(result) }] }; - } catch (err) { - return { - content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], - isError: true, - }; - } - }, -); - -// === RESOURCES === - -server.registerResource( - "config", - "quibot://config", - { description: "Current Raspberry Pi connection config and token" }, - async () => ({ - contents: [ - { - uri: "quibot://config", - name: "QuiBot Configuration", - mimeType: "application/json", - text: JSON.stringify( - { raspberryPiHost: RASPBERRY_PI_HOST, raspberryPiPort: RASPBERRY_PI_PORT, token: QUIBOT_TOKEN }, - null, - 2, - ), - }, - ], - }), -); - -server.registerResource( - "available-directions", - "quibot://directions", - { description: "Available motor movement directions" }, - async () => ({ - contents: [ - { - uri: "quibot://directions", - name: "Available Motor Directions", - mimeType: "text/plain", - text: ["forward", "backward"].map((d) => ` POST /motor/step/${d}`).join("\n"), - }, - ], - }), -); - -server.registerResource( - "eye-shapes", - "quibot://eyes/shapes", - { description: "Available LED eye shapes and their meanings" }, - async () => ({ - contents: [ - { - uri: "quibot://eyes/shapes", - name: "Available Eye Shapes", - mimeType: "text/plain", - text: [ - " EYES_OPEN — Normal resting eyes (default)", - " EYES_FW — Forward-looking eyes", - " EYES_DOWN — Downward/downcast eyes", - " EYES_GESTURE — Gesture-acknowledge eyes", - ].join("\n"), - }, - ], - }), -); - -server.registerResource( - "color-actions", - "quibot://blocks/colors", - { description: "Color-to-action mapping for block recognition" }, - async () => ({ - contents: [ - { - uri: "quibot://blocks/colors", - name: "Color Block Actions", - mimeType: "text/plain", - text: [ - " RED → Advance forward", - " GREEN → Turn right", - " BLUE → Turn left", - " YELLOW → Take / pick up block", - " ORANGE → Leave / eject block", - " VIOLET → Idle", - " BLACK → Reference / no block", - ].join("\n"), - }, - ], - }), -); - -server.registerResource( - "gestures", - "quibot://gestures", - { description: "Available PAJ7620U2 gestures" }, - async () => ({ - contents: [ - { - uri: "quibot://gestures", - name: "Available Gestures", - mimeType: "text/plain", - text: [ - " GS_FORWARD → Hand moving forward (toward sensor)", - " GS_BACKWARD → Hand moving backward (away from sensor)", - " GS_LEFT → Hand moving left", - " GS_RIGHT → Hand moving right", - " GS_UP → Hand moving up", - " GS_DOWN → Hand moving down", - " GS_CLOCKWISE → Clockwise wave motion", - " GS_ANTICLOCKWISE→ Counter-clockwise wave motion", - " GS_WAVE → Wave hello gesture", - ].join("\n"), - }, - ], - }), -); - -server.registerResource( - "pi-status", - "quibot://status/pi", - { description: "Check if Raspberry Pi HTTP server is reachable" }, - async () => { - try { - const res = await axios.get(`${RPI_URL}/health`, { timeout: 5000 }); - return { - contents: [ - { - uri: "quibot://status/pi", - name: "Pi Status", - mimeType: "application/json", - text: JSON.stringify({ status: "connected", data: res.data }, null, 2), - }, - ], - }; - } catch { - return { - contents: [ - { - uri: "quibot://status/pi", - name: "Pi Status", - mimeType: "application/json", - text: JSON.stringify({ status: "disconnected", error: "Cannot reach Raspberry Pi" }, null, 2), - }, - ], - }; - } - }, -); - -// === PROMPTS === - -server.registerPrompt( - "quibot-setup", - { - description: "Get a complete reference for controlling the QuiBot robot via MCP", - }, - () => ({ - messages: [ - { - role: "user", - content: { - type: "text", - text: `# QuiBot MCP Server - -You can control the physical QuiBot robot with these tools: - -## Motor Control -- motor_step(direction) — Move forward, backward, left, or right -- motor_stop() — Stop all motors -- motor_upload(filePath, format) — Upload audio file to Pi - -## Audio -- audio_upload_transcribe(audioBase64, format) — Upload + Whisper transcribe + llamacpp response -- audio_list() — List incoming audio files -- audio_lifecycle(filename, action) — lock/unlock/cancel/process audio -- tts_speak(text, lang) — Synthesize and play speech via Piper TTS - -## Eyes (WS2811 LED Matrix) -- eye_set_shape(shape) — Set face expression shape -- eye_set_color(color) — Change eye color -- eye_toggle(state) — Turn eyes on/off - -## Gesture Sensor -- gesture_on() / gesture_off() — Enable/disable gesture polling -- gesture_toggle_mode() — Toggle between block/gesture mode - -## System -- run_command(task) — Run system commands on Pi (uptime, restart_nginx) - -## Resources -- quibot://status/pi — Check if Pi is reachable -- quibot://config — Current connection config -- quibot://blocks/colors — Color-to-action mapping -- quibot://gestures — Gesture reference -`, - }, - }, - ], - }), -); - -// === START === - -async function main() { - const transport = new StdioServerTransport(); - await server.connect(transport); - console.error("[quibot-mcp] Server connected, waiting for requests via stdio..."); -} - -main().catch((err) => { - console.error("[quibot-mcp] Failed to start:", err); - process.exit(1); -}); diff --git a/mcp/tsconfig.json b/mcp/tsconfig.json deleted file mode 100644 index 2d0bdf2..0000000 --- a/mcp/tsconfig.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "compilerOptions": { - "target": "ES2022", - "module": "Node16", - "moduleResolution": "Node16", - "outDir": "./dist", - "rootDir": "./src", - "strict": true, - "esModuleInterop": true, - "skipLibCheck": true, - "forceConsistentCasingInFileNames": true, - "resolveJsonModule": true, - "declaration": true, - "sourceMap": false - }, - "include": ["src/**/*"], - "exclude": ["node_modules", "dist"] -} diff --git a/rasp/server.py b/rasp/server.py new file mode 100644 index 0000000..e6d561c --- /dev/null +++ b/rasp/server.py @@ -0,0 +1,81 @@ +from flask import Flask, request, jsonify +import sys +import os + +sys.path.insert(0, os.path.join(os.path.dirname(__file__), 'Rasp')) + +import time +import pigpio +import motion +from motion import ( + motion_setup, motion_setup_steppers, motion_setup_sensors, motion_cleanup, + enable_wheels, enable_arms, enable_syringe, + arms_home, syringe_home, + distance_to_object, + ON, OFF, CW, CCW, +) + +def _pi_connect(): + pi = pigpio.pi() + if not pi.connected: + print("ERROR: pigpiod no està en marxa. Executa: sudo pigpiod -s 1") + sys.exit(1) + return pi + +def _setup_motors(): + """Setup mínim per a tests de motors (sense sensors I2C).""" + pi = _pi_connect() + motion_setup_steppers(pi) + return pi + +def _setup_sensors(): + """Setup mínim per a tests de sensors I2C (sense steppers).""" + pi = _pi_connect() + motion_setup_sensors(pi) + return pi + +def _teardown_motors(pi): + motion_cleanup() + pi.stop() + +def _teardown_sensors(pi): + pi.stop() + +def test_arms_pair(): + pi = _setup_motors() + enable_arms(ON); time.sleep(0.1) + motion.arm_R.move(+200); motion.arm_L.move(+200) + time.sleep(1.5) + motion.arm_R.move(-200); motion.arm_L.move(-200) + time.sleep(0.5) + enable_arms(OFF) + +app = Flask(__name__) + +@app.route("/") +def home(): + return jsonify({ + "message": "Flask API is running" + }) + +@app.route("/greet", methods=["GET"]) +def greet(): + test_arms_pair() + return jsonify({ + "message": "Hello, world!" + }) + + +# Simple error handlers +@app.errorhandler(404) +def not_found(e): + return jsonify({"error": "Route not found"}), 404 + + +@app.errorhandler(500) +def server_error(e): + return jsonify({"error": "Internal server error"}), 500 + + +if __name__ == "__main__": + app.run(debug=True, host="0.0.0.0", port=8000)