Help us shape the future of Go! Take the 2026 Go Developer Survey

systemspec-pricingpackaging

module
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 22, 2026 License: MIT

README

systemspec-pricingpackaging

Go CI Go Lint Go SAST Docs Docs Visualization License

A Go-first, machine-readable description of a product's pricing and packaging: the tiers of its ladder, the plans in them with their prices, the features (a switch or an ordered level) and limits each plan sets, one-time products, a marketplace fee, and the application access each tier grants.

The Spec is the source of truth. A pricing page, a limit check, a payment provider's prices and an account's entitlements are computed from it.

  • SPEC.md: the normative description of the model.
  • pricingspec: the Go types, a loader, validation (E001 to E013) and lint (W001 to W006).
  • schema: the JSON Schema generated from the types.
spec, err := pricingspec.Load(f)
if err != nil {
	return err // a *pricingspec.ValidationError lists every error
}
for _, w := range spec.Lint() {
	fmt.Println(w) // warnings for review
}

Helpers (plan, feature and limit checks) and projections (a pricing view, an entitlement map, a diff) are planned; see the roadmap.

Releases

v0.1.0 · Changelog

Regenerating the schema

go generate ./schema/...
schemakit lint --property-case camelCase schema/pricing.schema.json

Directories

Path Synopsis
Package pricingspec is a machine-readable description of a product's pricing and packaging: the tiers of its ladder, the plans in them with their prices, the features and limits each plan sets, its one-time products, an optional marketplace fee, and the grants each tier gives an account.
Package pricingspec is a machine-readable description of a product's pricing and packaging: the tiers of its ladder, the plans in them with their prices, the features and limits each plan sets, its one-time products, an optional marketplace fee, and the grants each tier gives an account.
Package schema embeds the JSON Schema document generated from the pricingspec.Spec Go type.
Package schema embeds the JSON Schema document generated from the pricingspec.Spec Go type.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL