{"openapi":"3.1.0","info":{"title":"Nonogram Play API","version":"0.1.0","description":"A fully local, playable nonogram (picross/griddler) engine with uniquely-solvable puzzle generation, real line-solver hint logic, and a full backtracking solver. Stateless: the caller holds the puzzle state between calls.\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://nonogramplay.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"hr@unifydynamics.com","url":"https://connectorbay.com/nonogramplay/docs"},"termsOfService":"https://connectorbay.com/nonogramplay/terms"},"servers":[{"url":"https://nonogramplay.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/nonogramplay/docs"},"security":[{},{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Optional. A Pro API key raises rate limits; no credentials are required."}},"schemas":{"Error":{"type":"object","properties":{"ok":{"const":false},"error":{"type":"object"}}}}},"paths":{"/v1/tools/new_puzzle":{"post":{"operationId":"new_puzzle","summary":"Generate a new nonogram puzzle with a mathematically proven unique solution, at the requested","description":"Generate a new nonogram puzzle with a mathematically proven unique solution, at the requested\n    difficulty. Use for \"let's play a nonogram\", \"give me a picross puzzle\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"difficulty":{"default":"easy","description":"'easy' (8x8), 'medium' (10x10), or 'hard' (12x12).","title":"Difficulty","type":"string"}},"title":"new_puzzleArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/set_cell":{"post":{"operationId":"set_cell","summary":"Mark one cell filled, crossed out (known-empty), or cleared. Rejected if the mark makes its row","description":"Mark one cell filled, crossed out (known-empty), or cleared. Rejected if the mark makes its row\n    or column's clue impossible to satisfy.","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"state":{"additionalProperties":true,"description":"Current puzzle state, exactly as returned by a previous call.","title":"State","type":"object"},"row":{"description":"Row index, 0-based.","minimum":0,"title":"Row","type":"integer"},"col":{"description":"Column index, 0-based.","minimum":0,"title":"Col","type":"integer"},"value":{"description":"1 = fill, -1 = cross out as known-empty, 0 = clear back to unknown.","title":"Value","type":"integer"}},"required":["state","row","col","value"],"title":"set_cellArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_hint":{"post":{"operationId":"get_hint","summary":"Return one genuine logical deduction: a forced cell mark and WHY it's forced (real line-solving,","description":"Return one genuine logical deduction: a forced cell mark and WHY it's forced (real line-solving,\n    or -- only if that doesn't apply -- a solver-derived deeper deduction). Does not modify the state;\n    call set_cell yourself to apply it.","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"state":{"additionalProperties":true,"description":"Current puzzle state, exactly as returned by a previous call.","title":"State","type":"object"}},"required":["state"],"title":"get_hintArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/check_solution":{"post":{"operationId":"check_solution","summary":"Check whether the currently-filled cells match every row and column clue exactly.","description":"Check whether the currently-filled cells match every row and column clue exactly.","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"state":{"additionalProperties":true,"description":"Current puzzle state, exactly as returned by a previous call.","title":"State","type":"object"}},"required":["state"],"title":"check_solutionArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/solve":{"post":{"operationId":"solve","summary":"Run the full backtracking solver on the puzzle's clues and return the unique answer grid -- for","description":"Run the full backtracking solver on the puzzle's clues and return the unique answer grid -- for\n    verification, or for a player who wants to see the solution.","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"state":{"additionalProperties":true,"description":"Current puzzle state, exactly as returned by a previous call.","title":"State","type":"object"}},"required":["state"],"title":"solveArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/render_board":{"post":{"operationId":"render_board","summary":"Render the current grid as human-readable text with row/column clues.","description":"Render the current grid as human-readable text with row/column clues.","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"state":{"additionalProperties":true,"description":"Current puzzle state, exactly as returned by a previous call.","title":"State","type":"object"}},"required":["state"],"title":"render_boardArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/rules_info":{"post":{"operationId":"rules_info","summary":"Explain nonogram rules, the difficulty levels, and how hints and generation work.","description":"Explain nonogram rules, the difficulty levels, and how hints and generation work.","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{},"title":"rules_infoArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}}}}