HTTP API

Routes currently exposed by the webapp:

  • GET / Serves the main tabbed web UI shell.

  • GET /static/app.css Serves UI stylesheet.

  • GET /static/app.js Serves UI client script.

  • GET /favicon.ico Returns 204.

  • GET /api/health Liveness check.

  • GET /api/generation/package-options Returns generation package options grouped by name class (cached per DB; refreshed on import).

  • GET /api/generation/package-syllables?class_key=...&package_id=... Returns available syllable options for a class+package.

  • GET /api/generation/selection-stats?class_key=...&package_id=...&syllable_key=... Returns max_items and max_unique_combinations.

  • POST /api/generate Generates names from imported SQLite tables. Optional render_style values: raw, lower, upper, title, sentence. When render_style is not raw, responses include raw_names alongside the rendered names.

  • GET /api/database/packages Lists imported packages.

  • GET /api/database/package-tables?package_id=... Lists imported txt-backed tables for a package.

  • GET /api/database/table-rows?table_id=...&offset=...&limit=... Returns paginated table rows.

  • POST /api/import Imports a metadata JSON + ZIP package pair.

API-only mode:

  • Start with python -m pipeworks_name_generation.webapp.api --config server.ini or python -m pipeworks_name_generation.webapp.server --config server.ini --api-only.

  • UI/static routes (/, /static/*, /favicon.ico) are disabled in API-only mode.

Error shape:

  • API validation/runtime failures return JSON with an error key.

  • Unknown routes return standard HTTP 404.