StabisoDocs

Sales and customers

Products, list prices and standalone selling prices

A product is what an entity sells: a recurring service priced per month or year (a seat, a licence) or a one-off one priced per unit (a day of onboarding). It carries the revenue account, supply type and VAT rate type its invoice lines take, its list prices by currency, each from a day, and its standalone selling prices (SSPs, IFRS 15.77), which a person records with how they were established. Nothing here posts. The design is ADR-0036; this guide is slice 2 as built. Subscriptions and the revenue contract of each term (later slices) use the products, their prices and their SSPs. The controls are in the control matrix (section "Products", PR1 to PR5).

Everything is a REST operation first (/v1, tag "products" in the generated reference); the MCP tool list_products reads the same operations.

Products

POST  /v1/products                          {entity, code?, name, kind, unit?, revenue_account?, supply_type?, rate_type?, prices?}
GET   /v1/products                          ?entity&kind&active
GET   /v1/products/{product_id}
PATCH /v1/products/{product_id}             name, description, unit, revenue_account, supply_type, rate_type, active

The code is unique in the entity: your own article number (SEAT), or left out for the company's next product number (P-00001, P-00002, ..., counted without gaps). The revenue_account is a revenue account of the entity. Left out, a product sold as goods takes the chart's revenue from goods (role goods_revenue: KMU 3200 Handelserlöse, IFRS 4000 Revenue from goods, PCG 707000, ...) and any other product the default revenue account (KMU 3400). The entity, the code and the kind never change. A product is never deleted: active: false stops new invoice lines from naming it, and a credit note still credits a line that names it. A change is audited with the previous values; lines already written keep what they took.

List prices

POST /v1/products/{product_id}/prices   {currency?, unit_price, price_period?, valid_from?}
GET  /v1/products/{product_id}/price    ?currency&on&party&quantity

A recurring product's price is per month or year (price_period); a one-off product's is per unit (no period). A price is never changed: a new price is recorded from a later day (valid_from, default today), and the price in force on a day is the latest from on or before it. GET .../price answers the list price and the SSP in force on a day in a currency (null when there is none): what an invoice line of the product proposes. With party and quantity it also answers the customer's price from its price list in the currency, which a line proposes before the list price.

Standalone selling prices

POST /v1/products/{product_id}/ssps   {currency?, ssp, price_period?, ssp_basis, valid_from?}

The SSP is the price the product sells for on its own; a revenue contract allocates its price to its obligations in proportion to their SSPs (IFRS 15.74-80). ssp_basis says how it was established: an observable price, an adjusted market assessment, expected cost plus a margin or the residual approach, and the evidence. Since it decides how much revenue each obligation gets, a person records it: the policy action set_ssp, which agents are always denied (403). An agent may propose one in a note or a task. An SSP is never changed, and a new one applies only from a day after the latest one in its currency (409 otherwise): an earlier day would change the SSP in force on days already past, which contracts may have been allocated with (IFRS 15.88). A product's first SSP may be dated in the past.

Changing a product's revenue account, supply type or rate type is drafting (scope draft, agents included), audited with the previous values: it affects only lines written afterwards, since a posted line, a recurring invoice's approved lines and a revenue contract's obligations keep the values they took.

Products on invoice lines

A sales invoice or credit note line may name a product (product, its code or id). The line takes the product's revenue account, supply_type and rate_type unless it names its own, and stores the product's id (product_id on the line). A line that gives no description takes the product's name, and one that gives no price takes the customer's price from its price list, else the list price in force on the document's day (422 product_unpriced when there is none); the document's provenance.filled says what was taken (What the system fills in). A posted line keeps what it used whatever the product's later prices. A purchase document names no product (422), and a credit note without lines carries the products of the lines it credits. An inactive product is refused only on a line that names it newly: a draft that already has it can still be changed, and a credit note credits it.

A recurring invoice's lines may name a product too. When the template is created or its lines change, the product is resolved into the line: its id, and the revenue account, supply type and rate type it gives (unless the line names its own). These are part of the terms a second person approves, so a later change to the product (its account, its VAT, its deactivation) does not change what an approved template invoices; changing the template's lines takes the product's current values and needs a new approval.

Data export

The tables product, product_price and product_ssp and the column trade_document_line.product_id are in the data export, with the documented schema.

Stabiso, the Enterprise System of Record · generated from the code and its guides · release d6b82bcf059d