Skip to main content
Geni takes a fundamentally different approach to documentation generation: it never starts your Laravel application. Instead of booting the kernel, instantiating controllers, or opening database connections, Geni parses your source code directly as an Abstract Syntax Tree (AST). This means you can generate accurate, complete API documentation in any environment — local, CI, or locked-down production — with no infrastructure prerequisites beyond the source files themselves.

The Problem with Booting Applications

Traditional PHP documentation tools need to spin up a working Laravel application before they can introspect your routes or controllers. That dependency on a live runtime introduces a set of problems that grow worse the more complex your project becomes:
  • Database dependency — The application fails to boot, or throws exceptions, if database credentials are missing, the server is unreachable, or migrations haven’t run. Your CI pipeline needs a real database just to build static docs.
  • Accidental side effects — Running controller constructors and service providers can fire external API requests, queue jobs, touch the filesystem, or open Redis connections. Documentation generation shouldn’t have observable side effects.
  • Slow CI execution — Provisioning a database, seeding it, and waiting for connections adds minutes to every documentation build. Static analysis runs in seconds with no warmup.
  • Brittle environments — Pre-commit hooks, read-only containers, air-gapped servers, and local machines without a running database all fail with boot-dependent tools. Zero-boot documentation works everywhere your source code does.

How Geni Does Zero-Boot

Rather than executing your application, Geni reads and parses your PHP source files. Every piece of information needed to produce an OpenAPI 3.1.0 specification is already present in the code itself — in your migration files, Form Request classes, resource transformers, and controller return statements.

No Database Connections

Geni never calls DB::connection(), PDO, or any database driver. All database structure is reconstructed from your migration source files.

No Controller Instantiation

Geni never executes new $controllerClass() or invokes action methods. Every analysis is performed statically on AST nodes, so your constructors and dependencies are never resolved.

No Eloquent Hydration

Model relationships, table names, and column types are determined through static heuristics and migration schema replay — not through live queries against a database.

Deterministic Output

Running the generator multiple times always produces identical output. Keys are canonically ordered and no runtime state can cause drift between runs, making diffs in version control clean and meaningful.

What Touches the Runtime?

Geni’s zero-boot guarantee applies to the entire inference layer. There is exactly one point where Geni interacts with the Laravel runtime: reading the registered route collection.
This call reads the already-registered route collection to discover route URIs, HTTP methods, names, and middleware. It does not boot any additional providers, run database queries, or invoke controller logic. Everything that follows — reading source files, extracting validation rules, analyzing return statements, replaying migrations, and assembling the final OpenAPI document — is 100% static AST parsing with no runtime involvement.
Because inference is fully static, you can run geni:export in any environment where your source files are present, even if no .env file exists or the database server is offline.