Scan your whole stack
From OX Research Newsroom
Are you using @charivo/server?
Find out what’s in your code.
Scan your apps free in minutes (opens in a new tab)Latest version: v0.12.7
@charivo/server was last scanned on 23 Nov 2026 at version 0.12.7. Risk score 0 of 100. No malicious behavior was detected.
| Version | Published | Status |
|---|---|---|
| 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 |
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.
The publisher’s own README, as collected from the registry.
Server-side provider adapters for Charivo. Use these behind your own API routes so vendor credentials stay on the server.
pnpm add @charivo/server
Imports are subpath-only — there is no root export.
import {
createOpenAILLMProvider,
createOpenAITTSProvider,
createOpenAISTTProvider,
createOpenAIRealtimeProvider,
} from "@charivo/server/openai";
const llm = createOpenAILLMProvider({
apiKey: process.env.OPENAI_API_KEY!,
model: "gpt-5.6-luna",
});
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 throwsvoice must be one of Google's prebuilt voice names; an unknown one falls
back to the default Kore silently, since voice costs nothingtransport must be "websocket", and toolChoice may only be "auto" —
"none" and "required" are rejected because the Live API has no equivalentinputAudioTranscription.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 textimport { 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.
@charivo/server/openai: createOpenAILLMProvider, createOpenAITTSProvider, createOpenAISTTProvider, createOpenAIRealtimeProvider@charivo/server/openclaw: createOpenClawLLMProvider@charivo/server/gemini: createGeminiLLMProvider, createGeminiTTSProvider, createGeminiSTTProvider, createGeminiRealtimeProviderThe 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.
Every provider in this package (createOpenAILLMProvider, createOpenAITTSProvider,
createOpenAISTTProvider, createOpenAIRealtimeProvider,
createGeminiLLMProvider, createGeminiTTSProvider, createGeminiSTTProvider,
createGeminiRealtimeProvider, createOpenClawLLMProvider)
throws CharivoError subclasses from @charivo/core instead of plain Errors:
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.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.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.
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.
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).
The publisher’s own links, as the registry reports them. These are not sources for the assessment on this page.