> ## Documentation Index
> Fetch the complete documentation index at: https://alguna.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Rate cards

> A rate card holds dated usage rates and fees that many prices share, so one publish changes the rates of every subscription that uses the card

A **rate card** is one set of rates that many prices share. Each price points at one entry on the card, and the card decides the rate. When you publish new rates on the card, every subscription that uses it bills the new rates from the date you choose. You do not edit each price.

Use a rate card when rates change often, when another system owns them, or when many plans and contracts must bill the same rates. A typical case is a token price list: one rate for each model in each region, changed every few weeks. If a rate belongs to one plan and rarely changes, use a normal [pricing model](https://alguna.com/docs/pricing/pricing-models.md) on the price. For where prices sit in the object graph, see [How Alguna works](https://alguna.com/docs/concepts/how-alguna-works.md).

Rate cards are managed in the dashboard, under **Rate cards** in the Pricing & Packaging section of the navigation.

***

## Cards

A card has a name, one currency and one or more entries.

* **One currency.** You set the currency when you create the card. It never changes. Every price that uses the card bills in that currency. A USD card cannot price a EUR plan.
* **Name.** You can rename a card at any time from the card's actions menu.
* **Archive, not delete.** You cannot delete a card. Its phases stay as the history of what each invoice billed. You can archive a card that is no longer in use: price pickers stop offering it, and the rate cards list shows it only with the Archived filter. You can unarchive it at any time.
* **One publish at a time.** If someone else publishes a phase on the card while you prepare a publish, your publish is refused, so you can check the newer phase first. See [Phases](https://alguna.com/docs/rate-cards/phases.md).

The rates themselves live in **phases**. A phase is a dated set of rates for one or more entries. A published phase never changes. To change a rate, you publish a new phase. See [Phases](https://alguna.com/docs/rate-cards/phases.md).

***

## Entries

An entry is one product that the card prices. A card has at most one usage entry and one fixed entry for each product.

| Kind | What it prices | Model | Billing |
| - | - | - | - |
| Usage rates | Events of one metric | A matrix: a rate for each combination of dimension values | In arrears, at the cadence of the price |
| Flat fee | A flat fee, recurring or one-off | One amount per billing period | In advance, at the cadence of the entry, or once for a one-off price |

### Usage entries

A usage entry declares its **dimensions**. A dimension is an event property key, such as `model` or `region`. Each phase gives the entry a [matrix](https://alguna.com/docs/api-reference/v2/subscriptions/pricing-models.md#matrix-pricing) over those dimensions. Each **cell** of the matrix is one combination of values, such as `model=orion-pro` and `region=eu`, with its own pricing model. A cell takes any model that a matrix cell takes, for example a unit rate, graduated tiers or a percentage.

When an event arrives, Alguna reads its properties and finds the cell that matches. Usage that matches no cell is never billed silently. See [Unbilled usage](https://alguna.com/docs/rate-cards/unbilled-usage.md).

### Fixed entries

A fixed entry is one flat fee per billing period, for example a platform fee of \$500.00 a month. The entry sets the billing period, and every price on the entry must bill at that cadence. The price's quantity multiplies the fee, so a seat fee works the same way.

A fixed entry bills in advance, at the fee in force at the start of the billing cycle. If the fee changes in the middle of a cycle, the whole cycle bills at the old fee. The next cycle bills at the new fee.

***

## Create a card

On **Rate cards**, select **New rate card**. Give the card a name and a currency, and add its entries. For each entry, choose the product, an entry name and a kind:

* **Usage rates** for a usage entry. It declares the dimensions it prices, such as `model` and `region`, and has no billing period.
* **Flat fee** for a fixed entry. It has a billing period, such as one month, and no dimensions.

To add an entry later, select **Add entry** on the card. A new card has no rates until you publish its first phase. See [Phases](https://alguna.com/docs/rate-cards/phases.md).

***

## Point a price at an entry

A price uses the card when its pricing model is **Rate card**. In the pricing drawer of a plan, quote or subscription line, choose **Rate card** as the model, then choose the card and the entry for the line's product. A usage entry also needs the metric the line rates. The price carries no rates of its own: the drawer shows the card's current rates, with a link to the card.

Alguna checks the price against the entry when you save it:

* The price's product must be the entry's product, and its currency must be the card's currency.
* A price on a **usage entry** is metered, billed in arrears and recurring. It has exactly one metric, and the metric sums or counts.
* A price on a **fixed entry** is fixed and billed in advance. It has no metrics. A recurring price's cadence must equal the entry's billing period.
* A price cannot start before the first phase of its entry. See [Phases](https://alguna.com/docs/rate-cards/phases.md#a-card-price-cannot-start-before-the-first-phase).
* A price's card and entry never change. To move a subscription to another card, add a new price.

### One-off and setup fees

A one-off price, such as a setup fee, can use a fixed entry of any billing period. On a one-off line, the **Rate card** model lists only the card's fixed entries. The price bills the entry's fee once, at the rate in force at the start of the billing period it is charged in. A one-off price charged on the contract start uses the rate in force at the billing start. Contract values, such as the one-off total and the total contract value, count the fee at that same rate. The pricing drawer, the quote and hosted checkout show it as a one-time charge.

### Credits on card prices

Credits can pay for card usage cell by cell. A card entry sets the order in which unit credits draw its cells, and a credit allocation can name the cells it pays for. Both unit and monetary allocations can name cells. See [Credit consumption](https://alguna.com/docs/credits/credit-consumption.md#rate-card-and-matrix-prices).

***

## Example: one month on Token Standard

Phase 1 of Token Standard sets these rates. The rates are per token.

| Model | Region | Rate per token |
| - | - | - |
| `orion-pro` | `us` | \$0.000003 |
| `orion-pro` | `eu` | \$0.0000033 |
| `orion-mini` | `us` | \$0.0000005 |
| `orion-mini` | `eu` | \$0.00000055 |

The platform fee is \$500.00 a month. A customer uses 10,000,000 `orion-pro` tokens in `us` and 4,000,000 `orion-mini` tokens in `eu` in November.

| Line | Calculation | Amount |
| - | - | - |
| Tokens, `orion-pro` / `us` | 10,000,000 × \$0.000003 | \$30.00 |
| Tokens, `orion-mini` / `eu` | 4,000,000 × \$0.00000055 | \$2.20 |
| Platform fee | 1 × \$500.00 | \$500.00 |
| **Total** | | **\$532.20** |

Rates keep full precision. Each invoice line rounds once, to the currency's minor unit.

***

## Where the rates come from

You can write each phase by hand in the dashboard. A card can also take its rates from one **source**:

* A price list that Alguna fetches from a URL, that your system pushes, or that you upload. See [Sources](https://alguna.com/docs/rate-cards/sources.md).
* Another rate card, plus a markup. See [Followers](https://alguna.com/docs/rate-cards/followers.md).

On a card that a source prices, you can **pin** a cell to keep your own rate while the source changes the rest. See [Pins](https://alguna.com/docs/rate-cards/pins.md).

***

## Limits

* A fee change inside a billing cycle is not prorated. The whole cycle bills at the fee in force at its start.
* Fixed entries bill in advance.
* An issued invoice keeps the rates it was issued with. A later phase shows a note on the invoice. See [Phases](https://alguna.com/docs/rate-cards/phases.md#issued-invoices-keep-their-rates).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.