From 0be45c97d934c7cb743dde97b2cf7f27bdb0ecab Mon Sep 17 00:00:00 2001 From: Peppa Date: Sun, 15 Nov 2026 13:54:19 +0500 Subject: [PATCH 1/4] =?UTF-8?q?BRM-10:=20proposal=20(=D0=B1=D1=80=D0=B8?= =?UTF-8?q?=D1=84=20+=20=D1=84=D1=83=D0=BD=D0=B4=D0=B0=D0=BC=D0=B5=D0=BD?= =?UTF-8?q?=D1=82)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Sonnet 5.5 --- .../.openspec.yaml | 2 + .../brm-10-brief-and-foundation/design.md | 23 ++++++++++++ .../brm-10-brief-and-foundation/proposal.md | 37 +++++++++++++++++++ .../specs/approvals-audit/spec.md | 33 +++++++++++++++++ .../specs/brand-brief/spec.md | 16 ++++++++ .../specs/brand-knowledge-base/spec.md | 35 ++++++++++++++++++ .../brm-10-brief-and-foundation/tasks.md | 20 ++++++++++ 7 files changed, 166 insertions(+) create mode 100644 openspec/changes/brm-10-brief-and-foundation/.openspec.yaml create mode 100644 openspec/changes/brm-10-brief-and-foundation/design.md create mode 100644 openspec/changes/brm-10-brief-and-foundation/proposal.md create mode 100644 openspec/changes/brm-10-brief-and-foundation/specs/approvals-audit/spec.md create mode 100644 openspec/changes/brm-10-brief-and-foundation/specs/brand-brief/spec.md create mode 100644 openspec/changes/brm-10-brief-and-foundation/specs/brand-knowledge-base/spec.md create mode 100644 openspec/changes/brm-10-brief-and-foundation/tasks.md diff --git a/openspec/changes/brm-10-brief-and-foundation/.openspec.yaml b/openspec/changes/brm-10-brief-and-foundation/.openspec.yaml new file mode 100644 index 0000000..a01998f --- /dev/null +++ b/openspec/changes/brm-10-brief-and-foundation/.openspec.yaml @@ -0,0 +1,2 @@ +schema: spec-driven +created: 2026-11-15 diff --git a/openspec/changes/brm-10-brief-and-foundation/design.md b/openspec/changes/brm-10-brief-and-foundation/design.md new file mode 100644 index 0000000..b48f8d7 --- /dev/null +++ b/openspec/changes/brm-10-brief-and-foundation/design.md @@ -0,0 +1,23 @@ +## Решения + +- **Стек**: TypeScript, Node 22, Fastify, PostgreSQL (`pg` + SQL-миграции, без ORM), vitest. + Почему: стек из ТЗ допускает TS; минимум зависимостей; шаблон деплоя `Dockerfile.node` уже есть. + Альтернатива — Python/FastAPI; отвергнута ради единого стека с будущим веб-дашбордом. +- **Деплой**: один сервис `web`, порт из `$PORT`, `GET /healthz`, миграции `pnpm db:migrate`, + `DATABASE_URL` из окружения (секрет — через PM). +- **Достоверность**: enum `fact_status` = `public_confirmed | internal_confirmed | hypothesis | outdated | forbidden`. + Каждая запись: `created_at`, `updated_at`, `source_evidence_id` (nullable), `confidence` (0–100, nullable). + Публичный вывод (`?audience=public`) отдаёт только `public_confirmed`. +- **Таблицы**: `person_profile`, `career_history` (есть флаг `is_current`, историческую роль + нельзя выдать за текущую), `credentials` (статус подтверждения, документ), `cases` + (поля из ТЗ п.2.5 + `public_use_permitted`), `source_evidence`, `approvals`, `audit_logs`. +- **Полномочия**: таблица политики action → режим (A/B/C). Действие режима C без одобрения + `approved` отклоняется (403) и создаёт `approvals` со статусом `pending`. Остальное ТЗ (внешние публикации) — вне scope. +- **Аудит**: любая запись/изменение в одной транзакции с `audit_logs` (actor, action, entity, before/after JSON). + Секреты в журнал не пишутся. +- **Аутентификация**: единый токен владельца из `API_TOKEN` (Bearer); без него всё, кроме `/healthz`, — 401. +- **Бриф**: `docs/brief.md` пишется вручную из ТЗ; неизвестное — «не определено». + +## Риски + +- Фактов о Татьяне подтверждено мало: часть брифа останется «не определено» — это ожидаемо. diff --git a/openspec/changes/brm-10-brief-and-foundation/proposal.md b/openspec/changes/brm-10-brief-and-foundation/proposal.md new file mode 100644 index 0000000..7777ba9 --- /dev/null +++ b/openspec/changes/brm-10-brief-and-foundation/proposal.md @@ -0,0 +1,37 @@ +## Why + +Стори BRM-10 «Раскрутить и поддерживать личный бренд Татьяны Сайфаровой». Полное ТЗ «TANYA BRAND AI» +(агент-директор по бренду) — это несколько стори. PM решил (вопрос #157): в BRM-10 делаем +**бриф + фундамент**, остальное режем на отдельные стори. + +Цель среза: зафиксировать, чего Татьяна хочет от бренда и что о ней известно проверенного, и +создать основу, на которую лягут исследование, контент, каналы и CRM: хранилище проверенных +фактов, правила полномочий (режимы A/B/C из ТЗ) и журнал действий. + +## What Changes + +- **Бриф** — один документ `docs/brief.md` (цель, аудитория, 2–3 площадки, что уже есть); + неизвестное помечено «не определено», плюс список вопросов к Татьяне. Без контент-плана и обещаний по цифрам. +- **Brand Knowledge Base (ядро)**: сущности `person_profile`, `career_history`, `credentials`, + `cases`, `source_evidence` с датой создания/актуализации, источником и статусом достоверности + (подтверждённый публичный факт / внутренний / гипотеза / устаревшее / запрещено к публикации). +- **Согласования и аудит**: сущности `approvals`, `audit_logs`; политика полномочий + (режим A — автономно, B — в утверждённых пределах, C — только с одобрением Татьяны); + каждое изменение пишет запись в журнал. +- HTTP API (JSON) для этих сущностей, миграции Postgres, `/healthz`. + +## Вне scope (отдельные стори) + +Исследование рынка и ниш, конкуренты; бренд-стратегия; контент-фабрика и календарь; интеграции +с каналами (LinkedIn, Instagram, Telegram и др.) и публикация; CRM/лиды/PR-возможности; дашборд KPI; +отчётность; векторный поиск (pgvector); сайт saifarova.com; Telegram-бот; Google Drive/Calendar. + +## Impact + +Новый сервис (TypeScript + Postgres), новые таблицы. Новые спеки: `brand-brief`, +`brand-knowledge-base`, `approvals-audit`. + +## Открытые вопросы к PM + +- Нужно ли одобрение архитектуры (стек, Postgres, модель данных) — запрошено ниже. +- Написание фамилии: в ТЗ «Сайфарова», в комментариях «Сафарова». В брифе принято «Сайфарова» (по ТЗ); подтвердить. diff --git a/openspec/changes/brm-10-brief-and-foundation/specs/approvals-audit/spec.md b/openspec/changes/brm-10-brief-and-foundation/specs/approvals-audit/spec.md new file mode 100644 index 0000000..3c7f9e1 --- /dev/null +++ b/openspec/changes/brm-10-brief-and-foundation/specs/approvals-audit/spec.md @@ -0,0 +1,33 @@ +## ADDED Requirements + +### Requirement: Режимы полномочий +Система SHALL сопоставлять каждому действию режим A (автономно), B (в утверждённых пределах) или C (только с одобрением Татьяны). Действие режима C SHALL выполняться только при одобренном согласовании. + +#### Scenario: Режим C без одобрения +- **GIVEN** действие `set_public_positioning` относится к режиму C +- **WHEN** оно запрошено без одобренного согласования +- **THEN** API отвечает 403 +- **AND** создано согласование со статусом `pending` + +#### Scenario: Режим C с одобрением +- **GIVEN** согласование на `set_public_positioning` со статусом `approved` +- **WHEN** действие запрошено с этим согласованием +- **THEN** действие выполнено, API отвечает 200 + +#### Scenario: Режим A +- **GIVEN** действие `create_hypothesis` относится к режиму A +- **WHEN** оно запрошено без согласования +- **THEN** действие выполнено + +### Requirement: Журнал действий +Каждое изменение данных SHALL записываться в `audit_logs` (кто, что, над какой сущностью, значения до и после) в той же транзакции; значения секретов SHALL NOT попадать в журнал. + +#### Scenario: Изменение пишет журнал +- **GIVEN** запись карьеры с id 5 и должностью «Директор» +- **WHEN** владелец меняет должность на «Генеральный директор» +- **THEN** в `audit_logs` есть запись с entity `career_history/5`, before «Директор», after «Генеральный директор» + +#### Scenario: Без токена +- **GIVEN** запрос без заголовка Authorization +- **WHEN** вызывается `POST /cases` +- **THEN** API отвечает 401 и журнал не меняется diff --git a/openspec/changes/brm-10-brief-and-foundation/specs/brand-brief/spec.md b/openspec/changes/brm-10-brief-and-foundation/specs/brand-brief/spec.md new file mode 100644 index 0000000..f1a50ed --- /dev/null +++ b/openspec/changes/brm-10-brief-and-foundation/specs/brand-brief/spec.md @@ -0,0 +1,16 @@ +## ADDED Requirements + +### Requirement: Одностраничный бриф +В репозитории SHALL быть документ `docs/brief.md` с разделами «Цель», «Аудитория», «Площадки», «Что уже есть» и «Вопросы к Татьяне». Каждый раздел SHALL быть заполнен или помечен «не определено». + +#### Scenario: Все разделы на месте +- **GIVEN** открыт файл `docs/brief.md` +- **WHEN** проверяются заголовки разделов +- **THEN** присутствуют «Цель», «Аудитория», «Площадки», «Что уже есть», «Вопросы к Татьяне» +- **AND** пустых разделов нет + +#### Scenario: Неизвестное не придумывается +- **GIVEN** срок цели не назван ни в стори, ни в источниках +- **WHEN** читается раздел «Цель» +- **THEN** срок указан как «не определено» +- **BUT** контент-плана и обещаний по цифрам в брифе нет diff --git a/openspec/changes/brm-10-brief-and-foundation/specs/brand-knowledge-base/spec.md b/openspec/changes/brm-10-brief-and-foundation/specs/brand-knowledge-base/spec.md new file mode 100644 index 0000000..f5a26f2 --- /dev/null +++ b/openspec/changes/brm-10-brief-and-foundation/specs/brand-knowledge-base/spec.md @@ -0,0 +1,35 @@ +## ADDED Requirements + +### Requirement: Факты со статусом достоверности +Система SHALL хранить факты о Татьяне (профиль, карьера, квалификации, кейсы) со статусом `public_confirmed`, `internal_confirmed`, `hypothesis`, `outdated` или `forbidden`, датами создания и актуализации и ссылкой на источник. + +#### Scenario: Создание факта с источником +- **GIVEN** авторизованный владелец и источник «LinkedIn-профиль» с id 1 +- **WHEN** он создаёт запись карьеры «Казахтелеком» со статусом `hypothesis` и `source_evidence_id` 1 +- **THEN** API отвечает 201 и возвращает запись с `created_at` и `updated_at` + +#### Scenario: Недопустимый статус +- **GIVEN** авторизованный владелец +- **WHEN** он создаёт кейс со статусом «точно правда» +- **THEN** API отвечает 422 и запись не создаётся + +### Requirement: Публичный вывод только подтверждённого +Публичный вывод (`audience=public`) SHALL содержать только записи `public_confirmed`; кейс SHALL попадать в него только при `public_use_permitted = true`. + +#### Scenario: Гипотеза скрыта +- **GIVEN** две записи карьеры: «Казпочта» `public_confirmed` и «Грант» `hypothesis` +- **WHEN** запрашивается `GET /career?audience=public` +- **THEN** в ответе одна запись — «Казпочта» + +#### Scenario: Кейс без разрешения +- **GIVEN** кейс `public_confirmed` с `public_use_permitted = false` +- **WHEN** запрашивается `GET /cases?audience=public` +- **THEN** кейса в ответе нет + +### Requirement: Историческая роль не текущая +Запись карьеры SHALL иметь признак `is_current`; публичный профиль SHALL выводить как текущие только записи с `is_current = true`. + +#### Scenario: Прошлая должность +- **GIVEN** запись «Телеконтакт, генеральный директор» с `is_current = false` +- **WHEN** запрашивается публичный профиль +- **THEN** эта запись в разделе «текущие роли» отсутствует diff --git a/openspec/changes/brm-10-brief-and-foundation/tasks.md b/openspec/changes/brm-10-brief-and-foundation/tasks.md new file mode 100644 index 0000000..af9026b --- /dev/null +++ b/openspec/changes/brm-10-brief-and-foundation/tasks.md @@ -0,0 +1,20 @@ +## 1. Бриф +- [ ] 1.1 Написать `docs/brief.md` из ТЗ BRM-10: цель, аудитория, 2–3 площадки, что уже есть, вопросы к Татьяне; неизвестное — «не определено» + +## 2. Каркас сервиса +- [ ] 2.1 Инициализировать TS-проект (Fastify, vitest, eslint), `GET /healthz`, чтение `$PORT`; заполнить `checks` в `.peppa/project.json` +- [ ] 2.2 Подключить Postgres, раннер миграций (`db:migrate`), Bearer-аутентификацию по `API_TOKEN` +- [ ] 2.3 Адаптировать `Dockerfile` и `deploy/compose.yml`, проверить `docker build` и `/healthz` + +## 3. Knowledge Base +- [ ] 3.1 Миграции: `source_evidence`, `person_profile`, `career_history`, `credentials`, `cases`, enum `fact_status` +- [ ] 3.2 CRUD API с валидацией статусов (422) и фильтром `audience=public` +- [ ] 3.3 Тесты по сценариям spec `brand-knowledge-base` + +## 4. Согласования и аудит +- [ ] 4.1 Миграции `approvals`, `audit_logs`, таблица политики действий (A/B/C) +- [ ] 4.2 Запись в аудит в транзакции с изменением; проверка режима C +- [ ] 4.3 Тесты по сценариям spec `approvals-audit` + +## 5. Завершение +- [ ] 5.1 Записать память проекта, прогнать `bash .gitea/peppa-check.sh` по всем проверкам и `openspec validate brm-10-brief-and-foundation` -- 2.45.2 From 9d384695660a808ae554267dd39e0b7e0e9c0f1f Mon Sep 17 00:00:00 2001 From: Peppa Date: Sun, 15 Nov 2026 13:59:30 +0500 Subject: [PATCH 2/4] =?UTF-8?q?BRM-10:=20=D0=B1=D1=80=D0=B8=D1=84=20docs/b?= =?UTF-8?q?rief.md?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Sonnet 5.5 --- docs/brief-brm-10.md | 35 +++++++++++++++++++ .../brm-10-brief-and-foundation/design.md | 2 +- .../brm-10-brief-and-foundation/proposal.md | 2 +- .../specs/brand-brief/spec.md | 4 +-- .../brm-10-brief-and-foundation/tasks.md | 2 +- 5 files changed, 40 insertions(+), 5 deletions(-) create mode 100644 docs/brief-brm-10.md diff --git a/docs/brief-brm-10.md b/docs/brief-brm-10.md new file mode 100644 index 0000000..dcce8f1 --- /dev/null +++ b/docs/brief-brm-10.md @@ -0,0 +1,35 @@ +# Бриф: личный бренд Татьяны Сайфаровой + +Версия 1.0 · 2026-11-15 · источник: ТЗ BRM-10 (заказчик — Татьяна Сайфарова). Всё, чего нет в ТЗ, помечено «не определено». + +## Цель +- **Главная цель:** клиенты — коммерческие обращения и контракты на консультирование, диагностику, обучение и выступления (ТЗ п.1, п.15). +- **Второстепенные:** авторитет и узнаваемость среди руководителей; приглашения на выступления и в СМИ. +- **Срок:** первая стратегия на 60 дней; срок по доходу и числу клиентов — не определено. +- **Рабочая гипотеза позиционирования:** «архитектор бизнес-трансформации эпохи AI» — требует проверки, не утверждена. + +## Аудитория +Первые лица и руководители крупных и средних компаний (CEO, COO, CFO, HRD, CDO, собственники) в телеком, банках, ритейле и сервисе; предприниматели, которым нужны AI-продукты без разработчиков. Задача: внедрить AI ради измеримого результата, не потеряв управляемость и качество клиентского опыта. География: Казахстан → Центральная Азия → международный рынок. Язык: русский, далее казахский и английский. Размер, отрасли в приоритете и платёжеспособность — не определено. + +## Площадки +1. **LinkedIn** — профессиональное позиционирование и поиск корпоративных заказчиков и международной аудитории. +2. **Telegram** — авторский канал для длинной работы с русскоязычной деловой аудиторией, аналитика и анонсы. +3. **Персональный сайт saifarova.com** — центральный актив: биография, кейсы, продукты, заявки (доступность не проверена — не определено). + +Instagram и Facebook — вторая волна, выбор после аудита каналов. + +## Что уже есть +- Сайт saifarova.com — состояние не определено (проверить). +- Профили LinkedIn, Instagram, Facebook — ссылки и состояние не определены. +- Материалы в Google Drive, выступления, CV, сертификаты — доступа пока нет, не определено. +- Подтверждённые кейсы и разрешения на их публикацию — не определено; закрытые корпоративные проекты только обезличенно. +- Согласованные подписные базы и контакты — не определено. + +## Вопросы к Татьяне +1. Какой срок и какой результат считать успехом (число обращений, доход)? +2. Верна ли фамилия «Сайфарова» (в части материалов «Сафарова»)? Дайте ссылки на все ваши профили и сайт. +3. Какие должности текущие, какие исторические; что разрешено указывать публично? +4. Какие кейсы можно публиковать и в каком виде? Какие сертификаты подтверждены документами? +5. Нет ли ограничений от работодателя на консалтинг и публичные выступления? +6. Какие цены и форматы продуктов вы готовы утвердить? +7. Что разрешено делать агенту без согласования (режимы A/B/C)? diff --git a/openspec/changes/brm-10-brief-and-foundation/design.md b/openspec/changes/brm-10-brief-and-foundation/design.md index b48f8d7..268b08d 100644 --- a/openspec/changes/brm-10-brief-and-foundation/design.md +++ b/openspec/changes/brm-10-brief-and-foundation/design.md @@ -16,7 +16,7 @@ - **Аудит**: любая запись/изменение в одной транзакции с `audit_logs` (actor, action, entity, before/after JSON). Секреты в журнал не пишутся. - **Аутентификация**: единый токен владельца из `API_TOKEN` (Bearer); без него всё, кроме `/healthz`, — 401. -- **Бриф**: `docs/brief.md` пишется вручную из ТЗ; неизвестное — «не определено». +- **Бриф**: `docs/brief-brm-10.md` пишется вручную из ТЗ; неизвестное — «не определено». ## Риски diff --git a/openspec/changes/brm-10-brief-and-foundation/proposal.md b/openspec/changes/brm-10-brief-and-foundation/proposal.md index 7777ba9..76be300 100644 --- a/openspec/changes/brm-10-brief-and-foundation/proposal.md +++ b/openspec/changes/brm-10-brief-and-foundation/proposal.md @@ -10,7 +10,7 @@ ## What Changes -- **Бриф** — один документ `docs/brief.md` (цель, аудитория, 2–3 площадки, что уже есть); +- **Бриф** — один документ `docs/brief-brm-10.md` (цель, аудитория, 2–3 площадки, что уже есть); неизвестное помечено «не определено», плюс список вопросов к Татьяне. Без контент-плана и обещаний по цифрам. - **Brand Knowledge Base (ядро)**: сущности `person_profile`, `career_history`, `credentials`, `cases`, `source_evidence` с датой создания/актуализации, источником и статусом достоверности diff --git a/openspec/changes/brm-10-brief-and-foundation/specs/brand-brief/spec.md b/openspec/changes/brm-10-brief-and-foundation/specs/brand-brief/spec.md index f1a50ed..cc66e4b 100644 --- a/openspec/changes/brm-10-brief-and-foundation/specs/brand-brief/spec.md +++ b/openspec/changes/brm-10-brief-and-foundation/specs/brand-brief/spec.md @@ -1,10 +1,10 @@ ## ADDED Requirements ### Requirement: Одностраничный бриф -В репозитории SHALL быть документ `docs/brief.md` с разделами «Цель», «Аудитория», «Площадки», «Что уже есть» и «Вопросы к Татьяне». Каждый раздел SHALL быть заполнен или помечен «не определено». +В репозитории SHALL быть документ `docs/brief-brm-10.md` с разделами «Цель», «Аудитория», «Площадки», «Что уже есть» и «Вопросы к Татьяне». Каждый раздел SHALL быть заполнен или помечен «не определено». #### Scenario: Все разделы на месте -- **GIVEN** открыт файл `docs/brief.md` +- **GIVEN** открыт файл `docs/brief-brm-10.md` - **WHEN** проверяются заголовки разделов - **THEN** присутствуют «Цель», «Аудитория», «Площадки», «Что уже есть», «Вопросы к Татьяне» - **AND** пустых разделов нет diff --git a/openspec/changes/brm-10-brief-and-foundation/tasks.md b/openspec/changes/brm-10-brief-and-foundation/tasks.md index af9026b..dd8e8d1 100644 --- a/openspec/changes/brm-10-brief-and-foundation/tasks.md +++ b/openspec/changes/brm-10-brief-and-foundation/tasks.md @@ -1,5 +1,5 @@ ## 1. Бриф -- [ ] 1.1 Написать `docs/brief.md` из ТЗ BRM-10: цель, аудитория, 2–3 площадки, что уже есть, вопросы к Татьяне; неизвестное — «не определено» +- [ ] 1.1 Написать `docs/brief-brm-10.md` из ТЗ BRM-10: цель, аудитория, 2–3 площадки, что уже есть, вопросы к Татьяне; неизвестное — «не определено» ## 2. Каркас сервиса - [ ] 2.1 Инициализировать TS-проект (Fastify, vitest, eslint), `GET /healthz`, чтение `$PORT`; заполнить `checks` в `.peppa/project.json` -- 2.45.2 From 278819cc0507b63ecb07572b8eed01f9d5c7d9c3 Mon Sep 17 00:00:00 2001 From: Peppa Date: Sun, 15 Nov 2026 14:02:05 +0500 Subject: [PATCH 3/4] =?UTF-8?q?BRM-10:=20=D1=81=D0=B5=D1=80=D0=B2=D0=B8?= =?UTF-8?q?=D1=81=20Knowledge=20Base,=20=D1=81=D0=BE=D0=B3=D0=BB=D0=B0?= =?UTF-8?q?=D1=81=D0=BE=D0=B2=D0=B0=D0=BD=D0=B8=D1=8F=20A/B/C,=20=D0=B0?= =?UTF-8?q?=D1=83=D0=B4=D0=B8=D1=82,=20=D0=B4=D0=B5=D0=BF=D0=BB=D0=BE?= =?UTF-8?q?=D0=B9-=D0=BA=D0=BE=D0=BD=D1=84=D0=B8=D0=B3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Sonnet 5.5 --- .dockerignore | 4 + .gitignore | 1 + .peppa/memory.md | 6 + .peppa/project.json | 21 +- Dockerfile | 16 + deploy/compose.yml | 18 + eslint.config.js | 3 + migrations/001_init.sql | 101 + .../.openspec.yaml | 0 .../design.md | 0 .../proposal.md | 0 .../specs/approvals-audit/spec.md | 0 .../specs/brand-brief/spec.md | 0 .../specs/brand-knowledge-base/spec.md | 0 .../tasks.md | 22 +- openspec/specs/approvals-audit/spec.md | 38 + openspec/specs/brand-brief/spec.md | 15 + openspec/specs/brand-knowledge-base/spec.md | 40 + package.json | 32 + pnpm-lock.yaml | 2272 +++++++++++++++++ pnpm-workspace.yaml | 2 + src/app.ts | 145 ++ src/db.ts | 56 + src/index.ts | 13 + src/migrate.ts | 11 + src/resources.ts | 51 + tests/approvals-audit.test.ts | 65 + tests/helpers.ts | 34 + tests/knowledge-base.test.ts | 54 + tsconfig.build.json | 1 + tsconfig.json | 7 + 31 files changed, 3016 insertions(+), 12 deletions(-) create mode 100644 .dockerignore create mode 100644 Dockerfile create mode 100644 eslint.config.js create mode 100644 migrations/001_init.sql rename openspec/changes/{brm-10-brief-and-foundation => archive/2026-11-15-brm-10-brief-and-foundation}/.openspec.yaml (100%) rename openspec/changes/{brm-10-brief-and-foundation => archive/2026-11-15-brm-10-brief-and-foundation}/design.md (100%) rename openspec/changes/{brm-10-brief-and-foundation => archive/2026-11-15-brm-10-brief-and-foundation}/proposal.md (100%) rename openspec/changes/{brm-10-brief-and-foundation => archive/2026-11-15-brm-10-brief-and-foundation}/specs/approvals-audit/spec.md (100%) rename openspec/changes/{brm-10-brief-and-foundation => archive/2026-11-15-brm-10-brief-and-foundation}/specs/brand-brief/spec.md (100%) rename openspec/changes/{brm-10-brief-and-foundation => archive/2026-11-15-brm-10-brief-and-foundation}/specs/brand-knowledge-base/spec.md (100%) rename openspec/changes/{brm-10-brief-and-foundation => archive/2026-11-15-brm-10-brief-and-foundation}/tasks.md (56%) create mode 100644 openspec/specs/approvals-audit/spec.md create mode 100644 openspec/specs/brand-knowledge-base/spec.md create mode 100644 package.json create mode 100644 pnpm-lock.yaml create mode 100644 pnpm-workspace.yaml create mode 100644 src/app.ts create mode 100644 src/db.ts create mode 100644 src/index.ts create mode 100644 src/migrate.ts create mode 100644 src/resources.ts create mode 100644 tests/approvals-audit.test.ts create mode 100644 tests/helpers.ts create mode 100644 tests/knowledge-base.test.ts create mode 100644 tsconfig.build.json create mode 100644 tsconfig.json diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..3f29ae6 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,4 @@ +node_modules +dist +.git +.env diff --git a/.gitignore b/.gitignore index 8f85d90..30e1885 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ node_modules/ .env .env.local .DS_Store +dist/ diff --git a/.peppa/memory.md b/.peppa/memory.md index 59bb0dc..f106b24 100644 --- a/.peppa/memory.md +++ b/.peppa/memory.md @@ -6,3 +6,9 @@ - Открытый веб-поиск не находит профили Татьяны Сафаровой: ссылки в брифе не выдумываем, ставим «уточнить у Татьяны». BRM-3…BRM-10 — дубли, закрывает PM. - BRM-4: бриф в docs/positioning-brief.md (≤60 строк, гипотезы с пометкой «Допущение»); дубли BRM-1…10 закрывает PM; ветки от main. - BRM-3: docs/positioning.md без выдуманных фактов, только «нужно уточнить»; ветки брались от main (task/brm-3), гипотезы из BRM-1/2 не переносили. + +## Команды +- Проверки: pnpm lint|typecheck|test|build; миграции — migrations/*.sql, pnpm db:migrate (нужны DATABASE_URL, API_TOKEN); тесты на PGlite (tests/helpers.ts), локального Postgres нет. + +## Грабли +- typescript-eslint не работает с TS 7 — держим typescript@6; pnpm 11 требует allowBuilds (pnpm-workspace.yaml) и его копирования в Dockerfile. diff --git a/.peppa/project.json b/.peppa/project.json index edc8f52..6ff4712 100644 --- a/.peppa/project.json +++ b/.peppa/project.json @@ -1 +1,20 @@ -{"slug":"brendmanager","key":"BRM","name":"Бренд менеджер","peppaUrl":"https://peppa.telecom.quest"} +{ + "slug": "brendmanager", + "key": "BRM", + "name": "Бренд менеджер", + "peppaUrl": "https://peppa.telecom.quest", + "checks": { + "install": "pnpm install --frozen-lockfile", + "lint": "pnpm lint", + "typecheck": "pnpm typecheck", + "test": "pnpm test", + "build": "pnpm build" + }, + "deploy": { + "compose": "deploy/compose.yml", + "service": "web", + "port": 3000, + "health": "/healthz", + "migrate": "pnpm db:migrate" + } +} \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..3883dc0 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,16 @@ +# Заготовка для Node.js (pnpm). Скопируй в ./Dockerfile и поправь под проект. +# Приложение слушает $PORT и отвечает 200 на GET /healthz (deploy.health). +FROM node:22-bookworm-slim AS build +WORKDIR /app +RUN corepack enable +COPY package.json pnpm-lock.yaml* pnpm-workspace.yaml ./ +RUN pnpm install --frozen-lockfile +COPY . . +RUN pnpm build + +FROM node:22-bookworm-slim +WORKDIR /app +ENV NODE_ENV=production PORT=3000 +COPY --from=build /app ./ +EXPOSE 3000 +CMD ["node", "dist/index.js"] diff --git a/deploy/compose.yml b/deploy/compose.yml index 01936ba..54a710d 100644 --- a/deploy/compose.yml +++ b/deploy/compose.yml @@ -8,14 +8,32 @@ services: restart: unless-stopped environment: PORT: "${APP_PORT:-3000}" + DATABASE_URL: "${DATABASE_URL:-postgres://brand:brand@db:5432/brand}" + API_TOKEN: "${API_TOKEN}" + depends_on: + - db networks: - traefik_default + - default labels: - traefik.enable=true - traefik.docker.network=traefik_default - traefik.http.routers.${ROUTER}.rule=Host(`${HOST}`) - traefik.http.routers.${ROUTER}.entrypoints=web - traefik.http.services.${ROUTER}.loadbalancer.server.port=${APP_PORT:-3000} + db: + image: postgres:17-alpine + restart: unless-stopped + environment: + POSTGRES_USER: brand + POSTGRES_PASSWORD: brand + POSTGRES_DB: brand + volumes: + - dbdata:/var/lib/postgresql/data + networks: + - default +volumes: + dbdata: networks: traefik_default: external: true diff --git a/eslint.config.js b/eslint.config.js new file mode 100644 index 0000000..ea42d71 --- /dev/null +++ b/eslint.config.js @@ -0,0 +1,3 @@ +import tseslint from "typescript-eslint"; + +export default tseslint.config({ ignores: ["dist", "node_modules"] }, ...tseslint.configs.recommended); diff --git a/migrations/001_init.sql b/migrations/001_init.sql new file mode 100644 index 0000000..569f480 --- /dev/null +++ b/migrations/001_init.sql @@ -0,0 +1,101 @@ +create type fact_status as enum ('public_confirmed', 'internal_confirmed', 'hypothesis', 'outdated', 'forbidden'); + +create table source_evidence ( + id serial primary key, + title text not null, + url text, + note text, + status fact_status not null default 'hypothesis', + confidence int check (confidence between 0 and 100), + created_at timestamptz not null default now(), + updated_at timestamptz not null default now() +); + +create table person_profile ( + id serial primary key, + full_name text not null, + headline text, + bio text, + status fact_status not null default 'hypothesis', + confidence int check (confidence between 0 and 100), + source_evidence_id int references source_evidence(id), + created_at timestamptz not null default now(), + updated_at timestamptz not null default now() +); + +create table career_history ( + id serial primary key, + organization text not null, + position text, + start_year int, + end_year int, + is_current boolean not null default false, + status fact_status not null default 'hypothesis', + confidence int check (confidence between 0 and 100), + source_evidence_id int references source_evidence(id), + created_at timestamptz not null default now(), + updated_at timestamptz not null default now() +); + +create table credentials ( + id serial primary key, + title text not null, + issuer text, + year int, + document_url text, + status fact_status not null default 'hypothesis', + confidence int check (confidence between 0 and 100), + source_evidence_id int references source_evidence(id), + created_at timestamptz not null default now(), + updated_at timestamptz not null default now() +); + +create table cases ( + id serial primary key, + title text not null, + problem text, + role text, + solution text, + scale text, + result text, + metrics text, + public_use_permitted boolean not null default false, + status fact_status not null default 'hypothesis', + confidence int check (confidence between 0 and 100), + source_evidence_id int references source_evidence(id), + created_at timestamptz not null default now(), + updated_at timestamptz not null default now() +); + +create table action_policy ( + action text primary key, + mode char(1) not null check (mode in ('A', 'B', 'C')), + granted boolean not null default false +); + +create table approvals ( + id serial primary key, + action text not null references action_policy(action), + status text not null default 'pending' check (status in ('pending', 'approved', 'rejected', 'used')), + payload jsonb, + requested_at timestamptz not null default now(), + decided_at timestamptz +); + +create table audit_logs ( + id serial primary key, + actor text not null, + action text not null, + entity text not null, + before jsonb, + after jsonb, + created_at timestamptz not null default now() +); + +insert into action_policy (action, mode) values + ('create_hypothesis', 'A'), + ('schedule_approved_content', 'B'), + ('set_public_positioning', 'C'), + ('publish_sensitive_case', 'C'), + ('send_commercial_offer', 'C'), + ('send_personal_letter', 'C'); diff --git a/openspec/changes/brm-10-brief-and-foundation/.openspec.yaml b/openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/.openspec.yaml similarity index 100% rename from openspec/changes/brm-10-brief-and-foundation/.openspec.yaml rename to openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/.openspec.yaml diff --git a/openspec/changes/brm-10-brief-and-foundation/design.md b/openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/design.md similarity index 100% rename from openspec/changes/brm-10-brief-and-foundation/design.md rename to openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/design.md diff --git a/openspec/changes/brm-10-brief-and-foundation/proposal.md b/openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/proposal.md similarity index 100% rename from openspec/changes/brm-10-brief-and-foundation/proposal.md rename to openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/proposal.md diff --git a/openspec/changes/brm-10-brief-and-foundation/specs/approvals-audit/spec.md b/openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/specs/approvals-audit/spec.md similarity index 100% rename from openspec/changes/brm-10-brief-and-foundation/specs/approvals-audit/spec.md rename to openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/specs/approvals-audit/spec.md diff --git a/openspec/changes/brm-10-brief-and-foundation/specs/brand-brief/spec.md b/openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/specs/brand-brief/spec.md similarity index 100% rename from openspec/changes/brm-10-brief-and-foundation/specs/brand-brief/spec.md rename to openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/specs/brand-brief/spec.md diff --git a/openspec/changes/brm-10-brief-and-foundation/specs/brand-knowledge-base/spec.md b/openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/specs/brand-knowledge-base/spec.md similarity index 100% rename from openspec/changes/brm-10-brief-and-foundation/specs/brand-knowledge-base/spec.md rename to openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/specs/brand-knowledge-base/spec.md diff --git a/openspec/changes/brm-10-brief-and-foundation/tasks.md b/openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/tasks.md similarity index 56% rename from openspec/changes/brm-10-brief-and-foundation/tasks.md rename to openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/tasks.md index dd8e8d1..5702ecf 100644 --- a/openspec/changes/brm-10-brief-and-foundation/tasks.md +++ b/openspec/changes/archive/2026-11-15-brm-10-brief-and-foundation/tasks.md @@ -1,20 +1,20 @@ ## 1. Бриф -- [ ] 1.1 Написать `docs/brief-brm-10.md` из ТЗ BRM-10: цель, аудитория, 2–3 площадки, что уже есть, вопросы к Татьяне; неизвестное — «не определено» +- [x] 1.1 Написать `docs/brief-brm-10.md` из ТЗ BRM-10: цель, аудитория, 2–3 площадки, что уже есть, вопросы к Татьяне; неизвестное — «не определено» ## 2. Каркас сервиса -- [ ] 2.1 Инициализировать TS-проект (Fastify, vitest, eslint), `GET /healthz`, чтение `$PORT`; заполнить `checks` в `.peppa/project.json` -- [ ] 2.2 Подключить Postgres, раннер миграций (`db:migrate`), Bearer-аутентификацию по `API_TOKEN` -- [ ] 2.3 Адаптировать `Dockerfile` и `deploy/compose.yml`, проверить `docker build` и `/healthz` +- [x] 2.1 Инициализировать TS-проект (Fastify, vitest, eslint), `GET /healthz`, чтение `$PORT`; заполнить `checks` в `.peppa/project.json` +- [x] 2.2 Подключить Postgres, раннер миграций (`db:migrate`), Bearer-аутентификацию по `API_TOKEN` +- [x] 2.3 Адаптировать `Dockerfile` и `deploy/compose.yml`, проверить `docker build` и `/healthz` ## 3. Knowledge Base -- [ ] 3.1 Миграции: `source_evidence`, `person_profile`, `career_history`, `credentials`, `cases`, enum `fact_status` -- [ ] 3.2 CRUD API с валидацией статусов (422) и фильтром `audience=public` -- [ ] 3.3 Тесты по сценариям spec `brand-knowledge-base` +- [x] 3.1 Миграции: `source_evidence`, `person_profile`, `career_history`, `credentials`, `cases`, enum `fact_status` +- [x] 3.2 CRUD API с валидацией статусов (422) и фильтром `audience=public` +- [x] 3.3 Тесты по сценариям spec `brand-knowledge-base` ## 4. Согласования и аудит -- [ ] 4.1 Миграции `approvals`, `audit_logs`, таблица политики действий (A/B/C) -- [ ] 4.2 Запись в аудит в транзакции с изменением; проверка режима C -- [ ] 4.3 Тесты по сценариям spec `approvals-audit` +- [x] 4.1 Миграции `approvals`, `audit_logs`, таблица политики действий (A/B/C) +- [x] 4.2 Запись в аудит в транзакции с изменением; проверка режима C +- [x] 4.3 Тесты по сценариям spec `approvals-audit` ## 5. Завершение -- [ ] 5.1 Записать память проекта, прогнать `bash .gitea/peppa-check.sh` по всем проверкам и `openspec validate brm-10-brief-and-foundation` +- [x] 5.1 Записать память проекта, прогнать `bash .gitea/peppa-check.sh` по всем проверкам и `openspec validate brm-10-brief-and-foundation` diff --git a/openspec/specs/approvals-audit/spec.md b/openspec/specs/approvals-audit/spec.md new file mode 100644 index 0000000..ab33a9b --- /dev/null +++ b/openspec/specs/approvals-audit/spec.md @@ -0,0 +1,38 @@ +# approvals-audit Specification + +## Purpose +TBD - created by archiving change brm-10-brief-and-foundation. Update Purpose after archive. + +## Requirements + +### Requirement: Режимы полномочий +Система SHALL сопоставлять каждому действию режим A (автономно), B (в утверждённых пределах) или C (только с одобрением Татьяны). Действие режима C SHALL выполняться только при одобренном согласовании. + +#### Scenario: Режим C без одобрения +- **GIVEN** действие `set_public_positioning` относится к режиму C +- **WHEN** оно запрошено без одобренного согласования +- **THEN** API отвечает 403 +- **AND** создано согласование со статусом `pending` + +#### Scenario: Режим C с одобрением +- **GIVEN** согласование на `set_public_positioning` со статусом `approved` +- **WHEN** действие запрошено с этим согласованием +- **THEN** действие выполнено, API отвечает 200 + +#### Scenario: Режим A +- **GIVEN** действие `create_hypothesis` относится к режиму A +- **WHEN** оно запрошено без согласования +- **THEN** действие выполнено + +### Requirement: Журнал действий +Каждое изменение данных SHALL записываться в `audit_logs` (кто, что, над какой сущностью, значения до и после) в той же транзакции; значения секретов SHALL NOT попадать в журнал. + +#### Scenario: Изменение пишет журнал +- **GIVEN** запись карьеры с id 5 и должностью «Директор» +- **WHEN** владелец меняет должность на «Генеральный директор» +- **THEN** в `audit_logs` есть запись с entity `career_history/5`, before «Директор», after «Генеральный директор» + +#### Scenario: Без токена +- **GIVEN** запрос без заголовка Authorization +- **WHEN** вызывается `POST /cases` +- **THEN** API отвечает 401 и журнал не меняется diff --git a/openspec/specs/brand-brief/spec.md b/openspec/specs/brand-brief/spec.md index 9bf4689..4eb6a7c 100644 --- a/openspec/specs/brand-brief/spec.md +++ b/openspec/specs/brand-brief/spec.md @@ -23,3 +23,18 @@ TBD - created by archiving change brm-1-brand-brief. Update Purpose after archiv - **GIVEN** ссылку на Instagram не удалось найти в открытых источниках - **WHEN** читается раздел «Где её видно сейчас» - **THEN** у Instagram стоит «уточнить у Татьяны», ссылка не придумана + +### Requirement: Одностраничный бриф +В репозитории SHALL быть документ `docs/brief-brm-10.md` с разделами «Цель», «Аудитория», «Площадки», «Что уже есть» и «Вопросы к Татьяне». Каждый раздел SHALL быть заполнен или помечен «не определено». + +#### Scenario: Все разделы на месте +- **GIVEN** открыт файл `docs/brief-brm-10.md` +- **WHEN** проверяются заголовки разделов +- **THEN** присутствуют «Цель», «Аудитория», «Площадки», «Что уже есть», «Вопросы к Татьяне» +- **AND** пустых разделов нет + +#### Scenario: Неизвестное не придумывается +- **GIVEN** срок цели не назван ни в стори, ни в источниках +- **WHEN** читается раздел «Цель» +- **THEN** срок указан как «не определено» +- **BUT** контент-плана и обещаний по цифрам в брифе нет diff --git a/openspec/specs/brand-knowledge-base/spec.md b/openspec/specs/brand-knowledge-base/spec.md new file mode 100644 index 0000000..e3bdb8f --- /dev/null +++ b/openspec/specs/brand-knowledge-base/spec.md @@ -0,0 +1,40 @@ +# brand-knowledge-base Specification + +## Purpose +TBD - created by archiving change brm-10-brief-and-foundation. Update Purpose after archive. + +## Requirements + +### Requirement: Факты со статусом достоверности +Система SHALL хранить факты о Татьяне (профиль, карьера, квалификации, кейсы) со статусом `public_confirmed`, `internal_confirmed`, `hypothesis`, `outdated` или `forbidden`, датами создания и актуализации и ссылкой на источник. + +#### Scenario: Создание факта с источником +- **GIVEN** авторизованный владелец и источник «LinkedIn-профиль» с id 1 +- **WHEN** он создаёт запись карьеры «Казахтелеком» со статусом `hypothesis` и `source_evidence_id` 1 +- **THEN** API отвечает 201 и возвращает запись с `created_at` и `updated_at` + +#### Scenario: Недопустимый статус +- **GIVEN** авторизованный владелец +- **WHEN** он создаёт кейс со статусом «точно правда» +- **THEN** API отвечает 422 и запись не создаётся + +### Requirement: Публичный вывод только подтверждённого +Публичный вывод (`audience=public`) SHALL содержать только записи `public_confirmed`; кейс SHALL попадать в него только при `public_use_permitted = true`. + +#### Scenario: Гипотеза скрыта +- **GIVEN** две записи карьеры: «Казпочта» `public_confirmed` и «Грант» `hypothesis` +- **WHEN** запрашивается `GET /career?audience=public` +- **THEN** в ответе одна запись — «Казпочта» + +#### Scenario: Кейс без разрешения +- **GIVEN** кейс `public_confirmed` с `public_use_permitted = false` +- **WHEN** запрашивается `GET /cases?audience=public` +- **THEN** кейса в ответе нет + +### Requirement: Историческая роль не текущая +Запись карьеры SHALL иметь признак `is_current`; публичный профиль SHALL выводить как текущие только записи с `is_current = true`. + +#### Scenario: Прошлая должность +- **GIVEN** запись «Телеконтакт, генеральный директор» с `is_current = false` +- **WHEN** запрашивается публичный профиль +- **THEN** эта запись в разделе «текущие роли» отсутствует diff --git a/package.json b/package.json new file mode 100644 index 0000000..e7eaaaf --- /dev/null +++ b/package.json @@ -0,0 +1,32 @@ +{ + "name": "brendmanager", + "version": "0.1.0", + "private": true, + "type": "module", + "engines": { + "node": ">=22" + }, + "scripts": { + "dev": "tsx watch src/index.ts", + "build": "tsc -p tsconfig.build.json", + "start": "node dist/index.js", + "lint": "eslint .", + "typecheck": "tsc --noEmit", + "test": "vitest run", + "db:migrate": "node dist/migrate.js" + }, + "dependencies": { + "fastify": "^5.12.8", + "pg": "^8.23.1" + }, + "devDependencies": { + "@electric-sql/pglite": "^0.5.16", + "@types/node": "^26.6.6", + "@types/pg": "^8.23.1", + "eslint": "^10.15.0", + "tsx": "^4.23.15", + "typescript": "^6.0.3", + "typescript-eslint": "^8.72.2", + "vitest": "^5.1.0" + } +} diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml new file mode 100644 index 0000000..e550896 --- /dev/null +++ b/pnpm-lock.yaml @@ -0,0 +1,2272 @@ +lockfileVersion: '9.0' + +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false + +importers: + + .: + dependencies: + fastify: + specifier: ^5.12.8 + version: 5.12.8 + pg: + specifier: ^8.23.1 + version: 8.23.1 + devDependencies: + '@electric-sql/pglite': + specifier: ^0.5.16 + version: 0.5.16 + '@types/node': + specifier: ^26.6.6 + version: 26.6.6 + '@types/pg': + specifier: ^8.23.1 + version: 8.23.1 + eslint: + specifier: ^10.15.0 + version: 10.15.0 + tsx: + specifier: ^4.23.15 + version: 4.23.15 + typescript: + specifier: ^6.0.3 + version: 6.0.3 + typescript-eslint: + specifier: ^8.72.2 + version: 8.72.2(eslint@10.15.0)(typescript@6.0.3) + vitest: + specifier: ^5.1.0 + version: 5.1.0(@types/node@26.6.6)(vite@8.3.8(@types/node@26.6.6)(esbuild@0.28.2)(tsx@4.23.15)) + +packages: + + '@cacheable/memory@2.2.0': + resolution: {integrity: sha512-CTLKqLItRCEixEAewD3/j9DB3/o96gpTPD4eJ1v+DGOlxZRZncRQkGYqqnAGCscYd6RNeXfGeiuCphsPtqyIfQ==} + + '@cacheable/utils@2.5.0': + resolution: {integrity: sha512-buipgOVDkkPXNR5+xBpDw7Zk2n1EvU7qBJCNUcL7rhQ//kfpOXPAvQ511Os0vpLYJ1pZnvudNytkQt2hst3wqA==} + + '@electric-sql/pglite@0.5.16': + resolution: {integrity: sha512-Nj8KcIsJL748W408U2N8q4+9IlONdpRIU8MJypIAAINMJ5nqKyqpX7Mgg/5XKkXiAib3AoZGR6hnJFlrlLBrcg==} + + '@emnapi/core@2.0.0-beta.2': + resolution: {integrity: sha512-MzCVoWtcg4Pm2B3je5mMvYMvj3MmBKw+fU7vbsJc9/iT8ip6/eYIHo/Dsm/mr+wsHB6SEyJDuxB09Yy6r/8+4A==} + + '@emnapi/runtime@2.0.0-beta.2': + resolution: {integrity: sha512-JcrSPzPvZuNZvJqPTF9Fw25LbOJ8avzFVlaf2grmH4Cku0oGP47tRgqPZadcfj3YoZMHkFVnCYFbQM8I+i5QEw==} + + '@emnapi/wasi-threads@2.2.0': + resolution: {integrity: sha512-JP7OYH38Q7+pyTAe14raZHLQIK7BDKbdwji+Xi3pcd/6QkJYQH3SX4wu6EplGrGJWRepoNzedfm0G3B9Z4e9Rw==} + + '@esbuild/aix-ppc64@0.28.2': + resolution: {integrity: sha512-XExcO+dvLKvVtNTibSTBej1NCAbaGhWn9Ww1ZPx80qsahhPFe/8jgWP0IchNe0F3HwkU7n8ejhH8bjonqht8mQ==} + engines: {node: '>=18'} + cpu: [ppc64] + os: [aix] + + '@esbuild/android-arm64@0.28.2': + resolution: {integrity: sha512-5YfKeeI8qWfBZIX+u2xZC3Zlb3Os/gLS2sbEKM+I4ZOcsWmHS2WLysCcQZDAFRslDUU5Oiq44gf6PYN1vGwG5A==} + engines: {node: '>=18'} + cpu: [arm64] + os: [android] + + '@esbuild/android-arm@0.28.2': + resolution: {integrity: sha512-kXXoiPVVGQcnIYGOeaovwOURpniDBpSq4A03qkQ+BMQqtGG6HYap3xne9C1O1yo4TR3qxlCX5IqqmX6fFo2Lqg==} + engines: {node: '>=18'} + cpu: [arm] + os: [android] + + '@esbuild/android-x64@0.28.2': + resolution: {integrity: sha512-O387ite7SzUyCcy3JQX4P4bLtEA7bLLkx+esve5JHnyYfNTxcVpXZo9jhdB0lTKN44gztELTdU7nS8Nr16Fs1Q==} + engines: {node: '>=18'} + cpu: [x64] + os: [android] + + '@esbuild/darwin-arm64@0.28.2': + resolution: {integrity: sha512-n4KqkOQrraxHJcgjM1RvwbigfQKIKJVpM7xp+KsxiyUSrRdIXnt73VhrPAx0fV44hgfmIVKjxMN9J1t5jySVkw==} + engines: {node: '>=18'} + cpu: [arm64] + os: [darwin] + + '@esbuild/darwin-x64@0.28.2': + resolution: {integrity: sha512-uq6suIWYP37qzGddBKPw5QEQPi6HiLGsO7UmkpfyaYNQ3D+rN6w6WfwH+nuqcGXWvawGwxOEroO4YGnFh95azw==} + engines: {node: '>=18'} + cpu: [x64] + os: [darwin] + + '@esbuild/freebsd-arm64@0.28.2': + resolution: {integrity: sha512-n+I0BTSRIoy+d6RPKnEVwql5UwBJolytvY4mAOIEJorKlqgPII8ix6slVVrfZ5Tnj7glIZvloylbB/EJPMWEXw==} + engines: {node: '>=18'} + cpu: [arm64] + os: [freebsd] + + '@esbuild/freebsd-x64@0.28.2': + resolution: {integrity: sha512-78XJTJkvPs0kz2w61301PJjXl4g7q3JqiYMZ/M/yVI73EHBrCRTgkhu9oqG7vPqq+a/yadEW8aD+agKlk5xrmg==} + engines: {node: '>=18'} + cpu: [x64] + os: [freebsd] + + '@esbuild/linux-arm64@0.28.2': + resolution: {integrity: sha512-pW4AC0P3it8c7do9MVM4p51FzHzdM/TZrerurgRcHJ2WTa1VQ1CIq18xncfpBJw4ojkiZZrKW2yIBWBP92j6Ug==} + engines: {node: '>=18'} + cpu: [arm64] + os: [linux] + + '@esbuild/linux-arm@0.28.2': + resolution: {integrity: sha512-XlDnu2q5yoqems+xay6wSAcg9DDD7K9RLKZEBOMZm3ckNpJBvOX20tSfby8KfrrhINDyv9V2YVZKY/SpoGJI8w==} + engines: {node: '>=18'} + cpu: [arm] + os: [linux] + + '@esbuild/linux-ia32@0.28.2': + resolution: {integrity: sha512-CYbnj78HsIeA+DhgUKgFCfvNsTHFhMMrinUrMZpDXJXKN8T3XViTZ/+wtHeVxEWY8ewSzTFN+nRmSwO2tZaLUQ==} + engines: {node: '>=18'} + cpu: [ia32] + os: [linux] + + '@esbuild/linux-loong64@0.28.2': + resolution: {integrity: sha512-buwkd8nsph4R+ajRvw0qM5Hja/TXQow3ptzWO2EbG/cqcIkHloRrdlBtQlshyYGTNFvfkfJ5tpPLVkY4DtsPfQ==} + engines: {node: '>=18'} + cpu: [loong64] + os: [linux] + + '@esbuild/linux-mips64el@0.28.2': + resolution: {integrity: sha512-ZVykbDyk7519VwiNb9Lcj9m8XM6v5V9uKPvrEMkkEedVewf+0itkhahp4HDpgERXhwLRpWFypsGbG/J8s0QjJA==} + engines: {node: '>=18'} + cpu: [mips64el] + os: [linux] + + '@esbuild/linux-ppc64@0.28.2': + resolution: {integrity: sha512-CAXl+Dtd9UUuJd8pKKdwh6MLm3MUMiqMPmhZ3tTSXPqfyQ3vDl6R5hZdZ/kYojK4ofXtdfSv1tFq8XzWx3heNQ==} + engines: {node: '>=18'} + cpu: [ppc64] + os: [linux] + + '@esbuild/linux-riscv64@0.28.2': + resolution: {integrity: sha512-GeXCej4IQtU1B+QlDV8W/RRvbzI3O/Stss+/bCXv4lZls5WGRtu2a+3JkA3i4qIUlMXpcHebWpF8AkJhATowuA==} + engines: {node: '>=18'} + cpu: [riscv64] + os: [linux] + + '@esbuild/linux-s390x@0.28.2': + resolution: {integrity: sha512-3H1weTYZPxt/WOhByszQZybS9w5lKzUn1FDMsgEChbHWQwHYQQRfBxgCcZvPhjHfKyJjIievvMmEUawJrdY9Dg==} + engines: {node: '>=18'} + cpu: [s390x] + os: [linux] + + '@esbuild/linux-x64@0.28.2': + resolution: {integrity: sha512-4xTZr1FUmSoQW4XIWmit3tzQrUTZM+N3P0XV8xROKYF50XfI7xeO90+1bZvNwxIufQ9hDQVRJH5YhgPVF8A/HQ==} + engines: {node: '>=18'} + cpu: [x64] + os: [linux] + + '@esbuild/netbsd-arm64@0.28.2': + resolution: {integrity: sha512-sSATRjPeDBg3pdgHoQfoYBob11Kk1FGa9lui5RIHZCoCkJa9QKlvl3/vKz2usCmYYjs7ymJR/2Nnsqe+Hjt5nw==} + engines: {node: '>=18'} + cpu: [arm64] + os: [netbsd] + + '@esbuild/netbsd-x64@0.28.2': + resolution: {integrity: sha512-lqnzCV+mM0gIADaKihiCg6ifgfU2L3h5E33rNQBN1Y4MaVGnzryzmvvf7UHxprpQdE8hpqLolJ9Rl+SkIRDpyw==} + engines: {node: '>=18'} + cpu: [x64] + os: [netbsd] + + '@esbuild/openbsd-arm64@0.28.2': + resolution: {integrity: sha512-AL2qJILH7lNjrDmCQDvdxMfAUIv8KMNZOvrwAQ8i8//ntL9FflhOyMJ8OZSMBb8/AWXe3/5v5S20y3zCoZWKoQ==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openbsd] + + '@esbuild/openbsd-x64@0.28.2': + resolution: {integrity: sha512-QtiuPytchRyC4rwUKhexJdQKvDuZ6hWloi3igqPQNUJCS1/v9EiO3UTOXR6A3FoMo4fnAKbWJdqaIwhOzh8qEw==} + engines: {node: '>=18'} + cpu: [x64] + os: [openbsd] + + '@esbuild/openharmony-arm64@0.28.2': + resolution: {integrity: sha512-WkhYDmpTjLvGlScA1rwjRUmhl4k8oXR3cIbtqWmELgU/dFeHHlEllxDvdWcNJV9rbzCexB5vz8gtNewWLgCT7Q==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openharmony] + + '@esbuild/sunos-x64@0.28.2': + resolution: {integrity: sha512-GPMSkTOtMnv2U2F8gxe4Io6qmVs+YKyp832Etqqxr0hFngmXQ3rzwytelm3GIn7T4VviRUlf3sOgBOiTdvaf7g==} + engines: {node: '>=18'} + cpu: [x64] + os: [sunos] + + '@esbuild/win32-arm64@0.28.2': + resolution: {integrity: sha512-PIhhEkE9uPBleRBrQEJpUn7MBnibZzbGzYWPmY3x+YoVg/95zbjB4CxPPOQ8l5tYYM4mMaCthF8/1DIfBQQyWQ==} + engines: {node: '>=18'} + cpu: [arm64] + os: [win32] + + '@esbuild/win32-ia32@0.28.2': + resolution: {integrity: sha512-YmJbfTlvU7Sdn9BB+4PRES4oB6pxgS37MAONj+hBr/cpXS1aBPKXxNnDbu+QCWPj0o9dgyxeq79g6c5P8KeuYA==} + engines: {node: '>=18'} + cpu: [ia32] + os: [win32] + + '@esbuild/win32-x64@0.28.2': + resolution: {integrity: sha512-5ebpxr3nWMzrL/rnUI755Jkuee0bHL/Gq0WTF9lvcpv73wAp5eu8MfBUgWK9bhWvZjj7yX8etf/8tI8Ney695g==} + engines: {node: '>=18'} + cpu: [x64] + os: [win32] + + '@eslint-community/eslint-utils@4.10.1': + resolution: {integrity: sha512-cuadcxVFE8sDK6iWJbs8Sn0av2Nrh2QSGQhVlBW9AaAHqHwjWsZHT8LJ4hFGPh7ASBV2deFdM7H/DPjulmh8rg==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 + + '@eslint-community/regexpp@4.12.3': + resolution: {integrity: sha512-R76UKbvsqI68DJJVTVyqFKqU98CN4+B+acxNfEA2IFarSzP0SjtKf/3+fFiXzTyv5Fj3PxLkGHe2wnVWWMxobQ==} + engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0} + + '@eslint/config-array@0.23.6': + resolution: {integrity: sha512-WrTH7nioI9QPY4NZGnsywmecswJdgeq4BCM76qok9VgjTO29ZgUzUvcuJLVPYVQM4uDbaPBU0M33R9DIxI8X3w==} + engines: {node: ^20.19.0 || ^22.13.0 || >=24} + + '@eslint/config-helpers@0.7.0': + resolution: {integrity: sha512-DObd/KKUsU+FaFv4PLxSRenpXfQWmPXXP3pPZ6/K1PCrMu2vQpMDMuQe/BqYeoLcz8ro0bVDF1RxOJgfVEdhUw==} + engines: {node: ^20.19.0 || ^22.13.0 || >=24} + + '@eslint/core@1.2.1': + resolution: {integrity: sha512-MwcE1P+AZ4C6DWlpin/OmOA54mmIZ/+xZuJiQd4SyB29oAJjN30UW9wkKNptW2ctp4cEsvhlLY/CsQ1uoHDloQ==} + engines: {node: ^20.19.0 || ^22.13.0 || >=24} + + '@eslint/object-schema@3.0.5': + resolution: {integrity: sha512-vqTaUEgxzm+YDSdElad6PiRoX4t8VGDjCtt05zn4nU810UIx/uNEV7/lZJ6KwFThKZOzOxzXy48da+No7HZaMw==} + engines: {node: ^20.19.0 || ^22.13.0 || >=24} + + '@eslint/plugin-kit@0.7.3': + resolution: {integrity: sha512-IkO+/KEUvwbVpiURZg+P7zF74z5Jxe0UgJxVni+RtoHQ6IZieXaO02kmadomap/q+l6bc/jdPGGqTjhuZnuz1Q==} + engines: {node: ^20.19.0 || ^22.13.0 || >=24} + + '@fastify/ajv-compiler@4.0.7': + resolution: {integrity: sha512-VP0yIfwlc1ohj733keYDqyHm1VWeP9VQxYomunhr90jkC4aNNibbkrRiaNgPgqj1ORxUenILR4qzA/ppYBNAtQ==} + + '@fastify/deepmerge@3.2.4': + resolution: {integrity: sha512-kc8GQq5gX9RRhw0rov3DMrN8wS8yRlxJRdDzsYwwdBV/wazuVgc/1K7CKL90tlvu3RlHan6Y0R0aE3nJtBz2eQ==} + + '@fastify/error@4.2.1': + resolution: {integrity: sha512-MYBumuIwP+5MIpXSyKm6/o1Eigcoij186lWUssX3LH5U8KWqU0ktZhzC4CErIX9EJeQeRGI+zJZQWakBlFbUcg==} + + '@fastify/fast-json-stringify-compiler@5.2.0': + resolution: {integrity: sha512-LPTVA0w4oPITWHAvox9NgI1rDSrjUnjxX6QN5MCb9FY+HqvDsUmgLucbj9eQakqC8lYwO7UgkDPHEQLJNl9vtg==} + + '@fastify/forwarded@3.1.2': + resolution: {integrity: sha512-89WiRG+hW3VQSfCwg4Hb8b43PeyEX15K5+lEfsZ4EUth/FyOjS/lv8HsVuswUNXWiSnxMGNouE/fq/0w3VumHQ==} + + '@fastify/merge-json-schemas@0.2.2': + resolution: {integrity: sha512-d/gx9sRbUCVgGRGzma46wLcwiY8noTqO2Nmjg/vbTARxHRE5bdh5PIL8s97Lt1X7ScRWRW52eVYxwIoPwIdVUA==} + + '@fastify/proxy-addr@5.1.2': + resolution: {integrity: sha512-uqB4QsgVoro0XDC+DIftIMGXHdBPn+lK6Ek3xXAIxPMCJfqxnbtyEoMCm2KPUVOuIosd7Cyw9HawEqMFM/UA+g==} + + '@humanfs/core@0.19.2': + resolution: {integrity: sha512-UhXNm+CFMWcbChXywFwkmhqjs3PRCmcSa/hfBgLIb7oQ5HNb1wS0icWsGtSAUNgefHeI+eBrA8I1fxmbHsGdvA==} + engines: {node: '>=18.18.0'} + + '@humanfs/node@0.16.8': + resolution: {integrity: sha512-gE1eQNZ3R++kTzFUpdGlpmy8kDZD/MLyHqDwqjkVQI0JMdI1D51sy1H958PNXYkM2rAac7e5/CnIKZrHtPh3BQ==} + engines: {node: '>=18.18.0'} + + '@humanfs/types@0.15.0': + resolution: {integrity: sha512-ZZ1w0aoQkwuUuC7Yf+7sdeaNfqQiiLcSRbfI08oAxqLtpXQr9AIVX7Ay7HLDuiLYAaFPu8oBYNq/QIi9URHJ3Q==} + engines: {node: '>=18.18.0'} + + '@humanwhocodes/module-importer@1.0.1': + resolution: {integrity: sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==} + engines: {node: '>=12.22'} + + '@humanwhocodes/retry@0.4.3': + resolution: {integrity: sha512-bV0Tgo9K4hfPCek+aMAn81RppFKv2ySDQeMoSZuvTASywNTnVJCArCZE2FWqpvIatKu7VMRLWlR1EazvVhDyhQ==} + engines: {node: '>=18.18'} + + '@isaacs/nonrecursive-glob-match@1.1.0': + resolution: {integrity: sha512-GPm/Dbvk5RLmhRnxXIa7nTpK0xtl4E0wj0MslsuNiJ1FIROU+2+9lgUC/dgF7Ey4QCWhfEsgxilMRMCdHPfDfw==} + + '@jridgewell/resolve-uri@3.1.3': + resolution: {integrity: sha512-lhTtjtoEArWBjismtfS761S9Hlyn+nIZqOZVYoZ1Xn82PMNMVnk+jj/NhC4fAXGTs7ydONcJiR5vyQBTMDu27g==} + engines: {node: '>=6.0.0'} + + '@jridgewell/sourcemap-codec@1.6.0': + resolution: {integrity: sha512-T7jf+5zgsZHwNJ4lvQ7/aezbyk0nNX+zJVWpmHA7VYsEx7a7qr5Rg5IbtJFqkgze5Y2sruq1RUY8Q837Od7iFw==} + + '@jridgewell/trace-mapping@0.3.31': + resolution: {integrity: sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==} + + '@keyv/bigmap@1.3.1': + resolution: {integrity: sha512-WbzE9sdmQtKy8vrNPa9BRnwZh5UF4s1KTmSK0KUVLo3eff5BlQNNWDnFOouNpKfPKDnms9xynJjsMYjMaT/aFQ==} + engines: {node: '>= 18'} + peerDependencies: + keyv: ^5.6.0 + + '@keyv/serialize@1.1.1': + resolution: {integrity: sha512-dXn3FZhPv0US+7dtJsIi2R+c7qWYiReoEh5zUntWCf4oSpMNib8FDhSoed6m3QyZdx5hK7iLFkYk3rNxwt8vTA==} + + '@napi-rs/wasm-runtime@1.2.6': + resolution: {integrity: sha512-mRyDmEw9/fCDXCGfL1sbgIw/GUK0PVxRW4YwgPN61F3LQ+fSyoBFarJVzgGyhF6kRzEQZ0FejDqm4WLXSeqQmw==} + engines: {node: ^20.19.0 || ^22.13.0 || >=23.5.0} + peerDependencies: + '@emnapi/core': ^1.7.1 || 2.0.0-beta.2 + '@emnapi/runtime': ^1.7.1 || 2.0.0-beta.2 + + '@oxc-project/types@0.156.0': + resolution: {integrity: sha512-1Duyg48TdJNdyhEB8Xn1L36bT9Pv6GUtlKjHxOys8xkaF/rQq3XJE+bAurSK/AgIz5mGFsb77cn9Pb20+WCScw==} + + '@pinojs/redact@0.4.0': + resolution: {integrity: sha512-k2ENnmBugE/rzQfEcdWHcCY+/FM3VLzH9cYEsbdsoqrvzAKRhUZeRNhAZvB8OitQJ1TBed3yqWtdjzS6wJKBwg==} + + '@rolldown/binding-android-arm-eabi@1.2.19': + resolution: {integrity: sha512-e+Ebe0WT+9tbXmNKPIiC8YrWAHYwug3m6i4p3rZGGulfZri1jtI4HslT+OZnFf/OIHowWF71DTlHwXBP2SiA7A==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm] + os: [android] + + '@rolldown/binding-android-arm64@1.2.19': + resolution: {integrity: sha512-hOombrTJ+szt2ciEzS7oCA78lMPBgF5UMQWCJIyNfnrI7GLl8HYoFqCnpL2gcPOaXMqryGCU5ExdQKyDDcC+yA==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm64] + os: [android] + + '@rolldown/binding-darwin-arm64@1.2.19': + resolution: {integrity: sha512-XoMA2pwCKGTQzUjPgtRwkedH4WmXhdIPKT6l6oOxd1PUbNodGI6DcBekgN7EC//+x3pfBYX/qL1gNmZAqivw5g==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm64] + os: [darwin] + + '@rolldown/binding-darwin-x64@1.2.19': + resolution: {integrity: sha512-zo8EsSSwMZCY/e+fRnGaX02YGgvJD0yvhNi/9hpGPA2MJ9ZF8dPCw75UGfpI6OpQ/myR/dIYmogRvqiZD0TrXg==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [x64] + os: [darwin] + + '@rolldown/binding-freebsd-x64@1.2.19': + resolution: {integrity: sha512-O8ISAOfI1nj7AuBPd30FSF47z7f7lzlk5poQVGgiikvQuGEBFYvW8ki+UEnT+YJPnNGjQzn304klt4O9FUE7mA==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [x64] + os: [freebsd] + + '@rolldown/binding-linux-arm-gnueabihf@1.2.19': + resolution: {integrity: sha512-/lYCba5NO0yq4S0jGMH8QTBtkvQxoXjoQWzF5BcWp9MjB9jxVRD1GQDNofkVjcOj30DWyhLIN/4Oe60JKzaONw==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm] + os: [linux] + + '@rolldown/binding-linux-arm64-gnu@1.2.19': + resolution: {integrity: sha512-pm/apFMBnSbFb3O6nG5pHO1iqHhZrjGDFEjSm+ot9J17XXPvH9L90y5h+jgfHCE+Qdlsvy8qKEcU4VKxgjD+vA==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm64] + os: [linux] + libc: [glibc] + + '@rolldown/binding-linux-arm64-musl@1.2.19': + resolution: {integrity: sha512-K1SmQp3FFichn8oqrNIwvFoZ5wcvjC7goBzpaMNvLf9FZc+QB/QvLmnpJZgAAGHiD980tP8FZZnXk2K94rvlxg==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm64] + os: [linux] + libc: [musl] + + '@rolldown/binding-linux-ppc64-gnu@1.2.19': + resolution: {integrity: sha512-I0xwD57jP/3A7+5UPZin2w8Y7XHEmEM5zqpYZOcQ45MlNW6tUJUziymV3yRr7rL4vwyfEcRsRksC4a7Kc08p5Q==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [ppc64] + os: [linux] + libc: [glibc] + + '@rolldown/binding-linux-s390x-gnu@1.2.19': + resolution: {integrity: sha512-BrtEHT24SNXj9HiXqy+s/kXiSiQGt6EKCPUlRirAoIioVxKGnbXBUEkbZASAei7iZJB0/Ynm+0JP00Ipx7AnSw==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [s390x] + os: [linux] + libc: [glibc] + + '@rolldown/binding-linux-x64-gnu@1.2.19': + resolution: {integrity: sha512-rm75/9DkHKeU2WnA8w4X94WGYgLlDCFCfkQC+4bguVJmC/jvDRv2B+2wLOYhyE0fVuv7//Ckk39OoOufyCu76Q==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [x64] + os: [linux] + libc: [glibc] + + '@rolldown/binding-linux-x64-musl@1.2.19': + resolution: {integrity: sha512-irh/4+iYFM4GAzpluDErgjz89bj6NDtqqMAG/6O1LG38Ed3NpyebzCpcVNkFW8uhy+/3/BocUvnXDR33CXWe9A==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [x64] + os: [linux] + libc: [musl] + + '@rolldown/binding-openharmony-arm64@1.2.19': + resolution: {integrity: sha512-+KWTWNoPt+CfSq94CiceWu3yPE+QzkaG+phPyz9G60tmZLwfQkcA4AeksafzvJAw4pvg1mcd5a1TkUqVv0s4JA==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm64] + os: [openharmony] + + '@rolldown/binding-wasm32-wasi@1.2.19': + resolution: {integrity: sha512-7EH+skOsl5qpWnK0vzamgJFhOv1cwxQpsxm8tI883K9fur5c27p8q87fzEO6BbBPabA2/+s/zR63/pLc137iOg==} + engines: {node: ^20.19.0 || ^22.13.0 || >=23.5.0} + cpu: [wasm32] + + '@rolldown/binding-win32-arm64-msvc@1.2.19': + resolution: {integrity: sha512-3Q1Yg1Q7tEvBWoZf5rFvG/GKZQPgwfru+p4wBajDfJFBs0SHCpL++dfTjW9gyAKd1T7ZpIYvdaUax7Pa/IhFVQ==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm64] + os: [win32] + + '@rolldown/binding-win32-x64-msvc@1.2.19': + resolution: {integrity: sha512-y/sqRRc6d7hECzOFc5n3LSeqctmIp9mMjY1Kq4s14uLPd/LZ4z7i1zrW6fMtp2mPeuQIC4e6ULMcwQzMomqQag==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [x64] + os: [win32] + + '@rolldown/pluginutils@1.1.1': + resolution: {integrity: sha512-glFIJDvLNDtJhT9qrMFWLPbvS+skxgt4L0K8Ei2YtnhPysAJnsI7nyxSJxKj4ADeKX0OLjC4ntRkwpLOoS3rwA==} + + '@tybys/wasm-util@0.10.4': + resolution: {integrity: sha512-W3c4gRigFS0T/Ma4qIYF3GDAc5AQdHb1yL5znJT1Zv1YaD9Kitx656wBjvr19qbiosmZT8lWDM5BEMynUqX65A==} + + '@types/chai@5.2.3': + resolution: {integrity: sha512-Mw558oeA9fFbv65/y4mHtXDs9bPnFMZAL/jxdPFUpOHHIXX91mcgEHbS5Lahr+pwZFR8A7GQleRWeI6cGFC2UA==} + + '@types/deep-eql@4.0.2': + resolution: {integrity: sha512-c9h9dVVMigMPc4bwTvC5dxqtqJZwQPePsWjPlpSOnojbor6pGqdk541lfA7AqFQr5pB1BRdq0juY9db81BwyFw==} + + '@types/esrecurse@4.3.1': + resolution: {integrity: sha512-xJBAbDifo5hpffDBuHl0Y8ywswbiAp/Wi7Y/GtAgSlZyIABppyurxVueOPE8LUQOxdlgi6Zqce7uoEpqNTeiUw==} + + '@types/estree@1.0.10': + resolution: {integrity: sha512-lTyOMnOcmRBzdCv6/4zUZCrEhV0xrqQiUZBZtVcbmLHBXKLnN8q89v/wKRF/Q0HbwVsqbIG3o5HDoFl9sduM+g==} + + '@types/json-schema@7.0.15': + resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==} + + '@types/node@26.6.6': + resolution: {integrity: sha512-MzQj+8Kx3XI40OmUAE6Qoh58ZMNstNNMwn2nfd3qWsfe7nDNSqJNzes4njhz6AHwrSHOffSLwXU6yb474Q4aog==} + + '@types/pg@8.23.1': + resolution: {integrity: sha512-fKVHpikPdg4GKks3JuLEhvwSyvwzF23hnabPy6DD8ljVbC7+6J5dQzdv4arV6jqq57djnMgs1HKBxX4P8aBI3A==} + + '@typescript-eslint/eslint-plugin@8.72.2': + resolution: {integrity: sha512-222PKFXKihmFpi/pS5njoBgdAqsPhj2/GBmFbrNw8Tq8gEG9Sv+kSlKFy4u2q+mJv9ZzJgM2Gkv/bUzRZwZw5g==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + '@typescript-eslint/parser': ^8.72.2 + eslint: ^8.57.0 || ^9.0.0 || ^10.0.0 + typescript: '>=4.8.4 <6.1.0' + + '@typescript-eslint/parser@8.72.2': + resolution: {integrity: sha512-llP+T1YuJOLlxEciP6OyQGtz5SMxyn+9LA2BvZw5RmToGVa1y4beEDVQL6Gje7T5WFYh19WREjDCN9Ev4gm5AA==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + eslint: ^8.57.0 || ^9.0.0 || ^10.0.0 + typescript: '>=4.8.4 <6.1.0' + + '@typescript-eslint/project-service@8.72.2': + resolution: {integrity: sha512-6y5dLTZdHhI8Eh3yIQ/bfQhRKwn5e+TpJj64o18Cngc0iW/BCrVvrr6zGYqXPnYH31u6YXAYiFh0+qxX5mybJw==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + typescript: '>=4.8.4 <6.1.0' + + '@typescript-eslint/scope-manager@8.72.2': + resolution: {integrity: sha512-iIoMJ6/8c1/QpFNyFjU0d1YzPco4MsZjQw0k3V+vfzNWAFmUmvhlyMoYEoYYDQZXc+J6Gi1X5XcxlzW2taIIGQ==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + + '@typescript-eslint/tsconfig-utils@8.72.2': + resolution: {integrity: sha512-+h3iCgZXuTNtoLXcnnjP12ZUHLMqoUcIHPfQrFEXTUqvb9dF8QK9b5nv5VtSo5fLkdHuks8ehbTzZj3rImAm9w==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + typescript: '>=4.8.4 <6.1.0' + + '@typescript-eslint/type-utils@8.72.2': + resolution: {integrity: sha512-STfkR38qIdhfkLpgtXnUjAzsNy4xouqiBO0lrVc/Wpk9Kem5/aHXUx1J8dGC16zpdYN1+yc2ILQ28er1kXX7ag==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + eslint: ^8.57.0 || ^9.0.0 || ^10.0.0 + typescript: '>=4.8.4 <6.1.0' + + '@typescript-eslint/types@8.72.2': + resolution: {integrity: sha512-Xfn37OLZx03+PCU7qWx9DTv2FCRh1E6fk2+wONeNY15HXIwtcwuveaSwVpGAUptkNmPQegRxW5JyRel9T7wrog==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + + '@typescript-eslint/typescript-estree@8.72.2': + resolution: {integrity: sha512-pQEGqIK/cqEvKivVWaFLYpe7XYejFxfuAOi4mu1oAWFvIo36aRHI9esRFTUxcIy/z8N482RJyH+LpZB0ZIU7Ow==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + typescript: '>=4.8.4 <6.1.0' + + '@typescript-eslint/utils@8.72.2': + resolution: {integrity: sha512-hv3eRYbpPbbpezuax1EfGrzpa3C4ySgNZkPUkLOWOAjU8HsOKowEDAr8C7nsNl1C+SBSKDpvno6VKHnlhvp9iA==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + eslint: ^8.57.0 || ^9.0.0 || ^10.0.0 + typescript: '>=4.8.4 <6.1.0' + + '@typescript-eslint/visitor-keys@8.72.2': + resolution: {integrity: sha512-NAGrjn0Pitjqzq/GkgMC4kBYm233PQ8GffyQ9+kTA3AlNQYEzOf25EIM02BAHZv5FRJSpHpJk+OGUxVkOB93GQ==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + + '@vitest/mocker@5.1.0': + resolution: {integrity: sha512-5umB9/jlWcqVS6fsrFmv5Gdnpu6wAUio/lEOwAmvB7v+lFo/IW2B9FhAD0p19GCULTgMzLCdUmuCDCnAzWgppQ==} + peerDependencies: + msw: ^2.4.9 || ^3.0.0 + vite: ^6.0.0 || ^7.0.0 || ^8.0.0 + peerDependenciesMeta: + msw: + optional: true + vite: + optional: true + + '@vitest/spy@5.1.0': + resolution: {integrity: sha512-2DPO5OMHWKrBngC+fCmTQqemNF0gidRhp3lxbBmRhW+M1XJrfgPpqNqWVevXtn2f2ufD5ZaR1B6B641aAlcX5A==} + + abstract-logging@2.0.1: + resolution: {integrity: sha512-2BjRTZxTPvheOvGbBslFSYOUkr+SjPtOnrLP33f+VIWLzezQpZcqVg7ja3L4dBXmzzgwT+a029jRx5PCi3JuiA==} + + acorn-jsx@5.3.2: + resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==} + peerDependencies: + acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 + + acorn@8.19.0: + resolution: {integrity: sha512-oJlA3XiRm7Cyk6qFD2Jn8ak9B7jSy0qy00ADO3+8dpT0LSjFihQYv4C02LFCSYJV3Q37xYwwRy5m+IpIiUzqWw==} + engines: {node: '>=0.4.0'} + hasBin: true + + ajv-formats@3.0.1: + resolution: {integrity: sha512-8iUql50EUR+uUcdRQ3HDqa6EVyo3docL8g5WJ3FNcWmu62IbkGUue/pEyLBW8VGKKucTPgqeks4fIU1DA4yowQ==} + peerDependencies: + ajv: ^8.0.0 + peerDependenciesMeta: + ajv: + optional: true + + ajv@6.15.0: + resolution: {integrity: sha512-fgFx7Hfoq60ytK2c7DhnF8jIvzYgOMxfugjLOSMHjLIPgenqa7S7oaagATUq99mV6IYvN2tRmC0wnTYX6iPbMw==} + + ajv@8.20.0: + resolution: {integrity: sha512-Thbli+OlOj+iMPYFBVBfJ3OmCAnaSyNn4M1vz9T6Gka5Jt9ba/HIR56joy65tY6kx/FCF5VXNB819Y7/GUrBGA==} + + assertion-error@2.0.1: + resolution: {integrity: sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA==} + engines: {node: '>=12'} + + atomic-sleep@1.0.0: + resolution: {integrity: sha512-kNOjDqAh7px0XWNI+4QbzoiR/nTkHAWNud2uvnJquD1/x5a7EQZMJT0AczqK0Qn67oY/TTQ1LbUKajZpp3I9tQ==} + engines: {node: '>=8.0.0'} + + avvio@9.3.1: + resolution: {integrity: sha512-QyTKW61/qlba+cUQBm/sT9X8lri4UdomqSDwCnrnj1IvLVDRRiXRkz4CgBRWB+/cmfC7SK5WQc8T1vSdGvaUcQ==} + + balanced-match@4.0.4: + resolution: {integrity: sha512-BLrgEcRTwX2o6gGxGOCNyMvGSp35YofuYzw9h1IMTRmKqttAZZVU67bdb9Pr2vUHA8+j3i2tJfjO6C6+4myGTA==} + engines: {node: 18 || 20 || >=22} + + brace-expansion@5.0.13: + resolution: {integrity: sha512-Vh3dmFbc4wZeox7M9I/0L9GfFd83Su4+yCck/OF9Gi/P/dAHn0RT7X4K9R7gMNMhDck3DvhR6QXsnQdjjgwNvQ==} + engines: {node: 20 || >=22} + + cacheable@2.5.0: + resolution: {integrity: sha512-60cyAOytib/OzBw1JNSoSV/boK1AtHryDIjvVBk7XbN4ugfkM3+Sry7fEjNgPMGgOjuaZPAp8ruZ0Cxafwyq9g==} + + chai@6.3.0: + resolution: {integrity: sha512-XWAtwJ6OHO+tj0EKCs0Y2UamnyOxseZWltU4x2U2wh8g4AigdjwvtUjvLP2tqkA/avxHEtzxNaqGq/YGNwckKg==} + engines: {node: '>=18'} + + cookie@2.0.2: + resolution: {integrity: sha512-SL0cVuEdETEp7pN0FuZb01toc3vnODEfVUCooxG1SJN0yIirh7JMb9X9bvfCFf0vzzbT68RdbKDHYTiWy7a7iw==} + engines: {node: '>=22'} + + cross-spawn@7.0.6: + resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==} + engines: {node: '>= 8'} + + debug@4.4.3: + resolution: {integrity: sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==} + engines: {node: '>=6.0'} + peerDependencies: + supports-color: '*' + peerDependenciesMeta: + supports-color: + optional: true + + deep-is@0.1.4: + resolution: {integrity: sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==} + + dequal@2.0.3: + resolution: {integrity: sha512-0je+qPKHEMohvfRTCEo3CrPG6cAzAYgmzKyxRiYSSDkS6eGJdyVJm7WaYA5ECaAD9wLB2T4EEeymA5aFVcYXCA==} + engines: {node: '>=6'} + + detect-libc@2.1.2: + resolution: {integrity: sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==} + engines: {node: '>=8'} + + es-module-lexer@2.3.2: + resolution: {integrity: sha512-poHGpORABojJJucnV9KbOavETW8lBVnphkW77ER5/BQ5Fz7oXSoCNek7IH3vR5nRjdsEz926ibFYX8KtLQmdyw==} + + esbuild@0.28.2: + resolution: {integrity: sha512-HKVLS8dvII+xoKW9kmqxbRKrnWEXfJJr/FZhhJmiqIB0e053QNYFqOBouTMO/k5sID4MvCiUCvv8b9M4h32wIA==} + engines: {node: '>=18'} + hasBin: true + + escape-string-regexp@4.0.0: + resolution: {integrity: sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==} + engines: {node: '>=10'} + + eslint-scope@9.1.2: + resolution: {integrity: sha512-xS90H51cKw0jltxmvmHy2Iai1LIqrfbw57b79w/J7MfvDfkIkFZ+kj6zC3BjtUwh150HsSSdxXZcsuv72miDFQ==} + engines: {node: ^20.19.0 || ^22.13.0 || >=24} + + eslint-visitor-keys@3.4.3: + resolution: {integrity: sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + + eslint-visitor-keys@5.0.1: + resolution: {integrity: sha512-tD40eHxA35h0PEIZNeIjkHoDR4YjjJp34biM0mDvplBe//mB+IHCqHDGV7pxF+7MklTvighcCPPZC7ynWyjdTA==} + engines: {node: ^20.19.0 || ^22.13.0 || >=24} + + eslint@10.15.0: + resolution: {integrity: sha512-+5Wg4p+ze3sG1WErYgUO/3H1IQIfFBymVUA0Fo/XTeBOLS6UQIUekpSJ8sdRkn7O7wjh84b55w/roqavH2aScg==} + engines: {node: ^20.19.0 || ^22.13.0 || >=24} + hasBin: true + peerDependencies: + jiti: '*' + peerDependenciesMeta: + jiti: + optional: true + + espree@11.2.0: + resolution: {integrity: sha512-7p3DrVEIopW1B1avAGLuCSh1jubc01H2JHc8B4qqGblmg5gI9yumBgACjWo4JlIc04ufug4xJ3SQI8HkS/Rgzw==} + engines: {node: ^20.19.0 || ^22.13.0 || >=24} + + esquery@1.7.0: + resolution: {integrity: sha512-Ap6G0WQwcU/LHsvLwON1fAQX9Zp0A2Y6Y/cJBl9r/JbW90Zyg4/zbG6zzKa2OTALELarYHmKu0GhpM5EO+7T0g==} + engines: {node: '>=0.10'} + + esrecurse@4.3.0: + resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==} + engines: {node: '>=4.0'} + + estraverse@5.3.0: + resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==} + engines: {node: '>=4.0'} + + estree-walker@3.0.3: + resolution: {integrity: sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==} + + esutils@2.0.3: + resolution: {integrity: sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==} + engines: {node: '>=0.10.0'} + + expect-type@1.4.0: + resolution: {integrity: sha512-KfYbmpRm0VbLjEvVa9yGwCi9GI34xvi7A/HXYWQO65CSD2u3MczUJSuwXKFIxlGsgBQizV9q5J9NHj4VG0n+pA==} + engines: {node: '>=12.0.0'} + + fast-decode-uri-component@1.0.1: + resolution: {integrity: sha512-WKgKWg5eUxvRZGwW8FvfbaH7AXSh2cL+3j5fMGzUMCxWBJ3dV3a7Wz8y2f/uQ0e3B6WmodD3oS54jTQ9HVTIIg==} + + fast-deep-equal@3.1.3: + resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} + + fast-json-stable-stringify@2.1.0: + resolution: {integrity: sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==} + + fast-json-stringify@7.3.5: + resolution: {integrity: sha512-g7H3xqJmdH9aWLWh8S3CqrRZFZ321yaeNHZp3QUDl3wtXDWjPChDXCDDTwA4M/zsU42nOhE+z5KmpCzgBaaCgw==} + + fast-levenshtein@2.0.6: + resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==} + + fast-querystring@1.1.2: + resolution: {integrity: sha512-g6KuKWmFXc0fID8WWH0jit4g0AGBoJhCkJMb1RmbsSEUNvQ+ZC8D6CUZ+GtF8nMzSPXnhiePyyqqipzNNEnHjg==} + + fast-uri@3.1.9: + resolution: {integrity: sha512-hS/0Wt3Ya043oKXs0sIxrMpKQITXhMLIrVAKKXi4gozGC9v7YRWVnXIZzjNPTO02M9BdxLCWqK1yRXgNziVyJQ==} + + fast-uri@4.2.3: + resolution: {integrity: sha512-I1PXwP5eAhlNlcdpjt9CgB59op2ZvZfxw+BkqGFVIUOgNpCVTcTqp3HhTX7brxj5vsip+nSY4nTvff+eIA76hg==} + + fastify@5.12.8: + resolution: {integrity: sha512-moP8exb2sCHLUbJkwp+I6C0padhy4D8lp0SdmzY7HhSdZuqm7O/u3o2aq7u8okaQ//33QDzj3G/u+FsSdB8Qzw==} + + fastq@1.20.3: + resolution: {integrity: sha512-XKv5nnLs6nLF71NgiKJLIZFLkPyIEuOselLG7ujZnGrRfQK8HpvY+WqKhAJUAdLomwVHErVS4LfxFlPq0/FTAw==} + + fdir@6.5.0: + resolution: {integrity: sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==} + engines: {node: '>=12.0.0'} + peerDependencies: + picomatch: ^3 || ^4 + peerDependenciesMeta: + picomatch: + optional: true + + file-entry-cache@11.1.5: + resolution: {integrity: sha512-+PFTHITI08JIGhnNpGNI8T8inUpgZfk3GNEqfT9R2zZV2iFXg3CvqzSl/uEhs7TSGujYRELEANyDvS8Fj7+S7Q==} + + find-my-way@9.10.0: + resolution: {integrity: sha512-eru+uCPQ2g+nLBkf84MHP/KyNNMar0BDy0j+i8Fb72GF9/YHBZ58q7FODUtfVV7XU9nfRUHXSmaM8NmZcIbZ4Q==} + engines: {node: '>=20'} + + find-up@5.0.0: + resolution: {integrity: sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==} + engines: {node: '>=10'} + + flat-cache@6.1.23: + resolution: {integrity: sha512-f++BY9pTk+983xK1FLzlLpmM0i0z+jHmx3QESGkURMXujQZz1k5wzwX6hjnQ8goaD0B+sYnDK1yZ6MTyZfUaqA==} + + flatted@3.4.4: + resolution: {integrity: sha512-5+ybhBZANEJxaH3X5evAFatUxLfEHSr7n6kYJ+1Qd0mUqr4eu9gIf6GDbWHf8RJijHrjjO8G+la14SlL2SeS1Q==} + + fsevents@2.3.3: + resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} + engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} + os: [darwin] + + glob-parent@6.0.2: + resolution: {integrity: sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==} + engines: {node: '>=10.13.0'} + + hashery@1.5.1: + resolution: {integrity: sha512-iZyKG96/JwPz1N55vj2Ie2vXbhu440zfUfJvSwEqEbeLluk7NnapfGqa7LH0mOsnDxTF85Mx8/dyR6HfqcbmbQ==} + engines: {node: '>=20'} + + hookified@1.15.1: + resolution: {integrity: sha512-MvG/clsADq1GPM2KGo2nyfaWVyn9naPiXrqIe4jYjXNZQt238kWyOGrsyc/DmRAQ+Re6yeo6yX/yoNCG5KAEVg==} + + hookified@2.2.0: + resolution: {integrity: sha512-p/LgFzRN5FeoD3DLS6bkUapeye6E4SI6yJs6KetENd18S+FBthqYq2amJUWpt5z0EQwwHemidjY5OqJGEKm5uA==} + + ignore@5.3.2: + resolution: {integrity: sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==} + engines: {node: '>= 4'} + + ignore@7.0.14: + resolution: {integrity: sha512-wCBiZ77u1tuWde6G/nfOtLaCTYcFDU5yCzARzK10y+rLhzYoL7a7yEemcopcc2Mzow7gZOIjnV2ym1NYmdiJOQ==} + engines: {node: '>= 4'} + + imurmurhash@0.1.4: + resolution: {integrity: sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==} + engines: {node: '>=0.8.19'} + + ipaddr.js@2.5.0: + resolution: {integrity: sha512-aq+t5NAc+cS6rZQQVWC2x98CPqGtKKTMDd4Gaodv0wShnItdKg/51djkGJ1hqH+Oy0ivDftCbSLCQob8zso01w==} + engines: {node: '>= 10'} + + is-extglob@2.1.1: + resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} + engines: {node: '>=0.10.0'} + + is-glob@4.0.3: + resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==} + engines: {node: '>=0.10.0'} + + isexe@2.0.0: + resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==} + + json-schema-ref-resolver@3.0.1: + resolution: {integrity: sha512-w+HwgljXpVwZ3IidoUR1qPZxSOQ+NRQWuVe6a5pe8XbHsNZE4UAwVPUvzZagn7yBKbJtt6UJnRFYbNTRPZI45Q==} + + json-schema-traverse@0.4.1: + resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==} + + json-schema-traverse@1.0.0: + resolution: {integrity: sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==} + + json-stable-stringify-without-jsonify@1.0.1: + resolution: {integrity: sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==} + + keyv@5.6.0: + resolution: {integrity: sha512-CYDD3SOtsHtyXeEORYRx2qBtpDJFjRTGXUtmNEMGyzYOKj1TE3tycdlho7kA1Ufx9OYWZzg52QFBGALTirzDSw==} + + levn@0.4.1: + resolution: {integrity: sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==} + engines: {node: '>= 0.8.0'} + + light-my-request@6.8.0: + resolution: {integrity: sha512-5Q8PjoSEdtGIB8fikZsTem5vgRo4F2mR6vUKTDW/H1g6MtAt8e3duQbg/QxL5yzg6BZhor2KOUm3hhWMWLTZwg==} + + lightningcss-android-arm64@1.33.0: + resolution: {integrity: sha512-gEpRTalKdosp4Bb8qWtc2iOgE5SeIHlpS1up9bFq2wAyYhl1UdTObYiHe98zEM9SQvSoqQZ1IQD0JNpg3Ml5pg==} + engines: {node: '>= 12.0.0'} + cpu: [arm64] + os: [android] + + lightningcss-darwin-arm64@1.33.0: + resolution: {integrity: sha512-Sciaz8eenNTKn9b3t7+xr0ipTp9YxKQY4npwQ3mrRuL0BAVHBLyZxofhaKBAVtzmtRZ/zTyo0/to4B1uWG/Djg==} + engines: {node: '>= 12.0.0'} + cpu: [arm64] + os: [darwin] + + lightningcss-darwin-x64@1.33.0: + resolution: {integrity: sha512-Z5UPAxzrjlWNNyGy6i65cJzzvgJ5D3T6wMvs+gWpY9d7qRhANrxqAp6LhxIgZhWEw18RfJTGcRxjuLIBr+m8XQ==} + engines: {node: '>= 12.0.0'} + cpu: [x64] + os: [darwin] + + lightningcss-freebsd-x64@1.33.0: + resolution: {integrity: sha512-QQM/Ti/hQajJwCY+RiWuCZ9sdtI/XQk7nDK5vC8kkdwixezOlDgvDx7+RT+QjK6FcFT4MpsuoBnHIo/O3StRRg==} + engines: {node: '>= 12.0.0'} + cpu: [x64] + os: [freebsd] + + lightningcss-linux-arm-gnueabihf@1.33.0: + resolution: {integrity: sha512-N7FVBe6iS24MlM6R/4RBTxGhQheZGs7tiQ9U32UtF75NzP5Q7xWPRqLBCKxlRQRk3rY1jCIPLzx7WzOhuUIRLQ==} + engines: {node: '>= 12.0.0'} + cpu: [arm] + os: [linux] + + lightningcss-linux-arm64-gnu@1.33.0: + resolution: {integrity: sha512-j2v/itmy4HlNxlc6voKXYgBqNi0Ng2LShg4z7GufpEgs05P+2suBVyi9I6YHq5uoVFx9ETin3eCEhLVyXGQnKg==} + engines: {node: '>= 12.0.0'} + cpu: [arm64] + os: [linux] + libc: [glibc] + + lightningcss-linux-arm64-musl@1.33.0: + resolution: {integrity: sha512-yiO5ROMuYQgXbC60yjZU5CYSFZGKXL0HFATXt9mHJn1+zW55oCtMI9NfcVhYLMFDL7gV7oBPon/EmMMGg2OvtQ==} + engines: {node: '>= 12.0.0'} + cpu: [arm64] + os: [linux] + libc: [musl] + + lightningcss-linux-x64-gnu@1.33.0: + resolution: {integrity: sha512-ar+Ju7LmcN0Jo4FpL4hpFybwNG9/3A/Br5KW2n2jyODg3MEZXaDYADdemoNS+BDNfMgKvylJLj4S5tyRActuAg==} + engines: {node: '>= 12.0.0'} + cpu: [x64] + os: [linux] + libc: [glibc] + + lightningcss-linux-x64-musl@1.33.0: + resolution: {integrity: sha512-RYiYbkokw0trfKqqzfF55lginwEPrD3OJDfTuJzFs1MK6iFnDenaz1fqLLtX4ITG3OktJQXOeTaw1awrBAlZPw==} + engines: {node: '>= 12.0.0'} + cpu: [x64] + os: [linux] + libc: [musl] + + lightningcss-win32-arm64-msvc@1.33.0: + resolution: {integrity: sha512-1K+MPfLSFVpphzpdbfkhlWk6wBrTObBzS2T6db10PNOZgR9GoVsAWzwNyuhUYYbTp23j+4RrncfujZ4uAzXvwA==} + engines: {node: '>= 12.0.0'} + cpu: [arm64] + os: [win32] + + lightningcss-win32-x64-msvc@1.33.0: + resolution: {integrity: sha512-OlEICDx/Xl0FqSp4bry8zFnCvGpig3Gl4gCquvYwHuqJKEC1+n9NgDniFvqHGmMv1ZkqDJrDqKKSykTDX+ehuA==} + engines: {node: '>= 12.0.0'} + cpu: [x64] + os: [win32] + + lightningcss@1.33.0: + resolution: {integrity: sha512-WkUDrojuJs0xkgGf2udWxa3yGBRxPtxUkB79i6aCZLRgc7PM8fZe9TosfPDcvEpQZbuFASnHYmRLBLUbmLOIIA==} + engines: {node: '>= 12.0.0'} + + locate-path@6.0.0: + resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==} + engines: {node: '>=10'} + + magic-string@1.4.5: + resolution: {integrity: sha512-oLLC2+YvQUfAa+vxoufE/yc1icb87M9iXIRqAoR/2EhE/8cb3SF/+Gi0c2By1B+5Vz2e2vQtUvHiu1+63Znh+w==} + + minimatch@10.2.6: + resolution: {integrity: sha512-vpLQEs+VLCr1nU0BXS07maYoFwlDAH0gngQuuttxIwutDFEMHq2blX+8vpgxDdK3J1PwjCJiep77OitTZ4Ll1A==} + engines: {node: 18 || 20 || >=22} + + minimatch@11.0.8: + resolution: {integrity: sha512-nFQuYSTVrGvysVBps5Ih+0BdnYFN/Cj3C816r6+p7yK+FHrVLGE4O4N9AFwykrlNlvM2HYt+Rad1Uiro6h88Ig==} + engines: {node: 20 || >=22} + + ms@2.1.3: + resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} + + nanoid@3.3.20: + resolution: {integrity: sha512-uKdg2G3GNCKQn9byYOpxbGqrT2fGO5KRt5J/8b3pok8rT6qxGWF6hxMyJiEYtAf+FVyYuD9hRaDqX5uPFYJ4ZQ==} + engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} + hasBin: true + + natural-compare@1.4.0: + resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==} + + obug@3.0.0: + resolution: {integrity: sha512-5vvB5+W7ePv+p3uqxi+RcW1XAzLW0/hxt3/4X4Lc4qHudzOhmBiBwOY6DRob4WnanAEGvNcLjF+KNOufrUoEQw==} + engines: {node: '>=12.20.0'} + + on-exit-leak-free@2.1.2: + resolution: {integrity: sha512-0eJJY6hXLGf1udHwfNftBqH+g73EU4B504nZeKpz1sYRKafAghwxEJunB2O7rDZkL4PGfsMVnTXZ2EjibbqcsA==} + engines: {node: '>=14.0.0'} + + optionator@0.9.4: + resolution: {integrity: sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==} + engines: {node: '>= 0.8.0'} + + p-limit@3.1.0: + resolution: {integrity: sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==} + engines: {node: '>=10'} + + p-locate@5.0.0: + resolution: {integrity: sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==} + engines: {node: '>=10'} + + path-exists@4.0.0: + resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} + engines: {node: '>=8'} + + path-key@3.1.1: + resolution: {integrity: sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==} + engines: {node: '>=8'} + + pg-cloudflare@1.4.1: + resolution: {integrity: sha512-6PQbsFWZcp9EmJEwy5cGQ2La+AMWpP46lgbb8X+U/XsHIUweYDNCpeuKck5RxL2MdVFi7krbbEi5nX4Zh7JhrQ==} + + pg-connection-string@2.14.1: + resolution: {integrity: sha512-qR3kGNPBLpCNtz0evbKA0Y/MRFXwSSdT+pTJvYp/bXTcReZbvX1kzF0IyTc1QnxqF7AZbOeBhNL8R5mYQZV/MA==} + + pg-int8@1.0.1: + resolution: {integrity: sha512-WCtabS6t3c8SkpDBUlb1kjOs7l66xsGdKpIPZsg4wR+B3+u9UAum2odSsF9tnvxg80h4ZxLWMy4pRjOsFIqQpw==} + engines: {node: '>=4.0.0'} + + pg-pool@3.14.0: + resolution: {integrity: sha512-gKtPkFdQPU3DksooVLi9LsjZxrsBUZIpa+7aVx+LV5pNh0KzP4Zleud2po+ConrxbuXGBJ6Hfer6hdgpIBpBaw==} + peerDependencies: + pg: '>=8.0' + + pg-protocol@1.16.1: + resolution: {integrity: sha512-p9VOFMiHB/ZbJATetbg+99PxssTVSQRnyuPSQ67mN1+1KBOjZaZ83ZQzltnxPhJwSsC3nwVjJ10DVJlerbFzLg==} + + pg-types@2.2.0: + resolution: {integrity: sha512-qTAAlrEsl8s4OiEQY69wDvcMIdQN6wdz5ojQiOy6YRMuynxenON0O5oCpJI6lshc6scgAY8qvJ2On/p+CXY0GA==} + engines: {node: '>=4'} + + pg@8.23.1: + resolution: {integrity: sha512-aL96AHANtWjPLDOLqnhx+ngp9+UK7ETEU8VJrDCGvsSSi/mGLcWYsS6Herg7lmaBJe4uwrfqsa7gTEFaSizDoQ==} + engines: {node: '>= 16.0.0'} + peerDependencies: + pg-native: '>=3.0.1' + peerDependenciesMeta: + pg-native: + optional: true + + pgpass@1.0.5: + resolution: {integrity: sha512-FdW9r/jQZhSeohs1Z3sI1yxFQNFvMcnmfuj4WBMUTxOrAyLMaTcE1aAMBiTlbMNaXvBCQuVi0R7hd8udDSP7ug==} + + picocolors@1.1.1: + resolution: {integrity: sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==} + + picomatch@4.0.7: + resolution: {integrity: sha512-qcJu88Q2IWqJsDD529JKMdwGm/dvInW4HvQnRwiH9JtihJvzGOscDtHE3x1pBKeUOTysQ8kVmLnJ2kJu7yhcGA==} + engines: {node: '>=12'} + + pino-abstract-transport@3.0.0: + resolution: {integrity: sha512-wlfUczU+n7Hy/Ha5j9a/gZNy7We5+cXp8YL+X+PG8S0KXxw7n/JXA3c46Y0zQznIJ83URJiwy7Lh56WLokNuxg==} + + pino-std-serializers@7.1.0: + resolution: {integrity: sha512-BndPH67/JxGExRgiX1dX0w1FvZck5Wa4aal9198SrRhZjH3GxKQUKIBnYJTdj2HDN3UQAS06HlfcSbQj2OHmaw==} + + pino@10.4.0: + resolution: {integrity: sha512-bk1ZMTwG/Vymx+zPoa28MhNzucFvXJWp3csrSuxuHPSMeUettaCoQ5Jvg07mtC4JGNpcfTwz41oVCnNgBK9+vA==} + hasBin: true + + postcss@8.5.33: + resolution: {integrity: sha512-RVHEU9/Pp1Fnjr/MpAJsZoADukCKhfIi15OunEYiGktIkYLkPVvC1sioWolGDS7XByMTx9m/IGbro0Js13zhnQ==} + engines: {node: ^10 || ^12 || >=14} + + postgres-array@2.0.0: + resolution: {integrity: sha512-VpZrUqU5A69eQyW2c5CA1jtLecCsN2U/bD6VilrFDWq5+5UIEVO7nazS3TEcHf1zuPYO/sqGvUvW62g86RXZuA==} + engines: {node: '>=4'} + + postgres-bytea@1.0.1: + resolution: {integrity: sha512-5+5HqXnsZPE65IJZSMkZtURARZelel2oXUEO8rH83VS/hxH5vv1uHquPg5wZs8yMAfdv971IU+kcPUczi7NVBQ==} + engines: {node: '>=0.10.0'} + + postgres-date@1.0.7: + resolution: {integrity: sha512-suDmjLVQg78nMK2UZ454hAG+OAW+HQPZ6n++TNDUX+L0+uUlLywnoxJKDou51Zm+zTCjrCl0Nq6J9C5hP9vK/Q==} + engines: {node: '>=0.10.0'} + + postgres-interval@1.2.0: + resolution: {integrity: sha512-9ZhXKM/rw350N1ovuWHbGxnGh/SNJ4cnxHiM0rxE4VN41wsg8P8zWn9hv/buK00RP4WvlOyr/RBDiptyxVbkZQ==} + engines: {node: '>=0.10.0'} + + prelude-ls@1.2.1: + resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} + engines: {node: '>= 0.8.0'} + + process-warning@5.1.1: + resolution: {integrity: sha512-oCkNVj4OKnKEcocVBcDfiIugN1/cE6rgfT3nCtzeqZPA8+rIxMaQ0xXzIkGP8Gj2qUaP1UR7uhJ1VD8lUCpzCg==} + + punycode@2.3.1: + resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==} + engines: {node: '>=6'} + + qified@0.10.1: + resolution: {integrity: sha512-+Owyggi9IxT1ePKGafcI87ubSmxol6smwJ+RAHDQlx9+9cPwFWDiKFFCPuWhr9ignlGpZ9vDQLw67N4dcTVFEA==} + engines: {node: '>=20'} + + quick-format-unescaped@4.0.4: + resolution: {integrity: sha512-tYC1Q1hgyRuHgloV/YXs2w15unPVh8qfu/qCTfhTYamaw7fyhumKa2yGpdSo87vY32rIclj+4fWYQXUMs9EHvg==} + + real-require@1.0.0: + resolution: {integrity: sha512-P4nbQYQfePJxRSmY+v/KINxVucm4NF3p3s7pJveMTtom52FR4YGltUQLB8idDXwDDWW+eYrWDFbuzUnjoWHF7g==} + + require-from-string@2.0.2: + resolution: {integrity: sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==} + engines: {node: '>=0.10.0'} + + ret@0.5.1: + resolution: {integrity: sha512-Z/nyvABwcRnRD2mMP7Kz6G1dFZZqX1mNErOnxF42OCQKE07b9k9hK9SQxHL3LFEZUdzQaLM4dId1E/E6Vm4WhA==} + engines: {node: '>=10'} + + reusify@1.1.0: + resolution: {integrity: sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==} + engines: {iojs: '>=1.0.0', node: '>=0.10.0'} + + rfdc@1.4.1: + resolution: {integrity: sha512-q1b3N5QkRUWUl7iyylaaj3kOpIT0N2i9MqIEQXP73GVsN9cw3fdx8X63cEmWhJGi2PPCF23Ijp7ktmd39rawIA==} + + rolldown@1.2.19: + resolution: {integrity: sha512-QIiV1J9d0pzN4jeeTH4sjPy0AZ6cAy2cG0ExeoE1+U8Rvj+hR3gYkokx0YbeUNGlZqiQJJ2utcETe0oKXwzsuA==} + engines: {node: ^20.19.0 || >=22.12.0} + hasBin: true + + safe-regex2@5.1.2: + resolution: {integrity: sha512-tAtCGFPPP02VroDVzp4daGi6bC7jWG+41D47GKf18FeH/ubvKQHT9VmhAkvtjNOmJwqtApzWeUpEhkyEYULvmw==} + hasBin: true + + safe-stable-stringify@2.5.0: + resolution: {integrity: sha512-b3rppTKm9T+PsVCBEOUR46GWI7fdOs00VKZ1+9c1EWDaDMvjQc6tUwuFyIprgGgTcWoVHSKrU8H31ZHA2e0RHA==} + engines: {node: '>=10'} + + secure-json-parse@4.1.1: + resolution: {integrity: sha512-lnd81MQEZKjhW/Gd2TQqdd4XP6QYNdDW/EP+I7nTrFHP9y2LmaGPIHk9xsnzcOiEr1c39c/e84xFgGviQKBTRw==} + + semver@7.8.6: + resolution: {integrity: sha512-9lpSSU4Mly3mrtruwLs1eLK6+gzbzqeBFwRNjIjE+9LuDpWdYctrQlQ3ej1Ilgi7gknpsTRnPoLP8DpCHqHIJw==} + engines: {node: '>=10'} + hasBin: true + + set-cookie-parser@3.2.2: + resolution: {integrity: sha512-df017qMeYuXo4emL09nlyMpi2i2MtEIKS/6jtXH3vmjFgIRsOi852/5RmhJ4EkvN3ZF8jXadM/EkTPXgc8yPIw==} + + shebang-command@2.0.0: + resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} + engines: {node: '>=8'} + + shebang-regex@3.0.0: + resolution: {integrity: sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==} + engines: {node: '>=8'} + + sonic-boom@4.2.1: + resolution: {integrity: sha512-w6AxtubXa2wTXAUsZMMWERrsIRAdrK0Sc+FUytWvYAhBJLyuI4llrMIC1DtlNSdI99EI86KZum2MMq3EAZlF9Q==} + + source-map-js@1.2.2: + resolution: {integrity: sha512-KGj/8Y43x35aZVDtt+J4mK1hoLGHULMYfSkODJNQjNDC3oW1PqPoxMwo0pLUsWM/UEGzON/NxeHywEfNXNP3Vw==} + engines: {node: '>=0.10.0'} + + split2@4.2.0: + resolution: {integrity: sha512-UcjcJOWknrNkF6PLX83qcHM6KHgVKNkV62Y8a5uYDVv9ydGQVwAHMKqHdJje1VTWpljG0WYpCDhrCdAOYH4TWg==} + engines: {node: '>= 10.x'} + + std-env@4.3.0: + resolution: {integrity: sha512-OtU/EgQ1kIm5KwqQpBC6ZEMXrZRui11w8zgfTWp8cdO9B8OaPsbA8bTHO2P+HNo1VlUTGMVBwPhydu6poeXiag==} + + thread-stream@4.2.1: + resolution: {integrity: sha512-Stg6edJXC/6/xqGwSXwFokrUhChJ18amEjpKH89WrQQ0oVFDF+pUUcTpiwWhFUrE89Vf16FBOlwhaw+lescxMQ==} + engines: {node: '>=20'} + + tinybench@6.2.3: + resolution: {integrity: sha512-Al01C2JIBnO2CXCAPbpAl6sUiOZHeThGtHYNTa51JRw9PyWOCdr+9Ong05R4qg/Sk3+H645E8ov1h2c58ityNw==} + engines: {node: '>=20.0.0'} + + tinyexec@1.3.1: + resolution: {integrity: sha512-GCvB3aoys96IuDFBMcTB46JOR6mdMtAToqwiW8JlWhsoh1mhHi/xn9ss/Dg7N555GiJyEt2qzoG/NHCwM6h1EA==} + engines: {node: '>=18'} + + tinyglobby@0.2.17: + resolution: {integrity: sha512-wXR/dYpcqKmfWpEdZjiKJOwCNFndD0DMnrW/cYjVGttEkBfVgcLFHoNrlj47mjOVic9yyNu65alsgF4NQyTa2g==} + engines: {node: '>=12.0.0'} + + toad-cache@3.7.4: + resolution: {integrity: sha512-m1TdR/rvT7kgGJZhspNtXdsdYk0fddFpJJFlG5s+UkPFo6lkLoZ3YLOaovPYjq1R75NP5JfeTlSHaOsE09peCg==} + engines: {node: '>=20'} + + ts-api-utils@2.5.0: + resolution: {integrity: sha512-OJ/ibxhPlqrMM0UiNHJ/0CKQkoKF243/AEmplt3qpRgkW8VG7IfOS41h7V8TjITqdByHzrjcS/2si+y4lIh8NA==} + engines: {node: '>=18.12'} + peerDependencies: + typescript: '>=4.8.4' + + tslib@2.9.1: + resolution: {integrity: sha512-a4Ux9VKuIMHsOS7ENbEq6hK2ZGYIT27Rtl0E4eD9KqwxhKiQeMZE/9xb3IdYwWaSOyIBQLExhQgXDTYoiCxnWA==} + + tsx@4.23.15: + resolution: {integrity: sha512-Yiex1Ovn8z2xPpOWckIiysV1SSyRMY9BkLF++q0yKiDxCqRhosKfMg3janKkiLBwZ5c/YryloKwGZcrEmtwxKw==} + engines: {node: '>=18.0.0'} + hasBin: true + + type-check@0.4.0: + resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} + engines: {node: '>= 0.8.0'} + + typescript-eslint@8.72.2: + resolution: {integrity: sha512-c/+AKMW1KB81r28Sp0AAdcyXj5dzNmAsZFcsrxKbZTKmcBK2xIwBR31dcSYSDu3bKmzXe8GKrSxO+eDQ401Uzg==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + eslint: ^8.57.0 || ^9.0.0 || ^10.0.0 + typescript: '>=4.8.4 <6.1.0' + + typescript@6.0.3: + resolution: {integrity: sha512-y2TvuxSZPDyQakkFRPZHKFm+KKVqIisdg9/CZwm9ftvKXLP8NRWj38/ODjNbr43SsoXqNuAisEf1GdCxqWcdBw==} + engines: {node: '>=14.17'} + hasBin: true + + undici-types@8.9.0: + resolution: {integrity: sha512-KTDyRTYX8sWmKXAikPHHSyc63CRPETMctyjKFupcC6OBLXT3xsN0e9aF7m+mIXutFWpUXuedtowG7iLOzp0kQg==} + + uri-js@4.4.1: + resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==} + + vite@8.3.8: + resolution: {integrity: sha512-LzOn3h9rG/0vhLdXrV4yJ4QFA9eEoqCl+Yx+kGJd7aB9w6nfNgVHKSYwLPZUHrz4ZGa+t+kXjV9itvcHDLQouA==} + engines: {node: ^20.19.0 || >=22.12.0} + hasBin: true + peerDependencies: + '@types/node': ^20.19.0 || >=22.12.0 + '@vitejs/devtools': ^0.7.1 || ^0.8.0 + esbuild: ^0.27.0 || ^0.28.0 + jiti: '>=1.21.0' + less: ^4.0.0 + sass: ^1.70.0 + sass-embedded: ^1.70.0 + stylus: '>=0.54.8' + sugarss: ^5.0.0 + terser: ^5.16.0 + tsx: ^4.8.1 + yaml: ^2.4.2 + peerDependenciesMeta: + '@types/node': + optional: true + '@vitejs/devtools': + optional: true + esbuild: + optional: true + jiti: + optional: true + less: + optional: true + sass: + optional: true + sass-embedded: + optional: true + stylus: + optional: true + sugarss: + optional: true + terser: + optional: true + tsx: + optional: true + yaml: + optional: true + + vitest@5.1.0: + resolution: {integrity: sha512-MzmNFnrwa8v8lF1bLxw3UJ4EREwVOVb75VqJZmUDRjJ6EluK/x9th7qTbaeDk41WxE1GxWqmTXcdsfobfH5sOA==} + engines: {node: ^22.12.0 || ^24.0.0 || >=26.0.0} + hasBin: true + peerDependencies: + '@edge-runtime/vm': '*' + '@opentelemetry/api': ^1.9.0 + '@types/node': ^22.0.0 || >=24.0.0 + '@vitest/browser-playwright': 5.1.0 + '@vitest/browser-preview': 5.1.0 + '@vitest/browser-webdriverio': ^5.0.0-beta.5 || >=5.0.0 + '@vitest/coverage-istanbul': 5.1.0 + '@vitest/coverage-v8': 5.1.0 + '@vitest/ui': 5.1.0 + happy-dom: '*' + jsdom: '*' + vite: ^6.4.0 || ^7.0.0 || ^8.0.0 + peerDependenciesMeta: + '@edge-runtime/vm': + optional: true + '@opentelemetry/api': + optional: true + '@types/node': + optional: true + '@vitest/browser-playwright': + optional: true + '@vitest/browser-preview': + optional: true + '@vitest/browser-webdriverio': + optional: true + '@vitest/coverage-istanbul': + optional: true + '@vitest/coverage-v8': + optional: true + '@vitest/ui': + optional: true + happy-dom: + optional: true + jsdom: + optional: true + + which@2.0.2: + resolution: {integrity: sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==} + engines: {node: '>= 8'} + hasBin: true + + why-is-node-running@3.2.1: + resolution: {integrity: sha512-Tb2FUhB4vUsGQlfSquQLYkApkuPAFQXGFzxWKHHumVz2dK+X1RUm/HnID4+TfIGYJ1kTcwOaCk/buYCEJr6YjQ==} + engines: {node: '>=20.11'} + hasBin: true + + word-wrap@1.2.5: + resolution: {integrity: sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==} + engines: {node: '>=0.10.0'} + + xtend@4.0.2: + resolution: {integrity: sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==} + engines: {node: '>=0.4'} + + yocto-queue@0.1.0: + resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} + engines: {node: '>=10'} + +snapshots: + + '@cacheable/memory@2.2.0': + dependencies: + '@cacheable/utils': 2.5.0 + '@keyv/bigmap': 1.3.1(keyv@5.6.0) + hookified: 1.15.1 + keyv: 5.6.0 + + '@cacheable/utils@2.5.0': + dependencies: + hashery: 1.5.1 + keyv: 5.6.0 + + '@electric-sql/pglite@0.5.16': {} + + '@emnapi/core@2.0.0-beta.2': + dependencies: + '@emnapi/wasi-threads': 2.2.0 + tslib: 2.9.1 + optional: true + + '@emnapi/runtime@2.0.0-beta.2': + dependencies: + tslib: 2.9.1 + optional: true + + '@emnapi/wasi-threads@2.2.0': + dependencies: + tslib: 2.9.1 + optional: true + + '@esbuild/aix-ppc64@0.28.2': + optional: true + + '@esbuild/android-arm64@0.28.2': + optional: true + + '@esbuild/android-arm@0.28.2': + optional: true + + '@esbuild/android-x64@0.28.2': + optional: true + + '@esbuild/darwin-arm64@0.28.2': + optional: true + + '@esbuild/darwin-x64@0.28.2': + optional: true + + '@esbuild/freebsd-arm64@0.28.2': + optional: true + + '@esbuild/freebsd-x64@0.28.2': + optional: true + + '@esbuild/linux-arm64@0.28.2': + optional: true + + '@esbuild/linux-arm@0.28.2': + optional: true + + '@esbuild/linux-ia32@0.28.2': + optional: true + + '@esbuild/linux-loong64@0.28.2': + optional: true + + '@esbuild/linux-mips64el@0.28.2': + optional: true + + '@esbuild/linux-ppc64@0.28.2': + optional: true + + '@esbuild/linux-riscv64@0.28.2': + optional: true + + '@esbuild/linux-s390x@0.28.2': + optional: true + + '@esbuild/linux-x64@0.28.2': + optional: true + + '@esbuild/netbsd-arm64@0.28.2': + optional: true + + '@esbuild/netbsd-x64@0.28.2': + optional: true + + '@esbuild/openbsd-arm64@0.28.2': + optional: true + + '@esbuild/openbsd-x64@0.28.2': + optional: true + + '@esbuild/openharmony-arm64@0.28.2': + optional: true + + '@esbuild/sunos-x64@0.28.2': + optional: true + + '@esbuild/win32-arm64@0.28.2': + optional: true + + '@esbuild/win32-ia32@0.28.2': + optional: true + + '@esbuild/win32-x64@0.28.2': + optional: true + + '@eslint-community/eslint-utils@4.10.1(eslint@10.15.0)': + dependencies: + eslint: 10.15.0 + eslint-visitor-keys: 3.4.3 + + '@eslint-community/regexpp@4.12.3': {} + + '@eslint/config-array@0.23.6': + dependencies: + '@eslint/object-schema': 3.0.5 + debug: 4.4.3 + minimatch: 11.0.8 + transitivePeerDependencies: + - supports-color + + '@eslint/config-helpers@0.7.0': + dependencies: + '@eslint/core': 1.2.1 + + '@eslint/core@1.2.1': + dependencies: + '@types/json-schema': 7.0.15 + + '@eslint/object-schema@3.0.5': {} + + '@eslint/plugin-kit@0.7.3': + dependencies: + '@eslint/core': 1.2.1 + levn: 0.4.1 + + '@fastify/ajv-compiler@4.0.7': + dependencies: + ajv: 8.20.0 + ajv-formats: 3.0.1 + fast-uri: 4.2.3 + + '@fastify/deepmerge@3.2.4': {} + + '@fastify/error@4.2.1': {} + + '@fastify/fast-json-stringify-compiler@5.2.0': + dependencies: + fast-json-stringify: 7.3.5 + + '@fastify/forwarded@3.1.2': {} + + '@fastify/merge-json-schemas@0.2.2': + dependencies: + dequal: 2.0.3 + + '@fastify/proxy-addr@5.1.2': + dependencies: + '@fastify/forwarded': 3.1.2 + ipaddr.js: 2.5.0 + + '@humanfs/core@0.19.2': + dependencies: + '@humanfs/types': 0.15.0 + + '@humanfs/node@0.16.8': + dependencies: + '@humanfs/core': 0.19.2 + '@humanfs/types': 0.15.0 + '@humanwhocodes/retry': 0.4.3 + + '@humanfs/types@0.15.0': {} + + '@humanwhocodes/module-importer@1.0.1': {} + + '@humanwhocodes/retry@0.4.3': {} + + '@isaacs/nonrecursive-glob-match@1.1.0': {} + + '@jridgewell/resolve-uri@3.1.3': {} + + '@jridgewell/sourcemap-codec@1.6.0': {} + + '@jridgewell/trace-mapping@0.3.31': + dependencies: + '@jridgewell/resolve-uri': 3.1.3 + '@jridgewell/sourcemap-codec': 1.6.0 + + '@keyv/bigmap@1.3.1(keyv@5.6.0)': + dependencies: + hashery: 1.5.1 + hookified: 1.15.1 + keyv: 5.6.0 + + '@keyv/serialize@1.1.1': {} + + '@napi-rs/wasm-runtime@1.2.6(@emnapi/core@2.0.0-beta.2)(@emnapi/runtime@2.0.0-beta.2)': + dependencies: + '@emnapi/core': 2.0.0-beta.2 + '@emnapi/runtime': 2.0.0-beta.2 + '@tybys/wasm-util': 0.10.4 + optional: true + + '@oxc-project/types@0.156.0': {} + + '@pinojs/redact@0.4.0': {} + + '@rolldown/binding-android-arm-eabi@1.2.19': + optional: true + + '@rolldown/binding-android-arm64@1.2.19': + optional: true + + '@rolldown/binding-darwin-arm64@1.2.19': + optional: true + + '@rolldown/binding-darwin-x64@1.2.19': + optional: true + + '@rolldown/binding-freebsd-x64@1.2.19': + optional: true + + '@rolldown/binding-linux-arm-gnueabihf@1.2.19': + optional: true + + '@rolldown/binding-linux-arm64-gnu@1.2.19': + optional: true + + '@rolldown/binding-linux-arm64-musl@1.2.19': + optional: true + + '@rolldown/binding-linux-ppc64-gnu@1.2.19': + optional: true + + '@rolldown/binding-linux-s390x-gnu@1.2.19': + optional: true + + '@rolldown/binding-linux-x64-gnu@1.2.19': + optional: true + + '@rolldown/binding-linux-x64-musl@1.2.19': + optional: true + + '@rolldown/binding-openharmony-arm64@1.2.19': + optional: true + + '@rolldown/binding-wasm32-wasi@1.2.19': + dependencies: + '@emnapi/core': 2.0.0-beta.2 + '@emnapi/runtime': 2.0.0-beta.2 + '@napi-rs/wasm-runtime': 1.2.6(@emnapi/core@2.0.0-beta.2)(@emnapi/runtime@2.0.0-beta.2) + optional: true + + '@rolldown/binding-win32-arm64-msvc@1.2.19': + optional: true + + '@rolldown/binding-win32-x64-msvc@1.2.19': + optional: true + + '@rolldown/pluginutils@1.1.1': {} + + '@tybys/wasm-util@0.10.4': + dependencies: + tslib: 2.9.1 + optional: true + + '@types/chai@5.2.3': + dependencies: + '@types/deep-eql': 4.0.2 + assertion-error: 2.0.1 + + '@types/deep-eql@4.0.2': {} + + '@types/esrecurse@4.3.1': {} + + '@types/estree@1.0.10': {} + + '@types/json-schema@7.0.15': {} + + '@types/node@26.6.6': + dependencies: + undici-types: 8.9.0 + + '@types/pg@8.23.1': + dependencies: + '@types/node': 26.6.6 + pg-protocol: 1.16.1 + pg-types: 2.2.0 + + '@typescript-eslint/eslint-plugin@8.72.2(@typescript-eslint/parser@8.72.2(eslint@10.15.0)(typescript@6.0.3))(eslint@10.15.0)(typescript@6.0.3)': + dependencies: + '@eslint-community/regexpp': 4.12.3 + '@typescript-eslint/parser': 8.72.2(eslint@10.15.0)(typescript@6.0.3) + '@typescript-eslint/scope-manager': 8.72.2 + '@typescript-eslint/type-utils': 8.72.2(eslint@10.15.0)(typescript@6.0.3) + '@typescript-eslint/utils': 8.72.2(eslint@10.15.0)(typescript@6.0.3) + '@typescript-eslint/visitor-keys': 8.72.2 + eslint: 10.15.0 + ignore: 7.0.14 + natural-compare: 1.4.0 + ts-api-utils: 2.5.0(typescript@6.0.3) + typescript: 6.0.3 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/parser@8.72.2(eslint@10.15.0)(typescript@6.0.3)': + dependencies: + '@typescript-eslint/scope-manager': 8.72.2 + '@typescript-eslint/types': 8.72.2 + '@typescript-eslint/typescript-estree': 8.72.2(typescript@6.0.3) + '@typescript-eslint/visitor-keys': 8.72.2 + debug: 4.4.3 + eslint: 10.15.0 + typescript: 6.0.3 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/project-service@8.72.2(typescript@6.0.3)': + dependencies: + '@typescript-eslint/tsconfig-utils': 8.72.2(typescript@6.0.3) + '@typescript-eslint/types': 8.72.2 + debug: 4.4.3 + typescript: 6.0.3 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/scope-manager@8.72.2': + dependencies: + '@typescript-eslint/types': 8.72.2 + '@typescript-eslint/visitor-keys': 8.72.2 + + '@typescript-eslint/tsconfig-utils@8.72.2(typescript@6.0.3)': + dependencies: + typescript: 6.0.3 + + '@typescript-eslint/type-utils@8.72.2(eslint@10.15.0)(typescript@6.0.3)': + dependencies: + '@typescript-eslint/types': 8.72.2 + '@typescript-eslint/typescript-estree': 8.72.2(typescript@6.0.3) + '@typescript-eslint/utils': 8.72.2(eslint@10.15.0)(typescript@6.0.3) + debug: 4.4.3 + eslint: 10.15.0 + ts-api-utils: 2.5.0(typescript@6.0.3) + typescript: 6.0.3 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/types@8.72.2': {} + + '@typescript-eslint/typescript-estree@8.72.2(typescript@6.0.3)': + dependencies: + '@typescript-eslint/project-service': 8.72.2(typescript@6.0.3) + '@typescript-eslint/tsconfig-utils': 8.72.2(typescript@6.0.3) + '@typescript-eslint/types': 8.72.2 + '@typescript-eslint/visitor-keys': 8.72.2 + debug: 4.4.3 + minimatch: 10.2.6 + semver: 7.8.6 + tinyglobby: 0.2.17 + ts-api-utils: 2.5.0(typescript@6.0.3) + typescript: 6.0.3 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/utils@8.72.2(eslint@10.15.0)(typescript@6.0.3)': + dependencies: + '@eslint-community/eslint-utils': 4.10.1(eslint@10.15.0) + '@typescript-eslint/scope-manager': 8.72.2 + '@typescript-eslint/types': 8.72.2 + '@typescript-eslint/typescript-estree': 8.72.2(typescript@6.0.3) + eslint: 10.15.0 + typescript: 6.0.3 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/visitor-keys@8.72.2': + dependencies: + '@typescript-eslint/types': 8.72.2 + eslint-visitor-keys: 5.0.1 + + '@vitest/mocker@5.1.0(vite@8.3.8(@types/node@26.6.6)(esbuild@0.28.2)(tsx@4.23.15))': + dependencies: + '@jridgewell/trace-mapping': 0.3.31 + '@vitest/spy': 5.1.0 + estree-walker: 3.0.3 + magic-string: 1.4.5 + optionalDependencies: + vite: 8.3.8(@types/node@26.6.6)(esbuild@0.28.2)(tsx@4.23.15) + + '@vitest/spy@5.1.0': {} + + abstract-logging@2.0.1: {} + + acorn-jsx@5.3.2(acorn@8.19.0): + dependencies: + acorn: 8.19.0 + + acorn@8.19.0: {} + + ajv-formats@3.0.1: + dependencies: + ajv: 8.20.0 + + ajv@6.15.0: + dependencies: + fast-deep-equal: 3.1.3 + fast-json-stable-stringify: 2.1.0 + json-schema-traverse: 0.4.1 + uri-js: 4.4.1 + + ajv@8.20.0: + dependencies: + fast-deep-equal: 3.1.3 + fast-uri: 3.1.9 + json-schema-traverse: 1.0.0 + require-from-string: 2.0.2 + + assertion-error@2.0.1: {} + + atomic-sleep@1.0.0: {} + + avvio@9.3.1: + dependencies: + '@fastify/error': 4.2.1 + fastq: 1.20.3 + + balanced-match@4.0.4: {} + + brace-expansion@5.0.13: + dependencies: + balanced-match: 4.0.4 + + cacheable@2.5.0: + dependencies: + '@cacheable/memory': 2.2.0 + '@cacheable/utils': 2.5.0 + hookified: 1.15.1 + keyv: 5.6.0 + qified: 0.10.1 + + chai@6.3.0: {} + + cookie@2.0.2: {} + + cross-spawn@7.0.6: + dependencies: + path-key: 3.1.1 + shebang-command: 2.0.0 + which: 2.0.2 + + debug@4.4.3: + dependencies: + ms: 2.1.3 + + deep-is@0.1.4: {} + + dequal@2.0.3: {} + + detect-libc@2.1.2: {} + + es-module-lexer@2.3.2: {} + + esbuild@0.28.2: + optionalDependencies: + '@esbuild/aix-ppc64': 0.28.2 + '@esbuild/android-arm': 0.28.2 + '@esbuild/android-arm64': 0.28.2 + '@esbuild/android-x64': 0.28.2 + '@esbuild/darwin-arm64': 0.28.2 + '@esbuild/darwin-x64': 0.28.2 + '@esbuild/freebsd-arm64': 0.28.2 + '@esbuild/freebsd-x64': 0.28.2 + '@esbuild/linux-arm': 0.28.2 + '@esbuild/linux-arm64': 0.28.2 + '@esbuild/linux-ia32': 0.28.2 + '@esbuild/linux-loong64': 0.28.2 + '@esbuild/linux-mips64el': 0.28.2 + '@esbuild/linux-ppc64': 0.28.2 + '@esbuild/linux-riscv64': 0.28.2 + '@esbuild/linux-s390x': 0.28.2 + '@esbuild/linux-x64': 0.28.2 + '@esbuild/netbsd-arm64': 0.28.2 + '@esbuild/netbsd-x64': 0.28.2 + '@esbuild/openbsd-arm64': 0.28.2 + '@esbuild/openbsd-x64': 0.28.2 + '@esbuild/openharmony-arm64': 0.28.2 + '@esbuild/sunos-x64': 0.28.2 + '@esbuild/win32-arm64': 0.28.2 + '@esbuild/win32-ia32': 0.28.2 + '@esbuild/win32-x64': 0.28.2 + + escape-string-regexp@4.0.0: {} + + eslint-scope@9.1.2: + dependencies: + '@types/esrecurse': 4.3.1 + '@types/estree': 1.0.10 + esrecurse: 4.3.0 + estraverse: 5.3.0 + + eslint-visitor-keys@3.4.3: {} + + eslint-visitor-keys@5.0.1: {} + + eslint@10.15.0: + dependencies: + '@eslint-community/eslint-utils': 4.10.1(eslint@10.15.0) + '@eslint-community/regexpp': 4.12.3 + '@eslint/config-array': 0.23.6 + '@eslint/config-helpers': 0.7.0 + '@eslint/core': 1.2.1 + '@eslint/plugin-kit': 0.7.3 + '@humanfs/node': 0.16.8 + '@humanwhocodes/module-importer': 1.0.1 + '@humanwhocodes/retry': 0.4.3 + '@types/estree': 1.0.10 + ajv: 6.15.0 + cross-spawn: 7.0.6 + debug: 4.4.3 + escape-string-regexp: 4.0.0 + eslint-scope: 9.1.2 + eslint-visitor-keys: 5.0.1 + espree: 11.2.0 + esquery: 1.7.0 + esutils: 2.0.3 + fast-deep-equal: 3.1.3 + file-entry-cache: 11.1.5 + find-up: 5.0.0 + glob-parent: 6.0.2 + ignore: 5.3.2 + imurmurhash: 0.1.4 + is-glob: 4.0.3 + json-stable-stringify-without-jsonify: 1.0.1 + minimatch: 11.0.8 + natural-compare: 1.4.0 + optionator: 0.9.4 + transitivePeerDependencies: + - supports-color + + espree@11.2.0: + dependencies: + acorn: 8.19.0 + acorn-jsx: 5.3.2(acorn@8.19.0) + eslint-visitor-keys: 5.0.1 + + esquery@1.7.0: + dependencies: + estraverse: 5.3.0 + + esrecurse@4.3.0: + dependencies: + estraverse: 5.3.0 + + estraverse@5.3.0: {} + + estree-walker@3.0.3: + dependencies: + '@types/estree': 1.0.10 + + esutils@2.0.3: {} + + expect-type@1.4.0: {} + + fast-decode-uri-component@1.0.1: {} + + fast-deep-equal@3.1.3: {} + + fast-json-stable-stringify@2.1.0: {} + + fast-json-stringify@7.3.5: + dependencies: + '@fastify/merge-json-schemas': 0.2.2 + ajv: 8.20.0 + ajv-formats: 3.0.1 + fast-uri: 4.2.3 + json-schema-ref-resolver: 3.0.1 + rfdc: 1.4.1 + + fast-levenshtein@2.0.6: {} + + fast-querystring@1.1.2: + dependencies: + fast-decode-uri-component: 1.0.1 + + fast-uri@3.1.9: {} + + fast-uri@4.2.3: {} + + fastify@5.12.8: + dependencies: + '@fastify/ajv-compiler': 4.0.7 + '@fastify/error': 4.2.1 + '@fastify/fast-json-stringify-compiler': 5.2.0 + '@fastify/proxy-addr': 5.1.2 + abstract-logging: 2.0.1 + avvio: 9.3.1 + fast-json-stringify: 7.3.5 + find-my-way: 9.10.0 + light-my-request: 6.8.0 + pino: 10.4.0 + process-warning: 5.1.1 + rfdc: 1.4.1 + secure-json-parse: 4.1.1 + semver: 7.8.6 + toad-cache: 3.7.4 + + fastq@1.20.3: + dependencies: + reusify: 1.1.0 + + fdir@6.5.0(picomatch@4.0.7): + optionalDependencies: + picomatch: 4.0.7 + + file-entry-cache@11.1.5: + dependencies: + flat-cache: 6.1.23 + + find-my-way@9.10.0: + dependencies: + fast-deep-equal: 3.1.3 + fast-querystring: 1.1.2 + safe-regex2: 5.1.2 + + find-up@5.0.0: + dependencies: + locate-path: 6.0.0 + path-exists: 4.0.0 + + flat-cache@6.1.23: + dependencies: + cacheable: 2.5.0 + flatted: 3.4.4 + hookified: 1.15.1 + + flatted@3.4.4: {} + + fsevents@2.3.3: + optional: true + + glob-parent@6.0.2: + dependencies: + is-glob: 4.0.3 + + hashery@1.5.1: + dependencies: + hookified: 1.15.1 + + hookified@1.15.1: {} + + hookified@2.2.0: {} + + ignore@5.3.2: {} + + ignore@7.0.14: {} + + imurmurhash@0.1.4: {} + + ipaddr.js@2.5.0: {} + + is-extglob@2.1.1: {} + + is-glob@4.0.3: + dependencies: + is-extglob: 2.1.1 + + isexe@2.0.0: {} + + json-schema-ref-resolver@3.0.1: + dependencies: + dequal: 2.0.3 + + json-schema-traverse@0.4.1: {} + + json-schema-traverse@1.0.0: {} + + json-stable-stringify-without-jsonify@1.0.1: {} + + keyv@5.6.0: + dependencies: + '@keyv/serialize': 1.1.1 + + levn@0.4.1: + dependencies: + prelude-ls: 1.2.1 + type-check: 0.4.0 + + light-my-request@6.8.0: + dependencies: + '@fastify/deepmerge': 3.2.4 + cookie: 2.0.2 + process-warning: 5.1.1 + set-cookie-parser: 3.2.2 + + lightningcss-android-arm64@1.33.0: + optional: true + + lightningcss-darwin-arm64@1.33.0: + optional: true + + lightningcss-darwin-x64@1.33.0: + optional: true + + lightningcss-freebsd-x64@1.33.0: + optional: true + + lightningcss-linux-arm-gnueabihf@1.33.0: + optional: true + + lightningcss-linux-arm64-gnu@1.33.0: + optional: true + + lightningcss-linux-arm64-musl@1.33.0: + optional: true + + lightningcss-linux-x64-gnu@1.33.0: + optional: true + + lightningcss-linux-x64-musl@1.33.0: + optional: true + + lightningcss-win32-arm64-msvc@1.33.0: + optional: true + + lightningcss-win32-x64-msvc@1.33.0: + optional: true + + lightningcss@1.33.0: + dependencies: + detect-libc: 2.1.2 + optionalDependencies: + lightningcss-android-arm64: 1.33.0 + lightningcss-darwin-arm64: 1.33.0 + lightningcss-darwin-x64: 1.33.0 + lightningcss-freebsd-x64: 1.33.0 + lightningcss-linux-arm-gnueabihf: 1.33.0 + lightningcss-linux-arm64-gnu: 1.33.0 + lightningcss-linux-arm64-musl: 1.33.0 + lightningcss-linux-x64-gnu: 1.33.0 + lightningcss-linux-x64-musl: 1.33.0 + lightningcss-win32-arm64-msvc: 1.33.0 + lightningcss-win32-x64-msvc: 1.33.0 + + locate-path@6.0.0: + dependencies: + p-locate: 5.0.0 + + magic-string@1.4.5: + dependencies: + '@jridgewell/sourcemap-codec': 1.6.0 + + minimatch@10.2.6: + dependencies: + brace-expansion: 5.0.13 + + minimatch@11.0.8: + dependencies: + '@isaacs/nonrecursive-glob-match': 1.1.0 + brace-expansion: 5.0.13 + + ms@2.1.3: {} + + nanoid@3.3.20: {} + + natural-compare@1.4.0: {} + + obug@3.0.0: {} + + on-exit-leak-free@2.1.2: {} + + optionator@0.9.4: + dependencies: + deep-is: 0.1.4 + fast-levenshtein: 2.0.6 + levn: 0.4.1 + prelude-ls: 1.2.1 + type-check: 0.4.0 + word-wrap: 1.2.5 + + p-limit@3.1.0: + dependencies: + yocto-queue: 0.1.0 + + p-locate@5.0.0: + dependencies: + p-limit: 3.1.0 + + path-exists@4.0.0: {} + + path-key@3.1.1: {} + + pg-cloudflare@1.4.1: + optional: true + + pg-connection-string@2.14.1: {} + + pg-int8@1.0.1: {} + + pg-pool@3.14.0(pg@8.23.1): + dependencies: + pg: 8.23.1 + + pg-protocol@1.16.1: {} + + pg-types@2.2.0: + dependencies: + pg-int8: 1.0.1 + postgres-array: 2.0.0 + postgres-bytea: 1.0.1 + postgres-date: 1.0.7 + postgres-interval: 1.2.0 + + pg@8.23.1: + dependencies: + pg-connection-string: 2.14.1 + pg-pool: 3.14.0(pg@8.23.1) + pg-protocol: 1.16.1 + pg-types: 2.2.0 + pgpass: 1.0.5 + optionalDependencies: + pg-cloudflare: 1.4.1 + + pgpass@1.0.5: + dependencies: + split2: 4.2.0 + + picocolors@1.1.1: {} + + picomatch@4.0.7: {} + + pino-abstract-transport@3.0.0: + dependencies: + split2: 4.2.0 + + pino-std-serializers@7.1.0: {} + + pino@10.4.0: + dependencies: + '@pinojs/redact': 0.4.0 + atomic-sleep: 1.0.0 + on-exit-leak-free: 2.1.2 + pino-abstract-transport: 3.0.0 + pino-std-serializers: 7.1.0 + process-warning: 5.1.1 + quick-format-unescaped: 4.0.4 + real-require: 1.0.0 + safe-stable-stringify: 2.5.0 + sonic-boom: 4.2.1 + thread-stream: 4.2.1 + + postcss@8.5.33: + dependencies: + nanoid: 3.3.20 + picocolors: 1.1.1 + source-map-js: 1.2.2 + + postgres-array@2.0.0: {} + + postgres-bytea@1.0.1: {} + + postgres-date@1.0.7: {} + + postgres-interval@1.2.0: + dependencies: + xtend: 4.0.2 + + prelude-ls@1.2.1: {} + + process-warning@5.1.1: {} + + punycode@2.3.1: {} + + qified@0.10.1: + dependencies: + hookified: 2.2.0 + + quick-format-unescaped@4.0.4: {} + + real-require@1.0.0: {} + + require-from-string@2.0.2: {} + + ret@0.5.1: {} + + reusify@1.1.0: {} + + rfdc@1.4.1: {} + + rolldown@1.2.19: + dependencies: + '@oxc-project/types': 0.156.0 + '@rolldown/pluginutils': 1.1.1 + optionalDependencies: + '@rolldown/binding-android-arm-eabi': 1.2.19 + '@rolldown/binding-android-arm64': 1.2.19 + '@rolldown/binding-darwin-arm64': 1.2.19 + '@rolldown/binding-darwin-x64': 1.2.19 + '@rolldown/binding-freebsd-x64': 1.2.19 + '@rolldown/binding-linux-arm-gnueabihf': 1.2.19 + '@rolldown/binding-linux-arm64-gnu': 1.2.19 + '@rolldown/binding-linux-arm64-musl': 1.2.19 + '@rolldown/binding-linux-ppc64-gnu': 1.2.19 + '@rolldown/binding-linux-s390x-gnu': 1.2.19 + '@rolldown/binding-linux-x64-gnu': 1.2.19 + '@rolldown/binding-linux-x64-musl': 1.2.19 + '@rolldown/binding-openharmony-arm64': 1.2.19 + '@rolldown/binding-wasm32-wasi': 1.2.19 + '@rolldown/binding-win32-arm64-msvc': 1.2.19 + '@rolldown/binding-win32-x64-msvc': 1.2.19 + + safe-regex2@5.1.2: + dependencies: + ret: 0.5.1 + + safe-stable-stringify@2.5.0: {} + + secure-json-parse@4.1.1: {} + + semver@7.8.6: {} + + set-cookie-parser@3.2.2: {} + + shebang-command@2.0.0: + dependencies: + shebang-regex: 3.0.0 + + shebang-regex@3.0.0: {} + + sonic-boom@4.2.1: + dependencies: + atomic-sleep: 1.0.0 + + source-map-js@1.2.2: {} + + split2@4.2.0: {} + + std-env@4.3.0: {} + + thread-stream@4.2.1: + dependencies: + real-require: 1.0.0 + + tinybench@6.2.3: {} + + tinyexec@1.3.1: {} + + tinyglobby@0.2.17: + dependencies: + fdir: 6.5.0(picomatch@4.0.7) + picomatch: 4.0.7 + + toad-cache@3.7.4: {} + + ts-api-utils@2.5.0(typescript@6.0.3): + dependencies: + typescript: 6.0.3 + + tslib@2.9.1: + optional: true + + tsx@4.23.15: + dependencies: + esbuild: 0.28.2 + optionalDependencies: + fsevents: 2.3.3 + + type-check@0.4.0: + dependencies: + prelude-ls: 1.2.1 + + typescript-eslint@8.72.2(eslint@10.15.0)(typescript@6.0.3): + dependencies: + '@typescript-eslint/eslint-plugin': 8.72.2(@typescript-eslint/parser@8.72.2(eslint@10.15.0)(typescript@6.0.3))(eslint@10.15.0)(typescript@6.0.3) + '@typescript-eslint/parser': 8.72.2(eslint@10.15.0)(typescript@6.0.3) + '@typescript-eslint/typescript-estree': 8.72.2(typescript@6.0.3) + '@typescript-eslint/utils': 8.72.2(eslint@10.15.0)(typescript@6.0.3) + eslint: 10.15.0 + typescript: 6.0.3 + transitivePeerDependencies: + - supports-color + + typescript@6.0.3: {} + + undici-types@8.9.0: {} + + uri-js@4.4.1: + dependencies: + punycode: 2.3.1 + + vite@8.3.8(@types/node@26.6.6)(esbuild@0.28.2)(tsx@4.23.15): + dependencies: + lightningcss: 1.33.0 + picomatch: 4.0.7 + postcss: 8.5.33 + rolldown: 1.2.19 + tinyglobby: 0.2.17 + optionalDependencies: + '@types/node': 26.6.6 + esbuild: 0.28.2 + fsevents: 2.3.3 + tsx: 4.23.15 + + vitest@5.1.0(@types/node@26.6.6)(vite@8.3.8(@types/node@26.6.6)(esbuild@0.28.2)(tsx@4.23.15)): + dependencies: + '@types/chai': 5.2.3 + '@vitest/mocker': 5.1.0(vite@8.3.8(@types/node@26.6.6)(esbuild@0.28.2)(tsx@4.23.15)) + chai: 6.3.0 + es-module-lexer: 2.3.2 + expect-type: 1.4.0 + magic-string: 1.4.5 + obug: 3.0.0 + picomatch: 4.0.7 + std-env: 4.3.0 + tinybench: 6.2.3 + tinyexec: 1.3.1 + tinyglobby: 0.2.17 + vite: 8.3.8(@types/node@26.6.6)(esbuild@0.28.2)(tsx@4.23.15) + why-is-node-running: 3.2.1 + optionalDependencies: + '@types/node': 26.6.6 + transitivePeerDependencies: + - msw + + which@2.0.2: + dependencies: + isexe: 2.0.0 + + why-is-node-running@3.2.1: {} + + word-wrap@1.2.5: {} + + xtend@4.0.2: {} + + yocto-queue@0.1.0: {} diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml new file mode 100644 index 0000000..5ed0b5a --- /dev/null +++ b/pnpm-workspace.yaml @@ -0,0 +1,2 @@ +allowBuilds: + esbuild: true diff --git a/src/app.ts b/src/app.ts new file mode 100644 index 0000000..48576f9 --- /dev/null +++ b/src/app.ts @@ -0,0 +1,145 @@ +import Fastify, { type FastifyInstance } from "fastify"; +import type { Db, Queryable } from "./db.js"; +import { RESOURCES, validate, type Resource } from "./resources.js"; + +export interface AppOptions { + db: Db; + apiToken: string; +} + +const SECRET_KEY = /token|secret|password|api[_-]?key/i; +export function redact(value: unknown): unknown { + if (Array.isArray(value)) return value.map(redact); + if (value && typeof value === "object") { + return Object.fromEntries(Object.entries(value).map(([k, v]) => [k, SECRET_KEY.test(k) ? "[redacted]" : redact(v)])); + } + return value; +} + +async function audit(q: Queryable, action: string, entity: string, before: unknown, after: unknown, actor = "owner") { + await q.query("insert into audit_logs (actor, action, entity, before, after) values ($1,$2,$3,$4,$5)", [ + actor, action, entity, before == null ? null : JSON.stringify(redact(before)), after == null ? null : JSON.stringify(redact(after)), + ]); +} + +export function buildApp({ db, apiToken }: AppOptions): FastifyInstance { + const app = Fastify(); + + app.get("/healthz", async () => ({ ok: true })); + + app.addHook("onRequest", async (req, reply) => { + if (req.url === "/healthz") return; + if (req.headers.authorization !== `Bearer ${apiToken}`) return reply.code(401).send({ error: "unauthorized" }); + }); + + for (const res of RESOURCES) registerResource(app, db, res); + + app.get("/public-profile", async () => { + const profile = await db.query("select * from person_profile where status = 'public_confirmed' order by id limit 1"); + const roles = await db.query<{ is_current: boolean }>("select * from career_history where status = 'public_confirmed' order by start_year desc nulls last, id"); + return { profile: profile[0] ?? null, current_roles: roles.filter((r) => r.is_current), past_roles: roles.filter((r) => !r.is_current) }; + }); + + app.get("/audit", async () => db.query("select * from audit_logs order by id desc limit 200")); + + app.get("/approvals", async () => db.query("select * from approvals order by id desc")); + app.post<{ Params: { id: string }; Body: { decision?: string } }>("/approvals/:id/decision", async (req, reply) => { + const decision = req.body?.decision; + if (decision !== "approved" && decision !== "rejected") return reply.code(422).send({ error: "decision must be approved or rejected" }); + return db.tx(async (q) => { + const [before] = await q.query("select * from approvals where id = $1 for update", [Number(req.params.id)]); + if (!before) return reply.code(404).send({ error: "not found" }); + if ((before as { status: string }).status !== "pending") return reply.code(409).send({ error: "already decided" }); + const [after] = await q.query("update approvals set status = $2, decided_at = now() where id = $1 returning *", [Number(req.params.id), decision]); + await audit(q, "decide_approval", `approvals/${req.params.id}`, before, after); + return after; + }); + }); + + app.get("/policy", async () => db.query("select * from action_policy order by action")); + + app.post<{ Params: { action: string }; Body: { approval_id?: number; payload?: unknown } }>("/actions/:action", async (req, reply) => { + const action = req.params.action; + const approvalId = req.body?.approval_id; + const payload = req.body?.payload ?? null; + return db.tx(async (q) => { + const [policy] = await q.query<{ mode: string; granted: boolean }>("select * from action_policy where action = $1", [action]); + if (!policy) return reply.code(404).send({ error: "unknown action" }); + const needsApproval = policy.mode === "C" || (policy.mode === "B" && !policy.granted); + if (needsApproval) { + const [ap] = approvalId ? await q.query<{ id: number }>("select * from approvals where id = $1 and action = $2 and status = 'approved' for update", [approvalId, action]) : []; + if (!ap) { + const [created] = await q.query<{ id: number }>("insert into approvals (action, payload) values ($1, $2) returning *", [action, payload == null ? null : JSON.stringify(redact(payload))]); + await audit(q, "request_approval", `approvals/${created.id}`, null, created); + // Транзакция коммитится: согласование pending должно сохраниться. + return reply.code(403).send({ error: "approval required", mode: policy.mode, approval_id: created.id }); + } + await q.query("update approvals set status = 'used' where id = $1", [ap.id]); + } + await audit(q, `action:${action}`, `actions/${action}`, null, { mode: policy.mode, approval_id: approvalId ?? null, payload }); + return { ok: true, action, mode: policy.mode }; + }); + }); + + return app; +} + +function registerResource(app: FastifyInstance, db: Db, res: Resource) { + const base = `/${res.route}`; + + app.get<{ Querystring: { audience?: string } }>(base, async (req) => { + if (req.query.audience === "public") { + const where = ["status = 'public_confirmed'", res.publicWhere].filter(Boolean).join(" and "); + return db.query(`select * from ${res.table} where ${where} order by id`); + } + return db.query(`select * from ${res.table} order by id`); + }); + + app.get<{ Params: { id: string } }>(`${base}/:id`, async (req, reply) => { + const [row] = await db.query(`select * from ${res.table} where id = $1`, [Number(req.params.id)]); + return row ?? reply.code(404).send({ error: "not found" }); + }); + + app.post(base, async (req, reply) => { + const v = validate(res, req.body, false); + if ("error" in v) return reply.code(422).send({ error: v.error }); + const cols = Object.keys(v.values); + try { + const row = await db.tx(async (q) => { + const [created] = await q.query<{ id: number }>( + cols.length ? `insert into ${res.table} (${cols.join(",")}) values (${cols.map((_, i) => `$${i + 1}`).join(",")}) returning *` : `insert into ${res.table} default values returning *`, + Object.values(v.values), + ); + await audit(q, "create", `${res.table}/${created.id}`, null, created); + return created; + }); + return reply.code(201).send(row); + } catch (e) { + if ((e as { code?: string }).code === "23503") return reply.code(422).send({ error: "referenced record does not exist" }); + throw e; + } + }); + + app.patch<{ Params: { id: string } }>(`${base}/:id`, async (req, reply) => { + const v = validate(res, req.body, true); + if ("error" in v) return reply.code(422).send({ error: v.error }); + const cols = Object.keys(v.values); + if (!cols.length) return reply.code(422).send({ error: "nothing to update" }); + const id = Number(req.params.id); + try { + return await db.tx(async (q) => { + const [before] = await q.query(`select * from ${res.table} where id = $1 for update`, [id]); + if (!before) return reply.code(404).send({ error: "not found" }); + const [after] = await q.query( + `update ${res.table} set ${cols.map((c, i) => `${c} = $${i + 1}`).join(",")}, updated_at = now() where id = $${cols.length + 1} returning *`, + [...Object.values(v.values), id], + ); + await audit(q, "update", `${res.table}/${id}`, before, after); + return after; + }); + } catch (e) { + if ((e as { code?: string }).code === "23503") return reply.code(422).send({ error: "referenced record does not exist" }); + throw e; + } + }); +} diff --git a/src/db.ts b/src/db.ts new file mode 100644 index 0000000..824eb57 --- /dev/null +++ b/src/db.ts @@ -0,0 +1,56 @@ +import { readdirSync, readFileSync } from "node:fs"; +import { join } from "node:path"; +import pg from "pg"; + +export interface Queryable { + query>(sql: string, params?: unknown[]): Promise; +} +export interface Db extends Queryable { + tx(fn: (q: Queryable) => Promise): Promise; + close(): Promise; +} + +export function createPgDb(connectionString: string): Db { + const pool = new pg.Pool({ connectionString }); + return { + async query(sql: string, params?: unknown[]) { + return (await pool.query(sql, params)).rows as T[]; + }, + async tx(fn: (q: Queryable) => Promise) { + const client = await pool.connect(); + const q: Queryable = { + async query(sql: string, params?: unknown[]) { + return (await client.query(sql, params)).rows as R[]; + }, + }; + try { + await client.query("begin"); + const result = await fn(q); + await client.query("commit"); + return result; + } catch (e) { + await client.query("rollback"); + throw e; + } finally { + client.release(); + } + }, + close: () => pool.end(), + }; +} + +export async function migrate(db: Db, dir = join(process.cwd(), "migrations")): Promise { + await db.query("create table if not exists schema_migrations (name text primary key, applied_at timestamptz not null default now())"); + const done = new Set((await db.query<{ name: string }>("select name from schema_migrations")).map((r) => r.name)); + const applied: string[] = []; + for (const file of readdirSync(dir).filter((f) => f.endsWith(".sql")).sort()) { + if (done.has(file)) continue; + const sql = readFileSync(join(dir, file), "utf8"); + await db.tx(async (q) => { + await q.query(sql); + await q.query("insert into schema_migrations (name) values ($1)", [file]); + }); + applied.push(file); + } + return applied; +} diff --git a/src/index.ts b/src/index.ts new file mode 100644 index 0000000..1355108 --- /dev/null +++ b/src/index.ts @@ -0,0 +1,13 @@ +import { buildApp } from "./app.js"; +import { createPgDb, migrate } from "./db.js"; + +const url = process.env.DATABASE_URL; +const token = process.env.API_TOKEN; +if (!url || !token) { + console.error("DATABASE_URL and API_TOKEN are required"); + process.exit(1); +} +const db = createPgDb(url); +await migrate(db); +const app = buildApp({ db, apiToken: token }); +await app.listen({ port: Number(process.env.PORT ?? 3000), host: "0.0.0.0" }); diff --git a/src/migrate.ts b/src/migrate.ts new file mode 100644 index 0000000..5f5597d --- /dev/null +++ b/src/migrate.ts @@ -0,0 +1,11 @@ +import { createPgDb, migrate } from "./db.js"; + +const url = process.env.DATABASE_URL; +if (!url) { + console.error("DATABASE_URL is required"); + process.exit(1); +} +const db = createPgDb(url); +const applied = await migrate(db); +console.log(applied.length ? `applied: ${applied.join(", ")}` : "no pending migrations"); +await db.close(); diff --git a/src/resources.ts b/src/resources.ts new file mode 100644 index 0000000..ca309e3 --- /dev/null +++ b/src/resources.ts @@ -0,0 +1,51 @@ +export const FACT_STATUSES = ["public_confirmed", "internal_confirmed", "hypothesis", "outdated", "forbidden"] as const; + +type FieldType = "string" | "int" | "bool"; +export interface Resource { + route: string; + table: string; + fields: Record; + /** Дополнительное условие публичного вывода. */ + publicWhere?: string; +} + +const common: Resource["fields"] = { + status: { type: "string" }, + confidence: { type: "int" }, + source_evidence_id: { type: "int" }, +}; + +export const RESOURCES: Resource[] = [ + { route: "sources", table: "source_evidence", fields: { title: { type: "string", required: true }, url: { type: "string" }, note: { type: "string" }, status: { type: "string" }, confidence: { type: "int" } } }, + { route: "profile", table: "person_profile", fields: { full_name: { type: "string", required: true }, headline: { type: "string" }, bio: { type: "string" }, ...common } }, + { route: "career", table: "career_history", fields: { organization: { type: "string", required: true }, position: { type: "string" }, start_year: { type: "int" }, end_year: { type: "int" }, is_current: { type: "bool" }, ...common } }, + { route: "credentials", table: "credentials", fields: { title: { type: "string", required: true }, issuer: { type: "string" }, year: { type: "int" }, document_url: { type: "string" }, ...common } }, + { + route: "cases", + table: "cases", + fields: { title: { type: "string", required: true }, problem: { type: "string" }, role: { type: "string" }, solution: { type: "string" }, scale: { type: "string" }, result: { type: "string" }, metrics: { type: "string" }, public_use_permitted: { type: "bool" }, ...common }, + publicWhere: "public_use_permitted = true", + }, +]; + +/** Возвращает очищенные значения или текст ошибки. */ +export function validate(res: Resource, body: unknown, partial: boolean): { values: Record } | { error: string } { + if (typeof body !== "object" || body === null || Array.isArray(body)) return { error: "body must be an object" }; + const input = body as Record; + const values: Record = {}; + for (const [name, spec] of Object.entries(res.fields)) { + const v = input[name]; + if (v === undefined) { + if (spec.required && !partial) return { error: `${name} is required` }; + continue; + } + if (v === null && !spec.required) { values[name] = null; continue; } + if (spec.type === "string" && typeof v !== "string") return { error: `${name} must be a string` }; + if (spec.type === "int" && !Number.isInteger(v)) return { error: `${name} must be an integer` }; + if (spec.type === "bool" && typeof v !== "boolean") return { error: `${name} must be a boolean` }; + if (name === "status" && !(FACT_STATUSES as readonly string[]).includes(v as string)) return { error: `status must be one of ${FACT_STATUSES.join(", ")}` }; + if (name === "confidence" && ((v as number) < 0 || (v as number) > 100)) return { error: "confidence must be 0..100" }; + values[name] = v; + } + return { values }; +} diff --git a/tests/approvals-audit.test.ts b/tests/approvals-audit.test.ts new file mode 100644 index 0000000..5570315 --- /dev/null +++ b/tests/approvals-audit.test.ts @@ -0,0 +1,65 @@ +import { beforeEach, describe, expect, it } from "vitest"; +import { redact } from "../src/app.js"; +import { setup } from "./helpers.js"; + +let t: Awaited>; +beforeEach(async () => { t = await setup(); }); + +describe("Requirement: Режимы полномочий", () => { + it("Scenario: Режим C без одобрения", async () => { + const res = await t.call("POST", "/actions/set_public_positioning", { payload: { text: "x" } }); + expect(res.statusCode).toBe(403); + const approvals = (await t.call("GET", "/approvals")).json(); + expect(approvals).toHaveLength(1); + expect(approvals[0].status).toBe("pending"); + }); + + it("Scenario: Режим C с одобрением", async () => { + const { approval_id } = (await t.call("POST", "/actions/set_public_positioning", {})).json(); + await t.call("POST", `/approvals/${approval_id}/decision`, { decision: "approved" }); + const res = await t.call("POST", "/actions/set_public_positioning", { approval_id }); + expect(res.statusCode).toBe(200); + // одобрение одноразовое + expect((await t.call("POST", "/actions/set_public_positioning", { approval_id })).statusCode).toBe(403); + }); + + it("Scenario: Отклонённое согласование не открывает действие", async () => { + const { approval_id } = (await t.call("POST", "/actions/send_commercial_offer", {})).json(); + await t.call("POST", `/approvals/${approval_id}/decision`, { decision: "rejected" }); + expect((await t.call("POST", "/actions/send_commercial_offer", { approval_id })).statusCode).toBe(403); + }); + + it("Scenario: Режим A", async () => { + const res = await t.call("POST", "/actions/create_hypothesis", {}); + expect(res.statusCode).toBe(200); + }); + + it("Scenario: неизвестное действие — 404", async () => { + expect((await t.call("POST", "/actions/nope", {})).statusCode).toBe(404); + }); +}); + +describe("Requirement: Журнал действий", () => { + it("Scenario: Изменение пишет журнал", async () => { + const c = (await t.call("POST", "/career", { organization: "X", position: "Директор" })).json(); + await t.call("PATCH", `/career/${c.id}`, { position: "Генеральный директор" }); + const logs = (await t.call("GET", "/audit")).json(); + const upd = logs.find((l: { entity: string; action: string }) => l.entity === `career_history/${c.id}` && l.action === "update"); + expect(upd.before.position).toBe("Директор"); + expect(upd.after.position).toBe("Генеральный директор"); + }); + + it("Scenario: Без токена", async () => { + const res = await t.call("POST", "/cases", { title: "x" }, null); + expect(res.statusCode).toBe(401); + expect(await t.db.query("select * from audit_logs")).toHaveLength(0); + }); + + it("Scenario: секреты не попадают в журнал", () => { + expect(redact({ api_token: "abc", nested: { password: "p", ok: 1 } })).toEqual({ api_token: "[redacted]", nested: { password: "[redacted]", ok: 1 } }); + }); + + it("healthz открыт без токена", async () => { + expect((await t.call("GET", "/healthz", undefined, null)).statusCode).toBe(200); + }); +}); diff --git a/tests/helpers.ts b/tests/helpers.ts new file mode 100644 index 0000000..02fa5db --- /dev/null +++ b/tests/helpers.ts @@ -0,0 +1,34 @@ +import { PGlite } from "@electric-sql/pglite"; +import { buildApp } from "../src/app.js"; +import { migrate, type Db, type Queryable } from "../src/db.js"; + +export const TOKEN = "mock-owner-token"; + +/** Postgres в WASM (PGlite) с тем же интерфейсом Db, что и боевой pg. */ +export function createMockDb(): Db { + const pg = new PGlite(); + const wrap = (c: { query: PGlite["query"]; exec: PGlite["exec"] }): Queryable => ({ + async query(sql: string, params?: unknown[]) { + if (params === undefined) { + const r = await c.exec(sql); + return (r[r.length - 1]?.rows ?? []) as T[]; + } + return (await c.query(sql, params)).rows as T[]; + }, + }); + const base = wrap(pg as never); + return { + ...base, + tx: (fn) => pg.transaction((t) => fn(wrap(t as never))), + close: () => pg.close(), + }; +} + +export async function setup() { + const db = createMockDb(); + await migrate(db); + const app = buildApp({ db, apiToken: TOKEN }); + const call = (method: "GET" | "POST" | "PATCH", url: string, payload?: unknown, token: string | null = TOKEN) => + app.inject({ method, url, payload: payload as object, headers: token ? { authorization: `Bearer ${token}` } : {} }); + return { db, app, call }; +} diff --git a/tests/knowledge-base.test.ts b/tests/knowledge-base.test.ts new file mode 100644 index 0000000..de3ee0f --- /dev/null +++ b/tests/knowledge-base.test.ts @@ -0,0 +1,54 @@ +import { beforeEach, describe, expect, it } from "vitest"; +import { setup } from "./helpers.js"; + +let t: Awaited>; +beforeEach(async () => { t = await setup(); }); + +describe("Requirement: Факты со статусом достоверности", () => { + it("Scenario: Создание факта с источником", async () => { + const src = (await t.call("POST", "/sources", { title: "LinkedIn-профиль" })).json(); + const res = await t.call("POST", "/career", { organization: "Казахтелеком", status: "hypothesis", source_evidence_id: src.id }); + expect(res.statusCode).toBe(201); + const body = res.json(); + expect(body.created_at).toBeTruthy(); + expect(body.updated_at).toBeTruthy(); + expect(body.source_evidence_id).toBe(src.id); + }); + + it("Scenario: Недопустимый статус", async () => { + const res = await t.call("POST", "/cases", { title: "Кейс", status: "точно правда" }); + expect(res.statusCode).toBe(422); + expect((await t.call("GET", "/cases")).json()).toHaveLength(0); + }); + + it("Scenario: несуществующий источник — 422", async () => { + const res = await t.call("POST", "/career", { organization: "X", source_evidence_id: 999 }); + expect(res.statusCode).toBe(422); + }); +}); + +describe("Requirement: Публичный вывод только подтверждённого", () => { + it("Scenario: Гипотеза скрыта", async () => { + await t.call("POST", "/career", { organization: "Казпочта", status: "public_confirmed" }); + await t.call("POST", "/career", { organization: "Грант", status: "hypothesis" }); + const rows = (await t.call("GET", "/career?audience=public")).json(); + expect(rows.map((r: { organization: string }) => r.organization)).toEqual(["Казпочта"]); + }); + + it("Scenario: Кейс без разрешения", async () => { + await t.call("POST", "/cases", { title: "Закрытый", status: "public_confirmed", public_use_permitted: false }); + await t.call("POST", "/cases", { title: "Открытый", status: "public_confirmed", public_use_permitted: true }); + const rows = (await t.call("GET", "/cases?audience=public")).json(); + expect(rows.map((r: { title: string }) => r.title)).toEqual(["Открытый"]); + }); +}); + +describe("Requirement: Историческая роль не текущая", () => { + it("Scenario: Прошлая должность", async () => { + await t.call("POST", "/career", { organization: "Телеконтакт", position: "генеральный директор", is_current: false, status: "public_confirmed" }); + await t.call("POST", "/career", { organization: "Grow Consulting", is_current: true, status: "public_confirmed" }); + const body = (await t.call("GET", "/public-profile")).json(); + expect(body.current_roles.map((r: { organization: string }) => r.organization)).toEqual(["Grow Consulting"]); + expect(body.past_roles.map((r: { organization: string }) => r.organization)).toEqual(["Телеконтакт"]); + }); +}); diff --git a/tsconfig.build.json b/tsconfig.build.json new file mode 100644 index 0000000..f5a48c0 --- /dev/null +++ b/tsconfig.build.json @@ -0,0 +1 @@ +{ "extends": "./tsconfig.json", "compilerOptions": { "rootDir": "src" }, "include": ["src"] } diff --git a/tsconfig.json b/tsconfig.json new file mode 100644 index 0000000..5c1bcc4 --- /dev/null +++ b/tsconfig.json @@ -0,0 +1,7 @@ +{ + "compilerOptions": { + "target": "ES2023", "module": "NodeNext", "moduleResolution": "NodeNext", + "strict": true, "esModuleInterop": true, "skipLibCheck": true, "outDir": "dist", "rootDir": "." + }, + "include": ["src", "tests"] +} -- 2.45.2 From ad1a44aee8169c741d49c47f0791242948ea3f52 Mon Sep 17 00:00:00 2001 From: Peppa Date: Sun, 15 Nov 2026 14:02:34 +0500 Subject: [PATCH 4/4] =?UTF-8?q?BRM-10:=20CI=20=E2=80=94=20pnpm=20=D1=87?= =?UTF-8?q?=D0=B5=D1=80=D0=B5=D0=B7=20npx,=20=D0=B5=D1=81=D0=BB=D0=B8=20?= =?UTF-8?q?=D0=BD=D0=B5=20=D1=83=D1=81=D1=82=D0=B0=D0=BD=D0=BE=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=20=D0=BD=D0=B0=20=D1=80=D0=B0=D0=BD=D0=BD=D0=B5?= =?UTF-8?q?=D1=80=D0=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Sonnet 5.5 --- .peppa/project.json | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.peppa/project.json b/.peppa/project.json index 6ff4712..52ed01a 100644 --- a/.peppa/project.json +++ b/.peppa/project.json @@ -4,11 +4,11 @@ "name": "Бренд менеджер", "peppaUrl": "https://peppa.telecom.quest", "checks": { - "install": "pnpm install --frozen-lockfile", - "lint": "pnpm lint", - "typecheck": "pnpm typecheck", - "test": "pnpm test", - "build": "pnpm build" + "install": "command -v pnpm >/dev/null && pnpm install --frozen-lockfile || npx --yes pnpm@12.18.0 install --frozen-lockfile", + "lint": "command -v pnpm >/dev/null && pnpm lint || npx --yes pnpm@12.18.0 lint", + "typecheck": "command -v pnpm >/dev/null && pnpm typecheck || npx --yes pnpm@12.18.0 typecheck", + "test": "command -v pnpm >/dev/null && pnpm test || npx --yes pnpm@12.18.0 test", + "build": "command -v pnpm >/dev/null && pnpm build || npx --yes pnpm@12.18.0 build" }, "deploy": { "compose": "deploy/compose.yml", -- 2.45.2