Status: contract version 1. The schemas are generated from the library's own document definitions and checked by a test, so they always say what the code checks.
Everything QuantX stores apart from quotes and data series is a document: reference data, curve and market definitions, trades, securities, counterparties, volatility grids and their snapshots, and the provider mappings edited on the desktop. A data store keeps documents without reading them (data store contract); this page says what is inside them, for an IT team that loads, exports or audits them.
A document version
A document is identified by its kind and its identifier, and every change is saved as a new version, so its history is its audit trail. One version, as the bundled stores log it and as the schemas below describe it:
{
"kind": "CurveDefinition",
"id": "USD-SOFR",
"version": 3,
"schemaVersion": 2,
"createdAt": "2026-10-16T09:30:00.0000000+03:00",
"createdBy": "jc",
"fields": {
"Type": "OisCurve",
"Interpolation": "MonotoneConvex",
"...": "..."
}
}
fieldsmaps labels to texts. TheTypefield names the document type, so one kind can hold several types: aTradeis anOIS, anIRS, aBondand so on.- Every value is a text in an invariant format: dates
yyyy-MM-dd(ISO 8601), tenors such as5Yor-2D, numbers with a dot as decimal separator (-10000000,0.0475), lists separated by commas, a choice among the values its schema lists. A group field holds a JSON object of label to text, such as a trade's frozen convention terms. - Unknown labels are refused, so a misspelt label is caught. A required
field may be required only from a later
schemaVersionon, so older versions stay readable. schemaVersionis the version of the type's field layout the fields follow; a version newer than the library's is refused.- The library lays stored documents over the defaults it ships: the latest stored version of a kind and identifier replaces the shipped one.
The kinds
| Kind | What it holds | Schema |
|---|---|---|
ReferenceData |
rate and FX indices, FX pair conventions, trade conventions | ReferenceData |
CurveDefinition |
curve definitions and curve groups | CurveDefinition |
MarketDefinition |
which curve groups and volatility grids a market builds | MarketDefinition |
VolatilityGrid |
the expiries, tenors and strikes of a cap or swaption grid | VolatilityGrid |
VolatilitySnapshot |
one observed table of a grid, with its as-of date and source | VolatilitySnapshot |
Trade |
booked trades | Trade |
Security |
bonds and sukuk that trades refer to | Security |
Counterparty |
counterparties | Counterparty |
NettingSet |
netting sets and their collateral terms | NettingSet |
LegalEntity |
the group's legal entities | LegalEntity |
DataSeries |
definitions of data series, naming their provider and code | DataSeries |
ProviderMapping |
a provider's code for a library name, edited on the desktop | ProviderMapping |
Each schema lists its kind's types under oneOf, one branch per type, with
every field's description. A volatility snapshot has one row field per
maturity, or per expiry and tenor, of its grid, so its schema lists the fixed
fields and accepts any other label as a row. A group field's schema is
written out in full in each type that has it, so that every branch reads on
its own.
Validating a document
The schemas are JSON Schema 2020-12 and are shipped in the desktop
application's sdk\schemas\documents folder. Any validator can check an
exported version against its kind's schema. A document that passes is well
formed; the library still checks what a schema cannot, such as a curve that
names an index which exists, or a date the month does not have, when it reads
the document.
The schemas are written by the library's tests from its document definitions.
After a change to a document type, a developer regenerates them with
QUANTX_WRITE_SCHEMAS=1 dotnet test --solution QuantX.slnx; the test fails
on any schema that no longer matches the code.