make the world well-typed.
JSONSpec describes both the schema and the semantics of a data/service, it requires as much as possible info to build a rich specification.
A valid JSONSpec have following sections:
JSONSpec
header, contains the basic infomations of this JSONSpec document: the version of spec standard,type
section, contains the type information of the dataconstraint
optional section, which provides more specific constaint for provided data field.doc
optional section, contains the documents to describe related dta field.typedefs
optional section, contains internal type definitions.see stdlib
"[<type>]"
;{ "<keys>": "<typespec>" (, "<keys>": "<typespec>") + }
<key>?
, means the key can be optional[<type>]
the key must match specifid type (typically string, with some specific constraints)