| 1234567891011121314151617181920212223 |
- <?php
- declare(strict_types=1);
- /**
- * The handbook as one plain-text Markdown document.
- *
- * This is the address to hand to an agent: no markup, no navigation, no
- * JavaScript - documentation, source code and the OpenAPI document in one
- * response. Reachable as llms.txt through the rewrite in .htaccess.
- */
- require_once __DIR__ . "/inc/handbook.php";
- $markdown = handbookBuildMarkdown(false);
- header("Content-Type: text/plain; charset=utf-8");
- header("Content-Length: " . (string) strlen($markdown));
- header("X-Content-Type-Options: nosniff");
- // Cheap to rebuild, but a fetching agent should not re-download it per file.
- header("Cache-Control: public, max-age=300");
- echo $markdown;
|