OctaFuse Gateway 2.13.0: Timed Supplier Discounts, Pre-Save Route Testing, Multi-View Analytics
OctaFuse Gateway 2.13.0 introduces three major upgrades: supplier discounts now support time-bound validity and multi-rate pricing separating public promotions from user billing and actual costs; route editing gains instant pre-save testing with upstream request preview; and usage analytics splits into overview, cost/usage, and performance views with refined metrics like weighted success rate and failover request ratio.
Supplier Discount Pricing
Version 2.13.0 separates three distinct multipliers in route pricing configuration to avoid conflating upstream public promotions, user-facing billing, and actual supply costs. Previously a single multiplier forced manual recalculation when promotions started or ended.
Supplier multiplier : Represents upstream public discount; applies to both user billing and supply cost. Defaults to 1.
Billing multiplier : Adjusts the fee charged to the user for this route.
Cost multiplier : Records the actual supply-cost discount for this route.
Example for a Gemini 3.8 Flash route: supplier multiplier 0.5, billing multiplier 1, cost multiplier 0.68. With a catalog amount of $100 and no user-specific multiplier:
User fee: 100 × 0.5 × 1 = 50 USD
Supply cost: 100 × 0.5 × 0.68 = 34 USD
Standard amount remains $100 (not multiplied by supplier multiplier).
Supplier multipliers can have start/end timestamps and time-of-day windows (e.g., weekday vs. night discounts). Expired or not-yet-active multipliers fall back to 1 automatically; configuration is retained for audit. The editor previews per-window unit price, composite multiplier, and gross margin. Route list shows current window and discount status. Preview excludes user-specific multipliers, which continue to follow existing stacking or minimum-value rules.
Configured billing and cost composite multipliers are 0.5 and 0.34 ; supplier multiplier expires 2026-12-30 23:59 (Asia/Shanghai). Example only, not an official supplier promotion.
This scheme applies to text, image, and audio models, not agent tools. Model catalog and user-discount APIs return the current effective supplier multiplier and its active state so portals can update price displays; actual request routing still follows existing strategy.
Route Quick Test
When creating or editing a route, common checks are: correct upstream model name, custom headers taking effect, and request body accepted by the provider. Previously this required saving first, then using the debug console, then returning to fix issues.
Now the route editor includes a quick-test panel that sends a request using the current unsaved configuration. Choose a request sample, edit the payload, inspect the final upstream request and response, and verify the change. After further edits the UI marks the previous test result as stale to avoid confusion.
The editor now groups model mapping, request config, pricing config, and quick test in separate sections. New routes list only enabled providers; editing or cloning an existing route retains its originally bound (now disabled) providers with status labels.
Quick test and route config share one window; preview upstream request before sending. Image shows pre-send state with empty result; request URL masked for privacy.
Quick test only validates that the current configuration can call the selected upstream: it does not save drafts, consume gateway user quota, write request logs, or trigger failover, but it may incur provider call charges. It cannot replace billing verification; to check user auth, quota, full routing, and actual charging, use the simulator or a real client. Real-time WebSocket debugging still requires a saved route.
Playground and Simulator text debugging now unify request editing and response display: select samples, toggle streaming, edit JSON, and view body, reasoning, tool calls, and raw data separately. Long output scrolls in the result pane; requests can be stopped. Tool-call display shows model-returned parameters without auto-executing tools.
Usage Analysis Upgrade
When costs spike or latency degrades, operators need to pinpoint which models, providers, or users drive the change. A single wide table with all metrics is hard to scan and hides key shifts.
2.13.0 splits model, provider, and user usage into three views: Overview , Cost & Usage , and Performance & Quality . Targets can be searched; the provider usage page adds a provider-type filter. After filtering, request count, success rate, user fees, supply cost, and billing spread are recalculated; CSV export follows the current filter. Failed queries can be retried; rapid time-range switching preserves old results until new ones load.
User usage adds a "Current Budget" panel showing the account's present budget and wallet status (not the historical balance for the selected window). The gap between user fees and supply cost reflects recorded billing spread only, excluding infrastructure, tax, and other expenses.
Cost & Usage view selected, no search entered. Summary, list, and CSV export all follow the active filter.
Performance and reliability metrics are clarified:
Overall success rate : request-count weighted, not a simple average of row success rates.
Failover request ratio : counts requests that experienced at least one failover; multiple failovers on the same request are not double-counted.
Streaming generation speed : uses only successful samples with valid streaming duration; shows — when no measurable sample exists, not zero.
After a provider is deleted, historical usage retains the provider's account name from logs, marked as deleted; falls back to ID when name is unavailable. Reliability page's recent errors and log links respect the currently selected time window for consistent drill-down.
"Today", "This Week", "This Month", and dashboard trends now compute and display using the configured business time zone, reducing discrepancies from browser time zones. Quota reset times (input and display), provider quota checks and resets, and integration key last-used timestamps also use the business time zone.
Other Updates
Reuse model config : Model editor supports duplication, preserving price, modalities, tags, description, metadata, and time windows. New ID defaults to appending -copy, editable before save; routes are not copied and must be configured separately.
Provider cards : Protocol and capability badges are more compact; duplicate edit entry removed; clicking card still opens editor.
Statistics corrections : Requests without provider attribution no longer mix into provider stats; cache hit rate shows — when input tokens are absent.
New model presets : Added GPT-6.1 Sol, Claude Sonnet 5.5, Grok Build 0.1, Grok 4.20 Reasoning/Non-Reasoning, MiniMax M2.7 Highspeed, Kimi K2.7 Code Highspeed, Qwen3.8 Max Prime/2.4T-A95B/27B/Omni Flash; image models: Seedream 5.0 Flash, Qwen Image 2.1 Pro.
Catalog price corrections : Fixed USD presets for Qwen Image 3.0/Pro, Wan 2.7 Image/Pro; completed CNY presets for Doubao Seed 2.0 Mini/Lite/Pro input tiers up to 32K.
Legacy client compatibility : Added temporary Anthropic path aliases for older SoloEnt Agent versions. General clients must use the canonical POST /v1/messages endpoint; do not rely on temporary paths.
New presets must be imported from the catalog and routed; import does not overwrite existing same-ID models. To adopt corrected prices on existing models, verify provider pricing first, then update manually.
Upgrading to 2.13.0
Upgrading from 2.12.0 requires no new database migrations or mandatory config. Back up the database, then update Proxy, Admin, and migrate images together; from earlier versions, apply pending migrations in order.
Before enabling new discounts, upgrade all Proxies to 2.13.0, confirm old instances are out of traffic, then upgrade Admin and configure supplier multipliers. This avoids mixed pricing rules across versions. Unconfigured supplier multiplier defaults to 1.
Migration warning for price_override.provider_factor : Old versions used this field as a fallback cost multiplier only when metered_factor was missing. New versions treat it as an independent supplier multiplier affecting both user fees and supply cost. If the intent was solely to record a cost discount, move the value to metered_factor and remove or set provider_factor to 1. Even if metered_factor exists, check for residual provider_factor.
Systems parsing pricing audit logs must handle new pricing_audit.v = 6 with supplier multiplier data while retaining legacy version parsing; historical logs are not rewritten. Analysis API adds failover request ratio and successful streaming sample metrics; existing failover_rate and tokens_per_second semantics unchanged.
Post-upgrade validation checklist: verify pricing and audit logs for discount not-started, active, and expired states; test an unsaved route and a full client call; confirm analysis filtering, export, and "today" statistics range. With DST time zones note: D1/MySQL trend buckets use the query-end timestamp's zone offset, so intervals crossing a DST transition may show bucketing drift; PostgreSQL converts per zone rules.
Full changelog and upgrade notes: GitHub Release v2.13.0 (https://github.com/OctaFuse/octafuse-gateway/releases/tag/v2.13.0) and CHANGELOG.md (https://github.com/OctaFuse/octafuse-gateway/blob/v2.13.0/CHANGELOG.md).
Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
Programmer DD
A tinkering programmer and author of "Spring Cloud Microservices in Action"
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
