Get a rate plan version
One version of a rate plan. Secret and trusted tokens may call it; a limited token may not (403).
AuthorizationBearer <token>A secret, trusted or limited token. See Authentication.
rate_plan_id*stringThe rate plan id.
version*integerThe version.
Success.
application/json- response
The price of one metric in one currency. Each version is fixed once saved.
object?stringAlways rate_plan.
rate_plan_id?stringYour id, or rate_ plus 32 characters.
version?integer1 or more. Never changes once saved.
metric_id?stringThe metric it prices.
currency?stringThree letters. Must be the currency of the agreements that use it.
pricing_model?stringHow billable units are priced.
"flat_per_unit""package""tiered_volume""tiered_graduated"included_allowance?numberUnits included in each period before any charge.
overage_price?numberPrice per billable unit for flat_per_unit and package.
tiers?array<>Required for the tiered models.
effective_from?stringKept with the plan.
date-timeeffective_to?stringKept with the plan.
date-timebilling_region?stringBilling region. Defaults to us.
"us""uk""eu"test?booleanTest or live.
curl -X GET 'https://api.comecero.com/api/v1/usage/rate_plans/string/versions/0'{ "object": "rate_plan", "rate_plan_id": "ai_tokens_standard", "version": 1, "metric_id": "met_ai_tokens", "currency": "USD", "pricing_model": "flat_per_unit", "included_allowance": 100000, "overage_price": 0.00002, "tiers": [], "billing_region": "us", "test": false}Create a rate plan version POST
Prices a metric. A saved version never changes: to change a price, save a new `version` with the same `rate_plan_id`. Tiers and package sizes price only the units above the included allowance. Secret and trusted tokens may call it; a limited token may not (`403`). The plan is not checked against an agreement's currency here: use a plan in the agreement's currency, or its billing run fails with `currency_mismatch`.
Overview
Next Page