{
  "openapi": "3.1.1",
  "info": {
    "title": "Pinquest API",
    "version": "1.0.0",
    "summary": "Deterministic tools for people and AI agents.",
    "description": "Every endpoint performs the same calculation as the human page and returns inputs, result, units, assumptions, sources, warnings and computedAt. MCP endpoint: /mcp."
  },
  "servers": [
    {
      "url": "https://pinquest.usefulweb.site"
    }
  ],
  "paths": {
    "/api/v1/tools": {
      "get": {
        "operationId": "listTools",
        "summary": "Catalog of all tools",
        "responses": {
          "200": {
            "description": "Tool list.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/tools/{id}": {
      "get": {
        "operationId": "getTool",
        "summary": "Definition of one tool",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "pinquest-table-check",
                "pinquest-score-sim",
                "pinquest-shot-map"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Tool definition.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "404": {
            "description": "Invalid input (see errors[]).",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/tools/pinquest-table-check/calculate": {
      "post": {
        "operationId": "calculatePinquestTableCheck",
        "summary": "Validate a Pinquest pinball table and prove every mission goal can be reached by a bot.",
        "description": "Checks a Pinquest table — a built-in one or your own table JSON — for errors (unknown elements, broken references, missing flippers or plunger, invalid rules), then lets the autoplay bot play every mission stage with the real physics to prove each goal can be reached, and reports stuck balls, free-play scores and switches the ball never touched.\n\nMethodology:\n- Validation follows the Pinquest table format: ids, element types and their geometry in table units (x 0–20, y 0–40), exactly one plunger, at least one left and one right flipper, known lights, drop banks, missions, variables and achievements in every rule, and well-formed conditions and actions.\n- Physics: fixed steps of 1/240 s with sub-steps so no ball or flipper tip moves more than 0.35 ball radii per sub-step; walls, posts, bumpers, slingshots and targets use swept-circle time of impact, so the ball cannot tunnel through them; flippers transfer their surface speed to the ball.\n- For every mission stage the bot starts that mission at that stage as soon as a ball is in play and plays up to the given number of balls (games of 5 balls). A stage is reachable when the bot completes it once. The bot flips when a ball is about to reach a flipper, varies its timing to aim, cradles some balls and pulls the plunger with random strength — it is a fair but imperfect player, so \"not reached\" means \"hard\", not \"impossible\".\n- Free play: three whole games with the bot; ball searches count balls that stopped moving for 5 s (a sign of a ball trap); switches never touched are listed so you can spot shots no flipper can make.\n\nA game-design aid for Pinquest tables, not a model of a real pinball machine.",
        "tags": [
          "apps"
        ],
        "x-mcp-tool": "pinquest_table_check",
        "x-owner-app": "pinquest",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PinquestTableCheckInput"
              },
              "examples": {
                "example1": {
                  "summary": "Witch of the King's Castle (reference table)",
                  "value": {
                    "table": "witch-castle",
                    "tableJson": "",
                    "balls": 6,
                    "seed": 1
                  }
                },
                "example2": {
                  "summary": "Zombie Night with a strict proof",
                  "value": {
                    "table": "zombie-night",
                    "tableJson": "",
                    "balls": 8,
                    "seed": 2
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Calculation result envelope.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PinquestTableCheckResult"
                }
              }
            }
          },
          "400": {
            "description": "Malformed JSON body.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "422": {
            "description": "Invalid input (see errors[]).",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit exceeded (see Retry-After).",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/tools/pinquest-score-sim/calculate": {
      "post": {
        "operationId": "calculatePinquestScoreSim",
        "summary": "Play whole Pinquest pinball games with a bot: score spread, missions finished and a ball heat map.",
        "description": "Plays up to 20 complete games of a Pinquest table — built-in or your own JSON — with the autoplay bot and the real physics and rules, then reports the score spread, game length, which missions and wizard modes were finished, the busiest switches and a heat map of where the ball spends its time. Useful to balance a table’s scoring.\n\nMethodology:\n- Each game starts with the table’s rules (balls, ball save, missions, wizard) and is played by the autoplay bot with the same deterministic physics as the game: fixed 1/240 s steps, swept-circle collisions, flipper surface speed transferred to the ball.\n- Scores include switch scores, mission rewards, jackpots and the end-of-ball bonus × bonus multiplier, exactly as the game counts them. A game stops after 15 simulated minutes.\n- The heat map samples the ball position on the main playfield every 1/15 s in a 10 × 20 grid; 100 = the busiest cell.\n- The same table, seed and settings always give the same result; change the seed for another set of games.\n\nBot scores show how a table plays and pays relative to other tables — they are not a prediction of human scores.",
        "tags": [
          "apps"
        ],
        "x-mcp-tool": "pinquest_score_sim",
        "x-owner-app": "pinquest",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PinquestScoreSimInput"
              },
              "examples": {
                "example1": {
                  "summary": "Five games on Zombie Night",
                  "value": {
                    "table": "zombie-night",
                    "tableJson": "",
                    "games": 5,
                    "balls": 3,
                    "seed": 1
                  }
                },
                "example2": {
                  "summary": "Three one-ball games on the Witch's castle",
                  "value": {
                    "table": "witch-castle",
                    "tableJson": "",
                    "games": 3,
                    "balls": 1,
                    "seed": 4
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Calculation result envelope.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PinquestScoreSimResult"
                }
              }
            }
          },
          "400": {
            "description": "Malformed JSON body.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "422": {
            "description": "Invalid input (see errors[]).",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit exceeded (see Retry-After).",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/tools/pinquest-shot-map/calculate": {
      "post": {
        "operationId": "calculatePinquestShotMap",
        "summary": "Where does a pinball flipper shot go? Paths and first switches for spots along a Pinquest flipper.",
        "description": "Places a resting ball at evenly spaced spots along a flipper of a Pinquest table (built-in or your own JSON), fires the flipper with the game physics and shows where each shot goes: launch speed and angle, the path over 2.5 seconds and the first switches it hits. Table designers use it to check that ramps, orbits and targets are makeable.\n\nMethodology:\n- Spot 0 is the flipper pivot, 1 its tip; the ball starts at rest on the resting flipper at spots from 0.15 to 0.95. The flipper fires for 0.25 s and is then released.\n- Launch speed and angle are measured 1/8 s after the flip (angle: 0° = right, 270° = straight up the table). The path is sampled every 1/20 s for 2.5 s or until a saucer catches the ball.\n- Same physics as the game: fixed 1/240 s steps, swept-circle collisions, the flipper’s surface speed transferred to the ball.\n\nA design aid for Pinquest tables; real flippers and balls behave differently.",
        "tags": [
          "apps"
        ],
        "x-mcp-tool": "pinquest_shot_map",
        "x-owner-app": "pinquest",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PinquestShotMapInput"
              },
              "examples": {
                "example1": {
                  "summary": "Left flipper of the castle table",
                  "value": {
                    "table": "witch-castle",
                    "tableJson": "",
                    "flipper": "",
                    "spots": 8
                  }
                },
                "example2": {
                  "summary": "Right flipper on Zombie Night",
                  "value": {
                    "table": "zombie-night",
                    "tableJson": "",
                    "flipper": "flipper-right",
                    "spots": 6
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Calculation result envelope.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PinquestShotMapResult"
                }
              }
            }
          },
          "400": {
            "description": "Malformed JSON body.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "422": {
            "description": "Invalid input (see errors[]).",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit exceeded (see Retry-After).",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/workflows": {
      "get": {
        "operationId": "listWorkflows",
        "summary": "Multi-tool workflows",
        "responses": {
          "200": {
            "description": "Workflow list.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Problem": {
        "type": "object",
        "description": "RFC 9457 problem details. 422 responses include per-field `errors`.",
        "required": [
          "type",
          "title",
          "status",
          "detail"
        ],
        "properties": {
          "type": {
            "type": "string"
          },
          "title": {
            "type": "string"
          },
          "status": {
            "type": "integer"
          },
          "detail": {
            "type": "string"
          },
          "code": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "field",
                "message"
              ],
              "properties": {
                "field": {
                  "type": "string"
                },
                "message": {
                  "type": "string"
                }
              }
            }
          }
        }
      },
      "PinquestTableCheckInput": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "table": {
            "title": "Table",
            "type": "string",
            "enum": [
              "witch-castle",
              "zombie-night",
              "pirate-treasure",
              "space-station",
              "dragon-lair",
              "haunted-circus",
              "deep-sea",
              "jungle-temple",
              "steampunk-airship",
              "ninja-dojo",
              "wild-west-heist",
              "alien-invasion",
              "dinosaur-island",
              "candy-kingdom",
              "robot-factory",
              "viking-saga",
              "egyptian-tomb",
              "cyber-city",
              "fairy-forest",
              "volcano-forge",
              "arctic-expedition",
              "monster-carnival",
              "superhero-city",
              "detective-noir",
              "mad-science-lab",
              "samurai-storm",
              "moon-base",
              "wizard-school",
              "kaiju-attack",
              "atlantis",
              "sky-islands",
              "ghost-train"
            ],
            "default": "witch-castle"
          },
          "tableJson": {
            "title": "Your own table (Pinquest table JSON, optional — replaces the table above)",
            "description": "The format is described in the Pinquest table spec: elements (walls, flippers, bumpers, ramps …) in table units (20 × 40), lights and rules with missions.",
            "type": "string",
            "maxLength": 200000,
            "default": ""
          },
          "balls": {
            "title": "Simulated balls per mission stage",
            "description": "More balls = a stricter proof but a longer check. A stage counts as reachable as soon as the bot finishes it once.",
            "type": "integer",
            "minimum": 1,
            "maximum": 40,
            "default": 10
          },
          "seed": {
            "title": "Random seed of the bot",
            "type": "integer",
            "minimum": 1,
            "maximum": 1000000,
            "default": 1
          }
        },
        "required": []
      },
      "PinquestTableCheckResult": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "schemaVersion",
          "tool",
          "computedAt",
          "inputs",
          "summary",
          "result",
          "units",
          "assumptions",
          "sources",
          "warnings",
          "presentation",
          "links"
        ],
        "properties": {
          "schemaVersion": {
            "type": "string",
            "const": "1.0"
          },
          "tool": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "id",
              "name",
              "version"
            ],
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "version": {
                "type": "string"
              }
            }
          },
          "computedAt": {
            "type": "string",
            "format": "date-time"
          },
          "inputs": {
            "type": "object",
            "description": "Normalised inputs actually used, including applied defaults."
          },
          "summary": {
            "type": "string"
          },
          "result": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "table",
              "valid",
              "issues",
              "counts",
              "missions",
              "stages",
              "stageChecks",
              "allGoalsReached",
              "freePlay",
              "unreachedSwitches"
            ],
            "properties": {
              "table": {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "id",
                  "title",
                  "theme",
                  "style"
                ],
                "properties": {
                  "id": {
                    "type": "string"
                  },
                  "title": {
                    "type": "string"
                  },
                  "theme": {
                    "type": "string"
                  },
                  "style": {
                    "type": "string"
                  }
                }
              },
              "valid": {
                "type": "boolean"
              },
              "issues": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": [
                    "level",
                    "path",
                    "message"
                  ],
                  "properties": {
                    "level": {
                      "enum": [
                        "error",
                        "warning"
                      ]
                    },
                    "path": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  }
                }
              },
              "counts": {
                "type": "object",
                "additionalProperties": {
                  "type": "integer"
                }
              },
              "missions": {
                "type": "integer"
              },
              "stages": {
                "type": "integer"
              },
              "stageChecks": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": [
                    "mission",
                    "title",
                    "stage",
                    "text",
                    "goals",
                    "reached",
                    "seconds",
                    "ballsUsed"
                  ],
                  "properties": {
                    "mission": {
                      "type": "string"
                    },
                    "title": {
                      "type": "string"
                    },
                    "stage": {
                      "type": "integer"
                    },
                    "text": {
                      "type": "string"
                    },
                    "goals": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "additionalProperties": false,
                        "required": [
                          "on",
                          "count"
                        ],
                        "properties": {
                          "on": {
                            "type": "string"
                          },
                          "count": {
                            "type": "integer"
                          }
                        }
                      }
                    },
                    "reached": {
                      "type": "boolean"
                    },
                    "seconds": {
                      "type": [
                        "number",
                        "null"
                      ]
                    },
                    "ballsUsed": {
                      "type": "integer"
                    }
                  }
                }
              },
              "allGoalsReached": {
                "type": "boolean"
              },
              "freePlay": {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "games",
                  "meanScore",
                  "meanSeconds",
                  "ballSearches",
                  "drains",
                  "missionsStarted",
                  "missionsDone"
                ],
                "properties": {
                  "games": {
                    "type": "integer"
                  },
                  "meanScore": {
                    "type": "integer"
                  },
                  "meanSeconds": {
                    "type": "number"
                  },
                  "ballSearches": {
                    "type": "integer"
                  },
                  "drains": {
                    "type": "integer"
                  },
                  "missionsStarted": {
                    "type": "integer"
                  },
                  "missionsDone": {
                    "type": "integer"
                  }
                }
              },
              "unreachedSwitches": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            }
          },
          "units": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          },
          "assumptions": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "sources": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": false,
              "required": [
                "title"
              ],
              "properties": {
                "title": {
                  "type": "string"
                },
                "url": {
                  "type": "string"
                },
                "publisher": {
                  "type": "string"
                },
                "retrievedAt": {
                  "type": "string"
                },
                "note": {
                  "type": "string"
                }
              }
            }
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "presentation": {
            "type": "array",
            "items": {
              "type": "object"
            },
            "description": "Display blocks used by the human page (same data)."
          },
          "links": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "human",
              "api",
              "openapi",
              "methodology"
            ],
            "properties": {
              "human": {
                "type": "string",
                "format": "uri"
              },
              "api": {
                "type": "string",
                "format": "uri"
              },
              "openapi": {
                "type": "string",
                "format": "uri"
              },
              "methodology": {
                "type": "string",
                "format": "uri"
              }
            }
          }
        }
      },
      "PinquestScoreSimInput": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "table": {
            "title": "Table",
            "type": "string",
            "enum": [
              "witch-castle",
              "zombie-night",
              "pirate-treasure",
              "space-station",
              "dragon-lair",
              "haunted-circus",
              "deep-sea",
              "jungle-temple",
              "steampunk-airship",
              "ninja-dojo",
              "wild-west-heist",
              "alien-invasion",
              "dinosaur-island",
              "candy-kingdom",
              "robot-factory",
              "viking-saga",
              "egyptian-tomb",
              "cyber-city",
              "fairy-forest",
              "volcano-forge",
              "arctic-expedition",
              "monster-carnival",
              "superhero-city",
              "detective-noir",
              "mad-science-lab",
              "samurai-storm",
              "moon-base",
              "wizard-school",
              "kaiju-attack",
              "atlantis",
              "sky-islands",
              "ghost-train"
            ],
            "default": "witch-castle"
          },
          "tableJson": {
            "title": "Your own table (Pinquest table JSON, optional — replaces the table above)",
            "description": "The format is described in the Pinquest table spec: elements (walls, flippers, bumpers, ramps …) in table units (20 × 40), lights and rules with missions.",
            "type": "string",
            "maxLength": 200000,
            "default": ""
          },
          "games": {
            "title": "Games",
            "type": "integer",
            "minimum": 1,
            "maximum": 20,
            "default": 5
          },
          "balls": {
            "title": "Balls per game",
            "type": "integer",
            "minimum": 1,
            "maximum": 5,
            "default": 3
          },
          "seed": {
            "title": "Random seed of the bot",
            "type": "integer",
            "minimum": 1,
            "maximum": 1000000,
            "default": 1
          }
        },
        "required": []
      },
      "PinquestScoreSimResult": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "schemaVersion",
          "tool",
          "computedAt",
          "inputs",
          "summary",
          "result",
          "units",
          "assumptions",
          "sources",
          "warnings",
          "presentation",
          "links"
        ],
        "properties": {
          "schemaVersion": {
            "type": "string",
            "const": "1.0"
          },
          "tool": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "id",
              "name",
              "version"
            ],
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "version": {
                "type": "string"
              }
            }
          },
          "computedAt": {
            "type": "string",
            "format": "date-time"
          },
          "inputs": {
            "type": "object",
            "description": "Normalised inputs actually used, including applied defaults."
          },
          "summary": {
            "type": "string"
          },
          "result": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "table",
              "games",
              "balls",
              "scores",
              "seconds",
              "perGame",
              "missions",
              "wizardCompletedIn",
              "topSwitches",
              "heat"
            ],
            "properties": {
              "table": {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "id",
                  "title"
                ],
                "properties": {
                  "id": {
                    "type": "string"
                  },
                  "title": {
                    "type": "string"
                  }
                }
              },
              "games": {
                "type": "integer"
              },
              "balls": {
                "type": "integer"
              },
              "scores": {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "min",
                  "median",
                  "mean",
                  "max"
                ],
                "properties": {
                  "min": {
                    "type": "integer"
                  },
                  "median": {
                    "type": "integer"
                  },
                  "mean": {
                    "type": "integer"
                  },
                  "max": {
                    "type": "integer"
                  }
                }
              },
              "seconds": {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "mean",
                  "max"
                ],
                "properties": {
                  "mean": {
                    "type": "number"
                  },
                  "max": {
                    "type": "number"
                  }
                }
              },
              "perGame": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": [
                    "game",
                    "score",
                    "seconds",
                    "missionsDone",
                    "multiballs",
                    "ballSaves",
                    "drains"
                  ],
                  "properties": {
                    "game": {
                      "type": "integer"
                    },
                    "score": {
                      "type": "integer"
                    },
                    "seconds": {
                      "type": "number"
                    },
                    "missionsDone": {
                      "type": "integer"
                    },
                    "multiballs": {
                      "type": "integer"
                    },
                    "ballSaves": {
                      "type": "integer"
                    },
                    "drains": {
                      "type": "integer"
                    }
                  }
                }
              },
              "missions": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": [
                    "id",
                    "title",
                    "completedIn"
                  ],
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "title": {
                      "type": "string"
                    },
                    "completedIn": {
                      "type": "integer"
                    }
                  }
                }
              },
              "wizardCompletedIn": {
                "type": "integer"
              },
              "topSwitches": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": [
                    "event",
                    "perGame"
                  ],
                  "properties": {
                    "event": {
                      "type": "string"
                    },
                    "perGame": {
                      "type": "number"
                    }
                  }
                }
              },
              "heat": {
                "type": "array",
                "items": {
                  "type": "integer"
                },
                "description": "10 × 20 cells (rows from the top), 0–100 = share of time relative to the busiest cell."
              }
            }
          },
          "units": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          },
          "assumptions": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "sources": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": false,
              "required": [
                "title"
              ],
              "properties": {
                "title": {
                  "type": "string"
                },
                "url": {
                  "type": "string"
                },
                "publisher": {
                  "type": "string"
                },
                "retrievedAt": {
                  "type": "string"
                },
                "note": {
                  "type": "string"
                }
              }
            }
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "presentation": {
            "type": "array",
            "items": {
              "type": "object"
            },
            "description": "Display blocks used by the human page (same data)."
          },
          "links": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "human",
              "api",
              "openapi",
              "methodology"
            ],
            "properties": {
              "human": {
                "type": "string",
                "format": "uri"
              },
              "api": {
                "type": "string",
                "format": "uri"
              },
              "openapi": {
                "type": "string",
                "format": "uri"
              },
              "methodology": {
                "type": "string",
                "format": "uri"
              }
            }
          }
        }
      },
      "PinquestShotMapInput": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "table": {
            "title": "Table",
            "type": "string",
            "enum": [
              "witch-castle",
              "zombie-night",
              "pirate-treasure",
              "space-station",
              "dragon-lair",
              "haunted-circus",
              "deep-sea",
              "jungle-temple",
              "steampunk-airship",
              "ninja-dojo",
              "wild-west-heist",
              "alien-invasion",
              "dinosaur-island",
              "candy-kingdom",
              "robot-factory",
              "viking-saga",
              "egyptian-tomb",
              "cyber-city",
              "fairy-forest",
              "volcano-forge",
              "arctic-expedition",
              "monster-carnival",
              "superhero-city",
              "detective-noir",
              "mad-science-lab",
              "samurai-storm",
              "moon-base",
              "wizard-school",
              "kaiju-attack",
              "atlantis",
              "sky-islands",
              "ghost-train"
            ],
            "default": "witch-castle"
          },
          "tableJson": {
            "title": "Your own table (Pinquest table JSON, optional — replaces the table above)",
            "description": "The format is described in the Pinquest table spec: elements (walls, flippers, bumpers, ramps …) in table units (20 × 40), lights and rules with missions.",
            "type": "string",
            "maxLength": 200000,
            "default": ""
          },
          "flipper": {
            "title": "Flipper id (empty = the main left flipper)",
            "type": "string",
            "maxLength": 48,
            "default": ""
          },
          "spots": {
            "title": "Spots along the flipper",
            "type": "integer",
            "minimum": 2,
            "maximum": 12,
            "default": 8
          }
        },
        "required": []
      },
      "PinquestShotMapResult": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "schemaVersion",
          "tool",
          "computedAt",
          "inputs",
          "summary",
          "result",
          "units",
          "assumptions",
          "sources",
          "warnings",
          "presentation",
          "links"
        ],
        "properties": {
          "schemaVersion": {
            "type": "string",
            "const": "1.0"
          },
          "tool": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "id",
              "name",
              "version"
            ],
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "version": {
                "type": "string"
              }
            }
          },
          "computedAt": {
            "type": "string",
            "format": "date-time"
          },
          "inputs": {
            "type": "object",
            "description": "Normalised inputs actually used, including applied defaults."
          },
          "summary": {
            "type": "string"
          },
          "result": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "table",
              "flipper",
              "shots"
            ],
            "properties": {
              "table": {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "id",
                  "title"
                ],
                "properties": {
                  "id": {
                    "type": "string"
                  },
                  "title": {
                    "type": "string"
                  }
                }
              },
              "flipper": {
                "type": "string"
              },
              "shots": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": [
                    "spot",
                    "speed",
                    "angle",
                    "firstSwitches",
                    "path"
                  ],
                  "properties": {
                    "spot": {
                      "type": "number"
                    },
                    "speed": {
                      "type": "number"
                    },
                    "angle": {
                      "type": "number"
                    },
                    "firstSwitches": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "path": {
                      "type": "array",
                      "items": {
                        "type": "array",
                        "items": {
                          "type": "number"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "units": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          },
          "assumptions": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "sources": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": false,
              "required": [
                "title"
              ],
              "properties": {
                "title": {
                  "type": "string"
                },
                "url": {
                  "type": "string"
                },
                "publisher": {
                  "type": "string"
                },
                "retrievedAt": {
                  "type": "string"
                },
                "note": {
                  "type": "string"
                }
              }
            }
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "presentation": {
            "type": "array",
            "items": {
              "type": "object"
            },
            "description": "Display blocks used by the human page (same data)."
          },
          "links": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "human",
              "api",
              "openapi",
              "methodology"
            ],
            "properties": {
              "human": {
                "type": "string",
                "format": "uri"
              },
              "api": {
                "type": "string",
                "format": "uri"
              },
              "openapi": {
                "type": "string",
                "format": "uri"
              },
              "methodology": {
                "type": "string",
                "format": "uri"
              }
            }
          }
        }
      }
    }
  }
}