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

# Contract reference

<Note>
  This page is a field-level lookup. For task steps, see [how to work with contracts](/docs/20260301/product-modules/contracts/how-to-guides/contract). For the reasoning behind these fields, see [contract: concepts](/docs/20260301/product-modules/contracts/concepts/contract).
</Note>

## Layout

An open contract has two tabs: **Summary**, covering line items, pricing, and configuration, and **Invoices**, listing the invoices the contract has generated and offering a manual regeneration action. Fields and operations below are on the Summary tab unless stated otherwise.

## Contract fields

| Field             | Description                                                                                                                                              |
| ----------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Customer          | The customer the contract belongs to. Cannot be changed after the contract is created                                                                    |
| Business entity   | The entity the contract is billed under                                                                                                                  |
| Currency          | The contract's billing currency. Changing it after line items exist removes every line item; see the warning under [validation rules](#validation-rules) |
| Start date        | Required. When the contract begins                                                                                                                       |
| End date          | Required. Open-ended contracts are not supported yet                                                                                                     |
| Timezone          | Defaults to UTC if not set. Cannot be changed after the contract is created                                                                              |
| Custom attributes | Present in the data model, the same mechanism used on products and customers, but there is no way to set or edit them from the interface yet             |
| Status            | Draft or active. See [contract operations](#contract-operations)                                                                                         |
| Version           | A number Zenskar uses to detect conflicting concurrent edits. See [contract operations](#contract-operations)                                            |

## Line item configuration

| Feature                  | What it means                                                                                | Example                                                    | Status                                               |
| ------------------------ | -------------------------------------------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------- |
| Price versions           | Different prices for different time periods, covering the line item with no gaps or overlaps | $10/seat for Jan to Jun, $12/seat for Jul to Dec           | Available                                            |
| Billing schedule         | How often invoices are generated and whether payment is due upfront or at end of period      | Bill quarterly, payment due at end of quarter              | Available                                            |
| Discounts                | Flat dollar amount off, percentage off, a quantity reduction, or free units included         | \$100 off per month, or 1,000 free API calls per month     | Available                                            |
| Minimum commitments      | Guaranteed minimum the customer pays, or a minimum quantity, even if usage is low            | Minimum \$10,000 per quarter                               | Available                                            |
| Anchor dates             | Align billing cycles to specific dates instead of the line item's own start date             | Bill on the last day of the month                          | Available                                            |
| Quantities               | How many units the customer gets                                                             | 25 seats, or tracked by usage meter                        | Available, line item level only                      |
| Optional items           | Line items that can be turned on or off during the contract                                  | Premium support, billed only when activated                | Reserved in the data model; no interface support yet |
| Brand-new price creation | Building a price from scratch for a single line item, rather than reusing catalog pricing    | An ad hoc, one-off rate not saved to the product's catalog | Not available; shown disabled in the interface       |

## Pricing models

<Card title="Pricing models" icon="scale-balanced" href="/docs/20260301/pricing-models/index">
  See per unit, volume, and tiered pricing, and how each one applies to point in time and period of time products.
</Card>

## Contract operations

| Operation                   | Status | Description                                                                                                                                                                                                                                         |
| --------------------------- | ------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Create contract             | Done   | Create for a customer with a start and end date, then add products manually and set pricing for each                                                                                                                                                |
| View contracts              | Done   | View a single contract, or browse and filter the full list                                                                                                                                                                                          |
| Update contract             | Done   | Edit a draft contract in a single save, with concurrent-edit protection                                                                                                                                                                             |
| Change quantities           | Done   | Adjust recurring or on-demand quantities over time, line item level only                                                                                                                                                                            |
| Publish (activate) contract | Done   | Moves a draft to active status and starts generating its first invoice asynchronously, which may take a moment to appear. Runs full validation across pricing, billing schedule, quantities, discounts, and commitments, plus a tax-readiness check |
| Invoice preview             | Done   | Preview invoices for a saved contract or an unsaved draft                                                                                                                                                                                           |
| Regenerate invoices         | Done   | From the Invoices tab, manually re-run invoice generation for an active contract. Tracked by a status banner (enqueued, in progress, completed, or error, with retry); triggering it again while one is already running does not start a second one |

A contract only ever has two statuses, draft and active, and there is no path back from active to draft.

### Concurrent edits

Every contract carries a version number. When you save a change, you send back the version you started from. If someone else has already saved a change since then, your save is rejected with a conflict error, shown as a toast titled **Conflict: contract was modified elsewhere**, instead of silently overwriting theirs. Nothing is merged automatically; reload the contract to see the latest version and reapply your change.

## Contract list filters

Contracts can be filtered by: contract name, customer, status, currency, and created or updated date.

## Validation rules

| Rule                                                                                                           | Status                                                                                                  |
| -------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------- |
| End date must be after start date                                                                              | Done                                                                                                    |
| Contract must have at least one product                                                                        | Done, enforced on update and on publish; an empty draft can still be saved                              |
| Customer and business entity are valid                                                                         | Done                                                                                                    |
| Anchor dates are internally consistent (no overlaps, no mixing dated and undated entries within the same list) | Done                                                                                                    |
| Line item dates fall within contract dates                                                                     | Done                                                                                                    |
| Prices cover the full line item period with no gaps or overlaps                                                | Done                                                                                                    |
| Price currency matches the contract's currency                                                                 | Done                                                                                                    |
| Billing schedule has no gaps or overlaps, and aligns with quantity and tier cadences                           | Done                                                                                                    |
| Quantity configuration is consistent, including validity and partial-period handling                           | Done                                                                                                    |
| Discount dates and ordering are valid                                                                          | Done                                                                                                    |
| Commitment dates are valid, and align with quantity cadence for period of time products                        | Done                                                                                                    |
| All referenced products and prices exist                                                                       | Done                                                                                                    |
| Tax configuration is complete before publishing (customer country, applicable rates)                           | Done, enforced at publish                                                                               |
| Quantity entries form a complete, gap-free timeline                                                            | In progress. Entries cannot overlap and must fall within bounds, but full contiguity is not checked yet |
| Activation periods cover the full line item for optional items                                                 | Not yet available, since optional line items themselves are not available yet                           |

<Warning>
  Changing a contract's currency after it already has line items removes every existing line item. Zenskar shows a confirmation before this happens, and the change can be undone if caught before saving, but it cannot be recovered once saved.
</Warning>

## Invoice correction handling

| Correction on an approved invoice        | Available options                                                                   | Default                                                        |
| ---------------------------------------- | ----------------------------------------------------------------------------------- | -------------------------------------------------------------- |
| Positive arrear (customer under-charged) | Separate back-dated invoice for the period, or redate forward onto the next invoice | Separate back-dated invoice                                    |
| Negative amount (customer over-charged)  | Carried forward across upcoming invoices                                            | Carried forward. A standalone credit note is not available yet |

This is configured per contract through the **Invoicing config** section, using the **Billing increases after approval** toggle. Only one invoicing config rule can be active on a contract at a time, and it locks once the contract is active.

<Warning>
  The setting for delivering an overcharge correction as a standalone credit note exists but has no effect if set. There is no way to select it in the interface, and if it is set another way, Zenskar accepts it without error but still carries the correction forward as reduced future invoices. Do not rely on this setting to produce a credit note.
</Warning>

See [invoice corrections: concepts](/docs/20260301/product-modules/contracts/concepts/invoice-corrections) for how this works.

## Minimum commitment evaluation modes

| Mode                       | Behavior                                                                                                                                     |
| -------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
| Greedy (per-period)        | Each billing period must independently hit its share of the commitment; shortfalls are charged every period until the full commitment is met |
| Cumulative (running total) | The commitment tracks across the full window; a heavy period banks credit toward future ones                                                 |

## Not yet available

* Contract-level discounts and minimum commitments (currently line-item level only)
* Auto-populating a contract's line items from your organization's default pricing, from the dashboard
* Optional line items that can be turned on or off mid-contract (the underlying field exists, but nothing in the interface sets or activates it)
* Building a brand-new price from scratch for a single line item, rather than reusing catalog pricing (shown, but disabled, in the interface)
* Tags on contracts
* Editing custom attributes on a contract from the interface
* Changing the customer on an existing contract
* More than one invoicing config rule active on a contract at a time
* Contract-level settings: billing address, shipping address, invoice template, payment method
* A dedicated, readable contract amendment history beyond the contract's version number
* Lifecycle states: trial periods, eternal contracts, expiry, pause or suspend, auto-renewal
* Parent-child or third-party billing
* Delivering an overcharge correction as a standalone credit note
* Bulk contract export
