@owsp/schemas
v0.17.11
Published
JSON Schemas of the OpenWinSpec specification — an open, language-agnostic model for describing window constructions (Windows Order Model): construction topology, sizes, materials, glazing, hardware, ranges and price algorithms.
Maintainers
Readme
@owsp/schemas
JSON Schemas of OpenWinSpec — an open, language-agnostic specification for describing window constructions (Windows Order Model). Documents that follow the specification are unambiguous for humans and machines and convert losslessly between any systems that support the standard.
Install
npm install @owsp/schemasThe package ships generated JSON Schemas (draft-07) under src/v1/json/ and
example documents under src/v1/examples/. YAML sources live in the
openwinspec monorepo.
What's inside
| Path (under src/v1/json/) | Domain |
|---|---|
| construction/ | Construction: template (topology), sizes, materials binding, validation rules |
| material/profile/ | Profiles: base geometry, SKU with coatings, per-class params |
| material/glazing/ | Glazing: glass, IGU, spacer, sealant, desiccant |
| material/hardware/, material/opening/ | Hardware sets, handles |
| manufacturing/ | Assembly lists |
| ranges/ | Template size ranges (min/max/step) |
| calculation/ | Configurable construction price algorithms |
| core/ | Geometry primitives (points, polygons with bulge, index arrays) |
Schemas use custom x-* annotations (x-order, x-partial, x-allowedClasses,
x-uniqueBy, x-primary-key) — they are ignored by any standard draft-07
validator; full support (custom AJV keywords, projections, ordering) is provided
by @owsp/js.
Usage
const schema = require("@owsp/schemas/src/v1/json/construction/construction.json");
// validate with your favorite draft-07 validator, or use @owsp/js:import { AjvValidator, BundleType } from "@owsp/js";
const validator = new AjvValidator();
const result = validator.validate(BundleType.Construction, constructionDocument);Documentation
Guides and API reference: https://openwinspec.github.io/openwinspec/
License
Apache-2.0
