TypeSafe Jev on OpenRouter.
Yes, TypeSafe Jev is available on OpenRouter. You can call Jev directly using model identifier typesafe/jev-1.13 or rolling alias ~typesafe/jev-latest.
Jev on OpenRouter is a System One decision model, not a chat LLM. It takes an application state string and typed questions (Choice, Noul, Score), returning deterministic probabilities and structured decisions—with zero output token cost ($0.042/1M input tokens).
typesafe/jev-1.13 to POST /api/v1/chat/completions. It will reject with an HTTP 400 error. Instead, send requests to OpenRouter's native Decisions API (POST /api/alpha/decisions) or point the TypeSafe SDK to https://openrouter.ai/api (which targets /v1/systemone). If you need an OpenAI-compatible chat router that automatically dispatches prompts across OpenRouter's model catalog, use typesafe/jev-router instead.First Correct Request (30-Second cURL)
POST https://openrouter.ai/api/alpha/decisionsModel Identifiers & Quick Decision
OpenRouter exposes two slugs for direct Jev decision inference, alongside the separately managed Jev Router endpoint:
| Model Identifier | Model Type | API Interface | Context | Published Rate | Recommended For |
|---|---|---|---|---|---|
| typesafe/jev-1.13 | System One Decision Model | POST /api/alpha/decisions or /api/v1/systemone | 32,000 tok | $0.042 / 1M in · $0.00 out | Production systems. Locks inference to version 1.13.0 for deterministic decision boundaries and stable rubrics. |
| ~typesafe/jev-latest | Dynamic Rolling Alias | POST /api/alpha/decisions or /api/v1/systemone | 32,000 tok | $0.042 / 1M in · $0.00 out | Automatic upgrades. Tracks the latest stable Jev model release on OpenRouter without code changes. |
| typesafe/jev-router | Managed Chat Router | POST /api/v1/chat/completions | 1,000,000 tok | $0.00 prompt · $0.00 compl. | Chat completion routing. Uses Jev internally to dynamically route conversational prompts to downstream LLMs. See Jev Router reference → |
Direct Jev vs. Jev Router: Stop the 400 Error
The single most common cause of failed OpenRouter integrations with Jev is confusing direct Jev (typesafe/jev-1.13) with Jev Router (typesafe/jev-router).
| Dimension | Direct Jev (typesafe/jev-1.13) | Jev Router (typesafe/jev-router) |
|---|---|---|
| Page Owner | This page (/integrations/openrouter/) | /jev-router/ reference page |
| API Protocol | POST /api/alpha/decisions or /api/v1/systemone | POST /api/v1/chat/completions |
| Input Payload | state (string) + keyed questions (Choice, Noul, Score rubrics) | Standard OpenAI messages array (system, user, assistant turns) |
| What It Returns | Mathematical probabilities, chosen options, confidence floats. No generated text. | Standard generated natural language text or token stream from the chosen downstream LLM. |
| Context Window | 32,000 tokens | 1,000,000 tokens |
| Pricing | $0.042 / 1M input tokens · $0.00 output tokens | Listed at $0.00 / 1M prompt and completion on OpenRouter (catalog rate) |
| Primary Use Cases | Support ticket routing, moderation guardrails, agent tool validation, intent classification, lead scoring. | Single OpenAI-compatible chat endpoint that automatically switches between cheap and reasoning LLMs. |
OpenRouter Endpoints: Decisions API & System One
OpenRouter exposes two supported calling paths for executing structured decisions with Jev:
POST https://openrouter.ai/api/alpha/decisions) · OpenRouter NativeOpenRouter's native REST endpoint for System One models, featured prominently in OpenRouter's official documentation and the OpenRouter SDK (openrouter.alpha.decisions.create()). Accepts a model, application state, and keyed questions map (Choice, Noul, Score) with full criteria rubrics. Returns structured probability outputs with OpenRouter-native token accounting.
POST https://openrouter.ai/api/v1/systemone) · TypeSafe SDK ParityOpenRouter also supports direct TypeSafe SDK clients (@typesafe-ai/sdk and typesafe_sdk). When you configure the TypeSafe client with baseURL: "https://openrouter.ai/api", the SDK automatically appends /v1/systemone, allowing existing TypeSafe application code to run against OpenRouter without modifying request schemas.
/api/alpha/decisions or the TypeSafe SDK path.Quickstart & Implementation Examples
Select your preferred runtime or client to view copy-pasteable, verified integration code:
cURL (OpenRouter Decisions API)
POST https://openrouter.ai/api/alpha/decisionsEvaluates three distinct primitives (Choice, Noul, Score) against a single shared state in one HTTP request:
OpenRouter TypeScript SDK
npm install @openrouter/sdkUse the official OpenRouter SDK's decisions namespace (openrouter.alpha.decisions.create):
TypeSafe TypeScript SDK with OpenRouter
npm install @typesafe-ai/sdkPoint the official TypeSafe client to OpenRouter by overriding baseURL and passing your OpenRouter API key:
TypeScript / Node.js (Zero Dependencies)
Native fetch to OpenRouter Decisions APILightweight HTTP call suitable for serverless functions, edge middleware, and webhook receivers:
cURL (TypeSafe System One Route)
POST https://openrouter.ai/api/v1/systemoneDirect HTTP call to OpenRouter's TypeSafe SDK parity endpoint:
Response Payload Anatomy
JSON response from POST /api/alpha/decisionsOpenRouter returns calibrated probabilities and selected options inside an answers object. In the usage object, OpenRouter reports input_tokens, recorded output_tokens (representing serialized structured decision payload accounting), and computed cost. Crucially, while output tokens are accounted for in the response metadata, OpenRouter rates Jev output tokens at $0.00 / 1M—the billed cost reflects only input tokens ($0.042/1M tokens).
Primitive response shapes: Choice returns choice, confidence, and probabilities. Score returns score, confidence, probabilities, and legend. Unlike Choice and Score, Noul has no separate confidence field—the noul value itself is the direct calibrated yes-probability between 0.0 and 1.0.
Context Window Limit (32k Tokens)
This creates a practical difference between calling Jev through OpenRouter versus TypeSafe's direct API:
A strict cap of 32,000 tokens for the entire request payload. The combined token count of your shared state plus all question definitions and instructions must not exceed 32,000 tokens. Requests exceeding 32,000 tokens return an HTTP 400 Bad Request error.
Allows a total combined request budget of 64,000 tokens across all questions, provided the shared state plus the single longest question does not exceed 32,000 tokens.
Architectural guidance: If your workflow evaluates dozens of questions against large context documents (>30k tokens), either batch your questions into smaller chunks of 5–10 per call or use the direct TypeSafe API endpoint (see Jev API Key & Access Guide).
Pricing & Token Accounting
OpenRouter bills Jev at exact parity with TypeSafe official token rates:
output_tokens count for serialization accounting, output tokens are zero-rated ($0.00/1M). The reported cost reflects only input tokens.Because Jev is priced strictly on input tokens ($0.042 per 1,000,000 tokens) with free output tokens, cost depends on total token volume rather than raw request count. For example, evaluating 100 million total input tokens—equivalent to 200,000 requests averaging 500 tokens each, or 100,000 requests averaging 1,000 tokens—costs exactly $4.20. Evaluating 1 billion input tokens costs $42.00. For comprehensive pricing and comparisons with generative LLM classification costs, visit our Jev Pricing & Cost Calculator.
Authentication & Headers
Requests to OpenRouter require your standard OpenRouter API key. Configure the following HTTP headers:
Authorization: Bearer $OPENROUTER_API_KEY (Required)Pass your standard OpenRouter secret key. No separate TypeSafe subscription is required.
Content-Type: application/json (Required)HTTP-Referer: https://your-domain.com (Optional)Enables your application to be recognized on OpenRouter's public leaderboard and app analytics.
X-Title: Your Application Name (Optional)Displays a friendly name for your application in OpenRouter activity logs.
Troubleshooting & Frequently Asked Questions
You are calling https://openrouter.ai/api/v1/chat/completions or using a standard OpenAI client library with typesafe/jev-1.13. Direct Jev is a System One decision model, not an autoregressive chat model. Send your payload to POST /api/alpha/decisions (or POST /api/v1/systemone) instead. If you actually wanted OpenAI-compatible chat completions routed by Jev across OpenRouter's model catalog, use model identifier typesafe/jev-router (see Jev Router reference).
Use typesafe/jev-1.13 for production systems with strict confidence thresholding, compliance audits, or fine-tuned criteria. Use ~typesafe/jev-latest for development environments or workflows that want to immediately benefit from new Jev model checkpoints without redeploying configuration.
No. The OpenAI SDK is hardcoded to talk to /v1/chat/completions or /v1/completions with message arrays. Direct Jev requires state and questions schemas. Use @openrouter/sdk, native fetch, or the official TypeSafe SDK (@typesafe-ai/sdk or typesafe_sdk) with baseURL: "https://openrouter.ai/api".
No. Jev is a System One model that outputs calibrated probability numbers and discrete choices directly in a single forward pass. It does not generate chain-of-thought tokens or reasoning markdown.
No. You only need an OpenRouter account and API key. Usage is deducted from your OpenRouter credits at the standard $0.042/1M token rate. If you need direct enterprise SLAs, Zero Data Retention agreements, or 64k token budgets, consult the Jev Access Guide.