Introducing The Sweep: OX’s New Live Security Research Series
Register Now
Breaking: The 2026 Vulnpocalypse Hits PHP: Four Critical RCEs, but How Dangerous Are They?
Read the Report
Are you exposed? Connect your apps in minutes.
Scan your apps free

@charivo/server

Latest version: v0.12.7

Overview

Last scanned
23 Nov 2026
Published
23 Nov 2026
npm package Publisher: zeikar
29 Stars
3 Forks
24 Versions
159 Downloads
TypeScript Repo language

Scan summary

@charivo/server was last scanned on 23 Nov 2026 at version 0.12.7. Risk score 0 of 100. No malicious behavior was detected.

  • Releases: 24 versions; the latest 5 were published within 2 days (22 and 23 Nov 2026).
  • Findings: No rules fired in version 0.12.7.
  • Downloads: 159 downloads.

Versions

24 versions published
Versions and the rules that fired in each
VersionPublishedStatus
0.12.7 LATEST 23 Nov 2026 No rules fired
0.12.6 23 Nov 2026 No rules fired
0.12.5 23 Nov 2026 No rules fired
0.12.4 23 Nov 2026 Not shown
0.12.3 22 Nov 2026 Not shown

No rules fired in 0.12.7

Findings

Findings for v0.12.7. The score is a capped sum of the weights of the rules that fired — not CVSS, not exploitability, and not a probability. It is not comparable across packages with different scan coverage.

The score describes 0.12.7; other versions have their own rules, not their own score.

README

The publisher’s own README, as collected from the registry.

@charivo/server

Server-side provider adapters for Charivo. Use these behind your own API routes so vendor credentials stay on the server.

Install

pnpm add @charivo/server

Usage

Imports are subpath-only — there is no root export.

OpenAI providers
import {
  createOpenAILLMProvider,
  createOpenAITTSProvider,
  createOpenAISTTProvider,
  createOpenAIRealtimeProvider,
} from "@charivo/server/openai";

const llm = createOpenAILLMProvider({
  apiKey: process.env.OPENAI_API_KEY!,
  model: "gpt-5.6-luna",
});
Gemini providers
import {
  createGeminiLLMProvider,
  createGeminiTTSProvider,
  createGeminiSTTProvider,
  createGeminiRealtimeProvider,
} from "@charivo/server/gemini";

const llm = createGeminiLLMProvider({
  apiKey: process.env.GEMINI_API_KEY!,
  // Optional: defaults to "gemini-3.5-flash-lite".
  model: "gemini-3.5-flash-lite",
});

const tts = createGeminiTTSProvider({
  apiKey: process.env.GEMINI_API_KEY!,
  // Optional: defaults to "gemini-3.1-flash-tts-preview" / "Kore".
  defaultModel: "gemini-3.1-flash-tts-preview",
  defaultVoice: "Kore",
  // `@charivo/tts/remote` gives up at 30s, so the server must give up first.
  // On the streaming path this same 25s also caps the streamed body itself,
  // at roughly 80s of audio (Gemini delivers ~3.5x realtime).
  timeoutMs: 25_000,
});

const stt = createGeminiSTTProvider({
  apiKey: process.env.GEMINI_API_KEY!,
  // Optional: defaults to "gemini-3.5-transcribe".
  defaultModel: "gemini-3.5-transcribe",
});

const realtime = createGeminiRealtimeProvider({
  apiKey: process.env.GEMINI_API_KEY!,
});

createGeminiLLMProvider (implemented in @charivo/llm/gemini) calls Gemini's OpenAI-compatible endpoint. Tool-call history is resent with Gemini's documented skip_thought_signature_validator placeholder because LLMToolCall carries no thought signature, so reasoning continuity across tool rounds is lost.

