Files
nroxy/packages/domain
2026-03-10 14:03:52 +03:00
..
2026-03-10 14:03:52 +03:00
2026-03-10 14:03:52 +03:00
2026-03-10 14:03:52 +03:00
2026-03-10 14:03:52 +03:00
2026-03-10 14:03:52 +03:00

packages/domain

Business rules for nproxy.

Implemented in this iteration

  • Approximate quota bucket contract: 100/80/60/40/20/0
  • Provider key pool round-robin active-key selection
  • Provider attempt classification for retry vs terminal outcomes
  • Key-state transition policy for cooldown/manual_review/out_of_funds

Current exports

  • getApproximateQuotaBucket
  • isRetryableFailure
  • evaluateAttempt
  • selectActiveKeysRoundRobin
  • buildAttemptPlan

Notes

  • Domain logic stays provider-agnostic.
  • Transport code must live in packages/providers.