{"$schema":"https://json-schema.org/draft/2020-12/schema","title":"Trenerbenken treningsplan","description":"A training session. All text a coach reads is Norwegian bokmål; identifiers and enums are English.","type":"object","properties":{"title":{"type":"string","maxLength":120},"sport":{"enum":["football","handball"]},"venue":{"enum":["outdoor","indoor"]},"ageYears":{"type":"integer","minimum":4,"maximum":19},"ageGroup":{"type":"string","maxLength":40,"description":"how the coach names the group, e.g. G2019 or Gutter 6 år"},"durationMinutes":{"type":"integer","minimum":10,"maximum":180},"players":{"type":"integer","minimum":1,"maximum":60,"description":"expected number of players"},"focus":{"type":"array","items":{"enum":["passing","dribbling","finishing","teamplay","defending","coordination","fun"]}},"summary":{"type":"string","maxLength":2000},"equipment":{"type":"array","items":{"type":"string"}},"tips":{"type":"array","items":{"type":"string"},"maxItems":12,"description":"tips for the coach"},"drills":{"type":"array","minItems":1,"maxItems":15,"items":{"type":"object","properties":{"id":{"type":"string","pattern":"^[A-Za-z0-9][A-Za-z0-9_-]{0,31}$","description":"unique within the plan"},"title":{"type":"string","maxLength":120},"category":{"enum":["warmup","skill","game","cooldown"]},"minutes":{"type":"integer","minimum":1,"maximum":60},"description":{"type":"string","maxLength":2000,"description":"what the players do, Norwegian"},"organisation":{"type":"string","maxLength":2000,"description":"set-up: area size, cones, groups"},"coachingPoints":{"type":"array","items":{"type":"string"},"maxItems":12,"description":"what the coach looks for and says"},"players":{"type":"object","description":"Used to fit the drill to the players who turn up. teamSize for games (3 = 3 mot 3), groupSize for groups.","properties":{"min":{"type":"integer","minimum":1},"max":{"type":"integer","minimum":1},"groupSize":{"type":"integer","minimum":1},"teamSize":{"type":"integer","minimum":1}},"required":["min","max"]},"equipment":{"type":"array","items":{"type":"string"},"maxItems":12,"description":"equipment for this drill"},"easier":{"type":"string","maxLength":300},"harder":{"type":"string","maxLength":300},"diagram":{"type":"object","description":"An animated drill diagram. elements are the starting positions; each step moves elements (positions carry over to later steps) and draws arrows. An arrow end given as an element id resolves to its position at the start (from) or end (to) of the step, so a dribble is { kind: 'dribble', from: 'p1', to: 'p1' } with p1 and the ball moved.","properties":{"field":{"enum":["football","handball","hall","grid"],"description":"football (lined pitch), grid (plain grass area), handball (court), hall (gym floor)"},"width":{"type":"number","minimum":5,"maximum":120},"height":{"type":"number","minimum":5,"maximum":120},"elements":{"type":"array","maxItems":60,"items":{"type":"object","description":"Something on the field. Coordinates in metres from the top-left corner. player needs team (a=red, b=blue, coach, joker) and may have a label of up to 3 characters; goal needs size (rotation in degrees, 0 = goal line vertical); zone needs w and h.","properties":{"id":{"type":"string","pattern":"^[A-Za-z0-9][A-Za-z0-9_-]{0,31}$"},"kind":{"enum":["player","ball","cone","goal","zone"]},"x":{"type":"number"},"y":{"type":"number"},"team":{"enum":["a","b","coach","joker"]},"label":{"type":"string","maxLength":40},"color":{"enum":["orange","yellow","blue","red"]},"size":{"enum":["small","large"]},"rotation":{"type":"number"},"w":{"type":"number"},"h":{"type":"number"}},"required":["id","kind","x","y"]}},"steps":{"type":"array","maxItems":12,"items":{"type":"object","properties":{"caption":{"type":"string","maxLength":300,"description":"Norwegian, one sentence"},"moves":{"type":"object","additionalProperties":{"type":"object","description":"new position","properties":{"x":{"type":"number","minimum":0},"y":{"type":"number","minimum":0}},"required":["x","y"]}},"arrows":{"type":"array","maxItems":10,"items":{"type":"object","properties":{"kind":{"enum":["pass","run","dribble","shot"]},"from":{"oneOf":[{"type":"string","description":"element id"},{"type":"object","description":"fixed point in metres","properties":{"x":{"type":"number","minimum":0},"y":{"type":"number","minimum":0}},"required":["x","y"]}]},"to":{"oneOf":[{"type":"string","description":"element id"},{"type":"object","description":"fixed point in metres","properties":{"x":{"type":"number","minimum":0},"y":{"type":"number","minimum":0}},"required":["x","y"]}]}},"required":["kind","from","to"]}}},"required":["caption"]}}},"required":["field","width","height","elements"]}},"required":["id","title","category","minutes","description","coachingPoints","players"]}}},"required":["title","sport","venue","ageYears","durationMinutes","players","drills"]}