Skip to main content

Documentation

Everything you need to integrate The Puzzle Section into your application. Authenticate tenants, generate and fetch puzzles, validate solutions, and monitor usage — all via a single platform API.

Quick Start

Fetch a Puzzle in Seconds

The official TypeScript SDK is the recommended integration path. Install it, initialise a client with your API key, and start fetching puzzles:

src/puzzle-service.ts
1import { PuzzleSectionClient } from '@puzzle-section/sdk';
2
3const client = new PuzzleSectionClient({
4 apiKey: process.env.PUZZLE_SECTION_API_KEY!,
5});
6
7// Fetch today's daily puzzles
8const { data: dailyPuzzles } = await client.puzzles.getDaily();
9console.log(dailyPuzzles); // Puzzle[]
10
11// Fetch daily puzzles filtered by type and difficulty
12const { data: sudokuPuzzles } = await client.puzzles.getDaily({
13 types: ['sudoku'],
14 difficulties: ['medium'],
15});
16
17// Fetch a specific puzzle by ID
18const { data: puzzle } = await client.puzzles.getById('550e8400-e29b-...');
19console.log(puzzle.type); // 'sudoku'
20console.log(puzzle.difficulty); // 'medium'
21console.log(puzzle.data); // { grid: number[][], given: boolean[][], ... }

See the TypeScript SDK reference for the full API surface.

Supported Puzzle Types

Number Puzzles

  • Sudoku
  • Kakuro
  • Crossmath

Logic Puzzles

  • Slitherlink
  • Hashi (Bridges)
  • Breadcrumb

Word Puzzles

  • Crossword
  • Word Search
  • Word Ladder
  • Word Path

Picture Puzzles

  • Nonogram
  • Colour Nonogram
  • Mosaic
  • Picture Path

Each type is identified by a slug: sudoku, kakuro, crossmath, slitherlink, hashi, breadcrumb, crossword, wordsearch, wordladder, wordpath, nonogram, colornonogram, mosaic, picturepath.

Need Help?