{"openapi":"3.1.0","info":{"title":"LlmFiles","version":"1.66.0"},"paths":{"/admin":{"get":{"summary":"Admin Page","operationId":"admin_page_admin_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/admin/login":{"post":{"summary":"Admin Login","operationId":"admin_login_admin_login_post","requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"$ref":"#/components/schemas/Body_admin_login_admin_login_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/logout":{"get":{"summary":"Admin Logout","operationId":"admin_logout_admin_logout_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/admin/stats":{"get":{"summary":"Admin Stats","operationId":"admin_stats_api_admin_stats_get","parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","default":14,"title":"Days"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/admin/leads.csv":{"get":{"summary":"Admin Leads Csv","operationId":"admin_leads_csv_api_admin_leads_csv_get","parameters":[{"name":"tests","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Tests"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/pay":{"get":{"summary":"Pay Page","description":"Страница донатов. `plan`/`order` принимаем и игнорируем — старые ссылки не должны 404.","operationId":"pay_page_pay_get","parameters":[{"name":"plan","in":"query","required":false,"schema":{"type":"string","default":"","title":"Plan"}},{"name":"order","in":"query","required":false,"schema":{"type":"string","default":"","title":"Order"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/formats":{"get":{"summary":"Get Formats","operationId":"get_formats_api_formats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/license":{"get":{"summary":"License Status","operationId":"license_status_api_license_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/license/activate":{"post":{"summary":"Activate License","operationId":"activate_license_api_license_activate_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/license/deactivate":{"post":{"summary":"Deactivate License","operationId":"deactivate_license_api_license_deactivate_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/order":{"post":{"summary":"Create Order","operationId":"create_order_api_order_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/order/{oid}":{"get":{"summary":"Order Status","operationId":"order_status_api_order__oid__get","parameters":[{"name":"oid","in":"path","required":true,"schema":{"type":"string","title":"Oid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/pay/webhook":{"post":{"summary":"Pay Webhook","operationId":"pay_webhook_api_pay_webhook_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/track":{"post":{"summary":"Track","description":"Свой счётчик без сторонних скриптов и без кук: только хеш IP и факт события.","operationId":"track_api_track_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/robots.txt":{"get":{"summary":"Robots","operationId":"robots_robots_txt_get","responses":{"200":{"description":"Successful Response","content":{"text/plain":{"schema":{"type":"string"}}}}}}},"/llms.txt":{"get":{"summary":"Llms Txt","description":"llms.txt для агентов: что умеет сервис, как вызвать API и MCP, где гайды.","operationId":"llms_txt_llms_txt_get","responses":{"200":{"description":"Successful Response"}}}},"/.well-known/mcp-registry-auth":{"get":{"summary":"Mcp Registry Auth","description":"Публичный ключ Ed25519 для реестра MCP. Формат задан реестром: v, k, p.","operationId":"mcp_registry_auth__well_known_mcp_registry_auth_get","responses":{"200":{"description":"Successful Response","content":{"text/plain":{"schema":{"type":"string"}}}}}}},"/.well-known/mcp/server-card.json":{"get":{"summary":"Mcp Server Card","description":"Карточка сервера: имя, версия, транспорт, авторизация и все инструменты.","operationId":"mcp_server_card__well_known_mcp_server_card_json_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/.well-known/mcp":{"get":{"summary":"Mcp Discovery","description":"Форма Mintlify: один документ со списком серверов (у нас он один).","operationId":"mcp_discovery__well_known_mcp_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/.well-known/mcp.json":{"get":{"summary":"Mcp Discovery","description":"Форма Mintlify: один документ со списком серверов (у нас он один).","operationId":"mcp_discovery__well_known_mcp_json_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/mcp/server-card":{"get":{"summary":"Mcp Server Card Alias","description":"Короткий адрес, который просят чекеры (63 запроса от 4 IP): 301 на well-known.","operationId":"mcp_server_card_alias_mcp_server_card_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/og.png":{"get":{"summary":"Og Image","description":"Превью для соцсетей 1200×630. Файл собирает scripts/make_og.py (Pillow, локально).","operationId":"og_image_og_png_get","responses":{"200":{"description":"Successful Response"}}}},"/apple-touch-icon.png":{"get":{"summary":"Favicon","description":"Значок сайта: /favicon.ico, /favicon.svg, /favicon.png, /apple-touch-icon.png.","operationId":"favicon_apple_touch_icon_png_get","responses":{"200":{"description":"Successful Response"}}}},"/favicon.png":{"get":{"summary":"Favicon","description":"Значок сайта: /favicon.ico, /favicon.svg, /favicon.png, /apple-touch-icon.png.","operationId":"favicon_favicon_png_get","responses":{"200":{"description":"Successful Response"}}}},"/favicon.svg":{"get":{"summary":"Favicon","description":"Значок сайта: /favicon.ico, /favicon.svg, /favicon.png, /apple-touch-icon.png.","operationId":"favicon_favicon_svg_get","responses":{"200":{"description":"Successful Response"}}}},"/favicon.ico":{"get":{"summary":"Favicon","description":"Значок сайта: /favicon.ico, /favicon.svg, /favicon.png, /apple-touch-icon.png.","operationId":"favicon_favicon_ico_get","responses":{"200":{"description":"Successful Response"}}}},"/{keyfile}.txt":{"get":{"summary":"Indexnow Keyfile","description":"Ключ IndexNow: файл <key>.txt с самим ключом в корне домена.\nНужен, чтобы Bing и Яндекс принимали новые URL без аккаунта и подтверждений.","operationId":"indexnow_keyfile__keyfile__txt_get","parameters":[{"name":"keyfile","in":"path","required":true,"schema":{"type":"string","title":"Keyfile"}}],"responses":{"200":{"description":"Successful Response","content":{"text/plain":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/sitemap.xml":{"get":{"summary":"Sitemap Xml","operationId":"sitemap_xml_sitemap_xml_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api-docs":{"get":{"summary":"Api Docs","operationId":"api_docs_api_docs_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/guide":{"get":{"summary":"Guide Index","operationId":"guide_index_guide_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/guide/{slug}.md":{"get":{"summary":"Guide Markdown","description":"Markdown-вид гайда — по тому же адресу, что `<link rel=\"alternate\">` в шапке.\n\nОтдельный URL, а не только `Accept`: агенту проще дописать `.md`, чем собрать\nзаголовок, и такой ответ безопасно кэшируется по URL (Cloudflare отдаёт гайды\n`cf-cache-status: DYNAMIC`, но полагаться на это в коде нельзя).","operationId":"guide_markdown_guide__slug__md_get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/guide/{slug}":{"get":{"summary":"Guide","operationId":"guide_guide__slug__get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/convert":{"post":{"summary":"Convert File","description":"Одна загрузка → Markdown.\n\nstrip_nav (по умолчанию true) — для HTML: выкинуть меню, боковые колонки, футер\nи пермалинки «¶» и отдать только текст страницы. false — конвертировать файл\nцеликом, как он есть.","operationId":"convert_file_api_convert_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_convert_file_api_convert_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/convert/zip":{"post":{"summary":"Convert Zip","description":"Архив на входе — архив с .md на выходе. Один запрос = одна конвертация.","operationId":"convert_zip_api_convert_zip_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_convert_zip_api_convert_zip_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/convert/batch":{"post":{"summary":"Convert Batch","description":"Пакетная очередь: несколько файлов в одном запросе, отчёт по каждому.\n\nКаждый успешно сконвертированный файл списывает одну конвертацию из суточной\nквоты. Когда квота кончилась, остальные файлы возвращаются с пометкой\n`skipped`, а не роняют весь запрос: клиент видит, что успело пройти.\nЕсли не удалось конвертировать ни одного файла из-за лимита — 402, как у\nодиночной конвертации.","operationId":"convert_batch_api_convert_batch_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_convert_batch_api_convert_batch_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/download":{"post":{"summary":"Download Markdown","description":"Отдать markdown файлом. Имя — любое, включая кириллицу.\n\nДо v1.47.0 заголовок собирался как `filename=\"<имя>.md\"`, а HTTP-заголовки\nв Starlette кодируются в latin-1: `Отчёт.pdf` давало `UnicodeEncodeError`\nи **500 вместо файла** (10.11 в логе два таких запроса от сканера на\n`/api/download`). Теперь ASCII-заглушка для старых клиентов плюс\n`filename*` по RFC 5987, где имя уезжает в UTF-8 percent-encoding.\nКавычки, `\\`, `;` и переводы строк из имени выкидываются: CRLF в заголовке\n— это уже инъекция, а не имя файла.\n\nТело принимается в трёх видах, чтобы не спотыкаться на размере:\n`multipart/form-data` (как в примерах), `application/x-www-form-urlencoded`\nи `application/json` (`{\"filename\": …, \"markdown\": …}`). Страница сайта\nотдаёт .md прямо из браузера, без возврата на сервер.","operationId":"download_markdown_api_download_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/pdf-check":{"post":{"summary":"Pdf Check Endpoint","description":"Постраничный вердикт по PDF: текст есть, страница-скан, файл под паролем.\n\nКвота не тратится: файл только читается. Ответ — JSON, тот же, что у\n`llmfiles doctor --json`.","operationId":"pdf_check_endpoint_api_pdf_check_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_pdf_check_endpoint_api_pdf_check_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/mcp":{"get":{"summary":"Mcp Get","description":"SSE-поток сервер не открывает — по спецификации это 405 с `Allow: POST`.","operationId":"mcp_get_mcp_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"summary":"Mcp Endpoint","description":"MCP Streamable HTTP: одно JSON-RPC сообщение на POST, ответ — JSON.\n\nТонкая обёртка над `convert_bytes` (тот же реестр, что у сайта, CLI и архивов):\nинструменты `convert_file`, `check_pdf`, `list_formats`. Сессий нет — каждый\nзапрос самодостаточен; квота та же, что у сайта (по IP), и списывается только\nза удачную конвертацию. Нотификации клиента получают 202 без тела.\nОбе эпохи протокола обслуживаются здесь же: `initialize` для старых клиентов,\n`server/discover` для ревизии 2026-07-28 (HTTP-коды у неё строже — см.\n`mcp_server.http_status`).","operationId":"mcp_endpoint_mcp_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/":{"get":{"summary":"Index","operationId":"index__get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/pricing":{"get":{"summary":"Pricing","operationId":"pricing_pricing_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/thanks":{"get":{"summary":"Thanks","operationId":"thanks_thanks_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/pdf-check":{"get":{"summary":"Pdf Check Page","description":"Магнит под запрос-ошибку «pdf no text could be extracted».","operationId":"pdf_check_page_pdf_check_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/healthz":{"get":{"summary":"Healthz","operationId":"healthz_healthz_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}}},"components":{"schemas":{"Body_admin_login_admin_login_post":{"properties":{"token":{"type":"string","title":"Token"}},"type":"object","required":["token"],"title":"Body_admin_login_admin_login_post"},"Body_convert_batch_api_convert_batch_post":{"properties":{"files":{"items":{"type":"string","contentMediaType":"application/octet-stream"},"type":"array","title":"Files"}},"type":"object","required":["files"],"title":"Body_convert_batch_api_convert_batch_post"},"Body_convert_file_api_convert_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"},"strip_nav":{"type":"boolean","title":"Strip Nav","default":true}},"type":"object","required":["file"],"title":"Body_convert_file_api_convert_post"},"Body_convert_zip_api_convert_zip_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"}},"type":"object","required":["file"],"title":"Body_convert_zip_api_convert_zip_post"},"Body_pdf_check_endpoint_api_pdf_check_post":{"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"}},"type":"object","required":["file"],"title":"Body_pdf_check_endpoint_api_pdf_check_post"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}