{"$comment":"Text lengths count characters as people see them, after trimming spaces at both ends.","$defs":{"chapter":{"properties":{"ideas":{"items":{"$ref":"#/$defs/idea"},"type":"array"},"title":{"$comment":"The limit counts UTF-8 bytes, so non-Latin titles fit fewer characters.","description":"The chapter's title. Without one it becomes \"Chapter N\".","maxLength":200,"type":"string"}},"required":[],"type":"object"},"idea":{"properties":{"examples":{"description":"Shown when the reader swipes sideways. May be empty.","items":{"maxLength":400,"minLength":1,"type":"string"},"maxItems":20,"type":"array"},"text":{"description":"The idea, a complete thought that makes sense on its own. An idea with empty text is skipped.","maxLength":400,"type":"string"},"tier":{"default":"common","description":"How central the idea is. Important ideas have their own look on the card; any other value counts as common.","enum":["common","good","important"],"type":"string"}},"required":["text"],"type":"object"},"translatedChapter":{"properties":{"ideas":{"items":{"$ref":"#/$defs/translatedIdea"},"type":"array"},"title":{"minLength":1,"type":"string"}},"required":["title","ideas"],"type":"object"},"translatedIdea":{"properties":{"examples":{"description":"Shown when the reader swipes sideways. May be empty.","items":{"maxLength":400,"minLength":1,"type":"string"},"maxItems":20,"type":"array"},"text":{"description":"The idea in this language.","maxLength":400,"minLength":1,"type":"string"},"tier":{"description":"Optional; when given it must match the original idea's tier.","enum":["common","good","important"],"type":"string"}},"required":["text"],"type":"object"},"translation":{"$comment":"A translation has the same chapters, ideas and examples as the original, in the same order and number.","properties":{"authors":{"description":"The creators' names as written in this language. Joined with commas, the names may be up to 255 characters.","items":{"minLength":1,"type":"string"},"type":"array"},"description":{"description":"Two or three sentences about what a reader will learn.","maxLength":600,"type":"string"},"originalPeriod":{"description":"When the original appeared, for works without an exact year, such as \"5th century BCE\".","maxLength":80,"type":"string"},"summaries":{"items":{"$ref":"#/$defs/translatedChapter"},"type":"array"},"tags":{"description":"Short topics in this version's language, without # or commas. Tags that differ only in case, accents or width count as one. Leaving the field out keeps the tags already stored; an empty list clears them.","items":{"maxLength":30,"minLength":1,"pattern":"^[^#,]*$","type":"string"},"maxItems":5,"type":"array"},"title":{"description":"The title in this language.","maxLength":255,"minLength":1,"type":"string"}},"required":["title","authors","summaries"],"type":"object"}},"$id":"/scroll.schema.json","$schema":"https://json-schema.org/draft/2020-12/schema","description":"A Scroll: its details, its chapters of ideas and optional translations. Unknown fields are ignored.","properties":{"authors":{"description":"The source's creators, in order: authors, hosts or speakers. Joined with commas, the names may be up to 255 characters.","items":{"minLength":1,"type":"string"},"type":"array"},"description":{"description":"Two or three sentences about what a reader will learn.","maxLength":600,"type":"string"},"language":{"description":"Language code of the original version (BCP 47, such as en or pt-BR). It cannot change when the Scroll is replaced.","examples":["en","pt-BR"],"type":"string"},"originalPeriod":{"description":"When the original appeared, for works without an exact year, such as \"5th century BCE\".","maxLength":80,"type":"string"},"originalYear":{"description":"The year the original appeared. Negative years are BCE; there is no year 0, and the year cannot be in the future.","minimum":-3000,"not":{"const":0},"type":"integer"},"sourceUrl":{"description":"A link to the original.","format":"uri","maxLength":2000,"pattern":"^https?://","type":"string"},"summaries":{"description":"The chapters, in reading order. The Scroll needs at least one idea and may hold up to 500; one language's content may be up to 1000000 bytes.","items":{"$ref":"#/$defs/chapter"},"type":"array"},"tags":{"description":"Short topics in this version's language, without # or commas. Tags that differ only in case, accents or width count as one. Leaving the field out keeps the tags already stored; an empty list clears them.","items":{"maxLength":30,"minLength":1,"pattern":"^[^#,]*$","type":"string"},"maxItems":5,"type":"array"},"title":{"description":"The Scroll's title. Without one it is \"Untitled\".","maxLength":255,"type":"string"},"translations":{"additionalProperties":{"$ref":"#/$defs/translation"},"description":"Complete versions in other languages, keyed by language code. A key may not repeat the original language.","type":"object"}},"required":["language","summaries"],"title":"Nectar Scroll file","type":"object"}