createGeminiTTSProvider (implemented in @charivo/tts/gemini) wraps Gemini's raw PCM response as a 16-bit WAV file; rate and pitch are ignored, since the API has no speed or pitch control. The text is sent behind a fixed synthesis preamble, and a 5xx or a text-only answer is retried once within the same timeoutMs, per Google's documented mitigations. Its 90s default timeoutMs is only for callers that own their own deadline — a route behind @charivo/tts/remote must set it below that player's fixed 30s, as above — and the text cap is the real latency control on top of that deadline (the demo caps at 400 characters via TTS_GEMINI_MAX_TEXT_CHARS). generateSpeechStream returns a TTSPcmStream of pcm-s16le audio instead of a finished buffer, delivering its first audio in roughly 1.1-1.4s regardless of text length; the same timeoutMs bounds that whole streamed body, not just the connect-and-headers phase, so a reply that outlasts it errors mid-utterance rather than merely failing to start.

createGeminiSTTProvider (implemented in @charivo/stt/gemini) posts the recording inline as base64 to models/{model}:generateContent; the default model is gemini-3.5-transcribe. It returns the audioTranscription parts' text joined in order, or "" for silence. language is optional and only a soft hint, and there is no retry. Its 30s default timeoutMs also covers reading the response body, same as Gemini TTS. Gemini's free-tier rate limit surfaces as a 429 wrapped in a CharivoProviderError for the caller to handle.

createSession mints a single-use Gemini Live ephemeral token and returns a websocket bootstrap ({ adapter, transport: "websocket", url, token }) for @charivo/realtime/remote or @charivo/realtime/gemini. The whole session config goes into the token: Google's bidiGenerateContentSetup replaces the browser's setup frame rather than validating it, and a token minted without one lets the holder open any model on your key (both measured), so model, voice, instructions, tools, maxTokens, and transcription are all fixed at mint time and cannot be changed by the browser afterwards — which is also why the transport refuses updateSession(). The API key travels in the x-goog-api-key header, never the URL. Replaying a spent token closes the socket with 1011, so a reconnect calls this again.

What it pins itself, on top of whatever your route pins:

  • model must be on its allow-list (gemini-3.1-flash-live-preview, the default and the model measured against the live API, or gemini-2.5-flash-native-audio-preview-12-2025); anything else throws
  • voice must be one of Google's prebuilt voice names; an unknown one falls back to the default Kore silently, since voice costs nothing
  • transport must be "websocket", and toolChoice may only be "auto" — "none" and "required" are rejected because the Live API has no equivalent
  • inputAudioTranscription.model is rejected for the same reason; input transcription is requested only with enabled: true (off unless asked, as on OpenAI), and output transcription is always requested, because on a native-audio model it is the only source of assistant text
OpenClaw providers
import { createOpenClawLLMProvider } from "@charivo/server/openclaw";

const llm = createOpenClawLLMProvider({
  token: process.env.OPENCLAW_TOKEN!,
  baseURL: process.env.OPENCLAW_BASE_URL!,
  // Optional: target a specific agent. Omit to use the gateway's default agent.
  agentId: process.env.OPENCLAW_AGENT_ID,
  // Optional: pin the conversation to a server-side session on the gateway.
  sessionKey: conversationId,
});

The OpenClaw gateway keeps conversation state server-side. Without sessionKey it opens a fresh session per request: the caller's message history is still sent, so the model sees prior turns, but the gateway persists nothing between requests and each turn strands a throwaway session. Pass a conversation-scoped identifier (a UUID per conversation, rotated when the user resets the chat) to keep turns on one session; past turns are then left to the gateway instead of being resent. Rotating sessionKey is the only way to reset a pinned conversation — the gateway keeps the old transcript under the old key.

On a pinned session the provider treats only the first message as the system prompt and resends it every turn; any other system message is a past turn the gateway already holds. If your route adds its own instructions, merge them into that one message rather than prepending a second one.

Because the gateway retains every turn it receives, the @charivo/llm history policies for typed input (ephemeral, replaceKey, and a silent input kept only locally) hold only on an unpinned session. See Typed Input.

