Rulvar API reference / @rulvar/core / PricingTier
Interface: PricingTier
Defined in: packages/core/src/l0/spi/provider.ts:60
One long-context price tier. When the full prompt (canonical inputTokens, cache included) is strictly above aboveInputTokens, the ENTIRE request is re-priced with these multipliers, not only the tokens past the threshold (how providers state their long-context rules). inputMultiplier scales every input-side rate: input, cache read, and cache write. outputMultiplier scales the output rate. Provider pricing pages state multipliers for "input" without saying whether cache rates scale; scaling them with input is the conservative reading for budget enforcement (it never underestimates spend). With several tiers, the highest threshold below the prompt size wins, independent of array order.
Properties
| Property | Type | Defined in |
|---|---|---|
aboveInputTokens | number | packages/core/src/l0/spi/provider.ts:61 |
inputMultiplier | number | packages/core/src/l0/spi/provider.ts:62 |
outputMultiplier | number | packages/core/src/l0/spi/provider.ts:63 |