generateResponseWithTools depends on which runtime the target agent runs on. OpenClaw routes openai/* models to its Codex harness by default, and that harness builds its tool list from OpenClaw's own tools without reading the ones the caller sent. The gateway still parses and validates them, so the request succeeds — it just comes back as ordinary prose with no toolCalls, which reads like the model ignoring the tools rather than never being offered them. Tool calling needs an agent whose model resolves to OpenClaw's embedded runtime, set per provider/model in the gateway config:

{ models: { "openai/gpt-5.5": { agentRuntime: { id: "openclaw" } } } }

That key is valid under agents.list[] for one agent or agents.defaults for all of them, and it keeps the gateway's existing credentials. generateResponse is unaffected. Verified against OpenClaw 2026.6.11.

Exports

  • @charivo/server/openai: createOpenAILLMProvider, createOpenAITTSProvider, createOpenAISTTProvider, createOpenAIRealtimeProvider
  • @charivo/server/openclaw: createOpenClawLLMProvider
  • @charivo/server/gemini: createGeminiLLMProvider, createGeminiTTSProvider, createGeminiSTTProvider, createGeminiRealtimeProvider

The LLM/TTS/STT providers are re-exported from @charivo/llm, @charivo/tts, and @charivo/stt (the openai/openclaw/gemini subpaths implement them). Only the realtime providers, createOpenAIRealtimeProvider and createGeminiRealtimeProvider, are implemented in this package.

Errors

Every provider in this package (createOpenAILLMProvider, createOpenAITTSProvider, createOpenAISTTProvider, createOpenAIRealtimeProvider, createGeminiLLMProvider, createGeminiTTSProvider, createGeminiSTTProvider, createGeminiRealtimeProvider, createOpenClawLLMProvider) throws CharivoError subclasses from @charivo/core instead of plain Errors:

  • SDK/API failures throw CharivoProviderError (code: "CHARIVO_PROVIDER_ERROR"). The SDK-backed providers (OpenAI LLM/TTS/STT, Gemini LLM, and OpenClaw LLM) wrap the SDK's own error: its message is preserved and the original error is kept on cause. The Gemini TTS and STT providers (raw fetch, no SDK) build HTTP-status errors from non-2xx response body text the same way the two realtime providers do (which also cover an invalid client secret or token response), so they carry the API's message but no cause; their network/ connection failures and response body/JSON parsing failures are wrapped with the original error kept on cause.
  • Request timeouts throw CharivoTimeoutError (code: "CHARIVO_TIMEOUT_ERROR"): 30s for the OpenAI providers and Gemini LLM/Realtime; Gemini STT defaults its configurable timeoutMs to the same 30s, and like Gemini TTS its timer also covers reading the body. Gemini TTS itself defaults that timeoutMs to 90s (set it below 30s behind @charivo/tts/remote), and its timer also spans its single retry — see the @charivo/tts/gemini entry in the TTS package README for how the same deadline applies to a streamed body and when a stream stops being retried. For the two realtime providers the timer covers the request up to the response headers; reading the body afterwards is not timed.
  • Constructing a provider in a browser without dangerouslyAllowBrowser: true throws CharivoStateError (code: "CHARIVO_STATE_ERROR"). The realtime providers also throw CharivoStateError for invalid session requests: an unsupported provider/transport/adapter or a missing SDP offer on OpenAI; an unsupported provider/transport/adapter, a model off the allow-list, a toolChoice of "none"/"required", or an inputAudioTranscription.model on Gemini.

CharivoError extends Error, so existing catch (e) handling still works; use isCharivoError(error) or error.code to branch on the failure kind.

OX Radar and Response Center

Find threats in your stack.

OX Radar can check high-priority threats, like critical package CVEs, against your context.

Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.

Where it’s listed

The probe returned only these fields for this server — auth requirement, protocol and tool list weren’t observed, so they’re not shown (never guessed).

  • npm @charivo/server

References

The publisher’s own links, as the registry reports them. These are not sources for the assessment on this page.

Scan your whole stack

Group 1261154050 1
Group 1261154050
 

From OX Research Newsroom

Vulnerability Insights

Compromised Claude Code extensions (versions 2.1.312 & 2.1.313) in Cursor try to install a backdoor

Critical Apache HTTP Server Flaw Exposes Web Servers to RCE (1)
CVE

CVE-2026-119618: Critical Apache HTTP Server Flaw Exposes Web Servers to Remote Code Execution

Plug and Pray: Your AI Agents Are Taking Orders From Strangers
Research

Plug and Pray: Your AI Agents Are Taking Orders From Strangers

Frame 2085668439 (1)
Group 1261154229