diff --git a/.gitignore b/.gitignore index a6547a1..75b37ef 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,14 @@ +# Private project/agent docs — never commit +DEVELOPMENT_LOG.md +PROJECT.md +STRUCTURE.md +FUTURE.md +HISTORY.md +BUILD_SUMMARY.md +SCRIPTS.md +project-requirements.md +.learnings/ + # Dependencies node_modules/ .venv/ diff --git a/DEVELOPMENT_LOG.md b/DEVELOPMENT_LOG.md deleted file mode 100644 index cb6ad16..0000000 --- a/DEVELOPMENT_LOG.md +++ /dev/null @@ -1,88 +0,0 @@ -# Mission Control — Development Log - -**Purpose:** Track active development work across all agents. Bishop uses this to update documentation. - -**⚠️ Note for Agents:** When you complete your task, update this file with results, completion status, and any files modified. Ripley will then notify Bishop to review and decide on documentation updates. You have `write` and `edit` access to this file. - ---- - -## Current Work (In Progress) - -*(No active development — project is between phases)* - ---- - -## Completed Work - -### v0.0.4 — Gateway Data Collection Service -**Status:** ✅ COMPLETED -**Date:** 2026-05-11 -**Agent:** Neo (build) + Ripley (fix/verify/commit) - -**Files Created:** -- `src/backend/app/services/monitoring/__init__.py` — Package init, exports GatewayCollectorService -- `src/backend/app/services/monitoring/gateway_collector.py` — Background asyncio collector (544→510 lines after fixes) -- `src/backend/app/services/monitoring/models.py` — Pydantic schemas for RPC response parsing - -**Files Modified:** -- `src/backend/app/main.py` — Added asyncio import, collector startup/shutdown in lifespan -- `src/backend/app/models/monitoring.py` — Fixed FK definitions (Column(UUID, ForeignKey) → Field(foreign_key=)) -- `src/backend/app/models/alert_rules.py` — Fixed FK definitions, added missing gateway_id field - -**Bugs Fixed by Ripley:** -- Duplicate `select` imports (sqlalchemy + sqlmodel) -- Removed OpenClawDBService inheritance (collector uses session factory pattern) -- Removed unused imports (datetime, timezone, UUID, TYPE_CHECKING) -- Fixed `Column(UUID, ForeignKey(...))` — Python uuid.UUID is not a SQLAlchemy type -- Added missing `gateway_id` field to AlertRule model -- Cleaned up runtime imports in lifespan (moved to module-level) - -**Verification:** -- Docker build passes -- Backend starts successfully (logs `app.lifecycle.gateway_collector.no_gateways`) -- Collector class imports correctly in container - ---- - -### v0.0.2 — Base Platform Setup -**Status:** ✅ COMPLETED -**Date:** 2026-05-10 -**Priority:** N/A (setup) - -| Agent | Status | Time | Notes | -|-------|--------|------|-------| -| Ripley | ✅ COMPLETED | — | Forked base platform, set up Docker, verified 97 API endpoints | - -**Files created:** `compose.yml`, `.env`, `.dockerignore`, `src/backend/Dockerfile`, `HISTORY.md`, `VERSION.md` - -**Work Completed:** -- [x] Copied base platform into src/ (backend + frontend) -- [x] Adapted Dockerfile and compose.yml for src/ project layout -- [x] Fixed webhook-worker scripts path -- [x] Local dev auth mode: local (token-based) -- [x] All 4 services running: db, redis, backend, frontend, webhook-worker -- [x] 97 API endpoints verified operational -- [x] Database migrations auto-applied -- [x] Git repo initialized on main branch - -### v0.0.1 — Project Initialization -**Status:** ✅ COMPLETED -**Date:** 2026-05-10 -**Priority:** N/A (setup) - -| Agent | Status | Time | Notes | -|-------|--------|------|-------| -| Ripley | ✅ COMPLETED | — | Created project structure, cloned source repos, wrote plan | - -**Files created:** `PROJECT.md`, `STRUCTURE.md`, `FUTURE.md`, `HISTORY.md`, `DEVELOPMENT_LOG.md`, `VERSION.md` - -**Work Completed:** -- [x] Analyzed all 3 source repos (mission-control, dashboard, pixel-agents) -- [x] Wrote comprehensive 4-phase implementation plan -- [x] Created project structure with agent roles -- [x] Set up version history tracking -- [x] Cloned source repos to `/tmp/mission-control-research/` - ---- - -*This log tracks agent work. For user-facing changes, see HISTORY.md. For planned items, see FUTURE.md.* \ No newline at end of file diff --git a/FUTURE.md b/FUTURE.md deleted file mode 100644 index 4fdfc92..0000000 --- a/FUTURE.md +++ /dev/null @@ -1,313 +0,0 @@ -# Mission Control - Future Improvements - -**This document tracks potential future enhancements for Mission Control.** - -**Last Updated:** 2026-05-10 -**Current Version:** v0.0.4 - -## How to Use This Document - -This file is a living document. Agents should: -1. Read this file before proposing changes -2. Add new recommendations with priority levels -3. Never add completed items - move those to HISTORY.md instead -4. Reference this file when dispatching improvement tasks -5. Only Ripley can remove items from this list. - -### Priority Format - -All items must include the priority emoji in their heading, matching the section they belong to: - -| Priority | Emoji | Heading Format | -|----------|-------|---------------| -| CRITICAL | 🔴 | `### 🔴 Title - CRITICAL` | -| HIGH | 🟠 | `### 🟠 Title - HIGH` | -| MEDIUM | 🟡 | `### 💡 Title - MEDIUM` | -| LOW | 🔵 | `### 🔵 Title - LOW` | -| NICE TO HAVE | 💭 | `### 💭 Title - NICE TO HAVE` | - -Items are grouped under their priority section heading (`## 🔴 CRITICAL`, `## 🟠 HIGH`, etc.) and sorted most-impactful-first within each tier. - ---- - -## Pending Recommendations - -### 🟠 HIGH - -### 🟠 Gateway Data Collection Service - HIGH -**Priority:** HIGH -**Status:** DONE ✅ -**Added:** 2026-05-10 by Ripley -**Completed:** 2026-05-11 - -GatewayCollectorService created in `src/backend/app/services/monitoring/`. Background asyncio task polls gateway RPC endpoints (cost, cron, sessions, health) and upserts into monitoring models. Configurable intervals via env vars. Startup/shutdown integrated into main.py lifespan. - -### 🟠 Monitoring Database Models - HIGH -**Priority:** HIGH -**Status:** DONE ✅ -**Added:** 2026-05-10 by Ripley -**Completed:** 2026-05-11 - -All 7 models created, migrated, CASCADE + composite indexes verified in running DB. Committed as v0.0.3. - -**Description:** -Create new PostgreSQL models for tracking data (cost, sessions, crons, system health, alerts). - -**Implementation Notes:** -- CostSnapshot, CronJobStatus, SessionEvent, SubAgentRun, SystemHealthMetric, AlertRule -- Alembic migration for all new tables -- CRUD API endpoints under `/api/monitoring/` - -### 🟠 WebSocket for Agent Events - HIGH -**Priority:** HIGH -**Status:** DONE ✅ -**Added:** 2026-05-10 by Ripley -**Completed:** 2026-05-11 - -WebSocket endpoint at `/ws/agents` with initial state snapshot (last 50 events) and background polling (every 2s). Event parser ported from TS source. Committed in v0.0.4. - ---- - -### 🟡 MEDIUM - -### 🟠 Monitoring API Endpoints - HIGH -**Priority:** HIGH -**Status:** DONE ✅ -**Added:** 2026-05-11 by Ripley -**Completed:** 2026-05-11 - -10 read-only endpoints at /api/v1/monitoring/* with org-scoping, pagination, and filtering. Schemas in app/schemas/monitoring.py, router in app/api/monitoring.py. - -### 🟠 Dashboard Logic Port - HIGH -**Priority:** HIGH -**Status:** DONE ✅ -**Added:** 2026-05-11 by Ripley -**Completed:** 2026-05-11 - -Data processing functions ported to Python: `ModelName()`, `BuildDailyChart()`, `BuildAlerts()`, `FmtTokens()`, `BuildCostBreakdown()`. Event parser ported: `parse_session_event()`, `format_tool_status()`. WebSocket endpoint at `/ws/agents` with initial snapshot + polling. All committed in v0.0.4. - -### 🟠 Cost Summary API Endpoints — HIGH -**Priority:** HIGH -**Status:** DONE ✅ -**Added:** 2026-05-11 by Ripley -**Completed:** 2026-05-12 by Neo - -**Description:** -"How much have I spent today, and which model is burning the most?" — Cost Cards + Cost Breakdown API endpoints. - -**Implementation Notes:** -- Today's cost, all-time cost, projected monthly cost -- Per-model cost breakdown (7d/30d/all-time tabs) -- Use existing `data_processing.BuildCostBreakdown()` and `data_processing.BuildDailyChart()` -- New API endpoints: `GET /api/v1/monitoring/cost-summary` and `GET /api/v1/monitoring/cost-breakdown?range=7d|30d|all` -- Org-scoped, paginated where applicable -- Neo implemented cost-summary and cost-breakdown endpoints - -### 🟠 Health Summary API — HIGH -**Priority:** HIGH -**Status:** DONE ✅ -**Added:** 2026-05-11 by Ripley -**Completed:** 2026-05-12 by Neo - -**Description:** -"Is my gateway actually running right now?" — System health summary endpoint. - -**Implementation Notes:** -- Gateway status (online/offline), PID, uptime, memory, compaction -- CPU, RAM, swap, disk gauges -- Use existing `monitoring/health` endpoint data + `data_processing` functions -- New API endpoint: `GET /api/v1/monitoring/health-summary` -- Neo implemented health-summary endpoint - -### 🟠 Cron Summary API — HIGH -**Priority:** HIGH -**Status:** DONE ✅ -**Added:** 2026-05-11 by Ripley -**Completed:** 2026-05-12 by Neo - -**Description:** -"Which cron jobs ran, which failed, and when does the next one fire?" — Cron summary endpoint. - -**Implementation Notes:** -- List all cron jobs with status, schedule, last/next run, duration, model -- Filter by enabled/disabled, gateway -- Use existing `monitoring/cron-jobs` endpoint -- New API endpoint: `GET /api/v1/monitoring/cron-summary` -- Neo implemented cron-summary endpoint - -### 🟠 Sessions Summary API — HIGH -**Priority:** HIGH -**Status:** DONE ✅ -**Added:** 2026-05-11 by Ripley -**Completed:** 2026-05-12 by Neo - -**Description:** -"What sessions are active and how much context are they consuming?" — Active sessions summary. - -**Implementation Notes:** -- Recent sessions with model, type badges (DM/group/cron/subagent), context %, tokens -- Use `data_processing.ModelName()` and `event_parser.parse_session_event()` -- New API endpoint: `GET /api/v1/monitoring/sessions-summary` -- Neo implemented sessions-summary endpoint - -### 🟠 Sub-Agents Summary API — HIGH -**Priority:** HIGH -**Status:** DONE ✅ -**Added:** 2026-05-11 by Ripley -**Completed:** 2026-05-12 by Neo - -**Description:** -"Are my sub-agents doing useful work or spinning in circles?" — Sub-agent activity summary. - -**Implementation Notes:** -- Sub-agent runs with cost, duration, status + token breakdown (7d/30d tabs) -- Use existing `monitoring/sub-agents` endpoint -- New API endpoint: `GET /api/v1/monitoring/sub-agents-summary` -- Neo implemented sub-agents-summary endpoint - -### 🟠 Cost Trends API — HIGH -**Priority:** HIGH -**Status:** DONE ✅ -**Added:** 2026-05-11 by Ripley -**Completed:** 2026-05-12 by Neo - -**Description:** -"What's the cost trend over the last 7 days — am I accelerating?" — Charts & trends endpoint. - -**Implementation Notes:** -- Cost trend line (7d/30d), model cost breakdown bars, per-model usage -- Use `data_processing.BuildDailyChart()` -- New API endpoint: `GET /api/v1/monitoring/trends?range=7d|30d` -- Neo implemented trends endpoint with 7d/30d support - -### 🟡 Cost Tracking UI - MEDIUM -**Priority:** MEDIUM -**Status:** PENDING -**Added:** 2026-05-10 by Ripley - -**Description:** -Port the dashboard's cost cards, donut charts, and trend lines to React/Recharts components. - -**Implementation Notes:** -- Today's cost, all-time cost, projected monthly -- Per-model cost breakdown (7d/30d/all-time tabs) -- Cost trend line chart (SVG → Recharts) -- Theme-aware styling - -### 🟡 Session & Sub-Agent UI - MEDIUM -**Priority:** MEDIUM -**Status:** PENDING -**Added:** 2026-05-10 by Ripley - -**Description:** -Active sessions with model, type badges, context % bars, sub-agent activity grid. - -**Implementation Notes:** -- Session list with filtering (model, type, status) -- Context % bars, token counts -- Sub-agent activity grid with cost/duration/status -- Session detail panel with conversation preview - -### 🟡 Cron Job Management - MEDIUM -**Priority:** MEDIUM -**Status:** PENDING -**Added:** 2026-05-10 by Ripley - -**Description:** -Cron job list with schedule, status, run history. Trigger manual runs from UI. - -**Implementation Notes:** -- List, add, edit, delete cron jobs via gateway RPC -- Run history with duration and status badges -- Manual trigger button -- Uses existing `cron.*` gateway RPC methods - -### 🟡 System Health Dashboard - MEDIUM -**Priority:** MEDIUM -**Status:** PENDING -**Added:** 2026-05-10 by Ripley - -**Description:** -Gateway status, CPU/RAM/disk gauges, alert banners with configurable thresholds. - -**Implementation Notes:** -- Gateway uptime, PID, memory, compaction status -- CPU/RAM/swap/disk gauge cards -- Alert banner for high cost, failed crons, gateway offline -- Auto-refresh with countdown timer - ---- - -### 🔵 LOW - -### 🔵 AI Chat Panel - LOW -**Priority:** LOW -**Status:** PENDING -**Added:** 2026-05-10 by Ripley - -**Description:** -Port the dashboard's AI chat to a React component that uses OpenClaw gateway's `/v1/chat/completions`. - -**Implementation Notes:** -- Context-aware: feed live monitoring data into system prompt -- Persistent chat history per user -- Streaming responses - -### 🔵 Theme System Merge - LOW -**Priority:** LOW -**Status:** PENDING -**Added:** 2026-05-10 by Ripley - -**Description:** -Port the 6 dashboard themes into Mission Control's Tailwind config. - -**Implementation Notes:** -- Map dashboard's 19 CSS color variables to Tailwind config -- Theme picker in header (persists via localStorage) -- Glass morphism effects where appropriate - -### 🔵 Engineering Reference Manual - LOW -**Priority:** LOW -**Status:** PENDING - Requires explicit user initiation -**Added:** 2026-05-10 by Ripley - -**Description:** -Comprehensive engineering reference manual documenting the full system architecture, API endpoints, data models, frontend pages/components, and infrastructure. - -**Implementation Notes:** -- ⚠️ This task requires explicit initiation by the user. Do not create the Engineering Reference Manual unless specifically asked. -- Should document: system architecture, tech stack, all API endpoints, data models, frontend structure, Docker setup, auth flows -- Bishop would own this task when initiated - ---- - -### 💭 NICE TO HAVE - -### 💭 Pixel Agent Canvas - NICE TO HAVE -**Priority:** NICE TO HAVE -**Status:** PENDING -**Added:** 2026-05-10 by Ripley - -**Description:** -Port the pixel-art office scene with agent sprites, activity bubbles, and day/night cycle to React Canvas. - -**Implementation Notes:** -- Use `useRef` + `requestAnimationFrame` for animation, not React state -- Agent sprites with activity state (working, idle, talking) -- Activity bubbles showing current task/conversation -- Conversation heat glow based on recent activity -- Pan/zoom controls (touch + mouse) - -### 💭 Hardware Monitor & Service Controls - NICE TO HAVE -**Priority:** NICE TO HAVE -**Status:** PENDING -**Added:** 2026-05-10 by Ripley - -**Description:** -Server rack component for hardware gauges, breaker panel for gateway start/stop/restart. - -**Implementation Notes:** -- CPU/GPU/RAM/disk/network gauges -- Gateway start/stop/restart controls -- Update checker (ham radio component) -- All via gateway RPC methods \ No newline at end of file diff --git a/HISTORY.md b/HISTORY.md deleted file mode 100644 index 24a8095..0000000 --- a/HISTORY.md +++ /dev/null @@ -1,84 +0,0 @@ -# Mission Control — Changelog - -## v0.0.5 - -### Added -- **7 monitoring summary endpoints** — Neo implemented all remaining summary endpoints: - - `GET /api/v1/monitoring/cost-summary` — Cost overview per gateway with model breakdown - - `GET /api/v1/monitoring/cost-breakdown` — Models ranked by cost with percentage breakdown - - `GET /api/v1/monitoring/health-summary` — Gateway health status and system metrics (CPU, RAM, disk, uptime) - - `GET /api/v1/monitoring/cron-summary` — Cron job status with scheduling info (schedule, last/next run, failures) - - `GET /api/v1/monitoring/sessions-summary` — Active sessions with context and token breakdown - - `GET /api/v1/monitoring/sub-agents-summary` — Sub-agent runs with cost and token breakdown - - `GET /api/v1/monitoring/trends` — Cost and token trends over 7d or 30d time ranges -- **All endpoints support** org-scoped filtering via `gateway_id`, pagination, and security review passed (Hudson) -- **Security audit** — Hudson reviewed and applied 1 fix for security issues -- **Python compilation verification** — All Python files compile cleanly with `py_compile` - -### Changed -- Version bump: 0.0.4 → 0.0.5 (minor bump for new feature endpoints) -- Updated FUTURE.md — marked all 7 summary endpoints as DONE -- Updated README.md — API reference table now shows all 12 endpoints as Live - -### Build Status -- Backend builds successfully (Docker Compose unavailable due to client version, but Python compilation verified) -- All 50+ Python files in backend compile without errors -- GatewayCollectorService operational with 4 collection intervals (cost, cron, session, health) - -## v0.0.4 - -### Added -- **Gateway Data Collection Service** — Background asyncio task that polls gateway RPC endpoints and stores results in monitoring models - - `gateway_collector.py` — GatewayCollectorService class with per-endpoint collection methods (cost, cron, session, health) - - `models.py` — Pydantic schemas for parsing gateway RPC responses into typed Python objects - - `__init__.py` — Package init, exports GatewayCollectorService -- **Collector startup/shutdown** — Added to main.py lifespan; launches collector as background task when gateways exist -- **Configurable collection intervals** via env vars: COLLECTION_INTERVAL_COST (300s), COLLECTION_INTERVAL_CRON (60s), COLLECTION_INTERVAL_SESSION (30s), COLLECTION_INTERVAL_HEALTH (60s) -- **Upsert pattern** — All DB writes use insert-or-update to avoid duplicate records - -### Fixed -- Model FK definitions in monitoring.py and alert_rules.py: replaced `Column(UUID, ForeignKey(...))` with `Field(foreign_key=...)` to match codebase pattern -- Added missing `gateway_id` field to AlertRule model -- Removed OpenClawDBService inheritance from GatewayCollectorService (uses session factory pattern) -- Cleaned up duplicate/conflicting imports in collector - -## v0.0.3 - -### Added -- **Phase 2: Monitoring database models** — 7 new SQLModel tables for gateway data collection -- **CostSnapshot** — Timestamped cost readings from gateway RPC (per-model, per-provider breakdown) -- **CronJobStatus** — Cron job state, schedule, failure tracking -- **SessionEvent** — Session lifecycle events with model, channel, context%, token counts -- **SubAgentRun** — Sub-agent execution records with duration, cost, token tracking -- **SystemHealthMetric** — CPU, RAM, swap, disk, gateway status metrics -- **AlertRule** — Configurable alert thresholds with comparison operators and cooldown -- **AlertEvent** — Triggered alert instances with acknowledgment and resolution tracking -- **Alembic migration 7a8b9c0d1e2f** — Creates all 7 monitoring tables with FKs and indexes -- **Alembic migration 8f9a0b1c2d3e** — Adds ON DELETE CASCADE to all FKs, SET NULL on acknowledged_by, 14 composite indexes -- **Security audit passed** — Hudson: 1 CRITICAL (CASCADE), 2 HIGH (mass assignment, indexes), 3 MEDIUM — all remediated - -### Changed -- Frontend dev port changed from 3080 to 3037 -- Migration env.py updated for transaction-per-migration to prevent failure chaining - -## v0.0.2 - -### Added -- **Base platform forked and running** — Python/FastAPI backend + Next.js frontend copied into src/ -- **Docker Compose dev environment** — compose.yml, .env, .dockerignore created -- **Dockerfile adapted** — Fixed build context for src/ layout, fixed scripts paths for webhook worker -- **All services operational** — db (Postgres 16), redis, backend (uvicorn :8000), frontend (Next.js :3000), webhook-worker -- **97 API endpoints verified** — Full OpenAPI surface confirmed at /docs -- **Git repo initialized** — main branch, initial commit 9aee2e4 - -### Infrastructure -- Ports mapped: backend → 8080, frontend → 3080 (host), avoiding Portainer/open-webui conflicts -- Auth mode: local (token-based, LOCAL_AUTH_TOKEN in .env) -- DB auto-migrate enabled - -## v0.0.1 - -### Added -- **Project initialization** — STRUCTURE.md, PROJECT.md, FUTURE.md, HISTORY.md, DEVELOPMENT_LOG.md, VERSION.md -- **Source repos cloned** — openclaw-mission-control (base), openclaw-dashboard (tracking), openclaw-pixel-agents-dashboard (visualization) -- **Architecture plan** — Full 4-phase implementation plan documented in PROJECT.md \ No newline at end of file diff --git a/PROJECT.md b/PROJECT.md deleted file mode 100644 index 5539267..0000000 --- a/PROJECT.md +++ /dev/null @@ -1,396 +0,0 @@ -# 🎯 Mission Control — Project Plan - -> Merge three OpenClaw dashboards into a single, unified Mission Control platform. - ---- - -## Source Repos - -| Repo | Purpose | Stack | Key Assets | -|---|---|---|---| -| [abhi1693/openclaw-mission-control](https://github.com/abhi1693/openclaw-mission-control) | **Base platform** — work orchestration, governance, gateway management | Python/FastAPI + PostgreSQL + Redis + Next.js (React 19) + Clerk auth + Docker Compose | Organizations, boards, tasks, tags, approvals, agents, gateways, webhooks, activity feed, skills marketplace | -| [mudrii/openclaw-dashboard](https://github.com/mudrii/openclaw-dashboard) | **Tracking layer** — real-time metrics, costs, crons, sessions, system health | Go binary (zero deps) + embedded HTML/JS + SVG charts | Cost cards, cron status, session tracking, sub-agent activity, AI chat, system metrics (CPU/RAM/disk), 6 themes, alerts, token usage | -| [jaffer1979/openclaw-pixel-agents-dashboard](https://github.com/jaffer1979/openclaw-pixel-agents-dashboard) | **Agent visualization** — pixel-art agent sprites, real-time activity | Node/Express + Vite + React 19 + Canvas/WebSocket + JSONL parsing | Agent sprites with activity bubbles, conversation heat, spawn sub-agents, hardware monitor, service controls, day/night cycle | - ---- - -## Architecture Decision: What to Merge Into What - -**Base: openclaw-mission-control** — this becomes the foundation because: -- It has the richest data model (organizations, boards, tasks, approvals, agents, gateways, webhooks) -- It has proper auth (Clerk or local bearer token) -- It has a full API layer (FastAPI with SQLModel/SQLAlchemy) -- It has multi-tenancy built in -- It has the most mature frontend (Next.js 16 + React 19 + TanStack Query + Recharts) - -**Merge FROM dashboard** — extract the tracking/monitoring features: -- Cost tracking, token usage, model breakdown -- Cron job status, scheduling, last/next run -- Session tracking, sub-agent activity -- System health (CPU, RAM, disk, gateway status) -- AI chat panel (ask questions about your data) -- Alert system (high cost, failed crons, context usage) -- 6 themes + glass morphism UI - -**Merge FROM pixel-agents** — extract the agent visualization: -- Pixel-art agent sprites in a shared office scene -- Real-time activity bubbles, conversation heat -- Sub-agent spawning from the UI -- Hardware monitor (CPU/GPU/RAM/disk/network) -- Service controls (start/stop/restart gateway) -- Day/night cycle ambient lighting - ---- - -## Technical Analysis - -### Base Platform (openclaw-mission-control) - -**Backend:** -- Python 3.12+, FastAPI, SQLModel/SQLAlchemy, PostgreSQL, Redis -- Alembic migrations, RQ worker for webhooks -- Full OpenClaw gateway integration via WebSocket RPC (device pairing, control UI) -- Gateway methods: 60+ RPC calls for sessions, agents, cron, config, exec approvals, etc. -- Auth: Clerk JWT or local bearer token (≥50 chars) - -**Frontend:** -- Next.js 16.1.7, React 19.2, TanStack Query v5, TanStack Table v8 -- Radix UI primitives, Tailwind CSS, Recharts, React Markdown -- 40+ page routes (dashboard, boards, agents, approvals, gateways, skills, tags, etc.) -- Cypress E2E tests - -**Data Model (27 tables):** -- Organizations, users, boards, board_groups, tasks, tags, approvals -- Agents, gateways, activity_events, board_webhooks, skills -- Custom fields, task dependencies, task fingerprints -- Board memory, board group memory, onboarding - -**What it LACKS that the others have:** -- No real-time cost/token tracking -- No system health monitoring (CPU/RAM/disk) -- No cron job visualization -- No session/sub-agent activity monitoring -- No AI chat for asking about your deployment -- No pixel-art agent visualization -- No hardware monitoring -- No service controls (start/stop/restart gateway) - -### Dashboard (openclaw-dashboard) — What We Pull - -**Data Collection (Go):** -- `refresh.go` — main collector, reads OpenClaw filesystem + gateway API -- `refresh_sessions.go` — session listing, model resolution -- `refresh_tokens.go` — token usage tracking -- `cron_state` — cron job parsing and status -- `system.go` — CPU, RAM, swap, disk, gateway runtime probes - -**API Endpoints:** -- `/api/refresh` — stale-while-revalidate data.json -- `/api/chat` — AI chat via OpenClaw gateway -- `/api/system` — live host metrics -- `/api/logs` — merged log tail -- `/api/errors` — aggregated error feed - -**Frontend:** -- Pure HTML/CSS/JS (single `index.html`) — we'll rewrite as React components -- State management: 7 plain objects (State, DataLayer, DirtyChecker, Renderer, Theme, Chat, App) -- SVG chart rendering (cost trends, model breakdown, sub-agent activity) -- 6 themes with 19 CSS color variables each - -**Integration Approach:** -- Port the Go data collection to Python services that hit the OpenClaw gateway API -- Replace the embedded HTML frontend with React components in the Next.js app -- Use the existing gateway RPC connection in Mission Control's backend -- Add PostgreSQL models for tracking data (cost snapshots, cron states, session events) - -### Pixel Agents (openclaw-pixel-agents-dashboard) — What We Pull - -**Backend (Node/Express):** -- `sessionWatcher.ts` — tails JSONL session files, parses events -- `spawner.ts` — spawns sub-agents via gateway API -- `services.ts` — gateway service controls (start/stop/restart) -- `hardware.ts` — hardware stats collection -- `openclawParser.ts` — JSONL event parsing -- WebSocket broadcasting to frontend - -**Frontend (React/Vite):** -- Pixel-art canvas renderer (`OfficeCanvas.tsx`, game loop, character sprites) -- Activity bubbles, conversation heat overlays -- Spawn chat panel, session info panel -- Server rack (hardware monitor), breaker panel (service controls) -- Ham radio (update checker), fire alarm (gateway restart) - -**Integration Approach:** -- Port JSONL session watcher to Python (watch OpenClaw session directory) -- Move sub-agent spawning to use Mission Control's existing gateway RPC -- Rebuild the pixel-art canvas as a React component within Next.js -- Add WebSocket support to FastAPI for real-time agent events -- Hardware stats collected via the gateway's `health` and `status` methods - ---- - -## Implementation Plan - -### Phase 1: Foundation Setup (Week 1) - -**1.1 — Fork and Stand Up Base** -- Fork `abhi1693/openclaw-mission-control` to our org -- Stand up local dev environment (Docker Compose: Postgres + Redis + backend + frontend) -- Verify all existing features work: auth, boards, tasks, agents, gateways, approvals -- Document the data model and API surface - -**1.2 — Add Tracking Models (Backend)** -- Create new PostgreSQL models: - - `CostSnapshot` — daily cost tracking per model/gateway - - `CronJobStatus` — cron schedule, last/next run, duration, status - - `SessionEvent` — session start/stop, model, tokens, context % - - `SubAgentRun` — sub-agent spawn, cost, duration, status - - `SystemHealthMetric` — CPU, RAM, disk, swap, gateway uptime - - `AlertRule` — configurable alert thresholds -- Create Alembic migration -- Add CRUD API endpoints under `/api/monitoring/` - -**1.3 — Gateway Data Collection Service** -- Create `app/services/monitoring/gateway_collector.py` -- Reuse existing `gateway_rpc.py` to poll: - - `usage.cost` — cost data - - `usage.status` — token counts - - `cron.list` / `cron.status` — cron jobs - - `sessions.list` / `sessions.preview` — sessions - - `agents.list` — agents - - `health` — gateway health - - `status` — gateway runtime status -- Run as background task (asyncio) with configurable intervals -- Store collected data in the new models - -### Phase 2: Tracking Dashboard (Week 2) - -**2.1 — Monitoring Pages (Frontend)** -- New Next.js routes: - - `/monitoring` — main dashboard (cost cards, system health, alerts) - - `/monitoring/costs` — detailed cost breakdown with charts - - `/monitoring/sessions` — active sessions, sub-agent activity - - `/monitoring/crons` — cron job management - - `/monitoring/system` — CPU/RAM/disk/gateway health - -**2.2 — Cost Tracking UI** -- Port dashboard's cost cards and donut chart to React/Recharts -- Today's cost, all-time cost, projected monthly -- Per-model cost breakdown (7d/30d/all-time tabs) -- Cost trend line chart (SVG → Recharts) - -**2.3 — Session & Sub-Agent UI** -- Active sessions with model, type badges (DM/group/cron/subagent) -- Context % bars, token counts -- Sub-agent activity grid with cost/duration/status -- Session detail panel with conversation preview - -**2.4 — Cron Job Management** -- Cron job list with schedule, status, last/next run -- Run history with duration and status badges -- Trigger manual run from UI -- Add/edit/delete cron jobs (using existing gateway RPC) - -**2.5 — System Health** -- Gateway status card (uptime, PID, memory, compaction) -- CPU/RAM/swap/disk gauge cards (configurable thresholds) -- Alert banner for high cost, failed crons, gateway offline -- Auto-refresh with countdown timer - -**2.6 — AI Chat Panel** -- Port dashboard's AI chat to React component -- Uses OpenClaw gateway's `/v1/chat/completions` endpoint -- Context-aware: feed live monitoring data into system prompt -- Persistent chat history per user - -### Phase 3: Agent Visualization (Week 3) - -**3.1 — Pixel Agent Canvas** -- Port the pixel-art office scene to React (Canvas component) -- Agent sprites with activity state (working, idle, talking) -- Activity bubbles showing current task/conversation -- Conversation heat glow based on recent activity -- Day/night ambient cycle -- Pan/zoom controls (touch + mouse) - -**3.2 — Real-Time Agent Events** -- Add FastAPI WebSocket endpoint (`/ws/agents`) -- Port JSONL session watcher to Python: - - Watch `~/.openclaw/agents/*/sessions/*.jsonl` - - Parse events (tool calls, responses, status changes) - - Broadcast to connected WebSocket clients -- Activity ticker component (recent agent actions scrolling by) - -**3.3 — Sub-Agent Spawner** -- Spawn panel integrated into the canvas view -- Click agent → "Spawn sub-agent" button -- Mini-chat for tasking the sub-agent -- Session info panel for active sub-agents -- Uses existing `agents.create` gateway RPC - -**3.4 — Hardware Monitor & Service Controls** -- Server rack component (CPU/GPU/RAM/disk/network gauges) -- Breaker panel for gateway start/stop/restart -- Ham radio component for OpenClaw update checking -- All using existing gateway RPC methods (`health`, `status`, `update.run`) - -### Phase 4: Integration & Polish (Week 4) - -**4.1 — Navigation Integration** -- Add "Monitoring" and "Agents" sections to Mission Control sidebar -- Dashboard home page shows summary cards (cost, health, agent count) -- Deep links from monitoring → agents → pixel view - -**4.2 — Theme System** -- Port the 6 dashboard themes into Mission Control's Tailwind config -- Theme picker in header (persists via localStorage) -- Glass morphism effects where appropriate - -**4.3 — Alert System** -- Configurable alert rules (cost threshold, cron failure, context %, memory) -- Alert banner on every page when active -- Alert history in activity feed -- Notification delivery via webhooks or in-app - -**4.4 — Data Sync Strategy** -- Primary: Gateway RPC polling (configurable intervals) -- Secondary: JSONL file watching for real-time agent events -- Tertiary: REST API for manual refresh -- WebSocket push for live updates to connected browsers -- Stale-while-revalidate caching pattern - ---- - -## File Structure (Additions to Mission Control) - -``` -backend/ -├── app/ -│ ├── models/ -│ │ ├── monitoring.py # CostSnapshot, CronJobStatus, SessionEvent, etc. -│ │ └── alert_rules.py # AlertRule model -│ ├── api/ -│ │ ├── monitoring.py # Cost, session, cron endpoints -│ │ ├── monitoring_system.py # System health endpoints -│ │ └── agent_events.py # WebSocket endpoint for agent events -│ └── services/ -│ ├── monitoring/ -│ │ ├── gateway_collector.py # Polls OpenClaw gateway for data -│ │ ├── jsonl_watcher.py # Watches session JSONL files -│ │ ├── cost_tracker.py # Cost aggregation and projection -│ │ └── alert_engine.py # Alert rule evaluation -│ └── openclaw/ -│ └── (existing — no changes needed) -├── migrations/ -│ └── versions/ -│ └── xxx_add_monitoring_models.py -frontend/ -├── src/ -│ ├── app/ -│ │ ├── monitoring/ -│ │ │ ├── page.tsx # Main monitoring dashboard -│ │ │ ├── costs/page.tsx # Cost detail page -│ │ │ ├── sessions/page.tsx # Session detail page -│ │ │ ├── crons/page.tsx # Cron management page -│ │ │ └── system/page.tsx # System health page -│ │ └── agents/ -│ │ └── pixel/page.tsx # Pixel agent canvas page -│ ├── components/ -│ │ ├── monitoring/ -│ │ │ ├── CostCards.tsx -│ │ │ ├── CostTrendChart.tsx -│ │ │ ├── ModelBreakdownChart.tsx -│ │ │ ├── SessionTable.tsx -│ │ │ ├── SubAgentActivity.tsx -│ │ │ ├── CronJobList.tsx -│ │ │ ├── SystemHealthCards.tsx -│ │ │ ├── AlertBanner.tsx -│ │ │ └── AiChatPanel.tsx -│ │ ├── agents/ -│ │ │ ├── PixelCanvas.tsx -│ │ │ ├── AgentSprite.tsx -│ │ │ ├── ActivityBubble.tsx -│ │ │ ├── ConversationHeat.tsx -│ │ │ ├── SpawnPanel.tsx -│ │ │ ├── ServerRack.tsx -│ │ │ └── BreakerPanel.tsx -│ │ └── (existing Mission Control components) -│ └── lib/ -│ ├── monitoring-api.ts # API client for monitoring endpoints -│ └── agent-events.ts # WebSocket client for agent events -``` - ---- - -## Key Integration Points - -### Gateway Communication -All three projects talk to the OpenClaw gateway. Mission Control already has the richest integration (`gateway_rpc.py` with 60+ methods). We reuse this for everything: - -| Feature | Gateway Methods Used | -|---|---| -| Cost tracking | `usage.cost`, `usage.status` | -| Session monitoring | `sessions.list`, `sessions.preview` | -| Cron management | `cron.list`, `cron.status`, `cron.add`, `cron.update`, `cron.remove`, `cron.run` | -| Agent management | `agents.list`, `agents.create`, `agents.update`, `agents.delete` | -| System health | `health`, `status`, `logs.tail` | -| Sub-agent spawning | `agents.create`, `sessions.patch` | -| Service controls | `config.get`, `config.set`, `update.run` | - -### Real-Time Updates -- Dashboard uses polling (60s auto-refresh) -- Pixel agents uses WebSocket (real-time JSONL events) -- Mission Control uses TanStack Query (polling + cache invalidation) - -**Our approach:** WebSocket for agent events (real-time pixel animation), TanStack Query with 30s polling for monitoring data, SSE for alerts. - -### Auth -- Mission Control supports Clerk JWT and local bearer token -- Dashboard is auth-free (localhost only) -- Pixel agents uses gateway token - -**Our approach:** Inherit Mission Control's auth system. Local mode for self-hosted, Clerk for multi-tenant. Monitoring and agent data scoped to organization + gateway. - ---- - -## Dependency Summary - -| Layer | Technology | Source | -|---|---|---| -| Backend framework | FastAPI + SQLModel | Mission Control | -| Database | PostgreSQL + Alembic | Mission Control | -| Job queue | Redis + RQ | Mission Control | -| Frontend framework | Next.js 16 + React 19 | Mission Control | -| UI primitives | Radix UI + Tailwind | Mission Control | -| Charts | Recharts (existing) | Mission Control | -| Pixel canvas | HTML5 Canvas (new) | Pixel Agents → React port | -| WebSocket | FastAPI WebSocket (new) | Pixel Agents → Python port | -| Auth | Clerk / local bearer token | Mission Control | -| Gateway RPC | websockets Python (existing) | Mission Control | - -**No new backend languages.** Go and Node/Express are NOT added — their functionality ports to Python services within the existing FastAPI app. - ---- - -## Risk Assessment - -| Risk | Impact | Mitigation | -|---|---|---| -| Canvas rendering performance in React | Medium | Use `useRef` + `requestAnimationFrame`, not React state for animation | -| Go dashboard data collection rewritten in Python | Medium | Port logic faithfully; test against same OpenClaw data | -| JSONL file watching reliability | Medium | Use `watchdog` library + fallback polling | -| Theme system merge (6 themes × 2 systems) | Low | Map dashboard's 19 CSS vars to Tailwind config | -| Pixel assets licensing | Low | MIT licensed, attribution in ASSET-LICENSE.md | -| Gateway RPC version compatibility | Low | Already handled by protocol version negotiation in `gateway_rpc.py` | - ---- - -## Success Metrics - -1. **All monitoring features** from dashboard available in Mission Control UI -2. **Pixel agent visualization** showing real-time agent activity -3. **Single Docker Compose** brings up the entire system -4. **Single auth system** — no separate logins -5. **Single gateway connection** — reused across all features -6. **No Go or Node backend** — everything in Python/FastAPI -7. **All existing Mission Control features** still work (boards, tasks, approvals, etc.) \ No newline at end of file diff --git a/STRUCTURE.md b/STRUCTURE.md deleted file mode 100644 index a9198b3..0000000 --- a/STRUCTURE.md +++ /dev/null @@ -1,362 +0,0 @@ -# Mission Control Project Structure - -## Project Overview -Mission Control — Unified OpenClaw management platform merging three open-source dashboards into one. Python/FastAPI + PostgreSQL + Redis backend, Next.js 16 + React 19 frontend. - -**Current Version:** v0.0.2 -**Phase:** Phase 1 complete (base platform running), Phase 2 pending - -## Source Repos (Reference Only — Not Modified Directly) -``` -/tmp/mission-control-research/ -├── openclaw-mission-control/ # Base platform (Python/FastAPI + Next.js) -├── openclaw-dashboard/ # Tracking/monitoring (Go → port to Python) -└── openclaw-pixel-agents-dashboard/ # Agent visualization (Node/Express → port to Python) -``` - -## Directory Structure (Current) -``` -Mission-Control/ -├── PROJECT.md # Full project plan, phases, architecture decisions -├── STRUCTURE.md # THIS FILE — project structure and agent roles -├── FUTURE.md # Pending improvements (priority-grouped) -├── HISTORY.md # User-facing changelog (completed items only) -├── DEVELOPMENT_LOG.md # Agent work tracking -├── VERSION.md # Current version + history -├── compose.yml # Docker Compose (db + redis + backend + frontend + webhook-worker) -├── .env # Local dev environment config -├── .gitignore -├── .dockerignore -├── src/ -│ ├── backend/ # FastAPI application -│ │ ├── Dockerfile # Backend + webhook-worker container -│ │ ├── app/ -│ │ │ ├── main.py # FastAPI app entry -│ │ │ ├── models/ # SQLModel/SQLAlchemy models -│ │ │ ├── api/ # API route handlers -│ │ │ ├── services/ # Business logic -│ │ │ │ └── openclaw/ -│ │ │ │ └── gateway_rpc.py # Gateway RPC client (60+ methods) -│ │ │ └── core/ # Config, auth, deps -│ │ ├── migrations/ # Alembic migrations -│ │ ├── scripts/ # RQ worker script, utilities -│ │ └── tests/ # Backend tests -│ └── frontend/ # Next.js 16 application -│ ├── src/ -│ │ ├── app/ # Next.js App Router pages -│ │ ├── components/ # React components -│ │ └── lib/ # API clients, utilities -│ └── public/ # Static assets -├── sources/ # Cloned source repos (reference only) -└── docs/ # Documentation (Engineering Reference Manual — requires explicit user initiation) -``` - -## Critical Notes for Agents - -### Backend Code Location -**ALL backend code is in `src/backend/`:** -- Entry: `src/backend/app/main.py` -- Models: `src/backend/app/models/*.py` -- API: `src/backend/app/api/*.py` -- Services: `src/backend/app/services/**/*.py` -- Migrations: `src/backend/migrations/` -- Gateway RPC: `src/backend/app/services/openclaw/gateway_rpc.py` - -### Frontend Code Location -**ALL frontend code is in `src/frontend/`:** -- Pages: `src/frontend/src/app/**/page.tsx` -- Components: `src/frontend/src/components/**/*.tsx` -- API client: `src/frontend/src/lib/` -- WebSocket client: `src/frontend/src/lib/agent-events.ts` - -### Porting Rules -- **No Go.** All dashboard data collection ports to Python services. -- **No Node/Express.** All pixel-agents functionality ports to Python/FastAPI. -- **Reuse existing gateway RPC.** Mission Control already has `gateway_rpc.py` with 60+ methods. -- **React for all UI.** No embedded HTML/JS — everything becomes React components. - -### Docker Setup -- **Backend port:** 8080 (host) → 8000 (container) -- **Frontend port:** 3080 (host) → 3000 (container) -- **Auth mode:** local (bearer token, see `.env` for `LOCAL_AUTH_TOKEN`) -- **Database:** PostgreSQL 16 Alpine on port 5432 -- **Redis:** Redis 7 Alpine on port 6379 -- **4 services:** db, redis, backend, frontend, webhook-worker -- **97 API endpoints** verified operational - -### Test Procedure -```bash -cd /home/kaspa/.openclaw/Projects/Mission-Control - -# Start services -docker compose up -d --build - -# Verify backend health -curl -s http://localhost:8080/api/health | python3 -m json.tool - -# Verify frontend -curl -s -o /dev/null -w "%{http_code}" http://localhost:3080 - -# Stop services -docker compose down -``` - -## Agent Review Roles - -| Agent | Role | Focus Area | -|-------|------|------------| -| Neo | Backend / System Architecture | FastAPI services, models, migrations, gateway RPC, data collection, API endpoints | -| Scarlett | UI/UX / Frontend | Next.js pages, React components, Radix UI + Tailwind styling, pixel canvas, charts, themes | -| Bishop | Analysis / Code Quality | Architecture review, code quality, dependency review, version bumps, documentation | -| Private_Hudson | Security / Compliance | Auth flows, data protection, input validation, OWASP, dependency vulnerabilities | - -### Cross-Cutting Concerns -All agents must be aware of: -- **Auth**: Clerk JWT or local bearer token — scoped to organization + gateway -- **Gateway RPC**: `gateway_rpc.py` is the single source of truth for all OpenClaw API calls -- **Data Models**: PostgreSQL + SQLModel with Alembic migrations -- **Real-Time**: WebSocket for agent events, TanStack Query polling for monitoring data -- **Theme System**: 6 themes with CSS variables mapped to Tailwind config - -# OpenClaw Agent Structure - -## Prime - -Role: - -* executive coordinator -* project strategist -* Discord command interface - -Responsibilities: - -* **Overall Oversight:** Must maintain high-level awareness of all concurrent projects, ensuring every agent's output aligns with the goal set in `PROJECT.md`. -* **Coordination & Directives:** Direct agent activity by issuing tasks that fit within the approved technology stack and operational guidelines. -* **Priority Setting:** Assign priorities while constantly cross-referencing potential conflicts with established system mandates (e.g., Security > Performance > Feature). -* **Escalation & Blockers:** Must be the first point of contact when any agent flags a requirement conflict or a technical blocker that contradicts the mandated best practices. -* **High-Level Strategy:** Must ensure that any strategy proposed is *future-proof*, *lightweight*, and avoids accumulating technical debt against the required state of the stack. -* **Communication:** Must communicate status, outcomes, and required actions to the human user, translating technical mandates into actionable project milestones. - -Authority: - -* project coordination and task routing. -* Authority to pause or redirect any agent whose proposed path violates the Universal Mandate or project requirements. - ---- - -## Ripley - -Role: - -* operations -* infrastructure -* runtime management - -Responsibilities: - -* deployment oversight, adhering to stability and resilience standards. -* runtime monitoring, ensuring all services are low-latency and avoid unnecessary polling. -* infrastructure coordination, guaranteeing that all components use the approved stack. -* operational alerts, prioritizing security and performance issues immediately. -* service stability, adhering to the "fail gracefully" principle. -* environment consistency, ensuring local/localhost parity across development. -* operational communication, must be precise and action-oriented. -* **Git ownership:** Only Ripley commits, pushes, and deploys. No other agent touches git. - -Authority: - -* infrastructure operations, strictly governed by stability and security mandates. -* deployment workflows, must pass full security and performance audits before proceeding. -* runtime diagnostics, must use established, non-bloated tooling. -* operational communication, must be precise and action-oriented. - ---- - -## Neo - -Role: - -* senior backend developer -* backend architecture lead - -Responsibilities: - -* **Mandatory Adherence:** Must treat `PROJECT.md` and `STRUCTURE.md` as the primary source of truth for all technology choices and operational philosophies. -* **Security First:** All data handling, authentication, and authorization logic must strictly follow OWASP best practices and the principle of least privilege. -* **Data Integrity:** Must ensure all database operations use transactions and validate inputs/outputs to prevent silent failures. -* **Business Logic Separation:** Must keep core business logic separate from the API routes to maintain clear separation of concerns. -* **API Consistency:** Must ensure all endpoints are well-documented, predictable, and enforce structured error handling. -* **Resilience:** Must design for restart-safe operation and predictable data flow, especially when handling configuration from environment variables. - -Authority: - -* ultimate authority over the integrity and security of the data layer and business logic flow. -* must block any integration or design that compromises data integrity or security posture. - ---- - -## Scarlett - -Role: - -* frontend developer -* UI design authority - -Responsibilities: - -* **Mandatory Adherence:** Must treat `PROJECT.md` and `STRUCTURE.md` as the primary source of truth for UI/UX. -* **Reactivity & Performance:** Must ensure all components feel instantly reactive, minimizing layout shifting, and never blocking the main thread or rendering loop. -* **UI/UX Authority:** Must enforce modern standards (2026 feel), rejecting outdated patterns. -* **Component Purity:** Must use Radix UI + shadcn/ui components consistently and build complex logic in modular, clean ways. -* **Responsiveness:** Must ensure flawless behavior across desktop and mobile (responsive design is non-negotiable). -* **Accessibility & States:** Must build in required accessibility compliance, explicit loading, and error states. -* **Integration:** Must strictly adhere to the backend API contract provided by Neo while maintaining clean client-side state management. - -Technology Focus: - -* **Next.js 16 + React 19** is the frontend framework (App Router, server components where appropriate). -* **Radix UI + shadcn/ui** is the foundational component library — always use shadcn/ui components for UI primitives. -* **Tailwind CSS** must be used predictably to maintain consistency. -* **Recharts** for charts and data visualization. -* **TanStack Query v5** for server state management. - -Authority: - -* UI architecture and frontend interaction flows. -* Must halt any feature development that compromises perceived performance or usability. - ---- - -## Bishop - -Role: - -* code reviewer -* architecture validator -* documentation owner - -Responsibilities: - -* Must enforce adherence to `PROJECT.md` and `STRUCTURE.md` standards across the entire lifecycle. -* **Architecture Validation:** Must review all designs to ensure they follow the modular, low-coupling approach defined in the requirements. -* **Code Quality Review:** Beyond syntax, must audit for architectural flaws, overengineering, and non-compliance with best practices. -* **Standard Enforcement:** Must enforce the use of approved components and discourage workarounds or non-approved patterns. -* **Version Bumps:** Bishop owns version bumps as part of every verification. Determines version number and scope. -* **Documentation:** Bishop maintains `HISTORY.md` and `VERSION.md`. Does NOT create the Engineering Reference Manual unless explicitly initiated by the user. -* **Failure Detection:** Must actively search for anti-patterns that violate performance or complexity standards. - -Authority: - -* approve or reject code quality based *only* on adherence to established standards. -* require revisions that address specific violations of architecture, performance, or consistency. -* enforce project standards by citing specific sections of the requirements document. - ---- - -## Private Hudson - -Role: - -* security reviewer -* defensive operations specialist - -Responsibilities: - -* OWASP validation -* authentication security review -* authorization validation -* dependency vulnerability auditing -* secret exposure detection -* injection vulnerability analysis -* security hardening review -* infrastructure security analysis -* runtime security assessment - -Authority: - -* approve or reject security posture -* block insecure deployments -* require remediation before release - ---- - -## Universal Mandate - -**All agents are governed by the guidelines set in `PROJECT.md` and `STRUCTURE.md`.** Every decision, design choice, and implementation detail must strictly adhere to the philosophy, technology stack, standards, and policies defined in those files. Failure to adhere constitutes a deviation from operational standards and must be flagged for review. - -**Mandatory Adherence Checklist:** -1. **Always** refer to `PROJECT.md` and `STRUCTURE.md` for the definitive ruleset. -2. Never implement functionality that contradicts the approved Tech Stack (Python/FastAPI, PostgreSQL, Redis, Next.js 16, React 19, Radix UI, Tailwind CSS, Recharts). -3. Treat security and performance checks as *primary* considerations, not secondary checks. -4. **No Go.** No Go code in this project — all Go functionality ports to Python. -5. **No Node/Express.** No Express server code — all backend logic goes through FastAPI. -6. **Only Ripley touches git.** No other agent commits, pushes, or deploys. - ---- - -## Development Pipeline - -All code changes follow this pipeline: - -``` -Neo (code) → Bishop (verify + bump) → Private_Hudson (security audit) → Ripley (commit/push/deploy) -``` - -- **Neo** writes the code. -- **Bishop** verifies it works (build + runtime test), bumps the version, updates HISTORY.md. -- **Private_Hudson** audits for security issues. -- **Ripley** commits, pushes to `dev` branch, and deploys the Docker image. - -For small surgical fixes, Ripley may make changes directly without dispatching an agent. - -## Agent Dispatch Protocol - -Subagents run in **isolated sessions** — they start with zero context. When spawning any specialist, always include a context block at the top of the `task` string: - -``` -Project: Mission Control -Project dir: Projects/Mission-Control/ (symlinked in your workspace root) -Spec: read Projects/Mission-Control/PROJECT.md and STRUCTURE.md before starting -Prime workspace: _prime/ (briefing docs, templates, shared memory) -Recent changes: -- v0.0.2: Base platform forked, Docker Compose running, 97 API endpoints verified - -[task instructions] -``` - -**Shared paths available in every agent workspace:** -- `Projects/` → `/home/kaspa/.openclaw/Projects/` -- `_prime/` → `/home/kaspa/.openclaw/agent-workspace/Prime/` - -If a spec or briefing exists, drop it in Prime's workspace so agents find it at `_prime/`. Never assume context carries over from a prior session. - -⚠️ **Always set `agentId` explicitly when spawning.** Omitting it defaults to `main` (Ripley's agent), which loads the wrong workspace and identity files. - -| Agent | agentId | -|---|---| -| Prime | `prime` | -| Neo | `neo` | -| Scarlett | `scarlett` | -| Bishop | `bishop` | -| Private_Hudson | `private_hudson` | - -## Technology Stack - -| Layer | Technology | Notes | -|-------|-----------|-------| -| Backend | Python 3.12+ / FastAPI | Existing | -| Database | PostgreSQL + SQLModel | Existing | -| Migrations | Alembic | Existing | -| Job Queue | Redis + RQ | Existing | -| Frontend | Next.js 16 + React 19 | Existing | -| UI | Radix UI + Tailwind CSS | Existing | -| Charts | Recharts | Existing | -| Pixel Canvas | HTML5 Canvas | New — ported from pixel-agents | -| WebSocket | FastAPI WebSocket | New — ported from pixel-agents | -| Auth | Clerk / local bearer token | Existing | - -**No new backend languages.** Go and Node/Express are NOT added to this project. - ---- - -*Updated by Ripley for Mission Control project* \ No newline at end of file diff --git a/src/frontend/.dockerignore b/src/frontend/.dockerignore deleted file mode 100644 index 2ad8800..0000000 --- a/src/frontend/.dockerignore +++ /dev/null @@ -1,9 +0,0 @@ -node_modules -.next -coverage -cypress/screenshots -cypress/videos -npm-debug.log* -.env -.env.* -.git diff --git a/src/frontend/.env.example b/src/frontend/.env.example index c5f1ad1..1639013 100644 --- a/src/frontend/.env.example +++ b/src/frontend/.env.example @@ -1,14 +1,21 @@ -# Base URL for frontend -> backend calls. -# Use `auto` to target the same host currently serving Mission Control on port 8000. -# Example explicit override: https://mc.example.com -NEXT_PUBLIC_API_URL=auto +# Admin credentials for Mission Control +ADMIN_PASSWORD=change-me-to-a-strong-password +AUTH_SECRET=generate-a-random-32-char-string-here -# Auth mode: clerk or local. -# - clerk: Clerk sign-in flow -# - local: shared bearer token entered in UI -NEXT_PUBLIC_AUTH_MODE=local +# OpenClaw paths (defaults shown - override if your setup differs) +# OPENCLAW_DIR=/root/.openclaw +# OPENCLAW_WORKSPACE=/root/.openclaw/workspace -# Clerk auth (used when NEXT_PUBLIC_AUTH_MODE=clerk) -NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY= -NEXT_PUBLIC_CLERK_SIGN_IN_FALLBACK_REDIRECT_URL=/boards -NEXT_PUBLIC_CLERK_AFTER_SIGN_OUT_URL=/ +# Branding (customize for your instance) +NEXT_PUBLIC_AGENT_NAME=Mission Control +NEXT_PUBLIC_AGENT_EMOJI=🤖 +NEXT_PUBLIC_AGENT_DESCRIPTION=Your AI co-pilot, powered by OpenClaw +NEXT_PUBLIC_AGENT_LOCATION= +NEXT_PUBLIC_BIRTH_DATE= +NEXT_PUBLIC_AGENT_AVATAR= +NEXT_PUBLIC_OWNER_USERNAME=your-username +NEXT_PUBLIC_OWNER_EMAIL=your-email@example.com +NEXT_PUBLIC_OWNER_COLLAB_EMAIL=collabs@example.com +NEXT_PUBLIC_TWITTER_HANDLE=@username +NEXT_PUBLIC_COMPANY_NAME=MISSION CONTROL, INC. +NEXT_PUBLIC_APP_TITLE=Mission Control diff --git a/src/frontend/.gitattributes b/src/frontend/.gitattributes new file mode 100644 index 0000000..54b2486 --- /dev/null +++ b/src/frontend/.gitattributes @@ -0,0 +1,39 @@ +# Auto detect text files and perform LF normalization +* text=auto + +# Source code +*.ts text eol=lf +*.tsx text eol=lf +*.js text eol=lf +*.jsx text eol=lf +*.json text eol=lf +*.md text eol=lf +*.css text eol=lf +*.html text eol=lf + +# Scripts +*.sh text eol=lf + +# Images +*.png binary +*.jpg binary +*.jpeg binary +*.gif binary +*.ico binary +*.svg text + +# Fonts +*.woff binary +*.woff2 binary +*.ttf binary +*.otf binary + +# Archives +*.zip binary +*.tar binary +*.gz binary + +# Database +*.db binary +*.sqlite binary +*.sqlite3 binary diff --git a/src/frontend/.gitignore b/src/frontend/.gitignore index 162a0ac..7b1f43d 100644 --- a/src/frontend/.gitignore +++ b/src/frontend/.gitignore @@ -1,10 +1,55 @@ -node_modules/ -.next/ -.env.local -.env -out/ -dist/ +# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. -# clerk configuration (can include secrets) -/.clerk/ +# dependencies +/node_modules +/.pnp +.pnp.* +.yarn/* +!.yarn/patches +!.yarn/plugins +!.yarn/releases +!.yarn/versions + +# testing +/coverage + +# next.js +/.next/ +/out/ + +# production +/build + +# misc +.DS_Store +*.pem + +# debug +npm-debug.log* +yarn-debug.log* +yarn-error.log* +.pnpm-debug.log* + +# env files (contains sensitive credentials) +.env* +!.env.example + +# production data (contains instance-specific operational data) +/data/*.json +!data/*.example.json +/data/*.db +/data/*.sqlite +/data/*.sqlite3 + +# vercel +.vercel + +# typescript +*.tsbuildinfo next-env.d.ts + +# design files (local only) +/design/ + +# backup files +*.bak diff --git a/src/frontend/CONTRIBUTING.md b/src/frontend/CONTRIBUTING.md new file mode 100644 index 0000000..4e123b9 --- /dev/null +++ b/src/frontend/CONTRIBUTING.md @@ -0,0 +1,369 @@ +# Contributing to Mission Control + +Thank you for your interest in contributing! 🦞 + +## Getting Started + +1. Fork the repository +2. Clone your fork: `git clone https://github.com/YOUR-USERNAME/mission-control.git` +3. Create a branch: `git checkout -b feature/your-feature-name` +4. Make your changes +5. Test thoroughly +6. Commit with clear messages +7. Push and create a Pull Request + +## Development Setup + +See [README.md](./README.md#quick-start) for setup instructions. + +**TL;DR:** +```bash +npm install +cp .env.example .env.local +# Edit .env.local with your config +npm run dev +``` + +## Code Guidelines + +### File Organization + +- **Components**: `src/components/` - Reusable UI components +- **Pages**: `src/app/` - Next.js App Router pages +- **APIs**: `src/app/api/` - API route handlers +- **Config**: `src/config/` - Configuration files (branding, constants) +- **Lib**: `src/lib/` - Utilities, helpers, and libraries +- **Data**: `data/` - JSON data files (gitignored, use `.example` versions) + +### Naming Conventions + +- **Components**: PascalCase (`ActivityFeed.tsx`) +- **Utilities**: camelCase (`pricing.ts`, `usage-queries.ts`) +- **API Routes**: kebab-case folders (`/api/cron-jobs/`) +- **Config**: camelCase with SCREAMING_SNAKE for constants + +### TypeScript + +- Use TypeScript for all new code +- Define interfaces for data structures +- Avoid `any` - use `unknown` if type is truly unknown +- Export types alongside components + +Example: +```typescript +export interface AgentStatus { + agentId: string; + status: 'idle' | 'working' | 'error'; + model?: string; +} + +export function AgentCard({ agent }: { agent: AgentStatus }) { + // ... +} +``` + +### React Components + +- Use functional components with hooks +- Prefer `'use client'` for interactive components +- Keep components small and focused +- Extract logic into custom hooks when complex + +Example: +```typescript +'use client'; + +import { useState, useEffect } from 'react'; + +export function MyComponent() { + const [data, setData] = useState([]); + + useEffect(() => { + fetchData().then(setData); + }, []); + + return
{/* ... */}
; +} +``` + +### Styling + +- Use Tailwind CSS v4 utility classes +- Use CSS variables for theming (see `globals.css`) +- Avoid inline styles except for dynamic values +- Use `className` over `style` when possible + +Theme variables: +```css +--background: #000000; +--text-primary: #FFFFFF; +--accent: #FFCC00; +/* See src/app/globals.css for full list */ +``` + +### API Routes + +- Return `NextResponse.json()` for all API routes +- Use HTTP status codes correctly (200, 400, 404, 500) +- Handle errors gracefully with try/catch +- Validate input data + +Example: +```typescript +import { NextResponse } from 'next/server'; + +export async function GET(request: Request) { + try { + const data = await fetchData(); + return NextResponse.json(data); + } catch (error) { + console.error('Error fetching data:', error); + return NextResponse.json( + { error: 'Failed to fetch data' }, + { status: 500 } + ); + } +} +``` + +## Privacy & Security + +### 🚨 CRITICAL: No Personal Data in Commits + +**NEVER commit:** +- `.env.local` (contains passwords, secrets) +- `data/*.json` (contains operational data) +- `data/*.db` (contains usage metrics) +- Personal usernames, emails, API keys, tokens +- Screenshot with real data (use mock data or blur) + +**Use instead:** +- `.env.example` (with placeholder values) +- `data/*.example.json` (with example data) +- `BRANDING` config (via environment variables) + +### Checking for Leaks + +Before committing, run: + +```bash +# Check for hardcoded personal data +grep -r "your-real-username" src/ +grep -r "your-email@example.com" src/ +grep -r "password\|secret\|token" .env.local + +# Ensure .gitignore is working +git status +# Should NOT show .env.local or data/*.json +``` + +### Branding + +Use the `BRANDING` config from `src/config/branding.ts` instead of hardcoding: + +**❌ Bad:** +```typescript +const username = "@carlosazaustre"; +``` + +**✅ Good:** +```typescript +import { BRANDING } from "@/config/branding"; +const username = BRANDING.twitterHandle; +``` + +## Testing + +### Manual Testing Checklist + +Before submitting a PR: + +- [ ] Build succeeds: `npm run build` +- [ ] No TypeScript errors: `tsc --noEmit` +- [ ] No ESLint errors: `npm run lint` +- [ ] Tested in dev mode: `npm run dev` +- [ ] Tested in production mode: `npm run build && npm start` +- [ ] Responsive design works (mobile, tablet, desktop) +- [ ] Dark mode looks good (default theme) +- [ ] No console errors in browser +- [ ] No hardcoded personal data + +### Feature Testing + +For new features: + +1. Test happy path (normal usage) +2. Test edge cases (empty data, large datasets, etc.) +3. Test error handling (network failures, invalid input) +4. Test on different screen sizes +5. Update `IMPLEMENTATION-STATUS.md` + +## Commit Messages + +Use clear, descriptive commit messages: + +**Format:** +``` +: + + + + +``` + +**Types:** +- `feat:` New feature +- `fix:` Bug fix +- `docs:` Documentation changes +- `style:` Code formatting (no logic change) +- `refactor:` Code restructuring (no behavior change) +- `perf:` Performance improvements +- `test:` Adding or updating tests +- `chore:` Maintenance tasks + +**Examples:** +``` +feat: add real-time cost tracking with SQLite + +Implemented usage collector that reads openclaw status, +calculates costs, and stores in SQLite database. + +Closes #42 +``` + +``` +fix: prevent notification dropdown from closing on click inside + +Added stopPropagation to prevent event bubbling when +clicking notification items. +``` + +## Pull Request Process + +1. **Update documentation** + - Update README.md if adding features + - Update IMPLEMENTATION-STATUS.md with completion status + - Add docstrings to new functions/components + +2. **Keep PRs focused** + - One feature/fix per PR + - Don't mix refactoring with new features + - Keep diffs small and reviewable + +3. **PR Description Template** + ```markdown + ## What does this PR do? + Brief description of changes. + + ## Type of change + - [ ] Bug fix + - [ ] New feature + - [ ] Documentation update + - [ ] Refactoring + + ## Testing + - [ ] Tested locally in dev mode + - [ ] Tested locally in production mode + - [ ] No console errors + - [ ] Responsive design verified + + ## Screenshots (if UI change) + [Add screenshots here] + + ## Related Issues + Closes #[issue number] + ``` + +4. **Review Process** + - Address reviewer feedback + - Keep discussion respectful and constructive + - Be patient - reviews may take a few days + +## Documentation + +When adding features: + +1. **Code Comments**: Explain WHY, not WHAT + ```typescript + // ❌ Bad + // Increment counter + counter++; + + // ✅ Good + // Reset counter after 100 to prevent overflow + if (counter >= 100) counter = 0; + ``` + +2. **JSDoc for Functions** + ```typescript + /** + * Calculate cost based on token usage and model pricing + * @param modelId - Model identifier (e.g., "anthropic/claude-opus-4-6") + * @param inputTokens - Number of input tokens used + * @param outputTokens - Number of output tokens generated + * @returns Total cost in USD + */ + export function calculateCost( + modelId: string, + inputTokens: number, + outputTokens: number + ): number { + // ... + } + ``` + +3. **README Updates**: Add to README.md if: + - New API endpoint + - New configuration option + - New dependency + - Breaking change + +## Reporting Bugs + +Use GitHub Issues with this template: + +```markdown +**Describe the bug** +Clear description of what's wrong. + +**To Reproduce** +1. Go to '...' +2. Click on '...' +3. See error + +**Expected behavior** +What should happen instead. + +**Screenshots** +If applicable. + +**Environment** +- OS: [e.g., Ubuntu 22.04] +- Node version: [e.g., 22.0.0] +- OpenClaw version: [e.g., 2026.2.19] +- Browser: [e.g., Chrome 120] + +**Additional context** +Any other relevant info. +``` + +## Feature Requests + +Feature requests are welcome! Use GitHub Issues with: + +- **Use case**: Why is this needed? +- **Proposed solution**: How should it work? +- **Alternatives**: Other ways to solve the problem? +- **Priority**: Nice-to-have vs critical + +Check [ROADMAP.md](./ROADMAP.md) first - it might already be planned! + +## Questions? + +- **Discord**: [OpenClaw Community](https://discord.com/invite/clawd) +- **GitHub Discussions**: For general questions +- **GitHub Issues**: For bug reports and feature requests + +--- + +Thank you for contributing! 🦞✨ diff --git a/src/frontend/Dockerfile b/src/frontend/Dockerfile deleted file mode 100644 index 09bf681..0000000 --- a/src/frontend/Dockerfile +++ /dev/null @@ -1,50 +0,0 @@ -# syntax=docker/dockerfile:1 - -FROM node:20-alpine AS deps -WORKDIR /app - -COPY package.json package-lock.json ./ -RUN npm ci - -FROM node:20-alpine AS builder -WORKDIR /app - -COPY --from=deps /app/node_modules ./node_modules -COPY . ./ - -# Allows configuring the API URL at build time. -ARG NEXT_PUBLIC_API_URL=auto -ENV NEXT_PUBLIC_API_URL=${NEXT_PUBLIC_API_URL} -ARG NEXT_PUBLIC_AUTH_MODE -ENV NEXT_PUBLIC_AUTH_MODE=${NEXT_PUBLIC_AUTH_MODE} - -RUN npm run build - -FROM node:20-alpine AS runner -WORKDIR /app - -ENV NODE_ENV=production -ARG NEXT_PUBLIC_AUTH_MODE - -# If provided at runtime, Next will expose NEXT_PUBLIC_* to the browser as well -# (but note some values may be baked at build time). -ENV NEXT_PUBLIC_API_URL=auto -ENV NEXT_PUBLIC_AUTH_MODE=${NEXT_PUBLIC_AUTH_MODE} - -# Create non-root user before COPY so --chown can reference it. -# Using COPY --chown avoids a slow recursive chown on overlay2 (docker/for-linux#388). -RUN addgroup -S appgroup && adduser -S -G appgroup appuser \ - && chown appuser:appgroup /app - -COPY --from=builder --chown=appuser:appgroup /app/.next ./.next -# `public/` is optional in Next.js apps; repo may not have it. -# Avoid failing the build when the directory is absent. -COPY --from=builder --chown=appuser:appgroup /app/package.json ./package.json -COPY --from=builder --chown=appuser:appgroup /app/node_modules ./node_modules -COPY --from=builder --chown=appuser:appgroup /app/next.config.ts ./next.config.ts - -USER appuser - -EXPOSE 3000 - -CMD ["npm", "run", "start"] diff --git a/src/frontend/LICENSE b/src/frontend/LICENSE new file mode 100644 index 0000000..2eed843 --- /dev/null +++ b/src/frontend/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2026 Mission Control Contributors + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/src/frontend/README.md b/src/frontend/README.md index a80e069..7e58348 100644 --- a/src/frontend/README.md +++ b/src/frontend/README.md @@ -1,178 +1,408 @@ -# Mission Control Frontend (`frontend/`) +# TenacitOS — Mission Control -This package is the **Next.js** web UI for OpenClaw Mission Control. +A real-time dashboard and control center for [OpenClaw](https://openclaw.ai) AI agent instances. Built with Next.js, React 19, and Tailwind CSS v4. -- Talks to the Mission Control **backend** over HTTP (typically `http://localhost:8000`). -- Uses **React Query** for data fetching. -- Supports two auth modes: - - **local** shared bearer token mode (self-host default) - - **clerk** mode +> **TenacitOS** lives inside your OpenClaw workspace and reads its configuration, agents, sessions, memory, and logs directly from the host. No extra database or backend required — OpenClaw is the backend. -## Prerequisites +--- -- Node.js (recommend **18+**) and npm -- Backend running locally (see `../backend/README.md` if present) **or** run the stack via Docker Compose from repo root. +## Features -## Local development +- **📊 System Monitor** — Real-time VPS metrics (CPU, RAM, Disk, Network) + PM2/Docker status +- **🤖 Agent Dashboard** — All agents, their sessions, token usage, model, and activity status +- **💰 Cost Tracking** — Real cost analytics from OpenClaw sessions (SQLite) +- **⏰ Cron Manager** — Visual cron manager with weekly timeline, run history, and manual triggers +- **📋 Activity Feed** — Real-time log of agent actions with heatmap and charts +- **🧠 Memory Browser** — Explore, search, and edit agent memory files +- **📁 File Browser** — Navigate workspace files with preview and in-browser editing +- **🔎 Global Search** — Full-text search across memory and workspace files +- **🔔 Notifications** — Real-time notification center with unread badge +- **🏢 Office 3D** — Interactive 3D office with one desk per agent (React Three Fiber) +- **📺 Terminal** — Read-only terminal for safe status commands +- **🔐 Auth** — Password-protected with rate limiting and secure cookie -From `frontend/`: +--- + +## Screenshots + +**Dashboard** — activity overview, agent status, and weather widget + +![Dashboard](./docs/screenshots/dashboard.jpg) + +**Session History** — all OpenClaw sessions with token usage and context tracking + +![Sessions](./docs/screenshots/sessions.jpg) + +**Costs & Analytics** — daily cost trends and breakdown per agent + +![Costs](./docs/screenshots/costs.jpg) + +**System Monitor** — real-time CPU, RAM, Disk, and Network metrics + +![System Monitor](./docs/screenshots/system.jpg) + +**Office 3D** — interactive 3D office with one voxel avatar per agent (React Three Fiber) + +![Office 3D](./docs/screenshots/office3d.jpg) + +--- + +## Requirements + +- **Node.js** 18+ (tested with v22) +- **[OpenClaw](https://openclaw.ai)** installed and running on the same host +- **PM2** or **systemd** (recommended for production) +- **Caddy** or another reverse proxy (for HTTPS in production) + +--- + +## How it works + +TenacitOS reads directly from your OpenClaw installation: + +``` +/root/.openclaw/ ← OPENCLAW_DIR (configurable) +├── openclaw.json ← agents list, channels, models config +├── workspace/ ← main agent workspace (MEMORY.md, SOUL.md, etc.) +├── workspace-studio/ ← sub-agent workspaces +├── workspace-infra/ +├── ... +└── workspace/mission-control/ ← TenacitOS lives here +``` + +The app uses `OPENCLAW_DIR` to locate `openclaw.json` and all workspaces. **No manual agent configuration needed** — agents are auto-discovered from `openclaw.json`. + +--- + +## Installation + +### 1. Clone into your OpenClaw workspace ```bash +cd /root/.openclaw/workspace # or your OPENCLAW_DIR/workspace +git clone https://github.com/carlosazaustre/tenacitOS.git mission-control +cd mission-control npm install - -# set env vars (see below) -cp .env.example .env.local - -npm run dev ``` -Open http://localhost:3000. - -### LAN development - -To bind Next dev server to all interfaces: +### 2. Configure environment ```bash -npm run dev:lan +cp .env.example .env.local ``` -## Environment variables - -The frontend reads configuration from standard Next.js env files (`.env.local`, `.env`, etc.). - -### Required - -#### `NEXT_PUBLIC_API_URL` - -Base URL of the backend API (or `auto`). - -- Default: `auto` (resolved in browser as `http(s)://:8000`) -- Used by the generated API client and helpers (see `src/lib/api-base.ts` and `src/api/mutator.ts`). - -Example: +Edit `.env.local`: ```env -NEXT_PUBLIC_API_URL=auto +# --- Auth (required) --- +# Strong password to log in to the dashboard +ADMIN_PASSWORD=your-secure-password-here + +# Random secret used to sign the auth cookie +# Generate with: openssl rand -base64 32 +AUTH_SECRET=your-random-32-char-secret-here + +# --- OpenClaw paths (optional — defaults work for standard installs) --- +# OPENCLAW_DIR=/root/.openclaw + +# --- Branding (customize for your instance) --- +NEXT_PUBLIC_AGENT_NAME=Mission Control +NEXT_PUBLIC_AGENT_EMOJI=🤖 +NEXT_PUBLIC_AGENT_DESCRIPTION=Your AI co-pilot, powered by OpenClaw +NEXT_PUBLIC_AGENT_LOCATION= # e.g. "Madrid, Spain" +NEXT_PUBLIC_BIRTH_DATE= # ISO date, e.g. "2026-01-01" +NEXT_PUBLIC_AGENT_AVATAR= # path to image in /public, e.g. "/avatar.jpg" + +NEXT_PUBLIC_OWNER_USERNAME=your-username +NEXT_PUBLIC_OWNER_EMAIL=your-email@example.com +NEXT_PUBLIC_TWITTER_HANDLE=@username +NEXT_PUBLIC_COMPANY_NAME=MISSION CONTROL, INC. +NEXT_PUBLIC_APP_TITLE=Mission Control ``` -### Authentication mode +> **Tip:** `OPENCLAW_DIR` defaults to `/root/.openclaw`. If your OpenClaw is installed elsewhere, set this variable. -Set `NEXT_PUBLIC_AUTH_MODE` to one of: - -- `local` (default for self-host) -- `clerk` - -For `local` mode: - -- users enter the token in the local login screen -- requests use that token as `Authorization: Bearer ...` - -For `clerk` mode, configure: - -- `NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY` -- optional `NEXT_PUBLIC_CLERK_SIGN_IN_FALLBACK_REDIRECT_URL` -- optional `NEXT_PUBLIC_CLERK_AFTER_SIGN_OUT_URL` - -## How the frontend talks to the backend - -### API base URL - -The client builds URLs using `NEXT_PUBLIC_API_URL` (normalized to remove trailing slashes). - -### Generated API client (Orval + React Query) - -We generate a typed client from the backend OpenAPI schema using **Orval**: - -- Config: `orval.config.ts` -- Output: `src/api/generated/*` -- Script: `npm run api:gen` - -By default, Orval reads: - -- `ORVAL_INPUT` (if set), otherwise -- `http://127.0.0.1:8000/openapi.json` - -Example: +### 3. Initialize data files ```bash -# from frontend/ -ORVAL_INPUT=http://localhost:8000/openapi.json npm run api:gen +cp data/cron-jobs.example.json data/cron-jobs.json +cp data/activities.example.json data/activities.json +cp data/notifications.example.json data/notifications.json +cp data/configured-skills.example.json data/configured-skills.json +cp data/tasks.example.json data/tasks.json ``` -### Auth header / Clerk token injection - -All Orval-generated requests go through the custom mutator (`src/api/mutator.ts`). -It will: - -- set `Content-Type: application/json` when there is a body and you didn’t specify a content type -- add `Authorization: Bearer ` automatically from local mode token or Clerk session -- parse errors into an `ApiError` with status + parsed response body - -## Mobile / responsive UI validation - -When changing UI intended to be mobile-ready, validate in Chrome (or similar) using the device toolbar at common widths (e.g. **320px**, **375px**, **768px**). - -Quick checklist: - -- No horizontal scroll -- Primary actions reachable without precision taps -- Focus rings visible when tabbing -- Modals/popovers not clipped - -## Common commands - -From `frontend/`: +### 4. Generate secrets ```bash -npm run dev # start dev server -npm run build # production build -npm run start # run the built app -npm run lint # eslint -npm run test # vitest (with coverage) -npm run test:watch # watch mode -npm run api:gen # regenerate typed API client via Orval +# Auth secret +openssl rand -base64 32 + +# Password (or use a password manager) +openssl rand -base64 18 ``` -## Docker +### 5. Run -There is a `frontend/Dockerfile` used by the root `compose.yml`. +```bash +# Development +npm run dev +# → http://localhost:3000 -If you’re working on self-hosting, prefer running compose from the repo root so the backend/db are aligned with the documented ports/env. +# Production build +npm run build +npm start +``` + +Login at `http://localhost:3000` with the `ADMIN_PASSWORD` you set. + +--- + +## Production Deployment + +### PM2 (recommended) + +```bash +npm run build + +pm2 start npm --name "mission-control" -- start +pm2 save +pm2 startup # enable auto-restart on reboot +``` + +### systemd + +Create `/etc/systemd/system/mission-control.service`: + +```ini +[Unit] +Description=TenacitOS — OpenClaw Mission Control +After=network.target + +[Service] +Type=simple +User=root +WorkingDirectory=/root/.openclaw/workspace/mission-control +ExecStart=/usr/bin/npm start +Restart=always +RestartSec=10 +Environment=NODE_ENV=production + +[Install] +WantedBy=multi-user.target +``` + +```bash +sudo systemctl daemon-reload +sudo systemctl enable mission-control +sudo systemctl start mission-control +``` + +### Reverse proxy — Caddy (HTTPS) + +```caddy +mission-control.yourdomain.com { + reverse_proxy localhost:3000 +} +``` + +> When behind HTTPS, `secure: true` is set automatically on the auth cookie. + +--- + +## Configuration + +### Agent branding + +All personal data stays in `.env.local` (gitignored). The `src/config/branding.ts` file reads from env vars — **never edit it directly** with your personal data. + +### Agent discovery + +Agents are auto-discovered from `openclaw.json` at startup. The `/api/agents` endpoint reads: + +```json +{ + "agents": { + "list": [ + { "id": "main", "name": "...", "workspace": "...", "model": {...} }, + { "id": "studio", "name": "...", "workspace": "..." } + ] + } +} +``` + +Each agent can define its own visual appearance in `openclaw.json`: + +```json +{ + "id": "studio", + "name": "My Studio Agent", + "ui": { + "emoji": "🎬", + "color": "#E91E63" + } +} +``` + +### Office 3D — agent positions + +The 3D office has default positions for up to 6 agents. To customize positions, names, and colors for your own agents, edit `src/components/Office3D/agentsConfig.ts`: + +```ts +export const AGENTS: AgentConfig[] = [ + { + id: "main", // must match workspace ID + name: "...", // display name (can also come from API) + emoji: "🤖", + position: [0, 0, 0], + color: "#FFCC00", + role: "Main Agent", + }, + // add your sub-agents here +]; +``` + +### 3D Avatar models + +To add custom 3D avatars (Ready Player Me GLB format), place them in `public/models/`: + +``` +public/models/ +├── main.glb ← main agent avatar +├── studio.glb ← workspace-studio agent +└── infra.glb ← workspace-infra agent +``` + +Filename must match the agent `id`. If no file is found, a colored sphere is shown as fallback. +See `public/models/README.md` for full instructions. + +### Cost tracking + +Usage is collected from OpenClaw's SQLite databases via a script: + +```bash +# Collect once +npx tsx scripts/collect-usage.ts + +# Auto-collect every hour (adds a cron job) +./scripts/setup-cron.sh +``` + +See [docs/COST-TRACKING.md](./docs/COST-TRACKING.md) for details. + +--- + +## Project Structure + +``` +mission-control/ +├── src/ +│ ├── app/ +│ │ ├── (dashboard)/ # Dashboard pages (protected) +│ │ ├── api/ # API routes +│ │ ├── login/ # Login page +│ │ └── office/ # 3D office (unprotected route) +│ ├── components/ +│ │ ├── TenacitOS/ # OS-style UI shell (topbar, dock, status bar) +│ │ └── Office3D/ # React Three Fiber 3D office +│ ├── config/ +│ │ └── branding.ts # Branding constants (reads from env vars) +│ └── lib/ # Utilities (pricing, queries, activity logger...) +├── data/ # JSON data files (gitignored — use .example versions) +├── docs/ # Extended documentation +├── public/ +│ └── models/ # GLB avatar models (add your own) +├── scripts/ # Setup and data collection scripts +├── .env.example # Environment variable template +└── middleware.ts # Auth guard for all routes +``` + +--- + +## Security + +- All routes (including all `/api/*`) require authentication — handled by `src/middleware.ts` +- `/api/auth/login` and `/api/health` are the only public endpoints +- Login is rate-limited: **5 failed attempts → 15-minute lockout** per IP +- Auth cookie is `httpOnly`, `sameSite: lax`, and `secure` in production +- Terminal API uses a strict command allowlist — `env`, `curl`, `wget`, `node`, `python` are blocked +- **Never commit `.env.local`** — it contains your credentials + +Generate fresh secrets: + +```bash +openssl rand -base64 32 # AUTH_SECRET +openssl rand -base64 18 # ADMIN_PASSWORD +``` + +--- ## Troubleshooting -### `NEXT_PUBLIC_API_URL` and remote hosts - -If unset or set to `auto`, the client uses `http(s)://:8000`. -If your backend is on a different host/port, set `NEXT_PUBLIC_API_URL` explicitly. - -Fix: +**"Gateway not reachable" / agent data missing** ```bash -cp .env.example .env.local -# then edit .env.local if your backend URL differs +openclaw status +openclaw gateway start # if not running ``` -### Frontend loads, but API calls fail (CORS / network errors) +**"Database not found" (cost tracking)** -- Confirm backend is up: http://localhost:8000/healthz -- Confirm `NEXT_PUBLIC_API_URL` points to the correct host/port. -- If accessing from another device (LAN), use a reachable backend URL (not `localhost`). +```bash +npx tsx scripts/collect-usage.ts +``` -### Wrong auth mode UI +**Build errors after pulling updates** -- Ensure `NEXT_PUBLIC_AUTH_MODE` matches backend `AUTH_MODE`. -- For local mode, set `NEXT_PUBLIC_AUTH_MODE=local`. -- For Clerk mode, set `NEXT_PUBLIC_AUTH_MODE=clerk` and a real Clerk publishable key. +```bash +rm -rf .next node_modules +npm install +npm run build +``` -### Dev server blocked by origin restrictions +**Scripts not executable** -`next.config.ts` sets `allowedDevOrigins` for dev proxy safety. +```bash +chmod +x scripts/*.sh +``` -If you see repeated proxy errors (often `ECONNRESET`), make sure your dev server hostname and browser URL match (e.g. `localhost` vs `127.0.0.1`), and that your origin is included in `allowedDevOrigins`. +--- -Notes: +## Tech Stack -- Local dev should work via `http://localhost:3000` and `http://127.0.0.1:3000`. -- LAN dev should work via the configured LAN IP (e.g. `http://192.168.1.101:3000`) **only** if you bind the dev server to all interfaces (`npm run dev:lan`). -- If you bind Next to `127.0.0.1` only, remote LAN clients won’t connect. +| Layer | Tech | +|---|---| +| Framework | Next.js 15 (App Router) | +| UI | React 19 + Tailwind CSS v4 | +| 3D | React Three Fiber + Drei | +| Charts | Recharts | +| Icons | Lucide React | +| Database | SQLite (better-sqlite3) | +| Runtime | Node.js 22 | + +--- + +## Contributing + +1. Fork the repo +2. Create a feature branch (`git checkout -b feat/my-feature`) +3. **Keep personal data out of commits** — use `.env.local` and `data/` (both gitignored) +4. Write clear commit messages +5. Open a PR + +See [CONTRIBUTING.md](./CONTRIBUTING.md) for more details. + +--- + +## License + +MIT — see [LICENSE](./LICENSE) + +--- + +## Links + +- [OpenClaw](https://openclaw.ai) — the AI agent runtime this dashboard is built for +- [OpenClaw Docs](https://docs.openclaw.ai) +- [Discord Community](https://discord.com/invite/clawd) +- [GitHub Issues](../../issues) — bug reports and feature requests diff --git a/src/frontend/ROADMAP.md b/src/frontend/ROADMAP.md new file mode 100644 index 0000000..364a897 --- /dev/null +++ b/src/frontend/ROADMAP.md @@ -0,0 +1,420 @@ +# 🦞 Mission Control - Roadmap + +## Fase 1: Fundamentos (Semana 1) +> Mejorar lo que ya existe y añadir datos reales + +### 1.1 Activity Logger Real +- [ ] Crear endpoint POST `/api/activities` para que Tenacitas registre acciones +- [ ] Hook en OpenClaw para loguear automáticamente cada tool call +- [ ] Campos: timestamp, type, description, status, duration, tokens_used +- [ ] Retención: últimos 30 días + +### 1.2 Integración con Cron Real +- [ ] Leer cron jobs reales de OpenClaw (`cron list`) +- [ ] Mostrar en calendario con próximas ejecuciones +- [ ] Historial de ejecuciones pasadas + +### 1.3 Stats Dashboard +- [ ] Contador de actividades por día/semana +- [ ] Tipos de acciones más frecuentes +- [ ] Tasa de éxito/error + +--- + +## Fase 2: Memory & Files (Semana 2) +> Gestión visual del workspace + +### 2.1 Memory Browser +- [ ] Vista árbol de `memory/*.md` y archivos principales +- [ ] Editor markdown con preview +- [ ] Crear/renombrar/eliminar archivos +- [ ] Búsqueda dentro de archivos + +### 2.2 File Browser +- [ ] Explorador del workspace completo +- [ ] Preview de archivos (código, markdown, JSON) +- [ ] Descargar archivos +- [ ] Upload de archivos + +### 2.3 MEMORY.md Viewer +- [ ] Vista especial para MEMORY.md con secciones colapsables +- [ ] Edición inline +- [ ] Historial de cambios (git log) + +--- + +## Fase 3: Cron Manager (Semana 3) +> Control total de tareas programadas + +### 3.1 CRUD de Cron Jobs +- [x] Listar todos los jobs con estado (ya existía) +- [ ] Crear nuevo job con form visual (CronJobModal existe pero no está wired up al API) +- [ ] Editar job existente +- [x] Eliminar job (con confirmación) +- [x] Activar/desactivar job + +### 3.2 Cron Builder Visual +- [ ] Selector de frecuencia: diario, semanal, mensual, custom +- [ ] Preview de próximas 5 ejecuciones +- [ ] Selector de timezone +- [ ] Templates predefinidos + +### 3.3 Historial de Ejecuciones +- [x] ~~Re-ejecutar manualmente~~ → **"Run Now" button** en CronJobCard (llama a `POST /api/cron/run`) +- [x] **Run History inline** → botón History en CronJobCard, llama a `GET /api/cron/runs?id=` +- [ ] Filtrar historial por fecha, estado +- [ ] Log con output completo + +### 3.4 Weekly Timeline View ✅ (nuevo — 2026-02-19) +- [x] Vista tipo calendario de 7 días +- [x] Eventos de cron posicionados por día con hora exacta +- [x] Jobs de intervalo mostrados como "recurring" con dashed border +- [x] Leyenda de colores por job +- [x] Toggle Cards / Timeline en header +- [x] Componente: `CronWeeklyTimeline.tsx` +- [x] Nuevas rutas API: `POST /api/cron/run`, `GET /api/cron/runs` + +--- + +## Fase 4: Analytics (Semana 4) +> Visualización de datos + +### 4.1 Gráficas de Uso +- [ ] Actividad por hora del día (heatmap) +- [ ] Tokens consumidos por día (line chart) +- [ ] Tipos de tareas (pie chart) +- [ ] Tendencia semanal + +### 4.2 Cost Tracking +- [ ] Estimación de coste por modelo +- [ ] Coste acumulado diario/mensual +- [ ] Alertas de gasto (opcional) + +### 4.3 Performance Metrics +- [ ] Tiempo promedio de respuesta +- [ ] Tasa de éxito por tipo de tarea +- [ ] Uptime del agente + +--- + +## Fase 5: Comunicación (Semana 5) +> Interacción bidireccional + +### 5.1 Command Terminal +- [ ] Input para enviar mensajes/comandos a Tenacitas +- [ ] Output en tiempo real de respuesta +- [ ] Historial de comandos +- [ ] Shortcuts para comandos frecuentes + +### 5.2 Notifications Log +- [ ] Lista de mensajes enviados por canal (Telegram, etc.) +- [ ] Filtrar por fecha, canal, tipo +- [ ] Preview del mensaje +- [ ] Estado de entrega + +### 5.3 Session History ✅ (nuevo — 2026-02-21) +- [x] **Lista de sesiones** → todas las sesiones de OpenClaw (main, cron, subagent, chats) +- [x] **Tipos visuales** → badges con emoji 🦞 Main / 🕐 Cron / 🤖 Sub-agent / 💬 Direct +- [x] **Token counter** → total tokens + barra de contexto (% usado) con color-coding +- [x] **Model badge** → modelo mostrado (Sonnet 4.5, Opus 4.6, etc.) +- [x] **Age display** → "2 hours ago", "3 days ago" con date-fns +- [x] **Transcript viewer** → slide-in panel con mensajes del JSONL real +- [x] **Bubbles UI** → user/assistant/tool_use/tool_result con diferentes estilos +- [x] **Filter tabs** → All / Main / Cron / Sub-agents / Chats con contador +- [x] **Búsqueda** → filtro por key/model +- [x] **Stats cards** → Total sessions, Total tokens, Cron runs, Models used +- [x] **Sidebar + Dock** → añadido a navegación (icono History) +- **Archivos:** + - NEW: `src/app/api/sessions/route.ts` + - NEW: `src/app/(dashboard)/sessions/page.tsx` + - MODIFIED: `src/components/Sidebar.tsx` (añadida entrada Sessions) + - MODIFIED: `src/components/TenacitOS/Dock.tsx` (añadida entrada Sessions) + +### 5.4 Notifications System ✅ (nuevo — 2026-02-20) +- [x] **API de notificaciones** → `GET/POST/PATCH/DELETE /api/notifications` +- [x] **NotificationDropdown component** → Bell icon en TopBar con dropdown funcional +- [x] **Unread count badge** → Contador de notificaciones no leídas +- [x] **Notificación types** → info, success, warning, error con iconos y colores +- [x] **Mark as read/unread** → Individual o todas +- [x] **Delete notifications** → Individual o clear all read +- [x] **Links** → Notificaciones pueden tener links a páginas internas +- [x] **Auto-refresh** → Poll cada 30 segundos +- [x] **Integración con cron** → Cron Run Now genera notificación +- [x] **Storage** → JSON file en `data/notifications.json` (hasta 100 notificaciones) +- **Archivos:** + - NEW: `src/app/api/notifications/route.ts` + - NEW: `src/components/NotificationDropdown.tsx` + - MODIFIED: `src/components/TenacitOS/TopBar.tsx` + - MODIFIED: `src/app/api/cron/run/route.ts` (integración) + +--- + +## Fase 6: Configuración (Semana 6) +> Admin del sistema + +### 6.1 Skills Manager +- [ ] Lista de skills instalados +- [ ] Ver SKILL.md de cada uno +- [ ] Activar/desactivar +- [ ] Instalar desde ClawHub +- [ ] Actualizar skills + +### 6.2 Integration Status +- [ ] Estado de conexiones (Twitter, Gmail, etc.) +- [ ] Última actividad por integración +- [ ] Test de conectividad +- [ ] Reautenticar si necesario + +### 6.3 Config Editor +- [ ] Ver configuración actual de OpenClaw +- [ ] Editar valores seguros +- [ ] Validación antes de guardar +- [ ] Reiniciar gateway si necesario + +--- + +## Fase 7: Real-time (Semana 7) +> WebSockets y notificaciones live + +### 7.1 Live Activity Stream +- [ ] WebSocket connection +- [ ] Updates en tiempo real del activity feed +- [ ] Indicador "Tenacitas está trabajando..." +- [ ] Toast notifications + +### 7.2 System Status +- [ ] Heartbeat del agente +- [ ] CPU/memoria del VPS +- [ ] Cola de tareas pendientes + +--- + +## Fase 8: The Office 3D 🏢 (Semanas 8-10) +> Entorno 3D navegable que simula una oficina virtual donde trabajan los agentes + +**Ver spec completa:** `ROADMAP-OFFICE-3D.md` + +### 8.1 MVP - Oficina Básica (Semana 8) +- [ ] Sala 3D con React Three Fiber + 6 escritorios +- [ ] Navegación WASD + mouse (fly mode) +- [ ] Monitors mostrando estado: Working/Idle/Error +- [ ] Click en escritorio → panel lateral con activity feed +- [ ] Iluminación básica (día/noche) +- [ ] Avatares simples (cubo/esfera con emoji del agente) + +### 8.2 Interactions & Ambient (Semana 9) +- [ ] Avatares animados (tecleando, pensando, error) +- [ ] Sub-agents aparecen como "visitantes" en la oficina +- [ ] Trail visual entre parent y sub-agent +- [ ] Efectos visuales (partículas success, humo error, beam heartbeat) +- [ ] Sonido ambiental toggleable (teclas, notificaciones, lofi) +- [ ] Click en objetos (archivador→Memory, pizarra→Roadmap, café→Mood) + +### 8.3 Multi-Floor Building (Semana 10) +- [ ] 4 plantas navegables con ascensor: + - Planta 1: Main Office (agentes principales) + - Planta 2: Server Room (DBs, VPS, integrations) + - Planta 3: Archive (logs, memories históricas) + - Azotea: Control Tower (dashboard gigante) +- [ ] Customization: temas (modern, retro, cyberpunk, matrix) +- [ ] Modos especiales (Focus, God Mode, Cinematic) + +**Datos en tiempo real:** +- `/api/agents/status` - estado de cada agente +- `/api/activities` - activity feed +- `/api/subagents` - sub-agentes activos +- Polling cada 2-5 segundos + +--- + +## Fase 9: Agent Intelligence (Semana 11) +> Features experimentales y visualizaciones avanzadas (complementan "The Office") + +### 9.1 Agent Mood Dashboard +- [ ] Widget de "estado de ánimo" basado en métricas recientes +- [ ] Indicadores visuales: productivo, ocupado, idle, frustrado (muchos errores) +- [ ] Streak counter: días consecutivos sin errores críticos +- [ ] "Energy level" basado en tokens/hora +- [ ] Emoji animado que cambia según el estado + +### 9.2 Token Economics +- [ ] Vista detallada de consumo por modelo (Opus, Sonnet, Haiku, etc.) +- [ ] Breakdown: input tokens vs output tokens vs cache +- [ ] Comparativa: "Hoy vs ayer", "Esta semana vs la pasada" +- [ ] Proyección de gasto mensual +- [ ] Top 5 tareas que más tokens consumen +- [ ] Efficiency score: output útil / tokens totales + +### 9.3 Knowledge Graph Viewer +- [ ] Visualización de conceptos/entidades en MEMORY.md y brain +- [ ] Grafo interactivo con nodes y links +- [ ] Click en un nodo → muestra snippets relacionados +- [ ] Clustering por temas +- [ ] Búsqueda visual +- [ ] Export a imagen + +### 9.4 Quick Actions Hub +- [ ] Panel de botones para acciones frecuentes: + - Backup workspace now + - Clear temp files + - Test all integrations + - Re-authorize expired tokens + - Git status all repos + - Restart Gateway + - Flush message queue +- [ ] Status de cada acción (last run, next scheduled) +- [ ] One-click execution con confirmación + +### 9.5 Model Playground +- [ ] Input un prompt +- [ ] Seleccionar múltiples modelos para comparar +- [ ] Ver respuestas lado a lado +- [ ] Mostrar tokens/coste/tiempo de cada uno +- [ ] Guardar experimentos +- [ ] Share results (copy link) + +### 9.6 Smart Suggestions Engine +- [ ] Analiza patrones de uso +- [ ] Sugiere optimizaciones: + - "Usas mucho Opus para tareas simples, prueba Sonnet" + - "Muchos errores en cron X, revisar configuración" + - "Heartbeats muy frecuentes, considera reducir intervalo" + - "Token usage alto en horario Y, programar tareas pesadas en horario valle" +- [ ] Tarjetas de sugerencia con botón "Apply" o "Dismiss" +- [ ] Learn from dismissals + +--- + +## Fase 10: Sub-Agent Orchestra (Semana 12) +> Gestión y visualización de multi-agent workflows + +### 10.1 Sub-Agent Dashboard +- [ ] Lista de sub-agentes activos en tiempo real +- [ ] Estado: running, waiting, completed, failed +- [ ] Task description y progreso +- [ ] Modelo usado +- [ ] Tokens consumidos por cada uno +- [ ] Timeline de spawns/completions + +### 10.2 Agent Communication Graph +- [ ] Visualización de mensajes entre main agent y sub-agents +- [ ] Flow diagram tipo Sankey o network graph +- [ ] Ver contenido de mensajes al hacer click +- [ ] Filtrar por sesión, fecha, tipo + +### 10.3 Multi-Agent Orchestration +- [ ] Crear workflows visuales de múltiples agentes +- [ ] Drag & drop tasks → auto-spawn agents +- [ ] Dependencies entre tasks +- [ ] Parallel vs sequential execution +- [ ] Template workflows guardables + +--- + +## Fase 11: Advanced Visualizations (Semana 13) +> Porque los dashboards cool tienen gráficas cool + +### 11.1 3D Workspace Explorer +- [ ] Vista 3D del árbol de archivos +- [ ] Tamaño de nodos = tamaño de archivo +- [ ] Color = tipo de archivo +- [ ] Navigate con mouse +- [ ] Click → preview/edit +- [ ] Wow factor 📈 + +### 11.2 Heatmaps Interactivos +- [ ] Actividad por hora del día (24x7 grid) +- [ ] Hover → detalles de ese slot +- [ ] Click → filtrar activity feed a ese rango +- [ ] Export a imagen + +### 11.3 Sankey Diagrams +- [ ] Flow de tokens: input → cache → output +- [ ] Flow de tareas: type → status +- [ ] Flow de tiempo: hora → actividad → resultado + +### 11.4 Word Cloud de Memories +- [ ] Palabras más frecuentes en MEMORY.md +- [ ] Tamaño = frecuencia +- [ ] Click en palabra → buscar en memories +- [ ] Animated on hover + +--- + +## Fase 12: Collaboration (Semana 14) +> Share y trabajo en equipo + +### 12.1 Shareable Reports +- [ ] Generar report de actividad semanal/mensual +- [ ] Export a PDF +- [ ] Share link público (read-only) +- [ ] Custom date ranges + +### 12.2 Team Dashboard (futuro) +- [ ] Multi-user support +- [ ] Ver actividad de otros agentes +- [ ] Compare performance +- [ ] Shared memory bank + +--- + +## Stack Técnico + +| Componente | Tecnología | +|------------|------------| +| Frontend | Next.js 16 + App Router + React 19 | +| Styling | Tailwind v4 (latest) | +| Charts | Recharts (básicos) + D3.js (avanzados) | +| Editor | Monaco Editor (code) + TipTap (markdown) | +| Real-time | Server-Sent Events (SSE) o Socket.io | +| 3D Graphics | Three.js o React Three Fiber | +| Graphs/Networks | Cytoscape.js o Vis.js | +| Animations | Framer Motion | +| Storage | JSON files (actual) → SQLite (fase 2) → PostgreSQL (futuro multi-user) | +| AI Integration | OpenClaw API + direct model calls para suggestions | +| PDF Generation | jsPDF o Puppeteer | + +--- + +## Prioridad Recomendada + +### Tier 0: The Flagship 🚀 (Requested by Carlos) +**Fase 8: The Office 3D** - Entorno 3D inmersivo donde visualizar agentes trabajando +- Empezar por MVP (8.1) → 2 semanas +- Luego Interactions (8.2) → 1 semana +- Multi-Floor (8.3) es opcional/futuro + +### Tier 1: Core Functionality (Must Have) +1. **Fase 1** - Activity Logger Real → sin esto lo demás no tiene sentido +2. **Fase 3** - Cron Manager completo → uso diario +3. **Fase 2** - Memory Browser → gestión de conocimiento + +### Tier 2: High Value (Should Have) +4. **Fase 5** - Command Terminal + Session History → interacción directa +5. **Fase 9.4** - Quick Actions Hub → productividad inmediata +6. **Fase 10.1** - Sub-Agent Dashboard → visibilidad de workflows + +### Tier 3: Intelligence & Insights (Nice to Have) +7. **Fase 4** - Analytics básicos → métricas +8. **Fase 9.2** - Token Economics → optimización de costes +9. **Fase 9.6** - Smart Suggestions → IA que se auto-mejora + +### Tier 4: Advanced Features (Wow Factor) +10. **Fase 9.3** - Knowledge Graph → visualización avanzada +11. **Fase 11.2** - Heatmaps Interactivos → análisis visual +12. **Fase 10.2** - Agent Communication Graph → debugging multi-agent + +### Tier 5: Polish & Experimental (Future) +13. **Fase 7** - Real-time updates → UX premium +14. **Fase 11.1** - 3D Workspace Explorer (no-office) → alternativa visual +15. **Fase 12** - Collaboration → equipo/público + +### Tier 6: Admin & Config (When Needed) +16. **Fase 6** - Skills Manager + Config Editor → cuando sea necesario + +**Nota:** The Office 3D (Fase 8) es la feature flagship. Priorizar su MVP antes que otras fases avanzadas. + +--- + +*Creado: 2026-02-07* +*Última actualización: 2026-02-21 (Tenacitas nightly shift)* diff --git a/src/frontend/SECURITY.md b/src/frontend/SECURITY.md new file mode 100644 index 0000000..e7ab217 --- /dev/null +++ b/src/frontend/SECURITY.md @@ -0,0 +1,127 @@ +# Security Policy + +## Supported Versions + +Currently supporting: + +| Version | Supported | +| ------- | ------------------ | +| 0.1.x | :white_check_mark: | + +## Reporting a Vulnerability + +If you discover a security vulnerability, please report it by: + +1. **Email**: security@openclaw.ai (or create a private security advisory on GitHub) +2. **Do NOT** open a public issue +3. Include: + - Description of the vulnerability + - Steps to reproduce + - Potential impact + - Suggested fix (if any) + +We will respond within 48 hours and work with you to resolve the issue. + +## Security Best Practices + +### For Deployment + +1. **Strong Passwords** + - Use at least 16 characters for `ADMIN_PASSWORD` + - Generate with: `openssl rand -base64 24` + +2. **Secrets** + - Regenerate `AUTH_SECRET` for each instance + - Generate with: `openssl rand -base64 32` + - Never commit `.env.local` to git + +3. **File Permissions** + - Ensure `.env.local` is readable only by the app user: + ```bash + chmod 600 .env.local + ``` + - Lock down credentials directory: + ```bash + chmod 700 ~/.openclaw/credentials + ``` + +4. **Reverse Proxy** + - Always use HTTPS in production (Caddy auto-handles this) + - Configure rate limiting if exposing publicly + - Whitelist trusted IPs for admin endpoints + +5. **OpenClaw Gateway** + - Keep gateway on loopback (127.0.0.1) if possible + - Configure `trustedProxies` if behind a reverse proxy + - Review security audit output: `openclaw status` + +### For Development + +1. **Never commit:** + - `.env.local` (passwords, secrets) + - `data/*.json` (operational data) + - `data/*.db` (usage metrics) + - Real usernames, emails, tokens + +2. **Use branding config:** + - Import from `src/config/branding.ts` + - Use environment variables + - Never hardcode personal info + +3. **Dependencies:** + - Run `npm audit` regularly + - Update dependencies: `npm update` + - Review Dependabot alerts + +4. **Code Review:** + - No `eval()` or `Function()` with user input + - Validate and sanitize all input + - Use parameterized queries (SQLite prepared statements) + - Escape user-generated content in UI + +## Known Security Considerations + +### Authentication + +- Basic password auth (no 2FA yet) +- Session tokens in cookies (httpOnly, secure in production) +- TODO: Add OAuth2 / SAML support + +### Data Storage + +- Local JSON files (not encrypted at rest) +- SQLite database (not encrypted) +- TODO: Add encryption for sensitive data + +### Network + +- Gateway API exposed on loopback by default +- Control UI exposed via reverse proxy +- TODO: Add mTLS for gateway communication + +## Security Checklist + +Before deploying to production: + +- [ ] Changed `ADMIN_PASSWORD` from default +- [ ] Regenerated `AUTH_SECRET` +- [ ] Set file permissions on `.env.local` (600) +- [ ] Configured HTTPS via reverse proxy +- [ ] Reviewed `openclaw status` security audit +- [ ] Updated all npm dependencies +- [ ] Ran `npm audit fix` +- [ ] Configured firewall (UFW, iptables, etc.) +- [ ] Enabled fail2ban or similar (if public-facing) +- [ ] Configured backup for `data/` directory +- [ ] Documented incident response plan + +## Responsible Disclosure + +We follow coordinated vulnerability disclosure: + +1. Reporter notifies us privately +2. We confirm and develop a fix +3. We release a patched version +4. Disclosure is made public after patch is available + +Thank you for helping keep Mission Control secure! 🔒 diff --git a/src/frontend/cypress.config.ts b/src/frontend/cypress.config.ts deleted file mode 100644 index 46b1c77..0000000 --- a/src/frontend/cypress.config.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { defineConfig } from "cypress"; - -export default defineConfig({ - e2e: { - baseUrl: "http://localhost:3000", - specPattern: "cypress/e2e/**/*.cy.{js,jsx,ts,tsx}", - supportFile: "cypress/support/e2e.ts", - defaultCommandTimeout: 20_000, - retries: { - runMode: 2, - openMode: 0, - }, - }, -}); diff --git a/src/frontend/cypress/e2e/activity_feed.cy.ts b/src/frontend/cypress/e2e/activity_feed.cy.ts deleted file mode 100644 index 4245b4a..0000000 --- a/src/frontend/cypress/e2e/activity_feed.cy.ts +++ /dev/null @@ -1,173 +0,0 @@ -/// - -describe("/activity feed", () => { - const apiBase = "**/api/v1"; - - const originalDefaultCommandTimeout = Cypress.config("defaultCommandTimeout"); - - beforeEach(() => { - // CI can be slow enough that the default 4s command timeout flakes. - Cypress.config("defaultCommandTimeout", 20_000); - }); - - afterEach(() => { - Cypress.config("defaultCommandTimeout", originalDefaultCommandTimeout); - }); - - function stubStreamsEmpty() { - // The activity page connects multiple SSE streams (tasks/approvals/agents/board memory). - // In E2E we keep them empty to avoid flake and keep assertions deterministic. - const emptySse = { - statusCode: 200, - headers: { "content-type": "text/event-stream" }, - body: "", - }; - - cy.intercept("GET", `${apiBase}/boards/*/tasks/stream*`, emptySse).as( - "tasksStream", - ); - cy.intercept("GET", `${apiBase}/boards/*/approvals/stream*`, emptySse).as( - "approvalsStream", - ); - cy.intercept("GET", `${apiBase}/boards/*/memory/stream*`, emptySse).as( - "memoryStream", - ); - cy.intercept("GET", `${apiBase}/agents/stream*`, emptySse).as("agentsStream"); - } - - function stubBoardBootstrap() { - // Some app bootstraps happen before we get to the /activity call. - // Keep these stable so the page always reaches the activity request. - cy.intercept("GET", `${apiBase}/users/me*`, { - statusCode: 200, - body: { - id: "u1", - clerk_user_id: "local-auth-user", - email: "local@example.com", - name: "Local User", - preferred_name: "Local User", - timezone: "UTC", - }, - }).as("usersMe"); - - cy.intercept("GET", `${apiBase}/organizations/me/list*`, { - statusCode: 200, - body: [ - { - id: "org1", - name: "Testing Org", - is_active: true, - role: "owner", - }, - ], - }).as("orgsList"); - - cy.intercept("GET", `${apiBase}/organizations/me/member*`, { - statusCode: 200, - body: { organization_id: "org1", role: "owner" }, - }).as("orgMeMember"); - - cy.intercept("GET", `${apiBase}/boards*`, { - statusCode: 200, - body: { - items: [{ id: "b1", name: "Testing", updated_at: "2026-02-07T00:00:00Z" }], - }, - }).as("boardsList"); - - cy.intercept("GET", `${apiBase}/boards/b1/snapshot*`, { - statusCode: 200, - body: { - tasks: [{ id: "t1", title: "CI hardening" }], - agents: [], - approvals: [], - chat_messages: [], - }, - }).as("boardSnapshot"); - } - - function assertSignedInAndLanded() { - cy.waitForAppLoaded(); - cy.contains(/live feed/i).should("be.visible"); - } - - it("auth negative: signed-out user sees auth prompt", () => { - cy.visit("/activity"); - cy.contains(/sign in to view the feed|local authentication/i, { - timeout: 20_000, - }).should("be.visible"); - }); - - it("happy path: renders task comment cards", () => { - stubBoardBootstrap(); - - cy.intercept("GET", "**/api/v1/activity**", { - statusCode: 200, - body: { - items: [ - { - id: "e1", - event_type: "task.comment", - message: "Hello world", - agent_id: null, - agent_name: "Kunal", - created_at: "2026-02-07T00:00:00Z", - task_id: "t1", - task_title: "CI hardening", - agent_role: "QA 2", - }, - ], - }, - }).as("activityList"); - - stubStreamsEmpty(); - - cy.loginWithLocalAuth(); - cy.visit("/activity"); - assertSignedInAndLanded(); - cy.wait("@activityList", { timeout: 20_000 }); - - // Task-title rendering can be either enriched title or fallback label, - // depending on metadata resolution timing. - cy.contains(/ci hardening|unknown task/i).should("be.visible"); - cy.contains(/hello world/i).should("be.visible"); - }); - - it("empty state: shows waiting message when no items", () => { - stubBoardBootstrap(); - - cy.intercept("GET", "**/api/v1/activity**", { - statusCode: 200, - body: { items: [] }, - }).as("activityList"); - - stubStreamsEmpty(); - - cy.loginWithLocalAuth(); - cy.visit("/activity"); - assertSignedInAndLanded(); - cy.wait("@activityList", { timeout: 20_000 }); - - cy.contains(/waiting for new activity/i).should("be.visible"); - }); - - it("error state: shows failure UI when API errors", () => { - stubBoardBootstrap(); - - cy.intercept("GET", "**/api/v1/activity**", { - statusCode: 500, - body: { detail: "boom" }, - }).as("activityList"); - - stubStreamsEmpty(); - - cy.loginWithLocalAuth(); - cy.visit("/activity"); - assertSignedInAndLanded(); - cy.wait("@activityList", { timeout: 20_000 }); - - // Depending on how ApiError is surfaced, we may show a generic or specific message. - cy.contains(/unable to load activity feed|unable to load feed|boom/i).should( - "be.visible", - ); - }); -}); diff --git a/src/frontend/cypress/e2e/activity_smoke.cy.ts b/src/frontend/cypress/e2e/activity_smoke.cy.ts deleted file mode 100644 index 4da0469..0000000 --- a/src/frontend/cypress/e2e/activity_smoke.cy.ts +++ /dev/null @@ -1,8 +0,0 @@ -describe("/activity page", () => { - it("signed-out user sees an auth prompt", () => { - cy.visit("/activity"); - cy.contains(/local authentication|sign in to mission control/i, { - timeout: 20_000, - }).should("be.visible"); - }); -}); diff --git a/src/frontend/cypress/e2e/board_tasks.cy.ts b/src/frontend/cypress/e2e/board_tasks.cy.ts deleted file mode 100644 index c347c07..0000000 --- a/src/frontend/cypress/e2e/board_tasks.cy.ts +++ /dev/null @@ -1,304 +0,0 @@ -/// - -describe("/boards/:id task board", () => { - const apiBase = "**/api/v1"; - const email = "local-auth-user@example.com"; - - const originalDefaultCommandTimeout = Cypress.config("defaultCommandTimeout"); - - beforeEach(() => { - Cypress.config("defaultCommandTimeout", 20_000); - }); - - afterEach(() => { - Cypress.config("defaultCommandTimeout", originalDefaultCommandTimeout); - }); - - function stubEmptySse() { - // Keep known board-related SSE endpoints quiet in tests. - const emptySse = { - statusCode: 200, - headers: { "content-type": "text/event-stream" }, - body: "", - }; - - cy.intercept("GET", `${apiBase}/boards/*/tasks/stream*`, emptySse).as( - "tasksStream", - ); - cy.intercept("GET", `${apiBase}/boards/*/approvals/stream*`, emptySse).as( - "approvalsStream", - ); - cy.intercept("GET", `${apiBase}/boards/*/memory/stream*`, emptySse).as( - "memoryStream", - ); - cy.intercept("GET", `${apiBase}/agents/stream*`, emptySse).as("agentsStream"); - } - - function openEditTaskDialog() { - cy.get('button[title="Edit task"]', { timeout: 20_000 }) - .should("be.visible") - .and("not.be.disabled") - .click(); - cy.get('[aria-label="Edit task"]', { timeout: 20_000 }).should("be.visible"); - } - - it("auth negative: signed-out user is shown local auth login", () => { - cy.visit("/boards/b1"); - cy.contains("h1", /local authentication/i, { timeout: 30_000 }).should( - "be.visible", - ); - }); - - it("happy path: renders tasks from snapshot and supports create + status update + delete (stubbed)", () => { - stubEmptySse(); - - cy.intercept("GET", `${apiBase}/organizations/me/member*`, { - statusCode: 200, - body: { - id: "m1", - organization_id: "o1", - user_id: "u1", - role: "owner", - all_boards_read: true, - all_boards_write: true, - created_at: "2026-02-11T00:00:00Z", - updated_at: "2026-02-11T00:00:00Z", - board_access: [{ board_id: "b1", can_read: true, can_write: true }], - }, - }).as("membership"); - - cy.intercept("GET", `${apiBase}/users/me*`, { - statusCode: 200, - body: { - id: "u1", - clerk_user_id: "clerk_u1", - email, - name: "Jane Test", - preferred_name: "Jane", - timezone: "America/New_York", - is_super_admin: false, - }, - }).as("me"); - - cy.intercept("GET", `${apiBase}/organizations/me/list*`, { - statusCode: 200, - body: [ - { id: "o1", name: "Personal", role: "owner", is_active: true }, - ], - }).as("organizations"); - - cy.intercept("GET", `${apiBase}/tags*`, { - statusCode: 200, - body: { items: [], total: 0, limit: 200, offset: 0 }, - }).as("tags"); - - cy.intercept("GET", `${apiBase}/organizations/me/custom-fields*`, { - statusCode: 200, - body: [], - }).as("customFields"); - - cy.intercept("GET", `${apiBase}/boards/b1/snapshot*`, { - statusCode: 200, - body: { - board: { - id: "b1", - name: "Demo Board", - slug: "demo-board", - description: "Demo", - gateway_id: "g1", - board_group_id: null, - board_type: "general", - objective: null, - success_metrics: null, - target_date: null, - goal_confirmed: true, - goal_source: "test", - organization_id: "o1", - created_at: "2026-02-11T00:00:00Z", - updated_at: "2026-02-11T00:00:00Z", - }, - tasks: [ - { - id: "t1", - board_id: "b1", - title: "Inbox task", - description: "", - status: "inbox", - priority: "medium", - due_at: null, - assigned_agent_id: null, - depends_on_task_ids: [], - created_by_user_id: null, - in_progress_at: null, - created_at: "2026-02-11T00:00:00Z", - updated_at: "2026-02-11T00:00:00Z", - blocked_by_task_ids: [], - is_blocked: false, - assignee: null, - approvals_count: 0, - approvals_pending_count: 0, - }, - ], - agents: [], - approvals: [], - chat_messages: [], - pending_approvals_count: 0, - }, - }).as("snapshot"); - - cy.intercept("GET", `${apiBase}/boards/b1/group-snapshot*`, { - statusCode: 200, - body: { group: null, boards: [] }, - }).as("groupSnapshot"); - - cy.intercept("POST", `${apiBase}/boards/b1/tasks`, (req) => { - // Minimal assertion the UI sends expected fields. - expect(req.body).to.have.property("title"); - req.reply({ - statusCode: 200, - body: { - id: "t2", - board_id: "b1", - title: req.body.title, - description: req.body.description ?? "", - status: "inbox", - priority: req.body.priority ?? "medium", - due_at: null, - assigned_agent_id: null, - depends_on_task_ids: [], - created_by_user_id: null, - in_progress_at: null, - created_at: "2026-02-11T00:00:00Z", - updated_at: "2026-02-11T00:00:00Z", - blocked_by_task_ids: [], - is_blocked: false, - assignee: null, - approvals_count: 0, - approvals_pending_count: 0, - }, - }); - }).as("createTask"); - - cy.intercept("PATCH", `${apiBase}/boards/b1/tasks/t1`, (req) => { - expect(req.body).to.have.property("status"); - req.reply({ - statusCode: 200, - body: { - id: "t1", - board_id: "b1", - title: "Inbox task", - description: "", - status: req.body.status, - priority: "medium", - due_at: null, - assigned_agent_id: null, - depends_on_task_ids: [], - created_by_user_id: null, - in_progress_at: null, - created_at: "2026-02-11T00:00:00Z", - updated_at: "2026-02-11T00:00:01Z", - blocked_by_task_ids: [], - is_blocked: false, - assignee: null, - approvals_count: 0, - approvals_pending_count: 0, - }, - }); - }).as("updateTask"); - - cy.intercept("DELETE", `${apiBase}/boards/b1/tasks/t1`, { - statusCode: 200, - body: { ok: true }, - }).as("deleteTask"); - - cy.intercept("GET", `${apiBase}/boards/b1/tasks/t1/comments*`, { - statusCode: 200, - body: { items: [], total: 0, limit: 200, offset: 0 }, - }).as("taskComments"); - - cy.loginWithLocalAuth(); - cy.visit("/boards/b1"); - cy.waitForAppLoaded(); - - cy.wait([ - "@snapshot", - "@groupSnapshot", - "@membership", - "@me", - "@organizations", - "@tags", - "@customFields", - ]); - - // Existing task visible. - cy.contains("Inbox task").should("be.visible"); - - // Open create task flow. - // Board page uses an icon-only button with aria-label="New task". - cy.get('button[aria-label="New task"]') - .should("be.visible") - .and("not.be.disabled") - .click(); - - cy.contains('[role="dialog"]', "New task") - .should("be.visible") - .within(() => { - cy.contains("label", "Title").parent().find("input").type("New task"); - cy.contains("button", /^Create task$/) - .should("be.visible") - .and("not.be.disabled") - .click(); - }); - cy.wait(["@createTask"]); - - cy.contains("New task").should("be.visible"); - - // Open edit task dialog. - cy.contains("Inbox task").scrollIntoView().should("be.visible").click(); - cy.wait(["@taskComments"]); - cy.contains(/task detail/i).should("be.visible"); - openEditTaskDialog(); - - // Change status via Status select. - cy.get('[aria-label="Edit task"]').within(() => { - cy.contains("label", "Status") - .parent() - .within(() => { - cy.get('[role="combobox"]').first().should("be.visible").click(); - }); - }); - - cy.contains("In progress").should("be.visible").click(); - - cy.contains("button", /save changes/i) - .should("be.visible") - .and("not.be.disabled") - .click(); - cy.wait(["@updateTask"]); - cy.get('[aria-label="Edit task"]').should("not.exist"); - - // Save closes the edit dialog; reopen it from task detail. - cy.contains(/task detail/i).should("be.visible"); - openEditTaskDialog(); - - // Delete task via delete dialog. - cy.get('[aria-label="Edit task"]').within(() => { - cy.contains("button", /^Delete task$/) - .scrollIntoView() - .should("be.visible") - .and("not.be.disabled") - .click(); - }); - cy.get('[aria-label="Delete task"]').should("be.visible"); - cy.get('[aria-label="Delete task"]').within(() => { - cy.contains("button", /^Delete task$/) - .scrollIntoView() - .should("be.visible") - .and("not.be.disabled") - .click(); - }); - cy.wait(["@deleteTask"]); - - cy.contains("Inbox task").should("not.exist"); - }); -}); diff --git a/src/frontend/cypress/e2e/boards_list.cy.ts b/src/frontend/cypress/e2e/boards_list.cy.ts deleted file mode 100644 index ee07593..0000000 --- a/src/frontend/cypress/e2e/boards_list.cy.ts +++ /dev/null @@ -1,95 +0,0 @@ -/// - -import { setupCommonPageTestHooks } from "../support/testHooks"; - -describe("/boards", () => { - const apiBase = "**/api/v1"; - const email = "local-auth-user@example.com"; - - setupCommonPageTestHooks(apiBase); - - it("auth negative: signed-out user is shown local auth login", () => { - cy.visit("/boards"); - cy.contains("h1", /local authentication/i, { timeout: 30_000 }).should( - "be.visible", - ); - }); - - it("happy path: signed-in user sees boards list and create button", () => { - cy.intercept("GET", `${apiBase}/organizations/me/member*`, { - statusCode: 200, - body: { - id: "m1", - organization_id: "o1", - user_id: "u1", - role: "owner", - all_boards_read: true, - all_boards_write: true, - created_at: "2026-02-11T00:00:00Z", - updated_at: "2026-02-11T00:00:00Z", - board_access: [], - }, - }).as("membership"); - - cy.intercept("GET", `${apiBase}/users/me*`, { - statusCode: 200, - body: { - id: "u1", - clerk_user_id: "clerk_u1", - email, - name: "Jane Test", - preferred_name: "Jane", - timezone: "America/New_York", - is_super_admin: false, - }, - }).as("me"); - - cy.intercept("GET", `${apiBase}/organizations/me/list*`, { - statusCode: 200, - body: [{ id: "o1", name: "Personal", role: "owner", is_active: true }], - }).as("organizations"); - - cy.intercept("GET", `${apiBase}/boards*`, { - statusCode: 200, - body: { - items: [ - { - id: "b1", - name: "Demo Board", - slug: "demo-board", - description: "Demo", - gateway_id: "g1", - board_group_id: null, - board_type: "general", - objective: null, - success_metrics: null, - target_date: null, - goal_confirmed: true, - goal_source: "test", - organization_id: "o1", - created_at: "2026-02-11T00:00:00Z", - updated_at: "2026-02-11T00:00:00Z", - }, - ], - total: 1, - limit: 200, - offset: 0, - }, - }).as("boards"); - - cy.intercept("GET", `${apiBase}/board-groups*`, { - statusCode: 200, - body: { items: [], total: 0, limit: 200, offset: 0 }, - }).as("boardGroups"); - - cy.loginWithLocalAuth(); - cy.visit("/boards"); - cy.waitForAppLoaded(); - - cy.wait(["@membership", "@me", "@organizations", "@boards", "@boardGroups"]); - - cy.contains(/boards/i).should("be.visible"); - cy.contains("Demo Board").should("be.visible"); - cy.contains("a", /create board/i).should("be.visible"); - }); -}); diff --git a/src/frontend/cypress/e2e/global_approvals.cy.ts b/src/frontend/cypress/e2e/global_approvals.cy.ts deleted file mode 100644 index 7e0d7fb..0000000 --- a/src/frontend/cypress/e2e/global_approvals.cy.ts +++ /dev/null @@ -1,81 +0,0 @@ -/// - -import { setupCommonPageTestHooks } from "../support/testHooks"; - -describe("Global approvals", () => { - const apiBase = "**/api/v1"; - - setupCommonPageTestHooks(apiBase); - - it("can render a pending approval and approve it", () => { - const approval = { - id: "a1", - board_id: "b1", - action_type: "task.closeout", - status: "pending", - confidence: 92, - created_at: "2026-02-14T00:00:00Z", - task_id: "t1", - task_ids: ["t1"], - payload: { - task_id: "t1", - title: "Close task", - reason: "Merged and ready to close", - }, - }; - - cy.intercept("GET", `${apiBase}/boards*`, { - statusCode: 200, - body: { - items: [ - { - id: "b1", - name: "Testing", - group_id: null, - objective: null, - success_metrics: null, - target_date: null, - updated_at: "2026-02-14T00:00:00Z", - created_at: "2026-02-10T00:00:00Z", - }, - ], - }, - }).as("boardsList"); - - cy.intercept("GET", `${apiBase}/boards/b1/approvals*`, { - statusCode: 200, - body: { items: [approval] }, - }).as("approvalsList"); - - cy.intercept("PATCH", `${apiBase}/boards/b1/approvals/a1`, { - statusCode: 200, - body: { ...approval, status: "approved" }, - }).as("approvalUpdate"); - - cy.loginWithLocalAuth(); - cy.visit("/approvals"); - cy.waitForAppLoaded(); - - cy.wait( - [ - "@usersMe", - "@organizationsList", - "@orgMeMember", - "@boardsList", - "@approvalsList", - ], - { timeout: 20_000 }, - ); - - // Pending approval should be visible in the list. - cy.contains(/unapproved tasks/i).should("be.visible"); - // Action type is humanized as "Task · Closeout" in the UI. - cy.contains(/task\s*(?:·|\u00b7|\u2022)?\s*closeout/i).should("be.visible"); - - cy.contains("button", /^approve$/i).click(); - cy.wait("@approvalUpdate", { timeout: 20_000 }); - - // Status badge should flip to approved. - cy.contains(/approved/i).should("be.visible"); - }); -}); diff --git a/src/frontend/cypress/e2e/local_auth_login.cy.ts b/src/frontend/cypress/e2e/local_auth_login.cy.ts deleted file mode 100644 index 7df170e..0000000 --- a/src/frontend/cypress/e2e/local_auth_login.cy.ts +++ /dev/null @@ -1,49 +0,0 @@ -describe("Local auth login", () => { - it("user with local auth token can access protected route", () => { - cy.intercept("GET", "**/api/v1/users/me*", { - statusCode: 200, - body: { - id: "u1", - clerk_user_id: "local-auth-user", - email: "local@example.com", - name: "Local User", - preferred_name: "Local User", - timezone: "UTC", - }, - }).as("usersMe"); - - cy.intercept("GET", "**/api/v1/organizations/me/list*", { - statusCode: 200, - body: [ - { - id: "org1", - name: "Testing Org", - is_active: true, - role: "owner", - }, - ], - }).as("orgsList"); - - cy.intercept("GET", "**/api/v1/organizations/me/member*", { - statusCode: 200, - body: { organization_id: "org1", role: "owner" }, - }).as("orgMeMember"); - - cy.intercept("GET", "**/api/v1/boards*", { - statusCode: 200, - body: { - items: [{ id: "b1", name: "Testing", updated_at: "2026-02-07T00:00:00Z" }], - }, - }).as("boardsList"); - - cy.intercept("GET", "**/api/v1/boards/b1/snapshot*", { - statusCode: 200, - body: { tasks: [], agents: [], approvals: [], chat_messages: [] }, - }).as("boardSnapshot"); - - cy.loginWithLocalAuth(); - cy.visit("/activity"); - cy.waitForAppLoaded(); - cy.contains(/live feed/i).should("be.visible"); - }); -}); diff --git a/src/frontend/cypress/e2e/mobile_sidebar.cy.ts b/src/frontend/cypress/e2e/mobile_sidebar.cy.ts deleted file mode 100644 index a4a74a6..0000000 --- a/src/frontend/cypress/e2e/mobile_sidebar.cy.ts +++ /dev/null @@ -1,155 +0,0 @@ -/// - -import { setupCommonPageTestHooks } from "../support/testHooks"; - -describe("/dashboard - mobile sidebar", () => { - const apiBase = "**/api/v1"; - - setupCommonPageTestHooks(apiBase); - - const emptySeries = { - primary: { range: "7d", bucket: "day", points: [] }, - comparison: { range: "7d", bucket: "day", points: [] }, - }; - - function stubDashboardApis() { - cy.intercept("GET", `${apiBase}/metrics/dashboard*`, { - statusCode: 200, - body: { - generated_at: new Date().toISOString(), - range: "7d", - kpis: { - inbox_tasks: 0, - in_progress_tasks: 0, - review_tasks: 0, - done_tasks: 0, - tasks_in_progress: 0, - active_agents: 0, - error_rate_pct: 0, - median_cycle_time_hours_7d: null, - }, - throughput: emptySeries, - cycle_time: emptySeries, - error_rate: emptySeries, - wip: emptySeries, - pending_approvals: { items: [], total: 0 }, - }, - }).as("dashboardMetrics"); - - cy.intercept("GET", `${apiBase}/boards*`, { - statusCode: 200, - body: { items: [], total: 0 }, - }).as("boardsList"); - - cy.intercept("GET", `${apiBase}/agents*`, { - statusCode: 200, - body: { items: [], total: 0 }, - }).as("agentsList"); - - cy.intercept("GET", `${apiBase}/activity*`, { - statusCode: 200, - body: { items: [], total: 0 }, - }).as("activityList"); - - cy.intercept("GET", `${apiBase}/gateways/status*`, { - statusCode: 200, - body: { gateways: [] }, - }).as("gatewaysStatus"); - - cy.intercept("GET", `${apiBase}/board-groups*`, { - statusCode: 200, - body: { items: [], total: 0 }, - }).as("boardGroupsList"); - } - - function visitDashboardAuthenticated() { - stubDashboardApis(); - cy.loginWithLocalAuth(); - cy.visit("/dashboard"); - cy.waitForAppLoaded(); - } - - it("auth negative: signed-out user does not see hamburger button", () => { - cy.visit("/dashboard"); - cy.contains("h1", /local authentication/i, { timeout: 30_000 }).should( - "be.visible", - ); - cy.get('[aria-label="Toggle navigation"]').should("not.exist"); - }); - - it("mobile: hamburger button visible and sidebar hidden by default", () => { - cy.viewport(375, 812); - visitDashboardAuthenticated(); - - cy.get('[aria-label="Toggle navigation"]').should("be.visible"); - cy.get("[data-sidebar]").should("have.attr", "data-sidebar", "closed"); - cy.get("aside").should("not.be.visible"); - }); - - it("desktop: hamburger button hidden and sidebar always visible", () => { - cy.viewport(1280, 800); - visitDashboardAuthenticated(); - - cy.get('[aria-label="Toggle navigation"]').should("not.be.visible"); - cy.get("aside").should("be.visible"); - }); - - it("mobile: click hamburger opens sidebar and shows backdrop", () => { - cy.viewport(375, 812); - visitDashboardAuthenticated(); - - cy.get('[aria-label="Toggle navigation"]').click(); - - cy.get("[data-sidebar]").should("have.attr", "data-sidebar", "open"); - cy.get("aside").should("be.visible"); - cy.get('[data-cy="sidebar-backdrop"]').should("exist"); - }); - - it("mobile: click backdrop closes sidebar", () => { - cy.viewport(375, 812); - visitDashboardAuthenticated(); - - // Open sidebar first - cy.get('[aria-label="Toggle navigation"]').click(); - cy.get("[data-sidebar]").should("have.attr", "data-sidebar", "open"); - - // Click the backdrop overlay - cy.get('[data-cy="sidebar-backdrop"]').click({ force: true }); - - cy.get("[data-sidebar]").should("have.attr", "data-sidebar", "closed"); - cy.get("aside").should("not.be.visible"); - }); - - it("mobile: clicking a nav link closes sidebar", () => { - cy.viewport(375, 812); - visitDashboardAuthenticated(); - - // Open sidebar - cy.get('[aria-label="Toggle navigation"]').click(); - cy.get("[data-sidebar]").should("have.attr", "data-sidebar", "open"); - cy.get("aside").should("be.visible"); - - // Click a navigation link inside the sidebar - cy.get("aside").within(() => { - cy.contains("a", "Boards").click(); - }); - - // Sidebar should close after navigation - cy.get("[data-sidebar]").should("have.attr", "data-sidebar", "closed"); - }); - - it("mobile: pressing Escape closes sidebar", () => { - cy.viewport(375, 812); - visitDashboardAuthenticated(); - - // Open sidebar - cy.get('[aria-label="Toggle navigation"]').click(); - cy.get("[data-sidebar]").should("have.attr", "data-sidebar", "open"); - - // Press Escape - cy.get("body").type("{esc}"); - - cy.get("[data-sidebar]").should("have.attr", "data-sidebar", "closed"); - cy.get("aside").should("not.be.visible"); - }); -}); diff --git a/src/frontend/cypress/e2e/organizations.cy.ts b/src/frontend/cypress/e2e/organizations.cy.ts deleted file mode 100644 index f302d25..0000000 --- a/src/frontend/cypress/e2e/organizations.cy.ts +++ /dev/null @@ -1,88 +0,0 @@ -describe("Organizations (PR #61)", () => { - const apiBase = "**/api/v1"; - - function stubOrganizationApis() { - cy.intercept("GET", `${apiBase}/users/me*`, { - statusCode: 200, - body: { - id: "u1", - clerk_user_id: "local-auth-user", - email: "local@example.com", - name: "Local User", - preferred_name: "Local User", - timezone: "UTC", - }, - }).as("usersMe"); - - cy.intercept("GET", `${apiBase}/organizations/me/list*`, { - statusCode: 200, - body: [ - { - id: "org1", - name: "Testing Org", - is_active: true, - role: "member", - }, - ], - }).as("orgsList"); - - cy.intercept("GET", `${apiBase}/organizations/me/member*`, { - statusCode: 200, - body: { - id: "membership-1", - user_id: "u1", - organization_id: "org1", - role: "member", - }, - }).as("orgMembership"); - - cy.intercept("GET", `${apiBase}/organizations/me`, { - statusCode: 200, - body: { id: "org1", name: "Testing Org" }, - }).as("orgMe"); - - cy.intercept("GET", `${apiBase}/organizations/me/members*`, { - statusCode: 200, - body: { - items: [ - { - id: "membership-1", - user_id: "u1", - role: "member", - user: { - id: "u1", - email: "local@example.com", - name: "Local User", - preferred_name: "Local User", - }, - }, - ], - }, - }).as("orgMembers"); - - cy.intercept("GET", `${apiBase}/boards*`, { - statusCode: 200, - body: { items: [] }, - }).as("boardsList"); - } - - it("negative: signed-out user sees auth prompt when opening /organization", () => { - cy.visit("/organization"); - cy.contains(/sign in to manage your organization|local authentication/i, { - timeout: 30_000, - }).should("be.visible"); - }); - - it("positive: signed-in user can view /organization and sees correct invite permissions", () => { - stubOrganizationApis(); - cy.loginWithLocalAuth(); - cy.visit("/organization"); - cy.waitForAppLoaded(); - cy.contains(/members\s*&\s*invites/i).should("be.visible"); - cy.contains("button", /invite member/i) - .should("be.visible") - .should("be.disabled") - .and("have.attr", "title") - .and("match", /only organization admins can invite/i); - }); -}); diff --git a/src/frontend/cypress/e2e/skill_packs_sync.cy.ts b/src/frontend/cypress/e2e/skill_packs_sync.cy.ts deleted file mode 100644 index d0cb05f..0000000 --- a/src/frontend/cypress/e2e/skill_packs_sync.cy.ts +++ /dev/null @@ -1,48 +0,0 @@ -/// - -import { setupCommonPageTestHooks } from "../support/testHooks"; - -describe("Skill packs", () => { - const apiBase = "**/api/v1"; - - setupCommonPageTestHooks(apiBase); - - it("can sync a pack and surface warnings", () => { - cy.intercept("GET", `${apiBase}/skills/packs*`, { - statusCode: 200, - body: [ - { - id: "p1", - name: "OpenClaw Skills", - description: "Test pack", - source_url: "https://github.com/openclaw/skills", - branch: "main", - skill_count: 12, - updated_at: "2026-02-14T00:00:00Z", - created_at: "2026-02-10T00:00:00Z", - }, - ], - }).as("packsList"); - - cy.intercept("POST", `${apiBase}/skills/packs/p1/sync*`, { - statusCode: 200, - body: { - warnings: ["1 skill skipped (missing SKILL.md)"], - }, - }).as("packSync"); - - cy.loginWithLocalAuth(); - cy.visit("/skills/packs"); - cy.waitForAppLoaded(); - - cy.wait(["@usersMe", "@organizationsList", "@orgMeMember", "@packsList"], { - timeout: 20_000, - }); - cy.contains(/openclaw skills/i).should("be.visible"); - - cy.contains("button", /^sync$/i).click(); - cy.wait("@packSync", { timeout: 20_000 }); - - cy.contains(/skill skipped/i).should("be.visible"); - }); -}); diff --git a/src/frontend/cypress/support/commands.ts b/src/frontend/cypress/support/commands.ts deleted file mode 100644 index 83eae8e..0000000 --- a/src/frontend/cypress/support/commands.ts +++ /dev/null @@ -1,56 +0,0 @@ -/// - -const APP_LOAD_TIMEOUT_MS = 30_000; -const LOCAL_AUTH_STORAGE_KEY = "mc_local_auth_token"; -const DEFAULT_LOCAL_AUTH_TOKEN = - "cypress-local-auth-token-0123456789-0123456789-0123456789x"; - -Cypress.Commands.add("waitForAppLoaded", () => { - cy.get("[data-cy='route-loader']", { - timeout: APP_LOAD_TIMEOUT_MS, - }).should("not.exist"); - - cy.get("[data-cy='global-loader']", { - timeout: APP_LOAD_TIMEOUT_MS, - }).should("have.attr", "aria-hidden", "true"); -}); - -Cypress.Commands.add("loginWithLocalAuth", (token = DEFAULT_LOCAL_AUTH_TOKEN) => { - cy.visit("/", { - onBeforeLoad(win) { - win.sessionStorage.setItem(LOCAL_AUTH_STORAGE_KEY, token); - }, - }); -}); - -Cypress.Commands.add("logoutLocalAuth", () => { - cy.visit("/", { - onBeforeLoad(win) { - win.sessionStorage.removeItem(LOCAL_AUTH_STORAGE_KEY); - }, - }); -}); - -declare global { - // eslint-disable-next-line @typescript-eslint/no-namespace - namespace Cypress { - interface Chainable { - /** - * Waits for route-level and global app loaders to disappear. - */ - waitForAppLoaded(): Chainable; - - /** - * Seeds session storage with a local auth token for local-auth mode. - */ - loginWithLocalAuth(token?: string): Chainable; - - /** - * Clears local auth token from session storage. - */ - logoutLocalAuth(): Chainable; - } - } -} - -export {}; diff --git a/src/frontend/cypress/support/e2e.ts b/src/frontend/cypress/support/e2e.ts deleted file mode 100644 index a1b252f..0000000 --- a/src/frontend/cypress/support/e2e.ts +++ /dev/null @@ -1,19 +0,0 @@ -// Cypress support file. -// Place global hooks/commands here. - -/// - -import { addClerkCommands } from "@clerk/testing/cypress"; - -// Clerk/Next.js occasionally throws a non-deterministic hydration mismatch -// on /sign-in. Ignore this known UI noise so E2E assertions can proceed. -Cypress.on("uncaught:exception", (err) => { - if (err?.message?.includes("Hydration failed")) { - return false; - } - return true; -}); - -addClerkCommands({ Cypress, cy }); - -import "./commands"; diff --git a/src/frontend/cypress/support/testHooks.ts b/src/frontend/cypress/support/testHooks.ts deleted file mode 100644 index 4414132..0000000 --- a/src/frontend/cypress/support/testHooks.ts +++ /dev/null @@ -1,77 +0,0 @@ -/// - -type CommonPageTestHooksOptions = { - timeoutMs?: number; - orgMemberRole?: string; - organizationId?: string; - organizationName?: string; - userId?: string; - userEmail?: string; - userName?: string; -}; - -export function setupCommonPageTestHooks( - apiBase: string, - options: CommonPageTestHooksOptions = {}, -): void { - const { - timeoutMs = 20_000, - orgMemberRole = "owner", - organizationId = "org1", - organizationName = "Testing Org", - userId = "u1", - userEmail = "local-auth-user@example.com", - userName = "Local User", - } = options; - const originalDefaultCommandTimeout = Cypress.config("defaultCommandTimeout"); - - beforeEach(() => { - Cypress.config("defaultCommandTimeout", timeoutMs); - - cy.intercept("GET", "**/healthz", { - statusCode: 200, - body: { ok: true }, - }).as("healthz"); - - cy.intercept("GET", `${apiBase}/users/me*`, { - statusCode: 200, - body: { - id: userId, - clerk_user_id: "local-auth-user", - email: userEmail, - name: userName, - preferred_name: userName, - timezone: "UTC", - }, - }).as("usersMe"); - - cy.intercept("GET", `${apiBase}/organizations/me/list*`, { - statusCode: 200, - body: [ - { - id: organizationId, - name: organizationName, - is_active: true, - role: orgMemberRole, - }, - ], - }).as("organizationsList"); - - cy.intercept("GET", `${apiBase}/organizations/me/member*`, { - statusCode: 200, - body: { - id: "membership-1", - organization_id: organizationId, - user_id: userId, - role: orgMemberRole, - all_boards_read: true, - all_boards_write: true, - board_access: [], - }, - }).as("orgMeMember"); - }); - - afterEach(() => { - Cypress.config("defaultCommandTimeout", originalDefaultCommandTimeout); - }); -} diff --git a/src/frontend/data/activities.example.json b/src/frontend/data/activities.example.json new file mode 100644 index 0000000..fdf694f --- /dev/null +++ b/src/frontend/data/activities.example.json @@ -0,0 +1,32 @@ +[ + { + "id": "act-example-001", + "timestamp": "2026-01-15T10:00:00.000Z", + "type": "cron", + "description": "Health Check - All services up", + "status": "ok", + "duration_ms": 1523, + "tokens_used": null, + "metadata": { "jobId": "example-job-1" } + }, + { + "id": "act-example-002", + "timestamp": "2026-01-15T09:00:00.000Z", + "type": "cron", + "description": "Data Sync completed", + "status": "ok", + "duration_ms": 8200, + "tokens_used": null, + "metadata": { "jobId": "example-job-2" } + }, + { + "id": "act-example-003", + "timestamp": "2026-01-15T08:00:00.000Z", + "type": "task", + "description": "Example task executed", + "status": "success", + "duration_ms": 450, + "tokens_used": 1200, + "metadata": null + } +] diff --git a/src/frontend/data/configured-skills.example.json b/src/frontend/data/configured-skills.example.json new file mode 100644 index 0000000..8771405 --- /dev/null +++ b/src/frontend/data/configured-skills.example.json @@ -0,0 +1,7 @@ +{ + "lastUpdated": "2026-01-01", + "skills": [ + {"name": "weather", "location": "system", "description": "Get current weather and forecasts"}, + {"name": "web-search", "location": "system", "description": "Search the web using Brave API"} + ] +} diff --git a/src/frontend/data/cron-jobs.example.json b/src/frontend/data/cron-jobs.example.json new file mode 100644 index 0000000..a596aa8 --- /dev/null +++ b/src/frontend/data/cron-jobs.example.json @@ -0,0 +1,16 @@ +[ + { + "id": "example-cron-1", + "name": "Example Health Check", + "description": "Hourly health check of services", + "schedule": "0 * * * *", + "timezone": "UTC", + "enabled": true, + "lastStatus": "ok", + "lastRunAt": null, + "nextRunAt": null, + "lastDurationMs": null, + "createdAt": "2026-01-01T00:00:00.000Z", + "updatedAt": "2026-01-01T00:00:00.000Z" + } +] diff --git a/src/frontend/data/notifications.example.json b/src/frontend/data/notifications.example.json new file mode 100644 index 0000000..ee764eb --- /dev/null +++ b/src/frontend/data/notifications.example.json @@ -0,0 +1,10 @@ +[ + { + "id": "example-notification-1", + "timestamp": "2026-01-01T12:00:00.000Z", + "title": "Welcome to Mission Control", + "message": "This is an example notification. Real notifications will appear here when the system is running.", + "type": "info", + "read": false + } +] diff --git a/src/frontend/data/tasks.example.json b/src/frontend/data/tasks.example.json new file mode 100644 index 0000000..5c7cf85 --- /dev/null +++ b/src/frontend/data/tasks.example.json @@ -0,0 +1,11 @@ +[ + { + "id": "example-task-1", + "name": "Example Cron Job", + "schedule": "0 */4 * * *", + "timezone": "UTC", + "description": "Example periodic task", + "lastStatus": "ok", + "nextRun": null + } +] diff --git a/src/frontend/docs/COST-TRACKING.md b/src/frontend/docs/COST-TRACKING.md new file mode 100644 index 0000000..4055550 --- /dev/null +++ b/src/frontend/docs/COST-TRACKING.md @@ -0,0 +1,186 @@ +# Cost Tracking System + +Mission Control now tracks real usage costs by reading OpenClaw session data and calculating costs based on actual token usage. + +## How It Works + +1. **Data Collection**: The `collect-usage.ts` script reads `openclaw status --json` to get current session data +2. **Cost Calculation**: Uses model pricing table to calculate costs based on input/output tokens +3. **Storage**: Saves snapshots to SQLite database (`data/usage-tracking.db`) +4. **API**: The `/api/costs` endpoint queries the database to serve real cost data to the dashboard + +## Model Pricing + +Current pricing (as of Feb 2026): + +| Model | Input ($/M tokens) | Output ($/M tokens) | +|-------|-------------------|---------------------| +| Opus 4.6 | $15.00 | $75.00 | +| Sonnet 4.5 | $3.00 | $15.00 | +| Haiku 3.5 | $0.80 | $4.00 | +| Gemini Flash | $0.15 | $0.60 | +| Gemini Pro | $1.25 | $5.00 | +| Grok 4.1 Fast | $2.00 | $10.00 | + +Pricing is defined in `src/lib/pricing.ts`. + +## Manual Collection + +To collect usage data manually: + +```bash +cd /root/.openclaw/workspace/mission-control +npx tsx scripts/collect-usage.ts +``` + +This will: +- Read current OpenClaw session data +- Calculate costs for each agent + model combination +- Save a snapshot to the database (replacing any existing data for the same hour) + +## Automatic Collection (Cron) + +To set up hourly automatic collection: + +```bash +cd /root/.openclaw/workspace/mission-control +./scripts/setup-cron.sh +``` + +This adds a cron job that runs every hour at minute 0. + +**View cron jobs:** +```bash +crontab -l +``` + +**View logs:** +```bash +tail -f /var/log/mission-control-usage.log +``` + +**Remove cron job:** +```bash +crontab -e +# Delete the line containing 'collect-usage.ts' +``` + +## Database Schema + +```sql +CREATE TABLE usage_snapshots ( + id INTEGER PRIMARY KEY AUTOINCREMENT, + timestamp INTEGER NOT NULL, + date TEXT NOT NULL, -- YYYY-MM-DD + hour INTEGER NOT NULL, -- 0-23 + agent_id TEXT NOT NULL, + model TEXT NOT NULL, + input_tokens INTEGER NOT NULL, + output_tokens INTEGER NOT NULL, + total_tokens INTEGER NOT NULL, + cost REAL NOT NULL, + created_at INTEGER DEFAULT (strftime('%s', 'now')) +); +``` + +## Querying the Database + +**Total cost today:** +```bash +sqlite3 data/usage-tracking.db \ + "SELECT SUM(cost) FROM usage_snapshots WHERE date = date('now');" +``` + +**Cost by agent (last 30 days):** +```bash +sqlite3 data/usage-tracking.db \ + "SELECT agent_id, ROUND(SUM(cost), 2) as cost + FROM usage_snapshots + WHERE date >= date('now', '-30 days') + GROUP BY agent_id + ORDER BY cost DESC;" +``` + +**Cost by model:** +```bash +sqlite3 data/usage-tracking.db \ + "SELECT model, ROUND(SUM(cost), 2) as cost + FROM usage_snapshots + WHERE date >= date('now', '-30 days') + GROUP BY model + ORDER BY cost DESC;" +``` + +**Daily trend (last 7 days):** +```bash +sqlite3 data/usage-tracking.db \ + "SELECT date, ROUND(SUM(cost), 2) as cost + FROM usage_snapshots + WHERE date >= date('now', '-7 days') + GROUP BY date + ORDER BY date DESC;" +``` + +## API Endpoints + +### GET /api/costs + +Returns cost summary, breakdowns, and trends. + +**Query params:** +- `timeframe` (default: `30d`) - Number of days to include in aggregations + +**Response:** +```json +{ + "today": 0.80, + "yesterday": 1.25, + "thisMonth": 12.50, + "lastMonth": 38.90, + "projected": 52.30, + "budget": 100.00, + "byAgent": [ + { "agent": "main", "cost": 5.50, "tokens": 450000, "percentOfTotal": 44 } + ], + "byModel": [ + { "model": "anthropic/claude-sonnet-4-5", "cost": 8.30, "tokens": 890000, "percentOfTotal": 66 } + ], + "daily": [ + { "date": "02-20", "cost": 0.80, "input": 12000, "output": 8000 } + ], + "hourly": [ + { "hour": "14:00", "cost": 0.12 } + ] +} +``` + +## Troubleshooting + +**No data showing up:** +- Run `npx tsx scripts/collect-usage.ts` to collect initial data +- Check database exists: `ls -lh data/usage-tracking.db` +- Query database: `sqlite3 data/usage-tracking.db "SELECT COUNT(*) FROM usage_snapshots;"` + +**Unknown model warnings:** +- Update `src/lib/pricing.ts` with new model pricing +- Rebuild: `npm run build` +- Restart: `systemctl restart mission-control` + +**Costs seem wrong:** +- Verify pricing in `src/lib/pricing.ts` +- Check token counts: `openclaw status --json | jq '.sessions.byAgent[].recent[].totalTokens'` +- Recalculate: delete database and re-collect + +## Future Enhancements + +- [ ] Budget alerts (email/Telegram when >80% spent) +- [ ] Export reports (PDF/CSV) +- [ ] Cost forecasting with ML +- [ ] Per-session cost tracking (not just agent totals) +- [ ] Integration with OpenRouter billing API for real invoices +- [ ] Cost optimization suggestions ("switch to Haiku for heartbeats") + +--- + +**Created:** 2026-02-20 +**Author:** Tenacitas 🦞 diff --git a/src/frontend/docs/screenshots/costs.jpg b/src/frontend/docs/screenshots/costs.jpg new file mode 100644 index 0000000..10f3a90 Binary files /dev/null and b/src/frontend/docs/screenshots/costs.jpg differ diff --git a/src/frontend/docs/screenshots/dashboard.jpg b/src/frontend/docs/screenshots/dashboard.jpg new file mode 100644 index 0000000..d6222c9 Binary files /dev/null and b/src/frontend/docs/screenshots/dashboard.jpg differ diff --git a/src/frontend/docs/screenshots/office3d.jpg b/src/frontend/docs/screenshots/office3d.jpg new file mode 100644 index 0000000..4690d9a Binary files /dev/null and b/src/frontend/docs/screenshots/office3d.jpg differ diff --git a/src/frontend/docs/screenshots/sessions.jpg b/src/frontend/docs/screenshots/sessions.jpg new file mode 100644 index 0000000..725c74d Binary files /dev/null and b/src/frontend/docs/screenshots/sessions.jpg differ diff --git a/src/frontend/docs/screenshots/system.jpg b/src/frontend/docs/screenshots/system.jpg new file mode 100644 index 0000000..3a08af7 Binary files /dev/null and b/src/frontend/docs/screenshots/system.jpg differ diff --git a/src/frontend/eslint.config.mjs b/src/frontend/eslint.config.mjs index 549f000..05e726d 100644 --- a/src/frontend/eslint.config.mjs +++ b/src/frontend/eslint.config.mjs @@ -11,26 +11,8 @@ const eslintConfig = defineConfig([ ".next/**", "out/**", "build/**", - "coverage/**", "next-env.d.ts", - "tailwind.config.*", - "postcss.config.*", - "orval.config.*", ]), - { - rules: { - // We intentionally prefix unused destructured props with "_" to avoid - // passing them to DOM elements (e.g. react-markdown's `node` prop). - "@typescript-eslint/no-unused-vars": [ - "warn", - { - argsIgnorePattern: "^_", - varsIgnorePattern: "^_", - caughtErrorsIgnorePattern: "^_", - }, - ], - }, - }, ]); export default eslintConfig; diff --git a/src/frontend/next.config.mjs b/src/frontend/next.config.mjs new file mode 100644 index 0000000..caa9a76 --- /dev/null +++ b/src/frontend/next.config.mjs @@ -0,0 +1,8 @@ +/** @type {import('next').NextConfig} */ +const nextConfig = { + allowedDevOrigins: process.env.ALLOWED_DEV_ORIGINS + ? process.env.ALLOWED_DEV_ORIGINS.split(",") + : [], +}; + +export default nextConfig; diff --git a/src/frontend/next.config.ts b/src/frontend/next.config.ts deleted file mode 100644 index 8c034bc..0000000 --- a/src/frontend/next.config.ts +++ /dev/null @@ -1,19 +0,0 @@ -import type { NextConfig } from "next"; - -const nextConfig: NextConfig = { - // In dev, Next may proxy requests based on the request origin/host. - // Allow common local origins so `next dev --hostname 127.0.0.1` works - // when users access via http://localhost:3000 or http://127.0.0.1:3000. - // Keep the LAN IP as well for dev on the local network. - allowedDevOrigins: ["192.168.1.101", "localhost", "127.0.0.1"], - images: { - remotePatterns: [ - { - protocol: "https", - hostname: "img.clerk.com", - }, - ], - }, -}; - -export default nextConfig; diff --git a/src/frontend/orval.config.ts b/src/frontend/orval.config.ts deleted file mode 100644 index 9f7ce80..0000000 --- a/src/frontend/orval.config.ts +++ /dev/null @@ -1,26 +0,0 @@ -import { defineConfig } from "orval"; - -export default defineConfig({ - api: { - input: { - target: process.env.ORVAL_INPUT ?? "http://127.0.0.1:8000/openapi.json", - }, - output: { - mode: "tags-split", - target: "src/api/generated/index.ts", - schemas: "src/api/generated/model", - client: "react-query", - prettier: true, - override: { - mutator: { - path: "src/api/mutator.ts", - name: "customFetch", - }, - query: { - useQuery: true, - useMutation: true, - }, - }, - }, - }, -}); diff --git a/src/frontend/package-lock.json b/src/frontend/package-lock.json index fa4eaaf..9dc39e3 100644 --- a/src/frontend/package-lock.json +++ b/src/frontend/package-lock.json @@ -1,64 +1,40 @@ { - "name": "frontend", - "version": "0.1.0", + "name": "mission-control", + "version": "0.5.0", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "frontend", - "version": "0.1.0", + "name": "mission-control", + "version": "0.5.0", "dependencies": { - "@clerk/nextjs": "^6.37.3", - "@radix-ui/react-dialog": "^1.1.15", - "@radix-ui/react-popover": "^1.1.15", - "@radix-ui/react-select": "^2.2.6", - "@radix-ui/react-tabs": "^1.1.13", - "@radix-ui/react-tooltip": "^1.2.8", - "@tanstack/react-query": "^5.90.21", - "@tanstack/react-table": "^8.21.3", - "cmdk": "^1.1.1", - "next": "16.1.7", - "react": "19.2.4", - "react-dom": "19.2.4", + "@monaco-editor/react": "^4.7.0", + "@react-three/drei": "^10.7.7", + "@react-three/fiber": "^9.5.0", + "@react-three/rapier": "^2.2.0", + "@tailwindcss/typography": "^0.5.19", + "@types/better-sqlite3": "^7.6.13", + "better-sqlite3": "^12.6.2", + "date-fns": "^4.1.0", + "lucide-react": "^0.563.0", + "next": "16.1.6", + "react": "19.2.3", + "react-dom": "19.2.3", "react-markdown": "^10.1.0", - "recharts": "^3.7.0", - "remark-breaks": "^4.0.0", - "remark-gfm": "^4.0.1" + "recharts": "^2.15.4", + "three": "^0.183.0" }, "devDependencies": { - "@clerk/testing": "^1.13.35", - "@testing-library/jest-dom": "^6.9.1", - "@testing-library/react": "^16.3.2", - "@testing-library/user-event": "^14.6.1", + "@tailwindcss/postcss": "^4", "@types/node": "^20", "@types/react": "^19", "@types/react-dom": "^19", - "@vitest/coverage-v8": "^4.0.18", - "autoprefixer": "^10.4.24", - "class-variance-authority": "^0.7.1", - "clsx": "^2.1.1", - "cypress": "^14.5.4", "eslint": "^9", "eslint-config-next": "16.1.6", - "jsdom": "^25.0.1", - "lucide-react": "^0.563.0", - "orval": "^8.3.0", - "postcss": "^8.5.6", - "prettier": "^3.8.1", - "tailwind-merge": "^3.4.0", - "tailwindcss": "^3.4.19", - "tailwindcss-animate": "^1.0.7", - "typescript": "^5", - "vitest": "^4.0.18" + "tailwindcss": "^4", + "typescript": "^5" } }, - "node_modules/@adobe/css-tools": { - "version": "4.4.4", - "resolved": "https://registry.npmjs.org/@adobe/css-tools/-/css-tools-4.4.4.tgz", - "integrity": "sha512-Elp+iwUx5rN5+Y8xLt5/GRoG20WGoDCQ/1Fb+1LiGtvwbDavuSk0jhD/eZdckHAuzcDzccnkv+rEjyWfRx18gg==", - "dev": true, - "license": "MIT" - }, "node_modules/@alloc/quick-lru": { "version": "5.2.0", "resolved": "https://registry.npmjs.org/@alloc/quick-lru/-/quick-lru-5.2.0.tgz", @@ -72,27 +48,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@asamuzakjp/css-color": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/@asamuzakjp/css-color/-/css-color-3.2.0.tgz", - "integrity": "sha512-K1A6z8tS3XsmCMM86xoWdn7Fkdn9m6RSVtocUrJYIwZnFVkng/PvkEoWtOWmP+Scc6saYWHWZYbndEEXxl24jw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@csstools/css-calc": "^2.1.3", - "@csstools/css-color-parser": "^3.0.9", - "@csstools/css-parser-algorithms": "^3.0.4", - "@csstools/css-tokenizer": "^3.0.3", - "lru-cache": "^10.4.3" - } - }, - "node_modules/@asamuzakjp/css-color/node_modules/lru-cache": { - "version": "10.4.3", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", - "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", - "dev": true, - "license": "ISC" - }, "node_modules/@babel/code-frame": { "version": "7.29.0", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.29.0.tgz", @@ -149,16 +104,6 @@ "url": "https://opencollective.com/babel" } }, - "node_modules/@babel/core/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", - "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver.js" - } - }, "node_modules/@babel/generator": { "version": "7.29.1", "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.29.1.tgz", @@ -193,16 +138,6 @@ "node": ">=6.9.0" } }, - "node_modules/@babel/helper-compilation-targets/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", - "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver.js" - } - }, "node_modules/@babel/helper-globals": { "version": "7.28.0", "resolved": "https://registry.npmjs.org/@babel/helper-globals/-/helper-globals-7.28.0.tgz", @@ -309,7 +244,6 @@ "version": "7.28.6", "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.28.6.tgz", "integrity": "sha512-05WQkdpL9COIMz4LjTxGpPNCdlpyimKppYNoJ5Di5EUObifl8t4tuLuUBBZEpoLYOmfvIWrsp9fCl0HoPRVTdA==", - "dev": true, "license": "MIT", "engines": { "node": ">=6.9.0" @@ -363,305 +297,11 @@ "node": ">=6.9.0" } }, - "node_modules/@bcoe/v8-coverage": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@bcoe/v8-coverage/-/v8-coverage-1.0.2.tgz", - "integrity": "sha512-6zABk/ECA/QYSCQ1NGiVwwbQerUCZ+TQbp64Q3AgmfNvurHH0j8TtXa1qbShXA6qqkpAj4V5W8pP6mLe1mcMqA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - } - }, - "node_modules/@clerk/backend": { - "version": "2.30.1", - "resolved": "https://registry.npmjs.org/@clerk/backend/-/backend-2.30.1.tgz", - "integrity": "sha512-GoxnJzVH0ycNPAGCDMfo3lPBFbo5nehpLSVFjgGEnzIRGGahBtAB8PQT7KM2zo58pD8apjb/+suhcB/WCiEasQ==", - "license": "MIT", - "dependencies": { - "@clerk/shared": "^3.44.0", - "@clerk/types": "^4.101.14", - "standardwebhooks": "^1.0.0", - "tslib": "2.8.1" - }, - "engines": { - "node": ">=18.17.0" - } - }, - "node_modules/@clerk/clerk-react": { - "version": "5.60.0", - "resolved": "https://registry.npmjs.org/@clerk/clerk-react/-/clerk-react-5.60.0.tgz", - "integrity": "sha512-P88FncsJpq/3WZJhhlj+md8mYb35BIXpr462C/figwsBGHsinr8VuBQUMcMZZ/6M34C8ABfLTPa6PHVp6+3D5Q==", - "license": "MIT", - "dependencies": { - "@clerk/shared": "^3.44.0", - "tslib": "2.8.1" - }, - "engines": { - "node": ">=18.17.0" - }, - "peerDependencies": { - "react": "^18.0.0 || ~19.0.3 || ~19.1.4 || ~19.2.3 || ~19.3.0-0", - "react-dom": "^18.0.0 || ~19.0.3 || ~19.1.4 || ~19.2.3 || ~19.3.0-0" - } - }, - "node_modules/@clerk/nextjs": { - "version": "6.37.3", - "resolved": "https://registry.npmjs.org/@clerk/nextjs/-/nextjs-6.37.3.tgz", - "integrity": "sha512-kammmf4b5R2Izb/SN4UbEa/6rdyop9fPHwZkyyJoVfgMLFM26fwpXWaSqVJPe4YL2BmHKP+orIOolzTmEhhdQQ==", - "license": "MIT", - "dependencies": { - "@clerk/backend": "^2.30.1", - "@clerk/clerk-react": "^5.60.0", - "@clerk/shared": "^3.44.0", - "@clerk/types": "^4.101.14", - "server-only": "0.0.1", - "tslib": "2.8.1" - }, - "engines": { - "node": ">=18.17.0" - }, - "peerDependencies": { - "next": "^13.5.7 || ^14.2.25 || ^15.2.3 || ^16", - "react": "^18.0.0 || ~19.0.3 || ~19.1.4 || ~19.2.3 || ~19.3.0-0", - "react-dom": "^18.0.0 || ~19.0.3 || ~19.1.4 || ~19.2.3 || ~19.3.0-0" - } - }, - "node_modules/@clerk/shared": { - "version": "3.44.0", - "resolved": "https://registry.npmjs.org/@clerk/shared/-/shared-3.44.0.tgz", - "integrity": "sha512-kH+chNeZwqml3IDpWLgebWECfOZifyUQO4OISd/96w1EuCY1Bzw6cBq/ZbpsoO8jyG8/6bGr/MGXLhDzTrpPfA==", - "hasInstallScript": true, - "license": "MIT", - "dependencies": { - "csstype": "3.1.3", - "dequal": "2.0.3", - "glob-to-regexp": "0.4.1", - "js-cookie": "3.0.5", - "std-env": "^3.9.0", - "swr": "2.3.4" - }, - "engines": { - "node": ">=18.17.0" - }, - "peerDependencies": { - "react": "^18.0.0 || ~19.0.3 || ~19.1.4 || ~19.2.3 || ~19.3.0-0", - "react-dom": "^18.0.0 || ~19.0.3 || ~19.1.4 || ~19.2.3 || ~19.3.0-0" - }, - "peerDependenciesMeta": { - "react": { - "optional": true - }, - "react-dom": { - "optional": true - } - } - }, - "node_modules/@clerk/testing": { - "version": "1.13.35", - "resolved": "https://registry.npmjs.org/@clerk/testing/-/testing-1.13.35.tgz", - "integrity": "sha512-y95kJZrMt0tvbNek1AWhWrNrgnOy+a53PSzHTHPF9d0kkOgzzu9l/Wq+Y0kBk6p64wtupYomeb7oVCQD7yCc0A==", - "dev": true, - "license": "MIT", - "dependencies": { - "@clerk/backend": "^2.30.1", - "@clerk/shared": "^3.44.0", - "@clerk/types": "^4.101.14", - "dotenv": "17.2.2" - }, - "engines": { - "node": ">=18.17.0" - }, - "peerDependencies": { - "@playwright/test": "^1", - "cypress": "^13 || ^14" - }, - "peerDependenciesMeta": { - "@playwright/test": { - "optional": true - }, - "cypress": { - "optional": true - } - } - }, - "node_modules/@clerk/types": { - "version": "4.101.14", - "resolved": "https://registry.npmjs.org/@clerk/types/-/types-4.101.14.tgz", - "integrity": "sha512-jl7DywmeaZx1IntgEXcjDZq2uyk+X/1yAZOjxOboeGTS0rNTiQNhv7xK8tFVjexsUAFrYlwC1AxhFuJiMDQjow==", - "license": "MIT", - "dependencies": { - "@clerk/shared": "^3.44.0" - }, - "engines": { - "node": ">=18.17.0" - } - }, - "node_modules/@csstools/color-helpers": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/@csstools/color-helpers/-/color-helpers-5.1.0.tgz", - "integrity": "sha512-S11EXWJyy0Mz5SYvRmY8nJYTFFd1LCNV+7cXyAgQtOOuzb4EsgfqDufL+9esx72/eLhsRdGZwaldu/h+E4t4BA==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/csstools" - }, - { - "type": "opencollective", - "url": "https://opencollective.com/csstools" - } - ], - "license": "MIT-0", - "engines": { - "node": ">=18" - } - }, - "node_modules/@csstools/css-calc": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/@csstools/css-calc/-/css-calc-2.1.4.tgz", - "integrity": "sha512-3N8oaj+0juUw/1H3YwmDDJXCgTB1gKU6Hc/bB502u9zR0q2vd786XJH9QfrKIEgFlZmhZiq6epXl4rHqhzsIgQ==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/csstools" - }, - { - "type": "opencollective", - "url": "https://opencollective.com/csstools" - } - ], - "license": "MIT", - "engines": { - "node": ">=18" - }, - "peerDependencies": { - "@csstools/css-parser-algorithms": "^3.0.5", - "@csstools/css-tokenizer": "^3.0.4" - } - }, - "node_modules/@csstools/css-color-parser": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/@csstools/css-color-parser/-/css-color-parser-3.1.0.tgz", - "integrity": "sha512-nbtKwh3a6xNVIp/VRuXV64yTKnb1IjTAEEh3irzS+HkKjAOYLTGNb9pmVNntZ8iVBHcWDA2Dof0QtPgFI1BaTA==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/csstools" - }, - { - "type": "opencollective", - "url": "https://opencollective.com/csstools" - } - ], - "license": "MIT", - "dependencies": { - "@csstools/color-helpers": "^5.1.0", - "@csstools/css-calc": "^2.1.4" - }, - "engines": { - "node": ">=18" - }, - "peerDependencies": { - "@csstools/css-parser-algorithms": "^3.0.5", - "@csstools/css-tokenizer": "^3.0.4" - } - }, - "node_modules/@csstools/css-parser-algorithms": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@csstools/css-parser-algorithms/-/css-parser-algorithms-3.0.5.tgz", - "integrity": "sha512-DaDeUkXZKjdGhgYaHNJTV9pV7Y9B3b644jCLs9Upc3VeNGg6LWARAT6O+Q+/COo+2gg/bM5rhpMAtf70WqfBdQ==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/csstools" - }, - { - "type": "opencollective", - "url": "https://opencollective.com/csstools" - } - ], - "license": "MIT", - "engines": { - "node": ">=18" - }, - "peerDependencies": { - "@csstools/css-tokenizer": "^3.0.4" - } - }, - "node_modules/@csstools/css-tokenizer": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@csstools/css-tokenizer/-/css-tokenizer-3.0.4.tgz", - "integrity": "sha512-Vd/9EVDiu6PPJt9yAh6roZP6El1xHrdvIVGjyBsHR0RYwNHgL7FJPyIIW4fANJNG6FtyZfvlRPpFI4ZM/lubvw==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/csstools" - }, - { - "type": "opencollective", - "url": "https://opencollective.com/csstools" - } - ], - "license": "MIT", - "engines": { - "node": ">=18" - } - }, - "node_modules/@cypress/request": { - "version": "3.0.10", - "resolved": "https://registry.npmjs.org/@cypress/request/-/request-3.0.10.tgz", - "integrity": "sha512-hauBrOdvu08vOsagkZ/Aju5XuiZx6ldsLfByg1htFeldhex+PeMrYauANzFsMJeAA0+dyPLbDoX2OYuvVoLDkQ==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "aws-sign2": "~0.7.0", - "aws4": "^1.8.0", - "caseless": "~0.12.0", - "combined-stream": "~1.0.6", - "extend": "~3.0.2", - "forever-agent": "~0.6.1", - "form-data": "~4.0.4", - "http-signature": "~1.4.0", - "is-typedarray": "~1.0.0", - "isstream": "~0.1.2", - "json-stringify-safe": "~5.0.1", - "mime-types": "~2.1.19", - "performance-now": "^2.1.0", - "qs": "~6.14.1", - "safe-buffer": "^5.1.2", - "tough-cookie": "^5.0.0", - "tunnel-agent": "^0.6.0", - "uuid": "^8.3.2" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/@cypress/xvfb": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/@cypress/xvfb/-/xvfb-1.2.4.tgz", - "integrity": "sha512-skbBzPggOVYCbnGgV+0dmBdW/s77ZkAOXIC1knS8NagwDjBrNC1LuXtQJeiN6l+m7lzmHtaoUw/ctJKdqkG57Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "debug": "^3.1.0", - "lodash.once": "^4.1.1" - } - }, - "node_modules/@cypress/xvfb/node_modules/debug": { - "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "ms": "^2.1.1" - } + "node_modules/@dimforge/rapier3d-compat": { + "version": "0.19.2", + "resolved": "https://registry.npmjs.org/@dimforge/rapier3d-compat/-/rapier3d-compat-0.19.2.tgz", + "integrity": "sha512-AZHL1jqUF55QJkJyU1yKeh4ImX2J93bVLIezT1+o0FZqTix6O06MOaqpKoJ4MmbDCsoZmwO+qc471/SDMDm2AA==", + "license": "Apache-2.0" }, "node_modules/@emnapi/core": { "version": "1.8.1", @@ -696,448 +336,6 @@ "tslib": "^2.4.0" } }, - "node_modules/@esbuild/aix-ppc64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.27.3.tgz", - "integrity": "sha512-9fJMTNFTWZMh5qwrBItuziu834eOCUcEqymSH7pY+zoMVEZg3gcPuBNxH1EvfVYe9h0x/Ptw8KBzv7qxb7l8dg==", - "cpu": [ - "ppc64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "aix" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/android-arm": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.27.3.tgz", - "integrity": "sha512-i5D1hPY7GIQmXlXhs2w8AWHhenb00+GxjxRncS2ZM7YNVGNfaMxgzSGuO8o8SJzRc/oZwU2bcScvVERk03QhzA==", - "cpu": [ - "arm" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "android" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/android-arm64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.27.3.tgz", - "integrity": "sha512-YdghPYUmj/FX2SYKJ0OZxf+iaKgMsKHVPF1MAq/P8WirnSpCStzKJFjOjzsW0QQ7oIAiccHdcqjbHmJxRb/dmg==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "android" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/android-x64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.27.3.tgz", - "integrity": "sha512-IN/0BNTkHtk8lkOM8JWAYFg4ORxBkZQf9zXiEOfERX/CzxW3Vg1ewAhU7QSWQpVIzTW+b8Xy+lGzdYXV6UZObQ==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "android" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/darwin-arm64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.27.3.tgz", - "integrity": "sha512-Re491k7ByTVRy0t3EKWajdLIr0gz2kKKfzafkth4Q8A5n1xTHrkqZgLLjFEHVD+AXdUGgQMq+Godfq45mGpCKg==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/darwin-x64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.27.3.tgz", - "integrity": "sha512-vHk/hA7/1AckjGzRqi6wbo+jaShzRowYip6rt6q7VYEDX4LEy1pZfDpdxCBnGtl+A5zq8iXDcyuxwtv3hNtHFg==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/freebsd-arm64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.27.3.tgz", - "integrity": "sha512-ipTYM2fjt3kQAYOvo6vcxJx3nBYAzPjgTCk7QEgZG8AUO3ydUhvelmhrbOheMnGOlaSFUoHXB6un+A7q4ygY9w==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/freebsd-x64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.27.3.tgz", - "integrity": "sha512-dDk0X87T7mI6U3K9VjWtHOXqwAMJBNN2r7bejDsc+j03SEjtD9HrOl8gVFByeM0aJksoUuUVU9TBaZa2rgj0oA==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-arm": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.27.3.tgz", - "integrity": "sha512-s6nPv2QkSupJwLYyfS+gwdirm0ukyTFNl3KTgZEAiJDd+iHZcbTPPcWCcRYH+WlNbwChgH2QkE9NSlNrMT8Gfw==", - "cpu": [ - "arm" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-arm64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.27.3.tgz", - "integrity": "sha512-sZOuFz/xWnZ4KH3YfFrKCf1WyPZHakVzTiqji3WDc0BCl2kBwiJLCXpzLzUBLgmp4veFZdvN5ChW4Eq/8Fc2Fg==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-ia32": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.27.3.tgz", - "integrity": "sha512-yGlQYjdxtLdh0a3jHjuwOrxQjOZYD/C9PfdbgJJF3TIZWnm/tMd/RcNiLngiu4iwcBAOezdnSLAwQDPqTmtTYg==", - "cpu": [ - "ia32" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-loong64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.27.3.tgz", - "integrity": "sha512-WO60Sn8ly3gtzhyjATDgieJNet/KqsDlX5nRC5Y3oTFcS1l0KWba+SEa9Ja1GfDqSF1z6hif/SkpQJbL63cgOA==", - "cpu": [ - "loong64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-mips64el": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.27.3.tgz", - "integrity": "sha512-APsymYA6sGcZ4pD6k+UxbDjOFSvPWyZhjaiPyl/f79xKxwTnrn5QUnXR5prvetuaSMsb4jgeHewIDCIWljrSxw==", - "cpu": [ - "mips64el" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-ppc64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.27.3.tgz", - "integrity": "sha512-eizBnTeBefojtDb9nSh4vvVQ3V9Qf9Df01PfawPcRzJH4gFSgrObw+LveUyDoKU3kxi5+9RJTCWlj4FjYXVPEA==", - "cpu": [ - "ppc64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-riscv64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.27.3.tgz", - "integrity": "sha512-3Emwh0r5wmfm3ssTWRQSyVhbOHvqegUDRd0WhmXKX2mkHJe1SFCMJhagUleMq+Uci34wLSipf8Lagt4LlpRFWQ==", - "cpu": [ - "riscv64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-s390x": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.27.3.tgz", - "integrity": "sha512-pBHUx9LzXWBc7MFIEEL0yD/ZVtNgLytvx60gES28GcWMqil8ElCYR4kvbV2BDqsHOvVDRrOxGySBM9Fcv744hw==", - "cpu": [ - "s390x" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-x64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.27.3.tgz", - "integrity": "sha512-Czi8yzXUWIQYAtL/2y6vogER8pvcsOsk5cpwL4Gk5nJqH5UZiVByIY8Eorm5R13gq+DQKYg0+JyQoytLQas4dA==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/netbsd-arm64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.27.3.tgz", - "integrity": "sha512-sDpk0RgmTCR/5HguIZa9n9u+HVKf40fbEUt+iTzSnCaGvY9kFP0YKBWZtJaraonFnqef5SlJ8/TiPAxzyS+UoA==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/netbsd-x64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.27.3.tgz", - "integrity": "sha512-P14lFKJl/DdaE00LItAukUdZO5iqNH7+PjoBm+fLQjtxfcfFE20Xf5CrLsmZdq5LFFZzb5JMZ9grUwvtVYzjiA==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/openbsd-arm64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.27.3.tgz", - "integrity": "sha512-AIcMP77AvirGbRl/UZFTq5hjXK+2wC7qFRGoHSDrZ5v5b8DK/GYpXW3CPRL53NkvDqb9D+alBiC/dV0Fb7eJcw==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/openbsd-x64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.27.3.tgz", - "integrity": "sha512-DnW2sRrBzA+YnE70LKqnM3P+z8vehfJWHXECbwBmH/CU51z6FiqTQTHFenPlHmo3a8UgpLyH3PT+87OViOh1AQ==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/openharmony-arm64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.27.3.tgz", - "integrity": "sha512-NinAEgr/etERPTsZJ7aEZQvvg/A6IsZG/LgZy+81wON2huV7SrK3e63dU0XhyZP4RKGyTm7aOgmQk0bGp0fy2g==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openharmony" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/sunos-x64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.27.3.tgz", - "integrity": "sha512-PanZ+nEz+eWoBJ8/f8HKxTTD172SKwdXebZ0ndd953gt1HRBbhMsaNqjTyYLGLPdoWHy4zLU7bDVJztF5f3BHA==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "sunos" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/win32-arm64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.27.3.tgz", - "integrity": "sha512-B2t59lWWYrbRDw/tjiWOuzSsFh1Y/E95ofKz7rIVYSQkUYBjfSgf6oeYPNWHToFRr2zx52JKApIcAS/D5TUBnA==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/win32-ia32": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.27.3.tgz", - "integrity": "sha512-QLKSFeXNS8+tHW7tZpMtjlNb7HKau0QDpwm49u0vUp9y1WOF+PEzkU84y9GqYaAVW8aH8f3GcBck26jh54cX4Q==", - "cpu": [ - "ia32" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/win32-x64": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.27.3.tgz", - "integrity": "sha512-4uJGhsxuptu3OcpVAzli+/gWusVGwZZHTlS63hh++ehExkVT8SgiEf7/uC/PclrPPkLhZqGgCTjd0VWLo6xMqA==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">=18" - } - }, "node_modules/@eslint-community/eslint-utils": { "version": "4.9.1", "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.9.1.tgz", @@ -1282,58 +480,6 @@ "node": "^18.18.0 || ^20.9.0 || >=21.1.0" } }, - "node_modules/@floating-ui/core": { - "version": "1.7.4", - "resolved": "https://registry.npmjs.org/@floating-ui/core/-/core-1.7.4.tgz", - "integrity": "sha512-C3HlIdsBxszvm5McXlB8PeOEWfBhcGBTZGkGlWc2U0KFY5IwG5OQEuQ8rq52DZmcHDlPLd+YFBK+cZcytwIFWg==", - "license": "MIT", - "dependencies": { - "@floating-ui/utils": "^0.2.10" - } - }, - "node_modules/@floating-ui/dom": { - "version": "1.7.5", - "resolved": "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.7.5.tgz", - "integrity": "sha512-N0bD2kIPInNHUHehXhMke1rBGs1dwqvC9O9KYMyyjK7iXt7GAhnro7UlcuYcGdS/yYOlq0MAVgrow8IbWJwyqg==", - "license": "MIT", - "dependencies": { - "@floating-ui/core": "^1.7.4", - "@floating-ui/utils": "^0.2.10" - } - }, - "node_modules/@floating-ui/react-dom": { - "version": "2.1.7", - "resolved": "https://registry.npmjs.org/@floating-ui/react-dom/-/react-dom-2.1.7.tgz", - "integrity": "sha512-0tLRojf/1Go2JgEVm+3Frg9A3IW8bJgKgdO0BN5RkF//ufuz2joZM63Npau2ff3J6lUVYgDSNzNkR+aH3IVfjg==", - "license": "MIT", - "dependencies": { - "@floating-ui/dom": "^1.7.5" - }, - "peerDependencies": { - "react": ">=16.8.0", - "react-dom": ">=16.8.0" - } - }, - "node_modules/@floating-ui/utils": { - "version": "0.2.10", - "resolved": "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.2.10.tgz", - "integrity": "sha512-aGTxbpbg8/b5JfU1HXSrbH3wXZuLPJcNEcZQFMxLs3oSzgtVu6nFPkbbGGUvBcUjKV2YyB9Wxxabo+HEH9tcRQ==", - "license": "MIT" - }, - "node_modules/@gerrit0/mini-shiki": { - "version": "3.22.0", - "resolved": "https://registry.npmjs.org/@gerrit0/mini-shiki/-/mini-shiki-3.22.0.tgz", - "integrity": "sha512-jMpciqEVUBKE1QwU64S4saNMzpsSza6diNCk4MWAeCxO2+LFi2FIFmL2S0VDLzEJCxuvCbU783xi8Hp/gkM5CQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@shikijs/engine-oniguruma": "^3.22.0", - "@shikijs/langs": "^3.22.0", - "@shikijs/themes": "^3.22.0", - "@shikijs/types": "^3.22.0", - "@shikijs/vscode-textmate": "^10.0.2" - } - }, "node_modules/@humanfs/core": { "version": "0.19.1", "resolved": "https://registry.npmjs.org/@humanfs/core/-/core-0.19.1.tgz", @@ -1902,6 +1048,47 @@ "@jridgewell/sourcemap-codec": "^1.4.14" } }, + "node_modules/@mediapipe/tasks-vision": { + "version": "0.10.17", + "resolved": "https://registry.npmjs.org/@mediapipe/tasks-vision/-/tasks-vision-0.10.17.tgz", + "integrity": "sha512-CZWV/q6TTe8ta61cZXjfnnHsfWIdFhms03M9T7Cnd5y2mdpylJM0rF1qRq+wsQVRMLz1OYPVEBU9ph2Bx8cxrg==", + "license": "Apache-2.0" + }, + "node_modules/@monaco-editor/loader": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/@monaco-editor/loader/-/loader-1.7.0.tgz", + "integrity": "sha512-gIwR1HrJrrx+vfyOhYmCZ0/JcWqG5kbfG7+d3f/C1LXk2EvzAbHSg3MQ5lO2sMlo9izoAZ04shohfKLVT6crVA==", + "license": "MIT", + "dependencies": { + "state-local": "^1.0.6" + } + }, + "node_modules/@monaco-editor/react": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/@monaco-editor/react/-/react-4.7.0.tgz", + "integrity": "sha512-cyzXQCtO47ydzxpQtCGSQGOC8Gk3ZUeBXFAxD+CWXYFo5OqZyZUonFl0DwUlTyAfRHntBfw2p3w4s9R6oe1eCA==", + "license": "MIT", + "dependencies": { + "@monaco-editor/loader": "^1.5.0" + }, + "peerDependencies": { + "monaco-editor": ">= 0.25.0 < 1", + "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0", + "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" + } + }, + "node_modules/@monogrid/gainmap-js": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/@monogrid/gainmap-js/-/gainmap-js-3.4.0.tgz", + "integrity": "sha512-2Z0FATFHaoYJ8b+Y4y4Hgfn3FRFwuU5zRrk+9dFWp4uGAdHGqVEdP7HP+gLA3X469KXHmfupJaUbKo1b/aDKIg==", + "license": "MIT", + "dependencies": { + "promise-worker-transferable": "^1.0.4" + }, + "peerDependencies": { + "three": ">= 0.159.0" + } + }, "node_modules/@napi-rs/wasm-runtime": { "version": "0.2.12", "resolved": "https://registry.npmjs.org/@napi-rs/wasm-runtime/-/wasm-runtime-0.2.12.tgz", @@ -1916,9 +1103,9 @@ } }, "node_modules/@next/env": { - "version": "16.1.7", - "resolved": "https://registry.npmjs.org/@next/env/-/env-16.1.7.tgz", - "integrity": "sha512-rJJbIdJB/RQr2F1nylZr/PJzamvNNhfr3brdKP6s/GW850jbtR70QlSfFselvIBbcPUOlQwBakexjFzqLzF6pg==", + "version": "16.1.6", + "resolved": "https://registry.npmjs.org/@next/env/-/env-16.1.6.tgz", + "integrity": "sha512-N1ySLuZjnAtN3kFnwhAwPvZah8RJxKasD7x1f8shFqhncnWZn4JMfg37diLNuoHsLAlrDfM3g4mawVdtAG8XLQ==", "license": "MIT" }, "node_modules/@next/eslint-plugin-next": { @@ -1932,9 +1119,9 @@ } }, "node_modules/@next/swc-darwin-arm64": { - "version": "16.1.7", - "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-16.1.7.tgz", - "integrity": "sha512-b2wWIE8sABdyafc4IM8r5Y/dS6kD80JRtOGrUiKTsACFQfWWgUQ2NwoUX1yjFMXVsAwcQeNpnucF2ZrujsBBPg==", + "version": "16.1.6", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-16.1.6.tgz", + "integrity": "sha512-wTzYulosJr/6nFnqGW7FrG3jfUUlEf8UjGA0/pyypJl42ExdVgC6xJgcXQ+V8QFn6niSG2Pb8+MIG1mZr2vczw==", "cpu": [ "arm64" ], @@ -1948,9 +1135,9 @@ } }, "node_modules/@next/swc-darwin-x64": { - "version": "16.1.7", - "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-16.1.7.tgz", - "integrity": "sha512-zcnVaaZulS1WL0Ss38R5Q6D2gz7MtBu8GZLPfK+73D/hp4GFMrC2sudLky1QibfV7h6RJBJs/gOFvYP0X7UVlQ==", + "version": "16.1.6", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-16.1.6.tgz", + "integrity": "sha512-BLFPYPDO+MNJsiDWbeVzqvYd4NyuRrEYVB5k2N3JfWncuHAy2IVwMAOlVQDFjj+krkWzhY2apvmekMkfQR0CUQ==", "cpu": [ "x64" ], @@ -1964,9 +1151,9 @@ } }, "node_modules/@next/swc-linux-arm64-gnu": { - "version": "16.1.7", - "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-16.1.7.tgz", - "integrity": "sha512-2ant89Lux/Q3VyC8vNVg7uBaFVP9SwoK2jJOOR0L8TQnX8CAYnh4uctAScy2Hwj2dgjVHqHLORQZJ2wH6VxhSQ==", + "version": "16.1.6", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-16.1.6.tgz", + "integrity": "sha512-OJYkCd5pj/QloBvoEcJ2XiMnlJkRv9idWA/j0ugSuA34gMT6f5b7vOiCQHVRpvStoZUknhl6/UxOXL4OwtdaBw==", "cpu": [ "arm64" ], @@ -1980,9 +1167,9 @@ } }, "node_modules/@next/swc-linux-arm64-musl": { - "version": "16.1.7", - "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-16.1.7.tgz", - "integrity": "sha512-uufcze7LYv0FQg9GnNeZ3/whYfo+1Q3HnQpm16o6Uyi0OVzLlk2ZWoY7j07KADZFY8qwDbsmFnMQP3p3+Ftprw==", + "version": "16.1.6", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-16.1.6.tgz", + "integrity": "sha512-S4J2v+8tT3NIO9u2q+S0G5KdvNDjXfAv06OhfOzNDaBn5rw84DGXWndOEB7d5/x852A20sW1M56vhC/tRVbccQ==", "cpu": [ "arm64" ], @@ -1996,9 +1183,9 @@ } }, "node_modules/@next/swc-linux-x64-gnu": { - "version": "16.1.7", - "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-16.1.7.tgz", - "integrity": "sha512-KWVf2gxYvHtvuT+c4MBOGxuse5TD7DsMFYSxVxRBnOzok/xryNeQSjXgxSv9QpIVlaGzEn/pIuI6Koosx8CGWA==", + "version": "16.1.6", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-16.1.6.tgz", + "integrity": "sha512-2eEBDkFlMMNQnkTyPBhQOAyn2qMxyG2eE7GPH2WIDGEpEILcBPI/jdSv4t6xupSP+ot/jkfrCShLAa7+ZUPcJQ==", "cpu": [ "x64" ], @@ -2012,9 +1199,9 @@ } }, "node_modules/@next/swc-linux-x64-musl": { - "version": "16.1.7", - "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-16.1.7.tgz", - "integrity": "sha512-HguhaGwsGr1YAGs68uRKc4aGWxLET+NevJskOcCAwXbwj0fYX0RgZW2gsOCzr9S11CSQPIkxmoSbuVaBp4Z3dA==", + "version": "16.1.6", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-16.1.6.tgz", + "integrity": "sha512-oicJwRlyOoZXVlxmIMaTq7f8pN9QNbdes0q2FXfRsPhfCi8n8JmOZJm5oo1pwDaFbnnD421rVU409M3evFbIqg==", "cpu": [ "x64" ], @@ -2028,9 +1215,9 @@ } }, "node_modules/@next/swc-win32-arm64-msvc": { - "version": "16.1.7", - "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-16.1.7.tgz", - "integrity": "sha512-S0n3KrDJokKTeFyM/vGGGR8+pCmXYrjNTk2ZozOL1C/JFdfUIL9O1ATaJOl5r2POe56iRChbsszrjMAdWSv7kQ==", + "version": "16.1.6", + "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-16.1.6.tgz", + "integrity": "sha512-gQmm8izDTPgs+DCWH22kcDmuUp7NyiJgEl18bcr8irXA5N2m2O+JQIr6f3ct42GOs9c0h8QF3L5SzIxcYAAXXw==", "cpu": [ "arm64" ], @@ -2044,9 +1231,9 @@ } }, "node_modules/@next/swc-win32-x64-msvc": { - "version": "16.1.7", - "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-16.1.7.tgz", - "integrity": "sha512-mwgtg8CNZGYm06LeEd+bNnOUfwOyNem/rOiP14Lsz+AnUY92Zq/LXwtebtUiaeVkhbroRCQ0c8GlR4UT1U+0yg==", + "version": "16.1.6", + "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-16.1.6.tgz", + "integrity": "sha512-NRfO39AIrzBnixKbjuo2YiYhB6o9d8v/ymU9m/Xk8cyVk+k7XylniXkHwjs4s70wedVffc6bQNbufk5v0xEm0A==", "cpu": [ "x64" ], @@ -2107,1267 +1294,133 @@ "node": ">=12.4.0" } }, - "node_modules/@orval/angular": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/@orval/angular/-/angular-8.3.0.tgz", - "integrity": "sha512-u4rnYUWA5S4wyCAmDF/Z2JUZKwyVVEoi0NOrXwprqh+t3ixriDb3dTJzu22CN8qCtlXmhcIU/rZDxsMzNgM03A==", - "dev": true, + "node_modules/@react-three/drei": { + "version": "10.7.7", + "resolved": "https://registry.npmjs.org/@react-three/drei/-/drei-10.7.7.tgz", + "integrity": "sha512-ff+J5iloR0k4tC++QtD/j9u3w5fzfgFAWDtAGQah9pF2B1YgOq/5JxqY0/aVoQG5r3xSZz0cv5tk2YuBob4xEQ==", "license": "MIT", "dependencies": { - "@orval/core": "8.3.0" - } - }, - "node_modules/@orval/axios": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/@orval/axios/-/axios-8.3.0.tgz", - "integrity": "sha512-a4ItU75sAbWTWaLyD79sRZVXpQBo1PdzaMS4LtfkLMtKIfBsBgqS3GU7EtFfpnmlFA+snEorHCQxmITqMYEXsg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@orval/core": "8.3.0" - } - }, - "node_modules/@orval/core": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/@orval/core/-/core-8.3.0.tgz", - "integrity": "sha512-YnRmHoD+J8zClMMuJpMPgtLFsdawIRCRqJbkTZyT4aeBQw8QcmUZpI+1yX/XOsOAwRawa87FNuQLPtU04LR1bg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@scalar/openapi-types": "0.5.3", - "acorn": "^8.15.0", - "chalk": "^5.6.2", - "compare-versions": "^6.1.1", - "debug": "^4.4.3", - "esbuild": "^0.27.2", - "esutils": "2.0.3", - "fs-extra": "^11.3.2", - "globby": "16.1.0", - "remeda": "^2.32.0", - "typedoc": "^0.28.15" - } - }, - "node_modules/@orval/core/node_modules/chalk": { - "version": "5.6.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.6.2.tgz", - "integrity": "sha512-7NzBL0rN6fMUW+f7A6Io4h40qQlG+xGmtMxfbnH/K7TAtt8JQWVQK+6g0UXKMeVJoyV5EkkNsErQ8pVD3bLHbA==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^12.17.0 || ^14.13 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@orval/core/node_modules/fs-extra": { - "version": "11.3.3", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.3.3.tgz", - "integrity": "sha512-VWSRii4t0AFm6ixFFmLLx1t7wS1gh+ckoa84aOeapGum0h+EZd1EhEumSB+ZdDLnEPuucsVB9oB7cxJHap6Afg==", - "dev": true, - "license": "MIT", - "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - }, - "engines": { - "node": ">=14.14" - } - }, - "node_modules/@orval/fetch": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/@orval/fetch/-/fetch-8.3.0.tgz", - "integrity": "sha512-HX6XDjWfa3yoMqszSUpfJGJ4HRPiRzt1gyEZDUiBKEtkWuFCv4SRt1TLaZ51yESjY+NyhK5unaCINb4TXQTOog==", - "dev": true, - "license": "MIT", - "dependencies": { - "@orval/core": "8.3.0", - "@scalar/openapi-types": "0.5.3" - } - }, - "node_modules/@orval/hono": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/@orval/hono/-/hono-8.3.0.tgz", - "integrity": "sha512-p9FwQtrZe1qLK3/8CRBAwfkwDNftpegbNdsC+ZBKqOjhU8EEUInsG3ViNdxE+iGC2PyStYkHv9z0T8H6SaXyrA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@orval/core": "8.3.0", - "@orval/zod": "8.3.0", - "fs-extra": "^11.3.2", - "remeda": "^2.32.0" - } - }, - "node_modules/@orval/hono/node_modules/fs-extra": { - "version": "11.3.3", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.3.3.tgz", - "integrity": "sha512-VWSRii4t0AFm6ixFFmLLx1t7wS1gh+ckoa84aOeapGum0h+EZd1EhEumSB+ZdDLnEPuucsVB9oB7cxJHap6Afg==", - "dev": true, - "license": "MIT", - "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - }, - "engines": { - "node": ">=14.14" - } - }, - "node_modules/@orval/mcp": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/@orval/mcp/-/mcp-8.3.0.tgz", - "integrity": "sha512-nKK92T8IMLxP0k4i5Fz/aMFYYF6e7vGzk9PpD9wPZOKq+UAYY3CO/FzOdaTqS818lH6P9lzzlHj6uHLUO8AP3g==", - "dev": true, - "license": "MIT", - "dependencies": { - "@orval/core": "8.3.0", - "@orval/fetch": "8.3.0", - "@orval/zod": "8.3.0" - } - }, - "node_modules/@orval/mock": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/@orval/mock/-/mock-8.3.0.tgz", - "integrity": "sha512-JakiizNRtTBf/RQlv0pX5sRt7uRrBEEDvt47W39PAYl/2zpKy9SryhmJ8KIH/cpC0SHTt7fgFNyS1Zt+GfqbTg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@orval/core": "8.3.0" - } - }, - "node_modules/@orval/query": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/@orval/query/-/query-8.3.0.tgz", - "integrity": "sha512-qw0HfyPkFZATlQiT478zVX9gCNFhCxbfgoLavoq3UdfB+QVT7eEjXrbYBjMvMik0WrPqznJGizmCgq82EyKaQQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@orval/core": "8.3.0", - "@orval/fetch": "8.3.0", - "chalk": "^5.6.2", - "remeda": "^2.32.0" - } - }, - "node_modules/@orval/query/node_modules/chalk": { - "version": "5.6.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.6.2.tgz", - "integrity": "sha512-7NzBL0rN6fMUW+f7A6Io4h40qQlG+xGmtMxfbnH/K7TAtt8JQWVQK+6g0UXKMeVJoyV5EkkNsErQ8pVD3bLHbA==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^12.17.0 || ^14.13 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@orval/solid-start": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/@orval/solid-start/-/solid-start-8.3.0.tgz", - "integrity": "sha512-OVnjGCZtMBKdo3SIiRwJKKrCi6/q3tLapUHpugZxEPWTAQCNmri5ADCNnuKfVFVNCmtPwyDSTVKf4rHnSSV2aA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@orval/core": "8.3.0" - } - }, - "node_modules/@orval/swr": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/@orval/swr/-/swr-8.3.0.tgz", - "integrity": "sha512-uyfePjCQZSMwy1urgPPPdwc0zB99beZf8fleAvJZRbYKBcM+8yRcjKjUj+nHp48LlkG6U8enWulNRXlZeupUGQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@orval/core": "8.3.0", - "@orval/fetch": "8.3.0" - } - }, - "node_modules/@orval/zod": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/@orval/zod/-/zod-8.3.0.tgz", - "integrity": "sha512-3jfLj/Az+7PI5J45+MiCuWooFjOu2APJV1+PcfYd7Bjb62SG9wsGG9BcbylgqUxdDXUlNUrt4qmzbBK8h62UAg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@orval/core": "8.3.0", - "remeda": "^2.32.0" - } - }, - "node_modules/@radix-ui/number": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/number/-/number-1.1.1.tgz", - "integrity": "sha512-MkKCwxlXTgz6CFoJx3pCwn07GKp36+aZyu/u2Ln2VrA5DcdyCZkASEDBTd8x5whTQQL5CiYf4prXKLcgQdv29g==", - "license": "MIT" - }, - "node_modules/@radix-ui/primitive": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/@radix-ui/primitive/-/primitive-1.1.3.tgz", - "integrity": "sha512-JTF99U/6XIjCBo0wqkU5sK10glYe27MRRsfwoiq5zzOEZLHU3A3KCMa5X/azekYRCJ0HlwI0crAXS/5dEHTzDg==", - "license": "MIT" - }, - "node_modules/@radix-ui/react-arrow": { - "version": "1.1.7", - "resolved": "https://registry.npmjs.org/@radix-ui/react-arrow/-/react-arrow-1.1.7.tgz", - "integrity": "sha512-F+M1tLhO+mlQaOWspE8Wstg+z6PwxwRd8oQ8IXceWz92kfAmalTRf0EjrouQeo7QssEPfCn05B4Ihs1K9WQ/7w==", - "license": "MIT", - "dependencies": { - "@radix-ui/react-primitive": "2.1.3" + "@babel/runtime": "^7.26.0", + "@mediapipe/tasks-vision": "0.10.17", + "@monogrid/gainmap-js": "^3.0.6", + "@use-gesture/react": "^10.3.1", + "camera-controls": "^3.1.0", + "cross-env": "^7.0.3", + "detect-gpu": "^5.0.56", + "glsl-noise": "^0.0.0", + "hls.js": "^1.5.17", + "maath": "^0.10.8", + "meshline": "^3.3.1", + "stats-gl": "^2.2.8", + "stats.js": "^0.17.0", + "suspend-react": "^0.1.3", + "three-mesh-bvh": "^0.8.3", + "three-stdlib": "^2.35.6", + "troika-three-text": "^0.52.4", + "tunnel-rat": "^0.1.2", + "use-sync-external-store": "^1.4.0", + "utility-types": "^3.11.0", + "zustand": "^5.0.1" }, "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + "@react-three/fiber": "^9.0.0", + "react": "^19", + "react-dom": "^19", + "three": ">=0.159" }, "peerDependenciesMeta": { - "@types/react": { + "react-dom": { + "optional": true + } + } + }, + "node_modules/@react-three/fiber": { + "version": "9.5.0", + "resolved": "https://registry.npmjs.org/@react-three/fiber/-/fiber-9.5.0.tgz", + "integrity": "sha512-FiUzfYW4wB1+PpmsE47UM+mCads7j2+giRBltfwH7SNhah95rqJs3ltEs9V3pP8rYdS0QlNne+9Aj8dS/SiaIA==", + "license": "MIT", + "dependencies": { + "@babel/runtime": "^7.17.8", + "@types/webxr": "*", + "base64-js": "^1.5.1", + "buffer": "^6.0.3", + "its-fine": "^2.0.0", + "react-use-measure": "^2.1.7", + "scheduler": "^0.27.0", + "suspend-react": "^0.1.3", + "use-sync-external-store": "^1.4.0", + "zustand": "^5.0.3" + }, + "peerDependencies": { + "expo": ">=43.0", + "expo-asset": ">=8.4", + "expo-file-system": ">=11.0", + "expo-gl": ">=11.0", + "react": ">=19 <19.3", + "react-dom": ">=19 <19.3", + "react-native": ">=0.78", + "three": ">=0.156" + }, + "peerDependenciesMeta": { + "expo": { "optional": true }, - "@types/react-dom": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-collection": { - "version": "1.1.7", - "resolved": "https://registry.npmjs.org/@radix-ui/react-collection/-/react-collection-1.1.7.tgz", - "integrity": "sha512-Fh9rGN0MoI4ZFUNyfFVNU4y9LUz93u9/0K+yLgA2bwRojxM8JU1DyvvMBabnZPBgMWREAJvU2jjVzq+LrFUglw==", - "license": "MIT", - "dependencies": { - "@radix-ui/react-compose-refs": "1.1.2", - "@radix-ui/react-context": "1.1.2", - "@radix-ui/react-primitive": "2.1.3", - "@radix-ui/react-slot": "1.2.3" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { + "expo-asset": { "optional": true }, - "@types/react-dom": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-compose-refs": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@radix-ui/react-compose-refs/-/react-compose-refs-1.1.2.tgz", - "integrity": "sha512-z4eqJvfiNnFMHIIvXP3CY57y2WJs5g2v3X0zm9mEJkrkNv4rDxu+sg9Jh8EkXyeqBkB7SOcboo9dMVqhyrACIg==", - "license": "MIT", - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-context": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.1.2.tgz", - "integrity": "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA==", - "license": "MIT", - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-dialog": { - "version": "1.1.15", - "resolved": "https://registry.npmjs.org/@radix-ui/react-dialog/-/react-dialog-1.1.15.tgz", - "integrity": "sha512-TCglVRtzlffRNxRMEyR36DGBLJpeusFcgMVD9PZEzAKnUs1lKCgX5u9BmC2Yg+LL9MgZDugFFs1Vl+Jp4t/PGw==", - "license": "MIT", - "dependencies": { - "@radix-ui/primitive": "1.1.3", - "@radix-ui/react-compose-refs": "1.1.2", - "@radix-ui/react-context": "1.1.2", - "@radix-ui/react-dismissable-layer": "1.1.11", - "@radix-ui/react-focus-guards": "1.1.3", - "@radix-ui/react-focus-scope": "1.1.7", - "@radix-ui/react-id": "1.1.1", - "@radix-ui/react-portal": "1.1.9", - "@radix-ui/react-presence": "1.1.5", - "@radix-ui/react-primitive": "2.1.3", - "@radix-ui/react-slot": "1.2.3", - "@radix-ui/react-use-controllable-state": "1.2.2", - "aria-hidden": "^1.2.4", - "react-remove-scroll": "^2.6.3" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { + "expo-file-system": { "optional": true }, - "@types/react-dom": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-direction": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/react-direction/-/react-direction-1.1.1.tgz", - "integrity": "sha512-1UEWRX6jnOA2y4H5WczZ44gOOjTEmlqv1uNW4GAJEO5+bauCBhv8snY65Iw5/VOS/ghKN9gr2KjnLKxrsvoMVw==", - "license": "MIT", - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-dismissable-layer": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.1.11.tgz", - "integrity": "sha512-Nqcp+t5cTB8BinFkZgXiMJniQH0PsUt2k51FUhbdfeKvc4ACcG2uQniY/8+h1Yv6Kza4Q7lD7PQV0z0oicE0Mg==", - "license": "MIT", - "dependencies": { - "@radix-ui/primitive": "1.1.3", - "@radix-ui/react-compose-refs": "1.1.2", - "@radix-ui/react-primitive": "2.1.3", - "@radix-ui/react-use-callback-ref": "1.1.1", - "@radix-ui/react-use-escape-keydown": "1.1.1" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { + "expo-gl": { "optional": true }, - "@types/react-dom": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-focus-guards": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/@radix-ui/react-focus-guards/-/react-focus-guards-1.1.3.tgz", - "integrity": "sha512-0rFg/Rj2Q62NCm62jZw0QX7a3sz6QCQU0LpZdNrJX8byRGaGVTqbrW9jAoIAHyMQqsNpeZ81YgSizOt5WXq0Pw==", - "license": "MIT", - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-focus-scope": { - "version": "1.1.7", - "resolved": "https://registry.npmjs.org/@radix-ui/react-focus-scope/-/react-focus-scope-1.1.7.tgz", - "integrity": "sha512-t2ODlkXBQyn7jkl6TNaw/MtVEVvIGelJDCG41Okq/KwUsJBwQ4XVZsHAVUkK4mBv3ewiAS3PGuUWuY2BoK4ZUw==", - "license": "MIT", - "dependencies": { - "@radix-ui/react-compose-refs": "1.1.2", - "@radix-ui/react-primitive": "2.1.3", - "@radix-ui/react-use-callback-ref": "1.1.1" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { + "react-dom": { "optional": true }, - "@types/react-dom": { + "react-native": { "optional": true } } }, - "node_modules/@radix-ui/react-id": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/react-id/-/react-id-1.1.1.tgz", - "integrity": "sha512-kGkGegYIdQsOb4XjsfM97rXsiHaBwco+hFI66oO4s9LU+PLAC5oJ7khdOVFxkhsmlbpUqDAvXw11CluXP+jkHg==", - "license": "MIT", - "dependencies": { - "@radix-ui/react-use-layout-effect": "1.1.1" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-popover": { - "version": "1.1.15", - "resolved": "https://registry.npmjs.org/@radix-ui/react-popover/-/react-popover-1.1.15.tgz", - "integrity": "sha512-kr0X2+6Yy/vJzLYJUPCZEc8SfQcf+1COFoAqauJm74umQhta9M7lNJHP7QQS3vkvcGLQUbWpMzwrXYwrYztHKA==", - "license": "MIT", - "dependencies": { - "@radix-ui/primitive": "1.1.3", - "@radix-ui/react-compose-refs": "1.1.2", - "@radix-ui/react-context": "1.1.2", - "@radix-ui/react-dismissable-layer": "1.1.11", - "@radix-ui/react-focus-guards": "1.1.3", - "@radix-ui/react-focus-scope": "1.1.7", - "@radix-ui/react-id": "1.1.1", - "@radix-ui/react-popper": "1.2.8", - "@radix-ui/react-portal": "1.1.9", - "@radix-ui/react-presence": "1.1.5", - "@radix-ui/react-primitive": "2.1.3", - "@radix-ui/react-slot": "1.2.3", - "@radix-ui/react-use-controllable-state": "1.2.2", - "aria-hidden": "^1.2.4", - "react-remove-scroll": "^2.6.3" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true + "node_modules/@react-three/fiber/node_modules/buffer": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", + "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" }, - "@types/react-dom": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-popper": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/@radix-ui/react-popper/-/react-popper-1.2.8.tgz", - "integrity": "sha512-0NJQ4LFFUuWkE7Oxf0htBKS6zLkkjBH+hM1uk7Ng705ReR8m/uelduy1DBo0PyBXPKVnBA6YBlU94MBGXrSBCw==", - "license": "MIT", - "dependencies": { - "@floating-ui/react-dom": "^2.0.0", - "@radix-ui/react-arrow": "1.1.7", - "@radix-ui/react-compose-refs": "1.1.2", - "@radix-ui/react-context": "1.1.2", - "@radix-ui/react-primitive": "2.1.3", - "@radix-ui/react-use-callback-ref": "1.1.1", - "@radix-ui/react-use-layout-effect": "1.1.1", - "@radix-ui/react-use-rect": "1.1.1", - "@radix-ui/react-use-size": "1.1.1", - "@radix-ui/rect": "1.1.1" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true + { + "type": "patreon", + "url": "https://www.patreon.com/feross" }, - "@types/react-dom": { - "optional": true + { + "type": "consulting", + "url": "https://feross.org/support" } - } - }, - "node_modules/@radix-ui/react-portal": { - "version": "1.1.9", - "resolved": "https://registry.npmjs.org/@radix-ui/react-portal/-/react-portal-1.1.9.tgz", - "integrity": "sha512-bpIxvq03if6UNwXZ+HTK71JLh4APvnXntDc6XOX8UVq4XQOVl7lwok0AvIl+b8zgCw3fSaVTZMpAPPagXbKmHQ==", + ], "license": "MIT", "dependencies": { - "@radix-ui/react-primitive": "2.1.3", - "@radix-ui/react-use-layout-effect": "1.1.1" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - }, - "@types/react-dom": { - "optional": true - } + "base64-js": "^1.3.1", + "ieee754": "^1.2.1" } }, - "node_modules/@radix-ui/react-presence": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/@radix-ui/react-presence/-/react-presence-1.1.5.tgz", - "integrity": "sha512-/jfEwNDdQVBCNvjkGit4h6pMOzq8bHkopq458dPt2lMjx+eBQUohZNG9A7DtO/O5ukSbxuaNGXMjHicgwy6rQQ==", - "license": "MIT", + "node_modules/@react-three/rapier": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@react-three/rapier/-/rapier-2.2.0.tgz", + "integrity": "sha512-mVsqbKXlGZoN+XrqdhzFZUQmy8pibEOVzl4k7LC+LHe84bQnYBSagy1Hvbda6bL1PJDdTFyiDiBk5buKFinNIQ==", "dependencies": { - "@radix-ui/react-compose-refs": "1.1.2", - "@radix-ui/react-use-layout-effect": "1.1.1" + "@dimforge/rapier3d-compat": "0.19.2", + "suspend-react": "^0.1.3", + "three-stdlib": "^2.35.12" }, "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - }, - "@types/react-dom": { - "optional": true - } + "@react-three/fiber": "^9.0.4", + "react": "^19", + "three": ">=0.159.0" } }, - "node_modules/@radix-ui/react-primitive": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/@radix-ui/react-primitive/-/react-primitive-2.1.3.tgz", - "integrity": "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ==", - "license": "MIT", - "dependencies": { - "@radix-ui/react-slot": "1.2.3" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - }, - "@types/react-dom": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-roving-focus": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/@radix-ui/react-roving-focus/-/react-roving-focus-1.1.11.tgz", - "integrity": "sha512-7A6S9jSgm/S+7MdtNDSb+IU859vQqJ/QAtcYQcfFC6W8RS4IxIZDldLR0xqCFZ6DCyrQLjLPsxtTNch5jVA4lA==", - "license": "MIT", - "dependencies": { - "@radix-ui/primitive": "1.1.3", - "@radix-ui/react-collection": "1.1.7", - "@radix-ui/react-compose-refs": "1.1.2", - "@radix-ui/react-context": "1.1.2", - "@radix-ui/react-direction": "1.1.1", - "@radix-ui/react-id": "1.1.1", - "@radix-ui/react-primitive": "2.1.3", - "@radix-ui/react-use-callback-ref": "1.1.1", - "@radix-ui/react-use-controllable-state": "1.2.2" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - }, - "@types/react-dom": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-select": { - "version": "2.2.6", - "resolved": "https://registry.npmjs.org/@radix-ui/react-select/-/react-select-2.2.6.tgz", - "integrity": "sha512-I30RydO+bnn2PQztvo25tswPH+wFBjehVGtmagkU78yMdwTwVf12wnAOF+AeP8S2N8xD+5UPbGhkUfPyvT+mwQ==", - "license": "MIT", - "dependencies": { - "@radix-ui/number": "1.1.1", - "@radix-ui/primitive": "1.1.3", - "@radix-ui/react-collection": "1.1.7", - "@radix-ui/react-compose-refs": "1.1.2", - "@radix-ui/react-context": "1.1.2", - "@radix-ui/react-direction": "1.1.1", - "@radix-ui/react-dismissable-layer": "1.1.11", - "@radix-ui/react-focus-guards": "1.1.3", - "@radix-ui/react-focus-scope": "1.1.7", - "@radix-ui/react-id": "1.1.1", - "@radix-ui/react-popper": "1.2.8", - "@radix-ui/react-portal": "1.1.9", - "@radix-ui/react-primitive": "2.1.3", - "@radix-ui/react-slot": "1.2.3", - "@radix-ui/react-use-callback-ref": "1.1.1", - "@radix-ui/react-use-controllable-state": "1.2.2", - "@radix-ui/react-use-layout-effect": "1.1.1", - "@radix-ui/react-use-previous": "1.1.1", - "@radix-ui/react-visually-hidden": "1.2.3", - "aria-hidden": "^1.2.4", - "react-remove-scroll": "^2.6.3" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - }, - "@types/react-dom": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-slot": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.2.3.tgz", - "integrity": "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A==", - "license": "MIT", - "dependencies": { - "@radix-ui/react-compose-refs": "1.1.2" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-tabs": { - "version": "1.1.13", - "resolved": "https://registry.npmjs.org/@radix-ui/react-tabs/-/react-tabs-1.1.13.tgz", - "integrity": "sha512-7xdcatg7/U+7+Udyoj2zodtI9H/IIopqo+YOIcZOq1nJwXWBZ9p8xiu5llXlekDbZkca79a/fozEYQXIA4sW6A==", - "license": "MIT", - "dependencies": { - "@radix-ui/primitive": "1.1.3", - "@radix-ui/react-context": "1.1.2", - "@radix-ui/react-direction": "1.1.1", - "@radix-ui/react-id": "1.1.1", - "@radix-ui/react-presence": "1.1.5", - "@radix-ui/react-primitive": "2.1.3", - "@radix-ui/react-roving-focus": "1.1.11", - "@radix-ui/react-use-controllable-state": "1.2.2" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - }, - "@types/react-dom": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-tooltip": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/@radix-ui/react-tooltip/-/react-tooltip-1.2.8.tgz", - "integrity": "sha512-tY7sVt1yL9ozIxvmbtN5qtmH2krXcBCfjEiCgKGLqunJHvgvZG2Pcl2oQ3kbcZARb1BGEHdkLzcYGO8ynVlieg==", - "license": "MIT", - "dependencies": { - "@radix-ui/primitive": "1.1.3", - "@radix-ui/react-compose-refs": "1.1.2", - "@radix-ui/react-context": "1.1.2", - "@radix-ui/react-dismissable-layer": "1.1.11", - "@radix-ui/react-id": "1.1.1", - "@radix-ui/react-popper": "1.2.8", - "@radix-ui/react-portal": "1.1.9", - "@radix-ui/react-presence": "1.1.5", - "@radix-ui/react-primitive": "2.1.3", - "@radix-ui/react-slot": "1.2.3", - "@radix-ui/react-use-controllable-state": "1.2.2", - "@radix-ui/react-visually-hidden": "1.2.3" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - }, - "@types/react-dom": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-use-callback-ref": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/react-use-callback-ref/-/react-use-callback-ref-1.1.1.tgz", - "integrity": "sha512-FkBMwD+qbGQeMu1cOHnuGB6x4yzPjho8ap5WtbEJ26umhgqVXbhekKUQO+hZEL1vU92a3wHwdp0HAcqAUF5iDg==", - "license": "MIT", - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-use-controllable-state": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/@radix-ui/react-use-controllable-state/-/react-use-controllable-state-1.2.2.tgz", - "integrity": "sha512-BjasUjixPFdS+NKkypcyyN5Pmg83Olst0+c6vGov0diwTEo6mgdqVR6hxcEgFuh4QrAs7Rc+9KuGJ9TVCj0Zzg==", - "license": "MIT", - "dependencies": { - "@radix-ui/react-use-effect-event": "0.0.2", - "@radix-ui/react-use-layout-effect": "1.1.1" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-use-effect-event": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/@radix-ui/react-use-effect-event/-/react-use-effect-event-0.0.2.tgz", - "integrity": "sha512-Qp8WbZOBe+blgpuUT+lw2xheLP8q0oatc9UpmiemEICxGvFLYmHm9QowVZGHtJlGbS6A6yJ3iViad/2cVjnOiA==", - "license": "MIT", - "dependencies": { - "@radix-ui/react-use-layout-effect": "1.1.1" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-use-escape-keydown": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/react-use-escape-keydown/-/react-use-escape-keydown-1.1.1.tgz", - "integrity": "sha512-Il0+boE7w/XebUHyBjroE+DbByORGR9KKmITzbR7MyQ4akpORYP/ZmbhAr0DG7RmmBqoOnZdy2QlvajJ2QA59g==", - "license": "MIT", - "dependencies": { - "@radix-ui/react-use-callback-ref": "1.1.1" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-use-layout-effect": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/react-use-layout-effect/-/react-use-layout-effect-1.1.1.tgz", - "integrity": "sha512-RbJRS4UWQFkzHTTwVymMTUv8EqYhOp8dOOviLj2ugtTiXRaRQS7GLGxZTLL1jWhMeoSCf5zmcZkqTl9IiYfXcQ==", - "license": "MIT", - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-use-previous": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/react-use-previous/-/react-use-previous-1.1.1.tgz", - "integrity": "sha512-2dHfToCj/pzca2Ck724OZ5L0EVrr3eHRNsG/b3xQJLA2hZpVCS99bLAX+hm1IHXDEnzU6by5z/5MIY794/a8NQ==", - "license": "MIT", - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-use-rect": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/react-use-rect/-/react-use-rect-1.1.1.tgz", - "integrity": "sha512-QTYuDesS0VtuHNNvMh+CjlKJ4LJickCMUAqjlE3+j8w+RlRpwyX3apEQKGFzbZGdo7XNG1tXa+bQqIE7HIXT2w==", - "license": "MIT", - "dependencies": { - "@radix-ui/rect": "1.1.1" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-use-size": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/react-use-size/-/react-use-size-1.1.1.tgz", - "integrity": "sha512-ewrXRDTAqAXlkl6t/fkXWNAhFX9I+CkKlw6zjEwk86RSPKwZr3xpBRso655aqYafwtnbpHLj6toFzmd6xdVptQ==", - "license": "MIT", - "dependencies": { - "@radix-ui/react-use-layout-effect": "1.1.1" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@radix-ui/react-visually-hidden": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/@radix-ui/react-visually-hidden/-/react-visually-hidden-1.2.3.tgz", - "integrity": "sha512-pzJq12tEaaIhqjbzpCuv/OypJY/BPavOofm+dbab+MHLajy277+1lLm6JFcGgF5eskJ6mquGirhXY2GD/8u8Ug==", - "license": "MIT", - "dependencies": { - "@radix-ui/react-primitive": "2.1.3" - }, - "peerDependencies": { - "@types/react": "*", - "@types/react-dom": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", - "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - }, - "@types/react-dom": { - "optional": true - } - } - }, - "node_modules/@radix-ui/rect": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/rect/-/rect-1.1.1.tgz", - "integrity": "sha512-HPwpGIzkl28mWyZqG52jiqDJ12waP11Pa1lGoiyUkIEuMLBP0oeK/C89esbXrxsky5we7dfd8U58nm0SgAWpVw==", - "license": "MIT" - }, - "node_modules/@reduxjs/toolkit": { - "version": "2.11.2", - "resolved": "https://registry.npmjs.org/@reduxjs/toolkit/-/toolkit-2.11.2.tgz", - "integrity": "sha512-Kd6kAHTA6/nUpp8mySPqj3en3dm0tdMIgbttnQ1xFMVpufoj+ADi8pXLBsd4xzTRHQa7t/Jv8W5UnCuW4kuWMQ==", - "license": "MIT", - "dependencies": { - "@standard-schema/spec": "^1.0.0", - "@standard-schema/utils": "^0.3.0", - "immer": "^11.0.0", - "redux": "^5.0.1", - "redux-thunk": "^3.1.0", - "reselect": "^5.1.0" - }, - "peerDependencies": { - "react": "^16.9.0 || ^17.0.0 || ^18 || ^19", - "react-redux": "^7.2.1 || ^8.1.3 || ^9.0.0" - }, - "peerDependenciesMeta": { - "react": { - "optional": true - }, - "react-redux": { - "optional": true - } - } - }, - "node_modules/@reduxjs/toolkit/node_modules/immer": { - "version": "11.1.4", - "resolved": "https://registry.npmjs.org/immer/-/immer-11.1.4.tgz", - "integrity": "sha512-XREFCPo6ksxVzP4E0ekD5aMdf8WMwmdNaz6vuvxgI40UaEiu6q3p8X52aU6GdyvLY3XXX/8R7JOTXStz/nBbRw==", - "license": "MIT", - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/immer" - } - }, - "node_modules/@rollup/rollup-android-arm-eabi": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.59.0.tgz", - "integrity": "sha512-upnNBkA6ZH2VKGcBj9Fyl9IGNPULcjXRlg0LLeaioQWueH30p6IXtJEbKAgvyv+mJaMxSm1l6xwDXYjpEMiLMg==", - "cpu": [ - "arm" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "android" - ] - }, - "node_modules/@rollup/rollup-android-arm64": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.59.0.tgz", - "integrity": "sha512-hZ+Zxj3SySm4A/DylsDKZAeVg0mvi++0PYVceVyX7hemkw7OreKdCvW2oQ3T1FMZvCaQXqOTHb8qmBShoqk69Q==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "android" - ] - }, - "node_modules/@rollup/rollup-darwin-arm64": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.59.0.tgz", - "integrity": "sha512-W2Psnbh1J8ZJw0xKAd8zdNgF9HRLkdWwwdWqubSVk0pUuQkoHnv7rx4GiF9rT4t5DIZGAsConRE3AxCdJ4m8rg==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ] - }, - "node_modules/@rollup/rollup-darwin-x64": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.59.0.tgz", - "integrity": "sha512-ZW2KkwlS4lwTv7ZVsYDiARfFCnSGhzYPdiOU4IM2fDbL+QGlyAbjgSFuqNRbSthybLbIJ915UtZBtmuLrQAT/w==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ] - }, - "node_modules/@rollup/rollup-freebsd-arm64": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.59.0.tgz", - "integrity": "sha512-EsKaJ5ytAu9jI3lonzn3BgG8iRBjV4LxZexygcQbpiU0wU0ATxhNVEpXKfUa0pS05gTcSDMKpn3Sx+QB9RlTTA==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ] - }, - "node_modules/@rollup/rollup-freebsd-x64": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.59.0.tgz", - "integrity": "sha512-d3DuZi2KzTMjImrxoHIAODUZYoUUMsuUiY4SRRcJy6NJoZ6iIqWnJu9IScV9jXysyGMVuW+KNzZvBLOcpdl3Vg==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ] - }, - "node_modules/@rollup/rollup-linux-arm-gnueabihf": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.59.0.tgz", - "integrity": "sha512-t4ONHboXi/3E0rT6OZl1pKbl2Vgxf9vJfWgmUoCEVQVxhW6Cw/c8I6hbbu7DAvgp82RKiH7TpLwxnJeKv2pbsw==", - "cpu": [ - "arm" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-arm-musleabihf": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.59.0.tgz", - "integrity": "sha512-CikFT7aYPA2ufMD086cVORBYGHffBo4K8MQ4uPS/ZnY54GKj36i196u8U+aDVT2LX4eSMbyHtyOh7D7Zvk2VvA==", - "cpu": [ - "arm" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-arm64-gnu": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.59.0.tgz", - "integrity": "sha512-jYgUGk5aLd1nUb1CtQ8E+t5JhLc9x5WdBKew9ZgAXg7DBk0ZHErLHdXM24rfX+bKrFe+Xp5YuJo54I5HFjGDAA==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-arm64-musl": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.59.0.tgz", - "integrity": "sha512-peZRVEdnFWZ5Bh2KeumKG9ty7aCXzzEsHShOZEFiCQlDEepP1dpUl/SrUNXNg13UmZl+gzVDPsiCwnV1uI0RUA==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-loong64-gnu": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-gnu/-/rollup-linux-loong64-gnu-4.59.0.tgz", - "integrity": "sha512-gbUSW/97f7+r4gHy3Jlup8zDG190AuodsWnNiXErp9mT90iCy9NKKU0Xwx5k8VlRAIV2uU9CsMnEFg/xXaOfXg==", - "cpu": [ - "loong64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-loong64-musl": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-musl/-/rollup-linux-loong64-musl-4.59.0.tgz", - "integrity": "sha512-yTRONe79E+o0FWFijasoTjtzG9EBedFXJMl888NBEDCDV9I2wGbFFfJQQe63OijbFCUZqxpHz1GzpbtSFikJ4Q==", - "cpu": [ - "loong64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-ppc64-gnu": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-gnu/-/rollup-linux-ppc64-gnu-4.59.0.tgz", - "integrity": "sha512-sw1o3tfyk12k3OEpRddF68a1unZ5VCN7zoTNtSn2KndUE+ea3m3ROOKRCZxEpmT9nsGnogpFP9x6mnLTCaoLkA==", - "cpu": [ - "ppc64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-ppc64-musl": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-musl/-/rollup-linux-ppc64-musl-4.59.0.tgz", - "integrity": "sha512-+2kLtQ4xT3AiIxkzFVFXfsmlZiG5FXYW7ZyIIvGA7Bdeuh9Z0aN4hVyXS/G1E9bTP/vqszNIN/pUKCk/BTHsKA==", - "cpu": [ - "ppc64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-riscv64-gnu": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.59.0.tgz", - "integrity": "sha512-NDYMpsXYJJaj+I7UdwIuHHNxXZ/b/N2hR15NyH3m2qAtb/hHPA4g4SuuvrdxetTdndfj9b1WOmy73kcPRoERUg==", - "cpu": [ - "riscv64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-riscv64-musl": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.59.0.tgz", - "integrity": "sha512-nLckB8WOqHIf1bhymk+oHxvM9D3tyPndZH8i8+35p/1YiVoVswPid2yLzgX7ZJP0KQvnkhM4H6QZ5m0LzbyIAg==", - "cpu": [ - "riscv64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-s390x-gnu": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.59.0.tgz", - "integrity": "sha512-oF87Ie3uAIvORFBpwnCvUzdeYUqi2wY6jRFWJAy1qus/udHFYIkplYRW+wo+GRUP4sKzYdmE1Y3+rY5Gc4ZO+w==", - "cpu": [ - "s390x" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-x64-gnu": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.59.0.tgz", - "integrity": "sha512-3AHmtQq/ppNuUspKAlvA8HtLybkDflkMuLK4DPo77DfthRb71V84/c4MlWJXixZz4uruIH4uaa07IqoAkG64fg==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-x64-musl": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.59.0.tgz", - "integrity": "sha512-2UdiwS/9cTAx7qIUZB/fWtToJwvt0Vbo0zmnYt7ED35KPg13Q0ym1g442THLC7VyI6JfYTP4PiSOWyoMdV2/xg==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-openbsd-x64": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-openbsd-x64/-/rollup-openbsd-x64-4.59.0.tgz", - "integrity": "sha512-M3bLRAVk6GOwFlPTIxVBSYKUaqfLrn8l0psKinkCFxl4lQvOSz8ZrKDz2gxcBwHFpci0B6rttydI4IpS4IS/jQ==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ] - }, - "node_modules/@rollup/rollup-openharmony-arm64": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-openharmony-arm64/-/rollup-openharmony-arm64-4.59.0.tgz", - "integrity": "sha512-tt9KBJqaqp5i5HUZzoafHZX8b5Q2Fe7UjYERADll83O4fGqJ49O1FsL6LpdzVFQcpwvnyd0i+K/VSwu/o/nWlA==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openharmony" - ] - }, - "node_modules/@rollup/rollup-win32-arm64-msvc": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.59.0.tgz", - "integrity": "sha512-V5B6mG7OrGTwnxaNUzZTDTjDS7F75PO1ae6MJYdiMu60sq0CqN5CVeVsbhPxalupvTX8gXVSU9gq+Rx1/hvu6A==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@rollup/rollup-win32-ia32-msvc": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.59.0.tgz", - "integrity": "sha512-UKFMHPuM9R0iBegwzKF4y0C4J9u8C6MEJgFuXTBerMk7EJ92GFVFYBfOZaSGLu6COf7FxpQNqhNS4c4icUPqxA==", - "cpu": [ - "ia32" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@rollup/rollup-win32-x64-gnu": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-gnu/-/rollup-win32-x64-gnu-4.59.0.tgz", - "integrity": "sha512-laBkYlSS1n2L8fSo1thDNGrCTQMmxjYY5G0WFWjFFYZkKPjsMBsgJfGf4TLxXrF6RyhI60L8TMOjBMvXiTcxeA==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@rollup/rollup-win32-x64-msvc": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.59.0.tgz", - "integrity": "sha512-2HRCml6OztYXyJXAvdDXPKcawukWY2GpR5/nxKp4iBgiO3wcoEGkAaqctIbZcNB6KlUQBIqt8VYkNSj2397EfA==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, "node_modules/@rtsao/scc": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/@rtsao/scc/-/scc-1.1.0.tgz", @@ -3375,227 +1428,6 @@ "dev": true, "license": "MIT" }, - "node_modules/@scalar/helpers": { - "version": "0.2.6", - "resolved": "https://registry.npmjs.org/@scalar/helpers/-/helpers-0.2.6.tgz", - "integrity": "sha512-A471YFBCj7ZOlGIkAYnU8oYgeyts82ZNX+4UicrlmKv3eAQ+kwboN3Dy0R6u1lcA/+I/zzeXi/fBObsT7P9qTA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=20" - } - }, - "node_modules/@scalar/json-magic": { - "version": "0.8.10", - "resolved": "https://registry.npmjs.org/@scalar/json-magic/-/json-magic-0.8.10.tgz", - "integrity": "sha512-TWdKQ/hcy4erFQDp2MVlFoPesFep2VY96Q69cjLHmx5hxM0ZUBfmNB4lA8Uh3klgx5JmCDfSNIGjPFIpxlosUw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@scalar/helpers": "0.2.6", - "yaml": "^2.8.0" - }, - "engines": { - "node": ">=20" - } - }, - "node_modules/@scalar/openapi-parser": { - "version": "0.23.13", - "resolved": "https://registry.npmjs.org/@scalar/openapi-parser/-/openapi-parser-0.23.13.tgz", - "integrity": "sha512-YsljPOKOgQgZL/kBcEouwz2CUa+2hFfThlUZRWC2DFI2Fnw5Ur8F1IvGgPqCAHr9p2XMH+Z/Pag2jZUfLcxcww==", - "dev": true, - "license": "MIT", - "dependencies": { - "@scalar/json-magic": "0.9.0", - "@scalar/openapi-types": "0.5.3", - "@scalar/openapi-upgrader": "0.1.7", - "ajv": "^8.17.1", - "ajv-draft-04": "^1.0.0", - "ajv-formats": "^3.0.1", - "jsonpointer": "^5.0.1", - "leven": "^4.0.0", - "yaml": "^2.8.0" - }, - "engines": { - "node": ">=20" - } - }, - "node_modules/@scalar/openapi-parser/node_modules/@scalar/helpers": { - "version": "0.2.7", - "resolved": "https://registry.npmjs.org/@scalar/helpers/-/helpers-0.2.7.tgz", - "integrity": "sha512-uFTcdi3XYDDuaJLWiMuM3ijQit1OBw7AkuOuujReY8L9UmUQHY56erYg0+Db3llTsinuIYFh+eS/WX/sYuevYQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=20" - } - }, - "node_modules/@scalar/openapi-parser/node_modules/@scalar/json-magic": { - "version": "0.9.0", - "resolved": "https://registry.npmjs.org/@scalar/json-magic/-/json-magic-0.9.0.tgz", - "integrity": "sha512-aSWd8rd3O73Ak9Ylson2TywvOuTjjOYiXydl9Cn8Ip/r7fi+h0QqAGom5gqo/WewrhySF9v+H/sW/Qmd05T/Kg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@scalar/helpers": "0.2.7", - "yaml": "^2.8.0" - }, - "engines": { - "node": ">=20" - } - }, - "node_modules/@scalar/openapi-parser/node_modules/ajv": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", - "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", - "dev": true, - "license": "MIT", - "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/@scalar/openapi-parser/node_modules/ajv-draft-04": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/ajv-draft-04/-/ajv-draft-04-1.0.0.tgz", - "integrity": "sha512-mv00Te6nmYbRp5DCwclxtt7yV/joXJPGS7nM+97GdxvuttCOfgI3K4U25zboyeX0O+myI8ERluxQe5wljMmVIw==", - "dev": true, - "license": "MIT", - "peerDependencies": { - "ajv": "^8.5.0" - }, - "peerDependenciesMeta": { - "ajv": { - "optional": true - } - } - }, - "node_modules/@scalar/openapi-parser/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true, - "license": "MIT" - }, - "node_modules/@scalar/openapi-types": { - "version": "0.5.3", - "resolved": "https://registry.npmjs.org/@scalar/openapi-types/-/openapi-types-0.5.3.tgz", - "integrity": "sha512-m4n/Su3K01d15dmdWO1LlqecdSPKuNjuokrJLdiQ485kW/hRHbXW1QP6tJL75myhw/XhX5YhYAR+jrwnGjXiMw==", - "dev": true, - "license": "MIT", - "dependencies": { - "zod": "^4.1.11" - }, - "engines": { - "node": ">=20" - } - }, - "node_modules/@scalar/openapi-upgrader": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/@scalar/openapi-upgrader/-/openapi-upgrader-0.1.7.tgz", - "integrity": "sha512-065froUtqvaHjyeJtyitf8tb+k7oh7nU0OinAHYbj1Bqgwb1s2+uKMqHYHEES5CNpp+2xtL4lxup6Aq29yW+sQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@scalar/openapi-types": "0.5.3" - }, - "engines": { - "node": ">=20" - } - }, - "node_modules/@sec-ant/readable-stream": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/@sec-ant/readable-stream/-/readable-stream-0.4.1.tgz", - "integrity": "sha512-831qok9r2t8AlxLko40y2ebgSDhenenCatLVeW/uBtnHPyhHOvG0C7TvfgecV+wHzIm5KUICgzmVpWS+IMEAeg==", - "dev": true, - "license": "MIT" - }, - "node_modules/@shikijs/engine-oniguruma": { - "version": "3.22.0", - "resolved": "https://registry.npmjs.org/@shikijs/engine-oniguruma/-/engine-oniguruma-3.22.0.tgz", - "integrity": "sha512-DyXsOG0vGtNtl7ygvabHd7Mt5EY8gCNqR9Y7Lpbbd/PbJvgWrqaKzH1JW6H6qFkuUa8aCxoiYVv8/YfFljiQxA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@shikijs/types": "3.22.0", - "@shikijs/vscode-textmate": "^10.0.2" - } - }, - "node_modules/@shikijs/langs": { - "version": "3.22.0", - "resolved": "https://registry.npmjs.org/@shikijs/langs/-/langs-3.22.0.tgz", - "integrity": "sha512-x/42TfhWmp6H00T6uwVrdTJGKgNdFbrEdhaDwSR5fd5zhQ1Q46bHq9EO61SCEWJR0HY7z2HNDMaBZp8JRmKiIA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@shikijs/types": "3.22.0" - } - }, - "node_modules/@shikijs/themes": { - "version": "3.22.0", - "resolved": "https://registry.npmjs.org/@shikijs/themes/-/themes-3.22.0.tgz", - "integrity": "sha512-o+tlOKqsr6FE4+mYJG08tfCFDS+3CG20HbldXeVoyP+cYSUxDhrFf3GPjE60U55iOkkjbpY2uC3It/eeja35/g==", - "dev": true, - "license": "MIT", - "dependencies": { - "@shikijs/types": "3.22.0" - } - }, - "node_modules/@shikijs/types": { - "version": "3.22.0", - "resolved": "https://registry.npmjs.org/@shikijs/types/-/types-3.22.0.tgz", - "integrity": "sha512-491iAekgKDBFE67z70Ok5a8KBMsQ2IJwOWw3us/7ffQkIBCyOQfm/aNwVMBUriP02QshIfgHCBSIYAl3u2eWjg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@shikijs/vscode-textmate": "^10.0.2", - "@types/hast": "^3.0.4" - } - }, - "node_modules/@shikijs/vscode-textmate": { - "version": "10.0.2", - "resolved": "https://registry.npmjs.org/@shikijs/vscode-textmate/-/vscode-textmate-10.0.2.tgz", - "integrity": "sha512-83yeghZ2xxin3Nj8z1NMd/NCuca+gsYXswywDy5bHvwlWL8tpTQmzGeUuHd9FC3E/SBEMvzJRwWEOz5gGes9Qg==", - "dev": true, - "license": "MIT" - }, - "node_modules/@sindresorhus/merge-streams": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@sindresorhus/merge-streams/-/merge-streams-4.0.0.tgz", - "integrity": "sha512-tlqY9xq5ukxTUZBmoOp+m61cqwQD5pHJtFY3Mn8CA8ps6yghLH/Hw8UPdqg4OLmFW3IFlcXnQNmo/dh8HzXYIQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/@stablelib/base64": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@stablelib/base64/-/base64-1.0.1.tgz", - "integrity": "sha512-1bnPQqSxSuc3Ii6MhBysoWCg58j97aUjuCSZrGSmDxNqtytIi0k8utUenAwTZN4V5mXXYGsVUI9zeBqy+jBOSQ==", - "license": "MIT" - }, - "node_modules/@standard-schema/spec": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@standard-schema/spec/-/spec-1.1.0.tgz", - "integrity": "sha512-l2aFy5jALhniG5HgqrD6jXLi/rUWrKvqN/qJx6yoJsgKhblVd+iqqU4RCXavm/jPityDo5TCvKMnpjKnOriy0w==", - "license": "MIT" - }, - "node_modules/@standard-schema/utils": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/@standard-schema/utils/-/utils-0.3.0.tgz", - "integrity": "sha512-e7Mew686owMaPJVNNLs55PUvgz371nKgwsc4vxE49zsODpJEnxgxRo2y/OKrqueavXgZNMDVj3DdHFlaSAeU8g==", - "license": "MIT" - }, "node_modules/@swc/helpers": { "version": "0.5.15", "resolved": "https://registry.npmjs.org/@swc/helpers/-/helpers-0.5.15.tgz", @@ -3605,155 +1437,295 @@ "tslib": "^2.8.0" } }, - "node_modules/@tanstack/query-core": { - "version": "5.90.20", - "resolved": "https://registry.npmjs.org/@tanstack/query-core/-/query-core-5.90.20.tgz", - "integrity": "sha512-OMD2HLpNouXEfZJWcKeVKUgQ5n+n3A2JFmBaScpNDUqSrQSjiveC7dKMe53uJUg1nDG16ttFPz2xfilz6i2uVg==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/tannerlinsley" - } - }, - "node_modules/@tanstack/react-query": { - "version": "5.90.21", - "resolved": "https://registry.npmjs.org/@tanstack/react-query/-/react-query-5.90.21.tgz", - "integrity": "sha512-0Lu6y5t+tvlTJMTO7oh5NSpJfpg/5D41LlThfepTixPYkJ0sE2Jj0m0f6yYqujBwIXlId87e234+MxG3D3g7kg==", + "node_modules/@tailwindcss/node": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/node/-/node-4.1.18.tgz", + "integrity": "sha512-DoR7U1P7iYhw16qJ49fgXUlry1t4CpXeErJHnQ44JgTSKMaZUdf17cfn5mHchfJ4KRBZRFA/Coo+MUF5+gOaCQ==", + "dev": true, "license": "MIT", "dependencies": { - "@tanstack/query-core": "5.90.20" + "@jridgewell/remapping": "^2.3.4", + "enhanced-resolve": "^5.18.3", + "jiti": "^2.6.1", + "lightningcss": "1.30.2", + "magic-string": "^0.30.21", + "source-map-js": "^1.2.1", + "tailwindcss": "4.1.18" + } + }, + "node_modules/@tailwindcss/oxide": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide/-/oxide-4.1.18.tgz", + "integrity": "sha512-EgCR5tTS5bUSKQgzeMClT6iCY3ToqE1y+ZB0AKldj809QXk1Y+3jB0upOYZrn9aGIzPtUsP7sX4QQ4XtjBB95A==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 10" }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/tannerlinsley" + "optionalDependencies": { + "@tailwindcss/oxide-android-arm64": "4.1.18", + "@tailwindcss/oxide-darwin-arm64": "4.1.18", + "@tailwindcss/oxide-darwin-x64": "4.1.18", + "@tailwindcss/oxide-freebsd-x64": "4.1.18", + "@tailwindcss/oxide-linux-arm-gnueabihf": "4.1.18", + "@tailwindcss/oxide-linux-arm64-gnu": "4.1.18", + "@tailwindcss/oxide-linux-arm64-musl": "4.1.18", + "@tailwindcss/oxide-linux-x64-gnu": "4.1.18", + "@tailwindcss/oxide-linux-x64-musl": "4.1.18", + "@tailwindcss/oxide-wasm32-wasi": "4.1.18", + "@tailwindcss/oxide-win32-arm64-msvc": "4.1.18", + "@tailwindcss/oxide-win32-x64-msvc": "4.1.18" + } + }, + "node_modules/@tailwindcss/oxide-android-arm64": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-android-arm64/-/oxide-android-arm64-4.1.18.tgz", + "integrity": "sha512-dJHz7+Ugr9U/diKJA0W6N/6/cjI+ZTAoxPf9Iz9BFRF2GzEX8IvXxFIi/dZBloVJX/MZGvRuFA9rqwdiIEZQ0Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@tailwindcss/oxide-darwin-arm64": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-arm64/-/oxide-darwin-arm64-4.1.18.tgz", + "integrity": "sha512-Gc2q4Qhs660bhjyBSKgq6BYvwDz4G+BuyJ5H1xfhmDR3D8HnHCmT/BSkvSL0vQLy/nkMLY20PQ2OoYMO15Jd0A==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@tailwindcss/oxide-darwin-x64": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-x64/-/oxide-darwin-x64-4.1.18.tgz", + "integrity": "sha512-FL5oxr2xQsFrc3X9o1fjHKBYBMD1QZNyc1Xzw/h5Qu4XnEBi3dZn96HcHm41c/euGV+GRiXFfh2hUCyKi/e+yw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@tailwindcss/oxide-freebsd-x64": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-freebsd-x64/-/oxide-freebsd-x64-4.1.18.tgz", + "integrity": "sha512-Fj+RHgu5bDodmV1dM9yAxlfJwkkWvLiRjbhuO2LEtwtlYlBgiAT4x/j5wQr1tC3SANAgD+0YcmWVrj8R9trVMA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@tailwindcss/oxide-linux-arm-gnueabihf": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm-gnueabihf/-/oxide-linux-arm-gnueabihf-4.1.18.tgz", + "integrity": "sha512-Fp+Wzk/Ws4dZn+LV2Nqx3IilnhH51YZoRaYHQsVq3RQvEl+71VGKFpkfHrLM/Li+kt5c0DJe/bHXK1eHgDmdiA==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@tailwindcss/oxide-linux-arm64-gnu": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-gnu/-/oxide-linux-arm64-gnu-4.1.18.tgz", + "integrity": "sha512-S0n3jboLysNbh55Vrt7pk9wgpyTTPD0fdQeh7wQfMqLPM/Hrxi+dVsLsPrycQjGKEQk85Kgbx+6+QnYNiHalnw==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@tailwindcss/oxide-linux-arm64-musl": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-musl/-/oxide-linux-arm64-musl-4.1.18.tgz", + "integrity": "sha512-1px92582HkPQlaaCkdRcio71p8bc8i/ap5807tPRDK/uw953cauQBT8c5tVGkOwrHMfc2Yh6UuxaH4vtTjGvHg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@tailwindcss/oxide-linux-x64-gnu": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-gnu/-/oxide-linux-x64-gnu-4.1.18.tgz", + "integrity": "sha512-v3gyT0ivkfBLoZGF9LyHmts0Isc8jHZyVcbzio6Wpzifg/+5ZJpDiRiUhDLkcr7f/r38SWNe7ucxmGW3j3Kb/g==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@tailwindcss/oxide-linux-x64-musl": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-musl/-/oxide-linux-x64-musl-4.1.18.tgz", + "integrity": "sha512-bhJ2y2OQNlcRwwgOAGMY0xTFStt4/wyU6pvI6LSuZpRgKQwxTec0/3Scu91O8ir7qCR3AuepQKLU/kX99FouqQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@tailwindcss/oxide-wasm32-wasi": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-wasm32-wasi/-/oxide-wasm32-wasi-4.1.18.tgz", + "integrity": "sha512-LffYTvPjODiP6PT16oNeUQJzNVyJl1cjIebq/rWWBF+3eDst5JGEFSc5cWxyRCJ0Mxl+KyIkqRxk1XPEs9x8TA==", + "bundleDependencies": [ + "@napi-rs/wasm-runtime", + "@emnapi/core", + "@emnapi/runtime", + "@tybys/wasm-util", + "@emnapi/wasi-threads", + "tslib" + ], + "cpu": [ + "wasm32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "@emnapi/core": "^1.7.1", + "@emnapi/runtime": "^1.7.1", + "@emnapi/wasi-threads": "^1.1.0", + "@napi-rs/wasm-runtime": "^1.1.0", + "@tybys/wasm-util": "^0.10.1", + "tslib": "^2.4.0" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/@tailwindcss/oxide-win32-arm64-msvc": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-arm64-msvc/-/oxide-win32-arm64-msvc-4.1.18.tgz", + "integrity": "sha512-HjSA7mr9HmC8fu6bdsZvZ+dhjyGCLdotjVOgLA2vEqxEBZaQo9YTX4kwgEvPCpRh8o4uWc4J/wEoFzhEmjvPbA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@tailwindcss/oxide-win32-x64-msvc": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-x64-msvc/-/oxide-win32-x64-msvc-4.1.18.tgz", + "integrity": "sha512-bJWbyYpUlqamC8dpR7pfjA0I7vdF6t5VpUGMWRkXVE3AXgIZjYUYAK7II1GNaxR8J1SSrSrppRar8G++JekE3Q==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@tailwindcss/postcss": { + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/@tailwindcss/postcss/-/postcss-4.1.18.tgz", + "integrity": "sha512-Ce0GFnzAOuPyfV5SxjXGn0CubwGcuDB0zcdaPuCSzAa/2vII24JTkH+I6jcbXLb1ctjZMZZI6OjDaLPJQL1S0g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@alloc/quick-lru": "^5.2.0", + "@tailwindcss/node": "4.1.18", + "@tailwindcss/oxide": "4.1.18", + "postcss": "^8.4.41", + "tailwindcss": "4.1.18" + } + }, + "node_modules/@tailwindcss/typography": { + "version": "0.5.19", + "resolved": "https://registry.npmjs.org/@tailwindcss/typography/-/typography-0.5.19.tgz", + "integrity": "sha512-w31dd8HOx3k9vPtcQh5QHP9GwKcgbMp87j58qi6xgiBnFFtKEAgCWnDw4qUT8aHwkCp8bKvb/KGKWWHedP0AAg==", + "license": "MIT", + "dependencies": { + "postcss-selector-parser": "6.0.10" }, "peerDependencies": { - "react": "^18 || ^19" + "tailwindcss": ">=3.0.0 || insiders || >=4.0.0-alpha.20 || >=4.0.0-beta.1" } }, - "node_modules/@tanstack/react-table": { - "version": "8.21.3", - "resolved": "https://registry.npmjs.org/@tanstack/react-table/-/react-table-8.21.3.tgz", - "integrity": "sha512-5nNMTSETP4ykGegmVkhjcS8tTLW6Vl4axfEGQN3v0zdHYbK4UfoqfPChclTrJ4EoK9QynqAu9oUf8VEmrpZ5Ww==", - "license": "MIT", - "dependencies": { - "@tanstack/table-core": "8.21.3" - }, - "engines": { - "node": ">=12" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/tannerlinsley" - }, - "peerDependencies": { - "react": ">=16.8", - "react-dom": ">=16.8" - } - }, - "node_modules/@tanstack/table-core": { - "version": "8.21.3", - "resolved": "https://registry.npmjs.org/@tanstack/table-core/-/table-core-8.21.3.tgz", - "integrity": "sha512-ldZXEhOBb8Is7xLs01fR3YEc3DERiz5silj8tnGkFZytt1abEvl/GhUmCE0PMLaMPTa3Jk4HbKmRlHmu+gCftg==", - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/tannerlinsley" - } - }, - "node_modules/@testing-library/dom": { - "version": "10.4.1", - "resolved": "https://registry.npmjs.org/@testing-library/dom/-/dom-10.4.1.tgz", - "integrity": "sha512-o4PXJQidqJl82ckFaXUeoAW+XysPLauYI43Abki5hABd853iMhitooc6znOnczgbTYmEP6U6/y1ZyKAIsvMKGg==", - "dev": true, - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/code-frame": "^7.10.4", - "@babel/runtime": "^7.12.5", - "@types/aria-query": "^5.0.1", - "aria-query": "5.3.0", - "dom-accessibility-api": "^0.5.9", - "lz-string": "^1.5.0", - "picocolors": "1.1.1", - "pretty-format": "^27.0.2" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/@testing-library/jest-dom": { - "version": "6.9.1", - "resolved": "https://registry.npmjs.org/@testing-library/jest-dom/-/jest-dom-6.9.1.tgz", - "integrity": "sha512-zIcONa+hVtVSSep9UT3jZ5rizo2BsxgyDYU7WFD5eICBE7no3881HGeb/QkGfsJs6JTkY1aQhT7rIPC7e+0nnA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@adobe/css-tools": "^4.4.0", - "aria-query": "^5.0.0", - "css.escape": "^1.5.1", - "dom-accessibility-api": "^0.6.3", - "picocolors": "^1.1.1", - "redent": "^3.0.0" - }, - "engines": { - "node": ">=14", - "npm": ">=6", - "yarn": ">=1" - } - }, - "node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/dom-accessibility-api/-/dom-accessibility-api-0.6.3.tgz", - "integrity": "sha512-7ZgogeTnjuHbo+ct10G9Ffp0mif17idi0IyWNVA/wcwcm7NPOD/WEHVP3n7n3MhXqxoIYm8d6MuZohYWIZ4T3w==", - "dev": true, + "node_modules/@tweenjs/tween.js": { + "version": "23.1.3", + "resolved": "https://registry.npmjs.org/@tweenjs/tween.js/-/tween.js-23.1.3.tgz", + "integrity": "sha512-vJmvvwFxYuGnF2axRtPYocag6Clbb5YS7kLL+SO/TeVFzHqDIWrNKYtcsPMibjDx9O+bu+psAy9NKfWklassUA==", "license": "MIT" }, - "node_modules/@testing-library/react": { - "version": "16.3.2", - "resolved": "https://registry.npmjs.org/@testing-library/react/-/react-16.3.2.tgz", - "integrity": "sha512-XU5/SytQM+ykqMnAnvB2umaJNIOsLF3PVv//1Ew4CTcpz0/BRyy/af40qqrt7SjKpDdT1saBMc42CUok5gaw+g==", - "dev": true, - "license": "MIT", - "dependencies": { - "@babel/runtime": "^7.12.5" - }, - "engines": { - "node": ">=18" - }, - "peerDependencies": { - "@testing-library/dom": "^10.0.0", - "@types/react": "^18.0.0 || ^19.0.0", - "@types/react-dom": "^18.0.0 || ^19.0.0", - "react": "^18.0.0 || ^19.0.0", - "react-dom": "^18.0.0 || ^19.0.0" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - }, - "@types/react-dom": { - "optional": true - } - } - }, - "node_modules/@testing-library/user-event": { - "version": "14.6.1", - "resolved": "https://registry.npmjs.org/@testing-library/user-event/-/user-event-14.6.1.tgz", - "integrity": "sha512-vq7fv0rnt+QTXgPxr5Hjc210p6YKq2kmdziLgnsZGgLJ9e6VAShx1pACLuRjd/AS/sr7phAR58OIIpf0LlmQNw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12", - "npm": ">=6" - }, - "peerDependencies": { - "@testing-library/dom": ">=7.21.4" - } - }, "node_modules/@tybys/wasm-util": { "version": "0.10.1", "resolved": "https://registry.npmjs.org/@tybys/wasm-util/-/wasm-util-0.10.1.tgz", @@ -3765,23 +1737,13 @@ "tslib": "^2.4.0" } }, - "node_modules/@types/aria-query": { - "version": "5.0.4", - "resolved": "https://registry.npmjs.org/@types/aria-query/-/aria-query-5.0.4.tgz", - "integrity": "sha512-rfT93uj5s0PRL7EzccGMs3brplhcrghnDoV26NqKhCAS1hVo+WdNsPvE/yb6ilfr5hi2MEk6d5EWJTKdxg8jVw==", - "dev": true, - "license": "MIT", - "peer": true - }, - "node_modules/@types/chai": { - "version": "5.2.3", - "resolved": "https://registry.npmjs.org/@types/chai/-/chai-5.2.3.tgz", - "integrity": "sha512-Mw558oeA9fFbv65/y4mHtXDs9bPnFMZAL/jxdPFUpOHHIXX91mcgEHbS5Lahr+pwZFR8A7GQleRWeI6cGFC2UA==", - "dev": true, + "node_modules/@types/better-sqlite3": { + "version": "7.6.13", + "resolved": "https://registry.npmjs.org/@types/better-sqlite3/-/better-sqlite3-7.6.13.tgz", + "integrity": "sha512-NMv9ASNARoKksWtsq/SHakpYAYnhBrQgGD8zkLYk/jaK8jUGn08CfEdTRgYhMypUQAfzSP8W6gNLe0q19/t4VA==", "license": "MIT", "dependencies": { - "@types/deep-eql": "*", - "assertion-error": "^2.0.1" + "@types/node": "*" } }, "node_modules/@types/d3-array": { @@ -3856,11 +1818,10 @@ "@types/ms": "*" } }, - "node_modules/@types/deep-eql": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/@types/deep-eql/-/deep-eql-4.0.2.tgz", - "integrity": "sha512-c9h9dVVMigMPc4bwTvC5dxqtqJZwQPePsWjPlpSOnojbor6pGqdk541lfA7AqFQr5pB1BRdq0juY9db81BwyFw==", - "dev": true, + "node_modules/@types/draco3d": { + "version": "1.4.10", + "resolved": "https://registry.npmjs.org/@types/draco3d/-/draco3d-1.4.10.tgz", + "integrity": "sha512-AX22jp8Y7wwaBgAixaSvkoG4M/+PlAcm3Qs4OW8yT9DM4xUpWKeFhLueTAyZF39pviAdcDdeJoACapiAceqNcw==", "license": "MIT" }, "node_modules/@types/estree": { @@ -3917,19 +1878,24 @@ "license": "MIT" }, "node_modules/@types/node": { - "version": "20.19.33", - "resolved": "https://registry.npmjs.org/@types/node/-/node-20.19.33.tgz", - "integrity": "sha512-Rs1bVAIdBs5gbTIKza/tgpMuG1k3U/UMJLWecIMxNdJFDMzcM5LOiLVRYh3PilWEYDIeUDv7bpiHPLPsbydGcw==", - "dev": true, + "version": "20.19.32", + "resolved": "https://registry.npmjs.org/@types/node/-/node-20.19.32.tgz", + "integrity": "sha512-Ez8QE4DMfhjjTsES9K2dwfV258qBui7qxUsoaixZDiTzbde4U12e1pXGNu/ECsUIOi5/zoCxAQxIhQnaUQ2VvA==", "license": "MIT", "dependencies": { "undici-types": "~6.21.0" } }, + "node_modules/@types/offscreencanvas": { + "version": "2019.7.3", + "resolved": "https://registry.npmjs.org/@types/offscreencanvas/-/offscreencanvas-2019.7.3.tgz", + "integrity": "sha512-ieXiYmgSRXUDeOntE1InxjWyvEelZGP63M+cGuquuRLuIKKT1osnkXjxev9B7d1nXSug5vpunx+gNlbVxMlC9A==", + "license": "MIT" + }, "node_modules/@types/react": { - "version": "19.2.14", - "resolved": "https://registry.npmjs.org/@types/react/-/react-19.2.14.tgz", - "integrity": "sha512-ilcTH/UniCkMdtexkoCN0bI7pMcJDvmQFPvuPvmEaYA/NSfFTAgdUSLAoVjaRJm7+6PvcM+q1zYOwS4wTYMF9w==", + "version": "19.2.13", + "resolved": "https://registry.npmjs.org/@types/react/-/react-19.2.13.tgz", + "integrity": "sha512-KkiJeU6VbYbUOp5ITMIc7kBfqlYkKA5KhEHVrGMmUUMt7NeaZg65ojdPk+FtNrBAOXNVM5QM72jnADjM+XVRAQ==", "license": "MIT", "dependencies": { "csstype": "^3.2.2" @@ -3939,31 +1905,55 @@ "version": "19.2.3", "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-19.2.3.tgz", "integrity": "sha512-jp2L/eY6fn+KgVVQAOqYItbF0VY/YApe5Mz2F0aykSO8gx31bYCZyvSeYxCHKvzHG5eZjc+zyaS5BrBWya2+kQ==", - "devOptional": true, + "dev": true, "license": "MIT", "peerDependencies": { "@types/react": "^19.2.0" } }, - "node_modules/@types/react/node_modules/csstype": { - "version": "3.2.3", - "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.2.3.tgz", - "integrity": "sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==", + "node_modules/@types/react-reconciler": { + "version": "0.28.9", + "resolved": "https://registry.npmjs.org/@types/react-reconciler/-/react-reconciler-0.28.9.tgz", + "integrity": "sha512-HHM3nxyUZ3zAylX8ZEyrDNd2XZOnQ0D5XfunJF5FLQnZbHHYq4UWvW1QfelQNXv1ICNkwYhfxjwfnqivYB6bFg==", + "license": "MIT", + "peerDependencies": { + "@types/react": "*" + } + }, + "node_modules/@types/stats.js": { + "version": "0.17.4", + "resolved": "https://registry.npmjs.org/@types/stats.js/-/stats.js-0.17.4.tgz", + "integrity": "sha512-jIBvWWShCvlBqBNIZt0KAshWpvSjhkwkEu4ZUcASoAvhmrgAUI2t1dXrjSL4xXVLB4FznPrIsX3nKXFl/Dt4vA==", "license": "MIT" }, - "node_modules/@types/sinonjs__fake-timers": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-8.1.1.tgz", - "integrity": "sha512-0kSuKjAS0TrGLJ0M/+8MaFkGsQhZpB6pxOmvS3K8FYI72K//YmdfoW9X2qPsAKh1mkwxGD5zib9s1FIFed6E8g==", - "dev": true, - "license": "MIT" + "node_modules/@types/three": { + "version": "0.183.0", + "resolved": "https://registry.npmjs.org/@types/three/-/three-0.183.0.tgz", + "integrity": "sha512-AaGkvloQhxdrfMm/HbY8cpOz1K1jkEELn6zjFoY3yhAiC7zhhZE19+gDBybYwKk+GqXmWKxqDCB43NqyW3+QZw==", + "license": "MIT", + "dependencies": { + "@dimforge/rapier3d-compat": "~0.12.0", + "@tweenjs/tween.js": "~23.1.3", + "@types/stats.js": "*", + "@types/webxr": ">=0.5.17", + "@webgpu/types": "*", + "fflate": "~0.8.2", + "meshoptimizer": "~1.0.1" + } }, - "node_modules/@types/sizzle": { - "version": "2.3.10", - "resolved": "https://registry.npmjs.org/@types/sizzle/-/sizzle-2.3.10.tgz", - "integrity": "sha512-TC0dmN0K8YcWEAEfiPi5gJP14eJe30TTGjkvek3iM/1NdHHsdCA/Td6GvNndMOo/iSnIsZ4HuuhrYPDAmbxzww==", - "dev": true, - "license": "MIT" + "node_modules/@types/three/node_modules/@dimforge/rapier3d-compat": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/@dimforge/rapier3d-compat/-/rapier3d-compat-0.12.0.tgz", + "integrity": "sha512-uekIGetywIgopfD97oDL5PfeezkFpNhwlzlaEYNOA0N6ghdsOvh/HYjSMek5Q2O1PYvRSDFcqFVJl4r4ZBwOow==", + "license": "Apache-2.0" + }, + "node_modules/@types/trusted-types": { + "version": "2.0.7", + "resolved": "https://registry.npmjs.org/@types/trusted-types/-/trusted-types-2.0.7.tgz", + "integrity": "sha512-ScaPdn1dQczgbl0QFTeTOmVHFULt394XJgOQNoyVhZ6r2vLnMLJfBPd53SB52T/3G36VI1/g2MZaX0cwDuXsfw==", + "license": "MIT", + "optional": true, + "peer": true }, "node_modules/@types/unist": { "version": "3.0.3", @@ -3971,35 +1961,24 @@ "integrity": "sha512-ko/gIFJRv177XgZsZcBwnqJN5x/Gien8qNOn0D5bQU/zAzVf9Zt3BlcUiLqhV9y4ARk0GbT3tnUiPNgnTXzc/Q==", "license": "MIT" }, - "node_modules/@types/use-sync-external-store": { - "version": "0.0.6", - "resolved": "https://registry.npmjs.org/@types/use-sync-external-store/-/use-sync-external-store-0.0.6.tgz", - "integrity": "sha512-zFDAD+tlpf2r4asuHEj0XH6pY6i0g5NeAHPn+15wk3BV6JA69eERFXC1gyGThDkVa1zCyKr5jox1+2LbV/AMLg==", + "node_modules/@types/webxr": { + "version": "0.5.24", + "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.24.tgz", + "integrity": "sha512-h8fgEd/DpoS9CBrjEQXR+dIDraopAEfu4wYVNY2tEPwk60stPWhvZMf4Foo5FakuQ7HFZoa8WceaWFervK2Ovg==", "license": "MIT" }, - "node_modules/@types/yauzl": { - "version": "2.10.3", - "resolved": "https://registry.npmjs.org/@types/yauzl/-/yauzl-2.10.3.tgz", - "integrity": "sha512-oJoftv0LSuaDZE3Le4DbKX+KS9G36NzOeSap90UIK0yMA/NhKJhqlSGtNDORNRaIbQfzjXDrQa0ytJ6mNRGz/Q==", - "dev": true, - "license": "MIT", - "optional": true, - "dependencies": { - "@types/node": "*" - } - }, "node_modules/@typescript-eslint/eslint-plugin": { - "version": "8.55.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.55.0.tgz", - "integrity": "sha512-1y/MVSz0NglV1ijHC8OT49mPJ4qhPYjiK08YUQVbIOyu+5k862LKUHFkpKHWu//zmr7hDR2rhwUm6gnCGNmGBQ==", + "version": "8.54.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.54.0.tgz", + "integrity": "sha512-hAAP5io/7csFStuOmR782YmTthKBJ9ND3WVL60hcOjvtGFb+HJxH4O5huAcmcZ9v9G8P+JETiZ/G1B8MALnWZQ==", "dev": true, "license": "MIT", "dependencies": { "@eslint-community/regexpp": "^4.12.2", - "@typescript-eslint/scope-manager": "8.55.0", - "@typescript-eslint/type-utils": "8.55.0", - "@typescript-eslint/utils": "8.55.0", - "@typescript-eslint/visitor-keys": "8.55.0", + "@typescript-eslint/scope-manager": "8.54.0", + "@typescript-eslint/type-utils": "8.54.0", + "@typescript-eslint/utils": "8.54.0", + "@typescript-eslint/visitor-keys": "8.54.0", "ignore": "^7.0.5", "natural-compare": "^1.4.0", "ts-api-utils": "^2.4.0" @@ -4012,7 +1991,7 @@ "url": "https://opencollective.com/typescript-eslint" }, "peerDependencies": { - "@typescript-eslint/parser": "^8.55.0", + "@typescript-eslint/parser": "^8.54.0", "eslint": "^8.57.0 || ^9.0.0", "typescript": ">=4.8.4 <6.0.0" } @@ -4028,16 +2007,16 @@ } }, "node_modules/@typescript-eslint/parser": { - "version": "8.55.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.55.0.tgz", - "integrity": "sha512-4z2nCSBfVIMnbuu8uinj+f0o4qOeggYJLbjpPHka3KH1om7e+H9yLKTYgksTaHcGco+NClhhY2vyO3HsMH1RGw==", + "version": "8.54.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.54.0.tgz", + "integrity": "sha512-BtE0k6cjwjLZoZixN0t5AKP0kSzlGu7FctRXYuPAm//aaiZhmfq1JwdYpYr1brzEspYyFeF+8XF5j2VK6oalrA==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/scope-manager": "8.55.0", - "@typescript-eslint/types": "8.55.0", - "@typescript-eslint/typescript-estree": "8.55.0", - "@typescript-eslint/visitor-keys": "8.55.0", + "@typescript-eslint/scope-manager": "8.54.0", + "@typescript-eslint/types": "8.54.0", + "@typescript-eslint/typescript-estree": "8.54.0", + "@typescript-eslint/visitor-keys": "8.54.0", "debug": "^4.4.3" }, "engines": { @@ -4053,14 +2032,14 @@ } }, "node_modules/@typescript-eslint/project-service": { - "version": "8.55.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/project-service/-/project-service-8.55.0.tgz", - "integrity": "sha512-zRcVVPFUYWa3kNnjaZGXSu3xkKV1zXy8M4nO/pElzQhFweb7PPtluDLQtKArEOGmjXoRjnUZ29NjOiF0eCDkcQ==", + "version": "8.54.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/project-service/-/project-service-8.54.0.tgz", + "integrity": "sha512-YPf+rvJ1s7MyiWM4uTRhE4DvBXrEV+d8oC3P9Y2eT7S+HBS0clybdMIPnhiATi9vZOYDc7OQ1L/i6ga6NFYK/g==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/tsconfig-utils": "^8.55.0", - "@typescript-eslint/types": "^8.55.0", + "@typescript-eslint/tsconfig-utils": "^8.54.0", + "@typescript-eslint/types": "^8.54.0", "debug": "^4.4.3" }, "engines": { @@ -4075,14 +2054,14 @@ } }, "node_modules/@typescript-eslint/scope-manager": { - "version": "8.55.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.55.0.tgz", - "integrity": "sha512-fVu5Omrd3jeqeQLiB9f1YsuK/iHFOwb04bCtY4BSCLgjNbOD33ZdV6KyEqplHr+IlpgT0QTZ/iJ+wT7hvTx49Q==", + "version": "8.54.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.54.0.tgz", + "integrity": "sha512-27rYVQku26j/PbHYcVfRPonmOlVI6gihHtXFbTdB5sb6qA0wdAQAbyXFVarQ5t4HRojIz64IV90YtsjQSSGlQg==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.55.0", - "@typescript-eslint/visitor-keys": "8.55.0" + "@typescript-eslint/types": "8.54.0", + "@typescript-eslint/visitor-keys": "8.54.0" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -4093,9 +2072,9 @@ } }, "node_modules/@typescript-eslint/tsconfig-utils": { - "version": "8.55.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/tsconfig-utils/-/tsconfig-utils-8.55.0.tgz", - "integrity": "sha512-1R9cXqY7RQd7WuqSN47PK9EDpgFUK3VqdmbYrvWJZYDd0cavROGn+74ktWBlmJ13NXUQKlZ/iAEQHI/V0kKe0Q==", + "version": "8.54.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/tsconfig-utils/-/tsconfig-utils-8.54.0.tgz", + "integrity": "sha512-dRgOyT2hPk/JwxNMZDsIXDgyl9axdJI3ogZ2XWhBPsnZUv+hPesa5iuhdYt2gzwA9t8RE5ytOJ6xB0moV0Ujvw==", "dev": true, "license": "MIT", "engines": { @@ -4110,15 +2089,15 @@ } }, "node_modules/@typescript-eslint/type-utils": { - "version": "8.55.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.55.0.tgz", - "integrity": "sha512-x1iH2unH4qAt6I37I2CGlsNs+B9WGxurP2uyZLRz6UJoZWDBx9cJL1xVN/FiOmHEONEg6RIufdvyT0TEYIgC5g==", + "version": "8.54.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.54.0.tgz", + "integrity": "sha512-hiLguxJWHjjwL6xMBwD903ciAwd7DmK30Y9Axs/etOkftC3ZNN9K44IuRD/EB08amu+Zw6W37x9RecLkOo3pMA==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.55.0", - "@typescript-eslint/typescript-estree": "8.55.0", - "@typescript-eslint/utils": "8.55.0", + "@typescript-eslint/types": "8.54.0", + "@typescript-eslint/typescript-estree": "8.54.0", + "@typescript-eslint/utils": "8.54.0", "debug": "^4.4.3", "ts-api-utils": "^2.4.0" }, @@ -4135,9 +2114,9 @@ } }, "node_modules/@typescript-eslint/types": { - "version": "8.55.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.55.0.tgz", - "integrity": "sha512-ujT0Je8GI5BJWi+/mMoR0wxwVEQaxM+pi30xuMiJETlX80OPovb2p9E8ss87gnSVtYXtJoU9U1Cowcr6w2FE0w==", + "version": "8.54.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.54.0.tgz", + "integrity": "sha512-PDUI9R1BVjqu7AUDsRBbKMtwmjWcn4J3le+5LpcFgWULN3LvHC5rkc9gCVxbrsrGmO1jfPybN5s6h4Jy+OnkAA==", "dev": true, "license": "MIT", "engines": { @@ -4149,16 +2128,16 @@ } }, "node_modules/@typescript-eslint/typescript-estree": { - "version": "8.55.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.55.0.tgz", - "integrity": "sha512-EwrH67bSWdx/3aRQhCoxDaHM+CrZjotc2UCCpEDVqfCE+7OjKAGWNY2HsCSTEVvWH2clYQK8pdeLp42EVs+xQw==", + "version": "8.54.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.54.0.tgz", + "integrity": "sha512-BUwcskRaPvTk6fzVWgDPdUndLjB87KYDrN5EYGetnktoeAvPtO4ONHlAZDnj5VFnUANg0Sjm7j4usBlnoVMHwA==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/project-service": "8.55.0", - "@typescript-eslint/tsconfig-utils": "8.55.0", - "@typescript-eslint/types": "8.55.0", - "@typescript-eslint/visitor-keys": "8.55.0", + "@typescript-eslint/project-service": "8.54.0", + "@typescript-eslint/tsconfig-utils": "8.54.0", + "@typescript-eslint/types": "8.54.0", + "@typescript-eslint/visitor-keys": "8.54.0", "debug": "^4.4.3", "minimatch": "^9.0.5", "semver": "^7.7.3", @@ -4187,13 +2166,13 @@ } }, "node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch": { - "version": "9.0.9", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.9.tgz", - "integrity": "sha512-OBwBN9AL4dqmETlpS2zasx+vTeWclWzkblfZk7KTA5j3jeOONz/tRCnZomUyvNg83wL5Zv9Ss6HMJXAgL8R2Yg==", + "version": "9.0.5", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", + "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", "dev": true, "license": "ISC", "dependencies": { - "brace-expansion": "^2.0.2" + "brace-expansion": "^2.0.1" }, "engines": { "node": ">=16 || 14 >=14.17" @@ -4202,17 +2181,30 @@ "url": "https://github.com/sponsors/isaacs" } }, + "node_modules/@typescript-eslint/typescript-estree/node_modules/semver": { + "version": "7.7.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.4.tgz", + "integrity": "sha512-vFKC2IEtQnVhpT78h1Yp8wzwrf8CM+MzKMHGJZfBtzhZNycRFnXsHk6E5TxIkkMsgNS7mdX3AGB7x2QM2di4lA==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/@typescript-eslint/utils": { - "version": "8.55.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.55.0.tgz", - "integrity": "sha512-BqZEsnPGdYpgyEIkDC1BadNY8oMwckftxBT+C8W0g1iKPdeqKZBtTfnvcq0nf60u7MkjFO8RBvpRGZBPw4L2ow==", + "version": "8.54.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.54.0.tgz", + "integrity": "sha512-9Cnda8GS57AQakvRyG0PTejJNlA2xhvyNtEVIMlDWOOeEyBkYWhGPnfrIAnqxLMTSTo6q8g12XVjjev5l1NvMA==", "dev": true, "license": "MIT", "dependencies": { "@eslint-community/eslint-utils": "^4.9.1", - "@typescript-eslint/scope-manager": "8.55.0", - "@typescript-eslint/types": "8.55.0", - "@typescript-eslint/typescript-estree": "8.55.0" + "@typescript-eslint/scope-manager": "8.54.0", + "@typescript-eslint/types": "8.54.0", + "@typescript-eslint/typescript-estree": "8.54.0" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -4227,13 +2219,13 @@ } }, "node_modules/@typescript-eslint/visitor-keys": { - "version": "8.55.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.55.0.tgz", - "integrity": "sha512-AxNRwEie8Nn4eFS1FzDMJWIISMGoXMb037sgCBJ3UR6o0fQTzr2tqN9WT+DkWJPhIdQCfV7T6D387566VtnCJA==", + "version": "8.54.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.54.0.tgz", + "integrity": "sha512-VFlhGSl4opC0bprJiItPQ1RfUhGDIBokcPwaFH4yiBCaNPeld/9VeXbiPO1cLyorQi1G1vL+ecBk1x8o1axORA==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.55.0", + "@typescript-eslint/types": "8.54.0", "eslint-visitor-keys": "^4.2.1" }, "engines": { @@ -4519,147 +2511,29 @@ "win32" ] }, - "node_modules/@vitest/coverage-v8": { - "version": "4.0.18", - "resolved": "https://registry.npmjs.org/@vitest/coverage-v8/-/coverage-v8-4.0.18.tgz", - "integrity": "sha512-7i+N2i0+ME+2JFZhfuz7Tg/FqKtilHjGyGvoHYQ6iLV0zahbsJ9sljC9OcFcPDbhYKCet+sG8SsVqlyGvPflZg==", - "dev": true, + "node_modules/@use-gesture/core": { + "version": "10.3.1", + "resolved": "https://registry.npmjs.org/@use-gesture/core/-/core-10.3.1.tgz", + "integrity": "sha512-WcINiDt8WjqBdUXye25anHiNxPc0VOrlT8F6LLkU6cycrOGUDyY/yyFmsg3k8i5OLvv25llc0QC45GhR/C8llw==", + "license": "MIT" + }, + "node_modules/@use-gesture/react": { + "version": "10.3.1", + "resolved": "https://registry.npmjs.org/@use-gesture/react/-/react-10.3.1.tgz", + "integrity": "sha512-Yy19y6O2GJq8f7CHf7L0nxL8bf4PZCPaVOCgJrusOeFHY1LvHgYXnmnXg6N5iwAnbgbZCDjo60SiM6IPJi9C5g==", "license": "MIT", "dependencies": { - "@bcoe/v8-coverage": "^1.0.2", - "@vitest/utils": "4.0.18", - "ast-v8-to-istanbul": "^0.3.10", - "istanbul-lib-coverage": "^3.2.2", - "istanbul-lib-report": "^3.0.1", - "istanbul-reports": "^3.2.0", - "magicast": "^0.5.1", - "obug": "^2.1.1", - "std-env": "^3.10.0", - "tinyrainbow": "^3.0.3" - }, - "funding": { - "url": "https://opencollective.com/vitest" + "@use-gesture/core": "10.3.1" }, "peerDependencies": { - "@vitest/browser": "4.0.18", - "vitest": "4.0.18" - }, - "peerDependenciesMeta": { - "@vitest/browser": { - "optional": true - } + "react": ">= 16.8.0" } }, - "node_modules/@vitest/expect": { - "version": "4.0.18", - "resolved": "https://registry.npmjs.org/@vitest/expect/-/expect-4.0.18.tgz", - "integrity": "sha512-8sCWUyckXXYvx4opfzVY03EOiYVxyNrHS5QxX3DAIi5dpJAAkyJezHCP77VMX4HKA2LDT/Jpfo8i2r5BE3GnQQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@standard-schema/spec": "^1.0.0", - "@types/chai": "^5.2.2", - "@vitest/spy": "4.0.18", - "@vitest/utils": "4.0.18", - "chai": "^6.2.1", - "tinyrainbow": "^3.0.3" - }, - "funding": { - "url": "https://opencollective.com/vitest" - } - }, - "node_modules/@vitest/mocker": { - "version": "4.0.18", - "resolved": "https://registry.npmjs.org/@vitest/mocker/-/mocker-4.0.18.tgz", - "integrity": "sha512-HhVd0MDnzzsgevnOWCBj5Otnzobjy5wLBe4EdeeFGv8luMsGcYqDuFRMcttKWZA5vVO8RFjexVovXvAM4JoJDQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@vitest/spy": "4.0.18", - "estree-walker": "^3.0.3", - "magic-string": "^0.30.21" - }, - "funding": { - "url": "https://opencollective.com/vitest" - }, - "peerDependencies": { - "msw": "^2.4.9", - "vite": "^6.0.0 || ^7.0.0-0" - }, - "peerDependenciesMeta": { - "msw": { - "optional": true - }, - "vite": { - "optional": true - } - } - }, - "node_modules/@vitest/pretty-format": { - "version": "4.0.18", - "resolved": "https://registry.npmjs.org/@vitest/pretty-format/-/pretty-format-4.0.18.tgz", - "integrity": "sha512-P24GK3GulZWC5tz87ux0m8OADrQIUVDPIjjj65vBXYG17ZeU3qD7r+MNZ1RNv4l8CGU2vtTRqixrOi9fYk/yKw==", - "dev": true, - "license": "MIT", - "dependencies": { - "tinyrainbow": "^3.0.3" - }, - "funding": { - "url": "https://opencollective.com/vitest" - } - }, - "node_modules/@vitest/runner": { - "version": "4.0.18", - "resolved": "https://registry.npmjs.org/@vitest/runner/-/runner-4.0.18.tgz", - "integrity": "sha512-rpk9y12PGa22Jg6g5M3UVVnTS7+zycIGk9ZNGN+m6tZHKQb7jrP7/77WfZy13Y/EUDd52NDsLRQhYKtv7XfPQw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@vitest/utils": "4.0.18", - "pathe": "^2.0.3" - }, - "funding": { - "url": "https://opencollective.com/vitest" - } - }, - "node_modules/@vitest/snapshot": { - "version": "4.0.18", - "resolved": "https://registry.npmjs.org/@vitest/snapshot/-/snapshot-4.0.18.tgz", - "integrity": "sha512-PCiV0rcl7jKQjbgYqjtakly6T1uwv/5BQ9SwBLekVg/EaYeQFPiXcgrC2Y7vDMA8dM1SUEAEV82kgSQIlXNMvA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@vitest/pretty-format": "4.0.18", - "magic-string": "^0.30.21", - "pathe": "^2.0.3" - }, - "funding": { - "url": "https://opencollective.com/vitest" - } - }, - "node_modules/@vitest/spy": { - "version": "4.0.18", - "resolved": "https://registry.npmjs.org/@vitest/spy/-/spy-4.0.18.tgz", - "integrity": "sha512-cbQt3PTSD7P2OARdVW3qWER5EGq7PHlvE+QfzSC0lbwO+xnt7+XH06ZzFjFRgzUX//JmpxrCu92VdwvEPlWSNw==", - "dev": true, - "license": "MIT", - "funding": { - "url": "https://opencollective.com/vitest" - } - }, - "node_modules/@vitest/utils": { - "version": "4.0.18", - "resolved": "https://registry.npmjs.org/@vitest/utils/-/utils-4.0.18.tgz", - "integrity": "sha512-msMRKLMVLWygpK3u2Hybgi4MNjcYJvwTb0Ru09+fOyCXIgT5raYP041DRRdiJiI3k/2U6SEbAETB3YtBrUkCFA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@vitest/pretty-format": "4.0.18", - "tinyrainbow": "^3.0.3" - }, - "funding": { - "url": "https://opencollective.com/vitest" - } + "node_modules/@webgpu/types": { + "version": "0.1.69", + "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.69.tgz", + "integrity": "sha512-RPmm6kgRbI8e98zSD3RVACvnuktIja5+yLgDAkTmxLr90BEwdTXRQWNLF3ETTTyH/8mKhznZuN5AveXYFEsMGQ==", + "license": "BSD-3-Clause" }, "node_modules/acorn": { "version": "8.15.0", @@ -4684,30 +2558,6 @@ "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" } }, - "node_modules/agent-base": { - "version": "7.1.4", - "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", - "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 14" - } - }, - "node_modules/aggregate-error": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.1.0.tgz", - "integrity": "sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==", - "dev": true, - "license": "MIT", - "dependencies": { - "clean-stack": "^2.0.0", - "indent-string": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/ajv": { "version": "6.12.6", "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", @@ -4725,97 +2575,6 @@ "url": "https://github.com/sponsors/epoberezkin" } }, - "node_modules/ajv-formats": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/ajv-formats/-/ajv-formats-3.0.1.tgz", - "integrity": "sha512-8iUql50EUR+uUcdRQ3HDqa6EVyo3docL8g5WJ3FNcWmu62IbkGUue/pEyLBW8VGKKucTPgqeks4fIU1DA4yowQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "ajv": "^8.0.0" - }, - "peerDependencies": { - "ajv": "^8.0.0" - }, - "peerDependenciesMeta": { - "ajv": { - "optional": true - } - } - }, - "node_modules/ajv-formats/node_modules/ajv": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", - "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", - "dev": true, - "license": "MIT", - "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/ajv-formats/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true, - "license": "MIT" - }, - "node_modules/ansi-colors": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.3.tgz", - "integrity": "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/ansi-escapes": { - "version": "4.3.2", - "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", - "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "type-fest": "^0.21.3" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/ansi-escapes/node_modules/type-fest": { - "version": "0.21.3", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", - "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", - "dev": true, - "license": "(MIT OR CC0-1.0)", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, "node_modules/ansi-styles": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", @@ -4832,55 +2591,6 @@ "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/any-promise": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/any-promise/-/any-promise-1.3.0.tgz", - "integrity": "sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==", - "dev": true, - "license": "MIT" - }, - "node_modules/anymatch": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", - "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", - "dev": true, - "license": "ISC", - "dependencies": { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/arch": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/arch/-/arch-2.2.0.tgz", - "integrity": "sha512-Of/R0wqp83cgHozfIYLbBMnej79U/SVGOOyuB3VVFv1NRM/PSFMK12x9KVtiYzJqmnU5WR2qp0Z5rHb7sWGnFQ==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT" - }, - "node_modules/arg": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/arg/-/arg-5.0.2.tgz", - "integrity": "sha512-PYjyFOLKQ9y57JvQ6QLo8dAgNqswh8M1RMJYdQduT6xbWSgK36P/Z/v+p888pM69jMMfS8Xd8F6I1kQ/I9HUGg==", - "dev": true, - "license": "MIT" - }, "node_modules/argparse": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", @@ -4888,26 +2598,14 @@ "dev": true, "license": "Python-2.0" }, - "node_modules/aria-hidden": { - "version": "1.2.6", - "resolved": "https://registry.npmjs.org/aria-hidden/-/aria-hidden-1.2.6.tgz", - "integrity": "sha512-ik3ZgC9dY/lYVVM++OISsaYDeg1tb0VtP5uL3ouh1koGOaUMDPpbFIei4JkFimWUFPn90sbMNMXQAIVOlnYKJA==", - "license": "MIT", - "dependencies": { - "tslib": "^2.0.0" - }, - "engines": { - "node": ">=10" - } - }, "node_modules/aria-query": { - "version": "5.3.0", - "resolved": "https://registry.npmjs.org/aria-query/-/aria-query-5.3.0.tgz", - "integrity": "sha512-b0P0sZPKtyu8HkeRAfCq0IfURZK+SuwMjY1UXGBU27wpAiTwQAIlq56IbIO+ytk/JjS1fMR14ee5WBBfKi5J6A==", + "version": "5.3.2", + "resolved": "https://registry.npmjs.org/aria-query/-/aria-query-5.3.2.tgz", + "integrity": "sha512-COROpnaoap1E2F000S62r6A60uHZnmlvomhfyT2DlTcrY1OrBKn2UhH7qn5wTC9zMvD0AY7csdPSNwKP+7WiQw==", "dev": true, "license": "Apache-2.0", - "dependencies": { - "dequal": "^2.0.3" + "engines": { + "node": ">= 0.4" } }, "node_modules/array-buffer-byte-length": { @@ -5070,36 +2768,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/asn1": { - "version": "0.2.6", - "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.6.tgz", - "integrity": "sha512-ix/FxPn0MDjeyJ7i/yoHGFt/EX6LyNbxSEhPPXODPL+KB0VPk86UYfL0lMdy+KCnv+fmvIzySwaK5COwqVbWTQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "safer-buffer": "~2.1.0" - } - }, - "node_modules/assert-plus": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", - "integrity": "sha512-NfJ4UzBCcQGLDlQq7nHxH+tv3kyZ0hHQqF5BO6J7tNJeP5do1llPr8dZ8zHonfhAu0PHAdMkSo+8o0wxg9lZWw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.8" - } - }, - "node_modules/assertion-error": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-2.0.1.tgz", - "integrity": "sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12" - } - }, "node_modules/ast-types-flow": { "version": "0.0.8", "resolved": "https://registry.npmjs.org/ast-types-flow/-/ast-types-flow-0.0.8.tgz", @@ -5107,42 +2775,6 @@ "dev": true, "license": "MIT" }, - "node_modules/ast-v8-to-istanbul": { - "version": "0.3.11", - "resolved": "https://registry.npmjs.org/ast-v8-to-istanbul/-/ast-v8-to-istanbul-0.3.11.tgz", - "integrity": "sha512-Qya9fkoofMjCBNVdWINMjB5KZvkYfaO9/anwkWnjxibpWUxo5iHl2sOdP7/uAqaRuUYuoo8rDwnbaaKVFxoUvw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@jridgewell/trace-mapping": "^0.3.31", - "estree-walker": "^3.0.3", - "js-tokens": "^10.0.0" - } - }, - "node_modules/ast-v8-to-istanbul/node_modules/js-tokens": { - "version": "10.0.0", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-10.0.0.tgz", - "integrity": "sha512-lM/UBzQmfJRo9ABXbPWemivdCW8V2G8FHaHdypQaIy523snUjog0W71ayWXTjiR+ixeMyVHN2XcpnTd/liPg/Q==", - "dev": true, - "license": "MIT" - }, - "node_modules/astral-regex": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-2.0.0.tgz", - "integrity": "sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/async": { - "version": "3.2.6", - "resolved": "https://registry.npmjs.org/async/-/async-3.2.6.tgz", - "integrity": "sha512-htCUDlxyyCLMgaM3xXg0C0LW2xqfuQ6p05pCEIsXuyQ+a1koYKTuBMzRNwmybfLgvJDMd0r1LTn4+E0Ti6C2AA==", - "dev": true, - "license": "MIT" - }, "node_modules/async-function": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/async-function/-/async-function-1.0.0.tgz", @@ -5153,60 +2785,6 @@ "node": ">= 0.4" } }, - "node_modules/asynckit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", - "dev": true, - "license": "MIT" - }, - "node_modules/at-least-node": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz", - "integrity": "sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">= 4.0.0" - } - }, - "node_modules/autoprefixer": { - "version": "10.4.24", - "resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.4.24.tgz", - "integrity": "sha512-uHZg7N9ULTVbutaIsDRoUkoS8/h3bdsmVJYZ5l3wv8Cp/6UIIoRDm90hZ+BwxUj/hGBEzLxdHNSKuFpn8WOyZw==", - "dev": true, - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/postcss/" - }, - { - "type": "tidelift", - "url": "https://tidelift.com/funding/github/npm/autoprefixer" - }, - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], - "license": "MIT", - "dependencies": { - "browserslist": "^4.28.1", - "caniuse-lite": "^1.0.30001766", - "fraction.js": "^5.3.4", - "picocolors": "^1.1.1", - "postcss-value-parser": "^4.2.0" - }, - "bin": { - "autoprefixer": "bin/autoprefixer" - }, - "engines": { - "node": "^10 || ^12 || >=14" - }, - "peerDependencies": { - "postcss": "^8.1.0" - } - }, "node_modules/available-typed-arrays": { "version": "1.0.7", "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.7.tgz", @@ -5223,23 +2801,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/aws-sign2": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", - "integrity": "sha512-08kcGqnYf/YmjoRhfxyu+CLxBjUtHLXLXX/vUfx9l2LYzG3c1m61nrpyFUZI6zeS+Li/wWMMidD9KgrqtGq3mA==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "*" - } - }, - "node_modules/aws4": { - "version": "1.13.2", - "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.13.2.tgz", - "integrity": "sha512-lHe62zvbTB5eEABUVi/AwVh0ZKY9rMMDhmm+eeyuuUQbQ3+J+fONVQOZyj+DdrvD4BY33uYniyRJ4UJIaSKAfw==", - "dev": true, - "license": "MIT" - }, "node_modules/axe-core": { "version": "4.11.1", "resolved": "https://registry.npmjs.org/axe-core/-/axe-core-4.11.1.tgz", @@ -5281,7 +2842,6 @@ "version": "1.5.1", "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", - "dev": true, "funding": [ { "type": "github", @@ -5307,42 +2867,48 @@ "baseline-browser-mapping": "dist/cli.js" } }, - "node_modules/bcrypt-pbkdf": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", - "integrity": "sha512-qeFIXtP4MSoi6NLqO12WfqARWWuCKi2Rn/9hJLEmtB5yTNr9DqFWkJRCf2qShWzPeAMRnOgCrq0sg/KLv5ES9w==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "tweetnacl": "^0.14.3" - } - }, - "node_modules/binary-extensions": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.3.0.tgz", - "integrity": "sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==", - "dev": true, + "node_modules/better-sqlite3": { + "version": "12.6.2", + "resolved": "https://registry.npmjs.org/better-sqlite3/-/better-sqlite3-12.6.2.tgz", + "integrity": "sha512-8VYKM3MjCa9WcaSAI3hzwhmyHVlH8tiGFwf0RlTsZPWJ1I5MkzjiudCo4KC4DxOaL/53A5B1sI/IbldNFDbsKA==", + "hasInstallScript": true, "license": "MIT", - "engines": { - "node": ">=8" + "dependencies": { + "bindings": "^1.5.0", + "prebuild-install": "^7.1.1" }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "engines": { + "node": "20.x || 22.x || 23.x || 24.x || 25.x" } }, - "node_modules/blob-util": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/blob-util/-/blob-util-2.0.2.tgz", - "integrity": "sha512-T7JQa+zsXXEa6/8ZhHcQEW1UFfVM49Ts65uBkFL6fz2QmrElqmbajIDJvuA0tEhRe5eIjpV9ZF+0RfZR9voJFQ==", - "dev": true, - "license": "Apache-2.0" + "node_modules/bidi-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/bidi-js/-/bidi-js-1.0.3.tgz", + "integrity": "sha512-RKshQI1R3YQ+n9YJz2QQ147P66ELpa1FQEg20Dk8oW9t2KgLbpDLLp9aGZ7y8WHSshDknG0bknqGw5/tyCs5tw==", + "license": "MIT", + "dependencies": { + "require-from-string": "^2.0.2" + } }, - "node_modules/bluebird": { - "version": "3.7.2", - "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.7.2.tgz", - "integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==", - "dev": true, - "license": "MIT" + "node_modules/bindings": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz", + "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", + "license": "MIT", + "dependencies": { + "file-uri-to-path": "1.0.0" + } + }, + "node_modules/bl": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/bl/-/bl-4.1.0.tgz", + "integrity": "sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==", + "license": "MIT", + "dependencies": { + "buffer": "^5.5.0", + "inherits": "^2.0.4", + "readable-stream": "^3.4.0" + } }, "node_modules/brace-expansion": { "version": "1.1.12", @@ -5406,7 +2972,6 @@ "version": "5.7.1", "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", - "dev": true, "funding": [ { "type": "github", @@ -5427,26 +2992,6 @@ "ieee754": "^1.1.13" } }, - "node_modules/buffer-crc32": { - "version": "0.2.13", - "resolved": "https://registry.npmjs.org/buffer-crc32/-/buffer-crc32-0.2.13.tgz", - "integrity": "sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": "*" - } - }, - "node_modules/cachedir": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/cachedir/-/cachedir-2.4.0.tgz", - "integrity": "sha512-9EtFOZR8g22CL7BWjJ9BUx1+A/djkofnyW3aOXZORNW2kxoUpx2h+uN2cOqwPmFhnpVmxg+KW2OjOSgChTEvsQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, "node_modules/call-bind": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.8.tgz", @@ -5507,14 +3052,17 @@ "node": ">=6" } }, - "node_modules/camelcase-css": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/camelcase-css/-/camelcase-css-2.0.1.tgz", - "integrity": "sha512-QOSvevhslijgYwRx6Rv7zKdMF8lbRmx+uQGx2+vDc+KI/eBnsy9kit5aj23AgGu3pa4t9AgwbnXWqS+iOY+2aA==", - "dev": true, + "node_modules/camera-controls": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/camera-controls/-/camera-controls-3.1.2.tgz", + "integrity": "sha512-xkxfpG2ECZ6Ww5/9+kf4mfg1VEYAoe9aDSY+IwF0UEs7qEzwy0aVRfs2grImIECs/PoBtWFrh7RXsQkwG922JA==", "license": "MIT", "engines": { - "node": ">= 6" + "node": ">=22.0.0", + "npm": ">=10.5.1" + }, + "peerDependencies": { + "three": ">=0.126.1" } }, "node_modules/caniuse-lite": { @@ -5537,13 +3085,6 @@ ], "license": "CC-BY-4.0" }, - "node_modules/caseless": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", - "integrity": "sha512-4tYFyifaFfGacoiObjJegolkwSU4xQNGbVgUiNYVUxbQ2x2lUsFvY4hVgVzGiIe6WLOPqycWXA40l+PWsxthUw==", - "dev": true, - "license": "Apache-2.0" - }, "node_modules/ccount": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/ccount/-/ccount-2.0.1.tgz", @@ -5554,16 +3095,6 @@ "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/chai": { - "version": "6.2.2", - "resolved": "https://registry.npmjs.org/chai/-/chai-6.2.2.tgz", - "integrity": "sha512-NUPRluOfOiTKBKvWPtSD4PhFvWCqOi0BGStNWs57X9js7XGTprSmFoz5F0tWhR4WPjNeR9jXqdC7/UpSJTnlRg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - } - }, "node_modules/chalk": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", @@ -5581,19 +3112,6 @@ "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/chalk/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "license": "MIT", - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/character-entities": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/character-entities/-/character-entities-2.0.2.tgz", @@ -5634,116 +3152,11 @@ "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/check-more-types": { - "version": "2.24.0", - "resolved": "https://registry.npmjs.org/check-more-types/-/check-more-types-2.24.0.tgz", - "integrity": "sha512-Pj779qHxV2tuapviy1bSZNEL1maXr13bPYpsvSDB68HlYcYuhlDrmGd63i0JHMCLKzc7rUSNIrpdJlhVlNwrxA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/chokidar": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-5.0.0.tgz", - "integrity": "sha512-TQMmc3w+5AxjpL8iIiwebF73dRDF4fBIieAqGn9RGCWaEVwQ6Fb2cGe31Yns0RRIzii5goJ1Y7xbMwo1TxMplw==", - "dev": true, - "license": "MIT", - "dependencies": { - "readdirp": "^5.0.0" - }, - "engines": { - "node": ">= 20.19.0" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/ci-info": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.4.0.tgz", - "integrity": "sha512-77PSwercCZU2Fc4sX94eF8k8Pxte6JAwL4/ICZLFjJLqegs7kCuAsqqj/70NQF6TvDpgFjkubQB2FW2ZZddvQg==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/sibiraj-s" - } - ], - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/class-variance-authority": { - "version": "0.7.1", - "resolved": "https://registry.npmjs.org/class-variance-authority/-/class-variance-authority-0.7.1.tgz", - "integrity": "sha512-Ka+9Trutv7G8M6WT6SeiRWz792K5qEqIGEGzXKhAE6xOWAY6pPH8U+9IY3oCMv6kqTmLsv7Xh/2w2RigkePMsg==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "clsx": "^2.1.1" - }, - "funding": { - "url": "https://polar.sh/cva" - } - }, - "node_modules/clean-stack": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz", - "integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/cli-cursor": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-3.1.0.tgz", - "integrity": "sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==", - "dev": true, - "license": "MIT", - "dependencies": { - "restore-cursor": "^3.1.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/cli-table3": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/cli-table3/-/cli-table3-0.6.1.tgz", - "integrity": "sha512-w0q/enDHhPLq44ovMGdQeeDLvwxwavsJX7oQGYt/LrBlYsyaxyDnp6z3QzFut/6kLLKnlcUVJLrpB7KBfgG/RA==", - "dev": true, - "license": "MIT", - "dependencies": { - "string-width": "^4.2.0" - }, - "engines": { - "node": "10.* || >= 12.*" - }, - "optionalDependencies": { - "colors": "1.4.0" - } - }, - "node_modules/cli-truncate": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/cli-truncate/-/cli-truncate-2.1.0.tgz", - "integrity": "sha512-n8fOixwDD6b/ObinzTrp1ZKFzbgvKZvuz/TvejnLn1aQfC6r52XEx85FmuC+3HI+JM7coBRXUvNqEU2PHVrHpg==", - "dev": true, - "license": "MIT", - "dependencies": { - "slice-ansi": "^3.0.0", - "string-width": "^4.2.0" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } + "node_modules/chownr": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.4.tgz", + "integrity": "sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==", + "license": "ISC" }, "node_modules/client-only": { "version": "0.0.1", @@ -5760,22 +3173,6 @@ "node": ">=6" } }, - "node_modules/cmdk": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/cmdk/-/cmdk-1.1.1.tgz", - "integrity": "sha512-Vsv7kFaXm+ptHDMZ7izaRsP70GgrW9NBNGswt9OZaVBLlE0SNpDq8eu/VGXyF9r7M0azK3Wy7OlYXsuyYLFzHg==", - "license": "MIT", - "dependencies": { - "@radix-ui/react-compose-refs": "^1.1.1", - "@radix-ui/react-dialog": "^1.1.6", - "@radix-ui/react-id": "^1.1.0", - "@radix-ui/react-primitive": "^2.0.2" - }, - "peerDependencies": { - "react": "^18 || ^19 || ^19.0.0-rc", - "react-dom": "^18 || ^19 || ^19.0.0-rc" - } - }, "node_modules/color-convert": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", @@ -5796,37 +3193,6 @@ "dev": true, "license": "MIT" }, - "node_modules/colorette": { - "version": "2.0.20", - "resolved": "https://registry.npmjs.org/colorette/-/colorette-2.0.20.tgz", - "integrity": "sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==", - "dev": true, - "license": "MIT" - }, - "node_modules/colors": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/colors/-/colors-1.4.0.tgz", - "integrity": "sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA==", - "dev": true, - "license": "MIT", - "optional": true, - "engines": { - "node": ">=0.1.90" - } - }, - "node_modules/combined-stream": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", - "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", - "dev": true, - "license": "MIT", - "dependencies": { - "delayed-stream": "~1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, "node_modules/comma-separated-tokens": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/comma-separated-tokens/-/comma-separated-tokens-2.0.3.tgz", @@ -5837,33 +3203,6 @@ "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/commander": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-6.2.1.tgz", - "integrity": "sha512-U7VdrJFnJgo4xjrHpTzu0yrHPGImdsmD95ZlgYSEajAn2JKzDhDTPG9kBTefmObL2w/ngeZnilk+OV9CG3d7UA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 6" - } - }, - "node_modules/common-tags": { - "version": "1.8.2", - "resolved": "https://registry.npmjs.org/common-tags/-/common-tags-1.8.2.tgz", - "integrity": "sha512-gk/Z852D2Wtb//0I+kRFNKKE9dIIVirjoqPoA1wJU+XePVXZfGeBpk45+A1rKO4Q43prqWBNY/MiIeRLbPWUaA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=4.0.0" - } - }, - "node_modules/compare-versions": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/compare-versions/-/compare-versions-6.1.1.tgz", - "integrity": "sha512-4hm4VPpIecmlg59CHXnRDnqGplJFrbLG4aFEl5vl6cK1u76ws3LLvX7ikFnTDl5vo39sjWD6AaDPYodJp/NNHg==", - "dev": true, - "license": "MIT" - }, "node_modules/concat-map": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", @@ -5878,18 +3217,28 @@ "dev": true, "license": "MIT" }, - "node_modules/core-util-is": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", - "integrity": "sha512-3lqz5YjWTYnW6dlDa5TLaTCcShfar1e40rmcJVwCBJC6mWlFuj0eCHIElmG1g5kyuJ/GD+8Wn4FFCcz4gJPfaQ==", - "dev": true, - "license": "MIT" + "node_modules/cross-env": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-env/-/cross-env-7.0.3.tgz", + "integrity": "sha512-+/HKd6EgcQCJGh2PSjZuUitQBQynKor4wrFbRg4DtAgS1aWO+gU52xpH7M9ScGgXSYmAVS9bIJ8EzuaGw0oNAw==", + "license": "MIT", + "dependencies": { + "cross-spawn": "^7.0.1" + }, + "bin": { + "cross-env": "src/bin/cross-env.js", + "cross-env-shell": "src/bin/cross-env-shell.js" + }, + "engines": { + "node": ">=10.14", + "npm": ">=6", + "yarn": ">=1" + } }, "node_modules/cross-spawn": { "version": "7.0.6", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", - "dev": true, "license": "MIT", "dependencies": { "path-key": "^3.1.0", @@ -5900,18 +3249,10 @@ "node": ">= 8" } }, - "node_modules/css.escape": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/css.escape/-/css.escape-1.5.1.tgz", - "integrity": "sha512-YUifsXXuknHlUsmlgyY0PKzgPOr7/FjCePfHNt0jxm83wHZi44VDMQ7/fGNkjY3/jV1MC+1CmZbaHzugyeRtpg==", - "dev": true, - "license": "MIT" - }, "node_modules/cssesc": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/cssesc/-/cssesc-3.0.0.tgz", "integrity": "sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg==", - "dev": true, "license": "MIT", "bin": { "cssesc": "bin/cssesc" @@ -5920,93 +3261,12 @@ "node": ">=4" } }, - "node_modules/cssstyle": { - "version": "4.6.0", - "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-4.6.0.tgz", - "integrity": "sha512-2z+rWdzbbSZv6/rhtvzvqeZQHrBaqgogqt85sqFNbabZOuFbCVFb8kPeEtZjiKkbrm395irpNKiYeFeLiQnFPg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@asamuzakjp/css-color": "^3.2.0", - "rrweb-cssom": "^0.8.0" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/cssstyle/node_modules/rrweb-cssom": { - "version": "0.8.0", - "resolved": "https://registry.npmjs.org/rrweb-cssom/-/rrweb-cssom-0.8.0.tgz", - "integrity": "sha512-guoltQEx+9aMf2gDZ0s62EcV8lsXR+0w8915TC3ITdn2YueuNjdAYh/levpU9nFaoChh9RUS5ZdQMrKfVEN9tw==", - "dev": true, - "license": "MIT" - }, "node_modules/csstype": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz", - "integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==", + "version": "3.2.3", + "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.2.3.tgz", + "integrity": "sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==", "license": "MIT" }, - "node_modules/cypress": { - "version": "14.5.4", - "resolved": "https://registry.npmjs.org/cypress/-/cypress-14.5.4.tgz", - "integrity": "sha512-0Dhm4qc9VatOcI1GiFGVt8osgpPdqJLHzRwcAB5MSD/CAAts3oybvPUPawHyvJZUd8osADqZe/xzMsZ8sDTjXw==", - "dev": true, - "hasInstallScript": true, - "license": "MIT", - "dependencies": { - "@cypress/request": "^3.0.9", - "@cypress/xvfb": "^1.2.4", - "@types/sinonjs__fake-timers": "8.1.1", - "@types/sizzle": "^2.3.2", - "arch": "^2.2.0", - "blob-util": "^2.0.2", - "bluebird": "^3.7.2", - "buffer": "^5.7.1", - "cachedir": "^2.3.0", - "chalk": "^4.1.0", - "check-more-types": "^2.24.0", - "ci-info": "^4.1.0", - "cli-cursor": "^3.1.0", - "cli-table3": "0.6.1", - "commander": "^6.2.1", - "common-tags": "^1.8.0", - "dayjs": "^1.10.4", - "debug": "^4.3.4", - "enquirer": "^2.3.6", - "eventemitter2": "6.4.7", - "execa": "4.1.0", - "executable": "^4.1.1", - "extract-zip": "2.0.1", - "figures": "^3.2.0", - "fs-extra": "^9.1.0", - "getos": "^3.2.1", - "hasha": "5.2.2", - "is-installed-globally": "~0.4.0", - "lazy-ass": "^1.6.0", - "listr2": "^3.8.3", - "lodash": "^4.17.21", - "log-symbols": "^4.0.0", - "minimist": "^1.2.8", - "ospath": "^1.2.2", - "pretty-bytes": "^5.6.0", - "process": "^0.11.10", - "proxy-from-env": "1.0.0", - "request-progress": "^3.0.0", - "semver": "^7.7.1", - "supports-color": "^8.1.1", - "tmp": "~0.2.3", - "tree-kill": "1.2.2", - "untildify": "^4.0.0", - "yauzl": "^2.10.0" - }, - "bin": { - "cypress": "bin/cypress" - }, - "engines": { - "node": "^18.0.0 || ^20.0.0 || >=22.0.0" - } - }, "node_modules/d3-array": { "version": "3.2.4", "resolved": "https://registry.npmjs.org/d3-array/-/d3-array-3.2.4.tgz", @@ -6135,33 +3395,6 @@ "dev": true, "license": "BSD-2-Clause" }, - "node_modules/dashdash": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", - "integrity": "sha512-jRFi8UDGo6j+odZiEpjazZaWqEal3w/basFjQHQEwVtZJGDpxbH1MeYluwCS8Xq5wmLJooDlMgvVarmWfGM44g==", - "dev": true, - "license": "MIT", - "dependencies": { - "assert-plus": "^1.0.0" - }, - "engines": { - "node": ">=0.10" - } - }, - "node_modules/data-urls": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/data-urls/-/data-urls-5.0.0.tgz", - "integrity": "sha512-ZYP5VBHshaDAiVZxjbRVcFJpc+4xGgT0bK3vzy1HLN8jTO975HEbuYzZJcHoQEY5K1a0z8YayJkyVETa08eNTg==", - "dev": true, - "license": "MIT", - "dependencies": { - "whatwg-mimetype": "^4.0.0", - "whatwg-url": "^14.0.0" - }, - "engines": { - "node": ">=18" - } - }, "node_modules/data-view-buffer": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/data-view-buffer/-/data-view-buffer-1.0.2.tgz", @@ -6216,12 +3449,15 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/dayjs": { - "version": "1.11.19", - "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.19.tgz", - "integrity": "sha512-t5EcLVS6QPBNqM2z8fakk/NKel+Xzshgt8FFKAn+qwlD1pzZWxh0nVCrvFK7ZDb6XucZeF9z8C7CBWTRIVApAw==", - "dev": true, - "license": "MIT" + "node_modules/date-fns": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-4.1.0.tgz", + "integrity": "sha512-Ukq0owbQXxa/U3EGtsdVBkR1w7KOQ5gIBqdH2hkvknzZPYvBxb/aa6E8L7tmjFtkwZBu3UXBbjIgPo/Ez4xaNg==", + "license": "MIT", + "funding": { + "type": "github", + "url": "https://github.com/sponsors/kossnocorp" + } }, "node_modules/debug": { "version": "4.4.3", @@ -6240,13 +3476,6 @@ } } }, - "node_modules/decimal.js": { - "version": "10.6.0", - "resolved": "https://registry.npmjs.org/decimal.js/-/decimal.js-10.6.0.tgz", - "integrity": "sha512-YpgQiITW3JXGntzdUmyUR1V812Hn8T1YVXhCu+wO3OpS4eU9l4YdD3qjyiKdV6mvV29zapkMeD390UVEf2lkUg==", - "dev": true, - "license": "MIT" - }, "node_modules/decimal.js-light": { "version": "2.5.1", "resolved": "https://registry.npmjs.org/decimal.js-light/-/decimal.js-light-2.5.1.tgz", @@ -6266,6 +3495,30 @@ "url": "https://github.com/sponsors/wooorm" } }, + "node_modules/decompress-response": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-6.0.0.tgz", + "integrity": "sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==", + "license": "MIT", + "dependencies": { + "mimic-response": "^3.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/deep-extend": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", + "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", + "license": "MIT", + "engines": { + "node": ">=4.0.0" + } + }, "node_modules/deep-is": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", @@ -6309,16 +3562,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/delayed-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", - "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.4.0" - } - }, "node_modules/dequal": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/dequal/-/dequal-2.0.3.tgz", @@ -6328,22 +3571,24 @@ "node": ">=6" } }, + "node_modules/detect-gpu": { + "version": "5.0.70", + "resolved": "https://registry.npmjs.org/detect-gpu/-/detect-gpu-5.0.70.tgz", + "integrity": "sha512-bqerEP1Ese6nt3rFkwPnGbsUF9a4q+gMmpTVVOEzoCyeCc+y7/RvJnQZJx1JwhgQI5Ntg0Kgat8Uu7XpBqnz1w==", + "license": "MIT", + "dependencies": { + "webgl-constants": "^1.1.1" + } + }, "node_modules/detect-libc": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz", "integrity": "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==", "license": "Apache-2.0", - "optional": true, "engines": { "node": ">=8" } }, - "node_modules/detect-node-es": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/detect-node-es/-/detect-node-es-1.1.0.tgz", - "integrity": "sha512-ypdmJU/TbBby2Dxibuv7ZLW3Bs1QEmM7nHjEANfohJLvE0XVujisn1qPJcZxg+qDucsr+bP6fLD1rPS3AhJ7EQ==", - "license": "MIT" - }, "node_modules/devlop": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/devlop/-/devlop-1.1.0.tgz", @@ -6357,20 +3602,6 @@ "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/didyoumean": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/didyoumean/-/didyoumean-1.2.2.tgz", - "integrity": "sha512-gxtyfqMg7GKyhQmb056K7M3xszy/myH8w+B4RT+QXBQsvAOdc3XymqDDPHx1BgPgsdAA5SIifona89YtRATDzw==", - "dev": true, - "license": "Apache-2.0" - }, - "node_modules/dlv": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/dlv/-/dlv-1.1.3.tgz", - "integrity": "sha512-+HlytyjlPKnIG8XuRG8WvmBP8xs8P71y+SKKS6ZXWoEgLuePxtDoUEiH7WkdePWrQ5JBpE6aoVqfZfJUQkjXwA==", - "dev": true, - "license": "MIT" - }, "node_modules/doctrine": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", @@ -6384,27 +3615,32 @@ "node": ">=0.10.0" } }, - "node_modules/dom-accessibility-api": { - "version": "0.5.16", - "resolved": "https://registry.npmjs.org/dom-accessibility-api/-/dom-accessibility-api-0.5.16.tgz", - "integrity": "sha512-X7BJ2yElsnOJ30pZF4uIIDfBEVgF4XEBxL9Bxhy6dnrm5hkzqmsWHGTiHqRiITNhMyFLyAiWndIJP7Z1NTteDg==", - "dev": true, + "node_modules/dom-helpers": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/dom-helpers/-/dom-helpers-5.2.1.tgz", + "integrity": "sha512-nRCa7CK3VTrM2NmGkIy4cbK7IZlgBE/PYMn55rrXefr5xXDP0LdtfPnblFDoVdcAfslJ7or6iqAUnx0CCGIWQA==", "license": "MIT", - "peer": true - }, - "node_modules/dotenv": { - "version": "17.2.2", - "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-17.2.2.tgz", - "integrity": "sha512-Sf2LSQP+bOlhKWWyhFsn0UsfdK/kCWRv1iuA2gXAwt3dyNabr6QSj00I2V10pidqz69soatm9ZwZvpQMTIOd5Q==", - "dev": true, - "license": "BSD-2-Clause", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://dotenvx.com" + "dependencies": { + "@babel/runtime": "^7.8.7", + "csstype": "^3.0.2" } }, + "node_modules/dompurify": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/dompurify/-/dompurify-3.2.7.tgz", + "integrity": "sha512-WhL/YuveyGXJaerVlMYGWhvQswa7myDG17P7Vu65EWC05o8vfeNbvNf4d/BOvH99+ZW+LlQsc1GDKMa1vNK6dw==", + "license": "(MPL-2.0 OR Apache-2.0)", + "peer": true, + "optionalDependencies": { + "@types/trusted-types": "^2.0.7" + } + }, + "node_modules/draco3d": { + "version": "1.5.7", + "resolved": "https://registry.npmjs.org/draco3d/-/draco3d-1.5.7.tgz", + "integrity": "sha512-m6WCKt/erDXcw+70IJXnG7M3awwQPAsZvJGX5zY7beBqpELw6RDGkYVU0W43AFxye4pDZ5i2Lbyc/NNGqwjUVQ==", + "license": "Apache-2.0" + }, "node_modules/dunder-proto": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz", @@ -6420,17 +3656,6 @@ "node": ">= 0.4" } }, - "node_modules/ecc-jsbn": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", - "integrity": "sha512-eh9O+hwRHNbG4BLTjEl3nw044CkGm5X6LoaCf7LPp7UU8Qrt47JYNi6nPX8xjW97TKGKm1ouctg0QSpZe9qrnw==", - "dev": true, - "license": "MIT", - "dependencies": { - "jsbn": "~0.1.0", - "safer-buffer": "^2.1.0" - } - }, "node_modules/electron-to-chromium": { "version": "1.5.286", "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.286.tgz", @@ -6449,37 +3674,23 @@ "version": "1.4.5", "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.5.tgz", "integrity": "sha512-ooEGc6HP26xXq/N+GCGOT0JKCLDGrq2bQUZrQ7gyrJiZANJ/8YDTxTpQBXGMn+WbIQXNVpyWymm7KYVICQnyOg==", - "dev": true, "license": "MIT", "dependencies": { "once": "^1.4.0" } }, - "node_modules/enquirer": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/enquirer/-/enquirer-2.4.1.tgz", - "integrity": "sha512-rRqJg/6gd538VHvR3PSrdRBb/1Vy2YfzHqzvbhGIQpDRKIa4FgV/54b5Q1xYSxOOwKvjXweS26E0Q+nAMwp2pQ==", + "node_modules/enhanced-resolve": { + "version": "5.19.0", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.19.0.tgz", + "integrity": "sha512-phv3E1Xl4tQOShqSte26C7Fl84EwUdZsyOuSSk9qtAGyyQs2s3jJzComh+Abf4g187lUUAvH+H26omrqia2aGg==", "dev": true, "license": "MIT", "dependencies": { - "ansi-colors": "^4.1.1", - "strip-ansi": "^6.0.1" + "graceful-fs": "^4.2.4", + "tapable": "^2.3.0" }, "engines": { - "node": ">=8.6" - } - }, - "node_modules/entities": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/entities/-/entities-6.0.1.tgz", - "integrity": "sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g==", - "dev": true, - "license": "BSD-2-Clause", - "engines": { - "node": ">=0.12" - }, - "funding": { - "url": "https://github.com/fb55/entities?sponsor=1" + "node": ">=10.13.0" } }, "node_modules/es-abstract": { @@ -6599,13 +3810,6 @@ "node": ">= 0.4" } }, - "node_modules/es-module-lexer": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.7.0.tgz", - "integrity": "sha512-jEQoCwk8hyb2AZziIOLhDqpm5+2ww5uIE6lkO/6jcOCusfk6LhMHpXXfBLXTZ7Ydyt0j4VoUQv6uGNYbdW+kBA==", - "dev": true, - "license": "MIT" - }, "node_modules/es-object-atoms": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.1.tgz", @@ -6666,58 +3870,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/es-toolkit": { - "version": "1.44.0", - "resolved": "https://registry.npmjs.org/es-toolkit/-/es-toolkit-1.44.0.tgz", - "integrity": "sha512-6penXeZalaV88MM3cGkFZZfOoLGWshWWfdy0tWw/RlVVyhvMaWSBTOvXNeiW3e5FwdS5ePW0LGEu17zT139ktg==", - "license": "MIT", - "workspaces": [ - "docs", - "benchmarks" - ] - }, - "node_modules/esbuild": { - "version": "0.27.3", - "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.27.3.tgz", - "integrity": "sha512-8VwMnyGCONIs6cWue2IdpHxHnAjzxnw2Zr7MkVxB2vjmQ2ivqGFb4LEG3SMnv0Gb2F/G/2yA8zUaiL1gywDCCg==", - "dev": true, - "hasInstallScript": true, - "license": "MIT", - "bin": { - "esbuild": "bin/esbuild" - }, - "engines": { - "node": ">=18" - }, - "optionalDependencies": { - "@esbuild/aix-ppc64": "0.27.3", - "@esbuild/android-arm": "0.27.3", - "@esbuild/android-arm64": "0.27.3", - "@esbuild/android-x64": "0.27.3", - "@esbuild/darwin-arm64": "0.27.3", - "@esbuild/darwin-x64": "0.27.3", - "@esbuild/freebsd-arm64": "0.27.3", - "@esbuild/freebsd-x64": "0.27.3", - "@esbuild/linux-arm": "0.27.3", - "@esbuild/linux-arm64": "0.27.3", - "@esbuild/linux-ia32": "0.27.3", - "@esbuild/linux-loong64": "0.27.3", - "@esbuild/linux-mips64el": "0.27.3", - "@esbuild/linux-ppc64": "0.27.3", - "@esbuild/linux-riscv64": "0.27.3", - "@esbuild/linux-s390x": "0.27.3", - "@esbuild/linux-x64": "0.27.3", - "@esbuild/netbsd-arm64": "0.27.3", - "@esbuild/netbsd-x64": "0.27.3", - "@esbuild/openbsd-arm64": "0.27.3", - "@esbuild/openbsd-x64": "0.27.3", - "@esbuild/openharmony-arm64": "0.27.3", - "@esbuild/sunos-x64": "0.27.3", - "@esbuild/win32-arm64": "0.27.3", - "@esbuild/win32-ia32": "0.27.3", - "@esbuild/win32-x64": "0.27.3" - } - }, "node_modules/escalade": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", @@ -6970,16 +4122,6 @@ "ms": "^2.1.1" } }, - "node_modules/eslint-plugin-import/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", - "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver.js" - } - }, "node_modules/eslint-plugin-jsx-a11y": { "version": "6.10.2", "resolved": "https://registry.npmjs.org/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-6.10.2.tgz", @@ -7010,16 +4152,6 @@ "eslint": "^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9" } }, - "node_modules/eslint-plugin-jsx-a11y/node_modules/aria-query": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/aria-query/-/aria-query-5.3.2.tgz", - "integrity": "sha512-COROpnaoap1E2F000S62r6A60uHZnmlvomhfyT2DlTcrY1OrBKn2UhH7qn5wTC9zMvD0AY7csdPSNwKP+7WiQw==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">= 0.4" - } - }, "node_modules/eslint-plugin-react": { "version": "7.37.5", "resolved": "https://registry.npmjs.org/eslint-plugin-react/-/eslint-plugin-react-7.37.5.tgz", @@ -7091,16 +4223,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/eslint-plugin-react/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", - "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver.js" - } - }, "node_modules/eslint-scope": { "version": "8.4.0", "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-8.4.0.tgz", @@ -7195,16 +4317,6 @@ "url": "https://opencollective.com/unified" } }, - "node_modules/estree-walker": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-3.0.3.tgz", - "integrity": "sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==", - "dev": true, - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0" - } - }, "node_modules/esutils": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", @@ -7215,64 +4327,19 @@ "node": ">=0.10.0" } }, - "node_modules/eventemitter2": { - "version": "6.4.7", - "resolved": "https://registry.npmjs.org/eventemitter2/-/eventemitter2-6.4.7.tgz", - "integrity": "sha512-tYUSVOGeQPKt/eC1ABfhHy5Xd96N3oIijJvN3O9+TsC28T5V9yX9oEfEK5faP0EFSNVOG97qtAS68GBrQB2hDg==", - "dev": true, - "license": "MIT" - }, "node_modules/eventemitter3": { - "version": "5.0.4", - "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-5.0.4.tgz", - "integrity": "sha512-mlsTRyGaPBjPedk6Bvw+aqbsXDtoAyAzm5MO7JgU+yVRyMQ5O8bD4Kcci7BS85f93veegeCPkL8R4GLClnjLFw==", + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", + "integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==", "license": "MIT" }, - "node_modules/execa": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/execa/-/execa-4.1.0.tgz", - "integrity": "sha512-j5W0//W7f8UxAn8hXVnwG8tLwdiUy4FJLcSupCg6maBYZDpyBvTApK7KyuI4bKj8KOh1r2YH+6ucuYtJv1bTZA==", - "dev": true, - "license": "MIT", - "dependencies": { - "cross-spawn": "^7.0.0", - "get-stream": "^5.0.0", - "human-signals": "^1.1.1", - "is-stream": "^2.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.0", - "onetime": "^5.1.0", - "signal-exit": "^3.0.2", - "strip-final-newline": "^2.0.0" - }, + "node_modules/expand-template": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/expand-template/-/expand-template-2.0.3.tgz", + "integrity": "sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==", + "license": "(MIT OR WTFPL)", "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" - } - }, - "node_modules/executable": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/executable/-/executable-4.1.1.tgz", - "integrity": "sha512-8iA79xD3uAch729dUG8xaaBBFGaEa0wdD2VkYLFHwlqosEj/jT66AzcreRDSgV7ehnNLBW2WR5jIXwGKjVdTLg==", - "dev": true, - "license": "MIT", - "dependencies": { - "pify": "^2.2.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/expect-type": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/expect-type/-/expect-type-1.3.0.tgz", - "integrity": "sha512-knvyeauYhqjOYvQ66MznSMs83wmHrCycNEN6Ao+2AeYEfxUIkuiVxdEa1qlGEPK+We3n0THiDciYSsCcgW/DoA==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=12.0.0" + "node": ">=6" } }, "node_modules/extend": { @@ -7281,37 +4348,6 @@ "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==", "license": "MIT" }, - "node_modules/extract-zip": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/extract-zip/-/extract-zip-2.0.1.tgz", - "integrity": "sha512-GDhU9ntwuKyGXdZBUgTIe+vXnWj0fppUEtMDL0+idd5Sta8TGpHssn/eusA9mrPr9qNDym6SxAYZjNvCn/9RBg==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "debug": "^4.1.1", - "get-stream": "^5.1.0", - "yauzl": "^2.10.0" - }, - "bin": { - "extract-zip": "cli.js" - }, - "engines": { - "node": ">= 10.17.0" - }, - "optionalDependencies": { - "@types/yauzl": "^2.9.1" - } - }, - "node_modules/extsprintf": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", - "integrity": "sha512-11Ndz7Nv+mvAC1j0ktTa7fAb0vLyGGX+rMHNBYQviQDGU0Hw7lhctJANqbPhu9nV9/izT/IntTgZ7Im/9LJs9g==", - "dev": true, - "engines": [ - "node >=0.6.0" - ], - "license": "MIT" - }, "node_modules/fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", @@ -7319,6 +4355,15 @@ "dev": true, "license": "MIT" }, + "node_modules/fast-equals": { + "version": "5.4.0", + "resolved": "https://registry.npmjs.org/fast-equals/-/fast-equals-5.4.0.tgz", + "integrity": "sha512-jt2DW/aNFNwke7AUd+Z+e6pz39KO5rzdbbFCg2sGafS4mk13MI7Z8O5z9cADNn5lhGODIgLwug6TZO2ctf7kcw==", + "license": "MIT", + "engines": { + "node": ">=6.0.0" + } + }, "node_modules/fast-glob": { "version": "3.3.1", "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.1.tgz", @@ -7363,29 +4408,6 @@ "dev": true, "license": "MIT" }, - "node_modules/fast-sha256": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/fast-sha256/-/fast-sha256-1.3.0.tgz", - "integrity": "sha512-n11RGP/lrWEFI/bWdygLxhI+pVeo1ZYIVwvvPkW7azl/rOy+F3HYRZ2K5zeE9mmkhQppyv9sQFx0JM9UabnpPQ==", - "license": "Unlicense" - }, - "node_modules/fast-uri": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.1.0.tgz", - "integrity": "sha512-iPeeDKJSWf4IEOasVVrknXpaBV0IApz/gp7S2bb7Z4Lljbl2MGJRqInZiUrQwV16cpzw/D3S5j5Julj/gT52AA==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/fastify" - }, - { - "type": "opencollective", - "url": "https://opencollective.com/fastify" - } - ], - "license": "BSD-3-Clause" - }, "node_modules/fastq": { "version": "1.20.1", "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.20.1.tgz", @@ -7396,41 +4418,11 @@ "reusify": "^1.0.4" } }, - "node_modules/fd-slicer": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/fd-slicer/-/fd-slicer-1.1.0.tgz", - "integrity": "sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g==", - "dev": true, - "license": "MIT", - "dependencies": { - "pend": "~1.2.0" - } - }, - "node_modules/figures": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz", - "integrity": "sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==", - "dev": true, - "license": "MIT", - "dependencies": { - "escape-string-regexp": "^1.0.5" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/figures/node_modules/escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.8.0" - } + "node_modules/fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==", + "license": "MIT" }, "node_modules/file-entry-cache": { "version": "8.0.0", @@ -7445,6 +4437,12 @@ "node": ">=16.0.0" } }, + "node_modules/file-uri-to-path": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", + "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==", + "license": "MIT" + }, "node_modules/fill-range": { "version": "7.1.1", "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", @@ -7490,9 +4488,9 @@ } }, "node_modules/flatted": { - "version": "3.4.2", - "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.4.2.tgz", - "integrity": "sha512-PjDse7RzhcPkIJwy5t7KPWQSZ9cAbzQXcafsetQoD7sOJRQlGikNbx7yZp2OotDnJyrDcbyRq3Ttb18iYOqkxA==", + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.3.3.tgz", + "integrity": "sha512-GX+ysw4PBCz0PzosHDepZGANEuFCMLrnRTiEy9McGjmkCQYwRq4A/X786G/fjM/+OjsWSU1ZrY5qyARZmO/uwg==", "dev": true, "license": "ISC" }, @@ -7512,77 +4510,11 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/forever-agent": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", - "integrity": "sha512-j0KLYPhm6zeac4lz3oJ3o65qvgQCcPubiyotZrXqEaG4hNagNYO8qdlUrX5vwqv9ohqeT/Z3j6+yW067yWWdUw==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "*" - } - }, - "node_modules/form-data": { - "version": "4.0.5", - "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.5.tgz", - "integrity": "sha512-8RipRLol37bNs2bhoV67fiTEvdTrbMUYcFTiy3+wuuOnUog2QBHCZWXDRijWQfAkhBj2Uf5UnVaiWwA5vdd82w==", - "dev": true, - "license": "MIT", - "dependencies": { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.8", - "es-set-tostringtag": "^2.1.0", - "hasown": "^2.0.2", - "mime-types": "^2.1.12" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/fraction.js": { - "version": "5.3.4", - "resolved": "https://registry.npmjs.org/fraction.js/-/fraction.js-5.3.4.tgz", - "integrity": "sha512-1X1NTtiJphryn/uLQz3whtY6jK3fTqoE3ohKs0tT+Ujr1W59oopxmoEh7Lu5p6vBaPbgoM0bzveAW4Qi5RyWDQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": "*" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/rawify" - } - }, - "node_modules/fs-extra": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", - "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "at-least-node": "^1.0.0", - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/fsevents": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", - "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", - "dev": true, - "hasInstallScript": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": "^8.16.0 || ^10.6.0 || >=11.0.0" - } + "node_modules/fs-constants": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs-constants/-/fs-constants-1.0.0.tgz", + "integrity": "sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==", + "license": "MIT" }, "node_modules/function-bind": { "version": "1.1.2", @@ -7670,15 +4602,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/get-nonce": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/get-nonce/-/get-nonce-1.0.1.tgz", - "integrity": "sha512-FJhYRoDaiatfEkUK8HKlicmu/3SGFD51q3itKDGoSTysQJBnfOcxU5GxnhE1E6soB76MbT0MBtnKJuXyAx+96Q==", - "license": "MIT", - "engines": { - "node": ">=6" - } - }, "node_modules/get-proto": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz", @@ -7693,22 +4616,6 @@ "node": ">= 0.4" } }, - "node_modules/get-stream": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", - "integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==", - "dev": true, - "license": "MIT", - "dependencies": { - "pump": "^3.0.0" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/get-symbol-description": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.1.0.tgz", @@ -7740,25 +4647,11 @@ "url": "https://github.com/privatenumber/get-tsconfig?sponsor=1" } }, - "node_modules/getos": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/getos/-/getos-3.2.1.tgz", - "integrity": "sha512-U56CfOK17OKgTVqozZjUKNdkfEv6jk5WISBJ8SHoagjE6L69zOwl3Z+O8myjY9MEW3i2HPWQBt/LTbCgcC973Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "async": "^3.2.0" - } - }, - "node_modules/getpass": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", - "integrity": "sha512-0fzj9JxOLfJ+XGLhR8ze3unN0KZCgZwiSSDz168VERjK8Wl8kVSdcu2kspd4s4wtAa1y/qrVRiAA0WclVsu0ng==", - "dev": true, - "license": "MIT", - "dependencies": { - "assert-plus": "^1.0.0" - } + "node_modules/github-from-package": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/github-from-package/-/github-from-package-0.0.0.tgz", + "integrity": "sha512-SyHy3T1v2NUXn29OsWdxmK6RwHD+vkj3v8en8AOBZ1wBQ/hCAQ5bAQTD02kW4W9tUp/3Qh6J8r9EvntiyCmOOw==", + "license": "MIT" }, "node_modules/glob-parent": { "version": "6.0.2", @@ -7773,28 +4666,6 @@ "node": ">=10.13.0" } }, - "node_modules/glob-to-regexp": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz", - "integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==", - "license": "BSD-2-Clause" - }, - "node_modules/global-dirs": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/global-dirs/-/global-dirs-3.0.1.tgz", - "integrity": "sha512-NBcGGFbBA9s1VzD41QXDG+3++t9Mn5t1FpLdhESY6oKY4gYTFpX4wO3sqGUa0Srjtbfj3szX0RnemmrVRUdULA==", - "dev": true, - "license": "MIT", - "dependencies": { - "ini": "2.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/globals": { "version": "14.0.0", "resolved": "https://registry.npmjs.org/globals/-/globals-14.0.0.tgz", @@ -7825,79 +4696,11 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/globby": { - "version": "16.1.0", - "resolved": "https://registry.npmjs.org/globby/-/globby-16.1.0.tgz", - "integrity": "sha512-+A4Hq7m7Ze592k9gZRy4gJ27DrXRNnC1vPjxTt1qQxEY8RxagBkBxivkCwg7FxSTG0iLLEMaUx13oOr0R2/qcQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@sindresorhus/merge-streams": "^4.0.0", - "fast-glob": "^3.3.3", - "ignore": "^7.0.5", - "is-path-inside": "^4.0.0", - "slash": "^5.1.0", - "unicorn-magic": "^0.4.0" - }, - "engines": { - "node": ">=20" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/globby/node_modules/fast-glob": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.3.tgz", - "integrity": "sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@nodelib/fs.stat": "^2.0.2", - "@nodelib/fs.walk": "^1.2.3", - "glob-parent": "^5.1.2", - "merge2": "^1.3.0", - "micromatch": "^4.0.8" - }, - "engines": { - "node": ">=8.6.0" - } - }, - "node_modules/globby/node_modules/glob-parent": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", - "dev": true, - "license": "ISC", - "dependencies": { - "is-glob": "^4.0.1" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/globby/node_modules/ignore": { - "version": "7.0.5", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.5.tgz", - "integrity": "sha512-Hs59xBNfUIunMFgWAbGX5cq6893IbWg4KnrjbYwX3tx0ztorVgTDA6B2sxf8ejHJ4wz8BqGUMYlnzNBer5NvGg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 4" - } - }, - "node_modules/globby/node_modules/is-path-inside": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-4.0.0.tgz", - "integrity": "sha512-lJJV/5dYS+RcL8uQdBDW9c9uWFLLBNRyFhnAKXw5tVqLlKZ4RMGZKv+YQ/IA3OhD+RpbJa1LLFM1FQPGyIXvOA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } + "node_modules/glsl-noise": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/glsl-noise/-/glsl-noise-0.0.0.tgz", + "integrity": "sha512-b/ZCF6amfAUb7dJM/MxRs7AetQEahYzJ8PtgfrmEdtw6uyGOr+ZSGtgjFm6mfsBkxJ4d2W7kg+Nlqzqvn3Bc0w==", + "license": "MIT" }, "node_modules/gopd": { "version": "1.2.0", @@ -8000,23 +4803,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/hasha": { - "version": "5.2.2", - "resolved": "https://registry.npmjs.org/hasha/-/hasha-5.2.2.tgz", - "integrity": "sha512-Hrp5vIK/xr5SkeN2onO32H0MgNZ0f17HRNH39WfL0SYUNOTZ5Lz1TJ8Pajo/87dYGEFlLMm7mIc/k/s6Bvz9HQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "is-stream": "^2.0.0", - "type-fest": "^0.8.0" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/hasown": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", @@ -8087,25 +4873,11 @@ "hermes-estree": "0.25.1" } }, - "node_modules/html-encoding-sniffer": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/html-encoding-sniffer/-/html-encoding-sniffer-4.0.0.tgz", - "integrity": "sha512-Y22oTqIU4uuPgEemfz7NDJz6OeKf12Lsu+QC+s3BVpda64lTiMYCyGwg5ki4vFxkMwQdeZDl2adZoqUgdFuTgQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "whatwg-encoding": "^3.1.1" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/html-escaper": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-2.0.2.tgz", - "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", - "dev": true, - "license": "MIT" + "node_modules/hls.js": { + "version": "1.6.15", + "resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.6.15.tgz", + "integrity": "sha512-E3a5VwgXimGHwpRGV+WxRTKeSp2DW5DI5MWv34ulL3t5UNmyJWCQ1KmLEHbYzcfThfXG8amBL+fCYPneGHC4VA==", + "license": "Apache-2.0" }, "node_modules/html-url-attributes": { "version": "3.0.1", @@ -8117,77 +4889,10 @@ "url": "https://opencollective.com/unified" } }, - "node_modules/http-proxy-agent": { - "version": "7.0.2", - "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz", - "integrity": "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==", - "dev": true, - "license": "MIT", - "dependencies": { - "agent-base": "^7.1.0", - "debug": "^4.3.4" - }, - "engines": { - "node": ">= 14" - } - }, - "node_modules/http-signature": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.4.0.tgz", - "integrity": "sha512-G5akfn7eKbpDN+8nPS/cb57YeA1jLTVxjpCj7tmm3QKPdyDy7T+qSC40e9ptydSWvkwjSXw1VbkpyEm39ukeAg==", - "dev": true, - "license": "MIT", - "dependencies": { - "assert-plus": "^1.0.0", - "jsprim": "^2.0.2", - "sshpk": "^1.18.0" - }, - "engines": { - "node": ">=0.10" - } - }, - "node_modules/https-proxy-agent": { - "version": "7.0.6", - "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", - "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", - "dev": true, - "license": "MIT", - "dependencies": { - "agent-base": "^7.1.2", - "debug": "4" - }, - "engines": { - "node": ">= 14" - } - }, - "node_modules/human-signals": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-1.1.1.tgz", - "integrity": "sha512-SEQu7vl8KjNL2eoGBLF3+wAjpsNfA9XMlXAYj/3EdaNfAlxKthD1xjEQfGOUhllCGGJVNY34bRr6lPINhNjyZw==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=8.12.0" - } - }, - "node_modules/iconv-lite": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", - "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", - "dev": true, - "license": "MIT", - "dependencies": { - "safer-buffer": ">= 2.1.2 < 3.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/ieee754": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", - "dev": true, "funding": [ { "type": "github", @@ -8214,15 +4919,11 @@ "node": ">= 4" } }, - "node_modules/immer": { - "version": "10.2.0", - "resolved": "https://registry.npmjs.org/immer/-/immer-10.2.0.tgz", - "integrity": "sha512-d/+XTN3zfODyjr89gM3mPq1WNX2B8pYsu7eORitdwyA2sBubnTl3laYlBk4sXY5FUa5qTZGBDPJICVbvqzjlbw==", - "license": "MIT", - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/immer" - } + "node_modules/immediate": { + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/immediate/-/immediate-3.0.6.tgz", + "integrity": "sha512-XXOFtyqDjNDAQxVfYxuF7g9Il/IbWmmlQg2MYKOH8ExIT1qg6xc4zyS3HaEEATgs1btfzxq15ciUiY7gjSXRGQ==", + "license": "MIT" }, "node_modules/import-fresh": { "version": "3.3.1", @@ -8251,25 +4952,17 @@ "node": ">=0.8.19" } }, - "node_modules/indent-string": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz", - "integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "license": "ISC" }, "node_modules/ini": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ini/-/ini-2.0.0.tgz", - "integrity": "sha512-7PnF4oN3CvZF23ADhA5wRaYEQpJ8qygSkbtTXWBeXWXmEVRXK+1ITciHWwHhsjv1TmW0MgacIv6hEi5pX5NQdA==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">=10" - } + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", + "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", + "license": "ISC" }, "node_modules/inline-style-parser": { "version": "0.2.7", @@ -8379,19 +5072,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-binary-path": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", - "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", - "dev": true, - "license": "MIT", - "dependencies": { - "binary-extensions": "^2.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/is-boolean-object": { "version": "1.2.2", "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.2.2.tgz", @@ -8419,6 +5099,19 @@ "semver": "^7.7.1" } }, + "node_modules/is-bun-module/node_modules/semver": { + "version": "7.7.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.4.tgz", + "integrity": "sha512-vFKC2IEtQnVhpT78h1Yp8wzwrf8CM+MzKMHGJZfBtzhZNycRFnXsHk6E5TxIkkMsgNS7mdX3AGB7x2QM2di4lA==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/is-callable": { "version": "1.2.7", "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", @@ -8519,16 +5212,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, "node_modules/is-generator-function": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/is-generator-function/-/is-generator-function-1.1.2.tgz", @@ -8572,23 +5255,6 @@ "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/is-installed-globally": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/is-installed-globally/-/is-installed-globally-0.4.0.tgz", - "integrity": "sha512-iwGqO3J21aaSkC7jWnHP/difazwS7SFeIqxv6wEtLU8Y5KlzFTjyqcSIT0d8s4+dDhKytsk9PJZ2BkS5eZwQRQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "global-dirs": "^3.0.0", - "is-path-inside": "^3.0.2" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/is-map": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.3.tgz", @@ -8642,16 +5308,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-path-inside": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", - "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, "node_modules/is-plain-obj": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-4.1.0.tgz", @@ -8664,11 +5320,10 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/is-potential-custom-element-name": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz", - "integrity": "sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ==", - "dev": true, + "node_modules/is-promise": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-2.2.2.tgz", + "integrity": "sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ==", "license": "MIT" }, "node_modules/is-regex": { @@ -8719,19 +5374,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-stream": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", - "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/is-string": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.1.1.tgz", @@ -8783,26 +5425,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-typedarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", - "integrity": "sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA==", - "dev": true, - "license": "MIT" - }, - "node_modules/is-unicode-supported": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz", - "integrity": "sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/is-weakmap": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.2.tgz", @@ -8860,68 +5482,8 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", - "dev": true, "license": "ISC" }, - "node_modules/isstream": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", - "integrity": "sha512-Yljz7ffyPbrLpLngrMtZ7NduUgVvi6wG9RJ9IUcyCd59YQ911PBJphODUcbOVbqYfxe1wuYf/LJ8PauMRwsM/g==", - "dev": true, - "license": "MIT" - }, - "node_modules/istanbul-lib-coverage": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.2.tgz", - "integrity": "sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg==", - "dev": true, - "license": "BSD-3-Clause", - "engines": { - "node": ">=8" - } - }, - "node_modules/istanbul-lib-report": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-3.0.1.tgz", - "integrity": "sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "istanbul-lib-coverage": "^3.0.0", - "make-dir": "^4.0.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/istanbul-lib-report/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "license": "MIT", - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/istanbul-reports": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-3.2.0.tgz", - "integrity": "sha512-HGYWWS/ehqTV3xN10i23tkPkpH46MLCIMFNCaaKNavAXTF1RkqxawEPtnjnGZ6XKSInBKkiOA5BKS+aZiY3AvA==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "html-escaper": "^2.0.0", - "istanbul-lib-report": "^3.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/iterator.prototype": { "version": "1.1.5", "resolved": "https://registry.npmjs.org/iterator.prototype/-/iterator.prototype-1.1.5.tgz", @@ -8940,6 +5502,18 @@ "node": ">= 0.4" } }, + "node_modules/its-fine": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/its-fine/-/its-fine-2.0.0.tgz", + "integrity": "sha512-KLViCmWx94zOvpLwSlsx6yOCeMhZYaxrJV87Po5k/FoZzcPSahvK5qJ7fYhS61sZi5ikmh2S3Hz55A2l3U69ng==", + "license": "MIT", + "dependencies": { + "@types/react-reconciler": "^0.28.9" + }, + "peerDependencies": { + "react": "^19.0.0" + } + }, "node_modules/jiti": { "version": "2.6.1", "resolved": "https://registry.npmjs.org/jiti/-/jiti-2.6.1.tgz", @@ -8950,20 +5524,10 @@ "jiti": "lib/jiti-cli.mjs" } }, - "node_modules/js-cookie": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/js-cookie/-/js-cookie-3.0.5.tgz", - "integrity": "sha512-cEiJEAEoIbWfCZYKWhVwFuvPX1gETRYPw6LlaTKoxD3s2AkXzkCjnp6h0V77ozyqj0jakteJ4YqDJT830+lVGw==", - "license": "MIT", - "engines": { - "node": ">=14" - } - }, "node_modules/js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true, "license": "MIT" }, "node_modules/js-yaml": { @@ -8979,54 +5543,6 @@ "js-yaml": "bin/js-yaml.js" } }, - "node_modules/jsbn": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", - "integrity": "sha512-UVU9dibq2JcFWxQPA6KCqj5O42VOmAY3zQUfEKxU0KpTGXwNoCjkX1e13eHNvw/xPynt6pU0rZ1htjWTNTSXsg==", - "dev": true, - "license": "MIT" - }, - "node_modules/jsdom": { - "version": "25.0.1", - "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-25.0.1.tgz", - "integrity": "sha512-8i7LzZj7BF8uplX+ZyOlIz86V6TAsSs+np6m1kpW9u0JWi4z/1t+FzcK1aek+ybTnAC4KhBL4uXCNT0wcUIeCw==", - "dev": true, - "license": "MIT", - "dependencies": { - "cssstyle": "^4.1.0", - "data-urls": "^5.0.0", - "decimal.js": "^10.4.3", - "form-data": "^4.0.0", - "html-encoding-sniffer": "^4.0.0", - "http-proxy-agent": "^7.0.2", - "https-proxy-agent": "^7.0.5", - "is-potential-custom-element-name": "^1.0.1", - "nwsapi": "^2.2.12", - "parse5": "^7.1.2", - "rrweb-cssom": "^0.7.1", - "saxes": "^6.0.0", - "symbol-tree": "^3.2.4", - "tough-cookie": "^5.0.0", - "w3c-xmlserializer": "^5.0.0", - "webidl-conversions": "^7.0.0", - "whatwg-encoding": "^3.1.1", - "whatwg-mimetype": "^4.0.0", - "whatwg-url": "^14.0.0", - "ws": "^8.18.0", - "xml-name-validator": "^5.0.0" - }, - "engines": { - "node": ">=18" - }, - "peerDependencies": { - "canvas": "^2.11.2" - }, - "peerDependenciesMeta": { - "canvas": { - "optional": true - } - } - }, "node_modules/jsesc": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-3.1.0.tgz", @@ -9047,13 +5563,6 @@ "dev": true, "license": "MIT" }, - "node_modules/json-schema": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.4.0.tgz", - "integrity": "sha512-es94M3nTIfsEPisRafak+HDLfHXnKBhV3vU5eqPcS3flIWqcxJWgXHXiey3YrpaNsanY5ei1VoYEbOzijuq9BA==", - "dev": true, - "license": "(AFL-2.1 OR BSD-3-Clause)" - }, "node_modules/json-schema-traverse": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", @@ -9068,13 +5577,6 @@ "dev": true, "license": "MIT" }, - "node_modules/json-stringify-safe": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", - "integrity": "sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA==", - "dev": true, - "license": "ISC" - }, "node_modules/json5": { "version": "2.2.3", "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", @@ -9088,45 +5590,6 @@ "node": ">=6" } }, - "node_modules/jsonfile": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.2.0.tgz", - "integrity": "sha512-FGuPw30AdOIUTRMC2OMRtQV+jkVj2cfPqSeWXv1NEAJ1qZ5zb1X6z1mFhbfOB/iy3ssJCD+3KuZ8r8C3uVFlAg==", - "dev": true, - "license": "MIT", - "dependencies": { - "universalify": "^2.0.0" - }, - "optionalDependencies": { - "graceful-fs": "^4.1.6" - } - }, - "node_modules/jsonpointer": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/jsonpointer/-/jsonpointer-5.0.1.tgz", - "integrity": "sha512-p/nXbhSEcu3pZRdkW1OfJhpsVtW1gd4Wa1fnQc9YLiTfAjn0312eMKimbdIQzuZl9aa9xUGaRlP9T/CJE/ditQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/jsprim": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-2.0.2.tgz", - "integrity": "sha512-gqXddjPqQ6G40VdnI6T6yObEC+pDNvyP95wdQhkWkg7crHH3km5qP1FsOXEkzEQwnz6gz5qGTn1c2Y52wP3OyQ==", - "dev": true, - "engines": [ - "node >=0.6.0" - ], - "license": "MIT", - "dependencies": { - "assert-plus": "1.0.0", - "extsprintf": "1.3.0", - "json-schema": "0.4.0", - "verror": "1.10.0" - } - }, "node_modules/jsx-ast-utils": { "version": "3.3.5", "resolved": "https://registry.npmjs.org/jsx-ast-utils/-/jsx-ast-utils-3.3.5.tgz", @@ -9173,29 +5636,6 @@ "node": ">=0.10" } }, - "node_modules/lazy-ass": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/lazy-ass/-/lazy-ass-1.6.0.tgz", - "integrity": "sha512-cc8oEVoctTvsFZ/Oje/kGnHbpWHYBe8IAJe4C0QNc3t8uM/0Y8+erSz/7Y1ALuXTEZTMvxXwO6YbX1ey3ujiZw==", - "dev": true, - "license": "MIT", - "engines": { - "node": "> 0.8" - } - }, - "node_modules/leven": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/leven/-/leven-4.1.0.tgz", - "integrity": "sha512-KZ9W9nWDT7rF7Dazg8xyLHGLrmpgq2nVNFUckhqdW3szVP6YhCpp/RAnpmVExA9JvrMynjwSLVrEj3AepHR6ew==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/levn": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", @@ -9210,62 +5650,274 @@ "node": ">= 0.8.0" } }, - "node_modules/lilconfig": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/lilconfig/-/lilconfig-3.1.3.tgz", - "integrity": "sha512-/vlFKAoH5Cgt3Ie+JLhRbwOsCQePABiU3tJ1egGvyQ+33R/vcwM2Zl2QR/LzjsBeItPt3oSVXapn+m4nQDvpzw==", - "dev": true, + "node_modules/lie": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/lie/-/lie-3.3.0.tgz", + "integrity": "sha512-UaiMJzeWRlEujzAuw5LokY1L5ecNQYZKfmyZ9L7wDHb/p5etKaxXhohBcrw0EYby+G/NA52vRSN4N39dxHAIwQ==", "license": "MIT", + "dependencies": { + "immediate": "~3.0.5" + } + }, + "node_modules/lightningcss": { + "version": "1.30.2", + "resolved": "https://registry.npmjs.org/lightningcss/-/lightningcss-1.30.2.tgz", + "integrity": "sha512-utfs7Pr5uJyyvDETitgsaqSyjCb2qNRAtuqUeWIAKztsOYdcACf2KtARYXg2pSvhkt+9NfoaNY7fxjl6nuMjIQ==", + "dev": true, + "license": "MPL-2.0", + "dependencies": { + "detect-libc": "^2.0.3" + }, "engines": { - "node": ">=14" + "node": ">= 12.0.0" }, "funding": { - "url": "https://github.com/sponsors/antonk52" - } - }, - "node_modules/lines-and-columns": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", - "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==", - "dev": true, - "license": "MIT" - }, - "node_modules/linkify-it": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/linkify-it/-/linkify-it-5.0.0.tgz", - "integrity": "sha512-5aHCbzQRADcdP+ATqnDuhhJ/MRIqDkZX5pyjFHRRysS8vZ5AbqGEoFIb6pYHPZ+L/OC2Lc+xT8uHVVR5CAK/wQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "uc.micro": "^2.0.0" - } - }, - "node_modules/listr2": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/listr2/-/listr2-3.14.0.tgz", - "integrity": "sha512-TyWI8G99GX9GjE54cJ+RrNMcIFBfwMPxc3XTFiAYGN4s10hWROGtOg7+O6u6LE3mNkyld7RSLE6nrKBvTfcs3g==", - "dev": true, - "license": "MIT", - "dependencies": { - "cli-truncate": "^2.1.0", - "colorette": "^2.0.16", - "log-update": "^4.0.0", - "p-map": "^4.0.0", - "rfdc": "^1.3.0", - "rxjs": "^7.5.1", - "through": "^2.3.8", - "wrap-ansi": "^7.0.0" + "type": "opencollective", + "url": "https://opencollective.com/parcel" }, + "optionalDependencies": { + "lightningcss-android-arm64": "1.30.2", + "lightningcss-darwin-arm64": "1.30.2", + "lightningcss-darwin-x64": "1.30.2", + "lightningcss-freebsd-x64": "1.30.2", + "lightningcss-linux-arm-gnueabihf": "1.30.2", + "lightningcss-linux-arm64-gnu": "1.30.2", + "lightningcss-linux-arm64-musl": "1.30.2", + "lightningcss-linux-x64-gnu": "1.30.2", + "lightningcss-linux-x64-musl": "1.30.2", + "lightningcss-win32-arm64-msvc": "1.30.2", + "lightningcss-win32-x64-msvc": "1.30.2" + } + }, + "node_modules/lightningcss-android-arm64": { + "version": "1.30.2", + "resolved": "https://registry.npmjs.org/lightningcss-android-arm64/-/lightningcss-android-arm64-1.30.2.tgz", + "integrity": "sha512-BH9sEdOCahSgmkVhBLeU7Hc9DWeZ1Eb6wNS6Da8igvUwAe0sqROHddIlvU06q3WyXVEOYDZ6ykBZQnjTbmo4+A==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "android" + ], "engines": { - "node": ">=10.0.0" + "node": ">= 12.0.0" }, - "peerDependencies": { - "enquirer": ">= 2.3.0 < 3" + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-darwin-arm64": { + "version": "1.30.2", + "resolved": "https://registry.npmjs.org/lightningcss-darwin-arm64/-/lightningcss-darwin-arm64-1.30.2.tgz", + "integrity": "sha512-ylTcDJBN3Hp21TdhRT5zBOIi73P6/W0qwvlFEk22fkdXchtNTOU4Qc37SkzV+EKYxLouZ6M4LG9NfZ1qkhhBWA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 12.0.0" }, - "peerDependenciesMeta": { - "enquirer": { - "optional": true - } + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-darwin-x64": { + "version": "1.30.2", + "resolved": "https://registry.npmjs.org/lightningcss-darwin-x64/-/lightningcss-darwin-x64-1.30.2.tgz", + "integrity": "sha512-oBZgKchomuDYxr7ilwLcyms6BCyLn0z8J0+ZZmfpjwg9fRVZIR5/GMXd7r9RH94iDhld3UmSjBM6nXWM2TfZTQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-freebsd-x64": { + "version": "1.30.2", + "resolved": "https://registry.npmjs.org/lightningcss-freebsd-x64/-/lightningcss-freebsd-x64-1.30.2.tgz", + "integrity": "sha512-c2bH6xTrf4BDpK8MoGG4Bd6zAMZDAXS569UxCAGcA7IKbHNMlhGQ89eRmvpIUGfKWNVdbhSbkQaWhEoMGmGslA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-arm-gnueabihf": { + "version": "1.30.2", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm-gnueabihf/-/lightningcss-linux-arm-gnueabihf-1.30.2.tgz", + "integrity": "sha512-eVdpxh4wYcm0PofJIZVuYuLiqBIakQ9uFZmipf6LF/HRj5Bgm0eb3qL/mr1smyXIS1twwOxNWndd8z0E374hiA==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-arm64-gnu": { + "version": "1.30.2", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-gnu/-/lightningcss-linux-arm64-gnu-1.30.2.tgz", + "integrity": "sha512-UK65WJAbwIJbiBFXpxrbTNArtfuznvxAJw4Q2ZGlU8kPeDIWEX1dg3rn2veBVUylA2Ezg89ktszWbaQnxD/e3A==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-arm64-musl": { + "version": "1.30.2", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-musl/-/lightningcss-linux-arm64-musl-1.30.2.tgz", + "integrity": "sha512-5Vh9dGeblpTxWHpOx8iauV02popZDsCYMPIgiuw97OJ5uaDsL86cnqSFs5LZkG3ghHoX5isLgWzMs+eD1YzrnA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-x64-gnu": { + "version": "1.30.2", + "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-gnu/-/lightningcss-linux-x64-gnu-1.30.2.tgz", + "integrity": "sha512-Cfd46gdmj1vQ+lR6VRTTadNHu6ALuw2pKR9lYq4FnhvgBc4zWY1EtZcAc6EffShbb1MFrIPfLDXD6Xprbnni4w==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-x64-musl": { + "version": "1.30.2", + "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-musl/-/lightningcss-linux-x64-musl-1.30.2.tgz", + "integrity": "sha512-XJaLUUFXb6/QG2lGIW6aIk6jKdtjtcffUT0NKvIqhSBY3hh9Ch+1LCeH80dR9q9LBjG3ewbDjnumefsLsP6aiA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-win32-arm64-msvc": { + "version": "1.30.2", + "resolved": "https://registry.npmjs.org/lightningcss-win32-arm64-msvc/-/lightningcss-win32-arm64-msvc-1.30.2.tgz", + "integrity": "sha512-FZn+vaj7zLv//D/192WFFVA0RgHawIcHqLX9xuWiQt7P0PtdFEVaxgF9rjM/IRYHQXNnk61/H/gb2Ei+kUQ4xQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-win32-x64-msvc": { + "version": "1.30.2", + "resolved": "https://registry.npmjs.org/lightningcss-win32-x64-msvc/-/lightningcss-win32-x64-msvc-1.30.2.tgz", + "integrity": "sha512-5g1yc73p+iAkid5phb4oVFMB45417DkRevRbt/El/gKXJk4jid+vPFF/AXbxn05Aky8PapwzZrdJShv5C0avjw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" } }, "node_modules/locate-path": { @@ -9288,7 +5940,6 @@ "version": "4.17.23", "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.23.tgz", "integrity": "sha512-LgVTMpQtIopCi79SJeDiP0TfWi5CNEc/L/aRdTh3yIvmZXTnheWpKjSZhnvMl8iXbC1tFg9gdHHDMLoV7CnG+w==", - "dev": true, "license": "MIT" }, "node_modules/lodash.merge": { @@ -9298,82 +5949,6 @@ "dev": true, "license": "MIT" }, - "node_modules/lodash.once": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/lodash.once/-/lodash.once-4.1.1.tgz", - "integrity": "sha512-Sb487aTOCr9drQVL8pIxOzVhafOjZN9UU54hiN8PU3uAiSV7lx1yYNpbNmex2PK6dSJoNTSJUUswT651yww3Mg==", - "dev": true, - "license": "MIT" - }, - "node_modules/log-symbols": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", - "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", - "dev": true, - "license": "MIT", - "dependencies": { - "chalk": "^4.1.0", - "is-unicode-supported": "^0.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/log-update": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/log-update/-/log-update-4.0.0.tgz", - "integrity": "sha512-9fkkDevMefjg0mmzWFBW8YkFP91OrizzkW3diF7CpG+S2EYdy4+TVfGwz1zeF8x7hCx1ovSPTOE9Ngib74qqUg==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-escapes": "^4.3.0", - "cli-cursor": "^3.1.0", - "slice-ansi": "^4.0.0", - "wrap-ansi": "^6.2.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/log-update/node_modules/slice-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-4.0.0.tgz", - "integrity": "sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.0.0", - "astral-regex": "^2.0.0", - "is-fullwidth-code-point": "^3.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/slice-ansi?sponsor=1" - } - }, - "node_modules/log-update/node_modules/wrap-ansi": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", - "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/longest-streak": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/longest-streak/-/longest-streak-3.1.0.tgz", @@ -9388,7 +5963,6 @@ "version": "1.4.0", "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", - "dev": true, "license": "MIT", "dependencies": { "js-tokens": "^3.0.0 || ^4.0.0" @@ -9411,28 +5985,19 @@ "version": "0.563.0", "resolved": "https://registry.npmjs.org/lucide-react/-/lucide-react-0.563.0.tgz", "integrity": "sha512-8dXPB2GI4dI8jV4MgUDGBeLdGk8ekfqVZ0BdLcrRzocGgG75ltNEmWS+gE7uokKF/0oSUuczNDT+g9hFJ23FkA==", - "dev": true, "license": "ISC", "peerDependencies": { "react": "^16.5.1 || ^17.0.0 || ^18.0.0 || ^19.0.0" } }, - "node_modules/lunr": { - "version": "2.3.9", - "resolved": "https://registry.npmjs.org/lunr/-/lunr-2.3.9.tgz", - "integrity": "sha512-zTU3DaZaF3Rt9rhN3uBMGQD3dD2/vFQqnvZCDv4dl5iOzq2IZQqTxu90r4E5J+nP70J3ilqVCrbho2eWaeW8Ow==", - "dev": true, - "license": "MIT" - }, - "node_modules/lz-string": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/lz-string/-/lz-string-1.5.0.tgz", - "integrity": "sha512-h5bgJWpxJNswbU7qCrV0tIKQCaS3blPDrqKWx+QxzuzL1zGUzij9XCWLrSLsJPu5t+eWA/ycetzYAO5IOMcWAQ==", - "dev": true, + "node_modules/maath": { + "version": "0.10.8", + "resolved": "https://registry.npmjs.org/maath/-/maath-0.10.8.tgz", + "integrity": "sha512-tRvbDF0Pgqz+9XUa4jjfgAQ8/aPKmQdWXilFu2tMy4GWj4NOsx99HlULO4IeREfbO3a0sA145DZYyvXPkybm0g==", "license": "MIT", - "peer": true, - "bin": { - "lz-string": "bin/bin.js" + "peerDependencies": { + "@types/three": ">=0.134.0", + "three": ">=0.134.0" } }, "node_modules/magic-string": { @@ -9445,73 +6010,17 @@ "@jridgewell/sourcemap-codec": "^1.5.5" } }, - "node_modules/magicast": { - "version": "0.5.2", - "resolved": "https://registry.npmjs.org/magicast/-/magicast-0.5.2.tgz", - "integrity": "sha512-E3ZJh4J3S9KfwdjZhe2afj6R9lGIN5Pher1pF39UGrXRqq/VDaGVIGN13BjHd2u8B61hArAGOnso7nBOouW3TQ==", - "dev": true, + "node_modules/marked": { + "version": "14.0.0", + "resolved": "https://registry.npmjs.org/marked/-/marked-14.0.0.tgz", + "integrity": "sha512-uIj4+faQ+MgHgwUW1l2PsPglZLOLOT1uErt06dAPtx2kjteLAkbsd/0FiYg/MGS+i7ZKLb7w2WClxHkzOOuryQ==", "license": "MIT", - "dependencies": { - "@babel/parser": "^7.29.0", - "@babel/types": "^7.29.0", - "source-map-js": "^1.2.1" - } - }, - "node_modules/make-dir": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-4.0.0.tgz", - "integrity": "sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw==", - "dev": true, - "license": "MIT", - "dependencies": { - "semver": "^7.5.3" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/markdown-it": { - "version": "14.1.1", - "resolved": "https://registry.npmjs.org/markdown-it/-/markdown-it-14.1.1.tgz", - "integrity": "sha512-BuU2qnTti9YKgK5N+IeMubp14ZUKUUw7yeJbkjtosvHiP0AZ5c8IAgEMk79D0eC8F23r4Ac/q8cAIFdm2FtyoA==", - "dev": true, - "license": "MIT", - "dependencies": { - "argparse": "^2.0.1", - "entities": "^4.4.0", - "linkify-it": "^5.0.0", - "mdurl": "^2.0.0", - "punycode.js": "^2.3.1", - "uc.micro": "^2.1.0" - }, + "peer": true, "bin": { - "markdown-it": "bin/markdown-it.mjs" - } - }, - "node_modules/markdown-it/node_modules/entities": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz", - "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", - "dev": true, - "license": "BSD-2-Clause", - "engines": { - "node": ">=0.12" + "marked": "bin/marked.js" }, - "funding": { - "url": "https://github.com/fb55/entities?sponsor=1" - } - }, - "node_modules/markdown-table": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/markdown-table/-/markdown-table-3.0.4.tgz", - "integrity": "sha512-wiYz4+JrLyb/DqW2hkFJxP7Vd7JuTDm77fvbM8VfEQdmSMqcImWeeRbHwZjBjIFki/VaMK2BhFi7oUUZeM5bqw==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" + "engines": { + "node": ">= 18" } }, "node_modules/math-intrinsics": { @@ -9524,34 +6033,6 @@ "node": ">= 0.4" } }, - "node_modules/mdast-util-find-and-replace": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/mdast-util-find-and-replace/-/mdast-util-find-and-replace-3.0.2.tgz", - "integrity": "sha512-Tmd1Vg/m3Xz43afeNxDIhWRtFZgM2VLyaf4vSTYwudTyeuTneoL3qtWMA5jeLyz/O1vDJmmV4QuScFCA2tBPwg==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "escape-string-regexp": "^5.0.0", - "unist-util-is": "^6.0.0", - "unist-util-visit-parents": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-find-and-replace/node_modules/escape-string-regexp": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-5.0.0.tgz", - "integrity": "sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw==", - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/mdast-util-from-markdown": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/mdast-util-from-markdown/-/mdast-util-from-markdown-2.0.2.tgz", @@ -9576,107 +6057,6 @@ "url": "https://opencollective.com/unified" } }, - "node_modules/mdast-util-gfm": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm/-/mdast-util-gfm-3.1.0.tgz", - "integrity": "sha512-0ulfdQOM3ysHhCJ1p06l0b0VKlhU0wuQs3thxZQagjcjPrlFRqY215uZGHHJan9GEAXd9MbfPjFJz+qMkVR6zQ==", - "license": "MIT", - "dependencies": { - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-gfm-autolink-literal": "^2.0.0", - "mdast-util-gfm-footnote": "^2.0.0", - "mdast-util-gfm-strikethrough": "^2.0.0", - "mdast-util-gfm-table": "^2.0.0", - "mdast-util-gfm-task-list-item": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-autolink-literal": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-autolink-literal/-/mdast-util-gfm-autolink-literal-2.0.1.tgz", - "integrity": "sha512-5HVP2MKaP6L+G6YaxPNjuL0BPrq9orG3TsrZ9YXbA3vDw/ACI4MEsnoDpn6ZNm7GnZgtAcONJyPhOP8tNJQavQ==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "ccount": "^2.0.0", - "devlop": "^1.0.0", - "mdast-util-find-and-replace": "^3.0.0", - "micromark-util-character": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-footnote": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-footnote/-/mdast-util-gfm-footnote-2.1.0.tgz", - "integrity": "sha512-sqpDWlsHn7Ac9GNZQMeUzPQSMzR6Wv0WKRNvQRg0KqHh02fpTz69Qc1QSseNX29bhz1ROIyNyxExfawVKTm1GQ==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "devlop": "^1.1.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0", - "micromark-util-normalize-identifier": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-strikethrough": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-strikethrough/-/mdast-util-gfm-strikethrough-2.0.0.tgz", - "integrity": "sha512-mKKb915TF+OC5ptj5bJ7WFRPdYtuHv0yTRxK2tJvi+BDqbkiG7h7u/9SI89nRAYcmap2xHQL9D+QG/6wSrTtXg==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-table": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-table/-/mdast-util-gfm-table-2.0.0.tgz", - "integrity": "sha512-78UEvebzz/rJIxLvE7ZtDd/vIQ0RHv+3Mh5DR96p7cS7HsBhYIICDBCu8csTNWNO6tBWfqXPWekRuj2FNOGOZg==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "devlop": "^1.0.0", - "markdown-table": "^3.0.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-task-list-item": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-task-list-item/-/mdast-util-gfm-task-list-item-2.0.0.tgz", - "integrity": "sha512-IrtvNvjxC1o06taBAVJznEnkiHxLFTzgonUdy8hzFVeDun0uTjxxrRGVaNFqkU1wJR3RBPEfsxmU6jDWPofrTQ==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "devlop": "^1.0.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/mdast-util-mdx-expression": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/mdast-util-mdx-expression/-/mdast-util-mdx-expression-2.0.1.tgz", @@ -9737,20 +6117,6 @@ "url": "https://opencollective.com/unified" } }, - "node_modules/mdast-util-newline-to-break": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-newline-to-break/-/mdast-util-newline-to-break-2.0.0.tgz", - "integrity": "sha512-MbgeFca0hLYIEx/2zGsszCSEJJ1JSCdiY5xQxRcLDDGa8EPvlLPupJ4DSajbMPAnC0je8jfb9TiUATnxxrHUog==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-find-and-replace": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/mdast-util-phrasing": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/mdast-util-phrasing/-/mdast-util-phrasing-4.1.0.tgz", @@ -9820,20 +6186,6 @@ "url": "https://opencollective.com/unified" } }, - "node_modules/mdurl": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdurl/-/mdurl-2.0.0.tgz", - "integrity": "sha512-Lf+9+2r+Tdp5wXDXC4PcIBjTDtq4UKjCPMQhKIuzpJNW0b96kVqSwW0bT7FhRSfmAiFYgP+SCRvdrDozfh0U5w==", - "dev": true, - "license": "MIT" - }, - "node_modules/merge-stream": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", - "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", - "dev": true, - "license": "MIT" - }, "node_modules/merge2": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", @@ -9844,6 +6196,21 @@ "node": ">= 8" } }, + "node_modules/meshline": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/meshline/-/meshline-3.3.1.tgz", + "integrity": "sha512-/TQj+JdZkeSUOl5Mk2J7eLcYTLiQm2IDzmlSvYm7ov15anEcDJ92GHqqazxTSreeNgfnYu24kiEvvv0WlbCdFQ==", + "license": "MIT", + "peerDependencies": { + "three": ">=0.137" + } + }, + "node_modules/meshoptimizer": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/meshoptimizer/-/meshoptimizer-1.0.1.tgz", + "integrity": "sha512-Vix+QlA1YYT3FwmBBZ+49cE5y/b+pRrcXKqGpS5ouh33d3lSp2PoTpCw19E0cKDFWalembrHnIaZetf27a+W2g==", + "license": "MIT" + }, "node_modules/micromark": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/micromark/-/micromark-4.0.2.tgz", @@ -9913,127 +6280,6 @@ "micromark-util-types": "^2.0.0" } }, - "node_modules/micromark-extension-gfm": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm/-/micromark-extension-gfm-3.0.0.tgz", - "integrity": "sha512-vsKArQsicm7t0z2GugkCKtZehqUm31oeGBV/KVSorWSy8ZlNAv7ytjFhvaryUiCUJYqs+NoE6AFhpQvBTM6Q4w==", - "license": "MIT", - "dependencies": { - "micromark-extension-gfm-autolink-literal": "^2.0.0", - "micromark-extension-gfm-footnote": "^2.0.0", - "micromark-extension-gfm-strikethrough": "^2.0.0", - "micromark-extension-gfm-table": "^2.0.0", - "micromark-extension-gfm-tagfilter": "^2.0.0", - "micromark-extension-gfm-task-list-item": "^2.0.0", - "micromark-util-combine-extensions": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-autolink-literal": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-autolink-literal/-/micromark-extension-gfm-autolink-literal-2.1.0.tgz", - "integrity": "sha512-oOg7knzhicgQ3t4QCjCWgTmfNhvQbDDnJeVu9v81r7NltNCVmhPy1fJRX27pISafdjL+SVc4d3l48Gb6pbRypw==", - "license": "MIT", - "dependencies": { - "micromark-util-character": "^2.0.0", - "micromark-util-sanitize-uri": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-footnote": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-footnote/-/micromark-extension-gfm-footnote-2.1.0.tgz", - "integrity": "sha512-/yPhxI1ntnDNsiHtzLKYnE3vf9JZ6cAisqVDauhp4CEHxlb4uoOTxOCJ+9s51bIB8U1N1FJ1RXOKTIlD5B/gqw==", - "license": "MIT", - "dependencies": { - "devlop": "^1.0.0", - "micromark-core-commonmark": "^2.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-normalize-identifier": "^2.0.0", - "micromark-util-sanitize-uri": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-strikethrough": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-strikethrough/-/micromark-extension-gfm-strikethrough-2.1.0.tgz", - "integrity": "sha512-ADVjpOOkjz1hhkZLlBiYA9cR2Anf8F4HqZUO6e5eDcPQd0Txw5fxLzzxnEkSkfnD0wziSGiv7sYhk/ktvbf1uw==", - "license": "MIT", - "dependencies": { - "devlop": "^1.0.0", - "micromark-util-chunked": "^2.0.0", - "micromark-util-classify-character": "^2.0.0", - "micromark-util-resolve-all": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-table": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-table/-/micromark-extension-gfm-table-2.1.1.tgz", - "integrity": "sha512-t2OU/dXXioARrC6yWfJ4hqB7rct14e8f7m0cbI5hUmDyyIlwv5vEtooptH8INkbLzOatzKuVbQmAYcbWoyz6Dg==", - "license": "MIT", - "dependencies": { - "devlop": "^1.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-tagfilter": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-tagfilter/-/micromark-extension-gfm-tagfilter-2.0.0.tgz", - "integrity": "sha512-xHlTOmuCSotIA8TW1mDIM6X2O1SiX5P9IuDtqGonFhEK0qgRI4yeC6vMxEV2dgyr2TiD+2PQ10o+cOhdVAcwfg==", - "license": "MIT", - "dependencies": { - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-task-list-item": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-task-list-item/-/micromark-extension-gfm-task-list-item-2.1.0.tgz", - "integrity": "sha512-qIBZhqxqI6fjLDYFTBIa4eivDMnP+OZqsNwmQ3xNLE4Cxwc+zfQEfbs6tzAo2Hjq+bh6q5F+Z8/cksrLFYWQQw==", - "license": "MIT", - "dependencies": { - "devlop": "^1.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/micromark-factory-destination": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/micromark-factory-destination/-/micromark-factory-destination-2.0.1.tgz", @@ -10421,53 +6667,22 @@ "node": ">=8.6" } }, - "node_modules/mime-db": { - "version": "1.52.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", - "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", - "dev": true, + "node_modules/mimic-response": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-3.1.0.tgz", + "integrity": "sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==", "license": "MIT", "engines": { - "node": ">= 0.6" - } - }, - "node_modules/mime-types": { - "version": "2.1.35", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", - "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", - "dev": true, - "license": "MIT", - "dependencies": { - "mime-db": "1.52.0" + "node": ">=10" }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/mimic-fn": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", - "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/min-indent": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/min-indent/-/min-indent-1.0.1.tgz", - "integrity": "sha512-I9jwMn07Sy/IwOj3zVkVik2JTvgpaykDZEigL6Rx6N9LbMywwUSMtxET+7lVoDLLd3O3IXwJwvuuns8UB/HeAg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=4" + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/minimatch": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.5.tgz", - "integrity": "sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w==", + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", "dev": true, "license": "ISC", "dependencies": { @@ -10481,30 +6696,34 @@ "version": "1.2.8", "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", - "dev": true, "license": "MIT", "funding": { "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/mkdirp-classic": { + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/mkdirp-classic/-/mkdirp-classic-0.5.3.tgz", + "integrity": "sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==", + "license": "MIT" + }, + "node_modules/monaco-editor": { + "version": "0.55.1", + "resolved": "https://registry.npmjs.org/monaco-editor/-/monaco-editor-0.55.1.tgz", + "integrity": "sha512-jz4x+TJNFHwHtwuV9vA9rMujcZRb0CEilTEwG2rRSpe/A7Jdkuj8xPKttCgOh+v/lkHy7HsZ64oj+q3xoAFl9A==", + "license": "MIT", + "peer": true, + "dependencies": { + "dompurify": "3.2.7", + "marked": "14.0.0" + } + }, "node_modules/ms": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", "license": "MIT" }, - "node_modules/mz": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/mz/-/mz-2.7.0.tgz", - "integrity": "sha512-z81GNO7nnYMEhrGh9LeymoE4+Yr0Wn5McHIZMK5cfQCl+NDX08sCZgUc9/6MHni9IWuFLm1Z3HTCXu2z9fN62Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "any-promise": "^1.0.0", - "object-assign": "^4.0.1", - "thenify-all": "^1.0.0" - } - }, "node_modules/nanoid": { "version": "3.3.11", "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz", @@ -10523,6 +6742,12 @@ "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" } }, + "node_modules/napi-build-utils": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/napi-build-utils/-/napi-build-utils-2.0.0.tgz", + "integrity": "sha512-GEbrYkbfF7MoNaoh2iGG84Mnf/WZfB0GdGEsM8wz7Expx/LlWf5U8t9nvJKXSp3qr5IsEbK04cBGhol/KwOsWA==", + "license": "MIT" + }, "node_modules/napi-postinstall": { "version": "0.3.4", "resolved": "https://registry.npmjs.org/napi-postinstall/-/napi-postinstall-0.3.4.tgz", @@ -10547,14 +6772,14 @@ "license": "MIT" }, "node_modules/next": { - "version": "16.1.7", - "resolved": "https://registry.npmjs.org/next/-/next-16.1.7.tgz", - "integrity": "sha512-WM0L7WrSvKwoLegLYr6V+mz+RIofqQgVAfHhMp9a88ms0cFX8iX9ew+snpWlSBwpkURJOUdvCEt3uLl3NNzvWg==", + "version": "16.1.6", + "resolved": "https://registry.npmjs.org/next/-/next-16.1.6.tgz", + "integrity": "sha512-hkyRkcu5x/41KoqnROkfTm2pZVbKxvbZRuNvKXLRXxs3VfyO0WhY50TQS40EuKO9SW3rBj/sF3WbVwDACeMZyw==", "license": "MIT", "dependencies": { - "@next/env": "16.1.7", + "@next/env": "16.1.6", "@swc/helpers": "0.5.15", - "baseline-browser-mapping": "^2.9.19", + "baseline-browser-mapping": "^2.8.3", "caniuse-lite": "^1.0.30001579", "postcss": "8.4.31", "styled-jsx": "5.1.6" @@ -10566,14 +6791,14 @@ "node": ">=20.9.0" }, "optionalDependencies": { - "@next/swc-darwin-arm64": "16.1.7", - "@next/swc-darwin-x64": "16.1.7", - "@next/swc-linux-arm64-gnu": "16.1.7", - "@next/swc-linux-arm64-musl": "16.1.7", - "@next/swc-linux-x64-gnu": "16.1.7", - "@next/swc-linux-x64-musl": "16.1.7", - "@next/swc-win32-arm64-msvc": "16.1.7", - "@next/swc-win32-x64-msvc": "16.1.7", + "@next/swc-darwin-arm64": "16.1.6", + "@next/swc-darwin-x64": "16.1.6", + "@next/swc-linux-arm64-gnu": "16.1.6", + "@next/swc-linux-arm64-musl": "16.1.6", + "@next/swc-linux-x64-gnu": "16.1.6", + "@next/swc-linux-x64-musl": "16.1.6", + "@next/swc-win32-arm64-msvc": "16.1.6", + "@next/swc-win32-x64-msvc": "16.1.6", "sharp": "^0.34.4" }, "peerDependencies": { @@ -10627,6 +6852,30 @@ "node": "^10 || ^12 || >=14" } }, + "node_modules/node-abi": { + "version": "3.87.0", + "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-3.87.0.tgz", + "integrity": "sha512-+CGM1L1CgmtheLcBuleyYOn7NWPVu0s0EJH2C4puxgEZb9h8QpR9G2dBfZJOAUhi7VQxuBPMd0hiISWcTyiYyQ==", + "license": "MIT", + "dependencies": { + "semver": "^7.3.5" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/node-abi/node_modules/semver": { + "version": "7.7.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.4.tgz", + "integrity": "sha512-vFKC2IEtQnVhpT78h1Yp8wzwrf8CM+MzKMHGJZfBtzhZNycRFnXsHk6E5TxIkkMsgNS7mdX3AGB7x2QM2di4lA==", + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/node-releases": { "version": "2.0.27", "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.27.tgz", @@ -10634,56 +6883,15 @@ "dev": true, "license": "MIT" }, - "node_modules/normalize-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", - "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/npm-run-path": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", - "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", - "dev": true, - "license": "MIT", - "dependencies": { - "path-key": "^3.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/nwsapi": { - "version": "2.2.23", - "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.23.tgz", - "integrity": "sha512-7wfH4sLbt4M0gCDzGE6vzQBo0bfTKjU7Sfpqy/7gs1qBfYz2vEJH6vXcBKpO3+6Yu1telwd0t9HpyOoLEQQbIQ==", - "dev": true, - "license": "MIT" - }, "node_modules/object-assign": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", - "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" } }, - "node_modules/object-hash": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/object-hash/-/object-hash-3.0.0.tgz", - "integrity": "sha512-RSn9F68PjH9HqtltsSnqYC1XXoWe9Bju5+213R98cNGttag9q9yAOTzdbsqvIa7aNm5WffBZFpWYr2aWrklWAw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 6" - } - }, "node_modules/object-inspect": { "version": "1.13.4", "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.4.tgz", @@ -10797,43 +7005,15 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/obug": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/obug/-/obug-2.1.1.tgz", - "integrity": "sha512-uTqF9MuPraAQ+IsnPf366RG4cP9RtUi7MLO1N3KEc+wb0a6yKpeL0lmk2IB1jY5KHPAlTc6T/JRdC/YqxHNwkQ==", - "dev": true, - "funding": [ - "https://github.com/sponsors/sxzz", - "https://opencollective.com/debug" - ], - "license": "MIT" - }, "node_modules/once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", - "dev": true, "license": "ISC", "dependencies": { "wrappy": "1" } }, - "node_modules/onetime": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", - "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", - "dev": true, - "license": "MIT", - "dependencies": { - "mimic-fn": "^2.1.0" - }, - "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/optionator": { "version": "0.9.4", "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.4.tgz", @@ -10852,349 +7032,6 @@ "node": ">= 0.8.0" } }, - "node_modules/orval": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/orval/-/orval-8.3.0.tgz", - "integrity": "sha512-njTZ+YcSawGc6Zo4Ak19VWH1Ohpw6MSofYiTYwUgYemNLeX+d+CDjC3VofzUF2+TNYP+dXl9Nyo+5wraAdSDfA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@commander-js/extra-typings": "^14.0.0", - "@orval/angular": "8.3.0", - "@orval/axios": "8.3.0", - "@orval/core": "8.3.0", - "@orval/fetch": "8.3.0", - "@orval/hono": "8.3.0", - "@orval/mcp": "8.3.0", - "@orval/mock": "8.3.0", - "@orval/query": "8.3.0", - "@orval/solid-start": "8.3.0", - "@orval/swr": "8.3.0", - "@orval/zod": "8.3.0", - "@scalar/json-magic": "^0.8.8", - "@scalar/openapi-parser": "^0.23.9", - "@scalar/openapi-types": "0.5.3", - "chalk": "^5.6.2", - "chokidar": "^5.0.0", - "commander": "^14.0.2", - "enquirer": "^2.4.1", - "execa": "^9.6.1", - "find-up": "8.0.0", - "fs-extra": "^11.3.2", - "jiti": "^2.6.1", - "js-yaml": "4.1.1", - "remeda": "^2.32.0", - "string-argv": "^0.3.2", - "tsconfck": "^3.1.6", - "typedoc": "^0.28.15", - "typedoc-plugin-coverage": "^4.0.2", - "typedoc-plugin-markdown": "^4.9.0" - }, - "bin": { - "orval": "dist/bin/orval.mjs" - }, - "engines": { - "node": ">=22.18.0" - } - }, - "node_modules/orval/node_modules/@commander-js/extra-typings": { - "version": "14.0.0", - "resolved": "https://registry.npmjs.org/@commander-js/extra-typings/-/extra-typings-14.0.0.tgz", - "integrity": "sha512-hIn0ncNaJRLkZrxBIp5AsW/eXEHNKYQBh0aPdoUqNgD+Io3NIykQqpKFyKcuasZhicGaEZJX/JBSIkZ4e5x8Dg==", - "dev": true, - "license": "MIT", - "peerDependencies": { - "commander": "~14.0.0" - } - }, - "node_modules/orval/node_modules/chalk": { - "version": "5.6.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.6.2.tgz", - "integrity": "sha512-7NzBL0rN6fMUW+f7A6Io4h40qQlG+xGmtMxfbnH/K7TAtt8JQWVQK+6g0UXKMeVJoyV5EkkNsErQ8pVD3bLHbA==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^12.17.0 || ^14.13 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/orval/node_modules/commander": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/commander/-/commander-14.0.3.tgz", - "integrity": "sha512-H+y0Jo/T1RZ9qPP4Eh1pkcQcLRglraJaSLoyOtHxu6AapkjWVCy2Sit1QQ4x3Dng8qDlSsZEet7g5Pq06MvTgw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=20" - } - }, - "node_modules/orval/node_modules/execa": { - "version": "9.6.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-9.6.1.tgz", - "integrity": "sha512-9Be3ZoN4LmYR90tUoVu2te2BsbzHfhJyfEiAVfz7N5/zv+jduIfLrV2xdQXOHbaD6KgpGdO9PRPM1Y4Q9QkPkA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@sindresorhus/merge-streams": "^4.0.0", - "cross-spawn": "^7.0.6", - "figures": "^6.1.0", - "get-stream": "^9.0.0", - "human-signals": "^8.0.1", - "is-plain-obj": "^4.1.0", - "is-stream": "^4.0.1", - "npm-run-path": "^6.0.0", - "pretty-ms": "^9.2.0", - "signal-exit": "^4.1.0", - "strip-final-newline": "^4.0.0", - "yoctocolors": "^2.1.1" - }, - "engines": { - "node": "^18.19.0 || >=20.5.0" - }, - "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" - } - }, - "node_modules/orval/node_modules/figures": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/figures/-/figures-6.1.0.tgz", - "integrity": "sha512-d+l3qxjSesT4V7v2fh+QnmFnUWv9lSpjarhShNTgBOfA0ttejbQUAlHLitbjkoRiDulW0OPoQPYIGhIC8ohejg==", - "dev": true, - "license": "MIT", - "dependencies": { - "is-unicode-supported": "^2.0.0" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/orval/node_modules/find-up": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-8.0.0.tgz", - "integrity": "sha512-JGG8pvDi2C+JxidYdIwQDyS/CgcrIdh18cvgxcBge3wSHRQOrooMD3GlFBcmMJAN9M42SAZjDp5zv1dglJjwww==", - "dev": true, - "license": "MIT", - "dependencies": { - "locate-path": "^8.0.0", - "unicorn-magic": "^0.3.0" - }, - "engines": { - "node": ">=20" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/orval/node_modules/fs-extra": { - "version": "11.3.3", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.3.3.tgz", - "integrity": "sha512-VWSRii4t0AFm6ixFFmLLx1t7wS1gh+ckoa84aOeapGum0h+EZd1EhEumSB+ZdDLnEPuucsVB9oB7cxJHap6Afg==", - "dev": true, - "license": "MIT", - "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - }, - "engines": { - "node": ">=14.14" - } - }, - "node_modules/orval/node_modules/get-stream": { - "version": "9.0.1", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-9.0.1.tgz", - "integrity": "sha512-kVCxPF3vQM/N0B1PmoqVUqgHP+EeVjmZSQn+1oCRPxd2P21P2F19lIgbR3HBosbB1PUhOAoctJnfEn2GbN2eZA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@sec-ant/readable-stream": "^0.4.1", - "is-stream": "^4.0.1" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/orval/node_modules/human-signals": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-8.0.1.tgz", - "integrity": "sha512-eKCa6bwnJhvxj14kZk5NCPc6Hb6BdsU9DZcOnmQKSnO1VKrfV0zCvtttPZUsBvjmNDn8rpcJfpwSYnHBjc95MQ==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=18.18.0" - } - }, - "node_modules/orval/node_modules/is-stream": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-4.0.1.tgz", - "integrity": "sha512-Dnz92NInDqYckGEUJv689RbRiTSEHCQ7wOVeALbkOz999YpqT46yMRIGtSNl2iCL1waAZSx40+h59NV/EwzV/A==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/orval/node_modules/is-unicode-supported": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-2.1.0.tgz", - "integrity": "sha512-mE00Gnza5EEB3Ds0HfMyllZzbBrmLOX3vfWoj9A9PEnTfratQ/BcaJOuMhnkhjXvb2+FkY3VuHqtAGpTPmglFQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/orval/node_modules/locate-path": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-8.0.0.tgz", - "integrity": "sha512-XT9ewWAC43tiAV7xDAPflMkG0qOPn2QjHqlgX8FOqmWa/rxnyYDulF9T0F7tRy1u+TVTmK/M//6VIOye+2zDXg==", - "dev": true, - "license": "MIT", - "dependencies": { - "p-locate": "^6.0.0" - }, - "engines": { - "node": ">=20" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/orval/node_modules/npm-run-path": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-6.0.0.tgz", - "integrity": "sha512-9qny7Z9DsQU8Ou39ERsPU4OZQlSTP47ShQzuKZ6PRXpYLtIFgl/DEBYEXKlvcEa+9tHVcK8CF81Y2V72qaZhWA==", - "dev": true, - "license": "MIT", - "dependencies": { - "path-key": "^4.0.0", - "unicorn-magic": "^0.3.0" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/orval/node_modules/p-limit": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-4.0.0.tgz", - "integrity": "sha512-5b0R4txpzjPWVw/cXXUResoD4hb6U/x9BH08L7nw+GN1sezDzPdxeRvpc9c433fZhBan/wusjbCsqwqm4EIBIQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "yocto-queue": "^1.0.0" - }, - "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/orval/node_modules/p-locate": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-6.0.0.tgz", - "integrity": "sha512-wPrq66Llhl7/4AGC6I+cqxT07LhXvWL08LNXz1fENOw0Ap4sRZZ/gZpTTJ5jpurzzzfS2W/Ge9BY3LgLjCShcw==", - "dev": true, - "license": "MIT", - "dependencies": { - "p-limit": "^4.0.0" - }, - "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/orval/node_modules/path-key": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-4.0.0.tgz", - "integrity": "sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/orval/node_modules/signal-exit": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", - "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">=14" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/orval/node_modules/strip-final-newline": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-4.0.0.tgz", - "integrity": "sha512-aulFJcD6YK8V1G7iRB5tigAP4TsHBZZrOV8pjV++zdUwmeV8uzbY7yn6h9MswN62adStNZFuCIx4haBnRuMDaw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/orval/node_modules/unicorn-magic": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/unicorn-magic/-/unicorn-magic-0.3.0.tgz", - "integrity": "sha512-+QBBXBCvifc56fsbuxZQ6Sic3wqqc3WWaqxs58gvJrcOuN83HGTCwz3oS5phzU9LthRNE9VrJCFCLUgHeeFnfA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/orval/node_modules/yocto-queue": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-1.2.2.tgz", - "integrity": "sha512-4LCcse/U2MHZ63HAJVE+v71o7yOdIe4cZ70Wpf8D/IyjDKYQLV5GD46B+hSTjJsvV5PztjvHoU580EftxjDZFQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12.20" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/ospath": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/ospath/-/ospath-1.2.2.tgz", - "integrity": "sha512-o6E5qJV5zkAbIDNhGSIlyOhScKXgQrSRMilfph0clDfM0nEnBOlKlH4sWDmG95BW/CvwNz0vmm7dJVtU2KlMiA==", - "dev": true, - "license": "MIT" - }, "node_modules/own-keys": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/own-keys/-/own-keys-1.0.1.tgz", @@ -11245,22 +7082,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/p-map": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/p-map/-/p-map-4.0.0.tgz", - "integrity": "sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "aggregate-error": "^3.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/parent-module": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", @@ -11299,32 +7120,6 @@ "integrity": "sha512-CmBKiL6NNo/OqgmMn95Fk9Whlp2mtvIv+KNpQKN2F4SjvrEesubTRWGYSg+BnWZOnlCaSTU1sMpsBOzgbYhnsA==", "license": "MIT" }, - "node_modules/parse-ms": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/parse-ms/-/parse-ms-4.0.0.tgz", - "integrity": "sha512-TXfryirbmq34y8QBwgqCVLi+8oA3oWx2eAnSn62ITyEhEYaWRlVZ2DvMM9eZbMs/RfxPu/PK/aBLyGj4IrqMHw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/parse5": { - "version": "7.3.0", - "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.3.0.tgz", - "integrity": "sha512-IInvU7fabl34qmi9gY8XOVxhYyMyuH2xUNpb2q8/Y+7552KlejkRvqvD19nMoUW/uQGGbqNpA6Tufu5FL5BZgw==", - "dev": true, - "license": "MIT", - "dependencies": { - "entities": "^6.0.0" - }, - "funding": { - "url": "https://github.com/inikulin/parse5?sponsor=1" - } - }, "node_modules/path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -11339,7 +7134,6 @@ "version": "3.1.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", - "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -11352,27 +7146,6 @@ "dev": true, "license": "MIT" }, - "node_modules/pathe": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/pathe/-/pathe-2.0.3.tgz", - "integrity": "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==", - "dev": true, - "license": "MIT" - }, - "node_modules/pend": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz", - "integrity": "sha512-F3asv42UuXchdzt+xXqfW1OGlVBe+mxa2mqI0pg5yAHZPvFmY3Y6drSf/GQ1A86WgWEN9Kzh/WrgKa6iGcHXLg==", - "dev": true, - "license": "MIT" - }, - "node_modules/performance-now": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", - "integrity": "sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow==", - "dev": true, - "license": "MIT" - }, "node_modules/picocolors": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", @@ -11380,9 +7153,9 @@ "license": "ISC" }, "node_modules/picomatch": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.2.tgz", - "integrity": "sha512-V7+vQEJ06Z+c5tSye8S+nHUfI51xoXIXjHQ99cQtKUkQqqO1kO/KCJUfZXuB47h/YBlDhah2H3hdUGXn8ie0oA==", + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", "dev": true, "license": "MIT", "engines": { @@ -11392,26 +7165,6 @@ "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/pify": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz", - "integrity": "sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/pirates": { - "version": "4.0.7", - "resolved": "https://registry.npmjs.org/pirates/-/pirates-4.0.7.tgz", - "integrity": "sha512-TfySrs/5nm8fQJDcBDuUng3VOUKsd7S+zqvbOTiGXHfxX4wK31ard+hoNuvkicM/2YFzlpDgABOevKSsB4G/FA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 6" - } - }, "node_modules/possible-typed-array-names": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/possible-typed-array-names/-/possible-typed-array-names-1.1.0.tgz", @@ -11451,124 +7204,10 @@ "node": "^10 || ^12 || >=14" } }, - "node_modules/postcss-import": { - "version": "15.1.0", - "resolved": "https://registry.npmjs.org/postcss-import/-/postcss-import-15.1.0.tgz", - "integrity": "sha512-hpr+J05B2FVYUAXHeK1YyI267J/dDDhMU6B6civm8hSY1jYJnBXxzKDKDswzJmtLHryrjhnDjqqp/49t8FALew==", - "dev": true, - "license": "MIT", - "dependencies": { - "postcss-value-parser": "^4.0.0", - "read-cache": "^1.0.0", - "resolve": "^1.1.7" - }, - "engines": { - "node": ">=14.0.0" - }, - "peerDependencies": { - "postcss": "^8.0.0" - } - }, - "node_modules/postcss-js": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/postcss-js/-/postcss-js-4.1.0.tgz", - "integrity": "sha512-oIAOTqgIo7q2EOwbhb8UalYePMvYoIeRY2YKntdpFQXNosSu3vLrniGgmH9OKs/qAkfoj5oB3le/7mINW1LCfw==", - "dev": true, - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/postcss/" - }, - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], - "license": "MIT", - "dependencies": { - "camelcase-css": "^2.0.1" - }, - "engines": { - "node": "^12 || ^14 || >= 16" - }, - "peerDependencies": { - "postcss": "^8.4.21" - } - }, - "node_modules/postcss-load-config": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/postcss-load-config/-/postcss-load-config-6.0.1.tgz", - "integrity": "sha512-oPtTM4oerL+UXmx+93ytZVN82RrlY/wPUV8IeDxFrzIjXOLF1pN+EmKPLbubvKHT2HC20xXsCAH2Z+CKV6Oz/g==", - "dev": true, - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/postcss/" - }, - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], - "license": "MIT", - "dependencies": { - "lilconfig": "^3.1.1" - }, - "engines": { - "node": ">= 18" - }, - "peerDependencies": { - "jiti": ">=1.21.0", - "postcss": ">=8.0.9", - "tsx": "^4.8.1", - "yaml": "^2.4.2" - }, - "peerDependenciesMeta": { - "jiti": { - "optional": true - }, - "postcss": { - "optional": true - }, - "tsx": { - "optional": true - }, - "yaml": { - "optional": true - } - } - }, - "node_modules/postcss-nested": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/postcss-nested/-/postcss-nested-6.2.0.tgz", - "integrity": "sha512-HQbt28KulC5AJzG+cZtj9kvKB93CFCdLvog1WFLf1D+xmMvPGlBstkpTEZfK5+AN9hfJocyBFCNiqyS48bpgzQ==", - "dev": true, - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/postcss/" - }, - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], - "license": "MIT", - "dependencies": { - "postcss-selector-parser": "^6.1.1" - }, - "engines": { - "node": ">=12.0" - }, - "peerDependencies": { - "postcss": "^8.2.14" - } - }, "node_modules/postcss-selector-parser": { - "version": "6.1.2", - "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.1.2.tgz", - "integrity": "sha512-Q8qQfPiZ+THO/3ZrOrO0cJJKfpYCagtMUkXbnEfmgUjwXg6z/WBeOyS9APBBPCTSiDV+s4SwQGu8yFsiMRIudg==", - "dev": true, + "version": "6.0.10", + "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.0.10.tgz", + "integrity": "sha512-IQ7TZdoaqbT+LCpShg46jnZVlhWD2w6iQYAcYXfHARZ7X1t/UGhhceQDs5X0cGqKvYlHNOuv7Oa1xmb0oQuA3w==", "license": "MIT", "dependencies": { "cssesc": "^3.0.0", @@ -11578,12 +7217,37 @@ "node": ">=4" } }, - "node_modules/postcss-value-parser": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz", - "integrity": "sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==", - "dev": true, - "license": "MIT" + "node_modules/potpack": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/potpack/-/potpack-1.0.2.tgz", + "integrity": "sha512-choctRBIV9EMT9WGAZHn3V7t0Z2pMQyl0EZE6pFc/6ml3ssw7Dlf/oAOvFwjm1HVsqfQN8GfeFyJ+d8tRzqueQ==", + "license": "ISC" + }, + "node_modules/prebuild-install": { + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/prebuild-install/-/prebuild-install-7.1.3.tgz", + "integrity": "sha512-8Mf2cbV7x1cXPUILADGI3wuhfqWvtiLA1iclTDbFRZkgRQS0NqsPZphna9V+HyTEadheuPmjaJMsbzKQFOzLug==", + "license": "MIT", + "dependencies": { + "detect-libc": "^2.0.0", + "expand-template": "^2.0.3", + "github-from-package": "0.0.0", + "minimist": "^1.2.3", + "mkdirp-classic": "^0.5.3", + "napi-build-utils": "^2.0.0", + "node-abi": "^3.3.0", + "pump": "^3.0.0", + "rc": "^1.2.7", + "simple-get": "^4.0.0", + "tar-fs": "^2.0.0", + "tunnel-agent": "^0.6.0" + }, + "bin": { + "prebuild-install": "bin.js" + }, + "engines": { + "node": ">=10" + } }, "node_modules/prelude-ls": { "version": "1.2.1", @@ -11595,104 +7259,20 @@ "node": ">= 0.8.0" } }, - "node_modules/prettier": { - "version": "3.8.1", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.8.1.tgz", - "integrity": "sha512-UOnG6LftzbdaHZcKoPFtOcCKztrQ57WkHDeRD9t/PTQtmT0NHSeWWepj6pS0z/N7+08BHFDQVUrfmfMRcZwbMg==", - "dev": true, - "license": "MIT", - "bin": { - "prettier": "bin/prettier.cjs" - }, - "engines": { - "node": ">=14" - }, - "funding": { - "url": "https://github.com/prettier/prettier?sponsor=1" - } - }, - "node_modules/pretty-bytes": { - "version": "5.6.0", - "resolved": "https://registry.npmjs.org/pretty-bytes/-/pretty-bytes-5.6.0.tgz", - "integrity": "sha512-FFw039TmrBqFK8ma/7OL3sDz/VytdtJr044/QUJtH0wK9lb9jLq9tJyIxUwtQJHwar2BqtiA4iCWSwo9JLkzFg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/pretty-format": { - "version": "27.5.1", - "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-27.5.1.tgz", - "integrity": "sha512-Qb1gy5OrP5+zDf2Bvnzdl3jsTf1qXVMazbvCoKhtKqVs4/YK4ozX4gKQJJVyNe+cajNPn0KoC0MC3FUmaHWEmQ==", - "dev": true, - "license": "MIT", - "peer": true, + "node_modules/promise-worker-transferable": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/promise-worker-transferable/-/promise-worker-transferable-1.0.4.tgz", + "integrity": "sha512-bN+0ehEnrXfxV2ZQvU2PetO0n4gqBD4ulq3MI1WOPLgr7/Mg9yRQkX5+0v1vagr74ZTsl7XtzlaYDo2EuCeYJw==", + "license": "Apache-2.0", "dependencies": { - "ansi-regex": "^5.0.1", - "ansi-styles": "^5.0.0", - "react-is": "^17.0.1" - }, - "engines": { - "node": "^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0" - } - }, - "node_modules/pretty-format/node_modules/ansi-styles": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", - "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", - "dev": true, - "license": "MIT", - "peer": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/pretty-format/node_modules/react-is": { - "version": "17.0.2", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-17.0.2.tgz", - "integrity": "sha512-w2GsyukL62IJnlaff/nRegPQR94C/XXamvMWmSHRJ4y7Ts/4ocGRmTHvOs8PSE6pB3dWOrD/nueuU5sduBsQ4w==", - "dev": true, - "license": "MIT", - "peer": true - }, - "node_modules/pretty-ms": { - "version": "9.3.0", - "resolved": "https://registry.npmjs.org/pretty-ms/-/pretty-ms-9.3.0.tgz", - "integrity": "sha512-gjVS5hOP+M3wMm5nmNOucbIrqudzs9v/57bWRHQWLYklXqoXKrVfYW2W9+glfGsqtPgpiz5WwyEEB+ksXIx3gQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "parse-ms": "^4.0.0" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/process": { - "version": "0.11.10", - "resolved": "https://registry.npmjs.org/process/-/process-0.11.10.tgz", - "integrity": "sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.6.0" + "is-promise": "^2.1.0", + "lie": "^3.0.2" } }, "node_modules/prop-types": { "version": "15.8.1", "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.8.1.tgz", "integrity": "sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==", - "dev": true, "license": "MIT", "dependencies": { "loose-envify": "^1.4.0", @@ -11700,13 +7280,6 @@ "react-is": "^16.13.1" } }, - "node_modules/prop-types/node_modules/react-is": { - "version": "16.13.1", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", - "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==", - "dev": true, - "license": "MIT" - }, "node_modules/property-information": { "version": "7.1.0", "resolved": "https://registry.npmjs.org/property-information/-/property-information-7.1.0.tgz", @@ -11717,18 +7290,10 @@ "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/proxy-from-env": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.0.0.tgz", - "integrity": "sha512-F2JHgJQ1iqwnHDcQjVBsq3n/uoaFL+iPW/eAeL7kVxy/2RrWaN4WroKjjvbsoRtv0ftelNyC01bjRhn/bhcf4A==", - "dev": true, - "license": "MIT" - }, "node_modules/pump": { "version": "3.0.3", "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.3.tgz", "integrity": "sha512-todwxLMY7/heScKmntwQG8CXVkWUOdYxIvY2s0VWAAMh/nd8SoYiRaKjlr7+iCs984f2P8zvrfWcDDYVb73NfA==", - "dev": true, "license": "MIT", "dependencies": { "end-of-stream": "^1.1.0", @@ -11745,32 +7310,6 @@ "node": ">=6" } }, - "node_modules/punycode.js": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/punycode.js/-/punycode.js-2.3.1.tgz", - "integrity": "sha512-uxFIHU0YlHYhDQtV4R9J6a52SLx28BCjT+4ieh7IGbgwVJWO+km431c4yRlREUAsAmt/uMjQUyQHNEPf0M39CA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/qs": { - "version": "6.14.2", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.14.2.tgz", - "integrity": "sha512-V/yCWTTF7VJ9hIh18Ugr2zhJMP01MY7c5kh4J870L7imm6/DIzBsNLTXzMwUA3yZ5b/KBqLx8Kp3uRvd7xSe3Q==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "side-channel": "^1.1.0" - }, - "engines": { - "node": ">=0.6" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -11792,33 +7331,56 @@ ], "license": "MIT" }, + "node_modules/rc": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", + "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", + "license": "(BSD-2-Clause OR MIT OR Apache-2.0)", + "dependencies": { + "deep-extend": "^0.6.0", + "ini": "~1.3.0", + "minimist": "^1.2.0", + "strip-json-comments": "~2.0.1" + }, + "bin": { + "rc": "cli.js" + } + }, + "node_modules/rc/node_modules/strip-json-comments": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", + "integrity": "sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==", + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/react": { - "version": "19.2.4", - "resolved": "https://registry.npmjs.org/react/-/react-19.2.4.tgz", - "integrity": "sha512-9nfp2hYpCwOjAN+8TZFGhtWEwgvWHXqESH8qT89AT/lWklpLON22Lc8pEtnpsZz7VmawabSU0gCjnj8aC0euHQ==", + "version": "19.2.3", + "resolved": "https://registry.npmjs.org/react/-/react-19.2.3.tgz", + "integrity": "sha512-Ku/hhYbVjOQnXDZFv2+RibmLFGwFdeeKHFcOTlrt7xplBnya5OGn/hIRDsqDiSUcfORsDC7MPxwork8jBwsIWA==", "license": "MIT", "engines": { "node": ">=0.10.0" } }, "node_modules/react-dom": { - "version": "19.2.4", - "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-19.2.4.tgz", - "integrity": "sha512-AXJdLo8kgMbimY95O2aKQqsz2iWi9jMgKJhRBAxECE4IFxfcazB2LmzloIoibJI3C12IlY20+KFaLv+71bUJeQ==", + "version": "19.2.3", + "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-19.2.3.tgz", + "integrity": "sha512-yELu4WmLPw5Mr/lmeEpox5rw3RETacE++JgHqQzd2dg+YbJuat3jH4ingc+WPZhxaoFzdv9y33G+F7Nl5O0GBg==", "license": "MIT", "dependencies": { "scheduler": "^0.27.0" }, "peerDependencies": { - "react": "^19.2.4" + "react": "^19.2.3" } }, "node_modules/react-is": { - "version": "19.2.4", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-19.2.4.tgz", - "integrity": "sha512-W+EWGn2v0ApPKgKKCy/7s7WHXkboGcsrXE+2joLyVxkbyVQfO3MUEaUQDHoSmb8TFFrSKYa9mw64WZHNHSDzYA==", - "license": "MIT", - "peer": true + "version": "16.13.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", + "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==", + "license": "MIT" }, "node_modules/react-markdown": { "version": "10.1.0", @@ -11847,181 +7409,104 @@ "react": ">=18" } }, - "node_modules/react-redux": { - "version": "9.2.0", - "resolved": "https://registry.npmjs.org/react-redux/-/react-redux-9.2.0.tgz", - "integrity": "sha512-ROY9fvHhwOD9ySfrF0wmvu//bKCQ6AeZZq1nJNtbDC+kk5DuSuNX/n6YWYF/SYy7bSba4D4FSz8DJeKY/S/r+g==", + "node_modules/react-smooth": { + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/react-smooth/-/react-smooth-4.0.4.tgz", + "integrity": "sha512-gnGKTpYwqL0Iii09gHobNolvX4Kiq4PKx6eWBCYYix+8cdw+cGo3do906l1NBPKkSWx1DghC1dlWG9L2uGd61Q==", "license": "MIT", "dependencies": { - "@types/use-sync-external-store": "^0.0.6", - "use-sync-external-store": "^1.4.0" - }, - "peerDependencies": { - "@types/react": "^18.2.25 || ^19", - "react": "^18.0 || ^19", - "redux": "^5.0.0" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - }, - "redux": { - "optional": true - } - } - }, - "node_modules/react-remove-scroll": { - "version": "2.7.2", - "resolved": "https://registry.npmjs.org/react-remove-scroll/-/react-remove-scroll-2.7.2.tgz", - "integrity": "sha512-Iqb9NjCCTt6Hf+vOdNIZGdTiH1QSqr27H/Ek9sv/a97gfueI/5h1s3yRi1nngzMUaOOToin5dI1dXKdXiF+u0Q==", - "license": "MIT", - "dependencies": { - "react-remove-scroll-bar": "^2.3.7", - "react-style-singleton": "^2.2.3", - "tslib": "^2.1.0", - "use-callback-ref": "^1.3.3", - "use-sidecar": "^1.1.3" - }, - "engines": { - "node": ">=10" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/react-remove-scroll-bar": { - "version": "2.3.8", - "resolved": "https://registry.npmjs.org/react-remove-scroll-bar/-/react-remove-scroll-bar-2.3.8.tgz", - "integrity": "sha512-9r+yi9+mgU33AKcj6IbT9oRCO78WriSj6t/cF8DWBZJ9aOGPOTEDvdUDz1FwKim7QXWwmHqtdHnRJfhAxEG46Q==", - "license": "MIT", - "dependencies": { - "react-style-singleton": "^2.2.2", - "tslib": "^2.0.0" - }, - "engines": { - "node": ">=10" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/react-style-singleton": { - "version": "2.2.3", - "resolved": "https://registry.npmjs.org/react-style-singleton/-/react-style-singleton-2.2.3.tgz", - "integrity": "sha512-b6jSvxvVnyptAiLjbkWLE/lOnR4lfTtDAl+eUC7RZy+QQWc6wRzIV2CE6xBuMmDxc2qIihtDCZD5NPOFl7fRBQ==", - "license": "MIT", - "dependencies": { - "get-nonce": "^1.0.0", - "tslib": "^2.0.0" - }, - "engines": { - "node": ">=10" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/read-cache": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/read-cache/-/read-cache-1.0.0.tgz", - "integrity": "sha512-Owdv/Ft7IjOgm/i0xvNDZ1LrRANRfew4b2prF3OWMQLxLfu3bS8FVhCsrSCMK4lR56Y9ya+AThoTpDCTxCmpRA==", - "dev": true, - "license": "MIT", - "dependencies": { - "pify": "^2.3.0" - } - }, - "node_modules/readdirp": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-5.0.0.tgz", - "integrity": "sha512-9u/XQ1pvrQtYyMpZe7DXKv2p5CNvyVwzUB6uhLAnQwHMSgKMBR62lc7AHljaeteeHXn11XTAaLLUVZYVZyuRBQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 20.19.0" - }, - "funding": { - "type": "individual", - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/recharts": { - "version": "3.7.0", - "resolved": "https://registry.npmjs.org/recharts/-/recharts-3.7.0.tgz", - "integrity": "sha512-l2VCsy3XXeraxIID9fx23eCb6iCBsxUQDnE8tWm6DFdszVAO7WVY/ChAD9wVit01y6B2PMupYiMmQwhgPHc9Ew==", - "license": "MIT", - "workspaces": [ - "www" - ], - "dependencies": { - "@reduxjs/toolkit": "1.x.x || 2.x.x", - "clsx": "^2.1.1", - "decimal.js-light": "^2.5.1", - "es-toolkit": "^1.39.3", - "eventemitter3": "^5.0.1", - "immer": "^10.1.1", - "react-redux": "8.x.x || 9.x.x", - "reselect": "5.1.1", - "tiny-invariant": "^1.3.3", - "use-sync-external-store": "^1.2.2", - "victory-vendor": "^37.0.2" - }, - "engines": { - "node": ">=18" + "fast-equals": "^5.0.1", + "prop-types": "^15.8.1", + "react-transition-group": "^4.4.5" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0", - "react-dom": "^16.0.0 || ^17.0.0 || ^18.0.0 || ^19.0.0", - "react-is": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" + "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" } }, - "node_modules/redent": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/redent/-/redent-3.0.0.tgz", - "integrity": "sha512-6tDA8g98We0zd0GvVeMT9arEOnTw9qM03L9cJXaCjrip1OO764RDBLBfrB4cwzNGDj5OA5ioymC9GkizgWJDUg==", - "dev": true, - "license": "MIT", + "node_modules/react-transition-group": { + "version": "4.4.5", + "resolved": "https://registry.npmjs.org/react-transition-group/-/react-transition-group-4.4.5.tgz", + "integrity": "sha512-pZcd1MCJoiKiBR2NRxeCRg13uCXbydPnmB4EOeRrY7480qNWO8IIgQG6zlDkm6uRMsURXPuKq0GWtiM59a5Q6g==", + "license": "BSD-3-Clause", "dependencies": { - "indent-string": "^4.0.0", - "strip-indent": "^3.0.0" + "@babel/runtime": "^7.5.5", + "dom-helpers": "^5.0.1", + "loose-envify": "^1.4.0", + "prop-types": "^15.6.2" }, - "engines": { - "node": ">=8" + "peerDependencies": { + "react": ">=16.6.0", + "react-dom": ">=16.6.0" } }, - "node_modules/redux": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/redux/-/redux-5.0.1.tgz", - "integrity": "sha512-M9/ELqF6fy8FwmkpnF0S3YKOqMyoWJ4+CS5Efg2ct3oY9daQvd/Pc71FpGZsVsbl3Cpb+IIcjBDUnnyBdQbq4w==", - "license": "MIT" - }, - "node_modules/redux-thunk": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/redux-thunk/-/redux-thunk-3.1.0.tgz", - "integrity": "sha512-NW2r5T6ksUKXCabzhL9z+h206HQw/NJkcLm1GPImRQ8IzfXwRGqjVhKJGauHirT0DAuyy6hjdnMZaRoAcy0Klw==", + "node_modules/react-use-measure": { + "version": "2.1.7", + "resolved": "https://registry.npmjs.org/react-use-measure/-/react-use-measure-2.1.7.tgz", + "integrity": "sha512-KrvcAo13I/60HpwGO5jpW7E9DfusKyLPLvuHlUyP5zqnmAPhNc6qTRjUQrdTADl0lpPpDVU2/Gg51UlOGHXbdg==", "license": "MIT", "peerDependencies": { - "redux": "^5.0.0" + "react": ">=16.13", + "react-dom": ">=16.13" + }, + "peerDependenciesMeta": { + "react-dom": { + "optional": true + } } }, + "node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "license": "MIT", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/recharts": { + "version": "2.15.4", + "resolved": "https://registry.npmjs.org/recharts/-/recharts-2.15.4.tgz", + "integrity": "sha512-UT/q6fwS3c1dHbXv2uFgYJ9BMFHu3fwnd7AYZaEQhXuYQ4hgsxLvsUXzGdKeZrW5xopzDCvuA2N41WJ88I7zIw==", + "license": "MIT", + "dependencies": { + "clsx": "^2.0.0", + "eventemitter3": "^4.0.1", + "lodash": "^4.17.21", + "react-is": "^18.3.1", + "react-smooth": "^4.0.4", + "recharts-scale": "^0.4.4", + "tiny-invariant": "^1.3.1", + "victory-vendor": "^36.6.8" + }, + "engines": { + "node": ">=14" + }, + "peerDependencies": { + "react": "^16.0.0 || ^17.0.0 || ^18.0.0 || ^19.0.0", + "react-dom": "^16.0.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" + } + }, + "node_modules/recharts-scale": { + "version": "0.4.5", + "resolved": "https://registry.npmjs.org/recharts-scale/-/recharts-scale-0.4.5.tgz", + "integrity": "sha512-kivNFO+0OcUNu7jQquLXAxz1FIwZj8nrj+YkOKc5694NbjCvcT6aSZiIzNzd2Kul4o4rTto8QVR9lMNtxD4G1w==", + "license": "MIT", + "dependencies": { + "decimal.js-light": "^2.4.1" + } + }, + "node_modules/recharts/node_modules/react-is": { + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", + "license": "MIT" + }, "node_modules/reflect.getprototypeof": { "version": "1.0.10", "resolved": "https://registry.npmjs.org/reflect.getprototypeof/-/reflect.getprototypeof-1.0.10.tgz", @@ -12066,39 +7551,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/remark-breaks": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/remark-breaks/-/remark-breaks-4.0.0.tgz", - "integrity": "sha512-IjEjJOkH4FuJvHZVIW0QCDWxcG96kCq7An/KVH2NfJe6rKZU2AsHeB3OEjPNRxi4QC34Xdx7I2KGYn6IpT7gxQ==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-newline-to-break": "^2.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/remark-gfm": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/remark-gfm/-/remark-gfm-4.0.1.tgz", - "integrity": "sha512-1quofZ2RQ9EWdeN34S79+KExV1764+wCUGop5CPL1WGdD0ocPpu91lzPGbwWMECpEpd42kJGQwzRfyov9j4yNg==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-gfm": "^3.0.0", - "micromark-extension-gfm": "^3.0.0", - "remark-parse": "^11.0.0", - "remark-stringify": "^11.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/remark-parse": { "version": "11.0.0", "resolved": "https://registry.npmjs.org/remark-parse/-/remark-parse-11.0.0.tgz", @@ -12132,57 +7584,15 @@ "url": "https://opencollective.com/unified" } }, - "node_modules/remark-stringify": { - "version": "11.0.0", - "resolved": "https://registry.npmjs.org/remark-stringify/-/remark-stringify-11.0.0.tgz", - "integrity": "sha512-1OSmLd3awB/t8qdoEOMazZkNsfVTeY4fTsgzcQFdXNq8ToTN4ZGwrMnlda4K6smTFKD+GRV6O48i6Z4iKgPPpw==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-to-markdown": "^2.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/remeda": { - "version": "2.33.6", - "resolved": "https://registry.npmjs.org/remeda/-/remeda-2.33.6.tgz", - "integrity": "sha512-tazDGH7s75kUPGBKLvhgBEHMgW+TdDFhjUAMdQj57IoWz6HsGa5D2RX5yDUz6IIqiRRvZiaEHzCzWdTeixc/Kg==", - "dev": true, - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/remeda" - } - }, - "node_modules/request-progress": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/request-progress/-/request-progress-3.0.0.tgz", - "integrity": "sha512-MnWzEHHaxHO2iWiQuHrUPBi/1WeBf5PkxQqNyNvLl9VAYSdXkP8tQ3pBSeCPD+yw0v0Aq1zosWLz0BdeXpWwZg==", - "dev": true, - "license": "MIT", - "dependencies": { - "throttleit": "^1.0.0" - } - }, "node_modules/require-from-string": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", - "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" } }, - "node_modules/reselect": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/reselect/-/reselect-5.1.1.tgz", - "integrity": "sha512-K/BG6eIky/SBpzfHZv/dd+9JBFiS4SWV7FIujVyJRux6e45+73RaUHXLmIR1f7WOMaQ0U1km6qwklRQxpJJY0w==", - "license": "MIT" - }, "node_modules/resolve": { "version": "1.22.11", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.11.tgz", @@ -12224,20 +7634,6 @@ "url": "https://github.com/privatenumber/resolve-pkg-maps?sponsor=1" } }, - "node_modules/restore-cursor": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-3.1.0.tgz", - "integrity": "sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA==", - "dev": true, - "license": "MIT", - "dependencies": { - "onetime": "^5.1.0", - "signal-exit": "^3.0.2" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/reusify": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.1.0.tgz", @@ -12249,65 +7645,6 @@ "node": ">=0.10.0" } }, - "node_modules/rfdc": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/rfdc/-/rfdc-1.4.1.tgz", - "integrity": "sha512-q1b3N5QkRUWUl7iyylaaj3kOpIT0N2i9MqIEQXP73GVsN9cw3fdx8X63cEmWhJGi2PPCF23Ijp7ktmd39rawIA==", - "dev": true, - "license": "MIT" - }, - "node_modules/rollup": { - "version": "4.59.0", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.59.0.tgz", - "integrity": "sha512-2oMpl67a3zCH9H79LeMcbDhXW/UmWG/y2zuqnF2jQq5uq9TbM9TVyXvA4+t+ne2IIkBdrLpAaRQAvo7YI/Yyeg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@types/estree": "1.0.8" - }, - "bin": { - "rollup": "dist/bin/rollup" - }, - "engines": { - "node": ">=18.0.0", - "npm": ">=8.0.0" - }, - "optionalDependencies": { - "@rollup/rollup-android-arm-eabi": "4.59.0", - "@rollup/rollup-android-arm64": "4.59.0", - "@rollup/rollup-darwin-arm64": "4.59.0", - "@rollup/rollup-darwin-x64": "4.59.0", - "@rollup/rollup-freebsd-arm64": "4.59.0", - "@rollup/rollup-freebsd-x64": "4.59.0", - "@rollup/rollup-linux-arm-gnueabihf": "4.59.0", - "@rollup/rollup-linux-arm-musleabihf": "4.59.0", - "@rollup/rollup-linux-arm64-gnu": "4.59.0", - "@rollup/rollup-linux-arm64-musl": "4.59.0", - "@rollup/rollup-linux-loong64-gnu": "4.59.0", - "@rollup/rollup-linux-loong64-musl": "4.59.0", - "@rollup/rollup-linux-ppc64-gnu": "4.59.0", - "@rollup/rollup-linux-ppc64-musl": "4.59.0", - "@rollup/rollup-linux-riscv64-gnu": "4.59.0", - "@rollup/rollup-linux-riscv64-musl": "4.59.0", - "@rollup/rollup-linux-s390x-gnu": "4.59.0", - "@rollup/rollup-linux-x64-gnu": "4.59.0", - "@rollup/rollup-linux-x64-musl": "4.59.0", - "@rollup/rollup-openbsd-x64": "4.59.0", - "@rollup/rollup-openharmony-arm64": "4.59.0", - "@rollup/rollup-win32-arm64-msvc": "4.59.0", - "@rollup/rollup-win32-ia32-msvc": "4.59.0", - "@rollup/rollup-win32-x64-gnu": "4.59.0", - "@rollup/rollup-win32-x64-msvc": "4.59.0", - "fsevents": "~2.3.2" - } - }, - "node_modules/rrweb-cssom": { - "version": "0.7.1", - "resolved": "https://registry.npmjs.org/rrweb-cssom/-/rrweb-cssom-0.7.1.tgz", - "integrity": "sha512-TrEMa7JGdVm0UThDJSx7ddw5nVm3UJS9o9CCIZ72B1vSyEZoziDqBYP3XIoi/12lKrJR8rE3jeFHMok2F/Mnsg==", - "dev": true, - "license": "MIT" - }, "node_modules/run-parallel": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", @@ -12332,16 +7669,6 @@ "queue-microtask": "^1.2.2" } }, - "node_modules/rxjs": { - "version": "7.8.2", - "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.8.2.tgz", - "integrity": "sha512-dhKf903U/PQZY6boNNtAGdWbG85WAbjT/1xYoZIC7FAY0yWapOBQVsVrDl58W86//e1VpMNBtRV4MaXfdMySFA==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.1.0" - } - }, "node_modules/safe-array-concat": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.1.3.tgz", @@ -12366,7 +7693,6 @@ "version": "5.2.1", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", - "dev": true, "funding": [ { "type": "github", @@ -12418,26 +7744,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/safer-buffer": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", - "dev": true, - "license": "MIT" - }, - "node_modules/saxes": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/saxes/-/saxes-6.0.0.tgz", - "integrity": "sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA==", - "dev": true, - "license": "ISC", - "dependencies": { - "xmlchars": "^2.2.0" - }, - "engines": { - "node": ">=v12.22.7" - } - }, "node_modules/scheduler": { "version": "0.27.0", "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.27.0.tgz", @@ -12445,24 +7751,15 @@ "license": "MIT" }, "node_modules/semver": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.4.tgz", - "integrity": "sha512-vFKC2IEtQnVhpT78h1Yp8wzwrf8CM+MzKMHGJZfBtzhZNycRFnXsHk6E5TxIkkMsgNS7mdX3AGB7x2QM2di4lA==", - "devOptional": true, + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "dev": true, "license": "ISC", "bin": { "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" } }, - "node_modules/server-only": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/server-only/-/server-only-0.0.1.tgz", - "integrity": "sha512-qepMx2JxAa5jjfzxG79yPPq+8BuFToHd1hm7kI+Z4zAq1ftQiP7HcxMhDDItrbtwVeLg/cY2JnKnrcFkmiswNA==", - "license": "MIT" - }, "node_modules/set-function-length": { "version": "1.2.2", "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", @@ -12557,11 +7854,23 @@ "@img/sharp-win32-x64": "0.34.5" } }, + "node_modules/sharp/node_modules/semver": { + "version": "7.7.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.4.tgz", + "integrity": "sha512-vFKC2IEtQnVhpT78h1Yp8wzwrf8CM+MzKMHGJZfBtzhZNycRFnXsHk6E5TxIkkMsgNS7mdX3AGB7x2QM2di4lA==", + "license": "ISC", + "optional": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/shebang-command": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", - "dev": true, "license": "MIT", "dependencies": { "shebang-regex": "^3.0.0" @@ -12574,7 +7883,6 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", - "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -12656,46 +7964,49 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/siginfo": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/siginfo/-/siginfo-2.0.0.tgz", - "integrity": "sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==", - "dev": true, - "license": "ISC" + "node_modules/simple-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/simple-concat/-/simple-concat-1.0.1.tgz", + "integrity": "sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" }, - "node_modules/signal-exit": { - "version": "3.0.7", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", - "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", - "dev": true, - "license": "ISC" - }, - "node_modules/slash": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/slash/-/slash-5.1.0.tgz", - "integrity": "sha512-ZA6oR3T/pEyuqwMgAKT0/hAv8oAXckzbkmR0UkUosQ+Mc4RxGoJkRmwHgHufaenlyAgE1Mxgpdcrf75y6XcnDg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=14.16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/slice-ansi": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-3.0.0.tgz", - "integrity": "sha512-pSyv7bSTC7ig9Dcgbw9AuRNUb5k5V6oDudjZoMBSr13qpLBG7tB+zgCkARjq7xIUgdz5P1Qe8u+rSGdouOOIyQ==", - "dev": true, + "node_modules/simple-get": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/simple-get/-/simple-get-4.0.1.tgz", + "integrity": "sha512-brv7p5WgH0jmQJr1ZDDfKDOSeWWg+OVypG99A/5vYGPqJ6pxiaHLy8nxtFjBA7oMa01ebA9gfh1uMCFqOuXxvA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], "license": "MIT", "dependencies": { - "ansi-styles": "^4.0.0", - "astral-regex": "^2.0.0", - "is-fullwidth-code-point": "^3.0.0" - }, - "engines": { - "node": ">=8" + "decompress-response": "^6.0.0", + "once": "^1.3.1", + "simple-concat": "^1.0.0" } }, "node_modules/source-map-js": { @@ -12717,32 +8028,6 @@ "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/sshpk": { - "version": "1.18.0", - "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.18.0.tgz", - "integrity": "sha512-2p2KJZTSqQ/I3+HX42EpYOa2l3f8Erv8MWKsy2I9uf4wA7yFIkXRffYdsx86y6z4vHtV8u7g+pPlr8/4ouAxsQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "asn1": "~0.2.3", - "assert-plus": "^1.0.0", - "bcrypt-pbkdf": "^1.0.0", - "dashdash": "^1.12.0", - "ecc-jsbn": "~0.1.1", - "getpass": "^0.1.1", - "jsbn": "~0.1.0", - "safer-buffer": "^2.0.2", - "tweetnacl": "~0.14.0" - }, - "bin": { - "sshpk-conv": "bin/sshpk-conv", - "sshpk-sign": "bin/sshpk-sign", - "sshpk-verify": "bin/sshpk-verify" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/stable-hash": { "version": "0.0.5", "resolved": "https://registry.npmjs.org/stable-hash/-/stable-hash-0.0.5.tgz", @@ -12750,27 +8035,36 @@ "dev": true, "license": "MIT" }, - "node_modules/stackback": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/stackback/-/stackback-0.0.2.tgz", - "integrity": "sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==", - "dev": true, + "node_modules/state-local": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/state-local/-/state-local-1.0.7.tgz", + "integrity": "sha512-HTEHMNieakEnoe33shBYcZ7NX83ACUjCu8c40iOGEZsngj9zRnkqS9j1pqQPXwobB0ZcVTk27REb7COQ0UR59w==", "license": "MIT" }, - "node_modules/standardwebhooks": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/standardwebhooks/-/standardwebhooks-1.0.0.tgz", - "integrity": "sha512-BbHGOQK9olHPMvQNHWul6MYlrRTAOKn03rOe4A8O3CLWhNf4YHBqq2HJKKC+sfqpxiBY52pNeesD6jIiLDz8jg==", + "node_modules/stats-gl": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/stats-gl/-/stats-gl-2.4.2.tgz", + "integrity": "sha512-g5O9B0hm9CvnM36+v7SFl39T7hmAlv541tU81ME8YeSb3i1CIP5/QdDeSB3A0la0bKNHpxpwxOVRo2wFTYEosQ==", "license": "MIT", "dependencies": { - "@stablelib/base64": "^1.0.0", - "fast-sha256": "^1.3.0" + "@types/three": "*", + "three": "^0.170.0" + }, + "peerDependencies": { + "@types/three": "*", + "three": "*" } }, - "node_modules/std-env": { - "version": "3.10.0", - "resolved": "https://registry.npmjs.org/std-env/-/std-env-3.10.0.tgz", - "integrity": "sha512-5GS12FdOZNliM5mAOxFRg7Ir0pWz8MdpYm6AY6VPkGpbA7ZzmbzNcBJQ0GPvvyWgcY7QAhCgf9Uy89I03faLkg==", + "node_modules/stats-gl/node_modules/three": { + "version": "0.170.0", + "resolved": "https://registry.npmjs.org/three/-/three-0.170.0.tgz", + "integrity": "sha512-FQK+LEpYc0fBD+J8g6oSEyyNzjp+Q7Ks1C568WWaoMRLW+TkNNWmenWeGgJjV105Gd+p/2ql1ZcjYvNiPZBhuQ==", + "license": "MIT" + }, + "node_modules/stats.js": { + "version": "0.17.0", + "resolved": "https://registry.npmjs.org/stats.js/-/stats.js-0.17.0.tgz", + "integrity": "sha512-hNKz8phvYLPEcRkeG1rsGmV5ChMjKDAWU7/OJJdDErPBNChQXxCo3WZurGpnWc6gZhAzEPFad1aVgyOANH1sMw==", "license": "MIT" }, "node_modules/stop-iteration-iterator": { @@ -12787,38 +8081,15 @@ "node": ">= 0.4" } }, - "node_modules/string-argv": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/string-argv/-/string-argv-0.3.2.tgz", - "integrity": "sha512-aqD2Q0144Z+/RqG52NeHEkZauTAUWJO8c6yTftGJKO3Tja5tUgIfmIl6kExvhtxSDP7fXB6DvzkfMpCd/F3G+Q==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.6.19" - } - }, - "node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, + "node_modules/string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", "license": "MIT", "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" + "safe-buffer": "~5.2.0" } }, - "node_modules/string-width/node_modules/emoji-regex": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", - "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", - "dev": true, - "license": "MIT" - }, "node_modules/string.prototype.includes": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/string.prototype.includes/-/string.prototype.includes-2.0.1.tgz", @@ -12946,19 +8217,6 @@ "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/strip-bom": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", @@ -12969,29 +8227,6 @@ "node": ">=4" } }, - "node_modules/strip-final-newline": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", - "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/strip-indent": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/strip-indent/-/strip-indent-3.0.0.tgz", - "integrity": "sha512-laJTa3Jb+VQpaC6DseHhF7dXVqHTfJPCRDaEbid/drOhgitgYku/letMUqOXFoWV0zIIUbjpdH2t+tYj4bQMRQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "min-indent": "^1.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/strip-json-comments": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", @@ -13046,53 +8281,17 @@ } } }, - "node_modules/sucrase": { - "version": "3.35.1", - "resolved": "https://registry.npmjs.org/sucrase/-/sucrase-3.35.1.tgz", - "integrity": "sha512-DhuTmvZWux4H1UOnWMB3sk0sbaCVOoQZjv8u1rDoTV0HTdGem9hkAZtl4JZy8P2z4Bg0nT+YMeOFyVr4zcG5Tw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@jridgewell/gen-mapping": "^0.3.2", - "commander": "^4.0.0", - "lines-and-columns": "^1.1.6", - "mz": "^2.7.0", - "pirates": "^4.0.1", - "tinyglobby": "^0.2.11", - "ts-interface-checker": "^0.1.9" - }, - "bin": { - "sucrase": "bin/sucrase", - "sucrase-node": "bin/sucrase-node" - }, - "engines": { - "node": ">=16 || 14 >=14.17" - } - }, - "node_modules/sucrase/node_modules/commander": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-4.1.1.tgz", - "integrity": "sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 6" - } - }, "node_modules/supports-color": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", - "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/supports-color?sponsor=1" + "node": ">=8" } }, "node_modules/supports-preserve-symlinks-flag": { @@ -13108,214 +8307,99 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/swr": { - "version": "2.3.4", - "resolved": "https://registry.npmjs.org/swr/-/swr-2.3.4.tgz", - "integrity": "sha512-bYd2lrhc+VarcpkgWclcUi92wYCpOgMws9Sd1hG1ntAu0NEy+14CbotuFjshBU2kt9rYj9TSmDcybpxpeTU1fg==", + "node_modules/suspend-react": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/suspend-react/-/suspend-react-0.1.3.tgz", + "integrity": "sha512-aqldKgX9aZqpoDp3e8/BZ8Dm7x1pJl+qI3ZKxDN0i/IQTWUwBx/ManmlVJ3wowqbno6c2bmiIfs+Um6LbsjJyQ==", "license": "MIT", - "dependencies": { - "dequal": "^2.0.3", - "use-sync-external-store": "^1.4.0" - }, "peerDependencies": { - "react": "^16.11.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" - } - }, - "node_modules/symbol-tree": { - "version": "3.2.4", - "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz", - "integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==", - "dev": true, - "license": "MIT" - }, - "node_modules/tailwind-merge": { - "version": "3.4.0", - "resolved": "https://registry.npmjs.org/tailwind-merge/-/tailwind-merge-3.4.0.tgz", - "integrity": "sha512-uSaO4gnW+b3Y2aWoWfFpX62vn2sR3skfhbjsEnaBI81WD1wBLlHZe5sWf0AqjksNdYTbGBEd0UasQMT3SNV15g==", - "dev": true, - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/dcastil" + "react": ">=17.0" } }, "node_modules/tailwindcss": { - "version": "3.4.19", - "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-3.4.19.tgz", - "integrity": "sha512-3ofp+LL8E+pK/JuPLPggVAIaEuhvIz4qNcf3nA1Xn2o/7fb7s/TYpHhwGDv1ZU3PkBluUVaF8PyCHcm48cKLWQ==", + "version": "4.1.18", + "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-4.1.18.tgz", + "integrity": "sha512-4+Z+0yiYyEtUVCScyfHCxOYP06L5Ne+JiHhY2IjR2KWMIWhJOYZKLSGZaP5HkZ8+bY0cxfzwDE5uOmzFXyIwxw==", + "license": "MIT" + }, + "node_modules/tapable": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/tapable/-/tapable-2.3.0.tgz", + "integrity": "sha512-g9ljZiwki/LfxmQADO3dEY1CbpmXT5Hm2fJ+QaGKwSXUylMybePR7/67YW7jOrrvjEgL1Fmz5kzyAjWVWLlucg==", "dev": true, "license": "MIT", - "dependencies": { - "@alloc/quick-lru": "^5.2.0", - "arg": "^5.0.2", - "chokidar": "^3.6.0", - "didyoumean": "^1.2.2", - "dlv": "^1.1.3", - "fast-glob": "^3.3.2", - "glob-parent": "^6.0.2", - "is-glob": "^4.0.3", - "jiti": "^1.21.7", - "lilconfig": "^3.1.3", - "micromatch": "^4.0.8", - "normalize-path": "^3.0.0", - "object-hash": "^3.0.0", - "picocolors": "^1.1.1", - "postcss": "^8.4.47", - "postcss-import": "^15.1.0", - "postcss-js": "^4.0.1", - "postcss-load-config": "^4.0.2 || ^5.0 || ^6.0", - "postcss-nested": "^6.2.0", - "postcss-selector-parser": "^6.1.2", - "resolve": "^1.22.8", - "sucrase": "^3.35.0" - }, - "bin": { - "tailwind": "lib/cli.js", - "tailwindcss": "lib/cli.js" - }, "engines": { - "node": ">=14.0.0" + "node": ">=6" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" } }, - "node_modules/tailwindcss-animate": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/tailwindcss-animate/-/tailwindcss-animate-1.0.7.tgz", - "integrity": "sha512-bl6mpH3T7I3UFxuvDEXLxy/VuFxBk5bbzplh7tXI68mwMokNYd1t9qPBHlnyTwfa4JGC4zP516I1hYYtQ/vspA==", - "dev": true, + "node_modules/tar-fs": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.4.tgz", + "integrity": "sha512-mDAjwmZdh7LTT6pNleZ05Yt65HC3E+NiQzl672vQG38jIrehtJk/J3mNwIg+vShQPcLF/LV7CMnDW6vjj6sfYQ==", + "license": "MIT", + "dependencies": { + "chownr": "^1.1.1", + "mkdirp-classic": "^0.5.2", + "pump": "^3.0.0", + "tar-stream": "^2.1.4" + } + }, + "node_modules/tar-stream": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-2.2.0.tgz", + "integrity": "sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==", + "license": "MIT", + "dependencies": { + "bl": "^4.0.3", + "end-of-stream": "^1.4.1", + "fs-constants": "^1.0.0", + "inherits": "^2.0.3", + "readable-stream": "^3.1.1" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/three": { + "version": "0.183.0", + "resolved": "https://registry.npmjs.org/three/-/three-0.183.0.tgz", + "integrity": "sha512-G6SH2jfefIVa2YI4JL2VbgQhrrbp1A8dRc7lr3PW827kdVyaX2RgH6M5FmjmdVFLgSHppyg3OYOZdTfWElle+g==", + "license": "MIT" + }, + "node_modules/three-mesh-bvh": { + "version": "0.8.3", + "resolved": "https://registry.npmjs.org/three-mesh-bvh/-/three-mesh-bvh-0.8.3.tgz", + "integrity": "sha512-4G5lBaF+g2auKX3P0yqx+MJC6oVt6sB5k+CchS6Ob0qvH0YIhuUk1eYr7ktsIpY+albCqE80/FVQGV190PmiAg==", "license": "MIT", "peerDependencies": { - "tailwindcss": ">=3.0.0 || insiders" + "three": ">= 0.159.0" } }, - "node_modules/tailwindcss/node_modules/chokidar": { - "version": "3.6.0", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.6.0.tgz", - "integrity": "sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==", - "dev": true, + "node_modules/three-stdlib": { + "version": "2.36.1", + "resolved": "https://registry.npmjs.org/three-stdlib/-/three-stdlib-2.36.1.tgz", + "integrity": "sha512-XyGQrFmNQ5O/IoKm556ftwKsBg11TIb301MB5dWNicziQBEs2g3gtOYIf7pFiLa0zI2gUwhtCjv9fmjnxKZ1Cg==", "license": "MIT", "dependencies": { - "anymatch": "~3.1.2", - "braces": "~3.0.2", - "glob-parent": "~5.1.2", - "is-binary-path": "~2.1.0", - "is-glob": "~4.0.1", - "normalize-path": "~3.0.0", - "readdirp": "~3.6.0" + "@types/draco3d": "^1.4.0", + "@types/offscreencanvas": "^2019.6.4", + "@types/webxr": "^0.5.2", + "draco3d": "^1.4.1", + "fflate": "^0.6.9", + "potpack": "^1.0.1" }, - "engines": { - "node": ">= 8.10.0" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - }, - "optionalDependencies": { - "fsevents": "~2.3.2" + "peerDependencies": { + "three": ">=0.128.0" } }, - "node_modules/tailwindcss/node_modules/chokidar/node_modules/glob-parent": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", - "dev": true, - "license": "ISC", - "dependencies": { - "is-glob": "^4.0.1" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/tailwindcss/node_modules/fast-glob": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.3.tgz", - "integrity": "sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@nodelib/fs.stat": "^2.0.2", - "@nodelib/fs.walk": "^1.2.3", - "glob-parent": "^5.1.2", - "merge2": "^1.3.0", - "micromatch": "^4.0.8" - }, - "engines": { - "node": ">=8.6.0" - } - }, - "node_modules/tailwindcss/node_modules/fast-glob/node_modules/glob-parent": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", - "dev": true, - "license": "ISC", - "dependencies": { - "is-glob": "^4.0.1" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/tailwindcss/node_modules/jiti": { - "version": "1.21.7", - "resolved": "https://registry.npmjs.org/jiti/-/jiti-1.21.7.tgz", - "integrity": "sha512-/imKNG4EbWNrVjoNC/1H5/9GFy+tqjGBHCaSsN+P2RnPqjsLmv6UD3Ej+Kj8nBWaRAwyk7kK5ZUc+OEatnTR3A==", - "dev": true, - "license": "MIT", - "bin": { - "jiti": "bin/jiti.js" - } - }, - "node_modules/tailwindcss/node_modules/readdirp": { - "version": "3.6.0", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", - "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", - "dev": true, - "license": "MIT", - "dependencies": { - "picomatch": "^2.2.1" - }, - "engines": { - "node": ">=8.10.0" - } - }, - "node_modules/thenify": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/thenify/-/thenify-3.3.1.tgz", - "integrity": "sha512-RVZSIV5IG10Hk3enotrhvz0T9em6cyHBLkH/YAZuKqd8hRkKhSfCGIcP2KUY0EPxndzANBmNllzWPwak+bheSw==", - "dev": true, - "license": "MIT", - "dependencies": { - "any-promise": "^1.0.0" - } - }, - "node_modules/thenify-all": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/thenify-all/-/thenify-all-1.6.0.tgz", - "integrity": "sha512-RNxQH/qI8/t3thXJDwcstUO4zeqo64+Uy/+sNVRBx4Xn2OX+OZ9oP+iJnNFqplFra2ZUVeKCSa2oVWi3T4uVmA==", - "dev": true, - "license": "MIT", - "dependencies": { - "thenify": ">= 3.1.0 < 4" - }, - "engines": { - "node": ">=0.8" - } - }, - "node_modules/throttleit": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/throttleit/-/throttleit-1.0.1.tgz", - "integrity": "sha512-vDZpf9Chs9mAdfY046mcPt8fg5QSZr37hEH4TXYBnDF+izxgrbRGUAAaBvIk/fJm9aOFCGFd1EsNg5AZCbnQCQ==", - "dev": true, - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/through": { - "version": "2.3.8", - "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", - "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==", - "dev": true, + "node_modules/three-stdlib/node_modules/fflate": { + "version": "0.6.10", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.6.10.tgz", + "integrity": "sha512-IQrh3lEPM93wVCEczc9SaAOvkmcoQn/G8Bo1e8ZPlY3X3bnAxWaBdvTdvM1hP62iZp0BXWDy4vTAy4fF0+Dlpg==", "license": "MIT" }, "node_modules/tiny-invariant": { @@ -13324,23 +8408,6 @@ "integrity": "sha512-+FbBPE1o9QAYvviau/qC5SE3caw21q3xkvWKBtja5vgqOWIHHJ3ioaq1VPfn/Szqctz2bU/oYeKd9/z5BL+PVg==", "license": "MIT" }, - "node_modules/tinybench": { - "version": "2.9.0", - "resolved": "https://registry.npmjs.org/tinybench/-/tinybench-2.9.0.tgz", - "integrity": "sha512-0+DUvqWMValLmha6lr4kD8iAMK1HzV0/aKnCtWb9v9641TnP/MFb7Pc2bxoxQjTXAErryXVgUOfv2YqNllqGeg==", - "dev": true, - "license": "MIT" - }, - "node_modules/tinyexec": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/tinyexec/-/tinyexec-1.0.2.tgz", - "integrity": "sha512-W/KYk+NFhkmsYpuHq5JykngiOCnxeVL8v8dFnqxSD8qEEdRfXk1SDM6JzNqcERbcGYj9tMrDQBYV9cjgnunFIg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - } - }, "node_modules/tinyglobby": { "version": "0.2.15", "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.15.tgz", @@ -13377,9 +8444,9 @@ } }, "node_modules/tinyglobby/node_modules/picomatch": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.4.tgz", - "integrity": "sha512-QP88BAKvMam/3NxH6vj2o21R6MjxZUAd6nlwAS/pnGvN9IVLocLHxGYIzFhg6fUQ+5th6P4dv4eW9jX3DSIj7A==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", "engines": { @@ -13389,46 +8456,6 @@ "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/tinyrainbow": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/tinyrainbow/-/tinyrainbow-3.0.3.tgz", - "integrity": "sha512-PSkbLUoxOFRzJYjjxHJt9xro7D+iilgMX/C9lawzVuYiIdcihh9DXmVibBe8lmcFrRi/VzlPjBxbN7rH24q8/Q==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/tldts": { - "version": "6.1.86", - "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.86.tgz", - "integrity": "sha512-WMi/OQ2axVTf/ykqCQgXiIct+mSQDFdH2fkwhPwgEwvJ1kSzZRiinb0zF2Xb8u4+OqPChmyI6MEu4EezNJz+FQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "tldts-core": "^6.1.86" - }, - "bin": { - "tldts": "bin/cli.js" - } - }, - "node_modules/tldts-core": { - "version": "6.1.86", - "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.86.tgz", - "integrity": "sha512-Je6p7pkk+KMzMv2XXKmAE3McmolOQFdxkKw0R8EYNr7sELW46JqnNeTX8ybPiQgvg1ymCoF8LXs5fzFaZvJPTA==", - "dev": true, - "license": "MIT" - }, - "node_modules/tmp": { - "version": "0.2.5", - "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.2.5.tgz", - "integrity": "sha512-voyz6MApa1rQGUxT3E+BK7/ROe8itEx7vD8/HEvt4xwXucvQ5G5oeEiHkmHZJuBO21RpOf+YYm9MOivj709jow==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=14.14" - } - }, "node_modules/to-regex-range": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", @@ -13442,42 +8469,6 @@ "node": ">=8.0" } }, - "node_modules/tough-cookie": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-5.1.2.tgz", - "integrity": "sha512-FVDYdxtnj0G6Qm/DhNPSb8Ju59ULcup3tuJxkFb5K8Bv2pUXILbf0xZWU8PX8Ov19OXljbUyveOFwRMwkXzO+A==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "tldts": "^6.1.32" - }, - "engines": { - "node": ">=16" - } - }, - "node_modules/tr46": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/tr46/-/tr46-5.1.1.tgz", - "integrity": "sha512-hdF5ZgjTqgAntKkklYw0R03MG2x/bSzTtkxmIRw/sTNV8YXsCJ1tfLAX23lhxhHJlEf3CRCOCGGWw3vI3GaSPw==", - "dev": true, - "license": "MIT", - "dependencies": { - "punycode": "^2.3.1" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/tree-kill": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/tree-kill/-/tree-kill-1.2.2.tgz", - "integrity": "sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==", - "dev": true, - "license": "MIT", - "bin": { - "tree-kill": "cli.js" - } - }, "node_modules/trim-lines": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/trim-lines/-/trim-lines-3.0.1.tgz", @@ -13488,6 +8479,36 @@ "url": "https://github.com/sponsors/wooorm" } }, + "node_modules/troika-three-text": { + "version": "0.52.4", + "resolved": "https://registry.npmjs.org/troika-three-text/-/troika-three-text-0.52.4.tgz", + "integrity": "sha512-V50EwcYGruV5rUZ9F4aNsrytGdKcXKALjEtQXIOBfhVoZU9VAqZNIoGQ3TMiooVqFAbR1w15T+f+8gkzoFzawg==", + "license": "MIT", + "dependencies": { + "bidi-js": "^1.0.2", + "troika-three-utils": "^0.52.4", + "troika-worker-utils": "^0.52.0", + "webgl-sdf-generator": "1.1.1" + }, + "peerDependencies": { + "three": ">=0.125.0" + } + }, + "node_modules/troika-three-utils": { + "version": "0.52.4", + "resolved": "https://registry.npmjs.org/troika-three-utils/-/troika-three-utils-0.52.4.tgz", + "integrity": "sha512-NORAStSVa/BDiG52Mfudk4j1FG4jC4ILutB3foPnfGbOeIs9+G5vZLa0pnmnaftZUGm4UwSoqEpWdqvC7zms3A==", + "license": "MIT", + "peerDependencies": { + "three": ">=0.125.0" + } + }, + "node_modules/troika-worker-utils": { + "version": "0.52.0", + "resolved": "https://registry.npmjs.org/troika-worker-utils/-/troika-worker-utils-0.52.0.tgz", + "integrity": "sha512-W1CpvTHykaPH5brv5VHLfQo9D1OYuo0cSBEUQFFT/nBUzM8iD6Lq2/tgG/f1OelbAS1WtaTPQzE5uM49egnngw==", + "license": "MIT" + }, "node_modules/trough": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/trough/-/trough-2.2.0.tgz", @@ -13511,34 +8532,6 @@ "typescript": ">=4.8.4" } }, - "node_modules/ts-interface-checker": { - "version": "0.1.13", - "resolved": "https://registry.npmjs.org/ts-interface-checker/-/ts-interface-checker-0.1.13.tgz", - "integrity": "sha512-Y/arvbn+rrz3JCKl9C4kVNfTfSm2/mEp5FSz5EsZSANGPSlQrpRI5M4PKF+mJnE52jOO90PnPSc3Ur3bTQw0gA==", - "dev": true, - "license": "Apache-2.0" - }, - "node_modules/tsconfck": { - "version": "3.1.6", - "resolved": "https://registry.npmjs.org/tsconfck/-/tsconfck-3.1.6.tgz", - "integrity": "sha512-ks6Vjr/jEw0P1gmOVwutM3B7fWxoWBL2KRDb1JfqGVawBmO5UsvmWOQFGHBPl5yxYz4eERr19E6L7NMv+Fej4w==", - "dev": true, - "license": "MIT", - "bin": { - "tsconfck": "bin/tsconfck.js" - }, - "engines": { - "node": "^18 || >=20" - }, - "peerDependencies": { - "typescript": "^5.0.0" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } - } - }, "node_modules/tsconfig-paths": { "version": "3.15.0", "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.15.0.tgz", @@ -13575,7 +8568,6 @@ "version": "0.6.0", "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", "integrity": "sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==", - "dev": true, "license": "Apache-2.0", "dependencies": { "safe-buffer": "^5.0.1" @@ -13584,12 +8576,42 @@ "node": "*" } }, - "node_modules/tweetnacl": { - "version": "0.14.5", - "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", - "integrity": "sha512-KXXFFdAbFXY4geFIwoyNK+f5Z1b7swfXABfL7HXCmoIWMKU3dmS26672A4EeQtDzLKy7SXmfBu51JolvEKwtGA==", - "dev": true, - "license": "Unlicense" + "node_modules/tunnel-rat": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/tunnel-rat/-/tunnel-rat-0.1.2.tgz", + "integrity": "sha512-lR5VHmkPhzdhrM092lI2nACsLO4QubF0/yoOhzX7c+wIpbN1GjHNzCc91QlpxBi+cnx8vVJ+Ur6vL5cEoQPFpQ==", + "license": "MIT", + "dependencies": { + "zustand": "^4.3.2" + } + }, + "node_modules/tunnel-rat/node_modules/zustand": { + "version": "4.5.7", + "resolved": "https://registry.npmjs.org/zustand/-/zustand-4.5.7.tgz", + "integrity": "sha512-CHOUy7mu3lbD6o6LJLfllpjkzhHXSBlX8B9+qPddUsIfeF5S/UZ5q0kmCsnRqT1UHFQZchNFDDzMbQsuesHWlw==", + "license": "MIT", + "dependencies": { + "use-sync-external-store": "^1.2.2" + }, + "engines": { + "node": ">=12.7.0" + }, + "peerDependencies": { + "@types/react": ">=16.8", + "immer": ">=9.0.6", + "react": ">=16.8" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "immer": { + "optional": true + }, + "react": { + "optional": true + } + } }, "node_modules/type-check": { "version": "0.4.0", @@ -13604,16 +8626,6 @@ "node": ">= 0.8.0" } }, - "node_modules/type-fest": { - "version": "0.8.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", - "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", - "dev": true, - "license": "(MIT OR CC0-1.0)", - "engines": { - "node": ">=8" - } - }, "node_modules/typed-array-buffer": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.3.tgz", @@ -13692,82 +8704,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/typedoc": { - "version": "0.28.16", - "resolved": "https://registry.npmjs.org/typedoc/-/typedoc-0.28.16.tgz", - "integrity": "sha512-x4xW77QC3i5DUFMBp0qjukOTnr/sSg+oEs86nB3LjDslvAmwe/PUGDWbe3GrIqt59oTqoXK5GRK9tAa0sYMiog==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@gerrit0/mini-shiki": "^3.17.0", - "lunr": "^2.3.9", - "markdown-it": "^14.1.0", - "minimatch": "^9.0.5", - "yaml": "^2.8.1" - }, - "bin": { - "typedoc": "bin/typedoc" - }, - "engines": { - "node": ">= 18", - "pnpm": ">= 10" - }, - "peerDependencies": { - "typescript": "5.0.x || 5.1.x || 5.2.x || 5.3.x || 5.4.x || 5.5.x || 5.6.x || 5.7.x || 5.8.x || 5.9.x" - } - }, - "node_modules/typedoc-plugin-coverage": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/typedoc-plugin-coverage/-/typedoc-plugin-coverage-4.0.2.tgz", - "integrity": "sha512-mfn0e7NCqB8x2PfvhXrtmd7KWlsNf1+B2N9y8gR/jexXBLrXl/0e+b2HdG5HaTXGi7i0t2pyQY2VRmq7gtdEHQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 18" - }, - "peerDependencies": { - "typedoc": "0.28.x" - } - }, - "node_modules/typedoc-plugin-markdown": { - "version": "4.10.0", - "resolved": "https://registry.npmjs.org/typedoc-plugin-markdown/-/typedoc-plugin-markdown-4.10.0.tgz", - "integrity": "sha512-psrg8Rtnv4HPWCsoxId+MzEN8TVK5jeKCnTbnGAbTBqcDapR9hM41bJT/9eAyKn9C2MDG9Qjh3MkltAYuLDoXg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 18" - }, - "peerDependencies": { - "typedoc": "0.28.x" - } - }, - "node_modules/typedoc/node_modules/brace-expansion": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.2.tgz", - "integrity": "sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0" - } - }, - "node_modules/typedoc/node_modules/minimatch": { - "version": "9.0.9", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.9.tgz", - "integrity": "sha512-OBwBN9AL4dqmETlpS2zasx+vTeWclWzkblfZk7KTA5j3jeOONz/tRCnZomUyvNg83wL5Zv9Ss6HMJXAgL8R2Yg==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^2.0.2" - }, - "engines": { - "node": ">=16 || 14 >=14.17" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, "node_modules/typescript": { "version": "5.9.3", "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz", @@ -13783,16 +8719,16 @@ } }, "node_modules/typescript-eslint": { - "version": "8.55.0", - "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.55.0.tgz", - "integrity": "sha512-HE4wj+r5lmDVS9gdaN0/+iqNvPZwGfnJ5lZuz7s5vLlg9ODw0bIiiETaios9LvFI1U94/VBXGm3CB2Y5cNFMpw==", + "version": "8.54.0", + "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.54.0.tgz", + "integrity": "sha512-CKsJ+g53QpsNPqbzUsfKVgd3Lny4yKZ1pP4qN3jdMOg/sisIDLGyDMezycquXLE5JsEU0wp3dGNdzig0/fmSVQ==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/eslint-plugin": "8.55.0", - "@typescript-eslint/parser": "8.55.0", - "@typescript-eslint/typescript-estree": "8.55.0", - "@typescript-eslint/utils": "8.55.0" + "@typescript-eslint/eslint-plugin": "8.54.0", + "@typescript-eslint/parser": "8.54.0", + "@typescript-eslint/typescript-estree": "8.54.0", + "@typescript-eslint/utils": "8.54.0" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -13806,13 +8742,6 @@ "typescript": ">=4.8.4 <6.0.0" } }, - "node_modules/uc.micro": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-2.1.0.tgz", - "integrity": "sha512-ARDJmphmdvUk6Glw7y9DQ2bFkKBHwQHLi2lsaH6PPmz/Ka9sFOBsBluozhDltWmnv9u/cF6Rt87znRTPV+yp/A==", - "dev": true, - "license": "MIT" - }, "node_modules/unbox-primitive": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.1.0.tgz", @@ -13836,22 +8765,8 @@ "version": "6.21.0", "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", - "dev": true, "license": "MIT" }, - "node_modules/unicorn-magic": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/unicorn-magic/-/unicorn-magic-0.4.0.tgz", - "integrity": "sha512-wH590V9VNgYH9g3lH9wWjTrUoKsjLF6sGLjhR4sH1LWpLmCOH0Zf7PukhDA8BiS7KHe4oPNkcTHqYkj7SOGUOw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=20" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/unified": { "version": "11.0.5", "resolved": "https://registry.npmjs.org/unified/-/unified-11.0.5.tgz", @@ -13939,16 +8854,6 @@ "url": "https://opencollective.com/unified" } }, - "node_modules/universalify": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", - "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 10.0.0" - } - }, "node_modules/unrs-resolver": { "version": "1.11.1", "resolved": "https://registry.npmjs.org/unrs-resolver/-/unrs-resolver-1.11.1.tgz", @@ -13984,16 +8889,6 @@ "@unrs/resolver-binding-win32-x64-msvc": "1.11.1" } }, - "node_modules/untildify": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/untildify/-/untildify-4.0.0.tgz", - "integrity": "sha512-KK8xQ1mkzZeg9inewmFVDNkg3l5LUhoq9kN6iWYB/CC9YMG8HA+c1Q8HwDe6dEX7kErrEVNVBO3fWsVq5iDgtw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, "node_modules/update-browserslist-db": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.2.3.tgz", @@ -14035,49 +8930,6 @@ "punycode": "^2.1.0" } }, - "node_modules/use-callback-ref": { - "version": "1.3.3", - "resolved": "https://registry.npmjs.org/use-callback-ref/-/use-callback-ref-1.3.3.tgz", - "integrity": "sha512-jQL3lRnocaFtu3V00JToYz/4QkNWswxijDaCVNZRiRTO3HQDLsdu1ZtmIUvV4yPp+rvWm5j0y0TG/S61cuijTg==", - "license": "MIT", - "dependencies": { - "tslib": "^2.0.0" - }, - "engines": { - "node": ">=10" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/use-sidecar": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/use-sidecar/-/use-sidecar-1.1.3.tgz", - "integrity": "sha512-Fedw0aZvkhynoPYlA5WXrMCAMm+nSWdZt6lzJQ7Ok8S6Q+VsHmHpRWndVRJ8Be0ZbkfPc5LRYH+5XrzXcEeLRQ==", - "license": "MIT", - "dependencies": { - "detect-node-es": "^1.1.0", - "tslib": "^2.0.0" - }, - "engines": { - "node": ">=10" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, "node_modules/use-sync-external-store": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.6.0.tgz", @@ -14091,32 +8943,15 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", - "dev": true, "license": "MIT" }, - "node_modules/uuid": { - "version": "8.3.2", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", - "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==", - "dev": true, + "node_modules/utility-types": { + "version": "3.11.0", + "resolved": "https://registry.npmjs.org/utility-types/-/utility-types-3.11.0.tgz", + "integrity": "sha512-6Z7Ma2aVEWisaL6TvBCy7P8rm2LQoPv6dJ7ecIaIixHcwfbJ0x7mWdbcwlIM5IGQxPZSFYeqRCqlOOeKoJYMkw==", "license": "MIT", - "bin": { - "uuid": "dist/bin/uuid" - } - }, - "node_modules/verror": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", - "integrity": "sha512-ZZKSmDAEFOijERBLkmYfJ+vmk3w+7hOLYDNkRCuRuMJGEmqYNCNLyBBFwWKVMhfwaEF3WOd0Zlw86U/WC/+nYw==", - "dev": true, - "engines": [ - "node >=0.6.0" - ], - "license": "MIT", - "dependencies": { - "assert-plus": "^1.0.0", - "core-util-is": "1.0.2", - "extsprintf": "^1.2.0" + "engines": { + "node": ">= 4" } }, "node_modules/vfile": { @@ -14148,9 +8983,9 @@ } }, "node_modules/victory-vendor": { - "version": "37.3.6", - "resolved": "https://registry.npmjs.org/victory-vendor/-/victory-vendor-37.3.6.tgz", - "integrity": "sha512-SbPDPdDBYp+5MJHhBCAyI7wKM3d5ivekigc2Dk2s7pgbZ9wIgIBYGVw4zGHBml/qTFbexrofXW6Gu4noGxrOwQ==", + "version": "36.9.2", + "resolved": "https://registry.npmjs.org/victory-vendor/-/victory-vendor-36.9.2.tgz", + "integrity": "sha512-PnpQQMuxlwYdocC8fIJqVXvkeViHYzotI+NJrCuav0ZYFoq912ZHBk3mCeuj+5/VpodOjPe1z0Fk2ihgzlXqjQ==", "license": "MIT AND ISC", "dependencies": { "@types/d3-array": "^3.0.3", @@ -14169,269 +9004,21 @@ "d3-timer": "^3.0.1" } }, - "node_modules/vite": { - "version": "7.3.1", - "resolved": "https://registry.npmjs.org/vite/-/vite-7.3.1.tgz", - "integrity": "sha512-w+N7Hifpc3gRjZ63vYBXA56dvvRlNWRczTdmCBBa+CotUzAPf5b7YMdMR/8CQoeYE5LX3W4wj6RYTgonm1b9DA==", - "dev": true, - "license": "MIT", - "dependencies": { - "esbuild": "^0.27.0", - "fdir": "^6.5.0", - "picomatch": "^4.0.3", - "postcss": "^8.5.6", - "rollup": "^4.43.0", - "tinyglobby": "^0.2.15" - }, - "bin": { - "vite": "bin/vite.js" - }, - "engines": { - "node": "^20.19.0 || >=22.12.0" - }, - "funding": { - "url": "https://github.com/vitejs/vite?sponsor=1" - }, - "optionalDependencies": { - "fsevents": "~2.3.3" - }, - "peerDependencies": { - "@types/node": "^20.19.0 || >=22.12.0", - "jiti": ">=1.21.0", - "less": "^4.0.0", - "lightningcss": "^1.21.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 - }, - "jiti": { - "optional": true - }, - "less": { - "optional": true - }, - "lightningcss": { - "optional": true - }, - "sass": { - "optional": true - }, - "sass-embedded": { - "optional": true - }, - "stylus": { - "optional": true - }, - "sugarss": { - "optional": true - }, - "terser": { - "optional": true - }, - "tsx": { - "optional": true - }, - "yaml": { - "optional": true - } - } + "node_modules/webgl-constants": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/webgl-constants/-/webgl-constants-1.1.1.tgz", + "integrity": "sha512-LkBXKjU5r9vAW7Gcu3T5u+5cvSvh5WwINdr0C+9jpzVB41cjQAP5ePArDtk/WHYdVj0GefCgM73BA7FlIiNtdg==" }, - "node_modules/vite/node_modules/fdir": { - "version": "6.5.0", - "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.5.0.tgz", - "integrity": "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12.0.0" - }, - "peerDependencies": { - "picomatch": "^3 || ^4" - }, - "peerDependenciesMeta": { - "picomatch": { - "optional": true - } - } - }, - "node_modules/vite/node_modules/picomatch": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.4.tgz", - "integrity": "sha512-QP88BAKvMam/3NxH6vj2o21R6MjxZUAd6nlwAS/pnGvN9IVLocLHxGYIzFhg6fUQ+5th6P4dv4eW9jX3DSIj7A==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/jonschlinkert" - } - }, - "node_modules/vitest": { - "version": "4.0.18", - "resolved": "https://registry.npmjs.org/vitest/-/vitest-4.0.18.tgz", - "integrity": "sha512-hOQuK7h0FGKgBAas7v0mSAsnvrIgAvWmRFjmzpJ7SwFHH3g1k2u37JtYwOwmEKhK6ZO3v9ggDBBm0La1LCK4uQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@vitest/expect": "4.0.18", - "@vitest/mocker": "4.0.18", - "@vitest/pretty-format": "4.0.18", - "@vitest/runner": "4.0.18", - "@vitest/snapshot": "4.0.18", - "@vitest/spy": "4.0.18", - "@vitest/utils": "4.0.18", - "es-module-lexer": "^1.7.0", - "expect-type": "^1.2.2", - "magic-string": "^0.30.21", - "obug": "^2.1.1", - "pathe": "^2.0.3", - "picomatch": "^4.0.3", - "std-env": "^3.10.0", - "tinybench": "^2.9.0", - "tinyexec": "^1.0.2", - "tinyglobby": "^0.2.15", - "tinyrainbow": "^3.0.3", - "vite": "^6.0.0 || ^7.0.0", - "why-is-node-running": "^2.3.0" - }, - "bin": { - "vitest": "vitest.mjs" - }, - "engines": { - "node": "^20.0.0 || ^22.0.0 || >=24.0.0" - }, - "funding": { - "url": "https://opencollective.com/vitest" - }, - "peerDependencies": { - "@edge-runtime/vm": "*", - "@opentelemetry/api": "^1.9.0", - "@types/node": "^20.0.0 || ^22.0.0 || >=24.0.0", - "@vitest/browser-playwright": "4.0.18", - "@vitest/browser-preview": "4.0.18", - "@vitest/browser-webdriverio": "4.0.18", - "@vitest/ui": "4.0.18", - "happy-dom": "*", - "jsdom": "*" - }, - "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/ui": { - "optional": true - }, - "happy-dom": { - "optional": true - }, - "jsdom": { - "optional": true - } - } - }, - "node_modules/vitest/node_modules/picomatch": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.4.tgz", - "integrity": "sha512-QP88BAKvMam/3NxH6vj2o21R6MjxZUAd6nlwAS/pnGvN9IVLocLHxGYIzFhg6fUQ+5th6P4dv4eW9jX3DSIj7A==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/jonschlinkert" - } - }, - "node_modules/w3c-xmlserializer": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/w3c-xmlserializer/-/w3c-xmlserializer-5.0.0.tgz", - "integrity": "sha512-o8qghlI8NZHU1lLPrpi2+Uq7abh4GGPpYANlalzWxyWteJOCsr/P+oPBA49TOLu5FTZO4d3F9MnWJfiMo4BkmA==", - "dev": true, - "license": "MIT", - "dependencies": { - "xml-name-validator": "^5.0.0" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/webidl-conversions": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", - "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", - "dev": true, - "license": "BSD-2-Clause", - "engines": { - "node": ">=12" - } - }, - "node_modules/whatwg-encoding": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-3.1.1.tgz", - "integrity": "sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==", - "deprecated": "Use @exodus/bytes instead for a more spec-conformant and faster implementation", - "dev": true, - "license": "MIT", - "dependencies": { - "iconv-lite": "0.6.3" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/whatwg-mimetype": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-4.0.0.tgz", - "integrity": "sha512-QaKxh0eNIi2mE9p2vEdzfagOKHCcj1pJ56EEHGQOVxp8r9/iszLUUV7v89x9O1p/T+NlTM5W7jW6+cz4Fq1YVg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - } - }, - "node_modules/whatwg-url": { - "version": "14.2.0", - "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-14.2.0.tgz", - "integrity": "sha512-De72GdQZzNTUBBChsXueQUnPKDkg/5A5zp7pFDuQAj5UFoENpiACU0wlCvzpAGnTkj++ihpKwKyYewn/XNUbKw==", - "dev": true, - "license": "MIT", - "dependencies": { - "tr46": "^5.1.0", - "webidl-conversions": "^7.0.0" - }, - "engines": { - "node": ">=18" - } + "node_modules/webgl-sdf-generator": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/webgl-sdf-generator/-/webgl-sdf-generator-1.1.1.tgz", + "integrity": "sha512-9Z0JcMTFxeE+b2x1LJTdnaT8rT8aEp7MVxkNwoycNmJWwPdzoXzMh0BjJSh/AEFP+KPYZUli814h8bJZFIZ2jA==", + "license": "MIT" }, "node_modules/which": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "dev": true, "license": "ISC", "dependencies": { "isexe": "^2.0.0" @@ -14532,23 +9119,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/why-is-node-running": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/why-is-node-running/-/why-is-node-running-2.3.0.tgz", - "integrity": "sha512-hUrmaWBdVDcxvYqnyh09zunKzROWjbZTiNy8dBEjkS7ehEDQibXJ7XvlmtbwuTclUiIyN+CyXQD4Vmko8fNm8w==", - "dev": true, - "license": "MIT", - "dependencies": { - "siginfo": "^2.0.0", - "stackback": "0.0.2" - }, - "bin": { - "why-is-node-running": "cli.js" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/word-wrap": { "version": "1.2.5", "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.5.tgz", @@ -14559,70 +9129,12 @@ "node": ">=0.10.0" } }, - "node_modules/wrap-ansi": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", - "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, "node_modules/wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", - "dev": true, "license": "ISC" }, - "node_modules/ws": { - "version": "8.19.0", - "resolved": "https://registry.npmjs.org/ws/-/ws-8.19.0.tgz", - "integrity": "sha512-blAT2mjOEIi0ZzruJfIhb3nps74PRWTCz1IjglWEEpQl5XS/UNama6u2/rjFkDDouqr4L67ry+1aGIALViWjDg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10.0.0" - }, - "peerDependencies": { - "bufferutil": "^4.0.1", - "utf-8-validate": ">=5.0.2" - }, - "peerDependenciesMeta": { - "bufferutil": { - "optional": true - }, - "utf-8-validate": { - "optional": true - } - } - }, - "node_modules/xml-name-validator": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-5.0.0.tgz", - "integrity": "sha512-EvGK8EJ3DhaHfbRlETOWAS5pO9MZITeauHKJyb8wyajUfQUenkIg2MvLDTZ4T/TgIcm3HU0TFBgWWboAZ30UHg==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=18" - } - }, - "node_modules/xmlchars": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/xmlchars/-/xmlchars-2.2.0.tgz", - "integrity": "sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw==", - "dev": true, - "license": "MIT" - }, "node_modules/yallist": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", @@ -14630,33 +9142,6 @@ "dev": true, "license": "ISC" }, - "node_modules/yaml": { - "version": "2.8.2", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.8.2.tgz", - "integrity": "sha512-mplynKqc1C2hTVYxd0PU2xQAc22TI1vShAYGksCCfxbn/dFwnHTNi1bvYsBTkhdUNtGIf5xNOg938rrSSYvS9A==", - "dev": true, - "license": "ISC", - "bin": { - "yaml": "bin.mjs" - }, - "engines": { - "node": ">= 14.6" - }, - "funding": { - "url": "https://github.com/sponsors/eemeli" - } - }, - "node_modules/yauzl": { - "version": "2.10.0", - "resolved": "https://registry.npmjs.org/yauzl/-/yauzl-2.10.0.tgz", - "integrity": "sha512-p4a9I6X6nu6IhoGmBqAcbJy1mlC4j27vEPZX9F4L4/vZT3Lyq1VkFHw/V/PUcB9Buo+DG3iHkT0x3Qya58zc3g==", - "dev": true, - "license": "MIT", - "dependencies": { - "buffer-crc32": "~0.2.3", - "fd-slicer": "~1.1.0" - } - }, "node_modules/yocto-queue": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", @@ -14670,19 +9155,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/yoctocolors": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/yoctocolors/-/yoctocolors-2.1.2.tgz", - "integrity": "sha512-CzhO+pFNo8ajLM2d2IW/R93ipy99LWjtwblvC1RsoSUMZgyLbYFr221TnSNT7GjGdYui6P459mw9JH/g/zW2ug==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/zod": { "version": "4.3.6", "resolved": "https://registry.npmjs.org/zod/-/zod-4.3.6.tgz", @@ -14706,6 +9178,35 @@ "zod": "^3.25.0 || ^4.0.0" } }, + "node_modules/zustand": { + "version": "5.0.11", + "resolved": "https://registry.npmjs.org/zustand/-/zustand-5.0.11.tgz", + "integrity": "sha512-fdZY+dk7zn/vbWNCYmzZULHRrss0jx5pPFiOuMZ/5HJN6Yv3u+1Wswy/4MpZEkEGhtNH+pwxZB8OKgUBPzYAGg==", + "license": "MIT", + "engines": { + "node": ">=12.20.0" + }, + "peerDependencies": { + "@types/react": ">=18.0.0", + "immer": ">=9.0.6", + "react": ">=18.0.0", + "use-sync-external-store": ">=1.2.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "immer": { + "optional": true + }, + "react": { + "optional": true + }, + "use-sync-external-store": { + "optional": true + } + } + }, "node_modules/zwitch": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/zwitch/-/zwitch-2.0.4.tgz", diff --git a/src/frontend/package.json b/src/frontend/package.json index 3143b81..f18c915 100644 --- a/src/frontend/package.json +++ b/src/frontend/package.json @@ -1,62 +1,39 @@ { - "name": "frontend", - "version": "0.1.0", + "name": "mission-control", + "version": "0.5.0", "private": true, "scripts": { - "dev": "next dev", + "dev": "next dev -H 0.0.0.0", "build": "next build", - "start": "next start", - "lint": "eslint", - "test": "vitest run --passWithNoTests --coverage", - "test:full-coverage": "vitest run --passWithNoTests --coverage --config ./vitest.full-coverage.config.ts", - "test:watch": "vitest", - "dev:lan": "next dev --hostname 0.0.0.0 --port 3000", - "api:gen": "orval --config ./orval.config.ts", - "e2e": "cypress run", - "e2e:open": "cypress open" + "start": "next start -H 0.0.0.0", + "lint": "eslint" }, "dependencies": { - "@clerk/nextjs": "^6.37.3", - "@radix-ui/react-dialog": "^1.1.15", - "@radix-ui/react-popover": "^1.1.15", - "@radix-ui/react-select": "^2.2.6", - "@radix-ui/react-tabs": "^1.1.13", - "@radix-ui/react-tooltip": "^1.2.8", - "@tanstack/react-query": "^5.90.21", - "@tanstack/react-table": "^8.21.3", - "cmdk": "^1.1.1", - "next": "16.1.7", - "react": "19.2.4", - "react-dom": "19.2.4", + "@monaco-editor/react": "^4.7.0", + "@react-three/drei": "^10.7.7", + "@react-three/fiber": "^9.5.0", + "@react-three/rapier": "^2.2.0", + "@tailwindcss/typography": "^0.5.19", + "@types/better-sqlite3": "^7.6.13", + "better-sqlite3": "^12.6.2", + "date-fns": "^4.1.0", + "lucide-react": "^0.563.0", + "next": "16.1.6", + "react": "19.2.3", + "react-dom": "19.2.3", "react-markdown": "^10.1.0", - "recharts": "^3.7.0", - "remark-breaks": "^4.0.0", - "remark-gfm": "^4.0.1" + "recharts": "^2.15.4", + "three": "^0.183.0" }, "devDependencies": { - "@clerk/testing": "^1.13.35", - "@testing-library/jest-dom": "^6.9.1", - "@testing-library/react": "^16.3.2", - "@testing-library/user-event": "^14.6.1", + "@tailwindcss/postcss": "^4", "@types/node": "^20", "@types/react": "^19", "@types/react-dom": "^19", - "@vitest/coverage-v8": "^4.0.18", - "autoprefixer": "^10.4.24", - "class-variance-authority": "^0.7.1", - "clsx": "^2.1.1", - "cypress": "^14.5.4", "eslint": "^9", "eslint-config-next": "16.1.6", - "jsdom": "^25.0.1", - "lucide-react": "^0.563.0", - "orval": "^8.3.0", - "postcss": "^8.5.6", - "prettier": "^3.8.1", - "tailwind-merge": "^3.4.0", - "tailwindcss": "^3.4.19", - "tailwindcss-animate": "^1.0.7", - "typescript": "^5", - "vitest": "^4.0.18" - } + "tailwindcss": "^4", + "typescript": "^5" + }, + "description": "Mission Control \u2014 OpenClaw agent dashboard and control center" } diff --git a/src/frontend/postcss.config.js b/src/frontend/postcss.config.js deleted file mode 100644 index 12a703d..0000000 --- a/src/frontend/postcss.config.js +++ /dev/null @@ -1,6 +0,0 @@ -module.exports = { - plugins: { - tailwindcss: {}, - autoprefixer: {}, - }, -}; diff --git a/src/frontend/postcss.config.mjs b/src/frontend/postcss.config.mjs new file mode 100644 index 0000000..61e3684 --- /dev/null +++ b/src/frontend/postcss.config.mjs @@ -0,0 +1,7 @@ +const config = { + plugins: { + "@tailwindcss/postcss": {}, + }, +}; + +export default config; diff --git a/src/frontend/public/apple-touch-icon.png b/src/frontend/public/apple-touch-icon.png new file mode 100644 index 0000000..5dbbc80 Binary files /dev/null and b/src/frontend/public/apple-touch-icon.png differ diff --git a/src/frontend/public/favicon.ico b/src/frontend/public/favicon.ico new file mode 100644 index 0000000..87f1f73 Binary files /dev/null and b/src/frontend/public/favicon.ico differ diff --git a/src/frontend/public/file.svg b/src/frontend/public/file.svg new file mode 100644 index 0000000..004145c --- /dev/null +++ b/src/frontend/public/file.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/frontend/public/globe.svg b/src/frontend/public/globe.svg new file mode 100644 index 0000000..567f17b --- /dev/null +++ b/src/frontend/public/globe.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/frontend/public/icon-192.png b/src/frontend/public/icon-192.png new file mode 100644 index 0000000..3d5fc49 Binary files /dev/null and b/src/frontend/public/icon-192.png differ diff --git a/src/frontend/public/icon-512.png b/src/frontend/public/icon-512.png new file mode 100644 index 0000000..6c1a4e8 Binary files /dev/null and b/src/frontend/public/icon-512.png differ diff --git a/src/frontend/public/manifest.json b/src/frontend/public/manifest.json new file mode 100644 index 0000000..01602e7 --- /dev/null +++ b/src/frontend/public/manifest.json @@ -0,0 +1,12 @@ +{ + "name": "Mission Control", + "short_name": "MissionCtrl", + "start_url": "/", + "display": "standalone", + "theme_color": "#1a1a2e", + "background_color": "#1a1a2e", + "icons": [ + { "src": "/icon-192.png", "sizes": "192x192", "type": "image/png" }, + { "src": "/icon-512.png", "sizes": "512x512", "type": "image/png" } + ] +} diff --git a/src/frontend/public/models/README.md b/src/frontend/public/models/README.md new file mode 100644 index 0000000..bf10e41 --- /dev/null +++ b/src/frontend/public/models/README.md @@ -0,0 +1,21 @@ +# Avatar Models (GLB) + +This folder holds the 3D avatar models for the Office 3D view. +Each file is named after the agent's workspace ID (e.g. `main.glb`, `studio.glb`). + +## How to add your own models + +1. Go to https://readyplayer.me/avatar and create an avatar +2. Export as **GLB** +3. Rename the file to match your agent's workspace ID (see `agentsConfig.ts`) +4. Place it in this folder + +## Fallback + +If a GLB file is not found for an agent, the system displays a colored sphere as placeholder. + +## Recommended format + +- **Format:** GLB (binary GLTF) +- **Max size:** < 5 MB per model +- Ready Player Me exports web-optimized models by default diff --git a/src/frontend/public/next.svg b/src/frontend/public/next.svg new file mode 100644 index 0000000..5174b28 --- /dev/null +++ b/src/frontend/public/next.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/frontend/public/sw.js b/src/frontend/public/sw.js new file mode 100644 index 0000000..2276a6b --- /dev/null +++ b/src/frontend/public/sw.js @@ -0,0 +1,15 @@ +const CACHE = "mc-v1"; +self.addEventListener("install", e => { self.skipWaiting(); }); +self.addEventListener("activate", e => { e.waitUntil(clients.claim()); }); +self.addEventListener("fetch", e => { + const url = new URL(e.request.url); + if (url.pathname.startsWith("/api/")) { + e.respondWith(fetch(e.request).catch(() => caches.match(e.request))); + } else { + e.respondWith(caches.match(e.request).then(r => r || fetch(e.request).then(res => { + const clone = res.clone(); + caches.open(CACHE).then(c => c.put(e.request, clone)); + return res; + }))); + } +}); diff --git a/src/frontend/public/vercel.svg b/src/frontend/public/vercel.svg new file mode 100644 index 0000000..7705396 --- /dev/null +++ b/src/frontend/public/vercel.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/frontend/public/window.svg b/src/frontend/public/window.svg new file mode 100644 index 0000000..b2b2a44 --- /dev/null +++ b/src/frontend/public/window.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/frontend/scripts/collect-usage.sh b/src/frontend/scripts/collect-usage.sh new file mode 100755 index 0000000..de3e85f --- /dev/null +++ b/src/frontend/scripts/collect-usage.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# Collect usage wrapper script + +cd "$(dirname "$0")/.." || exit 1 + +# Run with tsx (TypeScript executor) +npx tsx scripts/collect-usage.ts diff --git a/src/frontend/scripts/collect-usage.ts b/src/frontend/scripts/collect-usage.ts new file mode 100644 index 0000000..fa52134 --- /dev/null +++ b/src/frontend/scripts/collect-usage.ts @@ -0,0 +1,29 @@ +#!/usr/bin/env tsx +/** + * Collect Usage Script + * + * Collects current OpenClaw usage data and stores it in SQLite + * Run manually or via cron + */ + +import path from "path"; +import { collectUsage } from "../src/lib/usage-collector"; + +const DB_PATH = path.join(__dirname, "..", "data", "usage-tracking.db"); + +async function main() { + console.log("🦞 Mission Control - Usage Collector"); + console.log(`Database: ${DB_PATH}`); + console.log(`Timestamp: ${new Date().toISOString()}`); + console.log(); + + try { + await collectUsage(DB_PATH); + console.log("✅ Usage data collected successfully"); + } catch (error) { + console.error("❌ Error collecting usage data:", error); + process.exit(1); + } +} + +main(); diff --git a/src/frontend/scripts/pre-commit-check.sh b/src/frontend/scripts/pre-commit-check.sh new file mode 100755 index 0000000..ee0d6f6 --- /dev/null +++ b/src/frontend/scripts/pre-commit-check.sh @@ -0,0 +1,92 @@ +#!/bin/bash +# Pre-commit Security Check +# Run this before committing to ensure no sensitive data leaks + +set -e + +echo "🔒 Mission Control - Pre-Commit Security Check" +echo "================================================" +echo "" + +FAILED=0 + +# Check 1: .env.local not staged +echo "✓ Checking .env.local is not staged..." +if git diff --cached --name-only | grep -q ".env.local"; then + echo "❌ FAIL: .env.local is staged! This contains secrets." + FAILED=1 +else + echo "✅ PASS" +fi + +# Check 2: data/*.json files not staged (except .example) +echo "" +echo "✓ Checking data files are not staged..." +STAGED_DATA=$(git diff --cached --name-only | grep "^data/.*\.json$" | grep -v ".example.json" || true) +if [ -n "$STAGED_DATA" ]; then + echo "❌ FAIL: Operational data files are staged:" + echo "$STAGED_DATA" + FAILED=1 +else + echo "✅ PASS" +fi + +# Check 3: data/*.db files not staged +echo "" +echo "✓ Checking database files are not staged..." +STAGED_DB=$(git diff --cached --name-only | grep "^data/.*\.db$\|^data/.*\.sqlite" || true) +if [ -n "$STAGED_DB" ]; then + echo "❌ FAIL: Database files are staged:" + echo "$STAGED_DB" + FAILED=1 +else + echo "✅ PASS" +fi + +# Check 4: No hardcoded emails in staged files +echo "" +echo "✓ Checking for hardcoded email addresses..." +HARDCODED_EMAILS=$(git diff --cached | grep -E "^+" | grep -oE "[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}" | grep -v "example.com\|localhost\|openclaw.ai" || true) +if [ -n "$HARDCODED_EMAILS" ]; then + echo "⚠️ WARNING: Found email addresses in staged changes:" + echo "$HARDCODED_EMAILS" + echo " Make sure these are intentional and not personal data." +fi + +# Check 5: No hardcoded passwords/secrets in staged files +echo "" +echo "✓ Checking for potential secrets in staged files..." +POTENTIAL_SECRETS=$(git diff --cached | grep -E "^+" | grep -iE "password.*=|secret.*=|api[_-]?key.*=|token.*=" | grep -v "ADMIN_PASSWORD\|AUTH_SECRET\|API_KEY\|placeholder\|example\|TODO" || true) +if [ -n "$POTENTIAL_SECRETS" ]; then + echo "⚠️ WARNING: Found potential secrets in staged changes:" + echo "$POTENTIAL_SECRETS" + echo " Review these carefully before committing." +fi + +# Check 6: All .example files have corresponding real files (reminder) +echo "" +echo "✓ Checking .example files..." +for example_file in data/*.example.json; do + real_file="${example_file%.example.json}.json" + if [ ! -f "$real_file" ]; then + echo "ℹ️ Note: $real_file doesn't exist yet (not an error, just FYI)" + fi +done +echo "✅ All .example files accounted for" + +echo "" +echo "================================================" + +if [ $FAILED -eq 1 ]; then + echo "❌ SECURITY CHECK FAILED" + echo "" + echo "Fix the issues above before committing." + echo "To unstage sensitive files:" + echo " git reset HEAD " + exit 1 +else + echo "✅ SECURITY CHECK PASSED" + echo "" + echo "Safe to commit!" + exit 0 +fi diff --git a/src/frontend/scripts/setup-cron.sh b/src/frontend/scripts/setup-cron.sh new file mode 100755 index 0000000..8035caa --- /dev/null +++ b/src/frontend/scripts/setup-cron.sh @@ -0,0 +1,32 @@ +#!/bin/bash +# Setup cron job for hourly usage collection + +SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +PROJECT_DIR="$(dirname "$SCRIPT_DIR")" + +# Cron entry (runs every hour at minute 0) +CRON_ENTRY="0 * * * * cd $PROJECT_DIR && npx tsx scripts/collect-usage.ts >> /var/log/mission-control-usage.log 2>&1" + +echo "Setting up cron job for usage collection..." +echo "Schedule: Every hour at minute 0" +echo "Command: $CRON_ENTRY" +echo + +# Check if entry already exists +if crontab -l 2>/dev/null | grep -F "collect-usage.ts" > /dev/null; then + echo "⚠️ Cron job already exists. Remove it first with:" + echo " crontab -e" + echo " (delete the line containing 'collect-usage.ts')" + exit 1 +fi + +# Add to crontab +(crontab -l 2>/dev/null; echo "$CRON_ENTRY") | crontab - + +echo "✅ Cron job added successfully" +echo +echo "To verify:" +echo " crontab -l" +echo +echo "To view logs:" +echo " tail -f /var/log/mission-control-usage.log" diff --git a/src/frontend/src/api/generated/activity/activity.ts b/src/frontend/src/api/generated/activity/activity.ts deleted file mode 100644 index 424b609..0000000 --- a/src/frontend/src/api/generated/activity/activity.ts +++ /dev/null @@ -1,774 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - HTTPValidationError, - LimitOffsetPageTypeVarCustomizedActivityEventRead, - LimitOffsetPageTypeVarCustomizedActivityTaskCommentFeedItemRead, - ListActivityApiV1ActivityGetParams, - ListTaskCommentFeedApiV1ActivityTaskCommentsGetParams, - StreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List activity events visible to the calling actor. - * @summary List Activity - */ -export type listActivityApiV1ActivityGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedActivityEventRead; - status: 200; -}; - -export type listActivityApiV1ActivityGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listActivityApiV1ActivityGetResponseSuccess = - listActivityApiV1ActivityGetResponse200 & { - headers: Headers; - }; -export type listActivityApiV1ActivityGetResponseError = - listActivityApiV1ActivityGetResponse422 & { - headers: Headers; - }; - -export type listActivityApiV1ActivityGetResponse = - | listActivityApiV1ActivityGetResponseSuccess - | listActivityApiV1ActivityGetResponseError; - -export const getListActivityApiV1ActivityGetUrl = ( - params?: ListActivityApiV1ActivityGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/activity?${stringifiedParams}` - : `/api/v1/activity`; -}; - -export const listActivityApiV1ActivityGet = async ( - params?: ListActivityApiV1ActivityGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListActivityApiV1ActivityGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListActivityApiV1ActivityGetQueryKey = ( - params?: ListActivityApiV1ActivityGetParams, -) => { - return [`/api/v1/activity`, ...(params ? [params] : [])] as const; -}; - -export const getListActivityApiV1ActivityGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListActivityApiV1ActivityGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getListActivityApiV1ActivityGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listActivityApiV1ActivityGet(params, { signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListActivityApiV1ActivityGetQueryResult = NonNullable< - Awaited> ->; -export type ListActivityApiV1ActivityGetQueryError = HTTPValidationError; - -export function useListActivityApiV1ActivityGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params: undefined | ListActivityApiV1ActivityGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListActivityApiV1ActivityGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListActivityApiV1ActivityGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListActivityApiV1ActivityGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListActivityApiV1ActivityGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Activity - */ - -export function useListActivityApiV1ActivityGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListActivityApiV1ActivityGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getListActivityApiV1ActivityGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * List task-comment feed items for accessible boards. - * @summary List Task Comment Feed - */ -export type listTaskCommentFeedApiV1ActivityTaskCommentsGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedActivityTaskCommentFeedItemRead; - status: 200; -}; - -export type listTaskCommentFeedApiV1ActivityTaskCommentsGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listTaskCommentFeedApiV1ActivityTaskCommentsGetResponseSuccess = - listTaskCommentFeedApiV1ActivityTaskCommentsGetResponse200 & { - headers: Headers; - }; -export type listTaskCommentFeedApiV1ActivityTaskCommentsGetResponseError = - listTaskCommentFeedApiV1ActivityTaskCommentsGetResponse422 & { - headers: Headers; - }; - -export type listTaskCommentFeedApiV1ActivityTaskCommentsGetResponse = - | listTaskCommentFeedApiV1ActivityTaskCommentsGetResponseSuccess - | listTaskCommentFeedApiV1ActivityTaskCommentsGetResponseError; - -export const getListTaskCommentFeedApiV1ActivityTaskCommentsGetUrl = ( - params?: ListTaskCommentFeedApiV1ActivityTaskCommentsGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/activity/task-comments?${stringifiedParams}` - : `/api/v1/activity/task-comments`; -}; - -export const listTaskCommentFeedApiV1ActivityTaskCommentsGet = async ( - params?: ListTaskCommentFeedApiV1ActivityTaskCommentsGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListTaskCommentFeedApiV1ActivityTaskCommentsGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListTaskCommentFeedApiV1ActivityTaskCommentsGetQueryKey = ( - params?: ListTaskCommentFeedApiV1ActivityTaskCommentsGetParams, -) => { - return [ - `/api/v1/activity/task-comments`, - ...(params ? [params] : []), - ] as const; -}; - -export const getListTaskCommentFeedApiV1ActivityTaskCommentsGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListTaskCommentFeedApiV1ActivityTaskCommentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListTaskCommentFeedApiV1ActivityTaskCommentsGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listTaskCommentFeedApiV1ActivityTaskCommentsGet(params, { - signal, - ...requestOptions, - }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListTaskCommentFeedApiV1ActivityTaskCommentsGetQueryResult = - NonNullable< - Awaited> - >; -export type ListTaskCommentFeedApiV1ActivityTaskCommentsGetQueryError = - HTTPValidationError; - -export function useListTaskCommentFeedApiV1ActivityTaskCommentsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: undefined | ListTaskCommentFeedApiV1ActivityTaskCommentsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListTaskCommentFeedApiV1ActivityTaskCommentsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListTaskCommentFeedApiV1ActivityTaskCommentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListTaskCommentFeedApiV1ActivityTaskCommentsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListTaskCommentFeedApiV1ActivityTaskCommentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Task Comment Feed - */ - -export function useListTaskCommentFeedApiV1ActivityTaskCommentsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListTaskCommentFeedApiV1ActivityTaskCommentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListTaskCommentFeedApiV1ActivityTaskCommentsGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Stream task-comment events for accessible boards. - * @summary Stream Task Comment Feed - */ -export type streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetResponse200 = - { - data: unknown; - status: 200; - }; - -export type streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetResponseSuccess = - streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetResponse200 & { - headers: Headers; - }; -export type streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetResponseError = - streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetResponse422 & { - headers: Headers; - }; - -export type streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetResponse = - | streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetResponseSuccess - | streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetResponseError; - -export const getStreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetUrl = ( - params?: StreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/activity/task-comments/stream?${stringifiedParams}` - : `/api/v1/activity/task-comments/stream`; -}; - -export const streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet = async ( - params?: StreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getStreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getStreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetQueryKey = - (params?: StreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams) => { - return [ - `/api/v1/activity/task-comments/stream`, - ...(params ? [params] : []), - ] as const; - }; - -export const getStreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetQueryOptions = - < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, - >( - params?: StreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getStreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetQueryKey( - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet - > - > - > = ({ signal }) => - streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet(params, { - signal, - ...requestOptions, - }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited< - ReturnType< - typeof streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type StreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetQueryResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type StreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetQueryError = - HTTPValidationError; - -export function useStreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: - | undefined - | StreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet - > - >, - TError, - Awaited< - ReturnType< - typeof streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useStreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: StreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet - > - >, - TError, - Awaited< - ReturnType< - typeof streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useStreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: StreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Stream Task Comment Feed - */ - -export function useStreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: StreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getStreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} diff --git a/src/frontend/src/api/generated/agent/agent.ts b/src/frontend/src/api/generated/agent/agent.ts deleted file mode 100644 index a419702..0000000 --- a/src/frontend/src/api/generated/agent/agent.ts +++ /dev/null @@ -1,4619 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - AgentCreate, - AgentHealthStatusResponse, - AgentNudge, - AgentRead, - ApprovalCreate, - ApprovalRead, - BoardMemoryCreate, - BoardMemoryRead, - BoardOnboardingAgentComplete, - BoardOnboardingAgentQuestion, - BoardOnboardingRead, - BoardRead, - GatewayLeadBroadcastRequest, - GatewayLeadBroadcastResponse, - GatewayLeadMessageRequest, - GatewayLeadMessageResponse, - GatewayMainAskUserRequest, - GatewayMainAskUserResponse, - HTTPValidationError, - LLMErrorResponse, - LimitOffsetPageTypeVarCustomizedAgentRead, - LimitOffsetPageTypeVarCustomizedApprovalRead, - LimitOffsetPageTypeVarCustomizedBoardMemoryRead, - LimitOffsetPageTypeVarCustomizedBoardRead, - LimitOffsetPageTypeVarCustomizedTaskCommentRead, - LimitOffsetPageTypeVarCustomizedTaskRead, - ListAgentsApiV1AgentAgentsGetParams, - ListApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams, - ListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams, - ListBoardsApiV1AgentBoardsGetParams, - ListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams, - ListTasksApiV1AgentBoardsBoardIdTasksGetParams, - OkResponse, - SoulUpdateRequest, - TagRef, - TaskCommentCreate, - TaskCommentRead, - TaskCreate, - TaskRead, - TaskUpdate, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * Return agents visible to the caller, optionally filtered by board. - -Use when downstream routing or coordination needs recipient actors. - * @summary List visible agents - */ -export type listAgentsApiV1AgentAgentsGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedAgentRead; - status: 200; -}; - -export type listAgentsApiV1AgentAgentsGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listAgentsApiV1AgentAgentsGetResponseSuccess = - listAgentsApiV1AgentAgentsGetResponse200 & { - headers: Headers; - }; -export type listAgentsApiV1AgentAgentsGetResponseError = - listAgentsApiV1AgentAgentsGetResponse422 & { - headers: Headers; - }; - -export type listAgentsApiV1AgentAgentsGetResponse = - | listAgentsApiV1AgentAgentsGetResponseSuccess - | listAgentsApiV1AgentAgentsGetResponseError; - -export const getListAgentsApiV1AgentAgentsGetUrl = ( - params?: ListAgentsApiV1AgentAgentsGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/agent/agents?${stringifiedParams}` - : `/api/v1/agent/agents`; -}; - -export const listAgentsApiV1AgentAgentsGet = async ( - params?: ListAgentsApiV1AgentAgentsGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListAgentsApiV1AgentAgentsGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListAgentsApiV1AgentAgentsGetQueryKey = ( - params?: ListAgentsApiV1AgentAgentsGetParams, -) => { - return [`/api/v1/agent/agents`, ...(params ? [params] : [])] as const; -}; - -export const getListAgentsApiV1AgentAgentsGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListAgentsApiV1AgentAgentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getListAgentsApiV1AgentAgentsGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listAgentsApiV1AgentAgentsGet(params, { signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListAgentsApiV1AgentAgentsGetQueryResult = NonNullable< - Awaited> ->; -export type ListAgentsApiV1AgentAgentsGetQueryError = HTTPValidationError; - -export function useListAgentsApiV1AgentAgentsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params: undefined | ListAgentsApiV1AgentAgentsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListAgentsApiV1AgentAgentsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListAgentsApiV1AgentAgentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListAgentsApiV1AgentAgentsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListAgentsApiV1AgentAgentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List visible agents - */ - -export function useListAgentsApiV1AgentAgentsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListAgentsApiV1AgentAgentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getListAgentsApiV1AgentAgentsGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Register a new board agent and attach it to the lead's board. - -The target board is derived from the caller identity and cannot be changed in payload. - * @summary Create a board agent as lead - */ -export type agentLeadCreateAgentResponse200 = { - data: AgentRead; - status: 200; -}; - -export type agentLeadCreateAgentResponse403 = { - data: LLMErrorResponse; - status: 403; -}; - -export type agentLeadCreateAgentResponse409 = { - data: LLMErrorResponse; - status: 409; -}; - -export type agentLeadCreateAgentResponse422 = { - data: LLMErrorResponse; - status: 422; -}; - -export type agentLeadCreateAgentResponseSuccess = - agentLeadCreateAgentResponse200 & { - headers: Headers; - }; -export type agentLeadCreateAgentResponseError = ( - | agentLeadCreateAgentResponse403 - | agentLeadCreateAgentResponse409 - | agentLeadCreateAgentResponse422 -) & { - headers: Headers; -}; - -export type agentLeadCreateAgentResponse = - | agentLeadCreateAgentResponseSuccess - | agentLeadCreateAgentResponseError; - -export const getAgentLeadCreateAgentUrl = () => { - return `/api/v1/agent/agents`; -}; - -export const agentLeadCreateAgent = async ( - agentCreate: AgentCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getAgentLeadCreateAgentUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(agentCreate), - }, - ); -}; - -export const getAgentLeadCreateAgentMutationOptions = < - TError = LLMErrorResponse, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: AgentCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { data: AgentCreate }, - TContext -> => { - const mutationKey = ["agentLeadCreateAgent"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { data: AgentCreate } - > = (props) => { - const { data } = props ?? {}; - - return agentLeadCreateAgent(data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type AgentLeadCreateAgentMutationResult = NonNullable< - Awaited> ->; -export type AgentLeadCreateAgentMutationBody = AgentCreate; -export type AgentLeadCreateAgentMutationError = LLMErrorResponse; - -/** - * @summary Create a board agent as lead - */ -export const useAgentLeadCreateAgent = < - TError = LLMErrorResponse, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: AgentCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: AgentCreate }, - TContext -> => { - return useMutation( - getAgentLeadCreateAgentMutationOptions(options), - queryClient, - ); -}; -/** - * Return boards the authenticated agent can access. - -Use this as a discovery step before board-scoped operations. - * @summary List boards visible to the caller - */ -export type listBoardsApiV1AgentBoardsGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedBoardRead; - status: 200; -}; - -export type listBoardsApiV1AgentBoardsGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listBoardsApiV1AgentBoardsGetResponseSuccess = - listBoardsApiV1AgentBoardsGetResponse200 & { - headers: Headers; - }; -export type listBoardsApiV1AgentBoardsGetResponseError = - listBoardsApiV1AgentBoardsGetResponse422 & { - headers: Headers; - }; - -export type listBoardsApiV1AgentBoardsGetResponse = - | listBoardsApiV1AgentBoardsGetResponseSuccess - | listBoardsApiV1AgentBoardsGetResponseError; - -export const getListBoardsApiV1AgentBoardsGetUrl = ( - params?: ListBoardsApiV1AgentBoardsGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/agent/boards?${stringifiedParams}` - : `/api/v1/agent/boards`; -}; - -export const listBoardsApiV1AgentBoardsGet = async ( - params?: ListBoardsApiV1AgentBoardsGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListBoardsApiV1AgentBoardsGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListBoardsApiV1AgentBoardsGetQueryKey = ( - params?: ListBoardsApiV1AgentBoardsGetParams, -) => { - return [`/api/v1/agent/boards`, ...(params ? [params] : [])] as const; -}; - -export const getListBoardsApiV1AgentBoardsGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListBoardsApiV1AgentBoardsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getListBoardsApiV1AgentBoardsGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listBoardsApiV1AgentBoardsGet(params, { signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListBoardsApiV1AgentBoardsGetQueryResult = NonNullable< - Awaited> ->; -export type ListBoardsApiV1AgentBoardsGetQueryError = HTTPValidationError; - -export function useListBoardsApiV1AgentBoardsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params: undefined | ListBoardsApiV1AgentBoardsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardsApiV1AgentBoardsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListBoardsApiV1AgentBoardsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardsApiV1AgentBoardsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListBoardsApiV1AgentBoardsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List boards visible to the caller - */ - -export function useListBoardsApiV1AgentBoardsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListBoardsApiV1AgentBoardsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getListBoardsApiV1AgentBoardsGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Read a single board entity if it is visible to the authenticated agent. - -Use for targeted planning and routing decisions. - * @summary Fetch a board by id - */ -export type getBoardApiV1AgentBoardsBoardIdGetResponse200 = { - data: BoardRead; - status: 200; -}; - -export type getBoardApiV1AgentBoardsBoardIdGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getBoardApiV1AgentBoardsBoardIdGetResponseSuccess = - getBoardApiV1AgentBoardsBoardIdGetResponse200 & { - headers: Headers; - }; -export type getBoardApiV1AgentBoardsBoardIdGetResponseError = - getBoardApiV1AgentBoardsBoardIdGetResponse422 & { - headers: Headers; - }; - -export type getBoardApiV1AgentBoardsBoardIdGetResponse = - | getBoardApiV1AgentBoardsBoardIdGetResponseSuccess - | getBoardApiV1AgentBoardsBoardIdGetResponseError; - -export const getGetBoardApiV1AgentBoardsBoardIdGetUrl = (boardId: string) => { - return `/api/v1/agent/boards/${boardId}`; -}; - -export const getBoardApiV1AgentBoardsBoardIdGet = async ( - boardId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetBoardApiV1AgentBoardsBoardIdGetUrl(boardId), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetBoardApiV1AgentBoardsBoardIdGetQueryKey = ( - boardId: string, -) => { - return [`/api/v1/agent/boards/${boardId}`] as const; -}; - -export const getGetBoardApiV1AgentBoardsBoardIdGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetBoardApiV1AgentBoardsBoardIdGetQueryKey(boardId); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getBoardApiV1AgentBoardsBoardIdGet(boardId, { signal, ...requestOptions }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetBoardApiV1AgentBoardsBoardIdGetQueryResult = NonNullable< - Awaited> ->; -export type GetBoardApiV1AgentBoardsBoardIdGetQueryError = HTTPValidationError; - -export function useGetBoardApiV1AgentBoardsBoardIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardApiV1AgentBoardsBoardIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardApiV1AgentBoardsBoardIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Fetch a board by id - */ - -export function useGetBoardApiV1AgentBoardsBoardIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getGetBoardApiV1AgentBoardsBoardIdGetQueryOptions( - boardId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Permanently remove a board agent and tear down associated lifecycle state. - -Use sparingly; prefer reassignment for continuity-sensitive teams. - * @summary Delete a board agent as lead - */ -export type agentLeadDeleteBoardAgentResponse200 = { - data: OkResponse; - status: 200; -}; - -export type agentLeadDeleteBoardAgentResponse403 = { - data: LLMErrorResponse; - status: 403; -}; - -export type agentLeadDeleteBoardAgentResponse404 = { - data: LLMErrorResponse; - status: 404; -}; - -export type agentLeadDeleteBoardAgentResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type agentLeadDeleteBoardAgentResponseSuccess = - agentLeadDeleteBoardAgentResponse200 & { - headers: Headers; - }; -export type agentLeadDeleteBoardAgentResponseError = ( - | agentLeadDeleteBoardAgentResponse403 - | agentLeadDeleteBoardAgentResponse404 - | agentLeadDeleteBoardAgentResponse422 -) & { - headers: Headers; -}; - -export type agentLeadDeleteBoardAgentResponse = - | agentLeadDeleteBoardAgentResponseSuccess - | agentLeadDeleteBoardAgentResponseError; - -export const getAgentLeadDeleteBoardAgentUrl = ( - boardId: string, - agentId: string, -) => { - return `/api/v1/agent/boards/${boardId}/agents/${agentId}`; -}; - -export const agentLeadDeleteBoardAgent = async ( - boardId: string, - agentId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getAgentLeadDeleteBoardAgentUrl(boardId, agentId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getAgentLeadDeleteBoardAgentMutationOptions = < - TError = LLMErrorResponse | HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; agentId: string }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string; agentId: string }, - TContext -> => { - const mutationKey = ["agentLeadDeleteBoardAgent"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string; agentId: string } - > = (props) => { - const { boardId, agentId } = props ?? {}; - - return agentLeadDeleteBoardAgent(boardId, agentId, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type AgentLeadDeleteBoardAgentMutationResult = NonNullable< - Awaited> ->; - -export type AgentLeadDeleteBoardAgentMutationError = - | LLMErrorResponse - | HTTPValidationError; - -/** - * @summary Delete a board agent as lead - */ -export const useAgentLeadDeleteBoardAgent = < - TError = LLMErrorResponse | HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; agentId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; agentId: string }, - TContext -> => { - return useMutation( - getAgentLeadDeleteBoardAgentMutationOptions(options), - queryClient, - ); -}; -/** - * Send a direct coordination message to a specific board agent. - -Use this when a lead sees stalled, idle, or misaligned work. - * @summary Nudge an agent on a board - */ -export type agentLeadNudgeAgentResponse200 = { - data: OkResponse; - status: 200; -}; - -export type agentLeadNudgeAgentResponse403 = { - data: LLMErrorResponse; - status: 403; -}; - -export type agentLeadNudgeAgentResponse404 = { - data: LLMErrorResponse; - status: 404; -}; - -export type agentLeadNudgeAgentResponse422 = { - data: LLMErrorResponse; - status: 422; -}; - -export type agentLeadNudgeAgentResponse502 = { - data: LLMErrorResponse; - status: 502; -}; - -export type agentLeadNudgeAgentResponseSuccess = - agentLeadNudgeAgentResponse200 & { - headers: Headers; - }; -export type agentLeadNudgeAgentResponseError = ( - | agentLeadNudgeAgentResponse403 - | agentLeadNudgeAgentResponse404 - | agentLeadNudgeAgentResponse422 - | agentLeadNudgeAgentResponse502 -) & { - headers: Headers; -}; - -export type agentLeadNudgeAgentResponse = - | agentLeadNudgeAgentResponseSuccess - | agentLeadNudgeAgentResponseError; - -export const getAgentLeadNudgeAgentUrl = (boardId: string, agentId: string) => { - return `/api/v1/agent/boards/${boardId}/agents/${agentId}/nudge`; -}; - -export const agentLeadNudgeAgent = async ( - boardId: string, - agentId: string, - agentNudge: AgentNudge, - options?: RequestInit, -): Promise => { - return customFetch( - getAgentLeadNudgeAgentUrl(boardId, agentId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(agentNudge), - }, - ); -}; - -export const getAgentLeadNudgeAgentMutationOptions = < - TError = LLMErrorResponse, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; agentId: string; data: AgentNudge }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string; agentId: string; data: AgentNudge }, - TContext -> => { - const mutationKey = ["agentLeadNudgeAgent"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string; agentId: string; data: AgentNudge } - > = (props) => { - const { boardId, agentId, data } = props ?? {}; - - return agentLeadNudgeAgent(boardId, agentId, data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type AgentLeadNudgeAgentMutationResult = NonNullable< - Awaited> ->; -export type AgentLeadNudgeAgentMutationBody = AgentNudge; -export type AgentLeadNudgeAgentMutationError = LLMErrorResponse; - -/** - * @summary Nudge an agent on a board - */ -export const useAgentLeadNudgeAgent = < - TError = LLMErrorResponse, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; agentId: string; data: AgentNudge }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; agentId: string; data: AgentNudge }, - TContext -> => { - return useMutation( - getAgentLeadNudgeAgentMutationOptions(options), - queryClient, - ); -}; -/** - * Fetch an agent's SOUL.md content. - -Allowed for board lead, or for an agent reading its own SOUL. - * @summary Get Agent Soul - */ -export type getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetResponse200 = - { - data: string; - status: 200; - }; - -export type getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetResponseSuccess = - getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetResponse200 & { - headers: Headers; - }; -export type getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetResponseError = - getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetResponse422 & { - headers: Headers; - }; - -export type getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetResponse = - | getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetResponseSuccess - | getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetResponseError; - -export const getGetAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetUrl = ( - boardId: string, - agentId: string, -) => { - return `/api/v1/agent/boards/${boardId}/agents/${agentId}/soul`; -}; - -export const getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet = async ( - boardId: string, - agentId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetUrl( - boardId, - agentId, - ), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetQueryKey = - (boardId: string, agentId: string) => { - return [`/api/v1/agent/boards/${boardId}/agents/${agentId}/soul`] as const; - }; - -export const getGetAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetQueryOptions = - < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, - >( - boardId: string, - agentId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetQueryKey( - boardId, - agentId, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet - > - > - > = ({ signal }) => - getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet( - boardId, - agentId, - { signal, ...requestOptions }, - ); - - return { - queryKey, - queryFn, - enabled: !!(boardId && agentId), - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType< - typeof getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type GetAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetQueryResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type GetAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetQueryError = - HTTPValidationError; - -export function useGetAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - agentId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet - > - >, - TError, - Awaited< - ReturnType< - typeof getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - agentId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet - > - >, - TError, - Awaited< - ReturnType< - typeof getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - agentId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Agent Soul - */ - -export function useGetAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - agentId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetAgentSoulApiV1AgentBoardsBoardIdAgentsAgentIdSoulGetQueryOptions( - boardId, - agentId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Write SOUL.md content for a board agent and persist it for reprovisioning. - -Use this when role instructions or behavior guardrails need updates. - * @summary Update an agent's SOUL template - */ -export type agentLeadUpdateAgentSoulResponse200 = { - data: OkResponse; - status: 200; -}; - -export type agentLeadUpdateAgentSoulResponse403 = { - data: LLMErrorResponse; - status: 403; -}; - -export type agentLeadUpdateAgentSoulResponse404 = { - data: LLMErrorResponse; - status: 404; -}; - -export type agentLeadUpdateAgentSoulResponse422 = { - data: LLMErrorResponse; - status: 422; -}; - -export type agentLeadUpdateAgentSoulResponse502 = { - data: LLMErrorResponse; - status: 502; -}; - -export type agentLeadUpdateAgentSoulResponseSuccess = - agentLeadUpdateAgentSoulResponse200 & { - headers: Headers; - }; -export type agentLeadUpdateAgentSoulResponseError = ( - | agentLeadUpdateAgentSoulResponse403 - | agentLeadUpdateAgentSoulResponse404 - | agentLeadUpdateAgentSoulResponse422 - | agentLeadUpdateAgentSoulResponse502 -) & { - headers: Headers; -}; - -export type agentLeadUpdateAgentSoulResponse = - | agentLeadUpdateAgentSoulResponseSuccess - | agentLeadUpdateAgentSoulResponseError; - -export const getAgentLeadUpdateAgentSoulUrl = ( - boardId: string, - agentId: string, -) => { - return `/api/v1/agent/boards/${boardId}/agents/${agentId}/soul`; -}; - -export const agentLeadUpdateAgentSoul = async ( - boardId: string, - agentId: string, - soulUpdateRequest: SoulUpdateRequest, - options?: RequestInit, -): Promise => { - return customFetch( - getAgentLeadUpdateAgentSoulUrl(boardId, agentId), - { - ...options, - method: "PUT", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(soulUpdateRequest), - }, - ); -}; - -export const getAgentLeadUpdateAgentSoulMutationOptions = < - TError = LLMErrorResponse, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; agentId: string; data: SoulUpdateRequest }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string; agentId: string; data: SoulUpdateRequest }, - TContext -> => { - const mutationKey = ["agentLeadUpdateAgentSoul"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string; agentId: string; data: SoulUpdateRequest } - > = (props) => { - const { boardId, agentId, data } = props ?? {}; - - return agentLeadUpdateAgentSoul(boardId, agentId, data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type AgentLeadUpdateAgentSoulMutationResult = NonNullable< - Awaited> ->; -export type AgentLeadUpdateAgentSoulMutationBody = SoulUpdateRequest; -export type AgentLeadUpdateAgentSoulMutationError = LLMErrorResponse; - -/** - * @summary Update an agent's SOUL template - */ -export const useAgentLeadUpdateAgentSoul = < - TError = LLMErrorResponse, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; agentId: string; data: SoulUpdateRequest }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; agentId: string; data: SoulUpdateRequest }, - TContext -> => { - return useMutation( - getAgentLeadUpdateAgentSoulMutationOptions(options), - queryClient, - ); -}; -/** - * List approvals for a board. - -Use status filtering to process pending approvals efficiently. - * @summary List Approvals - */ -export type listApprovalsApiV1AgentBoardsBoardIdApprovalsGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedApprovalRead; - status: 200; -}; - -export type listApprovalsApiV1AgentBoardsBoardIdApprovalsGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listApprovalsApiV1AgentBoardsBoardIdApprovalsGetResponseSuccess = - listApprovalsApiV1AgentBoardsBoardIdApprovalsGetResponse200 & { - headers: Headers; - }; -export type listApprovalsApiV1AgentBoardsBoardIdApprovalsGetResponseError = - listApprovalsApiV1AgentBoardsBoardIdApprovalsGetResponse422 & { - headers: Headers; - }; - -export type listApprovalsApiV1AgentBoardsBoardIdApprovalsGetResponse = - | listApprovalsApiV1AgentBoardsBoardIdApprovalsGetResponseSuccess - | listApprovalsApiV1AgentBoardsBoardIdApprovalsGetResponseError; - -export const getListApprovalsApiV1AgentBoardsBoardIdApprovalsGetUrl = ( - boardId: string, - params?: ListApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/agent/boards/${boardId}/approvals?${stringifiedParams}` - : `/api/v1/agent/boards/${boardId}/approvals`; -}; - -export const listApprovalsApiV1AgentBoardsBoardIdApprovalsGet = async ( - boardId: string, - params?: ListApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListApprovalsApiV1AgentBoardsBoardIdApprovalsGetUrl(boardId, params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListApprovalsApiV1AgentBoardsBoardIdApprovalsGetQueryKey = ( - boardId: string, - params?: ListApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams, -) => { - return [ - `/api/v1/agent/boards/${boardId}/approvals`, - ...(params ? [params] : []), - ] as const; -}; - -export const getListApprovalsApiV1AgentBoardsBoardIdApprovalsGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListApprovalsApiV1AgentBoardsBoardIdApprovalsGetQueryKey( - boardId, - params, - ); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listApprovalsApiV1AgentBoardsBoardIdApprovalsGet(boardId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListApprovalsApiV1AgentBoardsBoardIdApprovalsGetQueryResult = - NonNullable< - Awaited> - >; -export type ListApprovalsApiV1AgentBoardsBoardIdApprovalsGetQueryError = - HTTPValidationError; - -export function useListApprovalsApiV1AgentBoardsBoardIdApprovalsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params: undefined | ListApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListApprovalsApiV1AgentBoardsBoardIdApprovalsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListApprovalsApiV1AgentBoardsBoardIdApprovalsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Approvals - */ - -export function useListApprovalsApiV1AgentBoardsBoardIdApprovalsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListApprovalsApiV1AgentBoardsBoardIdApprovalsGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create an approval request for risky or low-confidence actions. - -Include `task_id` or `task_ids` to scope the decision precisely. - * @summary Create Approval - */ -export type createApprovalApiV1AgentBoardsBoardIdApprovalsPostResponse200 = { - data: ApprovalRead; - status: 200; -}; - -export type createApprovalApiV1AgentBoardsBoardIdApprovalsPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createApprovalApiV1AgentBoardsBoardIdApprovalsPostResponseSuccess = - createApprovalApiV1AgentBoardsBoardIdApprovalsPostResponse200 & { - headers: Headers; - }; -export type createApprovalApiV1AgentBoardsBoardIdApprovalsPostResponseError = - createApprovalApiV1AgentBoardsBoardIdApprovalsPostResponse422 & { - headers: Headers; - }; - -export type createApprovalApiV1AgentBoardsBoardIdApprovalsPostResponse = - | createApprovalApiV1AgentBoardsBoardIdApprovalsPostResponseSuccess - | createApprovalApiV1AgentBoardsBoardIdApprovalsPostResponseError; - -export const getCreateApprovalApiV1AgentBoardsBoardIdApprovalsPostUrl = ( - boardId: string, -) => { - return `/api/v1/agent/boards/${boardId}/approvals`; -}; - -export const createApprovalApiV1AgentBoardsBoardIdApprovalsPost = async ( - boardId: string, - approvalCreate: ApprovalCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateApprovalApiV1AgentBoardsBoardIdApprovalsPostUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(approvalCreate), - }, - ); -}; - -export const getCreateApprovalApiV1AgentBoardsBoardIdApprovalsPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: ApprovalCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: ApprovalCreate }, - TContext - > => { - const mutationKey = ["createApprovalApiV1AgentBoardsBoardIdApprovalsPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType - >, - { boardId: string; data: ApprovalCreate } - > = (props) => { - const { boardId, data } = props ?? {}; - - return createApprovalApiV1AgentBoardsBoardIdApprovalsPost( - boardId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type CreateApprovalApiV1AgentBoardsBoardIdApprovalsPostMutationResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type CreateApprovalApiV1AgentBoardsBoardIdApprovalsPostMutationBody = - ApprovalCreate; -export type CreateApprovalApiV1AgentBoardsBoardIdApprovalsPostMutationError = - HTTPValidationError; - -/** - * @summary Create Approval - */ -export const useCreateApprovalApiV1AgentBoardsBoardIdApprovalsPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: ApprovalCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: ApprovalCreate }, - TContext -> => { - return useMutation( - getCreateApprovalApiV1AgentBoardsBoardIdApprovalsPostMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Escalate a high-impact decision or ambiguity through the gateway-main interaction channel. - -Use when lead-level context needs human confirmation or consent. - * @summary Ask the human via gateway-main - */ -export type agentLeadAskUserViaGatewayMainResponse200 = { - data: GatewayMainAskUserResponse; - status: 200; -}; - -export type agentLeadAskUserViaGatewayMainResponse403 = { - data: LLMErrorResponse; - status: 403; -}; - -export type agentLeadAskUserViaGatewayMainResponse404 = { - data: LLMErrorResponse; - status: 404; -}; - -export type agentLeadAskUserViaGatewayMainResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type agentLeadAskUserViaGatewayMainResponse502 = { - data: LLMErrorResponse; - status: 502; -}; - -export type agentLeadAskUserViaGatewayMainResponseSuccess = - agentLeadAskUserViaGatewayMainResponse200 & { - headers: Headers; - }; -export type agentLeadAskUserViaGatewayMainResponseError = ( - | agentLeadAskUserViaGatewayMainResponse403 - | agentLeadAskUserViaGatewayMainResponse404 - | agentLeadAskUserViaGatewayMainResponse422 - | agentLeadAskUserViaGatewayMainResponse502 -) & { - headers: Headers; -}; - -export type agentLeadAskUserViaGatewayMainResponse = - | agentLeadAskUserViaGatewayMainResponseSuccess - | agentLeadAskUserViaGatewayMainResponseError; - -export const getAgentLeadAskUserViaGatewayMainUrl = (boardId: string) => { - return `/api/v1/agent/boards/${boardId}/gateway/main/ask-user`; -}; - -export const agentLeadAskUserViaGatewayMain = async ( - boardId: string, - gatewayMainAskUserRequest: GatewayMainAskUserRequest, - options?: RequestInit, -): Promise => { - return customFetch( - getAgentLeadAskUserViaGatewayMainUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(gatewayMainAskUserRequest), - }, - ); -}; - -export const getAgentLeadAskUserViaGatewayMainMutationOptions = < - TError = LLMErrorResponse | HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: GatewayMainAskUserRequest }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: GatewayMainAskUserRequest }, - TContext -> => { - const mutationKey = ["agentLeadAskUserViaGatewayMain"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string; data: GatewayMainAskUserRequest } - > = (props) => { - const { boardId, data } = props ?? {}; - - return agentLeadAskUserViaGatewayMain(boardId, data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type AgentLeadAskUserViaGatewayMainMutationResult = NonNullable< - Awaited> ->; -export type AgentLeadAskUserViaGatewayMainMutationBody = - GatewayMainAskUserRequest; -export type AgentLeadAskUserViaGatewayMainMutationError = - | LLMErrorResponse - | HTTPValidationError; - -/** - * @summary Ask the human via gateway-main - */ -export const useAgentLeadAskUserViaGatewayMain = < - TError = LLMErrorResponse | HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: GatewayMainAskUserRequest }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; data: GatewayMainAskUserRequest }, - TContext -> => { - return useMutation( - getAgentLeadAskUserViaGatewayMainMutationOptions(options), - queryClient, - ); -}; -/** - * List board memory with optional chat filtering. - -Use `is_chat=false` for durable context and `is_chat=true` for board chat. - * @summary List Board Memory - */ -export type listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedBoardMemoryRead; - status: 200; -}; - -export type listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetResponseSuccess = - listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetResponse200 & { - headers: Headers; - }; -export type listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetResponseError = - listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetResponse422 & { - headers: Headers; - }; - -export type listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetResponse = - | listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetResponseSuccess - | listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetResponseError; - -export const getListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetUrl = ( - boardId: string, - params?: ListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/agent/boards/${boardId}/memory?${stringifiedParams}` - : `/api/v1/agent/boards/${boardId}/memory`; -}; - -export const listBoardMemoryApiV1AgentBoardsBoardIdMemoryGet = async ( - boardId: string, - params?: ListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetUrl(boardId, params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetQueryKey = ( - boardId: string, - params?: ListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams, -) => { - return [ - `/api/v1/agent/boards/${boardId}/memory`, - ...(params ? [params] : []), - ] as const; -}; - -export const getListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetQueryKey(boardId, params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listBoardMemoryApiV1AgentBoardsBoardIdMemoryGet(boardId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetQueryResult = - NonNullable< - Awaited> - >; -export type ListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetQueryError = - HTTPValidationError; - -export function useListBoardMemoryApiV1AgentBoardsBoardIdMemoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params: undefined | ListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardMemoryApiV1AgentBoardsBoardIdMemoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardMemoryApiV1AgentBoardsBoardIdMemoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Board Memory - */ - -export function useListBoardMemoryApiV1AgentBoardsBoardIdMemoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create a board memory entry. - -Use tags to indicate purpose (e.g. `chat`, `decision`, `plan`, `handoff`). - * @summary Create Board Memory - */ -export type createBoardMemoryApiV1AgentBoardsBoardIdMemoryPostResponse200 = { - data: BoardMemoryRead; - status: 200; -}; - -export type createBoardMemoryApiV1AgentBoardsBoardIdMemoryPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createBoardMemoryApiV1AgentBoardsBoardIdMemoryPostResponseSuccess = - createBoardMemoryApiV1AgentBoardsBoardIdMemoryPostResponse200 & { - headers: Headers; - }; -export type createBoardMemoryApiV1AgentBoardsBoardIdMemoryPostResponseError = - createBoardMemoryApiV1AgentBoardsBoardIdMemoryPostResponse422 & { - headers: Headers; - }; - -export type createBoardMemoryApiV1AgentBoardsBoardIdMemoryPostResponse = - | createBoardMemoryApiV1AgentBoardsBoardIdMemoryPostResponseSuccess - | createBoardMemoryApiV1AgentBoardsBoardIdMemoryPostResponseError; - -export const getCreateBoardMemoryApiV1AgentBoardsBoardIdMemoryPostUrl = ( - boardId: string, -) => { - return `/api/v1/agent/boards/${boardId}/memory`; -}; - -export const createBoardMemoryApiV1AgentBoardsBoardIdMemoryPost = async ( - boardId: string, - boardMemoryCreate: BoardMemoryCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateBoardMemoryApiV1AgentBoardsBoardIdMemoryPostUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardMemoryCreate), - }, - ); -}; - -export const getCreateBoardMemoryApiV1AgentBoardsBoardIdMemoryPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardMemoryCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardMemoryCreate }, - TContext - > => { - const mutationKey = ["createBoardMemoryApiV1AgentBoardsBoardIdMemoryPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType - >, - { boardId: string; data: BoardMemoryCreate } - > = (props) => { - const { boardId, data } = props ?? {}; - - return createBoardMemoryApiV1AgentBoardsBoardIdMemoryPost( - boardId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type CreateBoardMemoryApiV1AgentBoardsBoardIdMemoryPostMutationResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type CreateBoardMemoryApiV1AgentBoardsBoardIdMemoryPostMutationBody = - BoardMemoryCreate; -export type CreateBoardMemoryApiV1AgentBoardsBoardIdMemoryPostMutationError = - HTTPValidationError; - -/** - * @summary Create Board Memory - */ -export const useCreateBoardMemoryApiV1AgentBoardsBoardIdMemoryPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardMemoryCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardMemoryCreate }, - TContext -> => { - return useMutation( - getCreateBoardMemoryApiV1AgentBoardsBoardIdMemoryPostMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Apply board onboarding updates from an agent workflow. - -Used during structured objective/success-metric intake loops. - * @summary Update Onboarding - */ -export type updateOnboardingApiV1AgentBoardsBoardIdOnboardingPostResponse200 = { - data: BoardOnboardingRead; - status: 200; -}; - -export type updateOnboardingApiV1AgentBoardsBoardIdOnboardingPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type updateOnboardingApiV1AgentBoardsBoardIdOnboardingPostResponseSuccess = - updateOnboardingApiV1AgentBoardsBoardIdOnboardingPostResponse200 & { - headers: Headers; - }; -export type updateOnboardingApiV1AgentBoardsBoardIdOnboardingPostResponseError = - updateOnboardingApiV1AgentBoardsBoardIdOnboardingPostResponse422 & { - headers: Headers; - }; - -export type updateOnboardingApiV1AgentBoardsBoardIdOnboardingPostResponse = - | updateOnboardingApiV1AgentBoardsBoardIdOnboardingPostResponseSuccess - | updateOnboardingApiV1AgentBoardsBoardIdOnboardingPostResponseError; - -export const getUpdateOnboardingApiV1AgentBoardsBoardIdOnboardingPostUrl = ( - boardId: string, -) => { - return `/api/v1/agent/boards/${boardId}/onboarding`; -}; - -export const updateOnboardingApiV1AgentBoardsBoardIdOnboardingPost = async ( - boardId: string, - boardOnboardingAgentCompleteBoardOnboardingAgentQuestion: - | BoardOnboardingAgentComplete - | BoardOnboardingAgentQuestion, - options?: RequestInit, -): Promise => { - return customFetch( - getUpdateOnboardingApiV1AgentBoardsBoardIdOnboardingPostUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify( - boardOnboardingAgentCompleteBoardOnboardingAgentQuestion, - ), - }, - ); -}; - -export const getUpdateOnboardingApiV1AgentBoardsBoardIdOnboardingPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { - boardId: string; - data: BoardOnboardingAgentComplete | BoardOnboardingAgentQuestion; - }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { - boardId: string; - data: BoardOnboardingAgentComplete | BoardOnboardingAgentQuestion; - }, - TContext - > => { - const mutationKey = [ - "updateOnboardingApiV1AgentBoardsBoardIdOnboardingPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType - >, - { - boardId: string; - data: BoardOnboardingAgentComplete | BoardOnboardingAgentQuestion; - } - > = (props) => { - const { boardId, data } = props ?? {}; - - return updateOnboardingApiV1AgentBoardsBoardIdOnboardingPost( - boardId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type UpdateOnboardingApiV1AgentBoardsBoardIdOnboardingPostMutationResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type UpdateOnboardingApiV1AgentBoardsBoardIdOnboardingPostMutationBody = - | BoardOnboardingAgentComplete - | BoardOnboardingAgentQuestion; -export type UpdateOnboardingApiV1AgentBoardsBoardIdOnboardingPostMutationError = - HTTPValidationError; - -/** - * @summary Update Onboarding - */ -export const useUpdateOnboardingApiV1AgentBoardsBoardIdOnboardingPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { - boardId: string; - data: BoardOnboardingAgentComplete | BoardOnboardingAgentQuestion; - }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { - boardId: string; - data: BoardOnboardingAgentComplete | BoardOnboardingAgentQuestion; - }, - TContext -> => { - return useMutation( - getUpdateOnboardingApiV1AgentBoardsBoardIdOnboardingPostMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * List available tags for the board's organization. - -Use returned ids in task create/update payloads (`tag_ids`). - * @summary List Tags - */ -export type listTagsApiV1AgentBoardsBoardIdTagsGetResponse200 = { - data: TagRef[]; - status: 200; -}; - -export type listTagsApiV1AgentBoardsBoardIdTagsGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listTagsApiV1AgentBoardsBoardIdTagsGetResponseSuccess = - listTagsApiV1AgentBoardsBoardIdTagsGetResponse200 & { - headers: Headers; - }; -export type listTagsApiV1AgentBoardsBoardIdTagsGetResponseError = - listTagsApiV1AgentBoardsBoardIdTagsGetResponse422 & { - headers: Headers; - }; - -export type listTagsApiV1AgentBoardsBoardIdTagsGetResponse = - | listTagsApiV1AgentBoardsBoardIdTagsGetResponseSuccess - | listTagsApiV1AgentBoardsBoardIdTagsGetResponseError; - -export const getListTagsApiV1AgentBoardsBoardIdTagsGetUrl = ( - boardId: string, -) => { - return `/api/v1/agent/boards/${boardId}/tags`; -}; - -export const listTagsApiV1AgentBoardsBoardIdTagsGet = async ( - boardId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getListTagsApiV1AgentBoardsBoardIdTagsGetUrl(boardId), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListTagsApiV1AgentBoardsBoardIdTagsGetQueryKey = ( - boardId: string, -) => { - return [`/api/v1/agent/boards/${boardId}/tags`] as const; -}; - -export const getListTagsApiV1AgentBoardsBoardIdTagsGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListTagsApiV1AgentBoardsBoardIdTagsGetQueryKey(boardId); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listTagsApiV1AgentBoardsBoardIdTagsGet(boardId, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListTagsApiV1AgentBoardsBoardIdTagsGetQueryResult = NonNullable< - Awaited> ->; -export type ListTagsApiV1AgentBoardsBoardIdTagsGetQueryError = - HTTPValidationError; - -export function useListTagsApiV1AgentBoardsBoardIdTagsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListTagsApiV1AgentBoardsBoardIdTagsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListTagsApiV1AgentBoardsBoardIdTagsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Tags - */ - -export function useListTagsApiV1AgentBoardsBoardIdTagsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getListTagsApiV1AgentBoardsBoardIdTagsGetQueryOptions( - boardId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * List tasks on a board with status/assignment filters. - -Common patterns: -- worker: fetch assigned inbox/in-progress tasks -- lead: fetch unassigned inbox tasks for delegation - * @summary List Tasks - */ -export type listTasksApiV1AgentBoardsBoardIdTasksGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedTaskRead; - status: 200; -}; - -export type listTasksApiV1AgentBoardsBoardIdTasksGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listTasksApiV1AgentBoardsBoardIdTasksGetResponseSuccess = - listTasksApiV1AgentBoardsBoardIdTasksGetResponse200 & { - headers: Headers; - }; -export type listTasksApiV1AgentBoardsBoardIdTasksGetResponseError = - listTasksApiV1AgentBoardsBoardIdTasksGetResponse422 & { - headers: Headers; - }; - -export type listTasksApiV1AgentBoardsBoardIdTasksGetResponse = - | listTasksApiV1AgentBoardsBoardIdTasksGetResponseSuccess - | listTasksApiV1AgentBoardsBoardIdTasksGetResponseError; - -export const getListTasksApiV1AgentBoardsBoardIdTasksGetUrl = ( - boardId: string, - params?: ListTasksApiV1AgentBoardsBoardIdTasksGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/agent/boards/${boardId}/tasks?${stringifiedParams}` - : `/api/v1/agent/boards/${boardId}/tasks`; -}; - -export const listTasksApiV1AgentBoardsBoardIdTasksGet = async ( - boardId: string, - params?: ListTasksApiV1AgentBoardsBoardIdTasksGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListTasksApiV1AgentBoardsBoardIdTasksGetUrl(boardId, params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListTasksApiV1AgentBoardsBoardIdTasksGetQueryKey = ( - boardId: string, - params?: ListTasksApiV1AgentBoardsBoardIdTasksGetParams, -) => { - return [ - `/api/v1/agent/boards/${boardId}/tasks`, - ...(params ? [params] : []), - ] as const; -}; - -export const getListTasksApiV1AgentBoardsBoardIdTasksGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListTasksApiV1AgentBoardsBoardIdTasksGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListTasksApiV1AgentBoardsBoardIdTasksGetQueryKey(boardId, params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listTasksApiV1AgentBoardsBoardIdTasksGet(boardId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListTasksApiV1AgentBoardsBoardIdTasksGetQueryResult = NonNullable< - Awaited> ->; -export type ListTasksApiV1AgentBoardsBoardIdTasksGetQueryError = - HTTPValidationError; - -export function useListTasksApiV1AgentBoardsBoardIdTasksGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - params: undefined | ListTasksApiV1AgentBoardsBoardIdTasksGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListTasksApiV1AgentBoardsBoardIdTasksGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListTasksApiV1AgentBoardsBoardIdTasksGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListTasksApiV1AgentBoardsBoardIdTasksGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListTasksApiV1AgentBoardsBoardIdTasksGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Tasks - */ - -export function useListTasksApiV1AgentBoardsBoardIdTasksGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListTasksApiV1AgentBoardsBoardIdTasksGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getListTasksApiV1AgentBoardsBoardIdTasksGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create a new task on a board and persist lead metadata. - -Use when a lead needs to introduce new work, create dependencies, or directly assign ownership. -Do not use for task updates or comments; those are separate endpoints. - * @summary Create and assign a new board task as a lead agent - */ -export type agentLeadCreateTaskResponse200 = { - data: TaskRead; - status: 200; -}; - -export type agentLeadCreateTaskResponse403 = { - data: LLMErrorResponse; - status: 403; -}; - -export type agentLeadCreateTaskResponse404 = { - data: LLMErrorResponse; - status: 404; -}; - -export type agentLeadCreateTaskResponse409 = { - data: LLMErrorResponse; - status: 409; -}; - -export type agentLeadCreateTaskResponse422 = { - data: LLMErrorResponse; - status: 422; -}; - -export type agentLeadCreateTaskResponseSuccess = - agentLeadCreateTaskResponse200 & { - headers: Headers; - }; -export type agentLeadCreateTaskResponseError = ( - | agentLeadCreateTaskResponse403 - | agentLeadCreateTaskResponse404 - | agentLeadCreateTaskResponse409 - | agentLeadCreateTaskResponse422 -) & { - headers: Headers; -}; - -export type agentLeadCreateTaskResponse = - | agentLeadCreateTaskResponseSuccess - | agentLeadCreateTaskResponseError; - -export const getAgentLeadCreateTaskUrl = (boardId: string) => { - return `/api/v1/agent/boards/${boardId}/tasks`; -}; - -export const agentLeadCreateTask = async ( - boardId: string, - taskCreate: TaskCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getAgentLeadCreateTaskUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(taskCreate), - }, - ); -}; - -export const getAgentLeadCreateTaskMutationOptions = < - TError = LLMErrorResponse, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: TaskCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: TaskCreate }, - TContext -> => { - const mutationKey = ["agentLeadCreateTask"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string; data: TaskCreate } - > = (props) => { - const { boardId, data } = props ?? {}; - - return agentLeadCreateTask(boardId, data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type AgentLeadCreateTaskMutationResult = NonNullable< - Awaited> ->; -export type AgentLeadCreateTaskMutationBody = TaskCreate; -export type AgentLeadCreateTaskMutationError = LLMErrorResponse; - -/** - * @summary Create and assign a new board task as a lead agent - */ -export const useAgentLeadCreateTask = < - TError = LLMErrorResponse, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: TaskCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; data: TaskCreate }, - TContext -> => { - return useMutation( - getAgentLeadCreateTaskMutationOptions(options), - queryClient, - ); -}; -/** - * Delete a board task and related records. - -This action is restricted to board lead agents. - * @summary Delete a task as board lead - */ -export type deleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteResponse200 = { - data: OkResponse; - status: 200; -}; - -export type deleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type deleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteResponseSuccess = - deleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteResponseError = - deleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteResponse = - | deleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteResponseSuccess - | deleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteResponseError; - -export const getDeleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteUrl = ( - boardId: string, - taskId: string, -) => { - return `/api/v1/agent/boards/${boardId}/tasks/${taskId}`; -}; - -export const deleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDelete = async ( - boardId: string, - taskId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getDeleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteUrl(boardId, taskId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getDeleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; taskId: string }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; taskId: string }, - TContext - > => { - const mutationKey = ["deleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDelete"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType - >, - { boardId: string; taskId: string } - > = (props) => { - const { boardId, taskId } = props ?? {}; - - return deleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDelete( - boardId, - taskId, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type DeleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteMutationResult = - NonNullable< - Awaited< - ReturnType - > - >; - -export type DeleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Delete a task as board lead - */ -export const useDeleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; taskId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { boardId: string; taskId: string }, - TContext -> => { - return useMutation( - getDeleteTaskApiV1AgentBoardsBoardIdTasksTaskIdDeleteMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Update a task after board-level authorization checks. - -Supports status, assignment, dependencies, and optional inline comment. - * @summary Update Task - */ -export type updateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchResponse200 = { - data: TaskRead; - status: 200; -}; - -export type updateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type updateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchResponseSuccess = - updateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchResponse200 & { - headers: Headers; - }; -export type updateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchResponseError = - updateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchResponse422 & { - headers: Headers; - }; - -export type updateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchResponse = - | updateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchResponseSuccess - | updateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchResponseError; - -export const getUpdateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchUrl = ( - boardId: string, - taskId: string, -) => { - return `/api/v1/agent/boards/${boardId}/tasks/${taskId}`; -}; - -export const updateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatch = async ( - boardId: string, - taskId: string, - taskUpdate: TaskUpdate, - options?: RequestInit, -): Promise => { - return customFetch( - getUpdateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchUrl(boardId, taskId), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(taskUpdate), - }, - ); -}; - -export const getUpdateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; taskId: string; data: TaskUpdate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; taskId: string; data: TaskUpdate }, - TContext - > => { - const mutationKey = ["updateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatch"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType - >, - { boardId: string; taskId: string; data: TaskUpdate } - > = (props) => { - const { boardId, taskId, data } = props ?? {}; - - return updateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatch( - boardId, - taskId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type UpdateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchMutationResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type UpdateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchMutationBody = - TaskUpdate; -export type UpdateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchMutationError = - HTTPValidationError; - -/** - * @summary Update Task - */ -export const useUpdateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatch = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; taskId: string; data: TaskUpdate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; taskId: string; data: TaskUpdate }, - TContext -> => { - return useMutation( - getUpdateTaskApiV1AgentBoardsBoardIdTasksTaskIdPatchMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * List task comments visible to the authenticated agent. - -Read this before posting updates to avoid duplicate or low-value comments. - * @summary List Task Comments - */ -export type listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetResponse200 = - { - data: LimitOffsetPageTypeVarCustomizedTaskCommentRead; - status: 200; - }; - -export type listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetResponseSuccess = - listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetResponse200 & { - headers: Headers; - }; -export type listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetResponseError = - listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetResponse422 & { - headers: Headers; - }; - -export type listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetResponse = - - | listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetResponseSuccess - | listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetResponseError; - -export const getListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetUrl = - ( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams, - ) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append( - key, - value === null ? "null" : value.toString(), - ); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/agent/boards/${boardId}/tasks/${taskId}/comments?${stringifiedParams}` - : `/api/v1/agent/boards/${boardId}/tasks/${taskId}/comments`; - }; - -export const listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet = - async ( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams, - options?: RequestInit, - ): Promise => { - return customFetch( - getListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetUrl( - boardId, - taskId, - params, - ), - { - ...options, - method: "GET", - }, - ); - }; - -export const getListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetQueryKey = - ( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams, - ) => { - return [ - `/api/v1/agent/boards/${boardId}/tasks/${taskId}/comments`, - ...(params ? [params] : []), - ] as const; - }; - -export const getListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetQueryOptions = - < - TData = Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError = HTTPValidationError, - >( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetQueryKey( - boardId, - taskId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - > - > = ({ signal }) => - listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet( - boardId, - taskId, - params, - { signal, ...requestOptions }, - ); - - return { - queryKey, - queryFn, - enabled: !!(boardId && taskId), - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type ListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetQueryResult = - NonNullable< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - > - >; -export type ListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetQueryError = - HTTPValidationError; - -export function useListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet< - TData = Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - taskId: string, - params: - | undefined - | ListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet< - TData = Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet< - TData = Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Task Comments - */ - -export function useListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet< - TData = Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetQueryOptions( - boardId, - taskId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create a task comment as the authenticated agent. - -This is the primary collaboration/log surface for task progress. - * @summary Create Task Comment - */ -export type createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostResponse200 = - { - data: TaskCommentRead; - status: 200; - }; - -export type createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostResponseSuccess = - createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostResponse200 & { - headers: Headers; - }; -export type createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostResponseError = - createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostResponse422 & { - headers: Headers; - }; - -export type createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostResponse = - - | createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostResponseSuccess - | createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostResponseError; - -export const getCreateTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostUrl = - (boardId: string, taskId: string) => { - return `/api/v1/agent/boards/${boardId}/tasks/${taskId}/comments`; - }; - -export const createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPost = - async ( - boardId: string, - taskId: string, - taskCommentCreate: TaskCommentCreate, - options?: RequestInit, - ): Promise => { - return customFetch( - getCreateTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostUrl( - boardId, - taskId, - ), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(taskCommentCreate), - }, - ); - }; - -export const getCreateTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPost - > - >, - TError, - { boardId: string; taskId: string; data: TaskCommentCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPost - > - >, - TError, - { boardId: string; taskId: string; data: TaskCommentCreate }, - TContext - > => { - const mutationKey = [ - "createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPost - > - >, - { boardId: string; taskId: string; data: TaskCommentCreate } - > = (props) => { - const { boardId, taskId, data } = props ?? {}; - - return createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPost( - boardId, - taskId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type CreateTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPost - > - > - >; -export type CreateTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostMutationBody = - TaskCommentCreate; -export type CreateTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostMutationError = - HTTPValidationError; - -/** - * @summary Create Task Comment - */ -export const useCreateTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPost = - ( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPost - > - >, - TError, - { boardId: string; taskId: string; data: TaskCommentCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, - ): UseMutationResult< - Awaited< - ReturnType< - typeof createTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPost - > - >, - TError, - { boardId: string; taskId: string; data: TaskCommentCreate }, - TContext - > => { - return useMutation( - getCreateTaskCommentApiV1AgentBoardsBoardIdTasksTaskIdCommentsPostMutationOptions( - options, - ), - queryClient, - ); - }; -/** - * Route a direct lead handoff or question from an agent to the board lead. - -Use when a lead requires explicit, board-scoped routing. - * @summary Message board lead via gateway-main - */ -export type agentMainMessageBoardLeadResponse200 = { - data: GatewayLeadMessageResponse; - status: 200; -}; - -export type agentMainMessageBoardLeadResponse403 = { - data: LLMErrorResponse; - status: 403; -}; - -export type agentMainMessageBoardLeadResponse404 = { - data: LLMErrorResponse; - status: 404; -}; - -export type agentMainMessageBoardLeadResponse422 = { - data: LLMErrorResponse; - status: 422; -}; - -export type agentMainMessageBoardLeadResponse502 = { - data: LLMErrorResponse; - status: 502; -}; - -export type agentMainMessageBoardLeadResponseSuccess = - agentMainMessageBoardLeadResponse200 & { - headers: Headers; - }; -export type agentMainMessageBoardLeadResponseError = ( - | agentMainMessageBoardLeadResponse403 - | agentMainMessageBoardLeadResponse404 - | agentMainMessageBoardLeadResponse422 - | agentMainMessageBoardLeadResponse502 -) & { - headers: Headers; -}; - -export type agentMainMessageBoardLeadResponse = - | agentMainMessageBoardLeadResponseSuccess - | agentMainMessageBoardLeadResponseError; - -export const getAgentMainMessageBoardLeadUrl = (boardId: string) => { - return `/api/v1/agent/gateway/boards/${boardId}/lead/message`; -}; - -export const agentMainMessageBoardLead = async ( - boardId: string, - gatewayLeadMessageRequest: GatewayLeadMessageRequest, - options?: RequestInit, -): Promise => { - return customFetch( - getAgentMainMessageBoardLeadUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(gatewayLeadMessageRequest), - }, - ); -}; - -export const getAgentMainMessageBoardLeadMutationOptions = < - TError = LLMErrorResponse, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: GatewayLeadMessageRequest }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: GatewayLeadMessageRequest }, - TContext -> => { - const mutationKey = ["agentMainMessageBoardLead"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string; data: GatewayLeadMessageRequest } - > = (props) => { - const { boardId, data } = props ?? {}; - - return agentMainMessageBoardLead(boardId, data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type AgentMainMessageBoardLeadMutationResult = NonNullable< - Awaited> ->; -export type AgentMainMessageBoardLeadMutationBody = GatewayLeadMessageRequest; -export type AgentMainMessageBoardLeadMutationError = LLMErrorResponse; - -/** - * @summary Message board lead via gateway-main - */ -export const useAgentMainMessageBoardLead = < - TError = LLMErrorResponse, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: GatewayLeadMessageRequest }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; data: GatewayLeadMessageRequest }, - TContext -> => { - return useMutation( - getAgentMainMessageBoardLeadMutationOptions(options), - queryClient, - ); -}; -/** - * Send a shared coordination request to multiple board leads. - -Use for urgent cross-board or multi-lead fan-out patterns. - * @summary Broadcast a message to board leads via gateway-main - */ -export type agentMainBroadcastLeadMessageResponse200 = { - data: GatewayLeadBroadcastResponse; - status: 200; -}; - -export type agentMainBroadcastLeadMessageResponse403 = { - data: LLMErrorResponse; - status: 403; -}; - -export type agentMainBroadcastLeadMessageResponse404 = { - data: LLMErrorResponse; - status: 404; -}; - -export type agentMainBroadcastLeadMessageResponse422 = { - data: LLMErrorResponse; - status: 422; -}; - -export type agentMainBroadcastLeadMessageResponse502 = { - data: LLMErrorResponse; - status: 502; -}; - -export type agentMainBroadcastLeadMessageResponseSuccess = - agentMainBroadcastLeadMessageResponse200 & { - headers: Headers; - }; -export type agentMainBroadcastLeadMessageResponseError = ( - | agentMainBroadcastLeadMessageResponse403 - | agentMainBroadcastLeadMessageResponse404 - | agentMainBroadcastLeadMessageResponse422 - | agentMainBroadcastLeadMessageResponse502 -) & { - headers: Headers; -}; - -export type agentMainBroadcastLeadMessageResponse = - | agentMainBroadcastLeadMessageResponseSuccess - | agentMainBroadcastLeadMessageResponseError; - -export const getAgentMainBroadcastLeadMessageUrl = () => { - return `/api/v1/agent/gateway/leads/broadcast`; -}; - -export const agentMainBroadcastLeadMessage = async ( - gatewayLeadBroadcastRequest: GatewayLeadBroadcastRequest, - options?: RequestInit, -): Promise => { - return customFetch( - getAgentMainBroadcastLeadMessageUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(gatewayLeadBroadcastRequest), - }, - ); -}; - -export const getAgentMainBroadcastLeadMessageMutationOptions = < - TError = LLMErrorResponse, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: GatewayLeadBroadcastRequest }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { data: GatewayLeadBroadcastRequest }, - TContext -> => { - const mutationKey = ["agentMainBroadcastLeadMessage"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { data: GatewayLeadBroadcastRequest } - > = (props) => { - const { data } = props ?? {}; - - return agentMainBroadcastLeadMessage(data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type AgentMainBroadcastLeadMessageMutationResult = NonNullable< - Awaited> ->; -export type AgentMainBroadcastLeadMessageMutationBody = - GatewayLeadBroadcastRequest; -export type AgentMainBroadcastLeadMessageMutationError = LLMErrorResponse; - -/** - * @summary Broadcast a message to board leads via gateway-main - */ -export const useAgentMainBroadcastLeadMessage = < - TError = LLMErrorResponse, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: GatewayLeadBroadcastRequest }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: GatewayLeadBroadcastRequest }, - TContext -> => { - return useMutation( - getAgentMainBroadcastLeadMessageMutationOptions(options), - queryClient, - ); -}; -/** - * Token-authenticated liveness probe for agent API clients. - -Use this endpoint when the caller needs to verify both service availability and agent-token validity in one request. - * @summary Agent Auth Health Check - */ -export type agentHealthzApiV1AgentHealthzGetResponse200 = { - data: AgentHealthStatusResponse; - status: 200; -}; - -export type agentHealthzApiV1AgentHealthzGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type agentHealthzApiV1AgentHealthzGetResponseSuccess = - agentHealthzApiV1AgentHealthzGetResponse200 & { - headers: Headers; - }; -export type agentHealthzApiV1AgentHealthzGetResponseError = - agentHealthzApiV1AgentHealthzGetResponse422 & { - headers: Headers; - }; - -export type agentHealthzApiV1AgentHealthzGetResponse = - | agentHealthzApiV1AgentHealthzGetResponseSuccess - | agentHealthzApiV1AgentHealthzGetResponseError; - -export const getAgentHealthzApiV1AgentHealthzGetUrl = () => { - return `/api/v1/agent/healthz`; -}; - -export const agentHealthzApiV1AgentHealthzGet = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getAgentHealthzApiV1AgentHealthzGetUrl(), - { - ...options, - method: "GET", - }, - ); -}; - -export const getAgentHealthzApiV1AgentHealthzGetQueryKey = () => { - return [`/api/v1/agent/healthz`] as const; -}; - -export const getAgentHealthzApiV1AgentHealthzGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->(options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getAgentHealthzApiV1AgentHealthzGetQueryKey(); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - agentHealthzApiV1AgentHealthzGet({ signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type AgentHealthzApiV1AgentHealthzGetQueryResult = NonNullable< - Awaited> ->; -export type AgentHealthzApiV1AgentHealthzGetQueryError = HTTPValidationError; - -export function useAgentHealthzApiV1AgentHealthzGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useAgentHealthzApiV1AgentHealthzGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useAgentHealthzApiV1AgentHealthzGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Agent Auth Health Check - */ - -export function useAgentHealthzApiV1AgentHealthzGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getAgentHealthzApiV1AgentHealthzGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Record liveness for the authenticated agent. - -Use this when the agent heartbeat loop checks in. - * @summary Upsert agent heartbeat - */ -export type agentHeartbeatApiV1AgentHeartbeatPostResponse200 = { - data: AgentRead; - status: 200; -}; - -export type agentHeartbeatApiV1AgentHeartbeatPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type agentHeartbeatApiV1AgentHeartbeatPostResponseSuccess = - agentHeartbeatApiV1AgentHeartbeatPostResponse200 & { - headers: Headers; - }; -export type agentHeartbeatApiV1AgentHeartbeatPostResponseError = - agentHeartbeatApiV1AgentHeartbeatPostResponse422 & { - headers: Headers; - }; - -export type agentHeartbeatApiV1AgentHeartbeatPostResponse = - | agentHeartbeatApiV1AgentHeartbeatPostResponseSuccess - | agentHeartbeatApiV1AgentHeartbeatPostResponseError; - -export const getAgentHeartbeatApiV1AgentHeartbeatPostUrl = () => { - return `/api/v1/agent/heartbeat`; -}; - -export const agentHeartbeatApiV1AgentHeartbeatPost = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getAgentHeartbeatApiV1AgentHeartbeatPostUrl(), - { - ...options, - method: "POST", - }, - ); -}; - -export const getAgentHeartbeatApiV1AgentHeartbeatPostMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - void, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - void, - TContext -> => { - const mutationKey = ["agentHeartbeatApiV1AgentHeartbeatPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - void - > = () => { - return agentHeartbeatApiV1AgentHeartbeatPost(requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type AgentHeartbeatApiV1AgentHeartbeatPostMutationResult = NonNullable< - Awaited> ->; - -export type AgentHeartbeatApiV1AgentHeartbeatPostMutationError = - HTTPValidationError; - -/** - * @summary Upsert agent heartbeat - */ -export const useAgentHeartbeatApiV1AgentHeartbeatPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - void, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - void, - TContext -> => { - return useMutation( - getAgentHeartbeatApiV1AgentHeartbeatPostMutationOptions(options), - queryClient, - ); -}; diff --git a/src/frontend/src/api/generated/agents/agents.ts b/src/frontend/src/api/generated/agents/agents.ts deleted file mode 100644 index 81822c5..0000000 --- a/src/frontend/src/api/generated/agents/agents.ts +++ /dev/null @@ -1,1312 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - AgentCreate, - AgentHeartbeat, - AgentHeartbeatCreate, - AgentRead, - AgentUpdate, - HTTPValidationError, - LimitOffsetPageTypeVarCustomizedAgentRead, - ListAgentsApiV1AgentsGetParams, - OkResponse, - StreamAgentsApiV1AgentsStreamGetParams, - UpdateAgentApiV1AgentsAgentIdPatchParams, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List agents visible to the active organization admin. - * @summary List Agents - */ -export type listAgentsApiV1AgentsGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedAgentRead; - status: 200; -}; - -export type listAgentsApiV1AgentsGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listAgentsApiV1AgentsGetResponseSuccess = - listAgentsApiV1AgentsGetResponse200 & { - headers: Headers; - }; -export type listAgentsApiV1AgentsGetResponseError = - listAgentsApiV1AgentsGetResponse422 & { - headers: Headers; - }; - -export type listAgentsApiV1AgentsGetResponse = - | listAgentsApiV1AgentsGetResponseSuccess - | listAgentsApiV1AgentsGetResponseError; - -export const getListAgentsApiV1AgentsGetUrl = ( - params?: ListAgentsApiV1AgentsGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/agents?${stringifiedParams}` - : `/api/v1/agents`; -}; - -export const listAgentsApiV1AgentsGet = async ( - params?: ListAgentsApiV1AgentsGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListAgentsApiV1AgentsGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListAgentsApiV1AgentsGetQueryKey = ( - params?: ListAgentsApiV1AgentsGetParams, -) => { - return [`/api/v1/agents`, ...(params ? [params] : [])] as const; -}; - -export const getListAgentsApiV1AgentsGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListAgentsApiV1AgentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getListAgentsApiV1AgentsGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listAgentsApiV1AgentsGet(params, { signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListAgentsApiV1AgentsGetQueryResult = NonNullable< - Awaited> ->; -export type ListAgentsApiV1AgentsGetQueryError = HTTPValidationError; - -export function useListAgentsApiV1AgentsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params: undefined | ListAgentsApiV1AgentsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListAgentsApiV1AgentsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListAgentsApiV1AgentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListAgentsApiV1AgentsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListAgentsApiV1AgentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Agents - */ - -export function useListAgentsApiV1AgentsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListAgentsApiV1AgentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getListAgentsApiV1AgentsGetQueryOptions(params, options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create and provision an agent. - * @summary Create Agent - */ -export type createAgentApiV1AgentsPostResponse200 = { - data: AgentRead; - status: 200; -}; - -export type createAgentApiV1AgentsPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createAgentApiV1AgentsPostResponseSuccess = - createAgentApiV1AgentsPostResponse200 & { - headers: Headers; - }; -export type createAgentApiV1AgentsPostResponseError = - createAgentApiV1AgentsPostResponse422 & { - headers: Headers; - }; - -export type createAgentApiV1AgentsPostResponse = - | createAgentApiV1AgentsPostResponseSuccess - | createAgentApiV1AgentsPostResponseError; - -export const getCreateAgentApiV1AgentsPostUrl = () => { - return `/api/v1/agents`; -}; - -export const createAgentApiV1AgentsPost = async ( - agentCreate: AgentCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateAgentApiV1AgentsPostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(agentCreate), - }, - ); -}; - -export const getCreateAgentApiV1AgentsPostMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: AgentCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { data: AgentCreate }, - TContext -> => { - const mutationKey = ["createAgentApiV1AgentsPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { data: AgentCreate } - > = (props) => { - const { data } = props ?? {}; - - return createAgentApiV1AgentsPost(data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type CreateAgentApiV1AgentsPostMutationResult = NonNullable< - Awaited> ->; -export type CreateAgentApiV1AgentsPostMutationBody = AgentCreate; -export type CreateAgentApiV1AgentsPostMutationError = HTTPValidationError; - -/** - * @summary Create Agent - */ -export const useCreateAgentApiV1AgentsPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: AgentCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: AgentCreate }, - TContext -> => { - return useMutation( - getCreateAgentApiV1AgentsPostMutationOptions(options), - queryClient, - ); -}; -/** - * Heartbeat an existing agent or create/provision one if needed. - * @summary Heartbeat Or Create Agent - */ -export type heartbeatOrCreateAgentApiV1AgentsHeartbeatPostResponse200 = { - data: AgentRead; - status: 200; -}; - -export type heartbeatOrCreateAgentApiV1AgentsHeartbeatPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type heartbeatOrCreateAgentApiV1AgentsHeartbeatPostResponseSuccess = - heartbeatOrCreateAgentApiV1AgentsHeartbeatPostResponse200 & { - headers: Headers; - }; -export type heartbeatOrCreateAgentApiV1AgentsHeartbeatPostResponseError = - heartbeatOrCreateAgentApiV1AgentsHeartbeatPostResponse422 & { - headers: Headers; - }; - -export type heartbeatOrCreateAgentApiV1AgentsHeartbeatPostResponse = - | heartbeatOrCreateAgentApiV1AgentsHeartbeatPostResponseSuccess - | heartbeatOrCreateAgentApiV1AgentsHeartbeatPostResponseError; - -export const getHeartbeatOrCreateAgentApiV1AgentsHeartbeatPostUrl = () => { - return `/api/v1/agents/heartbeat`; -}; - -export const heartbeatOrCreateAgentApiV1AgentsHeartbeatPost = async ( - agentHeartbeatCreate: AgentHeartbeatCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getHeartbeatOrCreateAgentApiV1AgentsHeartbeatPostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(agentHeartbeatCreate), - }, - ); -}; - -export const getHeartbeatOrCreateAgentApiV1AgentsHeartbeatPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: AgentHeartbeatCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited>, - TError, - { data: AgentHeartbeatCreate }, - TContext - > => { - const mutationKey = ["heartbeatOrCreateAgentApiV1AgentsHeartbeatPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType - >, - { data: AgentHeartbeatCreate } - > = (props) => { - const { data } = props ?? {}; - - return heartbeatOrCreateAgentApiV1AgentsHeartbeatPost( - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type HeartbeatOrCreateAgentApiV1AgentsHeartbeatPostMutationResult = - NonNullable< - Awaited> - >; -export type HeartbeatOrCreateAgentApiV1AgentsHeartbeatPostMutationBody = - AgentHeartbeatCreate; -export type HeartbeatOrCreateAgentApiV1AgentsHeartbeatPostMutationError = - HTTPValidationError; - -/** - * @summary Heartbeat Or Create Agent - */ -export const useHeartbeatOrCreateAgentApiV1AgentsHeartbeatPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: AgentHeartbeatCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: AgentHeartbeatCreate }, - TContext -> => { - return useMutation( - getHeartbeatOrCreateAgentApiV1AgentsHeartbeatPostMutationOptions(options), - queryClient, - ); -}; -/** - * Stream agent updates as SSE events. - * @summary Stream Agents - */ -export type streamAgentsApiV1AgentsStreamGetResponse200 = { - data: unknown; - status: 200; -}; - -export type streamAgentsApiV1AgentsStreamGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type streamAgentsApiV1AgentsStreamGetResponseSuccess = - streamAgentsApiV1AgentsStreamGetResponse200 & { - headers: Headers; - }; -export type streamAgentsApiV1AgentsStreamGetResponseError = - streamAgentsApiV1AgentsStreamGetResponse422 & { - headers: Headers; - }; - -export type streamAgentsApiV1AgentsStreamGetResponse = - | streamAgentsApiV1AgentsStreamGetResponseSuccess - | streamAgentsApiV1AgentsStreamGetResponseError; - -export const getStreamAgentsApiV1AgentsStreamGetUrl = ( - params?: StreamAgentsApiV1AgentsStreamGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/agents/stream?${stringifiedParams}` - : `/api/v1/agents/stream`; -}; - -export const streamAgentsApiV1AgentsStreamGet = async ( - params?: StreamAgentsApiV1AgentsStreamGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getStreamAgentsApiV1AgentsStreamGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getStreamAgentsApiV1AgentsStreamGetQueryKey = ( - params?: StreamAgentsApiV1AgentsStreamGetParams, -) => { - return [`/api/v1/agents/stream`, ...(params ? [params] : [])] as const; -}; - -export const getStreamAgentsApiV1AgentsStreamGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: StreamAgentsApiV1AgentsStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getStreamAgentsApiV1AgentsStreamGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - streamAgentsApiV1AgentsStreamGet(params, { signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type StreamAgentsApiV1AgentsStreamGetQueryResult = NonNullable< - Awaited> ->; -export type StreamAgentsApiV1AgentsStreamGetQueryError = HTTPValidationError; - -export function useStreamAgentsApiV1AgentsStreamGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params: undefined | StreamAgentsApiV1AgentsStreamGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useStreamAgentsApiV1AgentsStreamGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: StreamAgentsApiV1AgentsStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useStreamAgentsApiV1AgentsStreamGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: StreamAgentsApiV1AgentsStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Stream Agents - */ - -export function useStreamAgentsApiV1AgentsStreamGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: StreamAgentsApiV1AgentsStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getStreamAgentsApiV1AgentsStreamGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Delete an agent and clean related task state. - * @summary Delete Agent - */ -export type deleteAgentApiV1AgentsAgentIdDeleteResponse200 = { - data: OkResponse; - status: 200; -}; - -export type deleteAgentApiV1AgentsAgentIdDeleteResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type deleteAgentApiV1AgentsAgentIdDeleteResponseSuccess = - deleteAgentApiV1AgentsAgentIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteAgentApiV1AgentsAgentIdDeleteResponseError = - deleteAgentApiV1AgentsAgentIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteAgentApiV1AgentsAgentIdDeleteResponse = - | deleteAgentApiV1AgentsAgentIdDeleteResponseSuccess - | deleteAgentApiV1AgentsAgentIdDeleteResponseError; - -export const getDeleteAgentApiV1AgentsAgentIdDeleteUrl = (agentId: string) => { - return `/api/v1/agents/${agentId}`; -}; - -export const deleteAgentApiV1AgentsAgentIdDelete = async ( - agentId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getDeleteAgentApiV1AgentsAgentIdDeleteUrl(agentId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getDeleteAgentApiV1AgentsAgentIdDeleteMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { agentId: string }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { agentId: string }, - TContext -> => { - const mutationKey = ["deleteAgentApiV1AgentsAgentIdDelete"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { agentId: string } - > = (props) => { - const { agentId } = props ?? {}; - - return deleteAgentApiV1AgentsAgentIdDelete(agentId, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type DeleteAgentApiV1AgentsAgentIdDeleteMutationResult = NonNullable< - Awaited> ->; - -export type DeleteAgentApiV1AgentsAgentIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Delete Agent - */ -export const useDeleteAgentApiV1AgentsAgentIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { agentId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { agentId: string }, - TContext -> => { - return useMutation( - getDeleteAgentApiV1AgentsAgentIdDeleteMutationOptions(options), - queryClient, - ); -}; -/** - * Get a single agent by id. - * @summary Get Agent - */ -export type getAgentApiV1AgentsAgentIdGetResponse200 = { - data: AgentRead; - status: 200; -}; - -export type getAgentApiV1AgentsAgentIdGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getAgentApiV1AgentsAgentIdGetResponseSuccess = - getAgentApiV1AgentsAgentIdGetResponse200 & { - headers: Headers; - }; -export type getAgentApiV1AgentsAgentIdGetResponseError = - getAgentApiV1AgentsAgentIdGetResponse422 & { - headers: Headers; - }; - -export type getAgentApiV1AgentsAgentIdGetResponse = - | getAgentApiV1AgentsAgentIdGetResponseSuccess - | getAgentApiV1AgentsAgentIdGetResponseError; - -export const getGetAgentApiV1AgentsAgentIdGetUrl = (agentId: string) => { - return `/api/v1/agents/${agentId}`; -}; - -export const getAgentApiV1AgentsAgentIdGet = async ( - agentId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetAgentApiV1AgentsAgentIdGetUrl(agentId), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetAgentApiV1AgentsAgentIdGetQueryKey = (agentId: string) => { - return [`/api/v1/agents/${agentId}`] as const; -}; - -export const getGetAgentApiV1AgentsAgentIdGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - agentId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getGetAgentApiV1AgentsAgentIdGetQueryKey(agentId); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getAgentApiV1AgentsAgentIdGet(agentId, { signal, ...requestOptions }); - - return { - queryKey, - queryFn, - enabled: !!agentId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetAgentApiV1AgentsAgentIdGetQueryResult = NonNullable< - Awaited> ->; -export type GetAgentApiV1AgentsAgentIdGetQueryError = HTTPValidationError; - -export function useGetAgentApiV1AgentsAgentIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - agentId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetAgentApiV1AgentsAgentIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - agentId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetAgentApiV1AgentsAgentIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - agentId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Agent - */ - -export function useGetAgentApiV1AgentsAgentIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - agentId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getGetAgentApiV1AgentsAgentIdGetQueryOptions( - agentId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Update agent metadata and optionally reprovision. - * @summary Update Agent - */ -export type updateAgentApiV1AgentsAgentIdPatchResponse200 = { - data: AgentRead; - status: 200; -}; - -export type updateAgentApiV1AgentsAgentIdPatchResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type updateAgentApiV1AgentsAgentIdPatchResponseSuccess = - updateAgentApiV1AgentsAgentIdPatchResponse200 & { - headers: Headers; - }; -export type updateAgentApiV1AgentsAgentIdPatchResponseError = - updateAgentApiV1AgentsAgentIdPatchResponse422 & { - headers: Headers; - }; - -export type updateAgentApiV1AgentsAgentIdPatchResponse = - | updateAgentApiV1AgentsAgentIdPatchResponseSuccess - | updateAgentApiV1AgentsAgentIdPatchResponseError; - -export const getUpdateAgentApiV1AgentsAgentIdPatchUrl = ( - agentId: string, - params?: UpdateAgentApiV1AgentsAgentIdPatchParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/agents/${agentId}?${stringifiedParams}` - : `/api/v1/agents/${agentId}`; -}; - -export const updateAgentApiV1AgentsAgentIdPatch = async ( - agentId: string, - agentUpdate: AgentUpdate, - params?: UpdateAgentApiV1AgentsAgentIdPatchParams, - options?: RequestInit, -): Promise => { - return customFetch( - getUpdateAgentApiV1AgentsAgentIdPatchUrl(agentId, params), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(agentUpdate), - }, - ); -}; - -export const getUpdateAgentApiV1AgentsAgentIdPatchMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { - agentId: string; - data: AgentUpdate; - params?: UpdateAgentApiV1AgentsAgentIdPatchParams; - }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { - agentId: string; - data: AgentUpdate; - params?: UpdateAgentApiV1AgentsAgentIdPatchParams; - }, - TContext -> => { - const mutationKey = ["updateAgentApiV1AgentsAgentIdPatch"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { - agentId: string; - data: AgentUpdate; - params?: UpdateAgentApiV1AgentsAgentIdPatchParams; - } - > = (props) => { - const { agentId, data, params } = props ?? {}; - - return updateAgentApiV1AgentsAgentIdPatch( - agentId, - data, - params, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type UpdateAgentApiV1AgentsAgentIdPatchMutationResult = NonNullable< - Awaited> ->; -export type UpdateAgentApiV1AgentsAgentIdPatchMutationBody = AgentUpdate; -export type UpdateAgentApiV1AgentsAgentIdPatchMutationError = - HTTPValidationError; - -/** - * @summary Update Agent - */ -export const useUpdateAgentApiV1AgentsAgentIdPatch = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { - agentId: string; - data: AgentUpdate; - params?: UpdateAgentApiV1AgentsAgentIdPatchParams; - }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { - agentId: string; - data: AgentUpdate; - params?: UpdateAgentApiV1AgentsAgentIdPatchParams; - }, - TContext -> => { - return useMutation( - getUpdateAgentApiV1AgentsAgentIdPatchMutationOptions(options), - queryClient, - ); -}; -/** - * Record a heartbeat for a specific agent. - * @summary Heartbeat Agent - */ -export type heartbeatAgentApiV1AgentsAgentIdHeartbeatPostResponse200 = { - data: AgentRead; - status: 200; -}; - -export type heartbeatAgentApiV1AgentsAgentIdHeartbeatPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type heartbeatAgentApiV1AgentsAgentIdHeartbeatPostResponseSuccess = - heartbeatAgentApiV1AgentsAgentIdHeartbeatPostResponse200 & { - headers: Headers; - }; -export type heartbeatAgentApiV1AgentsAgentIdHeartbeatPostResponseError = - heartbeatAgentApiV1AgentsAgentIdHeartbeatPostResponse422 & { - headers: Headers; - }; - -export type heartbeatAgentApiV1AgentsAgentIdHeartbeatPostResponse = - | heartbeatAgentApiV1AgentsAgentIdHeartbeatPostResponseSuccess - | heartbeatAgentApiV1AgentsAgentIdHeartbeatPostResponseError; - -export const getHeartbeatAgentApiV1AgentsAgentIdHeartbeatPostUrl = ( - agentId: string, -) => { - return `/api/v1/agents/${agentId}/heartbeat`; -}; - -export const heartbeatAgentApiV1AgentsAgentIdHeartbeatPost = async ( - agentId: string, - agentHeartbeat: AgentHeartbeat, - options?: RequestInit, -): Promise => { - return customFetch( - getHeartbeatAgentApiV1AgentsAgentIdHeartbeatPostUrl(agentId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(agentHeartbeat), - }, - ); -}; - -export const getHeartbeatAgentApiV1AgentsAgentIdHeartbeatPostMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { agentId: string; data: AgentHeartbeat }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { agentId: string; data: AgentHeartbeat }, - TContext -> => { - const mutationKey = ["heartbeatAgentApiV1AgentsAgentIdHeartbeatPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { agentId: string; data: AgentHeartbeat } - > = (props) => { - const { agentId, data } = props ?? {}; - - return heartbeatAgentApiV1AgentsAgentIdHeartbeatPost( - agentId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type HeartbeatAgentApiV1AgentsAgentIdHeartbeatPostMutationResult = - NonNullable< - Awaited> - >; -export type HeartbeatAgentApiV1AgentsAgentIdHeartbeatPostMutationBody = - AgentHeartbeat; -export type HeartbeatAgentApiV1AgentsAgentIdHeartbeatPostMutationError = - HTTPValidationError; - -/** - * @summary Heartbeat Agent - */ -export const useHeartbeatAgentApiV1AgentsAgentIdHeartbeatPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { agentId: string; data: AgentHeartbeat }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { agentId: string; data: AgentHeartbeat }, - TContext -> => { - return useMutation( - getHeartbeatAgentApiV1AgentsAgentIdHeartbeatPostMutationOptions(options), - queryClient, - ); -}; diff --git a/src/frontend/src/api/generated/approvals/approvals.ts b/src/frontend/src/api/generated/approvals/approvals.ts deleted file mode 100644 index f618b5a..0000000 --- a/src/frontend/src/api/generated/approvals/approvals.ts +++ /dev/null @@ -1,860 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - ApprovalCreate, - ApprovalRead, - ApprovalUpdate, - HTTPValidationError, - LimitOffsetPageTypeVarCustomizedApprovalRead, - ListApprovalsApiV1BoardsBoardIdApprovalsGetParams, - StreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List approvals for a board, optionally filtering by status. - * @summary List Approvals - */ -export type listApprovalsApiV1BoardsBoardIdApprovalsGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedApprovalRead; - status: 200; -}; - -export type listApprovalsApiV1BoardsBoardIdApprovalsGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listApprovalsApiV1BoardsBoardIdApprovalsGetResponseSuccess = - listApprovalsApiV1BoardsBoardIdApprovalsGetResponse200 & { - headers: Headers; - }; -export type listApprovalsApiV1BoardsBoardIdApprovalsGetResponseError = - listApprovalsApiV1BoardsBoardIdApprovalsGetResponse422 & { - headers: Headers; - }; - -export type listApprovalsApiV1BoardsBoardIdApprovalsGetResponse = - | listApprovalsApiV1BoardsBoardIdApprovalsGetResponseSuccess - | listApprovalsApiV1BoardsBoardIdApprovalsGetResponseError; - -export const getListApprovalsApiV1BoardsBoardIdApprovalsGetUrl = ( - boardId: string, - params?: ListApprovalsApiV1BoardsBoardIdApprovalsGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards/${boardId}/approvals?${stringifiedParams}` - : `/api/v1/boards/${boardId}/approvals`; -}; - -export const listApprovalsApiV1BoardsBoardIdApprovalsGet = async ( - boardId: string, - params?: ListApprovalsApiV1BoardsBoardIdApprovalsGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListApprovalsApiV1BoardsBoardIdApprovalsGetUrl(boardId, params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListApprovalsApiV1BoardsBoardIdApprovalsGetQueryKey = ( - boardId: string, - params?: ListApprovalsApiV1BoardsBoardIdApprovalsGetParams, -) => { - return [ - `/api/v1/boards/${boardId}/approvals`, - ...(params ? [params] : []), - ] as const; -}; - -export const getListApprovalsApiV1BoardsBoardIdApprovalsGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListApprovalsApiV1BoardsBoardIdApprovalsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListApprovalsApiV1BoardsBoardIdApprovalsGetQueryKey(boardId, params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listApprovalsApiV1BoardsBoardIdApprovalsGet(boardId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListApprovalsApiV1BoardsBoardIdApprovalsGetQueryResult = - NonNullable< - Awaited> - >; -export type ListApprovalsApiV1BoardsBoardIdApprovalsGetQueryError = - HTTPValidationError; - -export function useListApprovalsApiV1BoardsBoardIdApprovalsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params: undefined | ListApprovalsApiV1BoardsBoardIdApprovalsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListApprovalsApiV1BoardsBoardIdApprovalsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListApprovalsApiV1BoardsBoardIdApprovalsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListApprovalsApiV1BoardsBoardIdApprovalsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListApprovalsApiV1BoardsBoardIdApprovalsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Approvals - */ - -export function useListApprovalsApiV1BoardsBoardIdApprovalsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListApprovalsApiV1BoardsBoardIdApprovalsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListApprovalsApiV1BoardsBoardIdApprovalsGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create an approval for a board. - * @summary Create Approval - */ -export type createApprovalApiV1BoardsBoardIdApprovalsPostResponse200 = { - data: ApprovalRead; - status: 200; -}; - -export type createApprovalApiV1BoardsBoardIdApprovalsPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createApprovalApiV1BoardsBoardIdApprovalsPostResponseSuccess = - createApprovalApiV1BoardsBoardIdApprovalsPostResponse200 & { - headers: Headers; - }; -export type createApprovalApiV1BoardsBoardIdApprovalsPostResponseError = - createApprovalApiV1BoardsBoardIdApprovalsPostResponse422 & { - headers: Headers; - }; - -export type createApprovalApiV1BoardsBoardIdApprovalsPostResponse = - | createApprovalApiV1BoardsBoardIdApprovalsPostResponseSuccess - | createApprovalApiV1BoardsBoardIdApprovalsPostResponseError; - -export const getCreateApprovalApiV1BoardsBoardIdApprovalsPostUrl = ( - boardId: string, -) => { - return `/api/v1/boards/${boardId}/approvals`; -}; - -export const createApprovalApiV1BoardsBoardIdApprovalsPost = async ( - boardId: string, - approvalCreate: ApprovalCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateApprovalApiV1BoardsBoardIdApprovalsPostUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(approvalCreate), - }, - ); -}; - -export const getCreateApprovalApiV1BoardsBoardIdApprovalsPostMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: ApprovalCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: ApprovalCreate }, - TContext -> => { - const mutationKey = ["createApprovalApiV1BoardsBoardIdApprovalsPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string; data: ApprovalCreate } - > = (props) => { - const { boardId, data } = props ?? {}; - - return createApprovalApiV1BoardsBoardIdApprovalsPost( - boardId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type CreateApprovalApiV1BoardsBoardIdApprovalsPostMutationResult = - NonNullable< - Awaited> - >; -export type CreateApprovalApiV1BoardsBoardIdApprovalsPostMutationBody = - ApprovalCreate; -export type CreateApprovalApiV1BoardsBoardIdApprovalsPostMutationError = - HTTPValidationError; - -/** - * @summary Create Approval - */ -export const useCreateApprovalApiV1BoardsBoardIdApprovalsPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: ApprovalCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; data: ApprovalCreate }, - TContext -> => { - return useMutation( - getCreateApprovalApiV1BoardsBoardIdApprovalsPostMutationOptions(options), - queryClient, - ); -}; -/** - * Stream approval updates for a board using server-sent events. - * @summary Stream Approvals - */ -export type streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetResponse200 = { - data: unknown; - status: 200; -}; - -export type streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetResponseSuccess = - streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetResponse200 & { - headers: Headers; - }; -export type streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetResponseError = - streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetResponse422 & { - headers: Headers; - }; - -export type streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetResponse = - | streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetResponseSuccess - | streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetResponseError; - -export const getStreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetUrl = ( - boardId: string, - params?: StreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards/${boardId}/approvals/stream?${stringifiedParams}` - : `/api/v1/boards/${boardId}/approvals/stream`; -}; - -export const streamApprovalsApiV1BoardsBoardIdApprovalsStreamGet = async ( - boardId: string, - params?: StreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getStreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetUrl(boardId, params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getStreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetQueryKey = ( - boardId: string, - params?: StreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams, -) => { - return [ - `/api/v1/boards/${boardId}/approvals/stream`, - ...(params ? [params] : []), - ] as const; -}; - -export const getStreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetQueryOptions = - < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, - >( - boardId: string, - params?: StreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamApprovalsApiV1BoardsBoardIdApprovalsStreamGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getStreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetQueryKey( - boardId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType - > - > = ({ signal }) => - streamApprovalsApiV1BoardsBoardIdApprovalsStreamGet(boardId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type StreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetQueryResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type StreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetQueryError = - HTTPValidationError; - -export function useStreamApprovalsApiV1BoardsBoardIdApprovalsStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params: undefined | StreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof streamApprovalsApiV1BoardsBoardIdApprovalsStreamGet - > - >, - TError, - Awaited< - ReturnType< - typeof streamApprovalsApiV1BoardsBoardIdApprovalsStreamGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useStreamApprovalsApiV1BoardsBoardIdApprovalsStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof streamApprovalsApiV1BoardsBoardIdApprovalsStreamGet - > - >, - TError, - Awaited< - ReturnType< - typeof streamApprovalsApiV1BoardsBoardIdApprovalsStreamGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useStreamApprovalsApiV1BoardsBoardIdApprovalsStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Stream Approvals - */ - -export function useStreamApprovalsApiV1BoardsBoardIdApprovalsStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getStreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Update an approval's status and resolution timestamp. - * @summary Update Approval - */ -export type updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchResponse200 = - { - data: ApprovalRead; - status: 200; - }; - -export type updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchResponseSuccess = - updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchResponse200 & { - headers: Headers; - }; -export type updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchResponseError = - updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchResponse422 & { - headers: Headers; - }; - -export type updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchResponse = - | updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchResponseSuccess - | updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchResponseError; - -export const getUpdateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchUrl = ( - boardId: string, - approvalId: string, -) => { - return `/api/v1/boards/${boardId}/approvals/${approvalId}`; -}; - -export const updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatch = async ( - boardId: string, - approvalId: string, - approvalUpdate: ApprovalUpdate, - options?: RequestInit, -): Promise => { - return customFetch( - getUpdateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchUrl( - boardId, - approvalId, - ), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(approvalUpdate), - }, - ); -}; - -export const getUpdateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatch - > - >, - TError, - { boardId: string; approvalId: string; data: ApprovalUpdate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatch - > - >, - TError, - { boardId: string; approvalId: string; data: ApprovalUpdate }, - TContext - > => { - const mutationKey = [ - "updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatch", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatch - > - >, - { boardId: string; approvalId: string; data: ApprovalUpdate } - > = (props) => { - const { boardId, approvalId, data } = props ?? {}; - - return updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatch( - boardId, - approvalId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type UpdateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatch - > - > - >; -export type UpdateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchMutationBody = - ApprovalUpdate; -export type UpdateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchMutationError = - HTTPValidationError; - -/** - * @summary Update Approval - */ -export const useUpdateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatch = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatch - > - >, - TError, - { boardId: string; approvalId: string; data: ApprovalUpdate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { boardId: string; approvalId: string; data: ApprovalUpdate }, - TContext -> => { - return useMutation( - getUpdateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatchMutationOptions( - options, - ), - queryClient, - ); -}; diff --git a/src/frontend/src/api/generated/auth/auth.ts b/src/frontend/src/api/generated/auth/auth.ts deleted file mode 100644 index cd6e0ac..0000000 --- a/src/frontend/src/api/generated/auth/auth.ts +++ /dev/null @@ -1,133 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation } from "@tanstack/react-query"; -import type { - MutationFunction, - QueryClient, - UseMutationOptions, - UseMutationResult, -} from "@tanstack/react-query"; - -import type { LLMErrorResponse, UserRead } from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * Resolve caller identity from auth headers and return the canonical user profile. This endpoint does not accept a request body. - * @summary Bootstrap Authenticated User Context - */ -export type bootstrapUserApiV1AuthBootstrapPostResponse200 = { - data: UserRead; - status: 200; -}; - -export type bootstrapUserApiV1AuthBootstrapPostResponse401 = { - data: LLMErrorResponse; - status: 401; -}; - -export type bootstrapUserApiV1AuthBootstrapPostResponseSuccess = - bootstrapUserApiV1AuthBootstrapPostResponse200 & { - headers: Headers; - }; -export type bootstrapUserApiV1AuthBootstrapPostResponseError = - bootstrapUserApiV1AuthBootstrapPostResponse401 & { - headers: Headers; - }; - -export type bootstrapUserApiV1AuthBootstrapPostResponse = - | bootstrapUserApiV1AuthBootstrapPostResponseSuccess - | bootstrapUserApiV1AuthBootstrapPostResponseError; - -export const getBootstrapUserApiV1AuthBootstrapPostUrl = () => { - return `/api/v1/auth/bootstrap`; -}; - -export const bootstrapUserApiV1AuthBootstrapPost = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getBootstrapUserApiV1AuthBootstrapPostUrl(), - { - ...options, - method: "POST", - }, - ); -}; - -export const getBootstrapUserApiV1AuthBootstrapPostMutationOptions = < - TError = LLMErrorResponse, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - void, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - void, - TContext -> => { - const mutationKey = ["bootstrapUserApiV1AuthBootstrapPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - void - > = () => { - return bootstrapUserApiV1AuthBootstrapPost(requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type BootstrapUserApiV1AuthBootstrapPostMutationResult = NonNullable< - Awaited> ->; - -export type BootstrapUserApiV1AuthBootstrapPostMutationError = LLMErrorResponse; - -/** - * @summary Bootstrap Authenticated User Context - */ -export const useBootstrapUserApiV1AuthBootstrapPost = < - TError = LLMErrorResponse, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - void, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - void, - TContext -> => { - return useMutation( - getBootstrapUserApiV1AuthBootstrapPostMutationOptions(options), - queryClient, - ); -}; diff --git a/src/frontend/src/api/generated/board-group-memory/board-group-memory.ts b/src/frontend/src/api/generated/board-group-memory/board-group-memory.ts deleted file mode 100644 index 852841d..0000000 --- a/src/frontend/src/api/generated/board-group-memory/board-group-memory.ts +++ /dev/null @@ -1,1607 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - BoardGroupMemoryCreate, - BoardGroupMemoryRead, - HTTPValidationError, - LimitOffsetPageTypeVarCustomizedBoardGroupMemoryRead, - ListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams, - ListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams, - StreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams, - StreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List board-group memory entries for a specific group. - * @summary List Board Group Memory - */ -export type listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedBoardGroupMemoryRead; - status: 200; -}; - -export type listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetResponseSuccess = - listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetResponse200 & { - headers: Headers; - }; -export type listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetResponseError = - listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetResponse422 & { - headers: Headers; - }; - -export type listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetResponse = - | listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetResponseSuccess - | listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetResponseError; - -export const getListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetUrl = ( - groupId: string, - params?: ListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/board-groups/${groupId}/memory?${stringifiedParams}` - : `/api/v1/board-groups/${groupId}/memory`; -}; - -export const listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet = async ( - groupId: string, - params?: ListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetUrl(groupId, params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetQueryKey = ( - groupId: string, - params?: ListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams, -) => { - return [ - `/api/v1/board-groups/${groupId}/memory`, - ...(params ? [params] : []), - ] as const; -}; - -export const getListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetQueryOptions = - < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, - >( - groupId: string, - params?: ListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetQueryKey( - groupId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType - > - > = ({ signal }) => - listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet(groupId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!groupId, - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type ListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetQueryResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type ListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetQueryError = - HTTPValidationError; - -export function useListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - groupId: string, - params: - | undefined - | ListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet - > - >, - TError, - Awaited< - ReturnType< - typeof listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - groupId: string, - params?: ListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet - > - >, - TError, - Awaited< - ReturnType< - typeof listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - groupId: string, - params?: ListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Board Group Memory - */ - -export function useListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - groupId: string, - params?: ListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetQueryOptions( - groupId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create a board-group memory entry and notify chat recipients. - * @summary Create Board Group Memory - */ -export type createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostResponse200 = - { - data: BoardGroupMemoryRead; - status: 200; - }; - -export type createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostResponseSuccess = - createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostResponse200 & { - headers: Headers; - }; -export type createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostResponseError = - createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostResponse422 & { - headers: Headers; - }; - -export type createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostResponse = - | createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostResponseSuccess - | createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostResponseError; - -export const getCreateBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostUrl = ( - groupId: string, -) => { - return `/api/v1/board-groups/${groupId}/memory`; -}; - -export const createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPost = async ( - groupId: string, - boardGroupMemoryCreate: BoardGroupMemoryCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostUrl(groupId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardGroupMemoryCreate), - }, - ); -}; - -export const getCreateBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPost - > - >, - TError, - { groupId: string; data: BoardGroupMemoryCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { groupId: string; data: BoardGroupMemoryCreate }, - TContext - > => { - const mutationKey = [ - "createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPost - > - >, - { groupId: string; data: BoardGroupMemoryCreate } - > = (props) => { - const { groupId, data } = props ?? {}; - - return createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPost( - groupId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type CreateBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostMutationResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type CreateBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostMutationBody = - BoardGroupMemoryCreate; -export type CreateBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostMutationError = - HTTPValidationError; - -/** - * @summary Create Board Group Memory - */ -export const useCreateBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof createBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPost - > - >, - TError, - { groupId: string; data: BoardGroupMemoryCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { groupId: string; data: BoardGroupMemoryCreate }, - TContext -> => { - return useMutation( - getCreateBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryPostMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Stream memory entries for a board group via server-sent events. - * @summary Stream Board Group Memory - */ -export type streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetResponse200 = - { - data: unknown; - status: 200; - }; - -export type streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetResponseSuccess = - streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetResponse200 & { - headers: Headers; - }; -export type streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetResponseError = - streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetResponse422 & { - headers: Headers; - }; - -export type streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetResponse = - - | streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetResponseSuccess - | streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetResponseError; - -export const getStreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetUrl = - ( - groupId: string, - params?: StreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams, - ) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append( - key, - value === null ? "null" : value.toString(), - ); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/board-groups/${groupId}/memory/stream?${stringifiedParams}` - : `/api/v1/board-groups/${groupId}/memory/stream`; - }; - -export const streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet = - async ( - groupId: string, - params?: StreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams, - options?: RequestInit, - ): Promise => { - return customFetch( - getStreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetUrl( - groupId, - params, - ), - { - ...options, - method: "GET", - }, - ); - }; - -export const getStreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetQueryKey = - ( - groupId: string, - params?: StreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams, - ) => { - return [ - `/api/v1/board-groups/${groupId}/memory/stream`, - ...(params ? [params] : []), - ] as const; - }; - -export const getStreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetQueryOptions = - < - TData = Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError = HTTPValidationError, - >( - groupId: string, - params?: StreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getStreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetQueryKey( - groupId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - > - > = ({ signal }) => - streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet( - groupId, - params, - { signal, ...requestOptions }, - ); - - return { - queryKey, - queryFn, - enabled: !!groupId, - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type StreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetQueryResult = - NonNullable< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - > - >; -export type StreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetQueryError = - HTTPValidationError; - -export function useStreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet< - TData = Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError = HTTPValidationError, ->( - groupId: string, - params: - | undefined - | StreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError, - Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useStreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet< - TData = Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError = HTTPValidationError, ->( - groupId: string, - params?: StreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError, - Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useStreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet< - TData = Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError = HTTPValidationError, ->( - groupId: string, - params?: StreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Stream Board Group Memory - */ - -export function useStreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet< - TData = Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError = HTTPValidationError, ->( - groupId: string, - params?: StreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getStreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetQueryOptions( - groupId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * List shared memory for the board's linked group. - -Use this for cross-board context and coordination signals. - * @summary List Board Group Memory For Board - */ -export type listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetResponse200 = - { - data: LimitOffsetPageTypeVarCustomizedBoardGroupMemoryRead; - status: 200; - }; - -export type listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetResponseSuccess = - listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetResponse200 & { - headers: Headers; - }; -export type listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetResponseError = - listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetResponse422 & { - headers: Headers; - }; - -export type listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetResponse = - - | listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetResponseSuccess - | listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetResponseError; - -export const getListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetUrl = - ( - boardId: string, - params?: ListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams, - ) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append( - key, - value === null ? "null" : value.toString(), - ); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards/${boardId}/group-memory?${stringifiedParams}` - : `/api/v1/boards/${boardId}/group-memory`; - }; - -export const listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet = - async ( - boardId: string, - params?: ListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams, - options?: RequestInit, - ): Promise => { - return customFetch( - getListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetUrl( - boardId, - params, - ), - { - ...options, - method: "GET", - }, - ); - }; - -export const getListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetQueryKey = - ( - boardId: string, - params?: ListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams, - ) => { - return [ - `/api/v1/boards/${boardId}/group-memory`, - ...(params ? [params] : []), - ] as const; - }; - -export const getListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetQueryOptions = - < - TData = Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError = HTTPValidationError, - >( - boardId: string, - params?: ListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetQueryKey( - boardId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - > - > = ({ signal }) => - listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet( - boardId, - params, - { signal, ...requestOptions }, - ); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type ListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetQueryResult = - NonNullable< - Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - > - >; -export type ListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetQueryError = - HTTPValidationError; - -export function useListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet< - TData = Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - params: - | undefined - | ListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError, - Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet< - TData = Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError, - Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet< - TData = Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Board Group Memory For Board - */ - -export function useListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet< - TData = Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create shared group memory from a board context. - -When tags/mentions indicate chat or broadcast intent, eligible agents in the -linked group are notified. - * @summary Create Board Group Memory For Board - */ -export type createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostResponse200 = - { - data: BoardGroupMemoryRead; - status: 200; - }; - -export type createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostResponseSuccess = - createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostResponse200 & { - headers: Headers; - }; -export type createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostResponseError = - createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostResponse422 & { - headers: Headers; - }; - -export type createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostResponse = - - | createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostResponseSuccess - | createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostResponseError; - -export const getCreateBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostUrl = - (boardId: string) => { - return `/api/v1/boards/${boardId}/group-memory`; - }; - -export const createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPost = - async ( - boardId: string, - boardGroupMemoryCreate: BoardGroupMemoryCreate, - options?: RequestInit, - ): Promise => { - return customFetch( - getCreateBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostUrl( - boardId, - ), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardGroupMemoryCreate), - }, - ); - }; - -export const getCreateBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPost - > - >, - TError, - { boardId: string; data: BoardGroupMemoryCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPost - > - >, - TError, - { boardId: string; data: BoardGroupMemoryCreate }, - TContext - > => { - const mutationKey = [ - "createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPost - > - >, - { boardId: string; data: BoardGroupMemoryCreate } - > = (props) => { - const { boardId, data } = props ?? {}; - - return createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPost( - boardId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type CreateBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPost - > - > - >; -export type CreateBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostMutationBody = - BoardGroupMemoryCreate; -export type CreateBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostMutationError = - HTTPValidationError; - -/** - * @summary Create Board Group Memory For Board - */ -export const useCreateBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPost = - ( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPost - > - >, - TError, - { boardId: string; data: BoardGroupMemoryCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, - ): UseMutationResult< - Awaited< - ReturnType< - typeof createBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPost - > - >, - TError, - { boardId: string; data: BoardGroupMemoryCreate }, - TContext - > => { - return useMutation( - getCreateBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryPostMutationOptions( - options, - ), - queryClient, - ); - }; -/** - * Stream linked-group memory via SSE for near-real-time coordination. - * @summary Stream Board Group Memory For Board - */ -export type streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetResponse200 = - { - data: unknown; - status: 200; - }; - -export type streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetResponseSuccess = - streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetResponse200 & { - headers: Headers; - }; -export type streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetResponseError = - streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetResponse422 & { - headers: Headers; - }; - -export type streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetResponse = - - | streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetResponseSuccess - | streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetResponseError; - -export const getStreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetUrl = - ( - boardId: string, - params?: StreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams, - ) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append( - key, - value === null ? "null" : value.toString(), - ); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards/${boardId}/group-memory/stream?${stringifiedParams}` - : `/api/v1/boards/${boardId}/group-memory/stream`; - }; - -export const streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet = - async ( - boardId: string, - params?: StreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams, - options?: RequestInit, - ): Promise => { - return customFetch( - getStreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetUrl( - boardId, - params, - ), - { - ...options, - method: "GET", - }, - ); - }; - -export const getStreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetQueryKey = - ( - boardId: string, - params?: StreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams, - ) => { - return [ - `/api/v1/boards/${boardId}/group-memory/stream`, - ...(params ? [params] : []), - ] as const; - }; - -export const getStreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetQueryOptions = - < - TData = Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError = HTTPValidationError, - >( - boardId: string, - params?: StreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getStreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetQueryKey( - boardId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - > - > = ({ signal }) => - streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet( - boardId, - params, - { signal, ...requestOptions }, - ); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type StreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetQueryResult = - NonNullable< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - > - >; -export type StreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetQueryError = - HTTPValidationError; - -export function useStreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet< - TData = Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - params: - | undefined - | StreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError, - Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useStreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet< - TData = Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError, - Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useStreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet< - TData = Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Stream Board Group Memory For Board - */ - -export function useStreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet< - TData = Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getStreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} diff --git a/src/frontend/src/api/generated/board-groups/board-groups.ts b/src/frontend/src/api/generated/board-groups/board-groups.ts deleted file mode 100644 index ceb6c86..0000000 --- a/src/frontend/src/api/generated/board-groups/board-groups.ts +++ /dev/null @@ -1,1292 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - BoardGroupCreate, - BoardGroupHeartbeatApply, - BoardGroupHeartbeatApplyResult, - BoardGroupRead, - BoardGroupSnapshot, - BoardGroupUpdate, - GetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams, - HTTPValidationError, - LimitOffsetPageTypeVarCustomizedBoardGroupRead, - ListBoardGroupsApiV1BoardGroupsGetParams, - OkResponse, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List board groups in the active organization. - * @summary List Board Groups - */ -export type listBoardGroupsApiV1BoardGroupsGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedBoardGroupRead; - status: 200; -}; - -export type listBoardGroupsApiV1BoardGroupsGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listBoardGroupsApiV1BoardGroupsGetResponseSuccess = - listBoardGroupsApiV1BoardGroupsGetResponse200 & { - headers: Headers; - }; -export type listBoardGroupsApiV1BoardGroupsGetResponseError = - listBoardGroupsApiV1BoardGroupsGetResponse422 & { - headers: Headers; - }; - -export type listBoardGroupsApiV1BoardGroupsGetResponse = - | listBoardGroupsApiV1BoardGroupsGetResponseSuccess - | listBoardGroupsApiV1BoardGroupsGetResponseError; - -export const getListBoardGroupsApiV1BoardGroupsGetUrl = ( - params?: ListBoardGroupsApiV1BoardGroupsGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/board-groups?${stringifiedParams}` - : `/api/v1/board-groups`; -}; - -export const listBoardGroupsApiV1BoardGroupsGet = async ( - params?: ListBoardGroupsApiV1BoardGroupsGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListBoardGroupsApiV1BoardGroupsGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListBoardGroupsApiV1BoardGroupsGetQueryKey = ( - params?: ListBoardGroupsApiV1BoardGroupsGetParams, -) => { - return [`/api/v1/board-groups`, ...(params ? [params] : [])] as const; -}; - -export const getListBoardGroupsApiV1BoardGroupsGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListBoardGroupsApiV1BoardGroupsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListBoardGroupsApiV1BoardGroupsGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listBoardGroupsApiV1BoardGroupsGet(params, { signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListBoardGroupsApiV1BoardGroupsGetQueryResult = NonNullable< - Awaited> ->; -export type ListBoardGroupsApiV1BoardGroupsGetQueryError = HTTPValidationError; - -export function useListBoardGroupsApiV1BoardGroupsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params: undefined | ListBoardGroupsApiV1BoardGroupsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardGroupsApiV1BoardGroupsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListBoardGroupsApiV1BoardGroupsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardGroupsApiV1BoardGroupsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListBoardGroupsApiV1BoardGroupsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Board Groups - */ - -export function useListBoardGroupsApiV1BoardGroupsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListBoardGroupsApiV1BoardGroupsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getListBoardGroupsApiV1BoardGroupsGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create a board group in the active organization. - * @summary Create Board Group - */ -export type createBoardGroupApiV1BoardGroupsPostResponse200 = { - data: BoardGroupRead; - status: 200; -}; - -export type createBoardGroupApiV1BoardGroupsPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createBoardGroupApiV1BoardGroupsPostResponseSuccess = - createBoardGroupApiV1BoardGroupsPostResponse200 & { - headers: Headers; - }; -export type createBoardGroupApiV1BoardGroupsPostResponseError = - createBoardGroupApiV1BoardGroupsPostResponse422 & { - headers: Headers; - }; - -export type createBoardGroupApiV1BoardGroupsPostResponse = - | createBoardGroupApiV1BoardGroupsPostResponseSuccess - | createBoardGroupApiV1BoardGroupsPostResponseError; - -export const getCreateBoardGroupApiV1BoardGroupsPostUrl = () => { - return `/api/v1/board-groups`; -}; - -export const createBoardGroupApiV1BoardGroupsPost = async ( - boardGroupCreate: BoardGroupCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateBoardGroupApiV1BoardGroupsPostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardGroupCreate), - }, - ); -}; - -export const getCreateBoardGroupApiV1BoardGroupsPostMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: BoardGroupCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { data: BoardGroupCreate }, - TContext -> => { - const mutationKey = ["createBoardGroupApiV1BoardGroupsPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { data: BoardGroupCreate } - > = (props) => { - const { data } = props ?? {}; - - return createBoardGroupApiV1BoardGroupsPost(data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type CreateBoardGroupApiV1BoardGroupsPostMutationResult = NonNullable< - Awaited> ->; -export type CreateBoardGroupApiV1BoardGroupsPostMutationBody = BoardGroupCreate; -export type CreateBoardGroupApiV1BoardGroupsPostMutationError = - HTTPValidationError; - -/** - * @summary Create Board Group - */ -export const useCreateBoardGroupApiV1BoardGroupsPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: BoardGroupCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: BoardGroupCreate }, - TContext -> => { - return useMutation( - getCreateBoardGroupApiV1BoardGroupsPostMutationOptions(options), - queryClient, - ); -}; -/** - * Delete a board group. - * @summary Delete Board Group - */ -export type deleteBoardGroupApiV1BoardGroupsGroupIdDeleteResponse200 = { - data: OkResponse; - status: 200; -}; - -export type deleteBoardGroupApiV1BoardGroupsGroupIdDeleteResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type deleteBoardGroupApiV1BoardGroupsGroupIdDeleteResponseSuccess = - deleteBoardGroupApiV1BoardGroupsGroupIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteBoardGroupApiV1BoardGroupsGroupIdDeleteResponseError = - deleteBoardGroupApiV1BoardGroupsGroupIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteBoardGroupApiV1BoardGroupsGroupIdDeleteResponse = - | deleteBoardGroupApiV1BoardGroupsGroupIdDeleteResponseSuccess - | deleteBoardGroupApiV1BoardGroupsGroupIdDeleteResponseError; - -export const getDeleteBoardGroupApiV1BoardGroupsGroupIdDeleteUrl = ( - groupId: string, -) => { - return `/api/v1/board-groups/${groupId}`; -}; - -export const deleteBoardGroupApiV1BoardGroupsGroupIdDelete = async ( - groupId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getDeleteBoardGroupApiV1BoardGroupsGroupIdDeleteUrl(groupId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getDeleteBoardGroupApiV1BoardGroupsGroupIdDeleteMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { groupId: string }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { groupId: string }, - TContext -> => { - const mutationKey = ["deleteBoardGroupApiV1BoardGroupsGroupIdDelete"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { groupId: string } - > = (props) => { - const { groupId } = props ?? {}; - - return deleteBoardGroupApiV1BoardGroupsGroupIdDelete( - groupId, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type DeleteBoardGroupApiV1BoardGroupsGroupIdDeleteMutationResult = - NonNullable< - Awaited> - >; - -export type DeleteBoardGroupApiV1BoardGroupsGroupIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Delete Board Group - */ -export const useDeleteBoardGroupApiV1BoardGroupsGroupIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { groupId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { groupId: string }, - TContext -> => { - return useMutation( - getDeleteBoardGroupApiV1BoardGroupsGroupIdDeleteMutationOptions(options), - queryClient, - ); -}; -/** - * Get a board group by id. - * @summary Get Board Group - */ -export type getBoardGroupApiV1BoardGroupsGroupIdGetResponse200 = { - data: BoardGroupRead; - status: 200; -}; - -export type getBoardGroupApiV1BoardGroupsGroupIdGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getBoardGroupApiV1BoardGroupsGroupIdGetResponseSuccess = - getBoardGroupApiV1BoardGroupsGroupIdGetResponse200 & { - headers: Headers; - }; -export type getBoardGroupApiV1BoardGroupsGroupIdGetResponseError = - getBoardGroupApiV1BoardGroupsGroupIdGetResponse422 & { - headers: Headers; - }; - -export type getBoardGroupApiV1BoardGroupsGroupIdGetResponse = - | getBoardGroupApiV1BoardGroupsGroupIdGetResponseSuccess - | getBoardGroupApiV1BoardGroupsGroupIdGetResponseError; - -export const getGetBoardGroupApiV1BoardGroupsGroupIdGetUrl = ( - groupId: string, -) => { - return `/api/v1/board-groups/${groupId}`; -}; - -export const getBoardGroupApiV1BoardGroupsGroupIdGet = async ( - groupId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetBoardGroupApiV1BoardGroupsGroupIdGetUrl(groupId), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetBoardGroupApiV1BoardGroupsGroupIdGetQueryKey = ( - groupId: string, -) => { - return [`/api/v1/board-groups/${groupId}`] as const; -}; - -export const getGetBoardGroupApiV1BoardGroupsGroupIdGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - groupId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetBoardGroupApiV1BoardGroupsGroupIdGetQueryKey(groupId); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getBoardGroupApiV1BoardGroupsGroupIdGet(groupId, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!groupId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetBoardGroupApiV1BoardGroupsGroupIdGetQueryResult = NonNullable< - Awaited> ->; -export type GetBoardGroupApiV1BoardGroupsGroupIdGetQueryError = - HTTPValidationError; - -export function useGetBoardGroupApiV1BoardGroupsGroupIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - groupId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardGroupApiV1BoardGroupsGroupIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - groupId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardGroupApiV1BoardGroupsGroupIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - groupId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Board Group - */ - -export function useGetBoardGroupApiV1BoardGroupsGroupIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - groupId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getGetBoardGroupApiV1BoardGroupsGroupIdGetQueryOptions( - groupId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Update a board group. - * @summary Update Board Group - */ -export type updateBoardGroupApiV1BoardGroupsGroupIdPatchResponse200 = { - data: BoardGroupRead; - status: 200; -}; - -export type updateBoardGroupApiV1BoardGroupsGroupIdPatchResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type updateBoardGroupApiV1BoardGroupsGroupIdPatchResponseSuccess = - updateBoardGroupApiV1BoardGroupsGroupIdPatchResponse200 & { - headers: Headers; - }; -export type updateBoardGroupApiV1BoardGroupsGroupIdPatchResponseError = - updateBoardGroupApiV1BoardGroupsGroupIdPatchResponse422 & { - headers: Headers; - }; - -export type updateBoardGroupApiV1BoardGroupsGroupIdPatchResponse = - | updateBoardGroupApiV1BoardGroupsGroupIdPatchResponseSuccess - | updateBoardGroupApiV1BoardGroupsGroupIdPatchResponseError; - -export const getUpdateBoardGroupApiV1BoardGroupsGroupIdPatchUrl = ( - groupId: string, -) => { - return `/api/v1/board-groups/${groupId}`; -}; - -export const updateBoardGroupApiV1BoardGroupsGroupIdPatch = async ( - groupId: string, - boardGroupUpdate: BoardGroupUpdate, - options?: RequestInit, -): Promise => { - return customFetch( - getUpdateBoardGroupApiV1BoardGroupsGroupIdPatchUrl(groupId), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardGroupUpdate), - }, - ); -}; - -export const getUpdateBoardGroupApiV1BoardGroupsGroupIdPatchMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { groupId: string; data: BoardGroupUpdate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { groupId: string; data: BoardGroupUpdate }, - TContext -> => { - const mutationKey = ["updateBoardGroupApiV1BoardGroupsGroupIdPatch"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { groupId: string; data: BoardGroupUpdate } - > = (props) => { - const { groupId, data } = props ?? {}; - - return updateBoardGroupApiV1BoardGroupsGroupIdPatch( - groupId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type UpdateBoardGroupApiV1BoardGroupsGroupIdPatchMutationResult = - NonNullable< - Awaited> - >; -export type UpdateBoardGroupApiV1BoardGroupsGroupIdPatchMutationBody = - BoardGroupUpdate; -export type UpdateBoardGroupApiV1BoardGroupsGroupIdPatchMutationError = - HTTPValidationError; - -/** - * @summary Update Board Group - */ -export const useUpdateBoardGroupApiV1BoardGroupsGroupIdPatch = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { groupId: string; data: BoardGroupUpdate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { groupId: string; data: BoardGroupUpdate }, - TContext -> => { - return useMutation( - getUpdateBoardGroupApiV1BoardGroupsGroupIdPatchMutationOptions(options), - queryClient, - ); -}; -/** - * Apply heartbeat settings to agents in a board group. - * @summary Apply Board Group Heartbeat - */ -export type applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostResponse200 = - { - data: BoardGroupHeartbeatApplyResult; - status: 200; - }; - -export type applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostResponseSuccess = - applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostResponse200 & { - headers: Headers; - }; -export type applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostResponseError = - applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostResponse422 & { - headers: Headers; - }; - -export type applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostResponse = - - | applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostResponseSuccess - | applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostResponseError; - -export const getApplyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostUrl = - (groupId: string) => { - return `/api/v1/board-groups/${groupId}/heartbeat`; - }; - -export const applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPost = - async ( - groupId: string, - boardGroupHeartbeatApply: BoardGroupHeartbeatApply, - options?: RequestInit, - ): Promise => { - return customFetch( - getApplyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostUrl( - groupId, - ), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardGroupHeartbeatApply), - }, - ); - }; - -export const getApplyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPost - > - >, - TError, - { groupId: string; data: BoardGroupHeartbeatApply }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPost - > - >, - TError, - { groupId: string; data: BoardGroupHeartbeatApply }, - TContext - > => { - const mutationKey = [ - "applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPost - > - >, - { groupId: string; data: BoardGroupHeartbeatApply } - > = (props) => { - const { groupId, data } = props ?? {}; - - return applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPost( - groupId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type ApplyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPost - > - > - >; -export type ApplyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostMutationBody = - BoardGroupHeartbeatApply; -export type ApplyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostMutationError = - HTTPValidationError; - -/** - * @summary Apply Board Group Heartbeat - */ -export const useApplyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPost - > - >, - TError, - { groupId: string; data: BoardGroupHeartbeatApply }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType< - typeof applyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPost - > - >, - TError, - { groupId: string; data: BoardGroupHeartbeatApply }, - TContext -> => { - return useMutation( - getApplyBoardGroupHeartbeatApiV1BoardGroupsGroupIdHeartbeatPostMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Get a snapshot across boards in a group. - * @summary Get Board Group Snapshot - */ -export type getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetResponse200 = - { - data: BoardGroupSnapshot; - status: 200; - }; - -export type getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetResponseSuccess = - getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetResponse200 & { - headers: Headers; - }; -export type getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetResponseError = - getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetResponse422 & { - headers: Headers; - }; - -export type getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetResponse = - | getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetResponseSuccess - | getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetResponseError; - -export const getGetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetUrl = ( - groupId: string, - params?: GetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/board-groups/${groupId}/snapshot?${stringifiedParams}` - : `/api/v1/board-groups/${groupId}/snapshot`; -}; - -export const getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet = async ( - groupId: string, - params?: GetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getGetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetUrl( - groupId, - params, - ), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetQueryKey = - ( - groupId: string, - params?: GetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams, - ) => { - return [ - `/api/v1/board-groups/${groupId}/snapshot`, - ...(params ? [params] : []), - ] as const; - }; - -export const getGetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetQueryOptions = - < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, - >( - groupId: string, - params?: GetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetQueryKey( - groupId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet - > - > - > = ({ signal }) => - getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet(groupId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!groupId, - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type GetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetQueryResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type GetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetQueryError = - HTTPValidationError; - -export function useGetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - groupId: string, - params: - | undefined - | GetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet - > - >, - TError, - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - groupId: string, - params?: GetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet - > - >, - TError, - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - groupId: string, - params?: GetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Board Group Snapshot - */ - -export function useGetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - groupId: string, - params?: GetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetQueryOptions( - groupId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} diff --git a/src/frontend/src/api/generated/board-memory/board-memory.ts b/src/frontend/src/api/generated/board-memory/board-memory.ts deleted file mode 100644 index b558707..0000000 --- a/src/frontend/src/api/generated/board-memory/board-memory.ts +++ /dev/null @@ -1,693 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - BoardMemoryCreate, - BoardMemoryRead, - HTTPValidationError, - LimitOffsetPageTypeVarCustomizedBoardMemoryRead, - ListBoardMemoryApiV1BoardsBoardIdMemoryGetParams, - StreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List board memory entries, optionally filtering chat entries. - * @summary List Board Memory - */ -export type listBoardMemoryApiV1BoardsBoardIdMemoryGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedBoardMemoryRead; - status: 200; -}; - -export type listBoardMemoryApiV1BoardsBoardIdMemoryGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listBoardMemoryApiV1BoardsBoardIdMemoryGetResponseSuccess = - listBoardMemoryApiV1BoardsBoardIdMemoryGetResponse200 & { - headers: Headers; - }; -export type listBoardMemoryApiV1BoardsBoardIdMemoryGetResponseError = - listBoardMemoryApiV1BoardsBoardIdMemoryGetResponse422 & { - headers: Headers; - }; - -export type listBoardMemoryApiV1BoardsBoardIdMemoryGetResponse = - | listBoardMemoryApiV1BoardsBoardIdMemoryGetResponseSuccess - | listBoardMemoryApiV1BoardsBoardIdMemoryGetResponseError; - -export const getListBoardMemoryApiV1BoardsBoardIdMemoryGetUrl = ( - boardId: string, - params?: ListBoardMemoryApiV1BoardsBoardIdMemoryGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards/${boardId}/memory?${stringifiedParams}` - : `/api/v1/boards/${boardId}/memory`; -}; - -export const listBoardMemoryApiV1BoardsBoardIdMemoryGet = async ( - boardId: string, - params?: ListBoardMemoryApiV1BoardsBoardIdMemoryGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListBoardMemoryApiV1BoardsBoardIdMemoryGetUrl(boardId, params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListBoardMemoryApiV1BoardsBoardIdMemoryGetQueryKey = ( - boardId: string, - params?: ListBoardMemoryApiV1BoardsBoardIdMemoryGetParams, -) => { - return [ - `/api/v1/boards/${boardId}/memory`, - ...(params ? [params] : []), - ] as const; -}; - -export const getListBoardMemoryApiV1BoardsBoardIdMemoryGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardMemoryApiV1BoardsBoardIdMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListBoardMemoryApiV1BoardsBoardIdMemoryGetQueryKey(boardId, params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listBoardMemoryApiV1BoardsBoardIdMemoryGet(boardId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListBoardMemoryApiV1BoardsBoardIdMemoryGetQueryResult = NonNullable< - Awaited> ->; -export type ListBoardMemoryApiV1BoardsBoardIdMemoryGetQueryError = - HTTPValidationError; - -export function useListBoardMemoryApiV1BoardsBoardIdMemoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params: undefined | ListBoardMemoryApiV1BoardsBoardIdMemoryGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardMemoryApiV1BoardsBoardIdMemoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardMemoryApiV1BoardsBoardIdMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardMemoryApiV1BoardsBoardIdMemoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardMemoryApiV1BoardsBoardIdMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Board Memory - */ - -export function useListBoardMemoryApiV1BoardsBoardIdMemoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardMemoryApiV1BoardsBoardIdMemoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListBoardMemoryApiV1BoardsBoardIdMemoryGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create a board memory entry and notify chat targets when needed. - * @summary Create Board Memory - */ -export type createBoardMemoryApiV1BoardsBoardIdMemoryPostResponse200 = { - data: BoardMemoryRead; - status: 200; -}; - -export type createBoardMemoryApiV1BoardsBoardIdMemoryPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createBoardMemoryApiV1BoardsBoardIdMemoryPostResponseSuccess = - createBoardMemoryApiV1BoardsBoardIdMemoryPostResponse200 & { - headers: Headers; - }; -export type createBoardMemoryApiV1BoardsBoardIdMemoryPostResponseError = - createBoardMemoryApiV1BoardsBoardIdMemoryPostResponse422 & { - headers: Headers; - }; - -export type createBoardMemoryApiV1BoardsBoardIdMemoryPostResponse = - | createBoardMemoryApiV1BoardsBoardIdMemoryPostResponseSuccess - | createBoardMemoryApiV1BoardsBoardIdMemoryPostResponseError; - -export const getCreateBoardMemoryApiV1BoardsBoardIdMemoryPostUrl = ( - boardId: string, -) => { - return `/api/v1/boards/${boardId}/memory`; -}; - -export const createBoardMemoryApiV1BoardsBoardIdMemoryPost = async ( - boardId: string, - boardMemoryCreate: BoardMemoryCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateBoardMemoryApiV1BoardsBoardIdMemoryPostUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardMemoryCreate), - }, - ); -}; - -export const getCreateBoardMemoryApiV1BoardsBoardIdMemoryPostMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: BoardMemoryCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: BoardMemoryCreate }, - TContext -> => { - const mutationKey = ["createBoardMemoryApiV1BoardsBoardIdMemoryPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string; data: BoardMemoryCreate } - > = (props) => { - const { boardId, data } = props ?? {}; - - return createBoardMemoryApiV1BoardsBoardIdMemoryPost( - boardId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type CreateBoardMemoryApiV1BoardsBoardIdMemoryPostMutationResult = - NonNullable< - Awaited> - >; -export type CreateBoardMemoryApiV1BoardsBoardIdMemoryPostMutationBody = - BoardMemoryCreate; -export type CreateBoardMemoryApiV1BoardsBoardIdMemoryPostMutationError = - HTTPValidationError; - -/** - * @summary Create Board Memory - */ -export const useCreateBoardMemoryApiV1BoardsBoardIdMemoryPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: BoardMemoryCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; data: BoardMemoryCreate }, - TContext -> => { - return useMutation( - getCreateBoardMemoryApiV1BoardsBoardIdMemoryPostMutationOptions(options), - queryClient, - ); -}; -/** - * Stream board memory events over server-sent events. - * @summary Stream Board Memory - */ -export type streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetResponse200 = { - data: unknown; - status: 200; -}; - -export type streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetResponseSuccess = - streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetResponse200 & { - headers: Headers; - }; -export type streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetResponseError = - streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetResponse422 & { - headers: Headers; - }; - -export type streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetResponse = - | streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetResponseSuccess - | streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetResponseError; - -export const getStreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetUrl = ( - boardId: string, - params?: StreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards/${boardId}/memory/stream?${stringifiedParams}` - : `/api/v1/boards/${boardId}/memory/stream`; -}; - -export const streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet = async ( - boardId: string, - params?: StreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getStreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetUrl(boardId, params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getStreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetQueryKey = ( - boardId: string, - params?: StreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams, -) => { - return [ - `/api/v1/boards/${boardId}/memory/stream`, - ...(params ? [params] : []), - ] as const; -}; - -export const getStreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetQueryOptions = - < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, - >( - boardId: string, - params?: StreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getStreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetQueryKey( - boardId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType - > - > = ({ signal }) => - streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet(boardId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type StreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetQueryResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type StreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetQueryError = - HTTPValidationError; - -export function useStreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params: undefined | StreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet - > - >, - TError, - Awaited< - ReturnType< - typeof streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useStreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet - > - >, - TError, - Awaited< - ReturnType< - typeof streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useStreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Stream Board Memory - */ - -export function useStreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getStreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} diff --git a/src/frontend/src/api/generated/board-onboarding/board-onboarding.ts b/src/frontend/src/api/generated/board-onboarding/board-onboarding.ts deleted file mode 100644 index 479bfd9..0000000 --- a/src/frontend/src/api/generated/board-onboarding/board-onboarding.ts +++ /dev/null @@ -1,897 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - BoardOnboardingAgentComplete, - BoardOnboardingAgentQuestion, - BoardOnboardingAnswer, - BoardOnboardingConfirm, - BoardOnboardingRead, - BoardOnboardingStart, - BoardRead, - HTTPValidationError, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * Get the latest onboarding session for a board. - * @summary Get Onboarding - */ -export type getOnboardingApiV1BoardsBoardIdOnboardingGetResponse200 = { - data: BoardOnboardingRead; - status: 200; -}; - -export type getOnboardingApiV1BoardsBoardIdOnboardingGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getOnboardingApiV1BoardsBoardIdOnboardingGetResponseSuccess = - getOnboardingApiV1BoardsBoardIdOnboardingGetResponse200 & { - headers: Headers; - }; -export type getOnboardingApiV1BoardsBoardIdOnboardingGetResponseError = - getOnboardingApiV1BoardsBoardIdOnboardingGetResponse422 & { - headers: Headers; - }; - -export type getOnboardingApiV1BoardsBoardIdOnboardingGetResponse = - | getOnboardingApiV1BoardsBoardIdOnboardingGetResponseSuccess - | getOnboardingApiV1BoardsBoardIdOnboardingGetResponseError; - -export const getGetOnboardingApiV1BoardsBoardIdOnboardingGetUrl = ( - boardId: string, -) => { - return `/api/v1/boards/${boardId}/onboarding`; -}; - -export const getOnboardingApiV1BoardsBoardIdOnboardingGet = async ( - boardId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetOnboardingApiV1BoardsBoardIdOnboardingGetUrl(boardId), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetOnboardingApiV1BoardsBoardIdOnboardingGetQueryKey = ( - boardId: string, -) => { - return [`/api/v1/boards/${boardId}/onboarding`] as const; -}; - -export const getGetOnboardingApiV1BoardsBoardIdOnboardingGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetOnboardingApiV1BoardsBoardIdOnboardingGetQueryKey(boardId); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getOnboardingApiV1BoardsBoardIdOnboardingGet(boardId, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetOnboardingApiV1BoardsBoardIdOnboardingGetQueryResult = - NonNullable< - Awaited> - >; -export type GetOnboardingApiV1BoardsBoardIdOnboardingGetQueryError = - HTTPValidationError; - -export function useGetOnboardingApiV1BoardsBoardIdOnboardingGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetOnboardingApiV1BoardsBoardIdOnboardingGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetOnboardingApiV1BoardsBoardIdOnboardingGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Onboarding - */ - -export function useGetOnboardingApiV1BoardsBoardIdOnboardingGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetOnboardingApiV1BoardsBoardIdOnboardingGetQueryOptions( - boardId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Store onboarding updates submitted by the gateway agent. - * @summary Agent Onboarding Update - */ -export type agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostResponse200 = - { - data: BoardOnboardingRead; - status: 200; - }; - -export type agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostResponseSuccess = - agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostResponse200 & { - headers: Headers; - }; -export type agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostResponseError = - agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostResponse422 & { - headers: Headers; - }; - -export type agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostResponse = - | agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostResponseSuccess - | agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostResponseError; - -export const getAgentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostUrl = - (boardId: string) => { - return `/api/v1/boards/${boardId}/onboarding/agent`; - }; - -export const agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPost = - async ( - boardId: string, - boardOnboardingAgentCompleteBoardOnboardingAgentQuestion: - | BoardOnboardingAgentComplete - | BoardOnboardingAgentQuestion, - options?: RequestInit, - ): Promise => { - return customFetch( - getAgentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify( - boardOnboardingAgentCompleteBoardOnboardingAgentQuestion, - ), - }, - ); - }; - -export const getAgentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPost - > - >, - TError, - { - boardId: string; - data: BoardOnboardingAgentComplete | BoardOnboardingAgentQuestion; - }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPost - > - >, - TError, - { - boardId: string; - data: BoardOnboardingAgentComplete | BoardOnboardingAgentQuestion; - }, - TContext - > => { - const mutationKey = [ - "agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPost - > - >, - { - boardId: string; - data: BoardOnboardingAgentComplete | BoardOnboardingAgentQuestion; - } - > = (props) => { - const { boardId, data } = props ?? {}; - - return agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPost( - boardId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type AgentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPost - > - > - >; -export type AgentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostMutationBody = - BoardOnboardingAgentComplete | BoardOnboardingAgentQuestion; -export type AgentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostMutationError = - HTTPValidationError; - -/** - * @summary Agent Onboarding Update - */ -export const useAgentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPost - > - >, - TError, - { - boardId: string; - data: BoardOnboardingAgentComplete | BoardOnboardingAgentQuestion; - }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType< - typeof agentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPost - > - >, - TError, - { - boardId: string; - data: BoardOnboardingAgentComplete | BoardOnboardingAgentQuestion; - }, - TContext -> => { - return useMutation( - getAgentOnboardingUpdateApiV1BoardsBoardIdOnboardingAgentPostMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Send a user onboarding answer to the gateway agent. - * @summary Answer Onboarding - */ -export type answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostResponse200 = - { - data: BoardOnboardingRead; - status: 200; - }; - -export type answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostResponseSuccess = - answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostResponse200 & { - headers: Headers; - }; -export type answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostResponseError = - answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostResponse422 & { - headers: Headers; - }; - -export type answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostResponse = - | answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostResponseSuccess - | answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostResponseError; - -export const getAnswerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostUrl = ( - boardId: string, -) => { - return `/api/v1/boards/${boardId}/onboarding/answer`; -}; - -export const answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPost = async ( - boardId: string, - boardOnboardingAnswer: BoardOnboardingAnswer, - options?: RequestInit, -): Promise => { - return customFetch( - getAnswerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardOnboardingAnswer), - }, - ); -}; - -export const getAnswerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPost - > - >, - TError, - { boardId: string; data: BoardOnboardingAnswer }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardOnboardingAnswer }, - TContext - > => { - const mutationKey = [ - "answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPost - > - >, - { boardId: string; data: BoardOnboardingAnswer } - > = (props) => { - const { boardId, data } = props ?? {}; - - return answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPost( - boardId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type AnswerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostMutationResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type AnswerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostMutationBody = - BoardOnboardingAnswer; -export type AnswerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostMutationError = - HTTPValidationError; - -/** - * @summary Answer Onboarding - */ -export const useAnswerOnboardingApiV1BoardsBoardIdOnboardingAnswerPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof answerOnboardingApiV1BoardsBoardIdOnboardingAnswerPost - > - >, - TError, - { boardId: string; data: BoardOnboardingAnswer }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardOnboardingAnswer }, - TContext -> => { - return useMutation( - getAnswerOnboardingApiV1BoardsBoardIdOnboardingAnswerPostMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Confirm onboarding results and provision the board lead agent. - * @summary Confirm Onboarding - */ -export type confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostResponse200 = - { - data: BoardRead; - status: 200; - }; - -export type confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostResponseSuccess = - confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostResponse200 & { - headers: Headers; - }; -export type confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostResponseError = - confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostResponse422 & { - headers: Headers; - }; - -export type confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostResponse = - | confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostResponseSuccess - | confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostResponseError; - -export const getConfirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostUrl = ( - boardId: string, -) => { - return `/api/v1/boards/${boardId}/onboarding/confirm`; -}; - -export const confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPost = async ( - boardId: string, - boardOnboardingConfirm: BoardOnboardingConfirm, - options?: RequestInit, -): Promise => { - return customFetch( - getConfirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardOnboardingConfirm), - }, - ); -}; - -export const getConfirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPost - > - >, - TError, - { boardId: string; data: BoardOnboardingConfirm }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPost - > - >, - TError, - { boardId: string; data: BoardOnboardingConfirm }, - TContext - > => { - const mutationKey = [ - "confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPost - > - >, - { boardId: string; data: BoardOnboardingConfirm } - > = (props) => { - const { boardId, data } = props ?? {}; - - return confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPost( - boardId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type ConfirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPost - > - > - >; -export type ConfirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostMutationBody = - BoardOnboardingConfirm; -export type ConfirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostMutationError = - HTTPValidationError; - -/** - * @summary Confirm Onboarding - */ -export const useConfirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof confirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPost - > - >, - TError, - { boardId: string; data: BoardOnboardingConfirm }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardOnboardingConfirm }, - TContext -> => { - return useMutation( - getConfirmOnboardingApiV1BoardsBoardIdOnboardingConfirmPostMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Start onboarding and send instructions to the gateway agent. - * @summary Start Onboarding - */ -export type startOnboardingApiV1BoardsBoardIdOnboardingStartPostResponse200 = { - data: BoardOnboardingRead; - status: 200; -}; - -export type startOnboardingApiV1BoardsBoardIdOnboardingStartPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type startOnboardingApiV1BoardsBoardIdOnboardingStartPostResponseSuccess = - startOnboardingApiV1BoardsBoardIdOnboardingStartPostResponse200 & { - headers: Headers; - }; -export type startOnboardingApiV1BoardsBoardIdOnboardingStartPostResponseError = - startOnboardingApiV1BoardsBoardIdOnboardingStartPostResponse422 & { - headers: Headers; - }; - -export type startOnboardingApiV1BoardsBoardIdOnboardingStartPostResponse = - | startOnboardingApiV1BoardsBoardIdOnboardingStartPostResponseSuccess - | startOnboardingApiV1BoardsBoardIdOnboardingStartPostResponseError; - -export const getStartOnboardingApiV1BoardsBoardIdOnboardingStartPostUrl = ( - boardId: string, -) => { - return `/api/v1/boards/${boardId}/onboarding/start`; -}; - -export const startOnboardingApiV1BoardsBoardIdOnboardingStartPost = async ( - boardId: string, - boardOnboardingStart: BoardOnboardingStart, - options?: RequestInit, -): Promise => { - return customFetch( - getStartOnboardingApiV1BoardsBoardIdOnboardingStartPostUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardOnboardingStart), - }, - ); -}; - -export const getStartOnboardingApiV1BoardsBoardIdOnboardingStartPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardOnboardingStart }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardOnboardingStart }, - TContext - > => { - const mutationKey = [ - "startOnboardingApiV1BoardsBoardIdOnboardingStartPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType - >, - { boardId: string; data: BoardOnboardingStart } - > = (props) => { - const { boardId, data } = props ?? {}; - - return startOnboardingApiV1BoardsBoardIdOnboardingStartPost( - boardId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type StartOnboardingApiV1BoardsBoardIdOnboardingStartPostMutationResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type StartOnboardingApiV1BoardsBoardIdOnboardingStartPostMutationBody = - BoardOnboardingStart; -export type StartOnboardingApiV1BoardsBoardIdOnboardingStartPostMutationError = - HTTPValidationError; - -/** - * @summary Start Onboarding - */ -export const useStartOnboardingApiV1BoardsBoardIdOnboardingStartPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardOnboardingStart }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardOnboardingStart }, - TContext -> => { - return useMutation( - getStartOnboardingApiV1BoardsBoardIdOnboardingStartPostMutationOptions( - options, - ), - queryClient, - ); -}; diff --git a/src/frontend/src/api/generated/board-webhooks/board-webhooks.ts b/src/frontend/src/api/generated/board-webhooks/board-webhooks.ts deleted file mode 100644 index 3170f95..0000000 --- a/src/frontend/src/api/generated/board-webhooks/board-webhooks.ts +++ /dev/null @@ -1,1829 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - BoardWebhookCreate, - BoardWebhookIngestResponse, - BoardWebhookPayloadRead, - BoardWebhookRead, - BoardWebhookUpdate, - HTTPValidationError, - LimitOffsetPageTypeVarCustomizedBoardWebhookPayloadRead, - LimitOffsetPageTypeVarCustomizedBoardWebhookRead, - ListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams, - ListBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams, - OkResponse, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List configured webhooks for a board. - * @summary List Board Webhooks - */ -export type listBoardWebhooksApiV1BoardsBoardIdWebhooksGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedBoardWebhookRead; - status: 200; -}; - -export type listBoardWebhooksApiV1BoardsBoardIdWebhooksGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listBoardWebhooksApiV1BoardsBoardIdWebhooksGetResponseSuccess = - listBoardWebhooksApiV1BoardsBoardIdWebhooksGetResponse200 & { - headers: Headers; - }; -export type listBoardWebhooksApiV1BoardsBoardIdWebhooksGetResponseError = - listBoardWebhooksApiV1BoardsBoardIdWebhooksGetResponse422 & { - headers: Headers; - }; - -export type listBoardWebhooksApiV1BoardsBoardIdWebhooksGetResponse = - | listBoardWebhooksApiV1BoardsBoardIdWebhooksGetResponseSuccess - | listBoardWebhooksApiV1BoardsBoardIdWebhooksGetResponseError; - -export const getListBoardWebhooksApiV1BoardsBoardIdWebhooksGetUrl = ( - boardId: string, - params?: ListBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards/${boardId}/webhooks?${stringifiedParams}` - : `/api/v1/boards/${boardId}/webhooks`; -}; - -export const listBoardWebhooksApiV1BoardsBoardIdWebhooksGet = async ( - boardId: string, - params?: ListBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListBoardWebhooksApiV1BoardsBoardIdWebhooksGetUrl(boardId, params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListBoardWebhooksApiV1BoardsBoardIdWebhooksGetQueryKey = ( - boardId: string, - params?: ListBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams, -) => { - return [ - `/api/v1/boards/${boardId}/webhooks`, - ...(params ? [params] : []), - ] as const; -}; - -export const getListBoardWebhooksApiV1BoardsBoardIdWebhooksGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListBoardWebhooksApiV1BoardsBoardIdWebhooksGetQueryKey(boardId, params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listBoardWebhooksApiV1BoardsBoardIdWebhooksGet(boardId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListBoardWebhooksApiV1BoardsBoardIdWebhooksGetQueryResult = - NonNullable< - Awaited> - >; -export type ListBoardWebhooksApiV1BoardsBoardIdWebhooksGetQueryError = - HTTPValidationError; - -export function useListBoardWebhooksApiV1BoardsBoardIdWebhooksGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params: undefined | ListBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardWebhooksApiV1BoardsBoardIdWebhooksGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardWebhooksApiV1BoardsBoardIdWebhooksGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Board Webhooks - */ - -export function useListBoardWebhooksApiV1BoardsBoardIdWebhooksGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListBoardWebhooksApiV1BoardsBoardIdWebhooksGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create a new board webhook with a generated UUID endpoint. - * @summary Create Board Webhook - */ -export type createBoardWebhookApiV1BoardsBoardIdWebhooksPostResponse200 = { - data: BoardWebhookRead; - status: 200; -}; - -export type createBoardWebhookApiV1BoardsBoardIdWebhooksPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createBoardWebhookApiV1BoardsBoardIdWebhooksPostResponseSuccess = - createBoardWebhookApiV1BoardsBoardIdWebhooksPostResponse200 & { - headers: Headers; - }; -export type createBoardWebhookApiV1BoardsBoardIdWebhooksPostResponseError = - createBoardWebhookApiV1BoardsBoardIdWebhooksPostResponse422 & { - headers: Headers; - }; - -export type createBoardWebhookApiV1BoardsBoardIdWebhooksPostResponse = - | createBoardWebhookApiV1BoardsBoardIdWebhooksPostResponseSuccess - | createBoardWebhookApiV1BoardsBoardIdWebhooksPostResponseError; - -export const getCreateBoardWebhookApiV1BoardsBoardIdWebhooksPostUrl = ( - boardId: string, -) => { - return `/api/v1/boards/${boardId}/webhooks`; -}; - -export const createBoardWebhookApiV1BoardsBoardIdWebhooksPost = async ( - boardId: string, - boardWebhookCreate: BoardWebhookCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateBoardWebhookApiV1BoardsBoardIdWebhooksPostUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardWebhookCreate), - }, - ); -}; - -export const getCreateBoardWebhookApiV1BoardsBoardIdWebhooksPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardWebhookCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardWebhookCreate }, - TContext - > => { - const mutationKey = ["createBoardWebhookApiV1BoardsBoardIdWebhooksPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType - >, - { boardId: string; data: BoardWebhookCreate } - > = (props) => { - const { boardId, data } = props ?? {}; - - return createBoardWebhookApiV1BoardsBoardIdWebhooksPost( - boardId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type CreateBoardWebhookApiV1BoardsBoardIdWebhooksPostMutationResult = - NonNullable< - Awaited> - >; -export type CreateBoardWebhookApiV1BoardsBoardIdWebhooksPostMutationBody = - BoardWebhookCreate; -export type CreateBoardWebhookApiV1BoardsBoardIdWebhooksPostMutationError = - HTTPValidationError; - -/** - * @summary Create Board Webhook - */ -export const useCreateBoardWebhookApiV1BoardsBoardIdWebhooksPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { boardId: string; data: BoardWebhookCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; data: BoardWebhookCreate }, - TContext -> => { - return useMutation( - getCreateBoardWebhookApiV1BoardsBoardIdWebhooksPostMutationOptions(options), - queryClient, - ); -}; -/** - * Delete a webhook and its stored payload rows. - * @summary Delete Board Webhook - */ -export type deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteResponse200 = - { - data: OkResponse; - status: 200; - }; - -export type deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteResponseSuccess = - deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteResponseError = - deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteResponse = - - | deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteResponseSuccess - | deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteResponseError; - -export const getDeleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteUrl = - (boardId: string, webhookId: string) => { - return `/api/v1/boards/${boardId}/webhooks/${webhookId}`; - }; - -export const deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDelete = - async ( - boardId: string, - webhookId: string, - options?: RequestInit, - ): Promise => { - return customFetch( - getDeleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteUrl( - boardId, - webhookId, - ), - { - ...options, - method: "DELETE", - }, - ); - }; - -export const getDeleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDelete - > - >, - TError, - { boardId: string; webhookId: string }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDelete - > - >, - TError, - { boardId: string; webhookId: string }, - TContext - > => { - const mutationKey = [ - "deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDelete", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDelete - > - >, - { boardId: string; webhookId: string } - > = (props) => { - const { boardId, webhookId } = props ?? {}; - - return deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDelete( - boardId, - webhookId, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type DeleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDelete - > - > - >; - -export type DeleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Delete Board Webhook - */ -export const useDeleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDelete - > - >, - TError, - { boardId: string; webhookId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType< - typeof deleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDelete - > - >, - TError, - { boardId: string; webhookId: string }, - TContext -> => { - return useMutation( - getDeleteBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdDeleteMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Get one board webhook configuration. - * @summary Get Board Webhook - */ -export type getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetResponse200 = { - data: BoardWebhookRead; - status: 200; -}; - -export type getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetResponseSuccess = - getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetResponse200 & { - headers: Headers; - }; -export type getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetResponseError = - getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetResponse422 & { - headers: Headers; - }; - -export type getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetResponse = - | getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetResponseSuccess - | getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetResponseError; - -export const getGetBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetUrl = ( - boardId: string, - webhookId: string, -) => { - return `/api/v1/boards/${boardId}/webhooks/${webhookId}`; -}; - -export const getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet = async ( - boardId: string, - webhookId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetUrl( - boardId, - webhookId, - ), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetQueryKey = - (boardId: string, webhookId: string) => { - return [`/api/v1/boards/${boardId}/webhooks/${webhookId}`] as const; - }; - -export const getGetBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetQueryOptions = - < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, - >( - boardId: string, - webhookId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetQueryKey( - boardId, - webhookId, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType - > - > = ({ signal }) => - getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet( - boardId, - webhookId, - { signal, ...requestOptions }, - ); - - return { - queryKey, - queryFn, - enabled: !!(boardId && webhookId), - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type GetBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetQueryResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type GetBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetQueryError = - HTTPValidationError; - -export function useGetBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - webhookId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet - > - >, - TError, - Awaited< - ReturnType< - typeof getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - webhookId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet - > - >, - TError, - Awaited< - ReturnType< - typeof getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - webhookId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Board Webhook - */ - -export function useGetBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - webhookId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdGetQueryOptions( - boardId, - webhookId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Update board webhook description or enabled state. - * @summary Update Board Webhook - */ -export type updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchResponse200 = - { - data: BoardWebhookRead; - status: 200; - }; - -export type updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchResponseSuccess = - updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchResponse200 & { - headers: Headers; - }; -export type updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchResponseError = - updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchResponse422 & { - headers: Headers; - }; - -export type updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchResponse = - | updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchResponseSuccess - | updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchResponseError; - -export const getUpdateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchUrl = - (boardId: string, webhookId: string) => { - return `/api/v1/boards/${boardId}/webhooks/${webhookId}`; - }; - -export const updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatch = - async ( - boardId: string, - webhookId: string, - boardWebhookUpdate: BoardWebhookUpdate, - options?: RequestInit, - ): Promise => { - return customFetch( - getUpdateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchUrl( - boardId, - webhookId, - ), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardWebhookUpdate), - }, - ); - }; - -export const getUpdateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatch - > - >, - TError, - { boardId: string; webhookId: string; data: BoardWebhookUpdate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatch - > - >, - TError, - { boardId: string; webhookId: string; data: BoardWebhookUpdate }, - TContext - > => { - const mutationKey = [ - "updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatch", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatch - > - >, - { boardId: string; webhookId: string; data: BoardWebhookUpdate } - > = (props) => { - const { boardId, webhookId, data } = props ?? {}; - - return updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatch( - boardId, - webhookId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type UpdateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatch - > - > - >; -export type UpdateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchMutationBody = - BoardWebhookUpdate; -export type UpdateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchMutationError = - HTTPValidationError; - -/** - * @summary Update Board Webhook - */ -export const useUpdateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatch = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatch - > - >, - TError, - { boardId: string; webhookId: string; data: BoardWebhookUpdate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType< - typeof updateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatch - > - >, - TError, - { boardId: string; webhookId: string; data: BoardWebhookUpdate }, - TContext -> => { - return useMutation( - getUpdateBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPatchMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Open inbound webhook endpoint that stores payloads and nudges the board lead. - * @summary Ingest Board Webhook - */ -export type ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostResponse202 = - { - data: BoardWebhookIngestResponse; - status: 202; - }; - -export type ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostResponseSuccess = - ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostResponse202 & { - headers: Headers; - }; -export type ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostResponseError = - ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostResponse422 & { - headers: Headers; - }; - -export type ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostResponse = - | ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostResponseSuccess - | ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostResponseError; - -export const getIngestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostUrl = ( - boardId: string, - webhookId: string, -) => { - return `/api/v1/boards/${boardId}/webhooks/${webhookId}`; -}; - -export const ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPost = async ( - boardId: string, - webhookId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getIngestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostUrl( - boardId, - webhookId, - ), - { - ...options, - method: "POST", - }, - ); -}; - -export const getIngestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPost - > - >, - TError, - { boardId: string; webhookId: string }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPost - > - >, - TError, - { boardId: string; webhookId: string }, - TContext - > => { - const mutationKey = [ - "ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPost - > - >, - { boardId: string; webhookId: string } - > = (props) => { - const { boardId, webhookId } = props ?? {}; - - return ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPost( - boardId, - webhookId, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type IngestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPost - > - > - >; - -export type IngestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostMutationError = - HTTPValidationError; - -/** - * @summary Ingest Board Webhook - */ -export const useIngestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof ingestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPost - > - >, - TError, - { boardId: string; webhookId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { boardId: string; webhookId: string }, - TContext -> => { - return useMutation( - getIngestBoardWebhookApiV1BoardsBoardIdWebhooksWebhookIdPostMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * List stored payloads for one board webhook. - * @summary List Board Webhook Payloads - */ -export type listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetResponse200 = - { - data: LimitOffsetPageTypeVarCustomizedBoardWebhookPayloadRead; - status: 200; - }; - -export type listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetResponseSuccess = - listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetResponse200 & { - headers: Headers; - }; -export type listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetResponseError = - listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetResponse422 & { - headers: Headers; - }; - -export type listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetResponse = - - | listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetResponseSuccess - | listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetResponseError; - -export const getListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetUrl = - ( - boardId: string, - webhookId: string, - params?: ListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams, - ) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append( - key, - value === null ? "null" : value.toString(), - ); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards/${boardId}/webhooks/${webhookId}/payloads?${stringifiedParams}` - : `/api/v1/boards/${boardId}/webhooks/${webhookId}/payloads`; - }; - -export const listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet = - async ( - boardId: string, - webhookId: string, - params?: ListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams, - options?: RequestInit, - ): Promise => { - return customFetch( - getListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetUrl( - boardId, - webhookId, - params, - ), - { - ...options, - method: "GET", - }, - ); - }; - -export const getListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetQueryKey = - ( - boardId: string, - webhookId: string, - params?: ListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams, - ) => { - return [ - `/api/v1/boards/${boardId}/webhooks/${webhookId}/payloads`, - ...(params ? [params] : []), - ] as const; - }; - -export const getListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetQueryOptions = - < - TData = Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError = HTTPValidationError, - >( - boardId: string, - webhookId: string, - params?: ListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetQueryKey( - boardId, - webhookId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - > - > = ({ signal }) => - listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet( - boardId, - webhookId, - params, - { signal, ...requestOptions }, - ); - - return { - queryKey, - queryFn, - enabled: !!(boardId && webhookId), - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type ListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetQueryResult = - NonNullable< - Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - > - >; -export type ListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetQueryError = - HTTPValidationError; - -export function useListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet< - TData = Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - webhookId: string, - params: - | undefined - | ListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError, - Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet< - TData = Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - webhookId: string, - params?: ListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError, - Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet< - TData = Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - webhookId: string, - params?: ListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Board Webhook Payloads - */ - -export function useListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet< - TData = Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - webhookId: string, - params?: ListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetQueryOptions( - boardId, - webhookId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Get a single stored payload for one board webhook. - * @summary Get Board Webhook Payload - */ -export type getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetResponse200 = - { - data: BoardWebhookPayloadRead; - status: 200; - }; - -export type getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetResponseSuccess = - getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetResponse200 & { - headers: Headers; - }; -export type getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetResponseError = - getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetResponse422 & { - headers: Headers; - }; - -export type getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetResponse = - - | getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetResponseSuccess - | getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetResponseError; - -export const getGetBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetUrl = - (boardId: string, webhookId: string, payloadId: string) => { - return `/api/v1/boards/${boardId}/webhooks/${webhookId}/payloads/${payloadId}`; - }; - -export const getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet = - async ( - boardId: string, - webhookId: string, - payloadId: string, - options?: RequestInit, - ): Promise => { - return customFetch( - getGetBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetUrl( - boardId, - webhookId, - payloadId, - ), - { - ...options, - method: "GET", - }, - ); - }; - -export const getGetBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetQueryKey = - (boardId: string, webhookId: string, payloadId: string) => { - return [ - `/api/v1/boards/${boardId}/webhooks/${webhookId}/payloads/${payloadId}`, - ] as const; - }; - -export const getGetBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetQueryOptions = - < - TData = Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError = HTTPValidationError, - >( - boardId: string, - webhookId: string, - payloadId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetQueryKey( - boardId, - webhookId, - payloadId, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - > - > = ({ signal }) => - getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet( - boardId, - webhookId, - payloadId, - { signal, ...requestOptions }, - ); - - return { - queryKey, - queryFn, - enabled: !!(boardId && webhookId && payloadId), - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type GetBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetQueryResult = - NonNullable< - Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - > - >; -export type GetBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetQueryError = - HTTPValidationError; - -export function useGetBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet< - TData = Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - webhookId: string, - payloadId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError, - Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet< - TData = Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - webhookId: string, - payloadId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError, - Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet< - TData = Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - webhookId: string, - payloadId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Board Webhook Payload - */ - -export function useGetBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet< - TData = Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError = HTTPValidationError, ->( - boardId: string, - webhookId: string, - payloadId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetBoardWebhookPayloadApiV1BoardsBoardIdWebhooksWebhookIdPayloadsPayloadIdGetQueryOptions( - boardId, - webhookId, - payloadId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} diff --git a/src/frontend/src/api/generated/boards/boards.ts b/src/frontend/src/api/generated/boards/boards.ts deleted file mode 100644 index 920d51d..0000000 --- a/src/frontend/src/api/generated/boards/boards.ts +++ /dev/null @@ -1,1345 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - BoardCreate, - BoardGroupSnapshot, - BoardRead, - BoardSnapshot, - BoardUpdate, - GetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams, - HTTPValidationError, - LimitOffsetPageTypeVarCustomizedBoardRead, - ListBoardsApiV1BoardsGetParams, - OkResponse, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List boards visible to the current organization member. - * @summary List Boards - */ -export type listBoardsApiV1BoardsGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedBoardRead; - status: 200; -}; - -export type listBoardsApiV1BoardsGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listBoardsApiV1BoardsGetResponseSuccess = - listBoardsApiV1BoardsGetResponse200 & { - headers: Headers; - }; -export type listBoardsApiV1BoardsGetResponseError = - listBoardsApiV1BoardsGetResponse422 & { - headers: Headers; - }; - -export type listBoardsApiV1BoardsGetResponse = - | listBoardsApiV1BoardsGetResponseSuccess - | listBoardsApiV1BoardsGetResponseError; - -export const getListBoardsApiV1BoardsGetUrl = ( - params?: ListBoardsApiV1BoardsGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards?${stringifiedParams}` - : `/api/v1/boards`; -}; - -export const listBoardsApiV1BoardsGet = async ( - params?: ListBoardsApiV1BoardsGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListBoardsApiV1BoardsGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListBoardsApiV1BoardsGetQueryKey = ( - params?: ListBoardsApiV1BoardsGetParams, -) => { - return [`/api/v1/boards`, ...(params ? [params] : [])] as const; -}; - -export const getListBoardsApiV1BoardsGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListBoardsApiV1BoardsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getListBoardsApiV1BoardsGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listBoardsApiV1BoardsGet(params, { signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListBoardsApiV1BoardsGetQueryResult = NonNullable< - Awaited> ->; -export type ListBoardsApiV1BoardsGetQueryError = HTTPValidationError; - -export function useListBoardsApiV1BoardsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params: undefined | ListBoardsApiV1BoardsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardsApiV1BoardsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListBoardsApiV1BoardsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListBoardsApiV1BoardsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListBoardsApiV1BoardsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Boards - */ - -export function useListBoardsApiV1BoardsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListBoardsApiV1BoardsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getListBoardsApiV1BoardsGetQueryOptions(params, options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create a board in the active organization. - * @summary Create Board - */ -export type createBoardApiV1BoardsPostResponse200 = { - data: BoardRead; - status: 200; -}; - -export type createBoardApiV1BoardsPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createBoardApiV1BoardsPostResponseSuccess = - createBoardApiV1BoardsPostResponse200 & { - headers: Headers; - }; -export type createBoardApiV1BoardsPostResponseError = - createBoardApiV1BoardsPostResponse422 & { - headers: Headers; - }; - -export type createBoardApiV1BoardsPostResponse = - | createBoardApiV1BoardsPostResponseSuccess - | createBoardApiV1BoardsPostResponseError; - -export const getCreateBoardApiV1BoardsPostUrl = () => { - return `/api/v1/boards`; -}; - -export const createBoardApiV1BoardsPost = async ( - boardCreate: BoardCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateBoardApiV1BoardsPostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardCreate), - }, - ); -}; - -export const getCreateBoardApiV1BoardsPostMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: BoardCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { data: BoardCreate }, - TContext -> => { - const mutationKey = ["createBoardApiV1BoardsPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { data: BoardCreate } - > = (props) => { - const { data } = props ?? {}; - - return createBoardApiV1BoardsPost(data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type CreateBoardApiV1BoardsPostMutationResult = NonNullable< - Awaited> ->; -export type CreateBoardApiV1BoardsPostMutationBody = BoardCreate; -export type CreateBoardApiV1BoardsPostMutationError = HTTPValidationError; - -/** - * @summary Create Board - */ -export const useCreateBoardApiV1BoardsPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: BoardCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: BoardCreate }, - TContext -> => { - return useMutation( - getCreateBoardApiV1BoardsPostMutationOptions(options), - queryClient, - ); -}; -/** - * Delete a board and all dependent records. - * @summary Delete Board - */ -export type deleteBoardApiV1BoardsBoardIdDeleteResponse200 = { - data: OkResponse; - status: 200; -}; - -export type deleteBoardApiV1BoardsBoardIdDeleteResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type deleteBoardApiV1BoardsBoardIdDeleteResponseSuccess = - deleteBoardApiV1BoardsBoardIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteBoardApiV1BoardsBoardIdDeleteResponseError = - deleteBoardApiV1BoardsBoardIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteBoardApiV1BoardsBoardIdDeleteResponse = - | deleteBoardApiV1BoardsBoardIdDeleteResponseSuccess - | deleteBoardApiV1BoardsBoardIdDeleteResponseError; - -export const getDeleteBoardApiV1BoardsBoardIdDeleteUrl = (boardId: string) => { - return `/api/v1/boards/${boardId}`; -}; - -export const deleteBoardApiV1BoardsBoardIdDelete = async ( - boardId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getDeleteBoardApiV1BoardsBoardIdDeleteUrl(boardId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getDeleteBoardApiV1BoardsBoardIdDeleteMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string }, - TContext -> => { - const mutationKey = ["deleteBoardApiV1BoardsBoardIdDelete"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string } - > = (props) => { - const { boardId } = props ?? {}; - - return deleteBoardApiV1BoardsBoardIdDelete(boardId, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type DeleteBoardApiV1BoardsBoardIdDeleteMutationResult = NonNullable< - Awaited> ->; - -export type DeleteBoardApiV1BoardsBoardIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Delete Board - */ -export const useDeleteBoardApiV1BoardsBoardIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string }, - TContext -> => { - return useMutation( - getDeleteBoardApiV1BoardsBoardIdDeleteMutationOptions(options), - queryClient, - ); -}; -/** - * Get a board by id. - * @summary Get Board - */ -export type getBoardApiV1BoardsBoardIdGetResponse200 = { - data: BoardRead; - status: 200; -}; - -export type getBoardApiV1BoardsBoardIdGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getBoardApiV1BoardsBoardIdGetResponseSuccess = - getBoardApiV1BoardsBoardIdGetResponse200 & { - headers: Headers; - }; -export type getBoardApiV1BoardsBoardIdGetResponseError = - getBoardApiV1BoardsBoardIdGetResponse422 & { - headers: Headers; - }; - -export type getBoardApiV1BoardsBoardIdGetResponse = - | getBoardApiV1BoardsBoardIdGetResponseSuccess - | getBoardApiV1BoardsBoardIdGetResponseError; - -export const getGetBoardApiV1BoardsBoardIdGetUrl = (boardId: string) => { - return `/api/v1/boards/${boardId}`; -}; - -export const getBoardApiV1BoardsBoardIdGet = async ( - boardId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetBoardApiV1BoardsBoardIdGetUrl(boardId), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetBoardApiV1BoardsBoardIdGetQueryKey = (boardId: string) => { - return [`/api/v1/boards/${boardId}`] as const; -}; - -export const getGetBoardApiV1BoardsBoardIdGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getGetBoardApiV1BoardsBoardIdGetQueryKey(boardId); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getBoardApiV1BoardsBoardIdGet(boardId, { signal, ...requestOptions }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetBoardApiV1BoardsBoardIdGetQueryResult = NonNullable< - Awaited> ->; -export type GetBoardApiV1BoardsBoardIdGetQueryError = HTTPValidationError; - -export function useGetBoardApiV1BoardsBoardIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardApiV1BoardsBoardIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardApiV1BoardsBoardIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Board - */ - -export function useGetBoardApiV1BoardsBoardIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getGetBoardApiV1BoardsBoardIdGetQueryOptions( - boardId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Update mutable board properties. - * @summary Update Board - */ -export type updateBoardApiV1BoardsBoardIdPatchResponse200 = { - data: BoardRead; - status: 200; -}; - -export type updateBoardApiV1BoardsBoardIdPatchResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type updateBoardApiV1BoardsBoardIdPatchResponseSuccess = - updateBoardApiV1BoardsBoardIdPatchResponse200 & { - headers: Headers; - }; -export type updateBoardApiV1BoardsBoardIdPatchResponseError = - updateBoardApiV1BoardsBoardIdPatchResponse422 & { - headers: Headers; - }; - -export type updateBoardApiV1BoardsBoardIdPatchResponse = - | updateBoardApiV1BoardsBoardIdPatchResponseSuccess - | updateBoardApiV1BoardsBoardIdPatchResponseError; - -export const getUpdateBoardApiV1BoardsBoardIdPatchUrl = (boardId: string) => { - return `/api/v1/boards/${boardId}`; -}; - -export const updateBoardApiV1BoardsBoardIdPatch = async ( - boardId: string, - boardUpdate: BoardUpdate, - options?: RequestInit, -): Promise => { - return customFetch( - getUpdateBoardApiV1BoardsBoardIdPatchUrl(boardId), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(boardUpdate), - }, - ); -}; - -export const getUpdateBoardApiV1BoardsBoardIdPatchMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: BoardUpdate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: BoardUpdate }, - TContext -> => { - const mutationKey = ["updateBoardApiV1BoardsBoardIdPatch"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string; data: BoardUpdate } - > = (props) => { - const { boardId, data } = props ?? {}; - - return updateBoardApiV1BoardsBoardIdPatch(boardId, data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type UpdateBoardApiV1BoardsBoardIdPatchMutationResult = NonNullable< - Awaited> ->; -export type UpdateBoardApiV1BoardsBoardIdPatchMutationBody = BoardUpdate; -export type UpdateBoardApiV1BoardsBoardIdPatchMutationError = - HTTPValidationError; - -/** - * @summary Update Board - */ -export const useUpdateBoardApiV1BoardsBoardIdPatch = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: BoardUpdate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; data: BoardUpdate }, - TContext -> => { - return useMutation( - getUpdateBoardApiV1BoardsBoardIdPatchMutationOptions(options), - queryClient, - ); -}; -/** - * Get a grouped snapshot across related boards. - -Returns high-signal cross-board status for dependency and overlap checks. - * @summary Get Board Group Snapshot - */ -export type getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetResponse200 = - { - data: BoardGroupSnapshot; - status: 200; - }; - -export type getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetResponseSuccess = - getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetResponse200 & { - headers: Headers; - }; -export type getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetResponseError = - getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetResponse422 & { - headers: Headers; - }; - -export type getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetResponse = - | getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetResponseSuccess - | getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetResponseError; - -export const getGetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetUrl = ( - boardId: string, - params?: GetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards/${boardId}/group-snapshot?${stringifiedParams}` - : `/api/v1/boards/${boardId}/group-snapshot`; -}; - -export const getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet = async ( - boardId: string, - params?: GetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getGetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetUrl( - boardId, - params, - ), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetQueryKey = - ( - boardId: string, - params?: GetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams, - ) => { - return [ - `/api/v1/boards/${boardId}/group-snapshot`, - ...(params ? [params] : []), - ] as const; - }; - -export const getGetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetQueryOptions = - < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, - >( - boardId: string, - params?: GetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetQueryKey( - boardId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet - > - > - > = ({ signal }) => - getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet(boardId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type GetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetQueryResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type GetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetQueryError = - HTTPValidationError; - -export function useGetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params: - | undefined - | GetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet - > - >, - TError, - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: GetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet - > - >, - TError, - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: GetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Board Group Snapshot - */ - -export function useGetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: GetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Get a board snapshot view model. - * @summary Get Board Snapshot - */ -export type getBoardSnapshotApiV1BoardsBoardIdSnapshotGetResponse200 = { - data: BoardSnapshot; - status: 200; -}; - -export type getBoardSnapshotApiV1BoardsBoardIdSnapshotGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getBoardSnapshotApiV1BoardsBoardIdSnapshotGetResponseSuccess = - getBoardSnapshotApiV1BoardsBoardIdSnapshotGetResponse200 & { - headers: Headers; - }; -export type getBoardSnapshotApiV1BoardsBoardIdSnapshotGetResponseError = - getBoardSnapshotApiV1BoardsBoardIdSnapshotGetResponse422 & { - headers: Headers; - }; - -export type getBoardSnapshotApiV1BoardsBoardIdSnapshotGetResponse = - | getBoardSnapshotApiV1BoardsBoardIdSnapshotGetResponseSuccess - | getBoardSnapshotApiV1BoardsBoardIdSnapshotGetResponseError; - -export const getGetBoardSnapshotApiV1BoardsBoardIdSnapshotGetUrl = ( - boardId: string, -) => { - return `/api/v1/boards/${boardId}/snapshot`; -}; - -export const getBoardSnapshotApiV1BoardsBoardIdSnapshotGet = async ( - boardId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetBoardSnapshotApiV1BoardsBoardIdSnapshotGetUrl(boardId), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetBoardSnapshotApiV1BoardsBoardIdSnapshotGetQueryKey = ( - boardId: string, -) => { - return [`/api/v1/boards/${boardId}/snapshot`] as const; -}; - -export const getGetBoardSnapshotApiV1BoardsBoardIdSnapshotGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetBoardSnapshotApiV1BoardsBoardIdSnapshotGetQueryKey(boardId); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getBoardSnapshotApiV1BoardsBoardIdSnapshotGet(boardId, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetBoardSnapshotApiV1BoardsBoardIdSnapshotGetQueryResult = - NonNullable< - Awaited> - >; -export type GetBoardSnapshotApiV1BoardsBoardIdSnapshotGetQueryError = - HTTPValidationError; - -export function useGetBoardSnapshotApiV1BoardsBoardIdSnapshotGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardSnapshotApiV1BoardsBoardIdSnapshotGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetBoardSnapshotApiV1BoardsBoardIdSnapshotGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Board Snapshot - */ - -export function useGetBoardSnapshotApiV1BoardsBoardIdSnapshotGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetBoardSnapshotApiV1BoardsBoardIdSnapshotGetQueryOptions( - boardId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} diff --git a/src/frontend/src/api/generated/custom-fields/custom-fields.ts b/src/frontend/src/api/generated/custom-fields/custom-fields.ts deleted file mode 100644 index 2f5e1c9..0000000 --- a/src/frontend/src/api/generated/custom-fields/custom-fields.ts +++ /dev/null @@ -1,751 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - HTTPValidationError, - OkResponse, - TaskCustomFieldDefinitionCreate, - TaskCustomFieldDefinitionRead, - TaskCustomFieldDefinitionUpdate, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List task custom field definitions for the authenticated organization. - * @summary List Org Custom Fields - */ -export type listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetResponse200 = - { - data: TaskCustomFieldDefinitionRead[]; - status: 200; - }; - -export type listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetResponseSuccess = - listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetResponse200 & { - headers: Headers; - }; -export type listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetResponse = - listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetResponseSuccess; - -export const getListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetUrl = - () => { - return `/api/v1/organizations/me/custom-fields`; - }; - -export const listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetUrl(), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetQueryKey = - () => { - return [`/api/v1/organizations/me/custom-fields`] as const; - }; - -export const getListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetQueryOptions = - < - TData = Awaited< - ReturnType - >, - TError = unknown, - >(options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetQueryKey(); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - > - > = ({ signal }) => - listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet({ - signal, - ...requestOptions, - }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type ListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetQueryResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type ListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetQueryError = - unknown; - -export function useListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Org Custom Fields - */ - -export function useListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetQueryOptions( - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create an organization-level task custom field definition. - * @summary Create Org Custom Field - */ -export type createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponse200 = - { - data: TaskCustomFieldDefinitionRead; - status: 200; - }; - -export type createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponseSuccess = - createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponse200 & { - headers: Headers; - }; -export type createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponseError = - createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponse422 & { - headers: Headers; - }; - -export type createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponse = - | createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponseSuccess - | createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponseError; - -export const getCreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostUrl = - () => { - return `/api/v1/organizations/me/custom-fields`; - }; - -export const createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost = async ( - taskCustomFieldDefinitionCreate: TaskCustomFieldDefinitionCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(taskCustomFieldDefinitionCreate), - }, - ); -}; - -export const getCreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost - > - >, - TError, - { data: TaskCustomFieldDefinitionCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost - > - >, - TError, - { data: TaskCustomFieldDefinitionCreate }, - TContext - > => { - const mutationKey = [ - "createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost - > - >, - { data: TaskCustomFieldDefinitionCreate } - > = (props) => { - const { data } = props ?? {}; - - return createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost( - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type CreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost - > - > - >; -export type CreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostMutationBody = - TaskCustomFieldDefinitionCreate; -export type CreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostMutationError = - HTTPValidationError; - -/** - * @summary Create Org Custom Field - */ -export const useCreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost - > - >, - TError, - { data: TaskCustomFieldDefinitionCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { data: TaskCustomFieldDefinitionCreate }, - TContext -> => { - return useMutation( - getCreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Delete an org-level definition when it has no persisted task values. - * @summary Delete Org Custom Field - */ -export type deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponse200 = - { - data: OkResponse; - status: 200; - }; - -export type deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponseSuccess = - deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponseError = - deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponse = - - | deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponseSuccess - | deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponseError; - -export const getDeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteUrl = - (taskCustomFieldDefinitionId: string) => { - return `/api/v1/organizations/me/custom-fields/${taskCustomFieldDefinitionId}`; - }; - -export const deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete = - async ( - taskCustomFieldDefinitionId: string, - options?: RequestInit, - ): Promise => { - return customFetch( - getDeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteUrl( - taskCustomFieldDefinitionId, - ), - { - ...options, - method: "DELETE", - }, - ); - }; - -export const getDeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete - > - >, - TError, - { taskCustomFieldDefinitionId: string }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete - > - >, - TError, - { taskCustomFieldDefinitionId: string }, - TContext - > => { - const mutationKey = [ - "deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete - > - >, - { taskCustomFieldDefinitionId: string } - > = (props) => { - const { taskCustomFieldDefinitionId } = props ?? {}; - - return deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete( - taskCustomFieldDefinitionId, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type DeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete - > - > - >; - -export type DeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Delete Org Custom Field - */ -export const useDeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete = - ( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete - > - >, - TError, - { taskCustomFieldDefinitionId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, - ): UseMutationResult< - Awaited< - ReturnType< - typeof deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete - > - >, - TError, - { taskCustomFieldDefinitionId: string }, - TContext - > => { - return useMutation( - getDeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteMutationOptions( - options, - ), - queryClient, - ); - }; -/** - * Update an organization-level task custom field definition. - * @summary Update Org Custom Field - */ -export type updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponse200 = - { - data: TaskCustomFieldDefinitionRead; - status: 200; - }; - -export type updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponseSuccess = - updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponse200 & { - headers: Headers; - }; -export type updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponseError = - updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponse422 & { - headers: Headers; - }; - -export type updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponse = - - | updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponseSuccess - | updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponseError; - -export const getUpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchUrl = - (taskCustomFieldDefinitionId: string) => { - return `/api/v1/organizations/me/custom-fields/${taskCustomFieldDefinitionId}`; - }; - -export const updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch = - async ( - taskCustomFieldDefinitionId: string, - taskCustomFieldDefinitionUpdate: TaskCustomFieldDefinitionUpdate, - options?: RequestInit, - ): Promise => { - return customFetch( - getUpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchUrl( - taskCustomFieldDefinitionId, - ), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(taskCustomFieldDefinitionUpdate), - }, - ); - }; - -export const getUpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch - > - >, - TError, - { - taskCustomFieldDefinitionId: string; - data: TaskCustomFieldDefinitionUpdate; - }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch - > - >, - TError, - { - taskCustomFieldDefinitionId: string; - data: TaskCustomFieldDefinitionUpdate; - }, - TContext - > => { - const mutationKey = [ - "updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch - > - >, - { - taskCustomFieldDefinitionId: string; - data: TaskCustomFieldDefinitionUpdate; - } - > = (props) => { - const { taskCustomFieldDefinitionId, data } = props ?? {}; - - return updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch( - taskCustomFieldDefinitionId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type UpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch - > - > - >; -export type UpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchMutationBody = - TaskCustomFieldDefinitionUpdate; -export type UpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchMutationError = - HTTPValidationError; - -/** - * @summary Update Org Custom Field - */ -export const useUpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch = - ( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch - > - >, - TError, - { - taskCustomFieldDefinitionId: string; - data: TaskCustomFieldDefinitionUpdate; - }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, - ): UseMutationResult< - Awaited< - ReturnType< - typeof updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch - > - >, - TError, - { - taskCustomFieldDefinitionId: string; - data: TaskCustomFieldDefinitionUpdate; - }, - TContext - > => { - return useMutation( - getUpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchMutationOptions( - options, - ), - queryClient, - ); - }; diff --git a/src/frontend/src/api/generated/default/default.ts b/src/frontend/src/api/generated/default/default.ts deleted file mode 100644 index 0708898..0000000 --- a/src/frontend/src/api/generated/default/default.ts +++ /dev/null @@ -1,518 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - HealthHealthGet200, - HealthzHealthzGet200, - ReadyzReadyzGet200, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * Lightweight liveness probe endpoint. - * @summary Health - */ -export type healthHealthGetResponse200 = { - data: HealthHealthGet200; - status: 200; -}; - -export type healthHealthGetResponseSuccess = healthHealthGetResponse200 & { - headers: Headers; -}; -export type healthHealthGetResponse = healthHealthGetResponseSuccess; - -export const getHealthHealthGetUrl = () => { - return `/health`; -}; - -export const healthHealthGet = async ( - options?: RequestInit, -): Promise => { - return customFetch(getHealthHealthGetUrl(), { - ...options, - method: "GET", - }); -}; - -export const getHealthHealthGetQueryKey = () => { - return [`/health`] as const; -}; - -export const getHealthHealthGetQueryOptions = < - TData = Awaited>, - TError = unknown, ->(options?: { - query?: Partial< - UseQueryOptions>, TError, TData> - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = queryOptions?.queryKey ?? getHealthHealthGetQueryKey(); - - const queryFn: QueryFunction>> = ({ - signal, - }) => healthHealthGet({ signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type HealthHealthGetQueryResult = NonNullable< - Awaited> ->; -export type HealthHealthGetQueryError = unknown; - -export function useHealthHealthGet< - TData = Awaited>, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useHealthHealthGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useHealthHealthGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Health - */ - -export function useHealthHealthGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getHealthHealthGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Alias liveness probe endpoint for platform compatibility. - * @summary Healthz - */ -export type healthzHealthzGetResponse200 = { - data: HealthzHealthzGet200; - status: 200; -}; - -export type healthzHealthzGetResponseSuccess = healthzHealthzGetResponse200 & { - headers: Headers; -}; -export type healthzHealthzGetResponse = healthzHealthzGetResponseSuccess; - -export const getHealthzHealthzGetUrl = () => { - return `/healthz`; -}; - -export const healthzHealthzGet = async ( - options?: RequestInit, -): Promise => { - return customFetch(getHealthzHealthzGetUrl(), { - ...options, - method: "GET", - }); -}; - -export const getHealthzHealthzGetQueryKey = () => { - return [`/healthz`] as const; -}; - -export const getHealthzHealthzGetQueryOptions = < - TData = Awaited>, - TError = unknown, ->(options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = queryOptions?.queryKey ?? getHealthzHealthzGetQueryKey(); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => healthzHealthzGet({ signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type HealthzHealthzGetQueryResult = NonNullable< - Awaited> ->; -export type HealthzHealthzGetQueryError = unknown; - -export function useHealthzHealthzGet< - TData = Awaited>, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useHealthzHealthzGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useHealthzHealthzGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Healthz - */ - -export function useHealthzHealthzGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getHealthzHealthzGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Readiness probe endpoint for service orchestration checks. - * @summary Readyz - */ -export type readyzReadyzGetResponse200 = { - data: ReadyzReadyzGet200; - status: 200; -}; - -export type readyzReadyzGetResponseSuccess = readyzReadyzGetResponse200 & { - headers: Headers; -}; -export type readyzReadyzGetResponse = readyzReadyzGetResponseSuccess; - -export const getReadyzReadyzGetUrl = () => { - return `/readyz`; -}; - -export const readyzReadyzGet = async ( - options?: RequestInit, -): Promise => { - return customFetch(getReadyzReadyzGetUrl(), { - ...options, - method: "GET", - }); -}; - -export const getReadyzReadyzGetQueryKey = () => { - return [`/readyz`] as const; -}; - -export const getReadyzReadyzGetQueryOptions = < - TData = Awaited>, - TError = unknown, ->(options?: { - query?: Partial< - UseQueryOptions>, TError, TData> - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = queryOptions?.queryKey ?? getReadyzReadyzGetQueryKey(); - - const queryFn: QueryFunction>> = ({ - signal, - }) => readyzReadyzGet({ signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ReadyzReadyzGetQueryResult = NonNullable< - Awaited> ->; -export type ReadyzReadyzGetQueryError = unknown; - -export function useReadyzReadyzGet< - TData = Awaited>, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useReadyzReadyzGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useReadyzReadyzGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Readyz - */ - -export function useReadyzReadyzGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getReadyzReadyzGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} diff --git a/src/frontend/src/api/generated/gateways/gateways.ts b/src/frontend/src/api/generated/gateways/gateways.ts deleted file mode 100644 index 63e1f9b..0000000 --- a/src/frontend/src/api/generated/gateways/gateways.ts +++ /dev/null @@ -1,2434 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - GatewayCommandsResponse, - GatewayCreate, - GatewayRead, - GatewaySessionHistoryResponse, - GatewaySessionMessageRequest, - GatewaySessionResponse, - GatewaySessionsResponse, - GatewayTemplatesSyncResult, - GatewayUpdate, - GatewaysStatusApiV1GatewaysStatusGetParams, - GatewaysStatusResponse, - GetGatewaySessionApiV1GatewaysSessionsSessionIdGetParams, - GetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams, - HTTPValidationError, - LimitOffsetPageTypeVarCustomizedGatewayRead, - ListGatewaySessionsApiV1GatewaysSessionsGetParams, - ListGatewaysApiV1GatewaysGetParams, - OkResponse, - SendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams, - SyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List gateways for the caller's organization. - * @summary List Gateways - */ -export type listGatewaysApiV1GatewaysGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedGatewayRead; - status: 200; -}; - -export type listGatewaysApiV1GatewaysGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listGatewaysApiV1GatewaysGetResponseSuccess = - listGatewaysApiV1GatewaysGetResponse200 & { - headers: Headers; - }; -export type listGatewaysApiV1GatewaysGetResponseError = - listGatewaysApiV1GatewaysGetResponse422 & { - headers: Headers; - }; - -export type listGatewaysApiV1GatewaysGetResponse = - | listGatewaysApiV1GatewaysGetResponseSuccess - | listGatewaysApiV1GatewaysGetResponseError; - -export const getListGatewaysApiV1GatewaysGetUrl = ( - params?: ListGatewaysApiV1GatewaysGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/gateways?${stringifiedParams}` - : `/api/v1/gateways`; -}; - -export const listGatewaysApiV1GatewaysGet = async ( - params?: ListGatewaysApiV1GatewaysGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListGatewaysApiV1GatewaysGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListGatewaysApiV1GatewaysGetQueryKey = ( - params?: ListGatewaysApiV1GatewaysGetParams, -) => { - return [`/api/v1/gateways`, ...(params ? [params] : [])] as const; -}; - -export const getListGatewaysApiV1GatewaysGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListGatewaysApiV1GatewaysGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getListGatewaysApiV1GatewaysGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listGatewaysApiV1GatewaysGet(params, { signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListGatewaysApiV1GatewaysGetQueryResult = NonNullable< - Awaited> ->; -export type ListGatewaysApiV1GatewaysGetQueryError = HTTPValidationError; - -export function useListGatewaysApiV1GatewaysGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params: undefined | ListGatewaysApiV1GatewaysGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListGatewaysApiV1GatewaysGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListGatewaysApiV1GatewaysGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListGatewaysApiV1GatewaysGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListGatewaysApiV1GatewaysGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Gateways - */ - -export function useListGatewaysApiV1GatewaysGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListGatewaysApiV1GatewaysGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getListGatewaysApiV1GatewaysGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create a gateway and provision or refresh its main agent. - * @summary Create Gateway - */ -export type createGatewayApiV1GatewaysPostResponse200 = { - data: GatewayRead; - status: 200; -}; - -export type createGatewayApiV1GatewaysPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createGatewayApiV1GatewaysPostResponseSuccess = - createGatewayApiV1GatewaysPostResponse200 & { - headers: Headers; - }; -export type createGatewayApiV1GatewaysPostResponseError = - createGatewayApiV1GatewaysPostResponse422 & { - headers: Headers; - }; - -export type createGatewayApiV1GatewaysPostResponse = - | createGatewayApiV1GatewaysPostResponseSuccess - | createGatewayApiV1GatewaysPostResponseError; - -export const getCreateGatewayApiV1GatewaysPostUrl = () => { - return `/api/v1/gateways`; -}; - -export const createGatewayApiV1GatewaysPost = async ( - gatewayCreate: GatewayCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateGatewayApiV1GatewaysPostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(gatewayCreate), - }, - ); -}; - -export const getCreateGatewayApiV1GatewaysPostMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: GatewayCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { data: GatewayCreate }, - TContext -> => { - const mutationKey = ["createGatewayApiV1GatewaysPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { data: GatewayCreate } - > = (props) => { - const { data } = props ?? {}; - - return createGatewayApiV1GatewaysPost(data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type CreateGatewayApiV1GatewaysPostMutationResult = NonNullable< - Awaited> ->; -export type CreateGatewayApiV1GatewaysPostMutationBody = GatewayCreate; -export type CreateGatewayApiV1GatewaysPostMutationError = HTTPValidationError; - -/** - * @summary Create Gateway - */ -export const useCreateGatewayApiV1GatewaysPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: GatewayCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: GatewayCreate }, - TContext -> => { - return useMutation( - getCreateGatewayApiV1GatewaysPostMutationOptions(options), - queryClient, - ); -}; -/** - * Return supported gateway protocol methods and events. - * @summary Gateway Commands - */ -export type gatewayCommandsApiV1GatewaysCommandsGetResponse200 = { - data: GatewayCommandsResponse; - status: 200; -}; - -export type gatewayCommandsApiV1GatewaysCommandsGetResponseSuccess = - gatewayCommandsApiV1GatewaysCommandsGetResponse200 & { - headers: Headers; - }; -export type gatewayCommandsApiV1GatewaysCommandsGetResponse = - gatewayCommandsApiV1GatewaysCommandsGetResponseSuccess; - -export const getGatewayCommandsApiV1GatewaysCommandsGetUrl = () => { - return `/api/v1/gateways/commands`; -}; - -export const gatewayCommandsApiV1GatewaysCommandsGet = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getGatewayCommandsApiV1GatewaysCommandsGetUrl(), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGatewayCommandsApiV1GatewaysCommandsGetQueryKey = () => { - return [`/api/v1/gateways/commands`] as const; -}; - -export const getGatewayCommandsApiV1GatewaysCommandsGetQueryOptions = < - TData = Awaited>, - TError = unknown, ->(options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGatewayCommandsApiV1GatewaysCommandsGetQueryKey(); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - gatewayCommandsApiV1GatewaysCommandsGet({ signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GatewayCommandsApiV1GatewaysCommandsGetQueryResult = NonNullable< - Awaited> ->; -export type GatewayCommandsApiV1GatewaysCommandsGetQueryError = unknown; - -export function useGatewayCommandsApiV1GatewaysCommandsGet< - TData = Awaited>, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGatewayCommandsApiV1GatewaysCommandsGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGatewayCommandsApiV1GatewaysCommandsGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Gateway Commands - */ - -export function useGatewayCommandsApiV1GatewaysCommandsGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGatewayCommandsApiV1GatewaysCommandsGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * List sessions for a gateway associated with a board. - * @summary List Gateway Sessions - */ -export type listGatewaySessionsApiV1GatewaysSessionsGetResponse200 = { - data: GatewaySessionsResponse; - status: 200; -}; - -export type listGatewaySessionsApiV1GatewaysSessionsGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listGatewaySessionsApiV1GatewaysSessionsGetResponseSuccess = - listGatewaySessionsApiV1GatewaysSessionsGetResponse200 & { - headers: Headers; - }; -export type listGatewaySessionsApiV1GatewaysSessionsGetResponseError = - listGatewaySessionsApiV1GatewaysSessionsGetResponse422 & { - headers: Headers; - }; - -export type listGatewaySessionsApiV1GatewaysSessionsGetResponse = - | listGatewaySessionsApiV1GatewaysSessionsGetResponseSuccess - | listGatewaySessionsApiV1GatewaysSessionsGetResponseError; - -export const getListGatewaySessionsApiV1GatewaysSessionsGetUrl = ( - params?: ListGatewaySessionsApiV1GatewaysSessionsGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/gateways/sessions?${stringifiedParams}` - : `/api/v1/gateways/sessions`; -}; - -export const listGatewaySessionsApiV1GatewaysSessionsGet = async ( - params?: ListGatewaySessionsApiV1GatewaysSessionsGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListGatewaySessionsApiV1GatewaysSessionsGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListGatewaySessionsApiV1GatewaysSessionsGetQueryKey = ( - params?: ListGatewaySessionsApiV1GatewaysSessionsGetParams, -) => { - return [`/api/v1/gateways/sessions`, ...(params ? [params] : [])] as const; -}; - -export const getListGatewaySessionsApiV1GatewaysSessionsGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListGatewaySessionsApiV1GatewaysSessionsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListGatewaySessionsApiV1GatewaysSessionsGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listGatewaySessionsApiV1GatewaysSessionsGet(params, { - signal, - ...requestOptions, - }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListGatewaySessionsApiV1GatewaysSessionsGetQueryResult = - NonNullable< - Awaited> - >; -export type ListGatewaySessionsApiV1GatewaysSessionsGetQueryError = - HTTPValidationError; - -export function useListGatewaySessionsApiV1GatewaysSessionsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: undefined | ListGatewaySessionsApiV1GatewaysSessionsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListGatewaySessionsApiV1GatewaysSessionsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListGatewaySessionsApiV1GatewaysSessionsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListGatewaySessionsApiV1GatewaysSessionsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListGatewaySessionsApiV1GatewaysSessionsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Gateway Sessions - */ - -export function useListGatewaySessionsApiV1GatewaysSessionsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListGatewaySessionsApiV1GatewaysSessionsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListGatewaySessionsApiV1GatewaysSessionsGetQueryOptions(params, options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Get a specific gateway session by key. - * @summary Get Gateway Session - */ -export type getGatewaySessionApiV1GatewaysSessionsSessionIdGetResponse200 = { - data: GatewaySessionResponse; - status: 200; -}; - -export type getGatewaySessionApiV1GatewaysSessionsSessionIdGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getGatewaySessionApiV1GatewaysSessionsSessionIdGetResponseSuccess = - getGatewaySessionApiV1GatewaysSessionsSessionIdGetResponse200 & { - headers: Headers; - }; -export type getGatewaySessionApiV1GatewaysSessionsSessionIdGetResponseError = - getGatewaySessionApiV1GatewaysSessionsSessionIdGetResponse422 & { - headers: Headers; - }; - -export type getGatewaySessionApiV1GatewaysSessionsSessionIdGetResponse = - | getGatewaySessionApiV1GatewaysSessionsSessionIdGetResponseSuccess - | getGatewaySessionApiV1GatewaysSessionsSessionIdGetResponseError; - -export const getGetGatewaySessionApiV1GatewaysSessionsSessionIdGetUrl = ( - sessionId: string, - params?: GetGatewaySessionApiV1GatewaysSessionsSessionIdGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/gateways/sessions/${sessionId}?${stringifiedParams}` - : `/api/v1/gateways/sessions/${sessionId}`; -}; - -export const getGatewaySessionApiV1GatewaysSessionsSessionIdGet = async ( - sessionId: string, - params?: GetGatewaySessionApiV1GatewaysSessionsSessionIdGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getGetGatewaySessionApiV1GatewaysSessionsSessionIdGetUrl(sessionId, params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetGatewaySessionApiV1GatewaysSessionsSessionIdGetQueryKey = ( - sessionId: string, - params?: GetGatewaySessionApiV1GatewaysSessionsSessionIdGetParams, -) => { - return [ - `/api/v1/gateways/sessions/${sessionId}`, - ...(params ? [params] : []), - ] as const; -}; - -export const getGetGatewaySessionApiV1GatewaysSessionsSessionIdGetQueryOptions = - < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, - >( - sessionId: string, - params?: GetGatewaySessionApiV1GatewaysSessionsSessionIdGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getGatewaySessionApiV1GatewaysSessionsSessionIdGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetGatewaySessionApiV1GatewaysSessionsSessionIdGetQueryKey( - sessionId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType - > - > = ({ signal }) => - getGatewaySessionApiV1GatewaysSessionsSessionIdGet(sessionId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!sessionId, - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type GetGatewaySessionApiV1GatewaysSessionsSessionIdGetQueryResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type GetGatewaySessionApiV1GatewaysSessionsSessionIdGetQueryError = - HTTPValidationError; - -export function useGetGatewaySessionApiV1GatewaysSessionsSessionIdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - sessionId: string, - params: undefined | GetGatewaySessionApiV1GatewaysSessionsSessionIdGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getGatewaySessionApiV1GatewaysSessionsSessionIdGet - > - >, - TError, - Awaited< - ReturnType< - typeof getGatewaySessionApiV1GatewaysSessionsSessionIdGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetGatewaySessionApiV1GatewaysSessionsSessionIdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - sessionId: string, - params?: GetGatewaySessionApiV1GatewaysSessionsSessionIdGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getGatewaySessionApiV1GatewaysSessionsSessionIdGet - > - >, - TError, - Awaited< - ReturnType< - typeof getGatewaySessionApiV1GatewaysSessionsSessionIdGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetGatewaySessionApiV1GatewaysSessionsSessionIdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - sessionId: string, - params?: GetGatewaySessionApiV1GatewaysSessionsSessionIdGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Gateway Session - */ - -export function useGetGatewaySessionApiV1GatewaysSessionsSessionIdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - sessionId: string, - params?: GetGatewaySessionApiV1GatewaysSessionsSessionIdGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetGatewaySessionApiV1GatewaysSessionsSessionIdGetQueryOptions( - sessionId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Fetch chat history for a gateway session. - * @summary Get Session History - */ -export type getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetResponse200 = - { - data: GatewaySessionHistoryResponse; - status: 200; - }; - -export type getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetResponseSuccess = - getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetResponse200 & { - headers: Headers; - }; -export type getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetResponseError = - getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetResponse422 & { - headers: Headers; - }; - -export type getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetResponse = - | getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetResponseSuccess - | getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetResponseError; - -export const getGetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetUrl = ( - sessionId: string, - params?: GetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/gateways/sessions/${sessionId}/history?${stringifiedParams}` - : `/api/v1/gateways/sessions/${sessionId}/history`; -}; - -export const getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet = async ( - sessionId: string, - params?: GetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getGetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetUrl( - sessionId, - params, - ), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetQueryKey = - ( - sessionId: string, - params?: GetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams, - ) => { - return [ - `/api/v1/gateways/sessions/${sessionId}/history`, - ...(params ? [params] : []), - ] as const; - }; - -export const getGetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetQueryOptions = - < - TData = Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - >, - TError = HTTPValidationError, - >( - sessionId: string, - params?: GetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetQueryKey( - sessionId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - > - > = ({ signal }) => - getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet( - sessionId, - params, - { signal, ...requestOptions }, - ); - - return { - queryKey, - queryFn, - enabled: !!sessionId, - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type GetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetQueryResult = - NonNullable< - Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - > - >; -export type GetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetQueryError = - HTTPValidationError; - -export function useGetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - sessionId: string, - params: - | undefined - | GetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - >, - TError, - Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - sessionId: string, - params?: GetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - >, - TError, - Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - sessionId: string, - params?: GetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Session History - */ - -export function useGetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - sessionId: string, - params?: GetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetQueryOptions( - sessionId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Send a message into a specific gateway session. - * @summary Send Gateway Session Message - */ -export type sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostResponse200 = - { - data: OkResponse; - status: 200; - }; - -export type sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostResponseSuccess = - sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostResponse200 & { - headers: Headers; - }; -export type sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostResponseError = - sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostResponse422 & { - headers: Headers; - }; - -export type sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostResponse = - - | sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostResponseSuccess - | sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostResponseError; - -export const getSendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostUrl = - ( - sessionId: string, - params?: SendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams, - ) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append( - key, - value === null ? "null" : value.toString(), - ); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/gateways/sessions/${sessionId}/message?${stringifiedParams}` - : `/api/v1/gateways/sessions/${sessionId}/message`; - }; - -export const sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePost = - async ( - sessionId: string, - gatewaySessionMessageRequest: GatewaySessionMessageRequest, - params?: SendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams, - options?: RequestInit, - ): Promise => { - return customFetch( - getSendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostUrl( - sessionId, - params, - ), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(gatewaySessionMessageRequest), - }, - ); - }; - -export const getSendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePost - > - >, - TError, - { - sessionId: string; - data: GatewaySessionMessageRequest; - params?: SendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams; - }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePost - > - >, - TError, - { - sessionId: string; - data: GatewaySessionMessageRequest; - params?: SendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams; - }, - TContext - > => { - const mutationKey = [ - "sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePost - > - >, - { - sessionId: string; - data: GatewaySessionMessageRequest; - params?: SendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams; - } - > = (props) => { - const { sessionId, data, params } = props ?? {}; - - return sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePost( - sessionId, - data, - params, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type SendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePost - > - > - >; -export type SendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostMutationBody = - GatewaySessionMessageRequest; -export type SendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostMutationError = - HTTPValidationError; - -/** - * @summary Send Gateway Session Message - */ -export const useSendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePost = - ( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePost - > - >, - TError, - { - sessionId: string; - data: GatewaySessionMessageRequest; - params?: SendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams; - }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, - ): UseMutationResult< - Awaited< - ReturnType< - typeof sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePost - > - >, - TError, - { - sessionId: string; - data: GatewaySessionMessageRequest; - params?: SendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams; - }, - TContext - > => { - return useMutation( - getSendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostMutationOptions( - options, - ), - queryClient, - ); - }; -/** - * Return gateway connectivity and session status. - * @summary Gateways Status - */ -export type gatewaysStatusApiV1GatewaysStatusGetResponse200 = { - data: GatewaysStatusResponse; - status: 200; -}; - -export type gatewaysStatusApiV1GatewaysStatusGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type gatewaysStatusApiV1GatewaysStatusGetResponseSuccess = - gatewaysStatusApiV1GatewaysStatusGetResponse200 & { - headers: Headers; - }; -export type gatewaysStatusApiV1GatewaysStatusGetResponseError = - gatewaysStatusApiV1GatewaysStatusGetResponse422 & { - headers: Headers; - }; - -export type gatewaysStatusApiV1GatewaysStatusGetResponse = - | gatewaysStatusApiV1GatewaysStatusGetResponseSuccess - | gatewaysStatusApiV1GatewaysStatusGetResponseError; - -export const getGatewaysStatusApiV1GatewaysStatusGetUrl = ( - params?: GatewaysStatusApiV1GatewaysStatusGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/gateways/status?${stringifiedParams}` - : `/api/v1/gateways/status`; -}; - -export const gatewaysStatusApiV1GatewaysStatusGet = async ( - params?: GatewaysStatusApiV1GatewaysStatusGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getGatewaysStatusApiV1GatewaysStatusGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGatewaysStatusApiV1GatewaysStatusGetQueryKey = ( - params?: GatewaysStatusApiV1GatewaysStatusGetParams, -) => { - return [`/api/v1/gateways/status`, ...(params ? [params] : [])] as const; -}; - -export const getGatewaysStatusApiV1GatewaysStatusGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: GatewaysStatusApiV1GatewaysStatusGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGatewaysStatusApiV1GatewaysStatusGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - gatewaysStatusApiV1GatewaysStatusGet(params, { signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GatewaysStatusApiV1GatewaysStatusGetQueryResult = NonNullable< - Awaited> ->; -export type GatewaysStatusApiV1GatewaysStatusGetQueryError = - HTTPValidationError; - -export function useGatewaysStatusApiV1GatewaysStatusGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params: undefined | GatewaysStatusApiV1GatewaysStatusGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGatewaysStatusApiV1GatewaysStatusGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: GatewaysStatusApiV1GatewaysStatusGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGatewaysStatusApiV1GatewaysStatusGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: GatewaysStatusApiV1GatewaysStatusGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Gateways Status - */ - -export function useGatewaysStatusApiV1GatewaysStatusGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: GatewaysStatusApiV1GatewaysStatusGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getGatewaysStatusApiV1GatewaysStatusGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Delete a gateway in the caller's organization. - * @summary Delete Gateway - */ -export type deleteGatewayApiV1GatewaysGatewayIdDeleteResponse200 = { - data: OkResponse; - status: 200; -}; - -export type deleteGatewayApiV1GatewaysGatewayIdDeleteResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type deleteGatewayApiV1GatewaysGatewayIdDeleteResponseSuccess = - deleteGatewayApiV1GatewaysGatewayIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteGatewayApiV1GatewaysGatewayIdDeleteResponseError = - deleteGatewayApiV1GatewaysGatewayIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteGatewayApiV1GatewaysGatewayIdDeleteResponse = - | deleteGatewayApiV1GatewaysGatewayIdDeleteResponseSuccess - | deleteGatewayApiV1GatewaysGatewayIdDeleteResponseError; - -export const getDeleteGatewayApiV1GatewaysGatewayIdDeleteUrl = ( - gatewayId: string, -) => { - return `/api/v1/gateways/${gatewayId}`; -}; - -export const deleteGatewayApiV1GatewaysGatewayIdDelete = async ( - gatewayId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getDeleteGatewayApiV1GatewaysGatewayIdDeleteUrl(gatewayId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getDeleteGatewayApiV1GatewaysGatewayIdDeleteMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { gatewayId: string }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { gatewayId: string }, - TContext -> => { - const mutationKey = ["deleteGatewayApiV1GatewaysGatewayIdDelete"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { gatewayId: string } - > = (props) => { - const { gatewayId } = props ?? {}; - - return deleteGatewayApiV1GatewaysGatewayIdDelete(gatewayId, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type DeleteGatewayApiV1GatewaysGatewayIdDeleteMutationResult = - NonNullable< - Awaited> - >; - -export type DeleteGatewayApiV1GatewaysGatewayIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Delete Gateway - */ -export const useDeleteGatewayApiV1GatewaysGatewayIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { gatewayId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { gatewayId: string }, - TContext -> => { - return useMutation( - getDeleteGatewayApiV1GatewaysGatewayIdDeleteMutationOptions(options), - queryClient, - ); -}; -/** - * Return one gateway by id for the caller's organization. - * @summary Get Gateway - */ -export type getGatewayApiV1GatewaysGatewayIdGetResponse200 = { - data: GatewayRead; - status: 200; -}; - -export type getGatewayApiV1GatewaysGatewayIdGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getGatewayApiV1GatewaysGatewayIdGetResponseSuccess = - getGatewayApiV1GatewaysGatewayIdGetResponse200 & { - headers: Headers; - }; -export type getGatewayApiV1GatewaysGatewayIdGetResponseError = - getGatewayApiV1GatewaysGatewayIdGetResponse422 & { - headers: Headers; - }; - -export type getGatewayApiV1GatewaysGatewayIdGetResponse = - | getGatewayApiV1GatewaysGatewayIdGetResponseSuccess - | getGatewayApiV1GatewaysGatewayIdGetResponseError; - -export const getGetGatewayApiV1GatewaysGatewayIdGetUrl = ( - gatewayId: string, -) => { - return `/api/v1/gateways/${gatewayId}`; -}; - -export const getGatewayApiV1GatewaysGatewayIdGet = async ( - gatewayId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetGatewayApiV1GatewaysGatewayIdGetUrl(gatewayId), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetGatewayApiV1GatewaysGatewayIdGetQueryKey = ( - gatewayId: string, -) => { - return [`/api/v1/gateways/${gatewayId}`] as const; -}; - -export const getGetGatewayApiV1GatewaysGatewayIdGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - gatewayId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetGatewayApiV1GatewaysGatewayIdGetQueryKey(gatewayId); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getGatewayApiV1GatewaysGatewayIdGet(gatewayId, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!gatewayId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetGatewayApiV1GatewaysGatewayIdGetQueryResult = NonNullable< - Awaited> ->; -export type GetGatewayApiV1GatewaysGatewayIdGetQueryError = HTTPValidationError; - -export function useGetGatewayApiV1GatewaysGatewayIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - gatewayId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetGatewayApiV1GatewaysGatewayIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - gatewayId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetGatewayApiV1GatewaysGatewayIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - gatewayId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Gateway - */ - -export function useGetGatewayApiV1GatewaysGatewayIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - gatewayId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getGetGatewayApiV1GatewaysGatewayIdGetQueryOptions( - gatewayId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Patch a gateway and refresh the main-agent provisioning state. - * @summary Update Gateway - */ -export type updateGatewayApiV1GatewaysGatewayIdPatchResponse200 = { - data: GatewayRead; - status: 200; -}; - -export type updateGatewayApiV1GatewaysGatewayIdPatchResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type updateGatewayApiV1GatewaysGatewayIdPatchResponseSuccess = - updateGatewayApiV1GatewaysGatewayIdPatchResponse200 & { - headers: Headers; - }; -export type updateGatewayApiV1GatewaysGatewayIdPatchResponseError = - updateGatewayApiV1GatewaysGatewayIdPatchResponse422 & { - headers: Headers; - }; - -export type updateGatewayApiV1GatewaysGatewayIdPatchResponse = - | updateGatewayApiV1GatewaysGatewayIdPatchResponseSuccess - | updateGatewayApiV1GatewaysGatewayIdPatchResponseError; - -export const getUpdateGatewayApiV1GatewaysGatewayIdPatchUrl = ( - gatewayId: string, -) => { - return `/api/v1/gateways/${gatewayId}`; -}; - -export const updateGatewayApiV1GatewaysGatewayIdPatch = async ( - gatewayId: string, - gatewayUpdate: GatewayUpdate, - options?: RequestInit, -): Promise => { - return customFetch( - getUpdateGatewayApiV1GatewaysGatewayIdPatchUrl(gatewayId), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(gatewayUpdate), - }, - ); -}; - -export const getUpdateGatewayApiV1GatewaysGatewayIdPatchMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { gatewayId: string; data: GatewayUpdate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { gatewayId: string; data: GatewayUpdate }, - TContext -> => { - const mutationKey = ["updateGatewayApiV1GatewaysGatewayIdPatch"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { gatewayId: string; data: GatewayUpdate } - > = (props) => { - const { gatewayId, data } = props ?? {}; - - return updateGatewayApiV1GatewaysGatewayIdPatch( - gatewayId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type UpdateGatewayApiV1GatewaysGatewayIdPatchMutationResult = - NonNullable< - Awaited> - >; -export type UpdateGatewayApiV1GatewaysGatewayIdPatchMutationBody = - GatewayUpdate; -export type UpdateGatewayApiV1GatewaysGatewayIdPatchMutationError = - HTTPValidationError; - -/** - * @summary Update Gateway - */ -export const useUpdateGatewayApiV1GatewaysGatewayIdPatch = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { gatewayId: string; data: GatewayUpdate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { gatewayId: string; data: GatewayUpdate }, - TContext -> => { - return useMutation( - getUpdateGatewayApiV1GatewaysGatewayIdPatchMutationOptions(options), - queryClient, - ); -}; -/** - * Sync templates for a gateway and optionally rotate runtime settings. - * @summary Sync Gateway Templates - */ -export type syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostResponse200 = - { - data: GatewayTemplatesSyncResult; - status: 200; - }; - -export type syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostResponseSuccess = - syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostResponse200 & { - headers: Headers; - }; -export type syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostResponseError = - syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostResponse422 & { - headers: Headers; - }; - -export type syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostResponse = - - | syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostResponseSuccess - | syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostResponseError; - -export const getSyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostUrl = - ( - gatewayId: string, - params?: SyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams, - ) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append( - key, - value === null ? "null" : value.toString(), - ); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/gateways/${gatewayId}/templates/sync?${stringifiedParams}` - : `/api/v1/gateways/${gatewayId}/templates/sync`; - }; - -export const syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPost = - async ( - gatewayId: string, - params?: SyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams, - options?: RequestInit, - ): Promise => { - return customFetch( - getSyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostUrl( - gatewayId, - params, - ), - { - ...options, - method: "POST", - }, - ); - }; - -export const getSyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPost - > - >, - TError, - { - gatewayId: string; - params?: SyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams; - }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPost - > - >, - TError, - { - gatewayId: string; - params?: SyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams; - }, - TContext - > => { - const mutationKey = [ - "syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPost - > - >, - { - gatewayId: string; - params?: SyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams; - } - > = (props) => { - const { gatewayId, params } = props ?? {}; - - return syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPost( - gatewayId, - params, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type SyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPost - > - > - >; - -export type SyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostMutationError = - HTTPValidationError; - -/** - * @summary Sync Gateway Templates - */ -export const useSyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPost - > - >, - TError, - { - gatewayId: string; - params?: SyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams; - }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType< - typeof syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPost - > - >, - TError, - { - gatewayId: string; - params?: SyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams; - }, - TContext -> => { - return useMutation( - getSyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostMutationOptions( - options, - ), - queryClient, - ); -}; diff --git a/src/frontend/src/api/generated/health/health.ts b/src/frontend/src/api/generated/health/health.ts deleted file mode 100644 index cc56591..0000000 --- a/src/frontend/src/api/generated/health/health.ts +++ /dev/null @@ -1,514 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { HealthStatusResponse } from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * Lightweight liveness probe endpoint. - * @summary Health Check - */ -export type healthHealthGetResponse200 = { - data: HealthStatusResponse; - status: 200; -}; - -export type healthHealthGetResponseSuccess = healthHealthGetResponse200 & { - headers: Headers; -}; -export type healthHealthGetResponse = healthHealthGetResponseSuccess; - -export const getHealthHealthGetUrl = () => { - return `/health`; -}; - -export const healthHealthGet = async ( - options?: RequestInit, -): Promise => { - return customFetch(getHealthHealthGetUrl(), { - ...options, - method: "GET", - }); -}; - -export const getHealthHealthGetQueryKey = () => { - return [`/health`] as const; -}; - -export const getHealthHealthGetQueryOptions = < - TData = Awaited>, - TError = unknown, ->(options?: { - query?: Partial< - UseQueryOptions>, TError, TData> - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = queryOptions?.queryKey ?? getHealthHealthGetQueryKey(); - - const queryFn: QueryFunction>> = ({ - signal, - }) => healthHealthGet({ signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type HealthHealthGetQueryResult = NonNullable< - Awaited> ->; -export type HealthHealthGetQueryError = unknown; - -export function useHealthHealthGet< - TData = Awaited>, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useHealthHealthGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useHealthHealthGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Health Check - */ - -export function useHealthHealthGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getHealthHealthGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Alias liveness probe endpoint for platform compatibility. - * @summary Health Alias Check - */ -export type healthzHealthzGetResponse200 = { - data: HealthStatusResponse; - status: 200; -}; - -export type healthzHealthzGetResponseSuccess = healthzHealthzGetResponse200 & { - headers: Headers; -}; -export type healthzHealthzGetResponse = healthzHealthzGetResponseSuccess; - -export const getHealthzHealthzGetUrl = () => { - return `/healthz`; -}; - -export const healthzHealthzGet = async ( - options?: RequestInit, -): Promise => { - return customFetch(getHealthzHealthzGetUrl(), { - ...options, - method: "GET", - }); -}; - -export const getHealthzHealthzGetQueryKey = () => { - return [`/healthz`] as const; -}; - -export const getHealthzHealthzGetQueryOptions = < - TData = Awaited>, - TError = unknown, ->(options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = queryOptions?.queryKey ?? getHealthzHealthzGetQueryKey(); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => healthzHealthzGet({ signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type HealthzHealthzGetQueryResult = NonNullable< - Awaited> ->; -export type HealthzHealthzGetQueryError = unknown; - -export function useHealthzHealthzGet< - TData = Awaited>, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useHealthzHealthzGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useHealthzHealthzGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Health Alias Check - */ - -export function useHealthzHealthzGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getHealthzHealthzGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Readiness probe endpoint for service orchestration checks. - * @summary Readiness Check - */ -export type readyzReadyzGetResponse200 = { - data: HealthStatusResponse; - status: 200; -}; - -export type readyzReadyzGetResponseSuccess = readyzReadyzGetResponse200 & { - headers: Headers; -}; -export type readyzReadyzGetResponse = readyzReadyzGetResponseSuccess; - -export const getReadyzReadyzGetUrl = () => { - return `/readyz`; -}; - -export const readyzReadyzGet = async ( - options?: RequestInit, -): Promise => { - return customFetch(getReadyzReadyzGetUrl(), { - ...options, - method: "GET", - }); -}; - -export const getReadyzReadyzGetQueryKey = () => { - return [`/readyz`] as const; -}; - -export const getReadyzReadyzGetQueryOptions = < - TData = Awaited>, - TError = unknown, ->(options?: { - query?: Partial< - UseQueryOptions>, TError, TData> - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = queryOptions?.queryKey ?? getReadyzReadyzGetQueryKey(); - - const queryFn: QueryFunction>> = ({ - signal, - }) => readyzReadyzGet({ signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ReadyzReadyzGetQueryResult = NonNullable< - Awaited> ->; -export type ReadyzReadyzGetQueryError = unknown; - -export function useReadyzReadyzGet< - TData = Awaited>, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useReadyzReadyzGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useReadyzReadyzGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Readiness Check - */ - -export function useReadyzReadyzGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getReadyzReadyzGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} diff --git a/src/frontend/src/api/generated/metrics/metrics.ts b/src/frontend/src/api/generated/metrics/metrics.ts deleted file mode 100644 index 63904c6..0000000 --- a/src/frontend/src/api/generated/metrics/metrics.ts +++ /dev/null @@ -1,244 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - DashboardMetrics, - DashboardMetricsApiV1MetricsDashboardGetParams, - HTTPValidationError, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * Return dashboard KPIs and time-series data for accessible boards. - * @summary Dashboard Metrics - */ -export type dashboardMetricsApiV1MetricsDashboardGetResponse200 = { - data: DashboardMetrics; - status: 200; -}; - -export type dashboardMetricsApiV1MetricsDashboardGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type dashboardMetricsApiV1MetricsDashboardGetResponseSuccess = - dashboardMetricsApiV1MetricsDashboardGetResponse200 & { - headers: Headers; - }; -export type dashboardMetricsApiV1MetricsDashboardGetResponseError = - dashboardMetricsApiV1MetricsDashboardGetResponse422 & { - headers: Headers; - }; - -export type dashboardMetricsApiV1MetricsDashboardGetResponse = - | dashboardMetricsApiV1MetricsDashboardGetResponseSuccess - | dashboardMetricsApiV1MetricsDashboardGetResponseError; - -export const getDashboardMetricsApiV1MetricsDashboardGetUrl = ( - params?: DashboardMetricsApiV1MetricsDashboardGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/metrics/dashboard?${stringifiedParams}` - : `/api/v1/metrics/dashboard`; -}; - -export const dashboardMetricsApiV1MetricsDashboardGet = async ( - params?: DashboardMetricsApiV1MetricsDashboardGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getDashboardMetricsApiV1MetricsDashboardGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getDashboardMetricsApiV1MetricsDashboardGetQueryKey = ( - params?: DashboardMetricsApiV1MetricsDashboardGetParams, -) => { - return [`/api/v1/metrics/dashboard`, ...(params ? [params] : [])] as const; -}; - -export const getDashboardMetricsApiV1MetricsDashboardGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: DashboardMetricsApiV1MetricsDashboardGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getDashboardMetricsApiV1MetricsDashboardGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - dashboardMetricsApiV1MetricsDashboardGet(params, { - signal, - ...requestOptions, - }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type DashboardMetricsApiV1MetricsDashboardGetQueryResult = NonNullable< - Awaited> ->; -export type DashboardMetricsApiV1MetricsDashboardGetQueryError = - HTTPValidationError; - -export function useDashboardMetricsApiV1MetricsDashboardGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params: undefined | DashboardMetricsApiV1MetricsDashboardGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useDashboardMetricsApiV1MetricsDashboardGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: DashboardMetricsApiV1MetricsDashboardGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useDashboardMetricsApiV1MetricsDashboardGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: DashboardMetricsApiV1MetricsDashboardGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Dashboard Metrics - */ - -export function useDashboardMetricsApiV1MetricsDashboardGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: DashboardMetricsApiV1MetricsDashboardGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getDashboardMetricsApiV1MetricsDashboardGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} diff --git a/src/frontend/src/api/generated/model/activityEventRead.ts b/src/frontend/src/api/generated/model/activityEventRead.ts deleted file mode 100644 index 8816315..0000000 --- a/src/frontend/src/api/generated/model/activityEventRead.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { ActivityEventReadRouteParams } from "./activityEventReadRouteParams"; - -/** - * Serialized activity event payload returned by activity endpoints. - */ -export interface ActivityEventRead { - agent_id: string | null; - board_id?: string | null; - created_at: string; - event_type: string; - id: string; - message: string | null; - route_name?: string | null; - route_params?: ActivityEventReadRouteParams; - task_id: string | null; -} diff --git a/src/frontend/src/api/generated/model/activityEventReadRouteParams.ts b/src/frontend/src/api/generated/model/activityEventReadRouteParams.ts deleted file mode 100644 index 1871643..0000000 --- a/src/frontend/src/api/generated/model/activityEventReadRouteParams.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ActivityEventReadRouteParams = { [key: string]: string } | null; diff --git a/src/frontend/src/api/generated/model/activityTaskCommentFeedItemRead.ts b/src/frontend/src/api/generated/model/activityTaskCommentFeedItemRead.ts deleted file mode 100644 index df534a5..0000000 --- a/src/frontend/src/api/generated/model/activityTaskCommentFeedItemRead.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Denormalized task-comment feed item enriched with task and board fields. - */ -export interface ActivityTaskCommentFeedItemRead { - agent_id: string | null; - agent_name?: string | null; - agent_role?: string | null; - board_id: string; - board_name: string; - created_at: string; - id: string; - message: string | null; - task_id: string; - task_title: string; -} diff --git a/src/frontend/src/api/generated/model/agentCreate.ts b/src/frontend/src/api/generated/model/agentCreate.ts deleted file mode 100644 index f714f1f..0000000 --- a/src/frontend/src/api/generated/model/agentCreate.ts +++ /dev/null @@ -1,31 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { AgentCreateHeartbeatConfig } from "./agentCreateHeartbeatConfig"; -import type { AgentCreateIdentityProfile } from "./agentCreateIdentityProfile"; - -/** - * Payload for creating a new agent. - */ -export interface AgentCreate { - /** Board id that scopes this agent. Omit only when policy allows global agents. */ - board_id?: string | null; - /** Runtime heartbeat behavior overrides for this agent. */ - heartbeat_config?: AgentCreateHeartbeatConfig; - /** Optional profile hints used by routing and policy checks. */ - identity_profile?: AgentCreateIdentityProfile; - /** Template that helps define initial intent and behavior. */ - identity_template?: string | null; - /** - * Human-readable agent display name. - * @minLength 1 - */ - name: string; - /** Template representing deeper agent instructions. */ - soul_template?: string | null; - /** Current lifecycle state used by coordinator logic. */ - status?: string; -} diff --git a/src/frontend/src/api/generated/model/agentCreateHeartbeatConfig.ts b/src/frontend/src/api/generated/model/agentCreateHeartbeatConfig.ts deleted file mode 100644 index 948daca..0000000 --- a/src/frontend/src/api/generated/model/agentCreateHeartbeatConfig.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Runtime heartbeat behavior overrides for this agent. - */ -export type AgentCreateHeartbeatConfig = { [key: string]: unknown } | null; diff --git a/src/frontend/src/api/generated/model/agentCreateIdentityProfile.ts b/src/frontend/src/api/generated/model/agentCreateIdentityProfile.ts deleted file mode 100644 index 322463d..0000000 --- a/src/frontend/src/api/generated/model/agentCreateIdentityProfile.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Optional profile hints used by routing and policy checks. - */ -export type AgentCreateIdentityProfile = { [key: string]: unknown } | null; diff --git a/src/frontend/src/api/generated/model/agentHealthStatusResponse.ts b/src/frontend/src/api/generated/model/agentHealthStatusResponse.ts deleted file mode 100644 index 20e8d16..0000000 --- a/src/frontend/src/api/generated/model/agentHealthStatusResponse.ts +++ /dev/null @@ -1,24 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Agent-authenticated liveness payload for agent route probes. - */ -export interface AgentHealthStatusResponse { - /** Authenticated agent id derived from `X-Agent-Token`. */ - agent_id: string; - /** Board scope for the authenticated agent, when applicable. */ - board_id?: string | null; - /** Gateway owning the authenticated agent. */ - gateway_id: string; - /** Whether the authenticated agent is the board lead. */ - is_board_lead: boolean; - /** Indicates whether the probe check succeeded. */ - ok: boolean; - /** Current persisted lifecycle status for the authenticated agent. */ - status: string; -} diff --git a/src/frontend/src/api/generated/model/agentHeartbeat.ts b/src/frontend/src/api/generated/model/agentHeartbeat.ts deleted file mode 100644 index de63cc7..0000000 --- a/src/frontend/src/api/generated/model/agentHeartbeat.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Heartbeat status payload sent by agents. - */ -export interface AgentHeartbeat { - /** Agent health status string. */ - status?: string | null; -} diff --git a/src/frontend/src/api/generated/model/agentHeartbeatCreate.ts b/src/frontend/src/api/generated/model/agentHeartbeatCreate.ts deleted file mode 100644 index 7e83d62..0000000 --- a/src/frontend/src/api/generated/model/agentHeartbeatCreate.ts +++ /dev/null @@ -1,21 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Heartbeat payload used to create an agent lazily. - */ -export interface AgentHeartbeatCreate { - /** Optional board context for bootstrap. */ - board_id?: string | null; - /** - * Display name assigned during first heartbeat bootstrap. - * @minLength 1 - */ - name: string; - /** Agent health status string. */ - status?: string | null; -} diff --git a/src/frontend/src/api/generated/model/agentNudge.ts b/src/frontend/src/api/generated/model/agentNudge.ts deleted file mode 100644 index 8b295b3..0000000 --- a/src/frontend/src/api/generated/model/agentNudge.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Nudge message payload for pinging an agent. - */ -export interface AgentNudge { - /** - * Short message to direct an agent toward immediate attention. - * @minLength 1 - */ - message: string; -} diff --git a/src/frontend/src/api/generated/model/agentRead.ts b/src/frontend/src/api/generated/model/agentRead.ts deleted file mode 100644 index 99658f7..0000000 --- a/src/frontend/src/api/generated/model/agentRead.ts +++ /dev/null @@ -1,47 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { AgentReadHeartbeatConfig } from "./agentReadHeartbeatConfig"; -import type { AgentReadIdentityProfile } from "./agentReadIdentityProfile"; - -/** - * Public agent representation returned by the API. - */ -export interface AgentRead { - /** Board id that scopes this agent. Omit only when policy allows global agents. */ - board_id?: string | null; - /** Creation timestamp. */ - created_at: string; - /** Gateway UUID that manages this agent. */ - gateway_id: string; - /** Runtime heartbeat behavior overrides for this agent. */ - heartbeat_config?: AgentReadHeartbeatConfig; - /** Agent UUID. */ - id: string; - /** Optional profile hints used by routing and policy checks. */ - identity_profile?: AgentReadIdentityProfile; - /** Template that helps define initial intent and behavior. */ - identity_template?: string | null; - /** Whether this agent is the board lead. */ - is_board_lead?: boolean; - /** Whether this agent is the primary gateway agent. */ - is_gateway_main?: boolean; - /** Last heartbeat timestamp. */ - last_seen_at?: string | null; - /** - * Human-readable agent display name. - * @minLength 1 - */ - name: string; - /** Optional openclaw session token. */ - openclaw_session_id?: string | null; - /** Template representing deeper agent instructions. */ - soul_template?: string | null; - /** Current lifecycle state used by coordinator logic. */ - status?: string; - /** Last update timestamp. */ - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/agentReadHeartbeatConfig.ts b/src/frontend/src/api/generated/model/agentReadHeartbeatConfig.ts deleted file mode 100644 index 069b9fd..0000000 --- a/src/frontend/src/api/generated/model/agentReadHeartbeatConfig.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Runtime heartbeat behavior overrides for this agent. - */ -export type AgentReadHeartbeatConfig = { [key: string]: unknown } | null; diff --git a/src/frontend/src/api/generated/model/agentReadIdentityProfile.ts b/src/frontend/src/api/generated/model/agentReadIdentityProfile.ts deleted file mode 100644 index 44e5935..0000000 --- a/src/frontend/src/api/generated/model/agentReadIdentityProfile.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Optional profile hints used by routing and policy checks. - */ -export type AgentReadIdentityProfile = { [key: string]: unknown } | null; diff --git a/src/frontend/src/api/generated/model/agentUpdate.ts b/src/frontend/src/api/generated/model/agentUpdate.ts deleted file mode 100644 index 1ec302a..0000000 --- a/src/frontend/src/api/generated/model/agentUpdate.ts +++ /dev/null @@ -1,30 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { AgentUpdateHeartbeatConfig } from "./agentUpdateHeartbeatConfig"; -import type { AgentUpdateIdentityProfile } from "./agentUpdateIdentityProfile"; - -/** - * Payload for patching an existing agent. - */ -export interface AgentUpdate { - /** Optional new board assignment. */ - board_id?: string | null; - /** Optional heartbeat policy override. */ - heartbeat_config?: AgentUpdateHeartbeatConfig; - /** Optional identity profile update values. */ - identity_profile?: AgentUpdateIdentityProfile; - /** Optional replacement identity template. */ - identity_template?: string | null; - /** Whether this agent is treated as the board gateway main. */ - is_gateway_main?: boolean | null; - /** Optional replacement display name. */ - name?: string | null; - /** Optional replacement soul template. */ - soul_template?: string | null; - /** Optional replacement lifecycle status. */ - status?: string | null; -} diff --git a/src/frontend/src/api/generated/model/agentUpdateHeartbeatConfig.ts b/src/frontend/src/api/generated/model/agentUpdateHeartbeatConfig.ts deleted file mode 100644 index 05c6888..0000000 --- a/src/frontend/src/api/generated/model/agentUpdateHeartbeatConfig.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Optional heartbeat policy override. - */ -export type AgentUpdateHeartbeatConfig = { [key: string]: unknown } | null; diff --git a/src/frontend/src/api/generated/model/agentUpdateIdentityProfile.ts b/src/frontend/src/api/generated/model/agentUpdateIdentityProfile.ts deleted file mode 100644 index b79273a..0000000 --- a/src/frontend/src/api/generated/model/agentUpdateIdentityProfile.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Optional identity profile update values. - */ -export type AgentUpdateIdentityProfile = { [key: string]: unknown } | null; diff --git a/src/frontend/src/api/generated/model/approvalCreate.ts b/src/frontend/src/api/generated/model/approvalCreate.ts deleted file mode 100644 index 320c7a0..0000000 --- a/src/frontend/src/api/generated/model/approvalCreate.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { ApprovalCreatePayload } from "./approvalCreatePayload"; -import type { ApprovalCreateRubricScores } from "./approvalCreateRubricScores"; -import type { ApprovalCreateStatus } from "./approvalCreateStatus"; - -/** - * Payload for creating a new approval request. - */ -export interface ApprovalCreate { - action_type: string; - agent_id?: string | null; - /** - * @minimum 0 - * @maximum 100 - */ - confidence: number; - lead_reasoning?: string | null; - payload?: ApprovalCreatePayload; - rubric_scores?: ApprovalCreateRubricScores; - status?: ApprovalCreateStatus; - task_id?: string | null; - task_ids?: string[]; -} diff --git a/src/frontend/src/api/generated/model/approvalCreatePayload.ts b/src/frontend/src/api/generated/model/approvalCreatePayload.ts deleted file mode 100644 index 76ec520..0000000 --- a/src/frontend/src/api/generated/model/approvalCreatePayload.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ApprovalCreatePayload = { [key: string]: unknown } | null; diff --git a/src/frontend/src/api/generated/model/approvalCreateRubricScores.ts b/src/frontend/src/api/generated/model/approvalCreateRubricScores.ts deleted file mode 100644 index 39ba1cb..0000000 --- a/src/frontend/src/api/generated/model/approvalCreateRubricScores.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ApprovalCreateRubricScores = { [key: string]: number } | null; diff --git a/src/frontend/src/api/generated/model/approvalCreateStatus.ts b/src/frontend/src/api/generated/model/approvalCreateStatus.ts deleted file mode 100644 index 7939616..0000000 --- a/src/frontend/src/api/generated/model/approvalCreateStatus.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ApprovalCreateStatus = - (typeof ApprovalCreateStatus)[keyof typeof ApprovalCreateStatus]; - -export const ApprovalCreateStatus = { - pending: "pending", - approved: "approved", - rejected: "rejected", -} as const; diff --git a/src/frontend/src/api/generated/model/approvalRead.ts b/src/frontend/src/api/generated/model/approvalRead.ts deleted file mode 100644 index 9715885..0000000 --- a/src/frontend/src/api/generated/model/approvalRead.ts +++ /dev/null @@ -1,32 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { ApprovalReadPayload } from "./approvalReadPayload"; -import type { ApprovalReadRubricScores } from "./approvalReadRubricScores"; -import type { ApprovalReadStatus } from "./approvalReadStatus"; - -/** - * Approval payload returned from read endpoints. - */ -export interface ApprovalRead { - action_type: string; - agent_id?: string | null; - board_id: string; - /** - * @minimum 0 - * @maximum 100 - */ - confidence: number; - created_at: string; - id: string; - payload?: ApprovalReadPayload; - resolved_at?: string | null; - rubric_scores?: ApprovalReadRubricScores; - status?: ApprovalReadStatus; - task_id?: string | null; - task_ids?: string[]; - task_titles?: string[]; -} diff --git a/src/frontend/src/api/generated/model/approvalReadPayload.ts b/src/frontend/src/api/generated/model/approvalReadPayload.ts deleted file mode 100644 index c5e7fa1..0000000 --- a/src/frontend/src/api/generated/model/approvalReadPayload.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ApprovalReadPayload = { [key: string]: unknown } | null; diff --git a/src/frontend/src/api/generated/model/approvalReadRubricScores.ts b/src/frontend/src/api/generated/model/approvalReadRubricScores.ts deleted file mode 100644 index e3aeff1..0000000 --- a/src/frontend/src/api/generated/model/approvalReadRubricScores.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ApprovalReadRubricScores = { [key: string]: number } | null; diff --git a/src/frontend/src/api/generated/model/approvalReadStatus.ts b/src/frontend/src/api/generated/model/approvalReadStatus.ts deleted file mode 100644 index e945fbb..0000000 --- a/src/frontend/src/api/generated/model/approvalReadStatus.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ApprovalReadStatus = - (typeof ApprovalReadStatus)[keyof typeof ApprovalReadStatus]; - -export const ApprovalReadStatus = { - pending: "pending", - approved: "approved", - rejected: "rejected", -} as const; diff --git a/src/frontend/src/api/generated/model/approvalUpdate.ts b/src/frontend/src/api/generated/model/approvalUpdate.ts deleted file mode 100644 index 7503cd7..0000000 --- a/src/frontend/src/api/generated/model/approvalUpdate.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for mutating approval status. - */ -export interface ApprovalUpdate { - status?: "pending" | "approved" | "rejected" | null; -} diff --git a/src/frontend/src/api/generated/model/blockedTaskDetail.ts b/src/frontend/src/api/generated/model/blockedTaskDetail.ts deleted file mode 100644 index d9e7112..0000000 --- a/src/frontend/src/api/generated/model/blockedTaskDetail.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Error detail payload listing blocking dependency task identifiers. - */ -export interface BlockedTaskDetail { - blocked_by_task_ids?: string[]; - message: string; -} diff --git a/src/frontend/src/api/generated/model/blockedTaskError.ts b/src/frontend/src/api/generated/model/blockedTaskError.ts deleted file mode 100644 index 3451e69..0000000 --- a/src/frontend/src/api/generated/model/blockedTaskError.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BlockedTaskDetail } from "./blockedTaskDetail"; - -/** - * Top-level blocked-task error response envelope. - */ -export interface BlockedTaskError { - detail: BlockedTaskDetail; -} diff --git a/src/frontend/src/api/generated/model/boardCreate.ts b/src/frontend/src/api/generated/model/boardCreate.ts deleted file mode 100644 index 915e26f..0000000 --- a/src/frontend/src/api/generated/model/boardCreate.ts +++ /dev/null @@ -1,31 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardCreateSuccessMetrics } from "./boardCreateSuccessMetrics"; - -/** - * Payload for creating a board. - */ -export interface BoardCreate { - block_status_changes_with_pending_approval?: boolean; - board_group_id?: string | null; - board_type?: string; - comment_required_for_review?: boolean; - description: string; - gateway_id?: string | null; - goal_confirmed?: boolean; - goal_source?: string | null; - /** @minimum 0 */ - max_agents?: number; - name: string; - objective?: string | null; - only_lead_can_change_status?: boolean; - require_approval_for_done?: boolean; - require_review_before_done?: boolean; - slug: string; - success_metrics?: BoardCreateSuccessMetrics; - target_date?: string | null; -} diff --git a/src/frontend/src/api/generated/model/boardCreateSuccessMetrics.ts b/src/frontend/src/api/generated/model/boardCreateSuccessMetrics.ts deleted file mode 100644 index f078313..0000000 --- a/src/frontend/src/api/generated/model/boardCreateSuccessMetrics.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type BoardCreateSuccessMetrics = { [key: string]: unknown } | null; diff --git a/src/frontend/src/api/generated/model/boardGroupBoardSnapshot.ts b/src/frontend/src/api/generated/model/boardGroupBoardSnapshot.ts deleted file mode 100644 index d51e515..0000000 --- a/src/frontend/src/api/generated/model/boardGroupBoardSnapshot.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardGroupBoardSnapshotTaskCounts } from "./boardGroupBoardSnapshotTaskCounts"; -import type { BoardGroupTaskSummary } from "./boardGroupTaskSummary"; -import type { BoardRead } from "./boardRead"; - -/** - * Board-level rollup embedded within a board-group snapshot. - */ -export interface BoardGroupBoardSnapshot { - board: BoardRead; - task_counts?: BoardGroupBoardSnapshotTaskCounts; - tasks?: BoardGroupTaskSummary[]; -} diff --git a/src/frontend/src/api/generated/model/boardGroupBoardSnapshotTaskCounts.ts b/src/frontend/src/api/generated/model/boardGroupBoardSnapshotTaskCounts.ts deleted file mode 100644 index 4335b85..0000000 --- a/src/frontend/src/api/generated/model/boardGroupBoardSnapshotTaskCounts.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type BoardGroupBoardSnapshotTaskCounts = { [key: string]: number }; diff --git a/src/frontend/src/api/generated/model/boardGroupCreate.ts b/src/frontend/src/api/generated/model/boardGroupCreate.ts deleted file mode 100644 index bd7da98..0000000 --- a/src/frontend/src/api/generated/model/boardGroupCreate.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for creating a board group. - */ -export interface BoardGroupCreate { - description?: string | null; - name: string; - slug: string; -} diff --git a/src/frontend/src/api/generated/model/boardGroupHeartbeatApply.ts b/src/frontend/src/api/generated/model/boardGroupHeartbeatApply.ts deleted file mode 100644 index 70d15e6..0000000 --- a/src/frontend/src/api/generated/model/boardGroupHeartbeatApply.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Request payload for heartbeat policy updates. - */ -export interface BoardGroupHeartbeatApply { - every: string; - include_board_leads?: boolean; -} diff --git a/src/frontend/src/api/generated/model/boardGroupHeartbeatApplyResult.ts b/src/frontend/src/api/generated/model/boardGroupHeartbeatApplyResult.ts deleted file mode 100644 index d5bb950..0000000 --- a/src/frontend/src/api/generated/model/boardGroupHeartbeatApplyResult.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardGroupHeartbeatApplyResultRequested } from "./boardGroupHeartbeatApplyResultRequested"; - -/** - * Result payload describing agents updated by a heartbeat request. - */ -export interface BoardGroupHeartbeatApplyResult { - board_group_id: string; - failed_agent_ids: string[]; - requested: BoardGroupHeartbeatApplyResultRequested; - updated_agent_ids: string[]; -} diff --git a/src/frontend/src/api/generated/model/boardGroupHeartbeatApplyResultRequested.ts b/src/frontend/src/api/generated/model/boardGroupHeartbeatApplyResultRequested.ts deleted file mode 100644 index 05ec5c5..0000000 --- a/src/frontend/src/api/generated/model/boardGroupHeartbeatApplyResultRequested.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type BoardGroupHeartbeatApplyResultRequested = { - [key: string]: unknown; -}; diff --git a/src/frontend/src/api/generated/model/boardGroupMemoryCreate.ts b/src/frontend/src/api/generated/model/boardGroupMemoryCreate.ts deleted file mode 100644 index 92bac01..0000000 --- a/src/frontend/src/api/generated/model/boardGroupMemoryCreate.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for creating a board-group memory entry. - */ -export interface BoardGroupMemoryCreate { - /** @minLength 1 */ - content: string; - source?: string | null; - tags?: string[] | null; -} diff --git a/src/frontend/src/api/generated/model/boardGroupMemoryRead.ts b/src/frontend/src/api/generated/model/boardGroupMemoryRead.ts deleted file mode 100644 index 364d468..0000000 --- a/src/frontend/src/api/generated/model/boardGroupMemoryRead.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Serialized board-group memory entry returned from read endpoints. - */ -export interface BoardGroupMemoryRead { - board_group_id: string; - content: string; - created_at: string; - id: string; - is_chat?: boolean; - source?: string | null; - tags?: string[] | null; -} diff --git a/src/frontend/src/api/generated/model/boardGroupRead.ts b/src/frontend/src/api/generated/model/boardGroupRead.ts deleted file mode 100644 index 174c3cc..0000000 --- a/src/frontend/src/api/generated/model/boardGroupRead.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Board-group payload returned from read endpoints. - */ -export interface BoardGroupRead { - created_at: string; - description?: string | null; - id: string; - name: string; - organization_id: string; - slug: string; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/boardGroupSnapshot.ts b/src/frontend/src/api/generated/model/boardGroupSnapshot.ts deleted file mode 100644 index 7f6143d..0000000 --- a/src/frontend/src/api/generated/model/boardGroupSnapshot.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardGroupBoardSnapshot } from "./boardGroupBoardSnapshot"; -import type { BoardGroupRead } from "./boardGroupRead"; - -/** - * Top-level board-group snapshot response payload. - */ -export interface BoardGroupSnapshot { - boards?: BoardGroupBoardSnapshot[]; - group?: BoardGroupRead | null; -} diff --git a/src/frontend/src/api/generated/model/boardGroupTaskSummary.ts b/src/frontend/src/api/generated/model/boardGroupTaskSummary.ts deleted file mode 100644 index f71cb04..0000000 --- a/src/frontend/src/api/generated/model/boardGroupTaskSummary.ts +++ /dev/null @@ -1,26 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { TagRef } from "./tagRef"; - -/** - * Task summary row used inside board-group snapshot responses. - */ -export interface BoardGroupTaskSummary { - assigned_agent_id?: string | null; - assignee?: string | null; - board_id: string; - board_name: string; - created_at: string; - due_at?: string | null; - id: string; - in_progress_at?: string | null; - priority: string; - status: string; - tags?: TagRef[]; - title: string; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/boardGroupUpdate.ts b/src/frontend/src/api/generated/model/boardGroupUpdate.ts deleted file mode 100644 index b831890..0000000 --- a/src/frontend/src/api/generated/model/boardGroupUpdate.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for partial board-group updates. - */ -export interface BoardGroupUpdate { - description?: string | null; - name?: string | null; - slug?: string | null; -} diff --git a/src/frontend/src/api/generated/model/boardMemoryCreate.ts b/src/frontend/src/api/generated/model/boardMemoryCreate.ts deleted file mode 100644 index f2b1afb..0000000 --- a/src/frontend/src/api/generated/model/boardMemoryCreate.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for creating a board memory entry. - */ -export interface BoardMemoryCreate { - /** @minLength 1 */ - content: string; - source?: string | null; - tags?: string[] | null; -} diff --git a/src/frontend/src/api/generated/model/boardMemoryRead.ts b/src/frontend/src/api/generated/model/boardMemoryRead.ts deleted file mode 100644 index 805c493..0000000 --- a/src/frontend/src/api/generated/model/boardMemoryRead.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Serialized board memory entry returned from read endpoints. - */ -export interface BoardMemoryRead { - board_id: string; - content: string; - created_at: string; - id: string; - is_chat?: boolean; - source?: string | null; - tags?: string[] | null; -} diff --git a/src/frontend/src/api/generated/model/boardOnboardingAgentComplete.ts b/src/frontend/src/api/generated/model/boardOnboardingAgentComplete.ts deleted file mode 100644 index a2be93e..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingAgentComplete.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardOnboardingAgentCompleteSuccessMetrics } from "./boardOnboardingAgentCompleteSuccessMetrics"; -import type { BoardOnboardingLeadAgentDraft } from "./boardOnboardingLeadAgentDraft"; -import type { BoardOnboardingUserProfile } from "./boardOnboardingUserProfile"; - -/** - * Complete onboarding draft produced by the onboarding assistant. - */ -export interface BoardOnboardingAgentComplete { - board_type: string; - lead_agent?: BoardOnboardingLeadAgentDraft | null; - objective?: string | null; - status: "complete"; - success_metrics?: BoardOnboardingAgentCompleteSuccessMetrics; - target_date?: string | null; - user_profile?: BoardOnboardingUserProfile | null; -} diff --git a/src/frontend/src/api/generated/model/boardOnboardingAgentCompleteSuccessMetrics.ts b/src/frontend/src/api/generated/model/boardOnboardingAgentCompleteSuccessMetrics.ts deleted file mode 100644 index c98eb04..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingAgentCompleteSuccessMetrics.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type BoardOnboardingAgentCompleteSuccessMetrics = { - [key: string]: unknown; -} | null; diff --git a/src/frontend/src/api/generated/model/boardOnboardingAgentQuestion.ts b/src/frontend/src/api/generated/model/boardOnboardingAgentQuestion.ts deleted file mode 100644 index 2ca429e..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingAgentQuestion.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardOnboardingQuestionOption } from "./boardOnboardingQuestionOption"; - -/** - * Question payload emitted by the onboarding assistant. - */ -export interface BoardOnboardingAgentQuestion { - /** @minItems 1 */ - options: BoardOnboardingQuestionOption[]; - /** @minLength 1 */ - question: string; -} diff --git a/src/frontend/src/api/generated/model/boardOnboardingAnswer.ts b/src/frontend/src/api/generated/model/boardOnboardingAnswer.ts deleted file mode 100644 index 8b27ffe..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingAnswer.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * User answer payload for a single onboarding question. - */ -export interface BoardOnboardingAnswer { - /** @minLength 1 */ - answer: string; - other_text?: string | null; -} diff --git a/src/frontend/src/api/generated/model/boardOnboardingConfirm.ts b/src/frontend/src/api/generated/model/boardOnboardingConfirm.ts deleted file mode 100644 index acfc895..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingConfirm.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardOnboardingConfirmSuccessMetrics } from "./boardOnboardingConfirmSuccessMetrics"; - -/** - * Payload used to confirm generated onboarding draft fields. - */ -export interface BoardOnboardingConfirm { - board_type: string; - objective?: string | null; - success_metrics?: BoardOnboardingConfirmSuccessMetrics; - target_date?: string | null; -} diff --git a/src/frontend/src/api/generated/model/boardOnboardingConfirmSuccessMetrics.ts b/src/frontend/src/api/generated/model/boardOnboardingConfirmSuccessMetrics.ts deleted file mode 100644 index 3ba27e8..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingConfirmSuccessMetrics.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type BoardOnboardingConfirmSuccessMetrics = { - [key: string]: unknown; -} | null; diff --git a/src/frontend/src/api/generated/model/boardOnboardingLeadAgentDraft.ts b/src/frontend/src/api/generated/model/boardOnboardingLeadAgentDraft.ts deleted file mode 100644 index a1bf356..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingLeadAgentDraft.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardOnboardingLeadAgentDraftIdentityProfile } from "./boardOnboardingLeadAgentDraftIdentityProfile"; - -/** - * Editable lead-agent draft configuration. - */ -export interface BoardOnboardingLeadAgentDraft { - autonomy_level?: "ask_first" | "balanced" | "autonomous" | null; - custom_instructions?: string | null; - identity_profile?: BoardOnboardingLeadAgentDraftIdentityProfile; - name?: string | null; - output_format?: "bullets" | "mixed" | "narrative" | null; - update_cadence?: "asap" | "hourly" | "daily" | "weekly" | null; - verbosity?: "concise" | "balanced" | "detailed" | null; -} diff --git a/src/frontend/src/api/generated/model/boardOnboardingLeadAgentDraftIdentityProfile.ts b/src/frontend/src/api/generated/model/boardOnboardingLeadAgentDraftIdentityProfile.ts deleted file mode 100644 index 5c22918..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingLeadAgentDraftIdentityProfile.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type BoardOnboardingLeadAgentDraftIdentityProfile = { - [key: string]: string; -} | null; diff --git a/src/frontend/src/api/generated/model/boardOnboardingQuestionOption.ts b/src/frontend/src/api/generated/model/boardOnboardingQuestionOption.ts deleted file mode 100644 index 98837be..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingQuestionOption.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Selectable option for an onboarding question. - */ -export interface BoardOnboardingQuestionOption { - /** @minLength 1 */ - id: string; - /** @minLength 1 */ - label: string; -} diff --git a/src/frontend/src/api/generated/model/boardOnboardingRead.ts b/src/frontend/src/api/generated/model/boardOnboardingRead.ts deleted file mode 100644 index e93ae06..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingRead.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardOnboardingAgentComplete } from "./boardOnboardingAgentComplete"; -import type { BoardOnboardingReadMessages } from "./boardOnboardingReadMessages"; - -/** - * Stored onboarding session state returned by API endpoints. - */ -export interface BoardOnboardingRead { - board_id: string; - created_at: string; - draft_goal?: BoardOnboardingAgentComplete | null; - id: string; - messages?: BoardOnboardingReadMessages; - session_key: string; - status: string; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/boardOnboardingReadMessages.ts b/src/frontend/src/api/generated/model/boardOnboardingReadMessages.ts deleted file mode 100644 index 4826a26..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingReadMessages.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type BoardOnboardingReadMessages = { [key: string]: unknown }[] | null; diff --git a/src/frontend/src/api/generated/model/boardOnboardingStart.ts b/src/frontend/src/api/generated/model/boardOnboardingStart.ts deleted file mode 100644 index 2d2c79d..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingStart.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Start signal for initializing onboarding conversation. - */ -export interface BoardOnboardingStart { - [key: string]: unknown; -} diff --git a/src/frontend/src/api/generated/model/boardOnboardingUserProfile.ts b/src/frontend/src/api/generated/model/boardOnboardingUserProfile.ts deleted file mode 100644 index 8c933ac..0000000 --- a/src/frontend/src/api/generated/model/boardOnboardingUserProfile.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * User-profile preferences gathered during onboarding. - */ -export interface BoardOnboardingUserProfile { - context?: string | null; - notes?: string | null; - preferred_name?: string | null; - pronouns?: string | null; - timezone?: string | null; -} diff --git a/src/frontend/src/api/generated/model/boardRead.ts b/src/frontend/src/api/generated/model/boardRead.ts deleted file mode 100644 index 20dc585..0000000 --- a/src/frontend/src/api/generated/model/boardRead.ts +++ /dev/null @@ -1,35 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardReadSuccessMetrics } from "./boardReadSuccessMetrics"; - -/** - * Board payload returned from read endpoints. - */ -export interface BoardRead { - block_status_changes_with_pending_approval?: boolean; - board_group_id?: string | null; - board_type?: string; - comment_required_for_review?: boolean; - created_at: string; - description: string; - gateway_id?: string | null; - goal_confirmed?: boolean; - goal_source?: string | null; - id: string; - /** @minimum 0 */ - max_agents?: number; - name: string; - objective?: string | null; - only_lead_can_change_status?: boolean; - organization_id: string; - require_approval_for_done?: boolean; - require_review_before_done?: boolean; - slug: string; - success_metrics?: BoardReadSuccessMetrics; - target_date?: string | null; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/boardReadSuccessMetrics.ts b/src/frontend/src/api/generated/model/boardReadSuccessMetrics.ts deleted file mode 100644 index 85d9b3f..0000000 --- a/src/frontend/src/api/generated/model/boardReadSuccessMetrics.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type BoardReadSuccessMetrics = { [key: string]: unknown } | null; diff --git a/src/frontend/src/api/generated/model/boardSnapshot.ts b/src/frontend/src/api/generated/model/boardSnapshot.ts deleted file mode 100644 index a752821..0000000 --- a/src/frontend/src/api/generated/model/boardSnapshot.ts +++ /dev/null @@ -1,23 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { AgentRead } from "./agentRead"; -import type { ApprovalRead } from "./approvalRead"; -import type { BoardMemoryRead } from "./boardMemoryRead"; -import type { BoardRead } from "./boardRead"; -import type { TaskCardRead } from "./taskCardRead"; - -/** - * Aggregated board payload used by board snapshot endpoints. - */ -export interface BoardSnapshot { - agents: AgentRead[]; - approvals: ApprovalRead[]; - board: BoardRead; - chat_messages: BoardMemoryRead[]; - pending_approvals_count?: number; - tasks: TaskCardRead[]; -} diff --git a/src/frontend/src/api/generated/model/boardUpdate.ts b/src/frontend/src/api/generated/model/boardUpdate.ts deleted file mode 100644 index bb0a890..0000000 --- a/src/frontend/src/api/generated/model/boardUpdate.ts +++ /dev/null @@ -1,30 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardUpdateSuccessMetrics } from "./boardUpdateSuccessMetrics"; - -/** - * Payload for partial board updates. - */ -export interface BoardUpdate { - block_status_changes_with_pending_approval?: boolean | null; - board_group_id?: string | null; - board_type?: string | null; - comment_required_for_review?: boolean | null; - description?: string | null; - gateway_id?: string | null; - goal_confirmed?: boolean | null; - goal_source?: string | null; - max_agents?: number | null; - name?: string | null; - objective?: string | null; - only_lead_can_change_status?: boolean | null; - require_approval_for_done?: boolean | null; - require_review_before_done?: boolean | null; - slug?: string | null; - success_metrics?: BoardUpdateSuccessMetrics; - target_date?: string | null; -} diff --git a/src/frontend/src/api/generated/model/boardUpdateSuccessMetrics.ts b/src/frontend/src/api/generated/model/boardUpdateSuccessMetrics.ts deleted file mode 100644 index f105a04..0000000 --- a/src/frontend/src/api/generated/model/boardUpdateSuccessMetrics.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type BoardUpdateSuccessMetrics = { [key: string]: unknown } | null; diff --git a/src/frontend/src/api/generated/model/boardWebhookCreate.ts b/src/frontend/src/api/generated/model/boardWebhookCreate.ts deleted file mode 100644 index dea943c..0000000 --- a/src/frontend/src/api/generated/model/boardWebhookCreate.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for creating a board webhook. - */ -export interface BoardWebhookCreate { - agent_id?: string | null; - /** @minLength 1 */ - description: string; - enabled?: boolean; -} diff --git a/src/frontend/src/api/generated/model/boardWebhookIngestResponse.ts b/src/frontend/src/api/generated/model/boardWebhookIngestResponse.ts deleted file mode 100644 index 806dcb4..0000000 --- a/src/frontend/src/api/generated/model/boardWebhookIngestResponse.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Response payload for inbound webhook ingestion. - */ -export interface BoardWebhookIngestResponse { - board_id: string; - ok?: boolean; - payload_id: string; - webhook_id: string; -} diff --git a/src/frontend/src/api/generated/model/boardWebhookPayloadRead.ts b/src/frontend/src/api/generated/model/boardWebhookPayloadRead.ts deleted file mode 100644 index 846b388..0000000 --- a/src/frontend/src/api/generated/model/boardWebhookPayloadRead.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardWebhookPayloadReadHeaders } from "./boardWebhookPayloadReadHeaders"; -import type { BoardWebhookPayloadReadPayload } from "./boardWebhookPayloadReadPayload"; - -/** - * Serialized stored webhook payload. - */ -export interface BoardWebhookPayloadRead { - board_id: string; - content_type?: string | null; - headers?: BoardWebhookPayloadReadHeaders; - id: string; - payload?: BoardWebhookPayloadReadPayload; - received_at: string; - source_ip?: string | null; - webhook_id: string; -} diff --git a/src/frontend/src/api/generated/model/boardWebhookPayloadReadHeaders.ts b/src/frontend/src/api/generated/model/boardWebhookPayloadReadHeaders.ts deleted file mode 100644 index 5d2d2f6..0000000 --- a/src/frontend/src/api/generated/model/boardWebhookPayloadReadHeaders.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type BoardWebhookPayloadReadHeaders = { [key: string]: string } | null; diff --git a/src/frontend/src/api/generated/model/boardWebhookPayloadReadPayload.ts b/src/frontend/src/api/generated/model/boardWebhookPayloadReadPayload.ts deleted file mode 100644 index d4bea61..0000000 --- a/src/frontend/src/api/generated/model/boardWebhookPayloadReadPayload.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type BoardWebhookPayloadReadPayload = - | { [key: string]: unknown } - | unknown[] - | string - | number - | boolean - | null; diff --git a/src/frontend/src/api/generated/model/boardWebhookRead.ts b/src/frontend/src/api/generated/model/boardWebhookRead.ts deleted file mode 100644 index b817133..0000000 --- a/src/frontend/src/api/generated/model/boardWebhookRead.ts +++ /dev/null @@ -1,21 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Serialized board webhook configuration. - */ -export interface BoardWebhookRead { - agent_id?: string | null; - board_id: string; - created_at: string; - description: string; - enabled: boolean; - endpoint_path: string; - endpoint_url?: string | null; - id: string; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/boardWebhookUpdate.ts b/src/frontend/src/api/generated/model/boardWebhookUpdate.ts deleted file mode 100644 index 26356b5..0000000 --- a/src/frontend/src/api/generated/model/boardWebhookUpdate.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for updating a board webhook. - */ -export interface BoardWebhookUpdate { - agent_id?: string | null; - description?: string | null; - enabled?: boolean | null; -} diff --git a/src/frontend/src/api/generated/model/dashboardKpis.ts b/src/frontend/src/api/generated/model/dashboardKpis.ts deleted file mode 100644 index f0d8a05..0000000 --- a/src/frontend/src/api/generated/model/dashboardKpis.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Topline dashboard KPI summary values. - */ -export interface DashboardKpis { - active_agents: number; - done_tasks: number; - error_rate_pct: number; - in_progress_tasks: number; - inbox_tasks: number; - median_cycle_time_hours_7d: number | null; - review_tasks: number; - tasks_in_progress: number; -} diff --git a/src/frontend/src/api/generated/model/dashboardMetrics.ts b/src/frontend/src/api/generated/model/dashboardMetrics.ts deleted file mode 100644 index ce45783..0000000 --- a/src/frontend/src/api/generated/model/dashboardMetrics.ts +++ /dev/null @@ -1,25 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { DashboardKpis } from "./dashboardKpis"; -import type { DashboardMetricsRange } from "./dashboardMetricsRange"; -import type { DashboardPendingApprovals } from "./dashboardPendingApprovals"; -import type { DashboardSeriesSet } from "./dashboardSeriesSet"; -import type { DashboardWipSeriesSet } from "./dashboardWipSeriesSet"; - -/** - * Complete dashboard metrics response payload. - */ -export interface DashboardMetrics { - cycle_time: DashboardSeriesSet; - error_rate: DashboardSeriesSet; - generated_at: string; - kpis: DashboardKpis; - pending_approvals: DashboardPendingApprovals; - range: DashboardMetricsRange; - throughput: DashboardSeriesSet; - wip: DashboardWipSeriesSet; -} diff --git a/src/frontend/src/api/generated/model/dashboardMetricsApiV1MetricsDashboardGetParams.ts b/src/frontend/src/api/generated/model/dashboardMetricsApiV1MetricsDashboardGetParams.ts deleted file mode 100644 index bddc307..0000000 --- a/src/frontend/src/api/generated/model/dashboardMetricsApiV1MetricsDashboardGetParams.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { DashboardMetricsApiV1MetricsDashboardGetRangeKey } from "./dashboardMetricsApiV1MetricsDashboardGetRangeKey"; - -export type DashboardMetricsApiV1MetricsDashboardGetParams = { - range_key?: DashboardMetricsApiV1MetricsDashboardGetRangeKey; - board_id?: string | null; - group_id?: string | null; -}; diff --git a/src/frontend/src/api/generated/model/dashboardMetricsApiV1MetricsDashboardGetRangeKey.ts b/src/frontend/src/api/generated/model/dashboardMetricsApiV1MetricsDashboardGetRangeKey.ts deleted file mode 100644 index 5003f9e..0000000 --- a/src/frontend/src/api/generated/model/dashboardMetricsApiV1MetricsDashboardGetRangeKey.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type DashboardMetricsApiV1MetricsDashboardGetRangeKey = - (typeof DashboardMetricsApiV1MetricsDashboardGetRangeKey)[keyof typeof DashboardMetricsApiV1MetricsDashboardGetRangeKey]; - -export const DashboardMetricsApiV1MetricsDashboardGetRangeKey = { - "24h": "24h", - "3d": "3d", - "7d": "7d", - "14d": "14d", - "1m": "1m", - "3m": "3m", - "6m": "6m", - "1y": "1y", -} as const; diff --git a/src/frontend/src/api/generated/model/dashboardMetricsRange.ts b/src/frontend/src/api/generated/model/dashboardMetricsRange.ts deleted file mode 100644 index 0b7e523..0000000 --- a/src/frontend/src/api/generated/model/dashboardMetricsRange.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type DashboardMetricsRange = - (typeof DashboardMetricsRange)[keyof typeof DashboardMetricsRange]; - -export const DashboardMetricsRange = { - "24h": "24h", - "3d": "3d", - "7d": "7d", - "14d": "14d", - "1m": "1m", - "3m": "3m", - "6m": "6m", - "1y": "1y", -} as const; diff --git a/src/frontend/src/api/generated/model/dashboardPendingApproval.ts b/src/frontend/src/api/generated/model/dashboardPendingApproval.ts deleted file mode 100644 index 66fab8a..0000000 --- a/src/frontend/src/api/generated/model/dashboardPendingApproval.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Single pending approval item for cross-board dashboard listing. - */ -export interface DashboardPendingApproval { - action_type: string; - approval_id: string; - board_id: string; - board_name: string; - confidence: number; - created_at: string; - task_title?: string | null; -} diff --git a/src/frontend/src/api/generated/model/dashboardPendingApprovals.ts b/src/frontend/src/api/generated/model/dashboardPendingApprovals.ts deleted file mode 100644 index 26dbe84..0000000 --- a/src/frontend/src/api/generated/model/dashboardPendingApprovals.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { DashboardPendingApproval } from "./dashboardPendingApproval"; - -/** - * Pending approval snapshot used on the dashboard. - */ -export interface DashboardPendingApprovals { - items: DashboardPendingApproval[]; - total: number; -} diff --git a/src/frontend/src/api/generated/model/dashboardRangeSeries.ts b/src/frontend/src/api/generated/model/dashboardRangeSeries.ts deleted file mode 100644 index f996bcf..0000000 --- a/src/frontend/src/api/generated/model/dashboardRangeSeries.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { DashboardRangeSeriesBucket } from "./dashboardRangeSeriesBucket"; -import type { DashboardRangeSeriesRange } from "./dashboardRangeSeriesRange"; -import type { DashboardSeriesPoint } from "./dashboardSeriesPoint"; - -/** - * Series payload for a single range/bucket combination. - */ -export interface DashboardRangeSeries { - bucket: DashboardRangeSeriesBucket; - points: DashboardSeriesPoint[]; - range: DashboardRangeSeriesRange; -} diff --git a/src/frontend/src/api/generated/model/dashboardRangeSeriesBucket.ts b/src/frontend/src/api/generated/model/dashboardRangeSeriesBucket.ts deleted file mode 100644 index 386ecaa..0000000 --- a/src/frontend/src/api/generated/model/dashboardRangeSeriesBucket.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type DashboardRangeSeriesBucket = - (typeof DashboardRangeSeriesBucket)[keyof typeof DashboardRangeSeriesBucket]; - -export const DashboardRangeSeriesBucket = { - hour: "hour", - day: "day", - week: "week", - month: "month", -} as const; diff --git a/src/frontend/src/api/generated/model/dashboardRangeSeriesRange.ts b/src/frontend/src/api/generated/model/dashboardRangeSeriesRange.ts deleted file mode 100644 index 157dfdb..0000000 --- a/src/frontend/src/api/generated/model/dashboardRangeSeriesRange.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type DashboardRangeSeriesRange = - (typeof DashboardRangeSeriesRange)[keyof typeof DashboardRangeSeriesRange]; - -export const DashboardRangeSeriesRange = { - "24h": "24h", - "3d": "3d", - "7d": "7d", - "14d": "14d", - "1m": "1m", - "3m": "3m", - "6m": "6m", - "1y": "1y", -} as const; diff --git a/src/frontend/src/api/generated/model/dashboardSeriesPoint.ts b/src/frontend/src/api/generated/model/dashboardSeriesPoint.ts deleted file mode 100644 index f5d68e4..0000000 --- a/src/frontend/src/api/generated/model/dashboardSeriesPoint.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Single numeric time-series point. - */ -export interface DashboardSeriesPoint { - period: string; - value: number; -} diff --git a/src/frontend/src/api/generated/model/dashboardSeriesSet.ts b/src/frontend/src/api/generated/model/dashboardSeriesSet.ts deleted file mode 100644 index 086f415..0000000 --- a/src/frontend/src/api/generated/model/dashboardSeriesSet.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { DashboardRangeSeries } from "./dashboardRangeSeries"; - -/** - * Primary vs comparison pair for generic series metrics. - */ -export interface DashboardSeriesSet { - comparison: DashboardRangeSeries; - primary: DashboardRangeSeries; -} diff --git a/src/frontend/src/api/generated/model/dashboardWipPoint.ts b/src/frontend/src/api/generated/model/dashboardWipPoint.ts deleted file mode 100644 index 7390dee..0000000 --- a/src/frontend/src/api/generated/model/dashboardWipPoint.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Work-in-progress point split by task status buckets. - */ -export interface DashboardWipPoint { - done: number; - in_progress: number; - inbox: number; - period: string; - review: number; -} diff --git a/src/frontend/src/api/generated/model/dashboardWipRangeSeries.ts b/src/frontend/src/api/generated/model/dashboardWipRangeSeries.ts deleted file mode 100644 index e439b04..0000000 --- a/src/frontend/src/api/generated/model/dashboardWipRangeSeries.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { DashboardWipPoint } from "./dashboardWipPoint"; -import type { DashboardWipRangeSeriesBucket } from "./dashboardWipRangeSeriesBucket"; -import type { DashboardWipRangeSeriesRange } from "./dashboardWipRangeSeriesRange"; - -/** - * WIP series payload for a single range/bucket combination. - */ -export interface DashboardWipRangeSeries { - bucket: DashboardWipRangeSeriesBucket; - points: DashboardWipPoint[]; - range: DashboardWipRangeSeriesRange; -} diff --git a/src/frontend/src/api/generated/model/dashboardWipRangeSeriesBucket.ts b/src/frontend/src/api/generated/model/dashboardWipRangeSeriesBucket.ts deleted file mode 100644 index 8566229..0000000 --- a/src/frontend/src/api/generated/model/dashboardWipRangeSeriesBucket.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type DashboardWipRangeSeriesBucket = - (typeof DashboardWipRangeSeriesBucket)[keyof typeof DashboardWipRangeSeriesBucket]; - -export const DashboardWipRangeSeriesBucket = { - hour: "hour", - day: "day", - week: "week", - month: "month", -} as const; diff --git a/src/frontend/src/api/generated/model/dashboardWipRangeSeriesRange.ts b/src/frontend/src/api/generated/model/dashboardWipRangeSeriesRange.ts deleted file mode 100644 index 09b4ad6..0000000 --- a/src/frontend/src/api/generated/model/dashboardWipRangeSeriesRange.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type DashboardWipRangeSeriesRange = - (typeof DashboardWipRangeSeriesRange)[keyof typeof DashboardWipRangeSeriesRange]; - -export const DashboardWipRangeSeriesRange = { - "24h": "24h", - "3d": "3d", - "7d": "7d", - "14d": "14d", - "1m": "1m", - "3m": "3m", - "6m": "6m", - "1y": "1y", -} as const; diff --git a/src/frontend/src/api/generated/model/dashboardWipSeriesSet.ts b/src/frontend/src/api/generated/model/dashboardWipSeriesSet.ts deleted file mode 100644 index f2f9e9c..0000000 --- a/src/frontend/src/api/generated/model/dashboardWipSeriesSet.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { DashboardWipRangeSeries } from "./dashboardWipRangeSeries"; - -/** - * Primary vs comparison pair for WIP status series metrics. - */ -export interface DashboardWipSeriesSet { - comparison: DashboardWipRangeSeries; - primary: DashboardWipRangeSeries; -} diff --git a/src/frontend/src/api/generated/model/gatewayCommandsResponse.ts b/src/frontend/src/api/generated/model/gatewayCommandsResponse.ts deleted file mode 100644 index d763c03..0000000 --- a/src/frontend/src/api/generated/model/gatewayCommandsResponse.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Gateway command catalog and protocol metadata. - */ -export interface GatewayCommandsResponse { - events: string[]; - methods: string[]; - protocol_version: number; -} diff --git a/src/frontend/src/api/generated/model/gatewayCreate.ts b/src/frontend/src/api/generated/model/gatewayCreate.ts deleted file mode 100644 index ee4ea5d..0000000 --- a/src/frontend/src/api/generated/model/gatewayCreate.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for creating a gateway configuration. - */ -export interface GatewayCreate { - allow_insecure_tls?: boolean; - disable_device_pairing?: boolean; - name: string; - token?: string | null; - url: string; - workspace_root: string; -} diff --git a/src/frontend/src/api/generated/model/gatewayLeadBroadcastBoardResult.ts b/src/frontend/src/api/generated/model/gatewayLeadBroadcastBoardResult.ts deleted file mode 100644 index e490d3f..0000000 --- a/src/frontend/src/api/generated/model/gatewayLeadBroadcastBoardResult.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Per-board result entry for a lead broadcast operation. - */ -export interface GatewayLeadBroadcastBoardResult { - /** Target board id for this result. */ - board_id: string; - /** Failure reason if this board failed. */ - error?: string | null; - /** Resolved lead agent id for the target board. */ - lead_agent_id?: string | null; - /** Resolved lead agent display name. */ - lead_agent_name?: string | null; - /** Whether this board delivery succeeded. */ - ok?: boolean; -} diff --git a/src/frontend/src/api/generated/model/gatewayLeadBroadcastRequest.ts b/src/frontend/src/api/generated/model/gatewayLeadBroadcastRequest.ts deleted file mode 100644 index e4d78dd..0000000 --- a/src/frontend/src/api/generated/model/gatewayLeadBroadcastRequest.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { GatewayLeadBroadcastRequestKind } from "./gatewayLeadBroadcastRequestKind"; - -/** - * Request payload for broadcasting a message to multiple board leads. - */ -export interface GatewayLeadBroadcastRequest { - /** Optional explicit list of board IDs; omit for lead-scoped defaults. */ - board_ids?: string[] | null; - /** - * Message content distributed to selected board leads. - * @minLength 1 - */ - content: string; - /** Optional correlation token shared with downstream handlers. */ - correlation_id?: string | null; - /** Broadcast intent. `question` asks for responses; `handoff` requests transfer. */ - kind?: GatewayLeadBroadcastRequestKind; - /** Reply destination key for broadcast responses. */ - reply_source?: string | null; - /** Tags required by reply templates when each lead responds. */ - reply_tags?: string[]; -} diff --git a/src/frontend/src/api/generated/model/gatewayLeadBroadcastRequestKind.ts b/src/frontend/src/api/generated/model/gatewayLeadBroadcastRequestKind.ts deleted file mode 100644 index 99e50b8..0000000 --- a/src/frontend/src/api/generated/model/gatewayLeadBroadcastRequestKind.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Broadcast intent. `question` asks for responses; `handoff` requests transfer. - */ -export type GatewayLeadBroadcastRequestKind = - (typeof GatewayLeadBroadcastRequestKind)[keyof typeof GatewayLeadBroadcastRequestKind]; - -export const GatewayLeadBroadcastRequestKind = { - question: "question", - handoff: "handoff", -} as const; diff --git a/src/frontend/src/api/generated/model/gatewayLeadBroadcastResponse.ts b/src/frontend/src/api/generated/model/gatewayLeadBroadcastResponse.ts deleted file mode 100644 index 36b905c..0000000 --- a/src/frontend/src/api/generated/model/gatewayLeadBroadcastResponse.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { GatewayLeadBroadcastBoardResult } from "./gatewayLeadBroadcastBoardResult"; - -/** - * Aggregate response for a lead broadcast operation. - */ -export interface GatewayLeadBroadcastResponse { - /** Number of boards that failed messaging. */ - failed?: number; - /** Whether broadcast execution succeeded. */ - ok?: boolean; - results?: GatewayLeadBroadcastBoardResult[]; - /** Number of boards successfully messaged. */ - sent?: number; -} diff --git a/src/frontend/src/api/generated/model/gatewayLeadMessageRequest.ts b/src/frontend/src/api/generated/model/gatewayLeadMessageRequest.ts deleted file mode 100644 index 0f8e150..0000000 --- a/src/frontend/src/api/generated/model/gatewayLeadMessageRequest.ts +++ /dev/null @@ -1,26 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { GatewayLeadMessageRequestKind } from "./gatewayLeadMessageRequestKind"; - -/** - * Request payload for sending a message to a board lead agent. - */ -export interface GatewayLeadMessageRequest { - /** - * Human-readable body sent to lead agents. - * @minLength 1 - */ - content: string; - /** Optional correlation token shared across upstream and downstream systems. */ - correlation_id?: string | null; - /** Routing mode for lead messages. */ - kind?: GatewayLeadMessageRequestKind; - /** Reply destination key for the orchestrator. */ - reply_source?: string | null; - /** Tags required by reply templates when the lead responds. */ - reply_tags?: string[]; -} diff --git a/src/frontend/src/api/generated/model/gatewayLeadMessageRequestKind.ts b/src/frontend/src/api/generated/model/gatewayLeadMessageRequestKind.ts deleted file mode 100644 index 0892984..0000000 --- a/src/frontend/src/api/generated/model/gatewayLeadMessageRequestKind.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Routing mode for lead messages. - */ -export type GatewayLeadMessageRequestKind = - (typeof GatewayLeadMessageRequestKind)[keyof typeof GatewayLeadMessageRequestKind]; - -export const GatewayLeadMessageRequestKind = { - question: "question", - handoff: "handoff", -} as const; diff --git a/src/frontend/src/api/generated/model/gatewayLeadMessageResponse.ts b/src/frontend/src/api/generated/model/gatewayLeadMessageResponse.ts deleted file mode 100644 index a4d3570..0000000 --- a/src/frontend/src/api/generated/model/gatewayLeadMessageResponse.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Response payload for a lead-message dispatch attempt. - */ -export interface GatewayLeadMessageResponse { - /** Board receiving the message. */ - board_id: string; - /** Resolved lead agent id when present. */ - lead_agent_id?: string | null; - /** Resolved lead agent display name. */ - lead_agent_name?: string | null; - /** Whether a lead fallback actor was created during routing. */ - lead_created?: boolean; - /** Whether dispatch was accepted. */ - ok?: boolean; -} diff --git a/src/frontend/src/api/generated/model/gatewayMainAskUserRequest.ts b/src/frontend/src/api/generated/model/gatewayMainAskUserRequest.ts deleted file mode 100644 index 10d58c3..0000000 --- a/src/frontend/src/api/generated/model/gatewayMainAskUserRequest.ts +++ /dev/null @@ -1,25 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Request payload for asking the end user via a main gateway agent. - */ -export interface GatewayMainAskUserRequest { - /** - * Prompt that should be asked to the human. - * @minLength 1 - */ - content: string; - /** Optional correlation token for tracing request/response flow. */ - correlation_id?: string | null; - /** Optional preferred messaging channel. */ - preferred_channel?: string | null; - /** Reply destination key for user confirmation loops. */ - reply_source?: string | null; - /** Tags required for routing the user response. */ - reply_tags?: string[]; -} diff --git a/src/frontend/src/api/generated/model/gatewayMainAskUserResponse.ts b/src/frontend/src/api/generated/model/gatewayMainAskUserResponse.ts deleted file mode 100644 index 599081b..0000000 --- a/src/frontend/src/api/generated/model/gatewayMainAskUserResponse.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Response payload for user-question dispatch via gateway main agent. - */ -export interface GatewayMainAskUserResponse { - /** Board context used for the request. */ - board_id: string; - /** Resolved main agent id handling the ask. */ - main_agent_id?: string | null; - /** Resolved main agent display name. */ - main_agent_name?: string | null; - /** Whether ask-user dispatch was accepted. */ - ok?: boolean; -} diff --git a/src/frontend/src/api/generated/model/gatewayRead.ts b/src/frontend/src/api/generated/model/gatewayRead.ts deleted file mode 100644 index def4911..0000000 --- a/src/frontend/src/api/generated/model/gatewayRead.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Gateway payload returned from read endpoints. - */ -export interface GatewayRead { - allow_insecure_tls?: boolean; - created_at: string; - disable_device_pairing?: boolean; - id: string; - name: string; - organization_id: string; - token?: string | null; - updated_at: string; - url: string; - workspace_root: string; -} diff --git a/src/frontend/src/api/generated/model/gatewaySessionHistoryResponse.ts b/src/frontend/src/api/generated/model/gatewaySessionHistoryResponse.ts deleted file mode 100644 index d061447..0000000 --- a/src/frontend/src/api/generated/model/gatewaySessionHistoryResponse.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Gateway session history response payload. - */ -export interface GatewaySessionHistoryResponse { - history: unknown[]; -} diff --git a/src/frontend/src/api/generated/model/gatewaySessionMessageRequest.ts b/src/frontend/src/api/generated/model/gatewaySessionMessageRequest.ts deleted file mode 100644 index 5a70ed5..0000000 --- a/src/frontend/src/api/generated/model/gatewaySessionMessageRequest.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Request payload for sending a message into a gateway session. - */ -export interface GatewaySessionMessageRequest { - /** @minLength 1 */ - content: string; -} diff --git a/src/frontend/src/api/generated/model/gatewaySessionResponse.ts b/src/frontend/src/api/generated/model/gatewaySessionResponse.ts deleted file mode 100644 index 609cd75..0000000 --- a/src/frontend/src/api/generated/model/gatewaySessionResponse.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Single gateway session response payload. - */ -export interface GatewaySessionResponse { - session: unknown; -} diff --git a/src/frontend/src/api/generated/model/gatewaySessionsResponse.ts b/src/frontend/src/api/generated/model/gatewaySessionsResponse.ts deleted file mode 100644 index 8cf60e1..0000000 --- a/src/frontend/src/api/generated/model/gatewaySessionsResponse.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Gateway sessions list response payload. - */ -export interface GatewaySessionsResponse { - main_session?: unknown | null; - sessions: unknown[]; -} diff --git a/src/frontend/src/api/generated/model/gatewayTemplatesSyncError.ts b/src/frontend/src/api/generated/model/gatewayTemplatesSyncError.ts deleted file mode 100644 index bdc6205..0000000 --- a/src/frontend/src/api/generated/model/gatewayTemplatesSyncError.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Per-agent error entry from a gateway template sync operation. - */ -export interface GatewayTemplatesSyncError { - agent_id?: string | null; - agent_name?: string | null; - board_id?: string | null; - message: string; -} diff --git a/src/frontend/src/api/generated/model/gatewayTemplatesSyncResult.ts b/src/frontend/src/api/generated/model/gatewayTemplatesSyncResult.ts deleted file mode 100644 index f6e19d8..0000000 --- a/src/frontend/src/api/generated/model/gatewayTemplatesSyncResult.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { GatewayTemplatesSyncError } from "./gatewayTemplatesSyncError"; - -/** - * Summary payload returned by gateway template sync endpoints. - */ -export interface GatewayTemplatesSyncResult { - agents_skipped: number; - agents_updated: number; - errors?: GatewayTemplatesSyncError[]; - gateway_id: string; - include_main: boolean; - main_updated: boolean; - reset_sessions: boolean; -} diff --git a/src/frontend/src/api/generated/model/gatewayUpdate.ts b/src/frontend/src/api/generated/model/gatewayUpdate.ts deleted file mode 100644 index e284f97..0000000 --- a/src/frontend/src/api/generated/model/gatewayUpdate.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for partial gateway updates. - */ -export interface GatewayUpdate { - allow_insecure_tls?: boolean | null; - disable_device_pairing?: boolean | null; - name?: string | null; - token?: string | null; - url?: string | null; - workspace_root?: string | null; -} diff --git a/src/frontend/src/api/generated/model/gatewaysStatusApiV1GatewaysStatusGetParams.ts b/src/frontend/src/api/generated/model/gatewaysStatusApiV1GatewaysStatusGetParams.ts deleted file mode 100644 index e26eefc..0000000 --- a/src/frontend/src/api/generated/model/gatewaysStatusApiV1GatewaysStatusGetParams.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type GatewaysStatusApiV1GatewaysStatusGetParams = { - board_id?: string | null; - gateway_url?: string | null; - gateway_token?: string | null; - gateway_disable_device_pairing?: boolean | null; - gateway_allow_insecure_tls?: boolean | null; -}; diff --git a/src/frontend/src/api/generated/model/gatewaysStatusResponse.ts b/src/frontend/src/api/generated/model/gatewaysStatusResponse.ts deleted file mode 100644 index cea5a7a..0000000 --- a/src/frontend/src/api/generated/model/gatewaysStatusResponse.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Aggregated gateway status response including session metadata. - */ -export interface GatewaysStatusResponse { - connected: boolean; - error?: string | null; - gateway_url: string; - main_session?: unknown | null; - main_session_error?: string | null; - sessions?: unknown[] | null; - sessions_count?: number | null; -} diff --git a/src/frontend/src/api/generated/model/getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams.ts b/src/frontend/src/api/generated/model/getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams.ts deleted file mode 100644 index ee5aaf2..0000000 --- a/src/frontend/src/api/generated/model/getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type GetBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams = { - include_done?: boolean; - per_board_task_limit?: number; -}; diff --git a/src/frontend/src/api/generated/model/getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams.ts b/src/frontend/src/api/generated/model/getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams.ts deleted file mode 100644 index 4c1838b..0000000 --- a/src/frontend/src/api/generated/model/getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type GetBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams = { - include_self?: boolean; - include_done?: boolean; - /** - * @minimum 0 - * @maximum 100 - */ - per_board_task_limit?: number; -}; diff --git a/src/frontend/src/api/generated/model/getGatewaySessionApiV1GatewaysSessionsSessionIdGetParams.ts b/src/frontend/src/api/generated/model/getGatewaySessionApiV1GatewaysSessionsSessionIdGetParams.ts deleted file mode 100644 index 24dbb3e..0000000 --- a/src/frontend/src/api/generated/model/getGatewaySessionApiV1GatewaysSessionsSessionIdGetParams.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type GetGatewaySessionApiV1GatewaysSessionsSessionIdGetParams = { - board_id?: string | null; -}; diff --git a/src/frontend/src/api/generated/model/getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams.ts b/src/frontend/src/api/generated/model/getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams.ts deleted file mode 100644 index 5ff290a..0000000 --- a/src/frontend/src/api/generated/model/getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type GetSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams = { - board_id?: string | null; -}; diff --git a/src/frontend/src/api/generated/model/hTTPValidationError.ts b/src/frontend/src/api/generated/model/hTTPValidationError.ts deleted file mode 100644 index 8edc359..0000000 --- a/src/frontend/src/api/generated/model/hTTPValidationError.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { ValidationError } from "./validationError"; - -export interface HTTPValidationError { - detail?: ValidationError[]; -} diff --git a/src/frontend/src/api/generated/model/healthHealthGet200.ts b/src/frontend/src/api/generated/model/healthHealthGet200.ts deleted file mode 100644 index 3bdea59..0000000 --- a/src/frontend/src/api/generated/model/healthHealthGet200.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type HealthHealthGet200 = { [key: string]: boolean }; diff --git a/src/frontend/src/api/generated/model/healthStatusResponse.ts b/src/frontend/src/api/generated/model/healthStatusResponse.ts deleted file mode 100644 index 77f20e0..0000000 --- a/src/frontend/src/api/generated/model/healthStatusResponse.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Standard payload for service liveness/readiness checks. - */ -export interface HealthStatusResponse { - /** Indicates whether the probe check succeeded. */ - ok: boolean; -} diff --git a/src/frontend/src/api/generated/model/healthzHealthzGet200.ts b/src/frontend/src/api/generated/model/healthzHealthzGet200.ts deleted file mode 100644 index 0a81465..0000000 --- a/src/frontend/src/api/generated/model/healthzHealthzGet200.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type HealthzHealthzGet200 = { [key: string]: boolean }; diff --git a/src/frontend/src/api/generated/model/index.ts b/src/frontend/src/api/generated/model/index.ts deleted file mode 100644 index 437fc1e..0000000 --- a/src/frontend/src/api/generated/model/index.ts +++ /dev/null @@ -1,235 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export * from "./activityEventRead"; -export * from "./activityEventReadRouteParams"; -export * from "./activityTaskCommentFeedItemRead"; -export * from "./agentCreate"; -export * from "./agentCreateHeartbeatConfig"; -export * from "./agentCreateIdentityProfile"; -export * from "./agentHealthStatusResponse"; -export * from "./agentHeartbeat"; -export * from "./agentHeartbeatCreate"; -export * from "./agentNudge"; -export * from "./agentRead"; -export * from "./agentReadHeartbeatConfig"; -export * from "./agentReadIdentityProfile"; -export * from "./agentUpdate"; -export * from "./agentUpdateHeartbeatConfig"; -export * from "./agentUpdateIdentityProfile"; -export * from "./approvalCreate"; -export * from "./approvalCreatePayload"; -export * from "./approvalCreateRubricScores"; -export * from "./approvalCreateStatus"; -export * from "./approvalRead"; -export * from "./approvalReadPayload"; -export * from "./approvalReadRubricScores"; -export * from "./approvalReadStatus"; -export * from "./approvalUpdate"; -export * from "./blockedTaskDetail"; -export * from "./blockedTaskError"; -export * from "./boardCreate"; -export * from "./boardCreateSuccessMetrics"; -export * from "./boardGroupBoardSnapshot"; -export * from "./boardGroupBoardSnapshotTaskCounts"; -export * from "./boardGroupCreate"; -export * from "./boardGroupHeartbeatApply"; -export * from "./boardGroupHeartbeatApplyResult"; -export * from "./boardGroupHeartbeatApplyResultRequested"; -export * from "./boardGroupMemoryCreate"; -export * from "./boardGroupMemoryRead"; -export * from "./boardGroupRead"; -export * from "./boardGroupSnapshot"; -export * from "./boardGroupTaskSummary"; -export * from "./boardGroupUpdate"; -export * from "./boardMemoryCreate"; -export * from "./boardMemoryRead"; -export * from "./boardOnboardingAgentComplete"; -export * from "./boardOnboardingAgentCompleteSuccessMetrics"; -export * from "./boardOnboardingAgentQuestion"; -export * from "./boardOnboardingAnswer"; -export * from "./boardOnboardingConfirm"; -export * from "./boardOnboardingConfirmSuccessMetrics"; -export * from "./boardOnboardingLeadAgentDraft"; -export * from "./boardOnboardingLeadAgentDraftIdentityProfile"; -export * from "./boardOnboardingQuestionOption"; -export * from "./boardOnboardingRead"; -export * from "./boardOnboardingReadMessages"; -export * from "./boardOnboardingStart"; -export * from "./boardOnboardingUserProfile"; -export * from "./boardRead"; -export * from "./boardReadSuccessMetrics"; -export * from "./boardSnapshot"; -export * from "./boardUpdate"; -export * from "./boardUpdateSuccessMetrics"; -export * from "./boardWebhookCreate"; -export * from "./boardWebhookIngestResponse"; -export * from "./boardWebhookPayloadRead"; -export * from "./boardWebhookPayloadReadHeaders"; -export * from "./boardWebhookPayloadReadPayload"; -export * from "./boardWebhookRead"; -export * from "./boardWebhookUpdate"; -export * from "./dashboardKpis"; -export * from "./dashboardMetrics"; -export * from "./dashboardMetricsApiV1MetricsDashboardGetParams"; -export * from "./dashboardMetricsApiV1MetricsDashboardGetRangeKey"; -export * from "./dashboardMetricsRange"; -export * from "./dashboardPendingApproval"; -export * from "./dashboardPendingApprovals"; -export * from "./dashboardRangeSeries"; -export * from "./dashboardRangeSeriesBucket"; -export * from "./dashboardRangeSeriesRange"; -export * from "./dashboardSeriesPoint"; -export * from "./dashboardSeriesSet"; -export * from "./dashboardWipPoint"; -export * from "./dashboardWipRangeSeries"; -export * from "./dashboardWipRangeSeriesBucket"; -export * from "./dashboardWipRangeSeriesRange"; -export * from "./dashboardWipSeriesSet"; -export * from "./gatewayCommandsResponse"; -export * from "./gatewayCreate"; -export * from "./gatewayLeadBroadcastBoardResult"; -export * from "./gatewayLeadBroadcastRequest"; -export * from "./gatewayLeadBroadcastRequestKind"; -export * from "./gatewayLeadBroadcastResponse"; -export * from "./gatewayLeadMessageRequest"; -export * from "./gatewayLeadMessageRequestKind"; -export * from "./gatewayLeadMessageResponse"; -export * from "./gatewayMainAskUserRequest"; -export * from "./gatewayMainAskUserResponse"; -export * from "./gatewayRead"; -export * from "./gatewaySessionHistoryResponse"; -export * from "./gatewaySessionMessageRequest"; -export * from "./gatewaySessionResponse"; -export * from "./gatewaySessionsResponse"; -export * from "./gatewaysStatusApiV1GatewaysStatusGetParams"; -export * from "./gatewaysStatusResponse"; -export * from "./gatewayTemplatesSyncError"; -export * from "./gatewayTemplatesSyncResult"; -export * from "./gatewayUpdate"; -export * from "./getBoardGroupSnapshotApiV1BoardGroupsGroupIdSnapshotGetParams"; -export * from "./getBoardGroupSnapshotApiV1BoardsBoardIdGroupSnapshotGetParams"; -export * from "./getGatewaySessionApiV1GatewaysSessionsSessionIdGetParams"; -export * from "./getSessionHistoryApiV1GatewaysSessionsSessionIdHistoryGetParams"; -export * from "./healthHealthGet200"; -export * from "./healthStatusResponse"; -export * from "./healthzHealthzGet200"; -export * from "./hTTPValidationError"; -export * from "./installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams"; -export * from "./limitOffsetPageTypeVarCustomizedActivityEventRead"; -export * from "./limitOffsetPageTypeVarCustomizedActivityTaskCommentFeedItemRead"; -export * from "./limitOffsetPageTypeVarCustomizedAgentRead"; -export * from "./limitOffsetPageTypeVarCustomizedApprovalRead"; -export * from "./limitOffsetPageTypeVarCustomizedBoardGroupMemoryRead"; -export * from "./limitOffsetPageTypeVarCustomizedBoardGroupRead"; -export * from "./limitOffsetPageTypeVarCustomizedBoardMemoryRead"; -export * from "./limitOffsetPageTypeVarCustomizedBoardRead"; -export * from "./limitOffsetPageTypeVarCustomizedBoardWebhookPayloadRead"; -export * from "./limitOffsetPageTypeVarCustomizedBoardWebhookRead"; -export * from "./limitOffsetPageTypeVarCustomizedGatewayRead"; -export * from "./limitOffsetPageTypeVarCustomizedOrganizationInviteRead"; -export * from "./limitOffsetPageTypeVarCustomizedOrganizationMemberRead"; -export * from "./limitOffsetPageTypeVarCustomizedTagRead"; -export * from "./limitOffsetPageTypeVarCustomizedTaskCommentRead"; -export * from "./limitOffsetPageTypeVarCustomizedTaskRead"; -export * from "./listActivityApiV1ActivityGetParams"; -export * from "./listAgentsApiV1AgentAgentsGetParams"; -export * from "./listAgentsApiV1AgentsGetParams"; -export * from "./listApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams"; -export * from "./listApprovalsApiV1BoardsBoardIdApprovalsGetParams"; -export * from "./listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams"; -export * from "./listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams"; -export * from "./listBoardGroupsApiV1BoardGroupsGetParams"; -export * from "./listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams"; -export * from "./listBoardMemoryApiV1BoardsBoardIdMemoryGetParams"; -export * from "./listBoardsApiV1AgentBoardsGetParams"; -export * from "./listBoardsApiV1BoardsGetParams"; -export * from "./listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams"; -export * from "./listBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams"; -export * from "./listGatewaysApiV1GatewaysGetParams"; -export * from "./listGatewaySessionsApiV1GatewaysSessionsGetParams"; -export * from "./listMarketplaceSkillsApiV1SkillsMarketplaceGetParams"; -export * from "./listOrgInvitesApiV1OrganizationsMeInvitesGetParams"; -export * from "./listOrgMembersApiV1OrganizationsMeMembersGetParams"; -export * from "./listTagsApiV1TagsGetParams"; -export * from "./listTaskCommentFeedApiV1ActivityTaskCommentsGetParams"; -export * from "./listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams"; -export * from "./listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams"; -export * from "./listTasksApiV1AgentBoardsBoardIdTasksGetParams"; -export * from "./listTasksApiV1BoardsBoardIdTasksGetParams"; -export * from "./lLMErrorResponse"; -export * from "./lLMErrorResponseDetail"; -export * from "./marketplaceSkillActionResponse"; -export * from "./marketplaceSkillCardRead"; -export * from "./marketplaceSkillCardReadMetadata"; -export * from "./marketplaceSkillCreate"; -export * from "./marketplaceSkillRead"; -export * from "./marketplaceSkillReadMetadata"; -export * from "./okResponse"; -export * from "./organizationActiveUpdate"; -export * from "./organizationBoardAccessRead"; -export * from "./organizationBoardAccessSpec"; -export * from "./organizationCreate"; -export * from "./organizationInviteAccept"; -export * from "./organizationInviteCreate"; -export * from "./organizationInviteRead"; -export * from "./organizationListItem"; -export * from "./organizationMemberAccessUpdate"; -export * from "./organizationMemberRead"; -export * from "./organizationMemberUpdate"; -export * from "./organizationRead"; -export * from "./organizationUserRead"; -export * from "./readyzReadyzGet200"; -export * from "./searchApiV1SoulsDirectorySearchGetParams"; -export * from "./sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams"; -export * from "./skillPackCreate"; -export * from "./skillPackCreateMetadata"; -export * from "./skillPackRead"; -export * from "./skillPackReadMetadata"; -export * from "./skillPackSyncResponse"; -export * from "./soulsDirectoryMarkdownResponse"; -export * from "./soulsDirectorySearchResponse"; -export * from "./soulsDirectorySoulRef"; -export * from "./soulUpdateRequest"; -export * from "./streamAgentsApiV1AgentsStreamGetParams"; -export * from "./streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams"; -export * from "./streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams"; -export * from "./streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams"; -export * from "./streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams"; -export * from "./streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams"; -export * from "./streamTasksApiV1BoardsBoardIdTasksStreamGetParams"; -export * from "./syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams"; -export * from "./tagCreate"; -export * from "./tagRead"; -export * from "./tagRef"; -export * from "./tagUpdate"; -export * from "./taskCardRead"; -export * from "./taskCardReadCustomFieldValues"; -export * from "./taskCardReadStatus"; -export * from "./taskCommentCreate"; -export * from "./taskCommentRead"; -export * from "./taskCreate"; -export * from "./taskCreateCustomFieldValues"; -export * from "./taskCreateStatus"; -export * from "./taskCustomFieldDefinitionCreate"; -export * from "./taskCustomFieldDefinitionCreateFieldType"; -export * from "./taskCustomFieldDefinitionCreateUiVisibility"; -export * from "./taskCustomFieldDefinitionRead"; -export * from "./taskCustomFieldDefinitionReadFieldType"; -export * from "./taskCustomFieldDefinitionReadUiVisibility"; -export * from "./taskCustomFieldDefinitionUpdate"; -export * from "./taskRead"; -export * from "./taskReadCustomFieldValues"; -export * from "./taskReadStatus"; -export * from "./taskUpdate"; -export * from "./taskUpdateCustomFieldValues"; -export * from "./uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams"; -export * from "./updateAgentApiV1AgentsAgentIdPatchParams"; -export * from "./userRead"; -export * from "./userUpdate"; -export * from "./validationError"; -export * from "./validationErrorCtx"; diff --git a/src/frontend/src/api/generated/model/installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams.ts b/src/frontend/src/api/generated/model/installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams.ts deleted file mode 100644 index 6672a93..0000000 --- a/src/frontend/src/api/generated/model/installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams = - { - gateway_id: string; - }; diff --git a/src/frontend/src/api/generated/model/lLMErrorResponse.ts b/src/frontend/src/api/generated/model/lLMErrorResponse.ts deleted file mode 100644 index 683bd0b..0000000 --- a/src/frontend/src/api/generated/model/lLMErrorResponse.ts +++ /dev/null @@ -1,21 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { LLMErrorResponseDetail } from "./lLMErrorResponseDetail"; - -/** - * Standardized LLM-facing error payload used by API contracts. - */ -export interface LLMErrorResponse { - /** Optional machine-readable error code. */ - code?: string | null; - /** Error payload. Agents should rely on `code` when present and default to `message` for fallback display. */ - detail: LLMErrorResponseDetail; - /** Request correlation identifier injected by middleware. */ - request_id?: string | null; - /** Whether a client should retry the call after remediating transient conditions. */ - retryable?: boolean | null; -} diff --git a/src/frontend/src/api/generated/model/lLMErrorResponseDetail.ts b/src/frontend/src/api/generated/model/lLMErrorResponseDetail.ts deleted file mode 100644 index 230029d..0000000 --- a/src/frontend/src/api/generated/model/lLMErrorResponseDetail.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Error payload. Agents should rely on `code` when present and default to `message` for fallback display. - */ -export type LLMErrorResponseDetail = - | string - | { [key: string]: unknown } - | unknown[]; diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedActivityEventRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedActivityEventRead.ts deleted file mode 100644 index 78b9086..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedActivityEventRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { ActivityEventRead } from "./activityEventRead"; - -export interface LimitOffsetPageTypeVarCustomizedActivityEventRead { - items: ActivityEventRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedActivityTaskCommentFeedItemRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedActivityTaskCommentFeedItemRead.ts deleted file mode 100644 index f39d782..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedActivityTaskCommentFeedItemRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { ActivityTaskCommentFeedItemRead } from "./activityTaskCommentFeedItemRead"; - -export interface LimitOffsetPageTypeVarCustomizedActivityTaskCommentFeedItemRead { - items: ActivityTaskCommentFeedItemRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedAgentRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedAgentRead.ts deleted file mode 100644 index 7c25454..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedAgentRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { AgentRead } from "./agentRead"; - -export interface LimitOffsetPageTypeVarCustomizedAgentRead { - items: AgentRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedApprovalRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedApprovalRead.ts deleted file mode 100644 index 0d66176..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedApprovalRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { ApprovalRead } from "./approvalRead"; - -export interface LimitOffsetPageTypeVarCustomizedApprovalRead { - items: ApprovalRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardGroupMemoryRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardGroupMemoryRead.ts deleted file mode 100644 index 5588cd9..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardGroupMemoryRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardGroupMemoryRead } from "./boardGroupMemoryRead"; - -export interface LimitOffsetPageTypeVarCustomizedBoardGroupMemoryRead { - items: BoardGroupMemoryRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardGroupRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardGroupRead.ts deleted file mode 100644 index ea0633d..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardGroupRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardGroupRead } from "./boardGroupRead"; - -export interface LimitOffsetPageTypeVarCustomizedBoardGroupRead { - items: BoardGroupRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardMemoryRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardMemoryRead.ts deleted file mode 100644 index fdf4acd..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardMemoryRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardMemoryRead } from "./boardMemoryRead"; - -export interface LimitOffsetPageTypeVarCustomizedBoardMemoryRead { - items: BoardMemoryRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardRead.ts deleted file mode 100644 index d182bde..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardRead } from "./boardRead"; - -export interface LimitOffsetPageTypeVarCustomizedBoardRead { - items: BoardRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardWebhookPayloadRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardWebhookPayloadRead.ts deleted file mode 100644 index e9fe9f7..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardWebhookPayloadRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardWebhookPayloadRead } from "./boardWebhookPayloadRead"; - -export interface LimitOffsetPageTypeVarCustomizedBoardWebhookPayloadRead { - items: BoardWebhookPayloadRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardWebhookRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardWebhookRead.ts deleted file mode 100644 index 6bde11e..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedBoardWebhookRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { BoardWebhookRead } from "./boardWebhookRead"; - -export interface LimitOffsetPageTypeVarCustomizedBoardWebhookRead { - items: BoardWebhookRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedGatewayRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedGatewayRead.ts deleted file mode 100644 index 3bae8a3..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedGatewayRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { GatewayRead } from "./gatewayRead"; - -export interface LimitOffsetPageTypeVarCustomizedGatewayRead { - items: GatewayRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedOrganizationInviteRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedOrganizationInviteRead.ts deleted file mode 100644 index cb770aa..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedOrganizationInviteRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { OrganizationInviteRead } from "./organizationInviteRead"; - -export interface LimitOffsetPageTypeVarCustomizedOrganizationInviteRead { - items: OrganizationInviteRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedOrganizationMemberRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedOrganizationMemberRead.ts deleted file mode 100644 index f616673..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedOrganizationMemberRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { OrganizationMemberRead } from "./organizationMemberRead"; - -export interface LimitOffsetPageTypeVarCustomizedOrganizationMemberRead { - items: OrganizationMemberRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedTagRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedTagRead.ts deleted file mode 100644 index 521dff8..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedTagRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { TagRead } from "./tagRead"; - -export interface LimitOffsetPageTypeVarCustomizedTagRead { - items: TagRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedTaskCommentRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedTaskCommentRead.ts deleted file mode 100644 index dcb134f..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedTaskCommentRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { TaskCommentRead } from "./taskCommentRead"; - -export interface LimitOffsetPageTypeVarCustomizedTaskCommentRead { - items: TaskCommentRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedTaskRead.ts b/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedTaskRead.ts deleted file mode 100644 index 789f482..0000000 --- a/src/frontend/src/api/generated/model/limitOffsetPageTypeVarCustomizedTaskRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { TaskRead } from "./taskRead"; - -export interface LimitOffsetPageTypeVarCustomizedTaskRead { - items: TaskRead[]; - /** @minimum 1 */ - limit: number; - /** @minimum 0 */ - offset: number; - /** @minimum 0 */ - total: number; -} diff --git a/src/frontend/src/api/generated/model/listActivityApiV1ActivityGetParams.ts b/src/frontend/src/api/generated/model/listActivityApiV1ActivityGetParams.ts deleted file mode 100644 index 050d7bc..0000000 --- a/src/frontend/src/api/generated/model/listActivityApiV1ActivityGetParams.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListActivityApiV1ActivityGetParams = { - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listAgentsApiV1AgentAgentsGetParams.ts b/src/frontend/src/api/generated/model/listAgentsApiV1AgentAgentsGetParams.ts deleted file mode 100644 index 13e6ac5..0000000 --- a/src/frontend/src/api/generated/model/listAgentsApiV1AgentAgentsGetParams.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListAgentsApiV1AgentAgentsGetParams = { - board_id?: string | null; - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listAgentsApiV1AgentsGetParams.ts b/src/frontend/src/api/generated/model/listAgentsApiV1AgentsGetParams.ts deleted file mode 100644 index d214191..0000000 --- a/src/frontend/src/api/generated/model/listAgentsApiV1AgentsGetParams.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListAgentsApiV1AgentsGetParams = { - board_id?: string | null; - gateway_id?: string | null; - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams.ts b/src/frontend/src/api/generated/model/listApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams.ts deleted file mode 100644 index a176afb..0000000 --- a/src/frontend/src/api/generated/model/listApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListApprovalsApiV1AgentBoardsBoardIdApprovalsGetParams = { - status?: "pending" | "approved" | "rejected" | null; - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listApprovalsApiV1BoardsBoardIdApprovalsGetParams.ts b/src/frontend/src/api/generated/model/listApprovalsApiV1BoardsBoardIdApprovalsGetParams.ts deleted file mode 100644 index 4d86564..0000000 --- a/src/frontend/src/api/generated/model/listApprovalsApiV1BoardsBoardIdApprovalsGetParams.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListApprovalsApiV1BoardsBoardIdApprovalsGetParams = { - status?: "pending" | "approved" | "rejected" | null; - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams.ts b/src/frontend/src/api/generated/model/listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams.ts deleted file mode 100644 index a9192e9..0000000 --- a/src/frontend/src/api/generated/model/listBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryGetParams = { - is_chat?: boolean | null; - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams.ts b/src/frontend/src/api/generated/model/listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams.ts deleted file mode 100644 index 957be7d..0000000 --- a/src/frontend/src/api/generated/model/listBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryGetParams = - { - is_chat?: boolean | null; - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; - }; diff --git a/src/frontend/src/api/generated/model/listBoardGroupsApiV1BoardGroupsGetParams.ts b/src/frontend/src/api/generated/model/listBoardGroupsApiV1BoardGroupsGetParams.ts deleted file mode 100644 index f34ab98..0000000 --- a/src/frontend/src/api/generated/model/listBoardGroupsApiV1BoardGroupsGetParams.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListBoardGroupsApiV1BoardGroupsGetParams = { - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams.ts b/src/frontend/src/api/generated/model/listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams.ts deleted file mode 100644 index 219d772..0000000 --- a/src/frontend/src/api/generated/model/listBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListBoardMemoryApiV1AgentBoardsBoardIdMemoryGetParams = { - is_chat?: boolean | null; - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listBoardMemoryApiV1BoardsBoardIdMemoryGetParams.ts b/src/frontend/src/api/generated/model/listBoardMemoryApiV1BoardsBoardIdMemoryGetParams.ts deleted file mode 100644 index 0fc8164..0000000 --- a/src/frontend/src/api/generated/model/listBoardMemoryApiV1BoardsBoardIdMemoryGetParams.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListBoardMemoryApiV1BoardsBoardIdMemoryGetParams = { - is_chat?: boolean | null; - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams.ts b/src/frontend/src/api/generated/model/listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams.ts deleted file mode 100644 index 430eac1..0000000 --- a/src/frontend/src/api/generated/model/listBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListBoardWebhookPayloadsApiV1BoardsBoardIdWebhooksWebhookIdPayloadsGetParams = - { - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; - }; diff --git a/src/frontend/src/api/generated/model/listBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams.ts b/src/frontend/src/api/generated/model/listBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams.ts deleted file mode 100644 index e260e49..0000000 --- a/src/frontend/src/api/generated/model/listBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListBoardWebhooksApiV1BoardsBoardIdWebhooksGetParams = { - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listBoardsApiV1AgentBoardsGetParams.ts b/src/frontend/src/api/generated/model/listBoardsApiV1AgentBoardsGetParams.ts deleted file mode 100644 index 76f0efb..0000000 --- a/src/frontend/src/api/generated/model/listBoardsApiV1AgentBoardsGetParams.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListBoardsApiV1AgentBoardsGetParams = { - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listBoardsApiV1BoardsGetParams.ts b/src/frontend/src/api/generated/model/listBoardsApiV1BoardsGetParams.ts deleted file mode 100644 index 0c32a78..0000000 --- a/src/frontend/src/api/generated/model/listBoardsApiV1BoardsGetParams.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListBoardsApiV1BoardsGetParams = { - gateway_id?: string | null; - board_group_id?: string | null; - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listGatewaySessionsApiV1GatewaysSessionsGetParams.ts b/src/frontend/src/api/generated/model/listGatewaySessionsApiV1GatewaysSessionsGetParams.ts deleted file mode 100644 index 4a1281c..0000000 --- a/src/frontend/src/api/generated/model/listGatewaySessionsApiV1GatewaysSessionsGetParams.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListGatewaySessionsApiV1GatewaysSessionsGetParams = { - board_id?: string | null; -}; diff --git a/src/frontend/src/api/generated/model/listGatewaysApiV1GatewaysGetParams.ts b/src/frontend/src/api/generated/model/listGatewaysApiV1GatewaysGetParams.ts deleted file mode 100644 index d667ba9..0000000 --- a/src/frontend/src/api/generated/model/listGatewaysApiV1GatewaysGetParams.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListGatewaysApiV1GatewaysGetParams = { - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listMarketplaceSkillsApiV1SkillsMarketplaceGetParams.ts b/src/frontend/src/api/generated/model/listMarketplaceSkillsApiV1SkillsMarketplaceGetParams.ts deleted file mode 100644 index a19609e..0000000 --- a/src/frontend/src/api/generated/model/listMarketplaceSkillsApiV1SkillsMarketplaceGetParams.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams = { - gateway_id: string; - search?: string | null; - category?: string | null; - risk?: string | null; - pack_id?: string | null; - limit?: number | null; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listOrgInvitesApiV1OrganizationsMeInvitesGetParams.ts b/src/frontend/src/api/generated/model/listOrgInvitesApiV1OrganizationsMeInvitesGetParams.ts deleted file mode 100644 index 8110149..0000000 --- a/src/frontend/src/api/generated/model/listOrgInvitesApiV1OrganizationsMeInvitesGetParams.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListOrgInvitesApiV1OrganizationsMeInvitesGetParams = { - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listOrgMembersApiV1OrganizationsMeMembersGetParams.ts b/src/frontend/src/api/generated/model/listOrgMembersApiV1OrganizationsMeMembersGetParams.ts deleted file mode 100644 index 7a186a3..0000000 --- a/src/frontend/src/api/generated/model/listOrgMembersApiV1OrganizationsMeMembersGetParams.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListOrgMembersApiV1OrganizationsMeMembersGetParams = { - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listTagsApiV1TagsGetParams.ts b/src/frontend/src/api/generated/model/listTagsApiV1TagsGetParams.ts deleted file mode 100644 index e631e09..0000000 --- a/src/frontend/src/api/generated/model/listTagsApiV1TagsGetParams.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListTagsApiV1TagsGetParams = { - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listTaskCommentFeedApiV1ActivityTaskCommentsGetParams.ts b/src/frontend/src/api/generated/model/listTaskCommentFeedApiV1ActivityTaskCommentsGetParams.ts deleted file mode 100644 index 2d3eef4..0000000 --- a/src/frontend/src/api/generated/model/listTaskCommentFeedApiV1ActivityTaskCommentsGetParams.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListTaskCommentFeedApiV1ActivityTaskCommentsGetParams = { - board_id?: string | null; - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams.ts b/src/frontend/src/api/generated/model/listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams.ts deleted file mode 100644 index 0bf1fa6..0000000 --- a/src/frontend/src/api/generated/model/listTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListTaskCommentsApiV1AgentBoardsBoardIdTasksTaskIdCommentsGetParams = - { - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; - }; diff --git a/src/frontend/src/api/generated/model/listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams.ts b/src/frontend/src/api/generated/model/listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams.ts deleted file mode 100644 index ef2f72a..0000000 --- a/src/frontend/src/api/generated/model/listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams = { - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listTasksApiV1AgentBoardsBoardIdTasksGetParams.ts b/src/frontend/src/api/generated/model/listTasksApiV1AgentBoardsBoardIdTasksGetParams.ts deleted file mode 100644 index 8e9f6c5..0000000 --- a/src/frontend/src/api/generated/model/listTasksApiV1AgentBoardsBoardIdTasksGetParams.ts +++ /dev/null @@ -1,21 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListTasksApiV1AgentBoardsBoardIdTasksGetParams = { - status?: string | null; - assigned_agent_id?: string | null; - unassigned?: boolean | null; - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/listTasksApiV1BoardsBoardIdTasksGetParams.ts b/src/frontend/src/api/generated/model/listTasksApiV1BoardsBoardIdTasksGetParams.ts deleted file mode 100644 index 4652d38..0000000 --- a/src/frontend/src/api/generated/model/listTasksApiV1BoardsBoardIdTasksGetParams.ts +++ /dev/null @@ -1,21 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ListTasksApiV1BoardsBoardIdTasksGetParams = { - status?: string | null; - assigned_agent_id?: string | null; - unassigned?: boolean | null; - /** - * @minimum 1 - * @maximum 200 - */ - limit?: number; - /** - * @minimum 0 - */ - offset?: number; -}; diff --git a/src/frontend/src/api/generated/model/marketplaceSkillActionResponse.ts b/src/frontend/src/api/generated/model/marketplaceSkillActionResponse.ts deleted file mode 100644 index 218a078..0000000 --- a/src/frontend/src/api/generated/model/marketplaceSkillActionResponse.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Install/uninstall action response payload. - */ -export interface MarketplaceSkillActionResponse { - gateway_id: string; - installed: boolean; - ok?: boolean; - skill_id: string; -} diff --git a/src/frontend/src/api/generated/model/marketplaceSkillCardRead.ts b/src/frontend/src/api/generated/model/marketplaceSkillCardRead.ts deleted file mode 100644 index 9d674fe..0000000 --- a/src/frontend/src/api/generated/model/marketplaceSkillCardRead.ts +++ /dev/null @@ -1,26 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { MarketplaceSkillCardReadMetadata } from "./marketplaceSkillCardReadMetadata"; - -/** - * Marketplace card payload with gateway-specific install state. - */ -export interface MarketplaceSkillCardRead { - category?: string | null; - created_at: string; - description?: string | null; - id: string; - installed: boolean; - installed_at?: string | null; - metadata?: MarketplaceSkillCardReadMetadata; - name: string; - organization_id: string; - risk?: string | null; - source?: string | null; - source_url: string; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/marketplaceSkillCardReadMetadata.ts b/src/frontend/src/api/generated/model/marketplaceSkillCardReadMetadata.ts deleted file mode 100644 index 245b3b1..0000000 --- a/src/frontend/src/api/generated/model/marketplaceSkillCardReadMetadata.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type MarketplaceSkillCardReadMetadata = { [key: string]: unknown }; diff --git a/src/frontend/src/api/generated/model/marketplaceSkillCreate.ts b/src/frontend/src/api/generated/model/marketplaceSkillCreate.ts deleted file mode 100644 index 8b9f676..0000000 --- a/src/frontend/src/api/generated/model/marketplaceSkillCreate.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload used to register a skill URL in the organization marketplace. - */ -export interface MarketplaceSkillCreate { - description?: string | null; - name?: string | null; - /** @minLength 1 */ - source_url: string; -} diff --git a/src/frontend/src/api/generated/model/marketplaceSkillRead.ts b/src/frontend/src/api/generated/model/marketplaceSkillRead.ts deleted file mode 100644 index 60e860b..0000000 --- a/src/frontend/src/api/generated/model/marketplaceSkillRead.ts +++ /dev/null @@ -1,24 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { MarketplaceSkillReadMetadata } from "./marketplaceSkillReadMetadata"; - -/** - * Serialized marketplace skill catalog record. - */ -export interface MarketplaceSkillRead { - category?: string | null; - created_at: string; - description?: string | null; - id: string; - metadata?: MarketplaceSkillReadMetadata; - name: string; - organization_id: string; - risk?: string | null; - source?: string | null; - source_url: string; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/marketplaceSkillReadMetadata.ts b/src/frontend/src/api/generated/model/marketplaceSkillReadMetadata.ts deleted file mode 100644 index 4846774..0000000 --- a/src/frontend/src/api/generated/model/marketplaceSkillReadMetadata.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type MarketplaceSkillReadMetadata = { [key: string]: unknown }; diff --git a/src/frontend/src/api/generated/model/okResponse.ts b/src/frontend/src/api/generated/model/okResponse.ts deleted file mode 100644 index 8987e86..0000000 --- a/src/frontend/src/api/generated/model/okResponse.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Standard success response payload. - */ -export interface OkResponse { - ok?: boolean; -} diff --git a/src/frontend/src/api/generated/model/organizationActiveUpdate.ts b/src/frontend/src/api/generated/model/organizationActiveUpdate.ts deleted file mode 100644 index 3a74a39..0000000 --- a/src/frontend/src/api/generated/model/organizationActiveUpdate.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for switching the active organization context. - */ -export interface OrganizationActiveUpdate { - organization_id: string; -} diff --git a/src/frontend/src/api/generated/model/organizationBoardAccessRead.ts b/src/frontend/src/api/generated/model/organizationBoardAccessRead.ts deleted file mode 100644 index 19b75f2..0000000 --- a/src/frontend/src/api/generated/model/organizationBoardAccessRead.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Board access payload returned from read endpoints. - */ -export interface OrganizationBoardAccessRead { - board_id: string; - can_read: boolean; - can_write: boolean; - created_at: string; - id: string; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/organizationBoardAccessSpec.ts b/src/frontend/src/api/generated/model/organizationBoardAccessSpec.ts deleted file mode 100644 index 6bd2881..0000000 --- a/src/frontend/src/api/generated/model/organizationBoardAccessSpec.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Board access specification used in member/invite mutation payloads. - */ -export interface OrganizationBoardAccessSpec { - board_id: string; - can_read?: boolean; - can_write?: boolean; -} diff --git a/src/frontend/src/api/generated/model/organizationCreate.ts b/src/frontend/src/api/generated/model/organizationCreate.ts deleted file mode 100644 index 339f226..0000000 --- a/src/frontend/src/api/generated/model/organizationCreate.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for creating a new organization. - */ -export interface OrganizationCreate { - name: string; -} diff --git a/src/frontend/src/api/generated/model/organizationInviteAccept.ts b/src/frontend/src/api/generated/model/organizationInviteAccept.ts deleted file mode 100644 index bd2d9eb..0000000 --- a/src/frontend/src/api/generated/model/organizationInviteAccept.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for accepting an organization invite token. - */ -export interface OrganizationInviteAccept { - token: string; -} diff --git a/src/frontend/src/api/generated/model/organizationInviteCreate.ts b/src/frontend/src/api/generated/model/organizationInviteCreate.ts deleted file mode 100644 index ef8e907..0000000 --- a/src/frontend/src/api/generated/model/organizationInviteCreate.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { OrganizationBoardAccessSpec } from "./organizationBoardAccessSpec"; - -/** - * Payload for creating an organization invite. - */ -export interface OrganizationInviteCreate { - all_boards_read?: boolean; - all_boards_write?: boolean; - board_access?: OrganizationBoardAccessSpec[]; - invited_email: string; - role?: string; -} diff --git a/src/frontend/src/api/generated/model/organizationInviteRead.ts b/src/frontend/src/api/generated/model/organizationInviteRead.ts deleted file mode 100644 index 5cba137..0000000 --- a/src/frontend/src/api/generated/model/organizationInviteRead.ts +++ /dev/null @@ -1,24 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Organization invite payload returned from read endpoints. - */ -export interface OrganizationInviteRead { - accepted_at?: string | null; - accepted_by_user_id?: string | null; - all_boards_read: boolean; - all_boards_write: boolean; - created_at: string; - created_by_user_id?: string | null; - id: string; - invited_email: string; - organization_id: string; - role: string; - token: string; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/organizationListItem.ts b/src/frontend/src/api/generated/model/organizationListItem.ts deleted file mode 100644 index 4c3cc08..0000000 --- a/src/frontend/src/api/generated/model/organizationListItem.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Organization list row for current user memberships. - */ -export interface OrganizationListItem { - id: string; - is_active: boolean; - name: string; - role: string; -} diff --git a/src/frontend/src/api/generated/model/organizationMemberAccessUpdate.ts b/src/frontend/src/api/generated/model/organizationMemberAccessUpdate.ts deleted file mode 100644 index 32e442b..0000000 --- a/src/frontend/src/api/generated/model/organizationMemberAccessUpdate.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { OrganizationBoardAccessSpec } from "./organizationBoardAccessSpec"; - -/** - * Payload for replacing organization member access permissions. - */ -export interface OrganizationMemberAccessUpdate { - all_boards_read?: boolean; - all_boards_write?: boolean; - board_access?: OrganizationBoardAccessSpec[]; -} diff --git a/src/frontend/src/api/generated/model/organizationMemberRead.ts b/src/frontend/src/api/generated/model/organizationMemberRead.ts deleted file mode 100644 index 5e91c9a..0000000 --- a/src/frontend/src/api/generated/model/organizationMemberRead.ts +++ /dev/null @@ -1,24 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { OrganizationBoardAccessRead } from "./organizationBoardAccessRead"; -import type { OrganizationUserRead } from "./organizationUserRead"; - -/** - * Organization member payload including board-level access overrides. - */ -export interface OrganizationMemberRead { - all_boards_read: boolean; - all_boards_write: boolean; - board_access?: OrganizationBoardAccessRead[]; - created_at: string; - id: string; - organization_id: string; - role: string; - updated_at: string; - user?: OrganizationUserRead | null; - user_id: string; -} diff --git a/src/frontend/src/api/generated/model/organizationMemberUpdate.ts b/src/frontend/src/api/generated/model/organizationMemberUpdate.ts deleted file mode 100644 index 6307b4b..0000000 --- a/src/frontend/src/api/generated/model/organizationMemberUpdate.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for partial updates to organization member role. - */ -export interface OrganizationMemberUpdate { - role?: string | null; -} diff --git a/src/frontend/src/api/generated/model/organizationRead.ts b/src/frontend/src/api/generated/model/organizationRead.ts deleted file mode 100644 index 8e45126..0000000 --- a/src/frontend/src/api/generated/model/organizationRead.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Organization payload returned by read endpoints. - */ -export interface OrganizationRead { - created_at: string; - id: string; - name: string; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/organizationUserRead.ts b/src/frontend/src/api/generated/model/organizationUserRead.ts deleted file mode 100644 index 490973d..0000000 --- a/src/frontend/src/api/generated/model/organizationUserRead.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Embedded user fields included in organization member payloads. - */ -export interface OrganizationUserRead { - email?: string | null; - id: string; - name?: string | null; - preferred_name?: string | null; -} diff --git a/src/frontend/src/api/generated/model/readyzReadyzGet200.ts b/src/frontend/src/api/generated/model/readyzReadyzGet200.ts deleted file mode 100644 index f2bf833..0000000 --- a/src/frontend/src/api/generated/model/readyzReadyzGet200.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ReadyzReadyzGet200 = { [key: string]: boolean }; diff --git a/src/frontend/src/api/generated/model/searchApiV1SoulsDirectorySearchGetParams.ts b/src/frontend/src/api/generated/model/searchApiV1SoulsDirectorySearchGetParams.ts deleted file mode 100644 index 10e77ba..0000000 --- a/src/frontend/src/api/generated/model/searchApiV1SoulsDirectorySearchGetParams.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type SearchApiV1SoulsDirectorySearchGetParams = { - /** - * @minLength 0 - */ - q?: string; - /** - * @minimum 1 - * @maximum 100 - */ - limit?: number; -}; diff --git a/src/frontend/src/api/generated/model/sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams.ts b/src/frontend/src/api/generated/model/sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams.ts deleted file mode 100644 index 2e42fcd..0000000 --- a/src/frontend/src/api/generated/model/sendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type SendGatewaySessionMessageApiV1GatewaysSessionsSessionIdMessagePostParams = - { - board_id?: string | null; - }; diff --git a/src/frontend/src/api/generated/model/skillPackCreate.ts b/src/frontend/src/api/generated/model/skillPackCreate.ts deleted file mode 100644 index a0fa15c..0000000 --- a/src/frontend/src/api/generated/model/skillPackCreate.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { SkillPackCreateMetadata } from "./skillPackCreateMetadata"; - -/** - * Payload used to register a pack URL in the organization. - */ -export interface SkillPackCreate { - branch?: string; - description?: string | null; - metadata?: SkillPackCreateMetadata; - name?: string | null; - /** @minLength 1 */ - source_url: string; -} diff --git a/src/frontend/src/api/generated/model/skillPackCreateMetadata.ts b/src/frontend/src/api/generated/model/skillPackCreateMetadata.ts deleted file mode 100644 index 3cc9082..0000000 --- a/src/frontend/src/api/generated/model/skillPackCreateMetadata.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type SkillPackCreateMetadata = { [key: string]: unknown }; diff --git a/src/frontend/src/api/generated/model/skillPackRead.ts b/src/frontend/src/api/generated/model/skillPackRead.ts deleted file mode 100644 index ece7257..0000000 --- a/src/frontend/src/api/generated/model/skillPackRead.ts +++ /dev/null @@ -1,23 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { SkillPackReadMetadata } from "./skillPackReadMetadata"; - -/** - * Serialized skill pack record. - */ -export interface SkillPackRead { - branch: string; - created_at: string; - description?: string | null; - id: string; - metadata?: SkillPackReadMetadata; - name: string; - organization_id: string; - skill_count?: number; - source_url: string; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/skillPackReadMetadata.ts b/src/frontend/src/api/generated/model/skillPackReadMetadata.ts deleted file mode 100644 index 307c24e..0000000 --- a/src/frontend/src/api/generated/model/skillPackReadMetadata.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type SkillPackReadMetadata = { [key: string]: unknown }; diff --git a/src/frontend/src/api/generated/model/skillPackSyncResponse.ts b/src/frontend/src/api/generated/model/skillPackSyncResponse.ts deleted file mode 100644 index fdcbbbc..0000000 --- a/src/frontend/src/api/generated/model/skillPackSyncResponse.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Pack sync summary payload. - */ -export interface SkillPackSyncResponse { - created: number; - ok?: boolean; - pack_id: string; - synced: number; - updated: number; - warnings?: string[]; -} diff --git a/src/frontend/src/api/generated/model/soulUpdateRequest.ts b/src/frontend/src/api/generated/model/soulUpdateRequest.ts deleted file mode 100644 index 4e0e840..0000000 --- a/src/frontend/src/api/generated/model/soulUpdateRequest.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for updating an agent SOUL document. - */ -export interface SoulUpdateRequest { - content: string; - reason?: string | null; - source_url?: string | null; -} diff --git a/src/frontend/src/api/generated/model/soulsDirectoryMarkdownResponse.ts b/src/frontend/src/api/generated/model/soulsDirectoryMarkdownResponse.ts deleted file mode 100644 index a7af0d7..0000000 --- a/src/frontend/src/api/generated/model/soulsDirectoryMarkdownResponse.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Response payload containing rendered markdown for a soul. - */ -export interface SoulsDirectoryMarkdownResponse { - content: string; - handle: string; - slug: string; -} diff --git a/src/frontend/src/api/generated/model/soulsDirectorySearchResponse.ts b/src/frontend/src/api/generated/model/soulsDirectorySearchResponse.ts deleted file mode 100644 index 32b3130..0000000 --- a/src/frontend/src/api/generated/model/soulsDirectorySearchResponse.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { SoulsDirectorySoulRef } from "./soulsDirectorySoulRef"; - -/** - * Response wrapper for directory search results. - */ -export interface SoulsDirectorySearchResponse { - items: SoulsDirectorySoulRef[]; -} diff --git a/src/frontend/src/api/generated/model/soulsDirectorySoulRef.ts b/src/frontend/src/api/generated/model/soulsDirectorySoulRef.ts deleted file mode 100644 index 6c1bb0a..0000000 --- a/src/frontend/src/api/generated/model/soulsDirectorySoulRef.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Reference metadata for a soul entry in the directory index. - */ -export interface SoulsDirectorySoulRef { - handle: string; - page_url: string; - raw_md_url: string; - slug: string; -} diff --git a/src/frontend/src/api/generated/model/streamAgentsApiV1AgentsStreamGetParams.ts b/src/frontend/src/api/generated/model/streamAgentsApiV1AgentsStreamGetParams.ts deleted file mode 100644 index 744f6c3..0000000 --- a/src/frontend/src/api/generated/model/streamAgentsApiV1AgentsStreamGetParams.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type StreamAgentsApiV1AgentsStreamGetParams = { - board_id?: string | null; - since?: string | null; -}; diff --git a/src/frontend/src/api/generated/model/streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams.ts b/src/frontend/src/api/generated/model/streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams.ts deleted file mode 100644 index 4d0fb9a..0000000 --- a/src/frontend/src/api/generated/model/streamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type StreamApprovalsApiV1BoardsBoardIdApprovalsStreamGetParams = { - since?: string | null; -}; diff --git a/src/frontend/src/api/generated/model/streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams.ts b/src/frontend/src/api/generated/model/streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams.ts deleted file mode 100644 index 51dd576..0000000 --- a/src/frontend/src/api/generated/model/streamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams.ts +++ /dev/null @@ -1,12 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type StreamBoardGroupMemoryApiV1BoardGroupsGroupIdMemoryStreamGetParams = - { - since?: string | null; - is_chat?: boolean | null; - }; diff --git a/src/frontend/src/api/generated/model/streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams.ts b/src/frontend/src/api/generated/model/streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams.ts deleted file mode 100644 index 1006956..0000000 --- a/src/frontend/src/api/generated/model/streamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams.ts +++ /dev/null @@ -1,12 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type StreamBoardGroupMemoryForBoardApiV1BoardsBoardIdGroupMemoryStreamGetParams = - { - since?: string | null; - is_chat?: boolean | null; - }; diff --git a/src/frontend/src/api/generated/model/streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams.ts b/src/frontend/src/api/generated/model/streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams.ts deleted file mode 100644 index b16a7c3..0000000 --- a/src/frontend/src/api/generated/model/streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type StreamBoardMemoryApiV1BoardsBoardIdMemoryStreamGetParams = { - since?: string | null; - is_chat?: boolean | null; -}; diff --git a/src/frontend/src/api/generated/model/streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams.ts b/src/frontend/src/api/generated/model/streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams.ts deleted file mode 100644 index 82e101b..0000000 --- a/src/frontend/src/api/generated/model/streamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type StreamTaskCommentFeedApiV1ActivityTaskCommentsStreamGetParams = { - board_id?: string | null; - since?: string | null; -}; diff --git a/src/frontend/src/api/generated/model/streamTasksApiV1BoardsBoardIdTasksStreamGetParams.ts b/src/frontend/src/api/generated/model/streamTasksApiV1BoardsBoardIdTasksStreamGetParams.ts deleted file mode 100644 index 9907aae..0000000 --- a/src/frontend/src/api/generated/model/streamTasksApiV1BoardsBoardIdTasksStreamGetParams.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type StreamTasksApiV1BoardsBoardIdTasksStreamGetParams = { - since?: string | null; -}; diff --git a/src/frontend/src/api/generated/model/syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams.ts b/src/frontend/src/api/generated/model/syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams.ts deleted file mode 100644 index 5b2524b..0000000 --- a/src/frontend/src/api/generated/model/syncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type SyncGatewayTemplatesApiV1GatewaysGatewayIdTemplatesSyncPostParams = - { - include_main?: boolean; - lead_only?: boolean; - reset_sessions?: boolean; - rotate_tokens?: boolean; - force_bootstrap?: boolean; - overwrite?: boolean; - board_id?: string | null; - }; diff --git a/src/frontend/src/api/generated/model/tagCreate.ts b/src/frontend/src/api/generated/model/tagCreate.ts deleted file mode 100644 index 9c75472..0000000 --- a/src/frontend/src/api/generated/model/tagCreate.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for creating a tag. - */ -export interface TagCreate { - color?: string; - description?: string | null; - /** @minLength 1 */ - name: string; - slug?: string | null; -} diff --git a/src/frontend/src/api/generated/model/tagRead.ts b/src/frontend/src/api/generated/model/tagRead.ts deleted file mode 100644 index af1d3bd..0000000 --- a/src/frontend/src/api/generated/model/tagRead.ts +++ /dev/null @@ -1,21 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Tag payload returned from API endpoints. - */ -export interface TagRead { - color?: string; - created_at: string; - description?: string | null; - id: string; - name: string; - organization_id: string; - slug: string; - task_count?: number; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/tagRef.ts b/src/frontend/src/api/generated/model/tagRef.ts deleted file mode 100644 index 9b7d745..0000000 --- a/src/frontend/src/api/generated/model/tagRef.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Compact tag representation embedded in task payloads. - */ -export interface TagRef { - color: string; - id: string; - name: string; - slug: string; -} diff --git a/src/frontend/src/api/generated/model/tagUpdate.ts b/src/frontend/src/api/generated/model/tagUpdate.ts deleted file mode 100644 index 4a18b9d..0000000 --- a/src/frontend/src/api/generated/model/tagUpdate.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for partial tag updates. - */ -export interface TagUpdate { - color?: string | null; - description?: string | null; - name?: string | null; - slug?: string | null; -} diff --git a/src/frontend/src/api/generated/model/taskCardRead.ts b/src/frontend/src/api/generated/model/taskCardRead.ts deleted file mode 100644 index 0202522..0000000 --- a/src/frontend/src/api/generated/model/taskCardRead.ts +++ /dev/null @@ -1,36 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { TagRef } from "./tagRef"; -import type { TaskCardReadCustomFieldValues } from "./taskCardReadCustomFieldValues"; -import type { TaskCardReadStatus } from "./taskCardReadStatus"; - -/** - * Task read model enriched with assignee and approval counters. - */ -export interface TaskCardRead { - approvals_count?: number; - approvals_pending_count?: number; - assigned_agent_id?: string | null; - assignee?: string | null; - blocked_by_task_ids?: string[]; - board_id: string | null; - created_at: string; - created_by_user_id: string | null; - custom_field_values?: TaskCardReadCustomFieldValues; - depends_on_task_ids?: string[]; - description?: string | null; - due_at?: string | null; - id: string; - in_progress_at: string | null; - is_blocked?: boolean; - priority?: string; - status?: TaskCardReadStatus; - tag_ids?: string[]; - tags?: TagRef[]; - title: string; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/taskCardReadCustomFieldValues.ts b/src/frontend/src/api/generated/model/taskCardReadCustomFieldValues.ts deleted file mode 100644 index 0eee1a7..0000000 --- a/src/frontend/src/api/generated/model/taskCardReadCustomFieldValues.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type TaskCardReadCustomFieldValues = { - [key: string]: unknown | null; -} | null; diff --git a/src/frontend/src/api/generated/model/taskCardReadStatus.ts b/src/frontend/src/api/generated/model/taskCardReadStatus.ts deleted file mode 100644 index 656ae19..0000000 --- a/src/frontend/src/api/generated/model/taskCardReadStatus.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type TaskCardReadStatus = - (typeof TaskCardReadStatus)[keyof typeof TaskCardReadStatus]; - -export const TaskCardReadStatus = { - inbox: "inbox", - in_progress: "in_progress", - review: "review", - done: "done", -} as const; diff --git a/src/frontend/src/api/generated/model/taskCommentCreate.ts b/src/frontend/src/api/generated/model/taskCommentCreate.ts deleted file mode 100644 index 7bc255c..0000000 --- a/src/frontend/src/api/generated/model/taskCommentCreate.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for creating a task comment. - */ -export interface TaskCommentCreate { - /** @minLength 1 */ - message: string; -} diff --git a/src/frontend/src/api/generated/model/taskCommentRead.ts b/src/frontend/src/api/generated/model/taskCommentRead.ts deleted file mode 100644 index faec431..0000000 --- a/src/frontend/src/api/generated/model/taskCommentRead.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Task comment payload returned from read endpoints. - */ -export interface TaskCommentRead { - agent_id: string | null; - created_at: string; - id: string; - message: string | null; - task_id: string | null; -} diff --git a/src/frontend/src/api/generated/model/taskCreate.ts b/src/frontend/src/api/generated/model/taskCreate.ts deleted file mode 100644 index a8572c2..0000000 --- a/src/frontend/src/api/generated/model/taskCreate.ts +++ /dev/null @@ -1,24 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { TaskCreateCustomFieldValues } from "./taskCreateCustomFieldValues"; -import type { TaskCreateStatus } from "./taskCreateStatus"; - -/** - * Payload for creating a task. - */ -export interface TaskCreate { - assigned_agent_id?: string | null; - created_by_user_id?: string | null; - custom_field_values?: TaskCreateCustomFieldValues; - depends_on_task_ids?: string[]; - description?: string | null; - due_at?: string | null; - priority?: string; - status?: TaskCreateStatus; - tag_ids?: string[]; - title: string; -} diff --git a/src/frontend/src/api/generated/model/taskCreateCustomFieldValues.ts b/src/frontend/src/api/generated/model/taskCreateCustomFieldValues.ts deleted file mode 100644 index 7bf9de0..0000000 --- a/src/frontend/src/api/generated/model/taskCreateCustomFieldValues.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type TaskCreateCustomFieldValues = { [key: string]: unknown | null }; diff --git a/src/frontend/src/api/generated/model/taskCreateStatus.ts b/src/frontend/src/api/generated/model/taskCreateStatus.ts deleted file mode 100644 index 2682406..0000000 --- a/src/frontend/src/api/generated/model/taskCreateStatus.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type TaskCreateStatus = - (typeof TaskCreateStatus)[keyof typeof TaskCreateStatus]; - -export const TaskCreateStatus = { - inbox: "inbox", - in_progress: "in_progress", - review: "review", - done: "done", -} as const; diff --git a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionCreate.ts b/src/frontend/src/api/generated/model/taskCustomFieldDefinitionCreate.ts deleted file mode 100644 index b348616..0000000 --- a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionCreate.ts +++ /dev/null @@ -1,25 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { TaskCustomFieldDefinitionCreateFieldType } from "./taskCustomFieldDefinitionCreateFieldType"; -import type { TaskCustomFieldDefinitionCreateUiVisibility } from "./taskCustomFieldDefinitionCreateUiVisibility"; - -/** - * Payload for creating a task custom field definition. - */ -export interface TaskCustomFieldDefinitionCreate { - /** @minItems 1 */ - board_ids: string[]; - default_value?: unknown | null; - description?: string | null; - /** @minLength 1 */ - field_key: string; - field_type?: TaskCustomFieldDefinitionCreateFieldType; - label?: string | null; - required?: boolean; - ui_visibility?: TaskCustomFieldDefinitionCreateUiVisibility; - validation_regex?: string | null; -} diff --git a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionCreateFieldType.ts b/src/frontend/src/api/generated/model/taskCustomFieldDefinitionCreateFieldType.ts deleted file mode 100644 index 82b9474..0000000 --- a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionCreateFieldType.ts +++ /dev/null @@ -1,21 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type TaskCustomFieldDefinitionCreateFieldType = - (typeof TaskCustomFieldDefinitionCreateFieldType)[keyof typeof TaskCustomFieldDefinitionCreateFieldType]; - -export const TaskCustomFieldDefinitionCreateFieldType = { - text: "text", - text_long: "text_long", - integer: "integer", - decimal: "decimal", - boolean: "boolean", - date: "date", - date_time: "date_time", - url: "url", - json: "json", -} as const; diff --git a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionCreateUiVisibility.ts b/src/frontend/src/api/generated/model/taskCustomFieldDefinitionCreateUiVisibility.ts deleted file mode 100644 index 9ad2cb2..0000000 --- a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionCreateUiVisibility.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type TaskCustomFieldDefinitionCreateUiVisibility = - (typeof TaskCustomFieldDefinitionCreateUiVisibility)[keyof typeof TaskCustomFieldDefinitionCreateUiVisibility]; - -export const TaskCustomFieldDefinitionCreateUiVisibility = { - always: "always", - if_set: "if_set", - hidden: "hidden", -} as const; diff --git a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionRead.ts b/src/frontend/src/api/generated/model/taskCustomFieldDefinitionRead.ts deleted file mode 100644 index 52c8066..0000000 --- a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionRead.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { TaskCustomFieldDefinitionReadFieldType } from "./taskCustomFieldDefinitionReadFieldType"; -import type { TaskCustomFieldDefinitionReadUiVisibility } from "./taskCustomFieldDefinitionReadUiVisibility"; - -/** - * Payload returned for custom field definitions. - */ -export interface TaskCustomFieldDefinitionRead { - board_ids?: string[]; - created_at: string; - default_value?: unknown | null; - description?: string | null; - field_key: string; - field_type: TaskCustomFieldDefinitionReadFieldType; - id: string; - label: string; - organization_id: string; - required?: boolean; - ui_visibility: TaskCustomFieldDefinitionReadUiVisibility; - updated_at: string; - validation_regex?: string | null; -} diff --git a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionReadFieldType.ts b/src/frontend/src/api/generated/model/taskCustomFieldDefinitionReadFieldType.ts deleted file mode 100644 index ac067c7..0000000 --- a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionReadFieldType.ts +++ /dev/null @@ -1,21 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type TaskCustomFieldDefinitionReadFieldType = - (typeof TaskCustomFieldDefinitionReadFieldType)[keyof typeof TaskCustomFieldDefinitionReadFieldType]; - -export const TaskCustomFieldDefinitionReadFieldType = { - text: "text", - text_long: "text_long", - integer: "integer", - decimal: "decimal", - boolean: "boolean", - date: "date", - date_time: "date_time", - url: "url", - json: "json", -} as const; diff --git a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionReadUiVisibility.ts b/src/frontend/src/api/generated/model/taskCustomFieldDefinitionReadUiVisibility.ts deleted file mode 100644 index 6719c08..0000000 --- a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionReadUiVisibility.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type TaskCustomFieldDefinitionReadUiVisibility = - (typeof TaskCustomFieldDefinitionReadUiVisibility)[keyof typeof TaskCustomFieldDefinitionReadUiVisibility]; - -export const TaskCustomFieldDefinitionReadUiVisibility = { - always: "always", - if_set: "if_set", - hidden: "hidden", -} as const; diff --git a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionUpdate.ts b/src/frontend/src/api/generated/model/taskCustomFieldDefinitionUpdate.ts deleted file mode 100644 index 7beeb43..0000000 --- a/src/frontend/src/api/generated/model/taskCustomFieldDefinitionUpdate.ts +++ /dev/null @@ -1,30 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for editing an existing task custom field definition. - */ -export interface TaskCustomFieldDefinitionUpdate { - board_ids?: string[] | null; - default_value?: unknown | null; - description?: string | null; - field_type?: - | "text" - | "text_long" - | "integer" - | "decimal" - | "boolean" - | "date" - | "date_time" - | "url" - | "json" - | null; - label?: string | null; - required?: boolean | null; - ui_visibility?: "always" | "if_set" | "hidden" | null; - validation_regex?: string | null; -} diff --git a/src/frontend/src/api/generated/model/taskRead.ts b/src/frontend/src/api/generated/model/taskRead.ts deleted file mode 100644 index 5d87441..0000000 --- a/src/frontend/src/api/generated/model/taskRead.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { TagRef } from "./tagRef"; -import type { TaskReadCustomFieldValues } from "./taskReadCustomFieldValues"; -import type { TaskReadStatus } from "./taskReadStatus"; - -/** - * Task payload returned from read endpoints. - */ -export interface TaskRead { - assigned_agent_id?: string | null; - blocked_by_task_ids?: string[]; - board_id: string | null; - created_at: string; - created_by_user_id: string | null; - custom_field_values?: TaskReadCustomFieldValues; - depends_on_task_ids?: string[]; - description?: string | null; - due_at?: string | null; - id: string; - in_progress_at: string | null; - is_blocked?: boolean; - priority?: string; - status?: TaskReadStatus; - tag_ids?: string[]; - tags?: TagRef[]; - title: string; - updated_at: string; -} diff --git a/src/frontend/src/api/generated/model/taskReadCustomFieldValues.ts b/src/frontend/src/api/generated/model/taskReadCustomFieldValues.ts deleted file mode 100644 index c7aa6fb..0000000 --- a/src/frontend/src/api/generated/model/taskReadCustomFieldValues.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type TaskReadCustomFieldValues = { - [key: string]: unknown | null; -} | null; diff --git a/src/frontend/src/api/generated/model/taskReadStatus.ts b/src/frontend/src/api/generated/model/taskReadStatus.ts deleted file mode 100644 index 25e581e..0000000 --- a/src/frontend/src/api/generated/model/taskReadStatus.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type TaskReadStatus = - (typeof TaskReadStatus)[keyof typeof TaskReadStatus]; - -export const TaskReadStatus = { - inbox: "inbox", - in_progress: "in_progress", - review: "review", - done: "done", -} as const; diff --git a/src/frontend/src/api/generated/model/taskUpdate.ts b/src/frontend/src/api/generated/model/taskUpdate.ts deleted file mode 100644 index ddaa993..0000000 --- a/src/frontend/src/api/generated/model/taskUpdate.ts +++ /dev/null @@ -1,23 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { TaskUpdateCustomFieldValues } from "./taskUpdateCustomFieldValues"; - -/** - * Payload for partial task updates. - */ -export interface TaskUpdate { - assigned_agent_id?: string | null; - comment?: string | null; - custom_field_values?: TaskUpdateCustomFieldValues; - depends_on_task_ids?: string[] | null; - description?: string | null; - due_at?: string | null; - priority?: string | null; - status?: "inbox" | "in_progress" | "review" | "done" | null; - tag_ids?: string[] | null; - title?: string | null; -} diff --git a/src/frontend/src/api/generated/model/taskUpdateCustomFieldValues.ts b/src/frontend/src/api/generated/model/taskUpdateCustomFieldValues.ts deleted file mode 100644 index d1dfaa0..0000000 --- a/src/frontend/src/api/generated/model/taskUpdateCustomFieldValues.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type TaskUpdateCustomFieldValues = { - [key: string]: unknown | null; -} | null; diff --git a/src/frontend/src/api/generated/model/uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams.ts b/src/frontend/src/api/generated/model/uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams.ts deleted file mode 100644 index d5a5a8d..0000000 --- a/src/frontend/src/api/generated/model/uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams = - { - gateway_id: string; - }; diff --git a/src/frontend/src/api/generated/model/updateAgentApiV1AgentsAgentIdPatchParams.ts b/src/frontend/src/api/generated/model/updateAgentApiV1AgentsAgentIdPatchParams.ts deleted file mode 100644 index 9334a8c..0000000 --- a/src/frontend/src/api/generated/model/updateAgentApiV1AgentsAgentIdPatchParams.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type UpdateAgentApiV1AgentsAgentIdPatchParams = { - force?: boolean; -}; diff --git a/src/frontend/src/api/generated/model/userRead.ts b/src/frontend/src/api/generated/model/userRead.ts deleted file mode 100644 index 1a75f6a..0000000 --- a/src/frontend/src/api/generated/model/userRead.ts +++ /dev/null @@ -1,32 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Full user payload returned by API responses. - */ -export interface UserRead { - /** External auth provider user identifier (Clerk). */ - clerk_user_id: string; - /** Additional context used by the system for personalization. */ - context?: string | null; - /** Primary email address for the user. */ - email?: string | null; - /** Internal user UUID. */ - id: string; - /** Whether this user has tenant-wide super-admin privileges. */ - is_super_admin: boolean; - /** Full display name. */ - name?: string | null; - /** Internal notes for operators. */ - notes?: string | null; - /** Preferred short name used in UI. */ - preferred_name?: string | null; - /** Preferred pronouns. */ - pronouns?: string | null; - /** IANA timezone identifier. */ - timezone?: string | null; -} diff --git a/src/frontend/src/api/generated/model/userUpdate.ts b/src/frontend/src/api/generated/model/userUpdate.ts deleted file mode 100644 index cc9ab99..0000000 --- a/src/frontend/src/api/generated/model/userUpdate.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -/** - * Payload for partial user profile updates. - */ -export interface UserUpdate { - context?: string | null; - name?: string | null; - notes?: string | null; - preferred_name?: string | null; - pronouns?: string | null; - timezone?: string | null; -} diff --git a/src/frontend/src/api/generated/model/validationError.ts b/src/frontend/src/api/generated/model/validationError.ts deleted file mode 100644 index b40de80..0000000 --- a/src/frontend/src/api/generated/model/validationError.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import type { ValidationErrorCtx } from "./validationErrorCtx"; - -export interface ValidationError { - ctx?: ValidationErrorCtx; - input?: unknown; - loc: (string | number)[]; - msg: string; - type: string; -} diff --git a/src/frontend/src/api/generated/model/validationErrorCtx.ts b/src/frontend/src/api/generated/model/validationErrorCtx.ts deleted file mode 100644 index 6551146..0000000 --- a/src/frontend/src/api/generated/model/validationErrorCtx.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ - -export type ValidationErrorCtx = { [key: string]: unknown }; diff --git a/src/frontend/src/api/generated/org-custom-fields/org-custom-fields.ts b/src/frontend/src/api/generated/org-custom-fields/org-custom-fields.ts deleted file mode 100644 index 2f5e1c9..0000000 --- a/src/frontend/src/api/generated/org-custom-fields/org-custom-fields.ts +++ /dev/null @@ -1,751 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - HTTPValidationError, - OkResponse, - TaskCustomFieldDefinitionCreate, - TaskCustomFieldDefinitionRead, - TaskCustomFieldDefinitionUpdate, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List task custom field definitions for the authenticated organization. - * @summary List Org Custom Fields - */ -export type listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetResponse200 = - { - data: TaskCustomFieldDefinitionRead[]; - status: 200; - }; - -export type listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetResponseSuccess = - listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetResponse200 & { - headers: Headers; - }; -export type listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetResponse = - listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetResponseSuccess; - -export const getListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetUrl = - () => { - return `/api/v1/organizations/me/custom-fields`; - }; - -export const listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetUrl(), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetQueryKey = - () => { - return [`/api/v1/organizations/me/custom-fields`] as const; - }; - -export const getListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetQueryOptions = - < - TData = Awaited< - ReturnType - >, - TError = unknown, - >(options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetQueryKey(); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - > - > = ({ signal }) => - listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet({ - signal, - ...requestOptions, - }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type ListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetQueryResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type ListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetQueryError = - unknown; - -export function useListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Org Custom Fields - */ - -export function useListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListOrgCustomFieldsApiV1OrganizationsMeCustomFieldsGetQueryOptions( - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create an organization-level task custom field definition. - * @summary Create Org Custom Field - */ -export type createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponse200 = - { - data: TaskCustomFieldDefinitionRead; - status: 200; - }; - -export type createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponseSuccess = - createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponse200 & { - headers: Headers; - }; -export type createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponseError = - createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponse422 & { - headers: Headers; - }; - -export type createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponse = - | createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponseSuccess - | createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostResponseError; - -export const getCreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostUrl = - () => { - return `/api/v1/organizations/me/custom-fields`; - }; - -export const createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost = async ( - taskCustomFieldDefinitionCreate: TaskCustomFieldDefinitionCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(taskCustomFieldDefinitionCreate), - }, - ); -}; - -export const getCreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost - > - >, - TError, - { data: TaskCustomFieldDefinitionCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost - > - >, - TError, - { data: TaskCustomFieldDefinitionCreate }, - TContext - > => { - const mutationKey = [ - "createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost - > - >, - { data: TaskCustomFieldDefinitionCreate } - > = (props) => { - const { data } = props ?? {}; - - return createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost( - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type CreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost - > - > - >; -export type CreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostMutationBody = - TaskCustomFieldDefinitionCreate; -export type CreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostMutationError = - HTTPValidationError; - -/** - * @summary Create Org Custom Field - */ -export const useCreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof createOrgCustomFieldApiV1OrganizationsMeCustomFieldsPost - > - >, - TError, - { data: TaskCustomFieldDefinitionCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { data: TaskCustomFieldDefinitionCreate }, - TContext -> => { - return useMutation( - getCreateOrgCustomFieldApiV1OrganizationsMeCustomFieldsPostMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Delete an org-level definition when it has no persisted task values. - * @summary Delete Org Custom Field - */ -export type deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponse200 = - { - data: OkResponse; - status: 200; - }; - -export type deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponseSuccess = - deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponseError = - deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponse = - - | deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponseSuccess - | deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteResponseError; - -export const getDeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteUrl = - (taskCustomFieldDefinitionId: string) => { - return `/api/v1/organizations/me/custom-fields/${taskCustomFieldDefinitionId}`; - }; - -export const deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete = - async ( - taskCustomFieldDefinitionId: string, - options?: RequestInit, - ): Promise => { - return customFetch( - getDeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteUrl( - taskCustomFieldDefinitionId, - ), - { - ...options, - method: "DELETE", - }, - ); - }; - -export const getDeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete - > - >, - TError, - { taskCustomFieldDefinitionId: string }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete - > - >, - TError, - { taskCustomFieldDefinitionId: string }, - TContext - > => { - const mutationKey = [ - "deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete - > - >, - { taskCustomFieldDefinitionId: string } - > = (props) => { - const { taskCustomFieldDefinitionId } = props ?? {}; - - return deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete( - taskCustomFieldDefinitionId, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type DeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete - > - > - >; - -export type DeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Delete Org Custom Field - */ -export const useDeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete = - ( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete - > - >, - TError, - { taskCustomFieldDefinitionId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, - ): UseMutationResult< - Awaited< - ReturnType< - typeof deleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDelete - > - >, - TError, - { taskCustomFieldDefinitionId: string }, - TContext - > => { - return useMutation( - getDeleteOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdDeleteMutationOptions( - options, - ), - queryClient, - ); - }; -/** - * Update an organization-level task custom field definition. - * @summary Update Org Custom Field - */ -export type updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponse200 = - { - data: TaskCustomFieldDefinitionRead; - status: 200; - }; - -export type updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponseSuccess = - updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponse200 & { - headers: Headers; - }; -export type updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponseError = - updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponse422 & { - headers: Headers; - }; - -export type updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponse = - - | updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponseSuccess - | updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchResponseError; - -export const getUpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchUrl = - (taskCustomFieldDefinitionId: string) => { - return `/api/v1/organizations/me/custom-fields/${taskCustomFieldDefinitionId}`; - }; - -export const updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch = - async ( - taskCustomFieldDefinitionId: string, - taskCustomFieldDefinitionUpdate: TaskCustomFieldDefinitionUpdate, - options?: RequestInit, - ): Promise => { - return customFetch( - getUpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchUrl( - taskCustomFieldDefinitionId, - ), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(taskCustomFieldDefinitionUpdate), - }, - ); - }; - -export const getUpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch - > - >, - TError, - { - taskCustomFieldDefinitionId: string; - data: TaskCustomFieldDefinitionUpdate; - }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch - > - >, - TError, - { - taskCustomFieldDefinitionId: string; - data: TaskCustomFieldDefinitionUpdate; - }, - TContext - > => { - const mutationKey = [ - "updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch - > - >, - { - taskCustomFieldDefinitionId: string; - data: TaskCustomFieldDefinitionUpdate; - } - > = (props) => { - const { taskCustomFieldDefinitionId, data } = props ?? {}; - - return updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch( - taskCustomFieldDefinitionId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type UpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch - > - > - >; -export type UpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchMutationBody = - TaskCustomFieldDefinitionUpdate; -export type UpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchMutationError = - HTTPValidationError; - -/** - * @summary Update Org Custom Field - */ -export const useUpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch = - ( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch - > - >, - TError, - { - taskCustomFieldDefinitionId: string; - data: TaskCustomFieldDefinitionUpdate; - }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, - ): UseMutationResult< - Awaited< - ReturnType< - typeof updateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatch - > - >, - TError, - { - taskCustomFieldDefinitionId: string; - data: TaskCustomFieldDefinitionUpdate; - }, - TContext - > => { - return useMutation( - getUpdateOrgCustomFieldApiV1OrganizationsMeCustomFieldsTaskCustomFieldDefinitionIdPatchMutationOptions( - options, - ), - queryClient, - ); - }; diff --git a/src/frontend/src/api/generated/organizations/organizations.ts b/src/frontend/src/api/generated/organizations/organizations.ts deleted file mode 100644 index cb75633..0000000 --- a/src/frontend/src/api/generated/organizations/organizations.ts +++ /dev/null @@ -1,2594 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - HTTPValidationError, - LimitOffsetPageTypeVarCustomizedOrganizationInviteRead, - LimitOffsetPageTypeVarCustomizedOrganizationMemberRead, - ListOrgInvitesApiV1OrganizationsMeInvitesGetParams, - ListOrgMembersApiV1OrganizationsMeMembersGetParams, - OkResponse, - OrganizationActiveUpdate, - OrganizationCreate, - OrganizationInviteAccept, - OrganizationInviteCreate, - OrganizationInviteRead, - OrganizationListItem, - OrganizationMemberAccessUpdate, - OrganizationMemberRead, - OrganizationMemberUpdate, - OrganizationRead, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * Create an organization and assign the caller as owner. - * @summary Create Organization - */ -export type createOrganizationApiV1OrganizationsPostResponse200 = { - data: OrganizationRead; - status: 200; -}; - -export type createOrganizationApiV1OrganizationsPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createOrganizationApiV1OrganizationsPostResponseSuccess = - createOrganizationApiV1OrganizationsPostResponse200 & { - headers: Headers; - }; -export type createOrganizationApiV1OrganizationsPostResponseError = - createOrganizationApiV1OrganizationsPostResponse422 & { - headers: Headers; - }; - -export type createOrganizationApiV1OrganizationsPostResponse = - | createOrganizationApiV1OrganizationsPostResponseSuccess - | createOrganizationApiV1OrganizationsPostResponseError; - -export const getCreateOrganizationApiV1OrganizationsPostUrl = () => { - return `/api/v1/organizations`; -}; - -export const createOrganizationApiV1OrganizationsPost = async ( - organizationCreate: OrganizationCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateOrganizationApiV1OrganizationsPostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(organizationCreate), - }, - ); -}; - -export const getCreateOrganizationApiV1OrganizationsPostMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: OrganizationCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { data: OrganizationCreate }, - TContext -> => { - const mutationKey = ["createOrganizationApiV1OrganizationsPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { data: OrganizationCreate } - > = (props) => { - const { data } = props ?? {}; - - return createOrganizationApiV1OrganizationsPost(data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type CreateOrganizationApiV1OrganizationsPostMutationResult = - NonNullable< - Awaited> - >; -export type CreateOrganizationApiV1OrganizationsPostMutationBody = - OrganizationCreate; -export type CreateOrganizationApiV1OrganizationsPostMutationError = - HTTPValidationError; - -/** - * @summary Create Organization - */ -export const useCreateOrganizationApiV1OrganizationsPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: OrganizationCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: OrganizationCreate }, - TContext -> => { - return useMutation( - getCreateOrganizationApiV1OrganizationsPostMutationOptions(options), - queryClient, - ); -}; -/** - * Accept an invite and return resulting membership. - * @summary Accept Org Invite - */ -export type acceptOrgInviteApiV1OrganizationsInvitesAcceptPostResponse200 = { - data: OrganizationMemberRead; - status: 200; -}; - -export type acceptOrgInviteApiV1OrganizationsInvitesAcceptPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type acceptOrgInviteApiV1OrganizationsInvitesAcceptPostResponseSuccess = - acceptOrgInviteApiV1OrganizationsInvitesAcceptPostResponse200 & { - headers: Headers; - }; -export type acceptOrgInviteApiV1OrganizationsInvitesAcceptPostResponseError = - acceptOrgInviteApiV1OrganizationsInvitesAcceptPostResponse422 & { - headers: Headers; - }; - -export type acceptOrgInviteApiV1OrganizationsInvitesAcceptPostResponse = - | acceptOrgInviteApiV1OrganizationsInvitesAcceptPostResponseSuccess - | acceptOrgInviteApiV1OrganizationsInvitesAcceptPostResponseError; - -export const getAcceptOrgInviteApiV1OrganizationsInvitesAcceptPostUrl = () => { - return `/api/v1/organizations/invites/accept`; -}; - -export const acceptOrgInviteApiV1OrganizationsInvitesAcceptPost = async ( - organizationInviteAccept: OrganizationInviteAccept, - options?: RequestInit, -): Promise => { - return customFetch( - getAcceptOrgInviteApiV1OrganizationsInvitesAcceptPostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(organizationInviteAccept), - }, - ); -}; - -export const getAcceptOrgInviteApiV1OrganizationsInvitesAcceptPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: OrganizationInviteAccept }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: OrganizationInviteAccept }, - TContext - > => { - const mutationKey = ["acceptOrgInviteApiV1OrganizationsInvitesAcceptPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType - >, - { data: OrganizationInviteAccept } - > = (props) => { - const { data } = props ?? {}; - - return acceptOrgInviteApiV1OrganizationsInvitesAcceptPost( - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type AcceptOrgInviteApiV1OrganizationsInvitesAcceptPostMutationResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type AcceptOrgInviteApiV1OrganizationsInvitesAcceptPostMutationBody = - OrganizationInviteAccept; -export type AcceptOrgInviteApiV1OrganizationsInvitesAcceptPostMutationError = - HTTPValidationError; - -/** - * @summary Accept Org Invite - */ -export const useAcceptOrgInviteApiV1OrganizationsInvitesAcceptPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: OrganizationInviteAccept }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { data: OrganizationInviteAccept }, - TContext -> => { - return useMutation( - getAcceptOrgInviteApiV1OrganizationsInvitesAcceptPostMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Delete the active organization and related entities. - * @summary Delete My Org - */ -export type deleteMyOrgApiV1OrganizationsMeDeleteResponse200 = { - data: OkResponse; - status: 200; -}; - -export type deleteMyOrgApiV1OrganizationsMeDeleteResponseSuccess = - deleteMyOrgApiV1OrganizationsMeDeleteResponse200 & { - headers: Headers; - }; -export type deleteMyOrgApiV1OrganizationsMeDeleteResponse = - deleteMyOrgApiV1OrganizationsMeDeleteResponseSuccess; - -export const getDeleteMyOrgApiV1OrganizationsMeDeleteUrl = () => { - return `/api/v1/organizations/me`; -}; - -export const deleteMyOrgApiV1OrganizationsMeDelete = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getDeleteMyOrgApiV1OrganizationsMeDeleteUrl(), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getDeleteMyOrgApiV1OrganizationsMeDeleteMutationOptions = < - TError = unknown, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - void, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - void, - TContext -> => { - const mutationKey = ["deleteMyOrgApiV1OrganizationsMeDelete"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - void - > = () => { - return deleteMyOrgApiV1OrganizationsMeDelete(requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type DeleteMyOrgApiV1OrganizationsMeDeleteMutationResult = NonNullable< - Awaited> ->; - -export type DeleteMyOrgApiV1OrganizationsMeDeleteMutationError = unknown; - -/** - * @summary Delete My Org - */ -export const useDeleteMyOrgApiV1OrganizationsMeDelete = < - TError = unknown, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - void, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - void, - TContext -> => { - return useMutation( - getDeleteMyOrgApiV1OrganizationsMeDeleteMutationOptions(options), - queryClient, - ); -}; -/** - * Return the caller's active organization. - * @summary Get My Org - */ -export type getMyOrgApiV1OrganizationsMeGetResponse200 = { - data: OrganizationRead; - status: 200; -}; - -export type getMyOrgApiV1OrganizationsMeGetResponseSuccess = - getMyOrgApiV1OrganizationsMeGetResponse200 & { - headers: Headers; - }; -export type getMyOrgApiV1OrganizationsMeGetResponse = - getMyOrgApiV1OrganizationsMeGetResponseSuccess; - -export const getGetMyOrgApiV1OrganizationsMeGetUrl = () => { - return `/api/v1/organizations/me`; -}; - -export const getMyOrgApiV1OrganizationsMeGet = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getGetMyOrgApiV1OrganizationsMeGetUrl(), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetMyOrgApiV1OrganizationsMeGetQueryKey = () => { - return [`/api/v1/organizations/me`] as const; -}; - -export const getGetMyOrgApiV1OrganizationsMeGetQueryOptions = < - TData = Awaited>, - TError = unknown, ->(options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getGetMyOrgApiV1OrganizationsMeGetQueryKey(); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getMyOrgApiV1OrganizationsMeGet({ signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetMyOrgApiV1OrganizationsMeGetQueryResult = NonNullable< - Awaited> ->; -export type GetMyOrgApiV1OrganizationsMeGetQueryError = unknown; - -export function useGetMyOrgApiV1OrganizationsMeGet< - TData = Awaited>, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetMyOrgApiV1OrganizationsMeGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetMyOrgApiV1OrganizationsMeGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get My Org - */ - -export function useGetMyOrgApiV1OrganizationsMeGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getGetMyOrgApiV1OrganizationsMeGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Set the caller's active organization. - * @summary Set Active Org - */ -export type setActiveOrgApiV1OrganizationsMeActivePatchResponse200 = { - data: OrganizationRead; - status: 200; -}; - -export type setActiveOrgApiV1OrganizationsMeActivePatchResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type setActiveOrgApiV1OrganizationsMeActivePatchResponseSuccess = - setActiveOrgApiV1OrganizationsMeActivePatchResponse200 & { - headers: Headers; - }; -export type setActiveOrgApiV1OrganizationsMeActivePatchResponseError = - setActiveOrgApiV1OrganizationsMeActivePatchResponse422 & { - headers: Headers; - }; - -export type setActiveOrgApiV1OrganizationsMeActivePatchResponse = - | setActiveOrgApiV1OrganizationsMeActivePatchResponseSuccess - | setActiveOrgApiV1OrganizationsMeActivePatchResponseError; - -export const getSetActiveOrgApiV1OrganizationsMeActivePatchUrl = () => { - return `/api/v1/organizations/me/active`; -}; - -export const setActiveOrgApiV1OrganizationsMeActivePatch = async ( - organizationActiveUpdate: OrganizationActiveUpdate, - options?: RequestInit, -): Promise => { - return customFetch( - getSetActiveOrgApiV1OrganizationsMeActivePatchUrl(), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(organizationActiveUpdate), - }, - ); -}; - -export const getSetActiveOrgApiV1OrganizationsMeActivePatchMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: OrganizationActiveUpdate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { data: OrganizationActiveUpdate }, - TContext -> => { - const mutationKey = ["setActiveOrgApiV1OrganizationsMeActivePatch"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { data: OrganizationActiveUpdate } - > = (props) => { - const { data } = props ?? {}; - - return setActiveOrgApiV1OrganizationsMeActivePatch(data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type SetActiveOrgApiV1OrganizationsMeActivePatchMutationResult = - NonNullable< - Awaited> - >; -export type SetActiveOrgApiV1OrganizationsMeActivePatchMutationBody = - OrganizationActiveUpdate; -export type SetActiveOrgApiV1OrganizationsMeActivePatchMutationError = - HTTPValidationError; - -/** - * @summary Set Active Org - */ -export const useSetActiveOrgApiV1OrganizationsMeActivePatch = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: OrganizationActiveUpdate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: OrganizationActiveUpdate }, - TContext -> => { - return useMutation( - getSetActiveOrgApiV1OrganizationsMeActivePatchMutationOptions(options), - queryClient, - ); -}; -/** - * List pending invites for the active organization. - * @summary List Org Invites - */ -export type listOrgInvitesApiV1OrganizationsMeInvitesGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedOrganizationInviteRead; - status: 200; -}; - -export type listOrgInvitesApiV1OrganizationsMeInvitesGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listOrgInvitesApiV1OrganizationsMeInvitesGetResponseSuccess = - listOrgInvitesApiV1OrganizationsMeInvitesGetResponse200 & { - headers: Headers; - }; -export type listOrgInvitesApiV1OrganizationsMeInvitesGetResponseError = - listOrgInvitesApiV1OrganizationsMeInvitesGetResponse422 & { - headers: Headers; - }; - -export type listOrgInvitesApiV1OrganizationsMeInvitesGetResponse = - | listOrgInvitesApiV1OrganizationsMeInvitesGetResponseSuccess - | listOrgInvitesApiV1OrganizationsMeInvitesGetResponseError; - -export const getListOrgInvitesApiV1OrganizationsMeInvitesGetUrl = ( - params?: ListOrgInvitesApiV1OrganizationsMeInvitesGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/organizations/me/invites?${stringifiedParams}` - : `/api/v1/organizations/me/invites`; -}; - -export const listOrgInvitesApiV1OrganizationsMeInvitesGet = async ( - params?: ListOrgInvitesApiV1OrganizationsMeInvitesGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListOrgInvitesApiV1OrganizationsMeInvitesGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListOrgInvitesApiV1OrganizationsMeInvitesGetQueryKey = ( - params?: ListOrgInvitesApiV1OrganizationsMeInvitesGetParams, -) => { - return [ - `/api/v1/organizations/me/invites`, - ...(params ? [params] : []), - ] as const; -}; - -export const getListOrgInvitesApiV1OrganizationsMeInvitesGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListOrgInvitesApiV1OrganizationsMeInvitesGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListOrgInvitesApiV1OrganizationsMeInvitesGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listOrgInvitesApiV1OrganizationsMeInvitesGet(params, { - signal, - ...requestOptions, - }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListOrgInvitesApiV1OrganizationsMeInvitesGetQueryResult = - NonNullable< - Awaited> - >; -export type ListOrgInvitesApiV1OrganizationsMeInvitesGetQueryError = - HTTPValidationError; - -export function useListOrgInvitesApiV1OrganizationsMeInvitesGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: undefined | ListOrgInvitesApiV1OrganizationsMeInvitesGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListOrgInvitesApiV1OrganizationsMeInvitesGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListOrgInvitesApiV1OrganizationsMeInvitesGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListOrgInvitesApiV1OrganizationsMeInvitesGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListOrgInvitesApiV1OrganizationsMeInvitesGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Org Invites - */ - -export function useListOrgInvitesApiV1OrganizationsMeInvitesGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListOrgInvitesApiV1OrganizationsMeInvitesGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListOrgInvitesApiV1OrganizationsMeInvitesGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create an organization invite for an email address. - * @summary Create Org Invite - */ -export type createOrgInviteApiV1OrganizationsMeInvitesPostResponse200 = { - data: OrganizationInviteRead; - status: 200; -}; - -export type createOrgInviteApiV1OrganizationsMeInvitesPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createOrgInviteApiV1OrganizationsMeInvitesPostResponseSuccess = - createOrgInviteApiV1OrganizationsMeInvitesPostResponse200 & { - headers: Headers; - }; -export type createOrgInviteApiV1OrganizationsMeInvitesPostResponseError = - createOrgInviteApiV1OrganizationsMeInvitesPostResponse422 & { - headers: Headers; - }; - -export type createOrgInviteApiV1OrganizationsMeInvitesPostResponse = - | createOrgInviteApiV1OrganizationsMeInvitesPostResponseSuccess - | createOrgInviteApiV1OrganizationsMeInvitesPostResponseError; - -export const getCreateOrgInviteApiV1OrganizationsMeInvitesPostUrl = () => { - return `/api/v1/organizations/me/invites`; -}; - -export const createOrgInviteApiV1OrganizationsMeInvitesPost = async ( - organizationInviteCreate: OrganizationInviteCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateOrgInviteApiV1OrganizationsMeInvitesPostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(organizationInviteCreate), - }, - ); -}; - -export const getCreateOrgInviteApiV1OrganizationsMeInvitesPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: OrganizationInviteCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited>, - TError, - { data: OrganizationInviteCreate }, - TContext - > => { - const mutationKey = ["createOrgInviteApiV1OrganizationsMeInvitesPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType - >, - { data: OrganizationInviteCreate } - > = (props) => { - const { data } = props ?? {}; - - return createOrgInviteApiV1OrganizationsMeInvitesPost( - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type CreateOrgInviteApiV1OrganizationsMeInvitesPostMutationResult = - NonNullable< - Awaited> - >; -export type CreateOrgInviteApiV1OrganizationsMeInvitesPostMutationBody = - OrganizationInviteCreate; -export type CreateOrgInviteApiV1OrganizationsMeInvitesPostMutationError = - HTTPValidationError; - -/** - * @summary Create Org Invite - */ -export const useCreateOrgInviteApiV1OrganizationsMeInvitesPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: OrganizationInviteCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: OrganizationInviteCreate }, - TContext -> => { - return useMutation( - getCreateOrgInviteApiV1OrganizationsMeInvitesPostMutationOptions(options), - queryClient, - ); -}; -/** - * Revoke a pending invite from the active organization. - * @summary Revoke Org Invite - */ -export type revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteResponse200 = - { - data: OrganizationInviteRead; - status: 200; - }; - -export type revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteResponseSuccess = - revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteResponse200 & { - headers: Headers; - }; -export type revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteResponseError = - revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteResponse422 & { - headers: Headers; - }; - -export type revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteResponse = - | revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteResponseSuccess - | revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteResponseError; - -export const getRevokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteUrl = ( - inviteId: string, -) => { - return `/api/v1/organizations/me/invites/${inviteId}`; -}; - -export const revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDelete = async ( - inviteId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getRevokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteUrl(inviteId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getRevokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDelete - > - >, - TError, - { inviteId: string }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDelete - > - >, - TError, - { inviteId: string }, - TContext - > => { - const mutationKey = [ - "revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDelete", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDelete - > - >, - { inviteId: string } - > = (props) => { - const { inviteId } = props ?? {}; - - return revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDelete( - inviteId, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type RevokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDelete - > - > - >; - -export type RevokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Revoke Org Invite - */ -export const useRevokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof revokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDelete - > - >, - TError, - { inviteId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { inviteId: string }, - TContext -> => { - return useMutation( - getRevokeOrgInviteApiV1OrganizationsMeInvitesInviteIdDeleteMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * List organizations where the current user is a member. - * @summary List My Organizations - */ -export type listMyOrganizationsApiV1OrganizationsMeListGetResponse200 = { - data: OrganizationListItem[]; - status: 200; -}; - -export type listMyOrganizationsApiV1OrganizationsMeListGetResponseSuccess = - listMyOrganizationsApiV1OrganizationsMeListGetResponse200 & { - headers: Headers; - }; -export type listMyOrganizationsApiV1OrganizationsMeListGetResponse = - listMyOrganizationsApiV1OrganizationsMeListGetResponseSuccess; - -export const getListMyOrganizationsApiV1OrganizationsMeListGetUrl = () => { - return `/api/v1/organizations/me/list`; -}; - -export const listMyOrganizationsApiV1OrganizationsMeListGet = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getListMyOrganizationsApiV1OrganizationsMeListGetUrl(), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListMyOrganizationsApiV1OrganizationsMeListGetQueryKey = () => { - return [`/api/v1/organizations/me/list`] as const; -}; - -export const getListMyOrganizationsApiV1OrganizationsMeListGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = unknown, ->(options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListMyOrganizationsApiV1OrganizationsMeListGetQueryKey(); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listMyOrganizationsApiV1OrganizationsMeListGet({ - signal, - ...requestOptions, - }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListMyOrganizationsApiV1OrganizationsMeListGetQueryResult = - NonNullable< - Awaited> - >; -export type ListMyOrganizationsApiV1OrganizationsMeListGetQueryError = unknown; - -export function useListMyOrganizationsApiV1OrganizationsMeListGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListMyOrganizationsApiV1OrganizationsMeListGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListMyOrganizationsApiV1OrganizationsMeListGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List My Organizations - */ - -export function useListMyOrganizationsApiV1OrganizationsMeListGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListMyOrganizationsApiV1OrganizationsMeListGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Get the caller's membership record in the active organization. - * @summary Get My Membership - */ -export type getMyMembershipApiV1OrganizationsMeMemberGetResponse200 = { - data: OrganizationMemberRead; - status: 200; -}; - -export type getMyMembershipApiV1OrganizationsMeMemberGetResponseSuccess = - getMyMembershipApiV1OrganizationsMeMemberGetResponse200 & { - headers: Headers; - }; -export type getMyMembershipApiV1OrganizationsMeMemberGetResponse = - getMyMembershipApiV1OrganizationsMeMemberGetResponseSuccess; - -export const getGetMyMembershipApiV1OrganizationsMeMemberGetUrl = () => { - return `/api/v1/organizations/me/member`; -}; - -export const getMyMembershipApiV1OrganizationsMeMemberGet = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getGetMyMembershipApiV1OrganizationsMeMemberGetUrl(), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetMyMembershipApiV1OrganizationsMeMemberGetQueryKey = () => { - return [`/api/v1/organizations/me/member`] as const; -}; - -export const getGetMyMembershipApiV1OrganizationsMeMemberGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = unknown, ->(options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetMyMembershipApiV1OrganizationsMeMemberGetQueryKey(); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getMyMembershipApiV1OrganizationsMeMemberGet({ signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetMyMembershipApiV1OrganizationsMeMemberGetQueryResult = - NonNullable< - Awaited> - >; -export type GetMyMembershipApiV1OrganizationsMeMemberGetQueryError = unknown; - -export function useGetMyMembershipApiV1OrganizationsMeMemberGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetMyMembershipApiV1OrganizationsMeMemberGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetMyMembershipApiV1OrganizationsMeMemberGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get My Membership - */ - -export function useGetMyMembershipApiV1OrganizationsMeMemberGet< - TData = Awaited< - ReturnType - >, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetMyMembershipApiV1OrganizationsMeMemberGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * List members for the active organization. - * @summary List Org Members - */ -export type listOrgMembersApiV1OrganizationsMeMembersGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedOrganizationMemberRead; - status: 200; -}; - -export type listOrgMembersApiV1OrganizationsMeMembersGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listOrgMembersApiV1OrganizationsMeMembersGetResponseSuccess = - listOrgMembersApiV1OrganizationsMeMembersGetResponse200 & { - headers: Headers; - }; -export type listOrgMembersApiV1OrganizationsMeMembersGetResponseError = - listOrgMembersApiV1OrganizationsMeMembersGetResponse422 & { - headers: Headers; - }; - -export type listOrgMembersApiV1OrganizationsMeMembersGetResponse = - | listOrgMembersApiV1OrganizationsMeMembersGetResponseSuccess - | listOrgMembersApiV1OrganizationsMeMembersGetResponseError; - -export const getListOrgMembersApiV1OrganizationsMeMembersGetUrl = ( - params?: ListOrgMembersApiV1OrganizationsMeMembersGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/organizations/me/members?${stringifiedParams}` - : `/api/v1/organizations/me/members`; -}; - -export const listOrgMembersApiV1OrganizationsMeMembersGet = async ( - params?: ListOrgMembersApiV1OrganizationsMeMembersGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListOrgMembersApiV1OrganizationsMeMembersGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListOrgMembersApiV1OrganizationsMeMembersGetQueryKey = ( - params?: ListOrgMembersApiV1OrganizationsMeMembersGetParams, -) => { - return [ - `/api/v1/organizations/me/members`, - ...(params ? [params] : []), - ] as const; -}; - -export const getListOrgMembersApiV1OrganizationsMeMembersGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListOrgMembersApiV1OrganizationsMeMembersGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListOrgMembersApiV1OrganizationsMeMembersGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listOrgMembersApiV1OrganizationsMeMembersGet(params, { - signal, - ...requestOptions, - }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListOrgMembersApiV1OrganizationsMeMembersGetQueryResult = - NonNullable< - Awaited> - >; -export type ListOrgMembersApiV1OrganizationsMeMembersGetQueryError = - HTTPValidationError; - -export function useListOrgMembersApiV1OrganizationsMeMembersGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: undefined | ListOrgMembersApiV1OrganizationsMeMembersGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListOrgMembersApiV1OrganizationsMeMembersGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListOrgMembersApiV1OrganizationsMeMembersGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListOrgMembersApiV1OrganizationsMeMembersGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListOrgMembersApiV1OrganizationsMeMembersGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Org Members - */ - -export function useListOrgMembersApiV1OrganizationsMeMembersGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params?: ListOrgMembersApiV1OrganizationsMeMembersGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListOrgMembersApiV1OrganizationsMeMembersGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Remove a member from the active organization. - * @summary Remove Org Member - */ -export type removeOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteResponse200 = - { - data: OkResponse; - status: 200; - }; - -export type removeOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type removeOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteResponseSuccess = - removeOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteResponse200 & { - headers: Headers; - }; -export type removeOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteResponseError = - removeOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteResponse422 & { - headers: Headers; - }; - -export type removeOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteResponse = - | removeOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteResponseSuccess - | removeOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteResponseError; - -export const getRemoveOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteUrl = ( - memberId: string, -) => { - return `/api/v1/organizations/me/members/${memberId}`; -}; - -export const removeOrgMemberApiV1OrganizationsMeMembersMemberIdDelete = async ( - memberId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getRemoveOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteUrl(memberId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getRemoveOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof removeOrgMemberApiV1OrganizationsMeMembersMemberIdDelete - > - >, - TError, - { memberId: string }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof removeOrgMemberApiV1OrganizationsMeMembersMemberIdDelete - > - >, - TError, - { memberId: string }, - TContext - > => { - const mutationKey = [ - "removeOrgMemberApiV1OrganizationsMeMembersMemberIdDelete", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof removeOrgMemberApiV1OrganizationsMeMembersMemberIdDelete - > - >, - { memberId: string } - > = (props) => { - const { memberId } = props ?? {}; - - return removeOrgMemberApiV1OrganizationsMeMembersMemberIdDelete( - memberId, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type RemoveOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof removeOrgMemberApiV1OrganizationsMeMembersMemberIdDelete - > - > - >; - -export type RemoveOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Remove Org Member - */ -export const useRemoveOrgMemberApiV1OrganizationsMeMembersMemberIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof removeOrgMemberApiV1OrganizationsMeMembersMemberIdDelete - > - >, - TError, - { memberId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { memberId: string }, - TContext -> => { - return useMutation( - getRemoveOrgMemberApiV1OrganizationsMeMembersMemberIdDeleteMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Get a specific organization member by id. - * @summary Get Org Member - */ -export type getOrgMemberApiV1OrganizationsMeMembersMemberIdGetResponse200 = { - data: OrganizationMemberRead; - status: 200; -}; - -export type getOrgMemberApiV1OrganizationsMeMembersMemberIdGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getOrgMemberApiV1OrganizationsMeMembersMemberIdGetResponseSuccess = - getOrgMemberApiV1OrganizationsMeMembersMemberIdGetResponse200 & { - headers: Headers; - }; -export type getOrgMemberApiV1OrganizationsMeMembersMemberIdGetResponseError = - getOrgMemberApiV1OrganizationsMeMembersMemberIdGetResponse422 & { - headers: Headers; - }; - -export type getOrgMemberApiV1OrganizationsMeMembersMemberIdGetResponse = - | getOrgMemberApiV1OrganizationsMeMembersMemberIdGetResponseSuccess - | getOrgMemberApiV1OrganizationsMeMembersMemberIdGetResponseError; - -export const getGetOrgMemberApiV1OrganizationsMeMembersMemberIdGetUrl = ( - memberId: string, -) => { - return `/api/v1/organizations/me/members/${memberId}`; -}; - -export const getOrgMemberApiV1OrganizationsMeMembersMemberIdGet = async ( - memberId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetOrgMemberApiV1OrganizationsMeMembersMemberIdGetUrl(memberId), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetOrgMemberApiV1OrganizationsMeMembersMemberIdGetQueryKey = ( - memberId: string, -) => { - return [`/api/v1/organizations/me/members/${memberId}`] as const; -}; - -export const getGetOrgMemberApiV1OrganizationsMeMembersMemberIdGetQueryOptions = - < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, - >( - memberId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof getOrgMemberApiV1OrganizationsMeMembersMemberIdGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetOrgMemberApiV1OrganizationsMeMembersMemberIdGetQueryKey(memberId); - - const queryFn: QueryFunction< - Awaited< - ReturnType - > - > = ({ signal }) => - getOrgMemberApiV1OrganizationsMeMembersMemberIdGet(memberId, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!memberId, - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type GetOrgMemberApiV1OrganizationsMeMembersMemberIdGetQueryResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type GetOrgMemberApiV1OrganizationsMeMembersMemberIdGetQueryError = - HTTPValidationError; - -export function useGetOrgMemberApiV1OrganizationsMeMembersMemberIdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - memberId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getOrgMemberApiV1OrganizationsMeMembersMemberIdGet - > - >, - TError, - Awaited< - ReturnType< - typeof getOrgMemberApiV1OrganizationsMeMembersMemberIdGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetOrgMemberApiV1OrganizationsMeMembersMemberIdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - memberId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof getOrgMemberApiV1OrganizationsMeMembersMemberIdGet - > - >, - TError, - Awaited< - ReturnType< - typeof getOrgMemberApiV1OrganizationsMeMembersMemberIdGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetOrgMemberApiV1OrganizationsMeMembersMemberIdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - memberId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Org Member - */ - -export function useGetOrgMemberApiV1OrganizationsMeMembersMemberIdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - memberId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetOrgMemberApiV1OrganizationsMeMembersMemberIdGetQueryOptions( - memberId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Update a member's role in the organization. - * @summary Update Org Member - */ -export type updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchResponse200 = - { - data: OrganizationMemberRead; - status: 200; - }; - -export type updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchResponseSuccess = - updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchResponse200 & { - headers: Headers; - }; -export type updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchResponseError = - updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchResponse422 & { - headers: Headers; - }; - -export type updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchResponse = - | updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchResponseSuccess - | updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchResponseError; - -export const getUpdateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchUrl = ( - memberId: string, -) => { - return `/api/v1/organizations/me/members/${memberId}`; -}; - -export const updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatch = async ( - memberId: string, - organizationMemberUpdate: OrganizationMemberUpdate, - options?: RequestInit, -): Promise => { - return customFetch( - getUpdateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchUrl(memberId), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(organizationMemberUpdate), - }, - ); -}; - -export const getUpdateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatch - > - >, - TError, - { memberId: string; data: OrganizationMemberUpdate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { memberId: string; data: OrganizationMemberUpdate }, - TContext - > => { - const mutationKey = [ - "updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatch", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatch - > - >, - { memberId: string; data: OrganizationMemberUpdate } - > = (props) => { - const { memberId, data } = props ?? {}; - - return updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatch( - memberId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type UpdateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchMutationResult = - NonNullable< - Awaited< - ReturnType - > - >; -export type UpdateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchMutationBody = - OrganizationMemberUpdate; -export type UpdateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchMutationError = - HTTPValidationError; - -/** - * @summary Update Org Member - */ -export const useUpdateOrgMemberApiV1OrganizationsMeMembersMemberIdPatch = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof updateOrgMemberApiV1OrganizationsMeMembersMemberIdPatch - > - >, - TError, - { memberId: string; data: OrganizationMemberUpdate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { memberId: string; data: OrganizationMemberUpdate }, - TContext -> => { - return useMutation( - getUpdateOrgMemberApiV1OrganizationsMeMembersMemberIdPatchMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Update board-level access settings for a member. - * @summary Update Member Access - */ -export type updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutResponse200 = - { - data: OrganizationMemberRead; - status: 200; - }; - -export type updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutResponseSuccess = - updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutResponse200 & { - headers: Headers; - }; -export type updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutResponseError = - updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutResponse422 & { - headers: Headers; - }; - -export type updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutResponse = - - | updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutResponseSuccess - | updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutResponseError; - -export const getUpdateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutUrl = - (memberId: string) => { - return `/api/v1/organizations/me/members/${memberId}/access`; - }; - -export const updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPut = - async ( - memberId: string, - organizationMemberAccessUpdate: OrganizationMemberAccessUpdate, - options?: RequestInit, - ): Promise => { - return customFetch( - getUpdateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutUrl( - memberId, - ), - { - ...options, - method: "PUT", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(organizationMemberAccessUpdate), - }, - ); - }; - -export const getUpdateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPut - > - >, - TError, - { memberId: string; data: OrganizationMemberAccessUpdate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPut - > - >, - TError, - { memberId: string; data: OrganizationMemberAccessUpdate }, - TContext - > => { - const mutationKey = [ - "updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPut", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPut - > - >, - { memberId: string; data: OrganizationMemberAccessUpdate } - > = (props) => { - const { memberId, data } = props ?? {}; - - return updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPut( - memberId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type UpdateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPut - > - > - >; -export type UpdateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutMutationBody = - OrganizationMemberAccessUpdate; -export type UpdateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutMutationError = - HTTPValidationError; - -/** - * @summary Update Member Access - */ -export const useUpdateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPut = - ( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPut - > - >, - TError, - { memberId: string; data: OrganizationMemberAccessUpdate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, - ): UseMutationResult< - Awaited< - ReturnType< - typeof updateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPut - > - >, - TError, - { memberId: string; data: OrganizationMemberAccessUpdate }, - TContext - > => { - return useMutation( - getUpdateMemberAccessApiV1OrganizationsMeMembersMemberIdAccessPutMutationOptions( - options, - ), - queryClient, - ); - }; diff --git a/src/frontend/src/api/generated/skills-marketplace/skills-marketplace.ts b/src/frontend/src/api/generated/skills-marketplace/skills-marketplace.ts deleted file mode 100644 index 9dcea69..0000000 --- a/src/frontend/src/api/generated/skills-marketplace/skills-marketplace.ts +++ /dev/null @@ -1,939 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - HTTPValidationError, - InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams, - ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - MarketplaceSkillActionResponse, - MarketplaceSkillCardRead, - MarketplaceSkillCreate, - MarketplaceSkillRead, - OkResponse, - UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List marketplace cards for an org and annotate install state for a gateway. - * @summary List Marketplace Skills - */ -export type listMarketplaceSkillsApiV1SkillsMarketplaceGetResponse200 = { - data: MarketplaceSkillCardRead[]; - status: 200; -}; - -export type listMarketplaceSkillsApiV1SkillsMarketplaceGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listMarketplaceSkillsApiV1SkillsMarketplaceGetResponseSuccess = - listMarketplaceSkillsApiV1SkillsMarketplaceGetResponse200 & { - headers: Headers; - }; -export type listMarketplaceSkillsApiV1SkillsMarketplaceGetResponseError = - listMarketplaceSkillsApiV1SkillsMarketplaceGetResponse422 & { - headers: Headers; - }; - -export type listMarketplaceSkillsApiV1SkillsMarketplaceGetResponse = - | listMarketplaceSkillsApiV1SkillsMarketplaceGetResponseSuccess - | listMarketplaceSkillsApiV1SkillsMarketplaceGetResponseError; - -export const getListMarketplaceSkillsApiV1SkillsMarketplaceGetUrl = ( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/skills/marketplace?${stringifiedParams}` - : `/api/v1/skills/marketplace`; -}; - -export const listMarketplaceSkillsApiV1SkillsMarketplaceGet = async ( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListMarketplaceSkillsApiV1SkillsMarketplaceGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListMarketplaceSkillsApiV1SkillsMarketplaceGetQueryKey = ( - params?: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, -) => { - return [`/api/v1/skills/marketplace`, ...(params ? [params] : [])] as const; -}; - -export const getListMarketplaceSkillsApiV1SkillsMarketplaceGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListMarketplaceSkillsApiV1SkillsMarketplaceGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listMarketplaceSkillsApiV1SkillsMarketplaceGet(params, { - signal, - ...requestOptions, - }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListMarketplaceSkillsApiV1SkillsMarketplaceGetQueryResult = - NonNullable< - Awaited> - >; -export type ListMarketplaceSkillsApiV1SkillsMarketplaceGetQueryError = - HTTPValidationError; - -export function useListMarketplaceSkillsApiV1SkillsMarketplaceGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListMarketplaceSkillsApiV1SkillsMarketplaceGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListMarketplaceSkillsApiV1SkillsMarketplaceGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Marketplace Skills - */ - -export function useListMarketplaceSkillsApiV1SkillsMarketplaceGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListMarketplaceSkillsApiV1SkillsMarketplaceGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Register a skill source URL in the organization's marketplace catalog. - * @summary Create Marketplace Skill - */ -export type createMarketplaceSkillApiV1SkillsMarketplacePostResponse200 = { - data: MarketplaceSkillRead; - status: 200; -}; - -export type createMarketplaceSkillApiV1SkillsMarketplacePostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createMarketplaceSkillApiV1SkillsMarketplacePostResponseSuccess = - createMarketplaceSkillApiV1SkillsMarketplacePostResponse200 & { - headers: Headers; - }; -export type createMarketplaceSkillApiV1SkillsMarketplacePostResponseError = - createMarketplaceSkillApiV1SkillsMarketplacePostResponse422 & { - headers: Headers; - }; - -export type createMarketplaceSkillApiV1SkillsMarketplacePostResponse = - | createMarketplaceSkillApiV1SkillsMarketplacePostResponseSuccess - | createMarketplaceSkillApiV1SkillsMarketplacePostResponseError; - -export const getCreateMarketplaceSkillApiV1SkillsMarketplacePostUrl = () => { - return `/api/v1/skills/marketplace`; -}; - -export const createMarketplaceSkillApiV1SkillsMarketplacePost = async ( - marketplaceSkillCreate: MarketplaceSkillCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateMarketplaceSkillApiV1SkillsMarketplacePostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(marketplaceSkillCreate), - }, - ); -}; - -export const getCreateMarketplaceSkillApiV1SkillsMarketplacePostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: MarketplaceSkillCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: MarketplaceSkillCreate }, - TContext - > => { - const mutationKey = ["createMarketplaceSkillApiV1SkillsMarketplacePost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType - >, - { data: MarketplaceSkillCreate } - > = (props) => { - const { data } = props ?? {}; - - return createMarketplaceSkillApiV1SkillsMarketplacePost( - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type CreateMarketplaceSkillApiV1SkillsMarketplacePostMutationResult = - NonNullable< - Awaited> - >; -export type CreateMarketplaceSkillApiV1SkillsMarketplacePostMutationBody = - MarketplaceSkillCreate; -export type CreateMarketplaceSkillApiV1SkillsMarketplacePostMutationError = - HTTPValidationError; - -/** - * @summary Create Marketplace Skill - */ -export const useCreateMarketplaceSkillApiV1SkillsMarketplacePost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: MarketplaceSkillCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: MarketplaceSkillCreate }, - TContext -> => { - return useMutation( - getCreateMarketplaceSkillApiV1SkillsMarketplacePostMutationOptions(options), - queryClient, - ); -}; -/** - * Delete a marketplace catalog entry and any install records that reference it. - * @summary Delete Marketplace Skill - */ -export type deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponse200 = - { - data: OkResponse; - status: 200; - }; - -export type deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponseSuccess = - deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponseError = - deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponse = - | deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponseSuccess - | deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponseError; - -export const getDeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteUrl = ( - skillId: string, -) => { - return `/api/v1/skills/marketplace/${skillId}`; -}; - -export const deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete = async ( - skillId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getDeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteUrl(skillId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getDeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete - > - >, - TError, - { skillId: string }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete - > - >, - TError, - { skillId: string }, - TContext - > => { - const mutationKey = [ - "deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete - > - >, - { skillId: string } - > = (props) => { - const { skillId } = props ?? {}; - - return deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete( - skillId, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type DeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete - > - > - >; - -export type DeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Delete Marketplace Skill - */ -export const useDeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete - > - >, - TError, - { skillId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { skillId: string }, - TContext -> => { - return useMutation( - getDeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Install a marketplace skill by dispatching instructions to the gateway agent. - * @summary Install Marketplace Skill - */ -export type installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponse200 = - { - data: MarketplaceSkillActionResponse; - status: 200; - }; - -export type installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponseSuccess = - installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponse200 & { - headers: Headers; - }; -export type installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponseError = - installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponse422 & { - headers: Headers; - }; - -export type installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponse = - - | installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponseSuccess - | installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponseError; - -export const getInstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostUrl = - ( - skillId: string, - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams, - ) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append( - key, - value === null ? "null" : value.toString(), - ); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/skills/marketplace/${skillId}/install?${stringifiedParams}` - : `/api/v1/skills/marketplace/${skillId}/install`; - }; - -export const installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost = - async ( - skillId: string, - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams, - options?: RequestInit, - ): Promise => { - return customFetch( - getInstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostUrl( - skillId, - params, - ), - { - ...options, - method: "POST", - }, - ); - }; - -export const getInstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost - > - >, - TError, - { - skillId: string; - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams; - }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost - > - >, - TError, - { - skillId: string; - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams; - }, - TContext - > => { - const mutationKey = [ - "installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost - > - >, - { - skillId: string; - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams; - } - > = (props) => { - const { skillId, params } = props ?? {}; - - return installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost( - skillId, - params, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost - > - > - >; - -export type InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostMutationError = - HTTPValidationError; - -/** - * @summary Install Marketplace Skill - */ -export const useInstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost = - ( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost - > - >, - TError, - { - skillId: string; - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams; - }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, - ): UseMutationResult< - Awaited< - ReturnType< - typeof installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost - > - >, - TError, - { - skillId: string; - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams; - }, - TContext - > => { - return useMutation( - getInstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostMutationOptions( - options, - ), - queryClient, - ); - }; -/** - * Uninstall a marketplace skill by dispatching instructions to the gateway agent. - * @summary Uninstall Marketplace Skill - */ -export type uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponse200 = - { - data: MarketplaceSkillActionResponse; - status: 200; - }; - -export type uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponseSuccess = - uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponse200 & { - headers: Headers; - }; -export type uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponseError = - uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponse422 & { - headers: Headers; - }; - -export type uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponse = - - | uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponseSuccess - | uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponseError; - -export const getUninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostUrl = - ( - skillId: string, - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams, - ) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append( - key, - value === null ? "null" : value.toString(), - ); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/skills/marketplace/${skillId}/uninstall?${stringifiedParams}` - : `/api/v1/skills/marketplace/${skillId}/uninstall`; - }; - -export const uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost = - async ( - skillId: string, - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams, - options?: RequestInit, - ): Promise => { - return customFetch( - getUninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostUrl( - skillId, - params, - ), - { - ...options, - method: "POST", - }, - ); - }; - -export const getUninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost - > - >, - TError, - { - skillId: string; - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams; - }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost - > - >, - TError, - { - skillId: string; - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams; - }, - TContext - > => { - const mutationKey = [ - "uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost - > - >, - { - skillId: string; - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams; - } - > = (props) => { - const { skillId, params } = props ?? {}; - - return uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost( - skillId, - params, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost - > - > - >; - -export type UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostMutationError = - HTTPValidationError; - -/** - * @summary Uninstall Marketplace Skill - */ -export const useUninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost = - ( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost - > - >, - TError, - { - skillId: string; - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams; - }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, - ): UseMutationResult< - Awaited< - ReturnType< - typeof uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost - > - >, - TError, - { - skillId: string; - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams; - }, - TContext - > => { - return useMutation( - getUninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostMutationOptions( - options, - ), - queryClient, - ); - }; diff --git a/src/frontend/src/api/generated/skills/skills.ts b/src/frontend/src/api/generated/skills/skills.ts deleted file mode 100644 index 1e34e5e..0000000 --- a/src/frontend/src/api/generated/skills/skills.ts +++ /dev/null @@ -1,1810 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - HTTPValidationError, - InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams, - ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - MarketplaceSkillActionResponse, - MarketplaceSkillCardRead, - MarketplaceSkillCreate, - MarketplaceSkillRead, - OkResponse, - SkillPackCreate, - SkillPackRead, - SkillPackSyncResponse, - UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List marketplace cards for an org and annotate install state for a gateway. - * @summary List Marketplace Skills - */ -export type listMarketplaceSkillsApiV1SkillsMarketplaceGetResponse200 = { - data: MarketplaceSkillCardRead[]; - status: 200; -}; - -export type listMarketplaceSkillsApiV1SkillsMarketplaceGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listMarketplaceSkillsApiV1SkillsMarketplaceGetResponseSuccess = - listMarketplaceSkillsApiV1SkillsMarketplaceGetResponse200 & { - headers: Headers; - }; -export type listMarketplaceSkillsApiV1SkillsMarketplaceGetResponseError = - listMarketplaceSkillsApiV1SkillsMarketplaceGetResponse422 & { - headers: Headers; - }; - -export type listMarketplaceSkillsApiV1SkillsMarketplaceGetResponse = - | listMarketplaceSkillsApiV1SkillsMarketplaceGetResponseSuccess - | listMarketplaceSkillsApiV1SkillsMarketplaceGetResponseError; - -export const getListMarketplaceSkillsApiV1SkillsMarketplaceGetUrl = ( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/skills/marketplace?${stringifiedParams}` - : `/api/v1/skills/marketplace`; -}; - -export const listMarketplaceSkillsApiV1SkillsMarketplaceGet = async ( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListMarketplaceSkillsApiV1SkillsMarketplaceGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListMarketplaceSkillsApiV1SkillsMarketplaceGetQueryKey = ( - params?: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, -) => { - return [`/api/v1/skills/marketplace`, ...(params ? [params] : [])] as const; -}; - -export const getListMarketplaceSkillsApiV1SkillsMarketplaceGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListMarketplaceSkillsApiV1SkillsMarketplaceGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listMarketplaceSkillsApiV1SkillsMarketplaceGet(params, { - signal, - ...requestOptions, - }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListMarketplaceSkillsApiV1SkillsMarketplaceGetQueryResult = - NonNullable< - Awaited> - >; -export type ListMarketplaceSkillsApiV1SkillsMarketplaceGetQueryError = - HTTPValidationError; - -export function useListMarketplaceSkillsApiV1SkillsMarketplaceGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListMarketplaceSkillsApiV1SkillsMarketplaceGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListMarketplaceSkillsApiV1SkillsMarketplaceGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Marketplace Skills - */ - -export function useListMarketplaceSkillsApiV1SkillsMarketplaceGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - params: ListMarketplaceSkillsApiV1SkillsMarketplaceGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListMarketplaceSkillsApiV1SkillsMarketplaceGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Register or update a direct marketplace skill URL in the catalog. - * @summary Create Marketplace Skill - */ -export type createMarketplaceSkillApiV1SkillsMarketplacePostResponse200 = { - data: MarketplaceSkillRead; - status: 200; -}; - -export type createMarketplaceSkillApiV1SkillsMarketplacePostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createMarketplaceSkillApiV1SkillsMarketplacePostResponseSuccess = - createMarketplaceSkillApiV1SkillsMarketplacePostResponse200 & { - headers: Headers; - }; -export type createMarketplaceSkillApiV1SkillsMarketplacePostResponseError = - createMarketplaceSkillApiV1SkillsMarketplacePostResponse422 & { - headers: Headers; - }; - -export type createMarketplaceSkillApiV1SkillsMarketplacePostResponse = - | createMarketplaceSkillApiV1SkillsMarketplacePostResponseSuccess - | createMarketplaceSkillApiV1SkillsMarketplacePostResponseError; - -export const getCreateMarketplaceSkillApiV1SkillsMarketplacePostUrl = () => { - return `/api/v1/skills/marketplace`; -}; - -export const createMarketplaceSkillApiV1SkillsMarketplacePost = async ( - marketplaceSkillCreate: MarketplaceSkillCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateMarketplaceSkillApiV1SkillsMarketplacePostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(marketplaceSkillCreate), - }, - ); -}; - -export const getCreateMarketplaceSkillApiV1SkillsMarketplacePostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: MarketplaceSkillCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: MarketplaceSkillCreate }, - TContext - > => { - const mutationKey = ["createMarketplaceSkillApiV1SkillsMarketplacePost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType - >, - { data: MarketplaceSkillCreate } - > = (props) => { - const { data } = props ?? {}; - - return createMarketplaceSkillApiV1SkillsMarketplacePost( - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type CreateMarketplaceSkillApiV1SkillsMarketplacePostMutationResult = - NonNullable< - Awaited> - >; -export type CreateMarketplaceSkillApiV1SkillsMarketplacePostMutationBody = - MarketplaceSkillCreate; -export type CreateMarketplaceSkillApiV1SkillsMarketplacePostMutationError = - HTTPValidationError; - -/** - * @summary Create Marketplace Skill - */ -export const useCreateMarketplaceSkillApiV1SkillsMarketplacePost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType - >, - TError, - { data: MarketplaceSkillCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: MarketplaceSkillCreate }, - TContext -> => { - return useMutation( - getCreateMarketplaceSkillApiV1SkillsMarketplacePostMutationOptions(options), - queryClient, - ); -}; -/** - * Delete a marketplace catalog entry and any install records that reference it. - * @summary Delete Marketplace Skill - */ -export type deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponse200 = - { - data: OkResponse; - status: 200; - }; - -export type deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponseSuccess = - deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponseError = - deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponse = - | deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponseSuccess - | deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteResponseError; - -export const getDeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteUrl = ( - skillId: string, -) => { - return `/api/v1/skills/marketplace/${skillId}`; -}; - -export const deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete = async ( - skillId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getDeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteUrl(skillId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getDeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete - > - >, - TError, - { skillId: string }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete - > - >, - TError, - { skillId: string }, - TContext - > => { - const mutationKey = [ - "deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete - > - >, - { skillId: string } - > = (props) => { - const { skillId } = props ?? {}; - - return deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete( - skillId, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type DeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete - > - > - >; - -export type DeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Delete Marketplace Skill - */ -export const useDeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof deleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDelete - > - >, - TError, - { skillId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType - >, - TError, - { skillId: string }, - TContext -> => { - return useMutation( - getDeleteMarketplaceSkillApiV1SkillsMarketplaceSkillIdDeleteMutationOptions( - options, - ), - queryClient, - ); -}; -/** - * Install a marketplace skill by dispatching instructions to the gateway agent. - * @summary Install Marketplace Skill - */ -export type installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponse200 = - { - data: MarketplaceSkillActionResponse; - status: 200; - }; - -export type installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponseSuccess = - installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponse200 & { - headers: Headers; - }; -export type installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponseError = - installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponse422 & { - headers: Headers; - }; - -export type installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponse = - - | installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponseSuccess - | installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostResponseError; - -export const getInstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostUrl = - ( - skillId: string, - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams, - ) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append( - key, - value === null ? "null" : value.toString(), - ); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/skills/marketplace/${skillId}/install?${stringifiedParams}` - : `/api/v1/skills/marketplace/${skillId}/install`; - }; - -export const installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost = - async ( - skillId: string, - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams, - options?: RequestInit, - ): Promise => { - return customFetch( - getInstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostUrl( - skillId, - params, - ), - { - ...options, - method: "POST", - }, - ); - }; - -export const getInstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost - > - >, - TError, - { - skillId: string; - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams; - }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost - > - >, - TError, - { - skillId: string; - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams; - }, - TContext - > => { - const mutationKey = [ - "installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost - > - >, - { - skillId: string; - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams; - } - > = (props) => { - const { skillId, params } = props ?? {}; - - return installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost( - skillId, - params, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost - > - > - >; - -export type InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostMutationError = - HTTPValidationError; - -/** - * @summary Install Marketplace Skill - */ -export const useInstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost = - ( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost - > - >, - TError, - { - skillId: string; - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams; - }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, - ): UseMutationResult< - Awaited< - ReturnType< - typeof installMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPost - > - >, - TError, - { - skillId: string; - params: InstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostParams; - }, - TContext - > => { - return useMutation( - getInstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdInstallPostMutationOptions( - options, - ), - queryClient, - ); - }; -/** - * Uninstall a marketplace skill by dispatching instructions to the gateway agent. - * @summary Uninstall Marketplace Skill - */ -export type uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponse200 = - { - data: MarketplaceSkillActionResponse; - status: 200; - }; - -export type uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponseSuccess = - uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponse200 & { - headers: Headers; - }; -export type uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponseError = - uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponse422 & { - headers: Headers; - }; - -export type uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponse = - - | uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponseSuccess - | uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostResponseError; - -export const getUninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostUrl = - ( - skillId: string, - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams, - ) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append( - key, - value === null ? "null" : value.toString(), - ); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/skills/marketplace/${skillId}/uninstall?${stringifiedParams}` - : `/api/v1/skills/marketplace/${skillId}/uninstall`; - }; - -export const uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost = - async ( - skillId: string, - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams, - options?: RequestInit, - ): Promise => { - return customFetch( - getUninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostUrl( - skillId, - params, - ), - { - ...options, - method: "POST", - }, - ); - }; - -export const getUninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost - > - >, - TError, - { - skillId: string; - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams; - }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost - > - >, - TError, - { - skillId: string; - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams; - }, - TContext - > => { - const mutationKey = [ - "uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost - > - >, - { - skillId: string; - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams; - } - > = (props) => { - const { skillId, params } = props ?? {}; - - return uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost( - skillId, - params, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost - > - > - >; - -export type UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostMutationError = - HTTPValidationError; - -/** - * @summary Uninstall Marketplace Skill - */ -export const useUninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost = - ( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost - > - >, - TError, - { - skillId: string; - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams; - }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, - ): UseMutationResult< - Awaited< - ReturnType< - typeof uninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPost - > - >, - TError, - { - skillId: string; - params: UninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostParams; - }, - TContext - > => { - return useMutation( - getUninstallMarketplaceSkillApiV1SkillsMarketplaceSkillIdUninstallPostMutationOptions( - options, - ), - queryClient, - ); - }; -/** - * List skill packs configured for the organization. - * @summary List Skill Packs - */ -export type listSkillPacksApiV1SkillsPacksGetResponse200 = { - data: SkillPackRead[]; - status: 200; -}; - -export type listSkillPacksApiV1SkillsPacksGetResponseSuccess = - listSkillPacksApiV1SkillsPacksGetResponse200 & { - headers: Headers; - }; -export type listSkillPacksApiV1SkillsPacksGetResponse = - listSkillPacksApiV1SkillsPacksGetResponseSuccess; - -export const getListSkillPacksApiV1SkillsPacksGetUrl = () => { - return `/api/v1/skills/packs`; -}; - -export const listSkillPacksApiV1SkillsPacksGet = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getListSkillPacksApiV1SkillsPacksGetUrl(), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListSkillPacksApiV1SkillsPacksGetQueryKey = () => { - return [`/api/v1/skills/packs`] as const; -}; - -export const getListSkillPacksApiV1SkillsPacksGetQueryOptions = < - TData = Awaited>, - TError = unknown, ->(options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getListSkillPacksApiV1SkillsPacksGetQueryKey(); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listSkillPacksApiV1SkillsPacksGet({ signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListSkillPacksApiV1SkillsPacksGetQueryResult = NonNullable< - Awaited> ->; -export type ListSkillPacksApiV1SkillsPacksGetQueryError = unknown; - -export function useListSkillPacksApiV1SkillsPacksGet< - TData = Awaited>, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListSkillPacksApiV1SkillsPacksGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListSkillPacksApiV1SkillsPacksGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Skill Packs - */ - -export function useListSkillPacksApiV1SkillsPacksGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListSkillPacksApiV1SkillsPacksGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Register a new skill pack source URL. - * @summary Create Skill Pack - */ -export type createSkillPackApiV1SkillsPacksPostResponse200 = { - data: SkillPackRead; - status: 200; -}; - -export type createSkillPackApiV1SkillsPacksPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createSkillPackApiV1SkillsPacksPostResponseSuccess = - createSkillPackApiV1SkillsPacksPostResponse200 & { - headers: Headers; - }; -export type createSkillPackApiV1SkillsPacksPostResponseError = - createSkillPackApiV1SkillsPacksPostResponse422 & { - headers: Headers; - }; - -export type createSkillPackApiV1SkillsPacksPostResponse = - | createSkillPackApiV1SkillsPacksPostResponseSuccess - | createSkillPackApiV1SkillsPacksPostResponseError; - -export const getCreateSkillPackApiV1SkillsPacksPostUrl = () => { - return `/api/v1/skills/packs`; -}; - -export const createSkillPackApiV1SkillsPacksPost = async ( - skillPackCreate: SkillPackCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateSkillPackApiV1SkillsPacksPostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(skillPackCreate), - }, - ); -}; - -export const getCreateSkillPackApiV1SkillsPacksPostMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: SkillPackCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { data: SkillPackCreate }, - TContext -> => { - const mutationKey = ["createSkillPackApiV1SkillsPacksPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { data: SkillPackCreate } - > = (props) => { - const { data } = props ?? {}; - - return createSkillPackApiV1SkillsPacksPost(data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type CreateSkillPackApiV1SkillsPacksPostMutationResult = NonNullable< - Awaited> ->; -export type CreateSkillPackApiV1SkillsPacksPostMutationBody = SkillPackCreate; -export type CreateSkillPackApiV1SkillsPacksPostMutationError = - HTTPValidationError; - -/** - * @summary Create Skill Pack - */ -export const useCreateSkillPackApiV1SkillsPacksPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: SkillPackCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: SkillPackCreate }, - TContext -> => { - return useMutation( - getCreateSkillPackApiV1SkillsPacksPostMutationOptions(options), - queryClient, - ); -}; -/** - * Delete one pack source from the organization. - * @summary Delete Skill Pack - */ -export type deleteSkillPackApiV1SkillsPacksPackIdDeleteResponse200 = { - data: OkResponse; - status: 200; -}; - -export type deleteSkillPackApiV1SkillsPacksPackIdDeleteResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type deleteSkillPackApiV1SkillsPacksPackIdDeleteResponseSuccess = - deleteSkillPackApiV1SkillsPacksPackIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteSkillPackApiV1SkillsPacksPackIdDeleteResponseError = - deleteSkillPackApiV1SkillsPacksPackIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteSkillPackApiV1SkillsPacksPackIdDeleteResponse = - | deleteSkillPackApiV1SkillsPacksPackIdDeleteResponseSuccess - | deleteSkillPackApiV1SkillsPacksPackIdDeleteResponseError; - -export const getDeleteSkillPackApiV1SkillsPacksPackIdDeleteUrl = ( - packId: string, -) => { - return `/api/v1/skills/packs/${packId}`; -}; - -export const deleteSkillPackApiV1SkillsPacksPackIdDelete = async ( - packId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getDeleteSkillPackApiV1SkillsPacksPackIdDeleteUrl(packId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getDeleteSkillPackApiV1SkillsPacksPackIdDeleteMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { packId: string }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { packId: string }, - TContext -> => { - const mutationKey = ["deleteSkillPackApiV1SkillsPacksPackIdDelete"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { packId: string } - > = (props) => { - const { packId } = props ?? {}; - - return deleteSkillPackApiV1SkillsPacksPackIdDelete(packId, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type DeleteSkillPackApiV1SkillsPacksPackIdDeleteMutationResult = - NonNullable< - Awaited> - >; - -export type DeleteSkillPackApiV1SkillsPacksPackIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Delete Skill Pack - */ -export const useDeleteSkillPackApiV1SkillsPacksPackIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { packId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { packId: string }, - TContext -> => { - return useMutation( - getDeleteSkillPackApiV1SkillsPacksPackIdDeleteMutationOptions(options), - queryClient, - ); -}; -/** - * Get one skill pack by ID. - * @summary Get Skill Pack - */ -export type getSkillPackApiV1SkillsPacksPackIdGetResponse200 = { - data: SkillPackRead; - status: 200; -}; - -export type getSkillPackApiV1SkillsPacksPackIdGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getSkillPackApiV1SkillsPacksPackIdGetResponseSuccess = - getSkillPackApiV1SkillsPacksPackIdGetResponse200 & { - headers: Headers; - }; -export type getSkillPackApiV1SkillsPacksPackIdGetResponseError = - getSkillPackApiV1SkillsPacksPackIdGetResponse422 & { - headers: Headers; - }; - -export type getSkillPackApiV1SkillsPacksPackIdGetResponse = - | getSkillPackApiV1SkillsPacksPackIdGetResponseSuccess - | getSkillPackApiV1SkillsPacksPackIdGetResponseError; - -export const getGetSkillPackApiV1SkillsPacksPackIdGetUrl = (packId: string) => { - return `/api/v1/skills/packs/${packId}`; -}; - -export const getSkillPackApiV1SkillsPacksPackIdGet = async ( - packId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetSkillPackApiV1SkillsPacksPackIdGetUrl(packId), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetSkillPackApiV1SkillsPacksPackIdGetQueryKey = ( - packId: string, -) => { - return [`/api/v1/skills/packs/${packId}`] as const; -}; - -export const getGetSkillPackApiV1SkillsPacksPackIdGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - packId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetSkillPackApiV1SkillsPacksPackIdGetQueryKey(packId); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getSkillPackApiV1SkillsPacksPackIdGet(packId, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!packId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetSkillPackApiV1SkillsPacksPackIdGetQueryResult = NonNullable< - Awaited> ->; -export type GetSkillPackApiV1SkillsPacksPackIdGetQueryError = - HTTPValidationError; - -export function useGetSkillPackApiV1SkillsPacksPackIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - packId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetSkillPackApiV1SkillsPacksPackIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - packId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetSkillPackApiV1SkillsPacksPackIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - packId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Skill Pack - */ - -export function useGetSkillPackApiV1SkillsPacksPackIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - packId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getGetSkillPackApiV1SkillsPacksPackIdGetQueryOptions( - packId, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Update a skill pack URL and metadata. - * @summary Update Skill Pack - */ -export type updateSkillPackApiV1SkillsPacksPackIdPatchResponse200 = { - data: SkillPackRead; - status: 200; -}; - -export type updateSkillPackApiV1SkillsPacksPackIdPatchResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type updateSkillPackApiV1SkillsPacksPackIdPatchResponseSuccess = - updateSkillPackApiV1SkillsPacksPackIdPatchResponse200 & { - headers: Headers; - }; -export type updateSkillPackApiV1SkillsPacksPackIdPatchResponseError = - updateSkillPackApiV1SkillsPacksPackIdPatchResponse422 & { - headers: Headers; - }; - -export type updateSkillPackApiV1SkillsPacksPackIdPatchResponse = - | updateSkillPackApiV1SkillsPacksPackIdPatchResponseSuccess - | updateSkillPackApiV1SkillsPacksPackIdPatchResponseError; - -export const getUpdateSkillPackApiV1SkillsPacksPackIdPatchUrl = ( - packId: string, -) => { - return `/api/v1/skills/packs/${packId}`; -}; - -export const updateSkillPackApiV1SkillsPacksPackIdPatch = async ( - packId: string, - skillPackCreate: SkillPackCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getUpdateSkillPackApiV1SkillsPacksPackIdPatchUrl(packId), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(skillPackCreate), - }, - ); -}; - -export const getUpdateSkillPackApiV1SkillsPacksPackIdPatchMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { packId: string; data: SkillPackCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { packId: string; data: SkillPackCreate }, - TContext -> => { - const mutationKey = ["updateSkillPackApiV1SkillsPacksPackIdPatch"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { packId: string; data: SkillPackCreate } - > = (props) => { - const { packId, data } = props ?? {}; - - return updateSkillPackApiV1SkillsPacksPackIdPatch( - packId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type UpdateSkillPackApiV1SkillsPacksPackIdPatchMutationResult = - NonNullable< - Awaited> - >; -export type UpdateSkillPackApiV1SkillsPacksPackIdPatchMutationBody = - SkillPackCreate; -export type UpdateSkillPackApiV1SkillsPacksPackIdPatchMutationError = - HTTPValidationError; - -/** - * @summary Update Skill Pack - */ -export const useUpdateSkillPackApiV1SkillsPacksPackIdPatch = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { packId: string; data: SkillPackCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { packId: string; data: SkillPackCreate }, - TContext -> => { - return useMutation( - getUpdateSkillPackApiV1SkillsPacksPackIdPatchMutationOptions(options), - queryClient, - ); -}; -/** - * Clone a pack repository and upsert discovered skills from `skills/**\/SKILL.md`. - * @summary Sync Skill Pack - */ -export type syncSkillPackApiV1SkillsPacksPackIdSyncPostResponse200 = { - data: SkillPackSyncResponse; - status: 200; -}; - -export type syncSkillPackApiV1SkillsPacksPackIdSyncPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type syncSkillPackApiV1SkillsPacksPackIdSyncPostResponseSuccess = - syncSkillPackApiV1SkillsPacksPackIdSyncPostResponse200 & { - headers: Headers; - }; -export type syncSkillPackApiV1SkillsPacksPackIdSyncPostResponseError = - syncSkillPackApiV1SkillsPacksPackIdSyncPostResponse422 & { - headers: Headers; - }; - -export type syncSkillPackApiV1SkillsPacksPackIdSyncPostResponse = - | syncSkillPackApiV1SkillsPacksPackIdSyncPostResponseSuccess - | syncSkillPackApiV1SkillsPacksPackIdSyncPostResponseError; - -export const getSyncSkillPackApiV1SkillsPacksPackIdSyncPostUrl = ( - packId: string, -) => { - return `/api/v1/skills/packs/${packId}/sync`; -}; - -export const syncSkillPackApiV1SkillsPacksPackIdSyncPost = async ( - packId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getSyncSkillPackApiV1SkillsPacksPackIdSyncPostUrl(packId), - { - ...options, - method: "POST", - }, - ); -}; - -export const getSyncSkillPackApiV1SkillsPacksPackIdSyncPostMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { packId: string }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { packId: string }, - TContext -> => { - const mutationKey = ["syncSkillPackApiV1SkillsPacksPackIdSyncPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { packId: string } - > = (props) => { - const { packId } = props ?? {}; - - return syncSkillPackApiV1SkillsPacksPackIdSyncPost(packId, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type SyncSkillPackApiV1SkillsPacksPackIdSyncPostMutationResult = - NonNullable< - Awaited> - >; - -export type SyncSkillPackApiV1SkillsPacksPackIdSyncPostMutationError = - HTTPValidationError; - -/** - * @summary Sync Skill Pack - */ -export const useSyncSkillPackApiV1SkillsPacksPackIdSyncPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { packId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { packId: string }, - TContext -> => { - return useMutation( - getSyncSkillPackApiV1SkillsPacksPackIdSyncPostMutationOptions(options), - queryClient, - ); -}; diff --git a/src/frontend/src/api/generated/souls-directory/souls-directory.ts b/src/frontend/src/api/generated/souls-directory/souls-directory.ts deleted file mode 100644 index 7a743f4..0000000 --- a/src/frontend/src/api/generated/souls-directory/souls-directory.ts +++ /dev/null @@ -1,730 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - HTTPValidationError, - SearchApiV1SoulsDirectorySearchGetParams, - SoulsDirectoryMarkdownResponse, - SoulsDirectorySearchResponse, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * Search souls-directory entries by handle/slug query text. - * @summary Search - */ -export type searchApiV1SoulsDirectorySearchGetResponse200 = { - data: SoulsDirectorySearchResponse; - status: 200; -}; - -export type searchApiV1SoulsDirectorySearchGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type searchApiV1SoulsDirectorySearchGetResponseSuccess = - searchApiV1SoulsDirectorySearchGetResponse200 & { - headers: Headers; - }; -export type searchApiV1SoulsDirectorySearchGetResponseError = - searchApiV1SoulsDirectorySearchGetResponse422 & { - headers: Headers; - }; - -export type searchApiV1SoulsDirectorySearchGetResponse = - | searchApiV1SoulsDirectorySearchGetResponseSuccess - | searchApiV1SoulsDirectorySearchGetResponseError; - -export const getSearchApiV1SoulsDirectorySearchGetUrl = ( - params?: SearchApiV1SoulsDirectorySearchGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/souls-directory/search?${stringifiedParams}` - : `/api/v1/souls-directory/search`; -}; - -export const searchApiV1SoulsDirectorySearchGet = async ( - params?: SearchApiV1SoulsDirectorySearchGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getSearchApiV1SoulsDirectorySearchGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getSearchApiV1SoulsDirectorySearchGetQueryKey = ( - params?: SearchApiV1SoulsDirectorySearchGetParams, -) => { - return [ - `/api/v1/souls-directory/search`, - ...(params ? [params] : []), - ] as const; -}; - -export const getSearchApiV1SoulsDirectorySearchGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: SearchApiV1SoulsDirectorySearchGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getSearchApiV1SoulsDirectorySearchGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - searchApiV1SoulsDirectorySearchGet(params, { signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type SearchApiV1SoulsDirectorySearchGetQueryResult = NonNullable< - Awaited> ->; -export type SearchApiV1SoulsDirectorySearchGetQueryError = HTTPValidationError; - -export function useSearchApiV1SoulsDirectorySearchGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params: undefined | SearchApiV1SoulsDirectorySearchGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useSearchApiV1SoulsDirectorySearchGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: SearchApiV1SoulsDirectorySearchGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useSearchApiV1SoulsDirectorySearchGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: SearchApiV1SoulsDirectorySearchGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Search - */ - -export function useSearchApiV1SoulsDirectorySearchGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: SearchApiV1SoulsDirectorySearchGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getSearchApiV1SoulsDirectorySearchGetQueryOptions( - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Fetch markdown content for a validated souls-directory handle and slug. - * @summary Get Markdown - */ -export type getMarkdownApiV1SoulsDirectoryHandleSlugGetResponse200 = { - data: SoulsDirectoryMarkdownResponse; - status: 200; -}; - -export type getMarkdownApiV1SoulsDirectoryHandleSlugGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getMarkdownApiV1SoulsDirectoryHandleSlugGetResponseSuccess = - getMarkdownApiV1SoulsDirectoryHandleSlugGetResponse200 & { - headers: Headers; - }; -export type getMarkdownApiV1SoulsDirectoryHandleSlugGetResponseError = - getMarkdownApiV1SoulsDirectoryHandleSlugGetResponse422 & { - headers: Headers; - }; - -export type getMarkdownApiV1SoulsDirectoryHandleSlugGetResponse = - | getMarkdownApiV1SoulsDirectoryHandleSlugGetResponseSuccess - | getMarkdownApiV1SoulsDirectoryHandleSlugGetResponseError; - -export const getGetMarkdownApiV1SoulsDirectoryHandleSlugGetUrl = ( - handle: string, - slug: string, -) => { - return `/api/v1/souls-directory/${handle}/${slug}`; -}; - -export const getMarkdownApiV1SoulsDirectoryHandleSlugGet = async ( - handle: string, - slug: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetMarkdownApiV1SoulsDirectoryHandleSlugGetUrl(handle, slug), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetMarkdownApiV1SoulsDirectoryHandleSlugGetQueryKey = ( - handle: string, - slug: string, -) => { - return [`/api/v1/souls-directory/${handle}/${slug}`] as const; -}; - -export const getGetMarkdownApiV1SoulsDirectoryHandleSlugGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - handle: string, - slug: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetMarkdownApiV1SoulsDirectoryHandleSlugGetQueryKey(handle, slug); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getMarkdownApiV1SoulsDirectoryHandleSlugGet(handle, slug, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!(handle && slug), - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetMarkdownApiV1SoulsDirectoryHandleSlugGetQueryResult = - NonNullable< - Awaited> - >; -export type GetMarkdownApiV1SoulsDirectoryHandleSlugGetQueryError = - HTTPValidationError; - -export function useGetMarkdownApiV1SoulsDirectoryHandleSlugGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - handle: string, - slug: string, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetMarkdownApiV1SoulsDirectoryHandleSlugGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - handle: string, - slug: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetMarkdownApiV1SoulsDirectoryHandleSlugGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - handle: string, - slug: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Markdown - */ - -export function useGetMarkdownApiV1SoulsDirectoryHandleSlugGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - handle: string, - slug: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetMarkdownApiV1SoulsDirectoryHandleSlugGetQueryOptions( - handle, - slug, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Fetch markdown content for a validated souls-directory handle and slug. - * @summary Get Markdown - */ -export type getMarkdownApiV1SoulsDirectoryHandleSlugMdGetResponse200 = { - data: SoulsDirectoryMarkdownResponse; - status: 200; -}; - -export type getMarkdownApiV1SoulsDirectoryHandleSlugMdGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getMarkdownApiV1SoulsDirectoryHandleSlugMdGetResponseSuccess = - getMarkdownApiV1SoulsDirectoryHandleSlugMdGetResponse200 & { - headers: Headers; - }; -export type getMarkdownApiV1SoulsDirectoryHandleSlugMdGetResponseError = - getMarkdownApiV1SoulsDirectoryHandleSlugMdGetResponse422 & { - headers: Headers; - }; - -export type getMarkdownApiV1SoulsDirectoryHandleSlugMdGetResponse = - | getMarkdownApiV1SoulsDirectoryHandleSlugMdGetResponseSuccess - | getMarkdownApiV1SoulsDirectoryHandleSlugMdGetResponseError; - -export const getGetMarkdownApiV1SoulsDirectoryHandleSlugMdGetUrl = ( - handle: string, - slug: string, -) => { - return `/api/v1/souls-directory/${handle}/${slug}.md`; -}; - -export const getMarkdownApiV1SoulsDirectoryHandleSlugMdGet = async ( - handle: string, - slug: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetMarkdownApiV1SoulsDirectoryHandleSlugMdGetUrl(handle, slug), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetMarkdownApiV1SoulsDirectoryHandleSlugMdGetQueryKey = ( - handle: string, - slug: string, -) => { - return [`/api/v1/souls-directory/${handle}/${slug}.md`] as const; -}; - -export const getGetMarkdownApiV1SoulsDirectoryHandleSlugMdGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - handle: string, - slug: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getGetMarkdownApiV1SoulsDirectoryHandleSlugMdGetQueryKey(handle, slug); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getMarkdownApiV1SoulsDirectoryHandleSlugMdGet(handle, slug, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!(handle && slug), - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetMarkdownApiV1SoulsDirectoryHandleSlugMdGetQueryResult = - NonNullable< - Awaited> - >; -export type GetMarkdownApiV1SoulsDirectoryHandleSlugMdGetQueryError = - HTTPValidationError; - -export function useGetMarkdownApiV1SoulsDirectoryHandleSlugMdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - handle: string, - slug: string, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetMarkdownApiV1SoulsDirectoryHandleSlugMdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - handle: string, - slug: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetMarkdownApiV1SoulsDirectoryHandleSlugMdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - handle: string, - slug: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Markdown - */ - -export function useGetMarkdownApiV1SoulsDirectoryHandleSlugMdGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - handle: string, - slug: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getGetMarkdownApiV1SoulsDirectoryHandleSlugMdGetQueryOptions( - handle, - slug, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} diff --git a/src/frontend/src/api/generated/tags/tags.ts b/src/frontend/src/api/generated/tags/tags.ts deleted file mode 100644 index 36278bd..0000000 --- a/src/frontend/src/api/generated/tags/tags.ts +++ /dev/null @@ -1,794 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - HTTPValidationError, - LimitOffsetPageTypeVarCustomizedTagRead, - ListTagsApiV1TagsGetParams, - OkResponse, - TagCreate, - TagRead, - TagUpdate, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List tags for the active organization. - * @summary List Tags - */ -export type listTagsApiV1TagsGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedTagRead; - status: 200; -}; - -export type listTagsApiV1TagsGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listTagsApiV1TagsGetResponseSuccess = - listTagsApiV1TagsGetResponse200 & { - headers: Headers; - }; -export type listTagsApiV1TagsGetResponseError = - listTagsApiV1TagsGetResponse422 & { - headers: Headers; - }; - -export type listTagsApiV1TagsGetResponse = - | listTagsApiV1TagsGetResponseSuccess - | listTagsApiV1TagsGetResponseError; - -export const getListTagsApiV1TagsGetUrl = ( - params?: ListTagsApiV1TagsGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/tags?${stringifiedParams}` - : `/api/v1/tags`; -}; - -export const listTagsApiV1TagsGet = async ( - params?: ListTagsApiV1TagsGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListTagsApiV1TagsGetUrl(params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListTagsApiV1TagsGetQueryKey = ( - params?: ListTagsApiV1TagsGetParams, -) => { - return [`/api/v1/tags`, ...(params ? [params] : [])] as const; -}; - -export const getListTagsApiV1TagsGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListTagsApiV1TagsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getListTagsApiV1TagsGetQueryKey(params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listTagsApiV1TagsGet(params, { signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListTagsApiV1TagsGetQueryResult = NonNullable< - Awaited> ->; -export type ListTagsApiV1TagsGetQueryError = HTTPValidationError; - -export function useListTagsApiV1TagsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params: undefined | ListTagsApiV1TagsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListTagsApiV1TagsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListTagsApiV1TagsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListTagsApiV1TagsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListTagsApiV1TagsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Tags - */ - -export function useListTagsApiV1TagsGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - params?: ListTagsApiV1TagsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getListTagsApiV1TagsGetQueryOptions(params, options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create a tag within the active organization. - * @summary Create Tag - */ -export type createTagApiV1TagsPostResponse200 = { - data: TagRead; - status: 200; -}; - -export type createTagApiV1TagsPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createTagApiV1TagsPostResponseSuccess = - createTagApiV1TagsPostResponse200 & { - headers: Headers; - }; -export type createTagApiV1TagsPostResponseError = - createTagApiV1TagsPostResponse422 & { - headers: Headers; - }; - -export type createTagApiV1TagsPostResponse = - | createTagApiV1TagsPostResponseSuccess - | createTagApiV1TagsPostResponseError; - -export const getCreateTagApiV1TagsPostUrl = () => { - return `/api/v1/tags`; -}; - -export const createTagApiV1TagsPost = async ( - tagCreate: TagCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateTagApiV1TagsPostUrl(), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(tagCreate), - }, - ); -}; - -export const getCreateTagApiV1TagsPostMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: TagCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { data: TagCreate }, - TContext -> => { - const mutationKey = ["createTagApiV1TagsPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { data: TagCreate } - > = (props) => { - const { data } = props ?? {}; - - return createTagApiV1TagsPost(data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type CreateTagApiV1TagsPostMutationResult = NonNullable< - Awaited> ->; -export type CreateTagApiV1TagsPostMutationBody = TagCreate; -export type CreateTagApiV1TagsPostMutationError = HTTPValidationError; - -/** - * @summary Create Tag - */ -export const useCreateTagApiV1TagsPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: TagCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: TagCreate }, - TContext -> => { - return useMutation( - getCreateTagApiV1TagsPostMutationOptions(options), - queryClient, - ); -}; -/** - * Delete a tag and remove all associated tag links. - * @summary Delete Tag - */ -export type deleteTagApiV1TagsTagIdDeleteResponse200 = { - data: OkResponse; - status: 200; -}; - -export type deleteTagApiV1TagsTagIdDeleteResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type deleteTagApiV1TagsTagIdDeleteResponseSuccess = - deleteTagApiV1TagsTagIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteTagApiV1TagsTagIdDeleteResponseError = - deleteTagApiV1TagsTagIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteTagApiV1TagsTagIdDeleteResponse = - | deleteTagApiV1TagsTagIdDeleteResponseSuccess - | deleteTagApiV1TagsTagIdDeleteResponseError; - -export const getDeleteTagApiV1TagsTagIdDeleteUrl = (tagId: string) => { - return `/api/v1/tags/${tagId}`; -}; - -export const deleteTagApiV1TagsTagIdDelete = async ( - tagId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getDeleteTagApiV1TagsTagIdDeleteUrl(tagId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getDeleteTagApiV1TagsTagIdDeleteMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { tagId: string }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { tagId: string }, - TContext -> => { - const mutationKey = ["deleteTagApiV1TagsTagIdDelete"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { tagId: string } - > = (props) => { - const { tagId } = props ?? {}; - - return deleteTagApiV1TagsTagIdDelete(tagId, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type DeleteTagApiV1TagsTagIdDeleteMutationResult = NonNullable< - Awaited> ->; - -export type DeleteTagApiV1TagsTagIdDeleteMutationError = HTTPValidationError; - -/** - * @summary Delete Tag - */ -export const useDeleteTagApiV1TagsTagIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { tagId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { tagId: string }, - TContext -> => { - return useMutation( - getDeleteTagApiV1TagsTagIdDeleteMutationOptions(options), - queryClient, - ); -}; -/** - * Get a single tag in the active organization. - * @summary Get Tag - */ -export type getTagApiV1TagsTagIdGetResponse200 = { - data: TagRead; - status: 200; -}; - -export type getTagApiV1TagsTagIdGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type getTagApiV1TagsTagIdGetResponseSuccess = - getTagApiV1TagsTagIdGetResponse200 & { - headers: Headers; - }; -export type getTagApiV1TagsTagIdGetResponseError = - getTagApiV1TagsTagIdGetResponse422 & { - headers: Headers; - }; - -export type getTagApiV1TagsTagIdGetResponse = - | getTagApiV1TagsTagIdGetResponseSuccess - | getTagApiV1TagsTagIdGetResponseError; - -export const getGetTagApiV1TagsTagIdGetUrl = (tagId: string) => { - return `/api/v1/tags/${tagId}`; -}; - -export const getTagApiV1TagsTagIdGet = async ( - tagId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getGetTagApiV1TagsTagIdGetUrl(tagId), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetTagApiV1TagsTagIdGetQueryKey = (tagId: string) => { - return [`/api/v1/tags/${tagId}`] as const; -}; - -export const getGetTagApiV1TagsTagIdGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - tagId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? getGetTagApiV1TagsTagIdGetQueryKey(tagId); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - getTagApiV1TagsTagIdGet(tagId, { signal, ...requestOptions }); - - return { - queryKey, - queryFn, - enabled: !!tagId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetTagApiV1TagsTagIdGetQueryResult = NonNullable< - Awaited> ->; -export type GetTagApiV1TagsTagIdGetQueryError = HTTPValidationError; - -export function useGetTagApiV1TagsTagIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - tagId: string, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetTagApiV1TagsTagIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - tagId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetTagApiV1TagsTagIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - tagId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Tag - */ - -export function useGetTagApiV1TagsTagIdGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - tagId: string, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getGetTagApiV1TagsTagIdGetQueryOptions(tagId, options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Update a tag in the active organization. - * @summary Update Tag - */ -export type updateTagApiV1TagsTagIdPatchResponse200 = { - data: TagRead; - status: 200; -}; - -export type updateTagApiV1TagsTagIdPatchResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type updateTagApiV1TagsTagIdPatchResponseSuccess = - updateTagApiV1TagsTagIdPatchResponse200 & { - headers: Headers; - }; -export type updateTagApiV1TagsTagIdPatchResponseError = - updateTagApiV1TagsTagIdPatchResponse422 & { - headers: Headers; - }; - -export type updateTagApiV1TagsTagIdPatchResponse = - | updateTagApiV1TagsTagIdPatchResponseSuccess - | updateTagApiV1TagsTagIdPatchResponseError; - -export const getUpdateTagApiV1TagsTagIdPatchUrl = (tagId: string) => { - return `/api/v1/tags/${tagId}`; -}; - -export const updateTagApiV1TagsTagIdPatch = async ( - tagId: string, - tagUpdate: TagUpdate, - options?: RequestInit, -): Promise => { - return customFetch( - getUpdateTagApiV1TagsTagIdPatchUrl(tagId), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(tagUpdate), - }, - ); -}; - -export const getUpdateTagApiV1TagsTagIdPatchMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { tagId: string; data: TagUpdate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { tagId: string; data: TagUpdate }, - TContext -> => { - const mutationKey = ["updateTagApiV1TagsTagIdPatch"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { tagId: string; data: TagUpdate } - > = (props) => { - const { tagId, data } = props ?? {}; - - return updateTagApiV1TagsTagIdPatch(tagId, data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type UpdateTagApiV1TagsTagIdPatchMutationResult = NonNullable< - Awaited> ->; -export type UpdateTagApiV1TagsTagIdPatchMutationBody = TagUpdate; -export type UpdateTagApiV1TagsTagIdPatchMutationError = HTTPValidationError; - -/** - * @summary Update Tag - */ -export const useUpdateTagApiV1TagsTagIdPatch = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { tagId: string; data: TagUpdate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { tagId: string; data: TagUpdate }, - TContext -> => { - return useMutation( - getUpdateTagApiV1TagsTagIdPatchMutationOptions(options), - queryClient, - ); -}; diff --git a/src/frontend/src/api/generated/tasks/tasks.ts b/src/frontend/src/api/generated/tasks/tasks.ts deleted file mode 100644 index cf1f6ac..0000000 --- a/src/frontend/src/api/generated/tasks/tasks.ts +++ /dev/null @@ -1,1403 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - BlockedTaskError, - HTTPValidationError, - LimitOffsetPageTypeVarCustomizedTaskCommentRead, - LimitOffsetPageTypeVarCustomizedTaskRead, - ListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams, - ListTasksApiV1BoardsBoardIdTasksGetParams, - OkResponse, - StreamTasksApiV1BoardsBoardIdTasksStreamGetParams, - TaskCommentCreate, - TaskCommentRead, - TaskCreate, - TaskRead, - TaskUpdate, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * List board tasks with optional status and assignment filters. - * @summary List Tasks - */ -export type listTasksApiV1BoardsBoardIdTasksGetResponse200 = { - data: LimitOffsetPageTypeVarCustomizedTaskRead; - status: 200; -}; - -export type listTasksApiV1BoardsBoardIdTasksGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type listTasksApiV1BoardsBoardIdTasksGetResponseSuccess = - listTasksApiV1BoardsBoardIdTasksGetResponse200 & { - headers: Headers; - }; -export type listTasksApiV1BoardsBoardIdTasksGetResponseError = - listTasksApiV1BoardsBoardIdTasksGetResponse422 & { - headers: Headers; - }; - -export type listTasksApiV1BoardsBoardIdTasksGetResponse = - | listTasksApiV1BoardsBoardIdTasksGetResponseSuccess - | listTasksApiV1BoardsBoardIdTasksGetResponseError; - -export const getListTasksApiV1BoardsBoardIdTasksGetUrl = ( - boardId: string, - params?: ListTasksApiV1BoardsBoardIdTasksGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards/${boardId}/tasks?${stringifiedParams}` - : `/api/v1/boards/${boardId}/tasks`; -}; - -export const listTasksApiV1BoardsBoardIdTasksGet = async ( - boardId: string, - params?: ListTasksApiV1BoardsBoardIdTasksGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListTasksApiV1BoardsBoardIdTasksGetUrl(boardId, params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListTasksApiV1BoardsBoardIdTasksGetQueryKey = ( - boardId: string, - params?: ListTasksApiV1BoardsBoardIdTasksGetParams, -) => { - return [ - `/api/v1/boards/${boardId}/tasks`, - ...(params ? [params] : []), - ] as const; -}; - -export const getListTasksApiV1BoardsBoardIdTasksGetQueryOptions = < - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListTasksApiV1BoardsBoardIdTasksGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListTasksApiV1BoardsBoardIdTasksGetQueryKey(boardId, params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - listTasksApiV1BoardsBoardIdTasksGet(boardId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type ListTasksApiV1BoardsBoardIdTasksGetQueryResult = NonNullable< - Awaited> ->; -export type ListTasksApiV1BoardsBoardIdTasksGetQueryError = HTTPValidationError; - -export function useListTasksApiV1BoardsBoardIdTasksGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - params: undefined | ListTasksApiV1BoardsBoardIdTasksGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListTasksApiV1BoardsBoardIdTasksGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListTasksApiV1BoardsBoardIdTasksGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListTasksApiV1BoardsBoardIdTasksGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListTasksApiV1BoardsBoardIdTasksGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Tasks - */ - -export function useListTasksApiV1BoardsBoardIdTasksGet< - TData = Awaited>, - TError = HTTPValidationError, ->( - boardId: string, - params?: ListTasksApiV1BoardsBoardIdTasksGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getListTasksApiV1BoardsBoardIdTasksGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create a task and initialize dependency rows. - * @summary Create Task - */ -export type createTaskApiV1BoardsBoardIdTasksPostResponse200 = { - data: TaskRead; - status: 200; -}; - -export type createTaskApiV1BoardsBoardIdTasksPostResponse409 = { - data: BlockedTaskError; - status: 409; -}; - -export type createTaskApiV1BoardsBoardIdTasksPostResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type createTaskApiV1BoardsBoardIdTasksPostResponseSuccess = - createTaskApiV1BoardsBoardIdTasksPostResponse200 & { - headers: Headers; - }; -export type createTaskApiV1BoardsBoardIdTasksPostResponseError = ( - | createTaskApiV1BoardsBoardIdTasksPostResponse409 - | createTaskApiV1BoardsBoardIdTasksPostResponse422 -) & { - headers: Headers; -}; - -export type createTaskApiV1BoardsBoardIdTasksPostResponse = - | createTaskApiV1BoardsBoardIdTasksPostResponseSuccess - | createTaskApiV1BoardsBoardIdTasksPostResponseError; - -export const getCreateTaskApiV1BoardsBoardIdTasksPostUrl = ( - boardId: string, -) => { - return `/api/v1/boards/${boardId}/tasks`; -}; - -export const createTaskApiV1BoardsBoardIdTasksPost = async ( - boardId: string, - taskCreate: TaskCreate, - options?: RequestInit, -): Promise => { - return customFetch( - getCreateTaskApiV1BoardsBoardIdTasksPostUrl(boardId), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(taskCreate), - }, - ); -}; - -export const getCreateTaskApiV1BoardsBoardIdTasksPostMutationOptions = < - TError = BlockedTaskError | HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: TaskCreate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: TaskCreate }, - TContext -> => { - const mutationKey = ["createTaskApiV1BoardsBoardIdTasksPost"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string; data: TaskCreate } - > = (props) => { - const { boardId, data } = props ?? {}; - - return createTaskApiV1BoardsBoardIdTasksPost(boardId, data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type CreateTaskApiV1BoardsBoardIdTasksPostMutationResult = NonNullable< - Awaited> ->; -export type CreateTaskApiV1BoardsBoardIdTasksPostMutationBody = TaskCreate; -export type CreateTaskApiV1BoardsBoardIdTasksPostMutationError = - | BlockedTaskError - | HTTPValidationError; - -/** - * @summary Create Task - */ -export const useCreateTaskApiV1BoardsBoardIdTasksPost = < - TError = BlockedTaskError | HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; data: TaskCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; data: TaskCreate }, - TContext -> => { - return useMutation( - getCreateTaskApiV1BoardsBoardIdTasksPostMutationOptions(options), - queryClient, - ); -}; -/** - * Stream task and task-comment events as SSE payloads. - * @summary Stream Tasks - */ -export type streamTasksApiV1BoardsBoardIdTasksStreamGetResponse200 = { - data: unknown; - status: 200; -}; - -export type streamTasksApiV1BoardsBoardIdTasksStreamGetResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type streamTasksApiV1BoardsBoardIdTasksStreamGetResponseSuccess = - streamTasksApiV1BoardsBoardIdTasksStreamGetResponse200 & { - headers: Headers; - }; -export type streamTasksApiV1BoardsBoardIdTasksStreamGetResponseError = - streamTasksApiV1BoardsBoardIdTasksStreamGetResponse422 & { - headers: Headers; - }; - -export type streamTasksApiV1BoardsBoardIdTasksStreamGetResponse = - | streamTasksApiV1BoardsBoardIdTasksStreamGetResponseSuccess - | streamTasksApiV1BoardsBoardIdTasksStreamGetResponseError; - -export const getStreamTasksApiV1BoardsBoardIdTasksStreamGetUrl = ( - boardId: string, - params?: StreamTasksApiV1BoardsBoardIdTasksStreamGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards/${boardId}/tasks/stream?${stringifiedParams}` - : `/api/v1/boards/${boardId}/tasks/stream`; -}; - -export const streamTasksApiV1BoardsBoardIdTasksStreamGet = async ( - boardId: string, - params?: StreamTasksApiV1BoardsBoardIdTasksStreamGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getStreamTasksApiV1BoardsBoardIdTasksStreamGetUrl(boardId, params), - { - ...options, - method: "GET", - }, - ); -}; - -export const getStreamTasksApiV1BoardsBoardIdTasksStreamGetQueryKey = ( - boardId: string, - params?: StreamTasksApiV1BoardsBoardIdTasksStreamGetParams, -) => { - return [ - `/api/v1/boards/${boardId}/tasks/stream`, - ...(params ? [params] : []), - ] as const; -}; - -export const getStreamTasksApiV1BoardsBoardIdTasksStreamGetQueryOptions = < - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamTasksApiV1BoardsBoardIdTasksStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, -) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getStreamTasksApiV1BoardsBoardIdTasksStreamGetQueryKey(boardId, params); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => - streamTasksApiV1BoardsBoardIdTasksStreamGet(boardId, params, { - signal, - ...requestOptions, - }); - - return { - queryKey, - queryFn, - enabled: !!boardId, - ...queryOptions, - } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type StreamTasksApiV1BoardsBoardIdTasksStreamGetQueryResult = - NonNullable< - Awaited> - >; -export type StreamTasksApiV1BoardsBoardIdTasksStreamGetQueryError = - HTTPValidationError; - -export function useStreamTasksApiV1BoardsBoardIdTasksStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params: undefined | StreamTasksApiV1BoardsBoardIdTasksStreamGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useStreamTasksApiV1BoardsBoardIdTasksStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamTasksApiV1BoardsBoardIdTasksStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType - >, - TError, - Awaited< - ReturnType - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useStreamTasksApiV1BoardsBoardIdTasksStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamTasksApiV1BoardsBoardIdTasksStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Stream Tasks - */ - -export function useStreamTasksApiV1BoardsBoardIdTasksStreamGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - params?: StreamTasksApiV1BoardsBoardIdTasksStreamGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getStreamTasksApiV1BoardsBoardIdTasksStreamGetQueryOptions( - boardId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Delete a task and related records. - * @summary Delete Task - */ -export type deleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteResponse200 = { - data: OkResponse; - status: 200; -}; - -export type deleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type deleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteResponseSuccess = - deleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteResponse200 & { - headers: Headers; - }; -export type deleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteResponseError = - deleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteResponse422 & { - headers: Headers; - }; - -export type deleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteResponse = - | deleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteResponseSuccess - | deleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteResponseError; - -export const getDeleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteUrl = ( - boardId: string, - taskId: string, -) => { - return `/api/v1/boards/${boardId}/tasks/${taskId}`; -}; - -export const deleteTaskApiV1BoardsBoardIdTasksTaskIdDelete = async ( - boardId: string, - taskId: string, - options?: RequestInit, -): Promise => { - return customFetch( - getDeleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteUrl(boardId, taskId), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getDeleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; taskId: string }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string; taskId: string }, - TContext -> => { - const mutationKey = ["deleteTaskApiV1BoardsBoardIdTasksTaskIdDelete"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string; taskId: string } - > = (props) => { - const { boardId, taskId } = props ?? {}; - - return deleteTaskApiV1BoardsBoardIdTasksTaskIdDelete( - boardId, - taskId, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type DeleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteMutationResult = - NonNullable< - Awaited> - >; - -export type DeleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteMutationError = - HTTPValidationError; - -/** - * @summary Delete Task - */ -export const useDeleteTaskApiV1BoardsBoardIdTasksTaskIdDelete = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; taskId: string }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; taskId: string }, - TContext -> => { - return useMutation( - getDeleteTaskApiV1BoardsBoardIdTasksTaskIdDeleteMutationOptions(options), - queryClient, - ); -}; -/** - * Update task status, assignment, comment, and dependency state. - * @summary Update Task - */ -export type updateTaskApiV1BoardsBoardIdTasksTaskIdPatchResponse200 = { - data: TaskRead; - status: 200; -}; - -export type updateTaskApiV1BoardsBoardIdTasksTaskIdPatchResponse409 = { - data: BlockedTaskError; - status: 409; -}; - -export type updateTaskApiV1BoardsBoardIdTasksTaskIdPatchResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type updateTaskApiV1BoardsBoardIdTasksTaskIdPatchResponseSuccess = - updateTaskApiV1BoardsBoardIdTasksTaskIdPatchResponse200 & { - headers: Headers; - }; -export type updateTaskApiV1BoardsBoardIdTasksTaskIdPatchResponseError = ( - | updateTaskApiV1BoardsBoardIdTasksTaskIdPatchResponse409 - | updateTaskApiV1BoardsBoardIdTasksTaskIdPatchResponse422 -) & { - headers: Headers; -}; - -export type updateTaskApiV1BoardsBoardIdTasksTaskIdPatchResponse = - | updateTaskApiV1BoardsBoardIdTasksTaskIdPatchResponseSuccess - | updateTaskApiV1BoardsBoardIdTasksTaskIdPatchResponseError; - -export const getUpdateTaskApiV1BoardsBoardIdTasksTaskIdPatchUrl = ( - boardId: string, - taskId: string, -) => { - return `/api/v1/boards/${boardId}/tasks/${taskId}`; -}; - -export const updateTaskApiV1BoardsBoardIdTasksTaskIdPatch = async ( - boardId: string, - taskId: string, - taskUpdate: TaskUpdate, - options?: RequestInit, -): Promise => { - return customFetch( - getUpdateTaskApiV1BoardsBoardIdTasksTaskIdPatchUrl(boardId, taskId), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(taskUpdate), - }, - ); -}; - -export const getUpdateTaskApiV1BoardsBoardIdTasksTaskIdPatchMutationOptions = < - TError = BlockedTaskError | HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; taskId: string; data: TaskUpdate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { boardId: string; taskId: string; data: TaskUpdate }, - TContext -> => { - const mutationKey = ["updateTaskApiV1BoardsBoardIdTasksTaskIdPatch"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { boardId: string; taskId: string; data: TaskUpdate } - > = (props) => { - const { boardId, taskId, data } = props ?? {}; - - return updateTaskApiV1BoardsBoardIdTasksTaskIdPatch( - boardId, - taskId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type UpdateTaskApiV1BoardsBoardIdTasksTaskIdPatchMutationResult = - NonNullable< - Awaited> - >; -export type UpdateTaskApiV1BoardsBoardIdTasksTaskIdPatchMutationBody = - TaskUpdate; -export type UpdateTaskApiV1BoardsBoardIdTasksTaskIdPatchMutationError = - | BlockedTaskError - | HTTPValidationError; - -/** - * @summary Update Task - */ -export const useUpdateTaskApiV1BoardsBoardIdTasksTaskIdPatch = < - TError = BlockedTaskError | HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { boardId: string; taskId: string; data: TaskUpdate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { boardId: string; taskId: string; data: TaskUpdate }, - TContext -> => { - return useMutation( - getUpdateTaskApiV1BoardsBoardIdTasksTaskIdPatchMutationOptions(options), - queryClient, - ); -}; -/** - * List comments for a task in chronological order. - * @summary List Task Comments - */ -export type listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetResponse200 = - { - data: LimitOffsetPageTypeVarCustomizedTaskCommentRead; - status: 200; - }; - -export type listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetResponseSuccess = - listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetResponse200 & { - headers: Headers; - }; -export type listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetResponseError = - listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetResponse422 & { - headers: Headers; - }; - -export type listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetResponse = - | listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetResponseSuccess - | listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetResponseError; - -export const getListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetUrl = ( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams, -) => { - const normalizedParams = new URLSearchParams(); - - Object.entries(params || {}).forEach(([key, value]) => { - if (value !== undefined) { - normalizedParams.append(key, value === null ? "null" : value.toString()); - } - }); - - const stringifiedParams = normalizedParams.toString(); - - return stringifiedParams.length > 0 - ? `/api/v1/boards/${boardId}/tasks/${taskId}/comments?${stringifiedParams}` - : `/api/v1/boards/${boardId}/tasks/${taskId}/comments`; -}; - -export const listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet = async ( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams, - options?: RequestInit, -): Promise => { - return customFetch( - getListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetUrl( - boardId, - taskId, - params, - ), - { - ...options, - method: "GET", - }, - ); -}; - -export const getListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetQueryKey = - ( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams, - ) => { - return [ - `/api/v1/boards/${boardId}/tasks/${taskId}/comments`, - ...(params ? [params] : []), - ] as const; - }; - -export const getListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetQueryOptions = - < - TData = Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError = HTTPValidationError, - >( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - ) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = - queryOptions?.queryKey ?? - getListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetQueryKey( - boardId, - taskId, - params, - ); - - const queryFn: QueryFunction< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - > - > = ({ signal }) => - listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet( - boardId, - taskId, - params, - { signal, ...requestOptions }, - ); - - return { - queryKey, - queryFn, - enabled: !!(boardId && taskId), - ...queryOptions, - } as UseQueryOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - TData - > & { queryKey: DataTag }; - }; - -export type ListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetQueryResult = - NonNullable< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - > - >; -export type ListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetQueryError = - HTTPValidationError; - -export function useListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - taskId: string, - params: - | undefined - | ListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams, - options: { - query: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - > - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary List Task Comments - */ - -export function useListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet< - TData = Awaited< - ReturnType - >, - TError = HTTPValidationError, ->( - boardId: string, - taskId: string, - params?: ListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetParams, - options?: { - query?: Partial< - UseQueryOptions< - Awaited< - ReturnType< - typeof listTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGet - > - >, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = - getListTaskCommentsApiV1BoardsBoardIdTasksTaskIdCommentsGetQueryOptions( - boardId, - taskId, - params, - options, - ); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Create a task comment and notify relevant agents. - * @summary Create Task Comment - */ -export type createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostResponse200 = - { - data: TaskCommentRead; - status: 200; - }; - -export type createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostResponse422 = - { - data: HTTPValidationError; - status: 422; - }; - -export type createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostResponseSuccess = - createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostResponse200 & { - headers: Headers; - }; -export type createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostResponseError = - createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostResponse422 & { - headers: Headers; - }; - -export type createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostResponse = - | createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostResponseSuccess - | createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostResponseError; - -export const getCreateTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostUrl = - (boardId: string, taskId: string) => { - return `/api/v1/boards/${boardId}/tasks/${taskId}/comments`; - }; - -export const createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPost = - async ( - boardId: string, - taskId: string, - taskCommentCreate: TaskCommentCreate, - options?: RequestInit, - ): Promise => { - return customFetch( - getCreateTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostUrl( - boardId, - taskId, - ), - { - ...options, - method: "POST", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(taskCommentCreate), - }, - ); - }; - -export const getCreateTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostMutationOptions = - (options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPost - > - >, - TError, - { boardId: string; taskId: string; data: TaskCommentCreate }, - TContext - >; - request?: SecondParameter; - }): UseMutationOptions< - Awaited< - ReturnType< - typeof createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPost - > - >, - TError, - { boardId: string; taskId: string; data: TaskCommentCreate }, - TContext - > => { - const mutationKey = [ - "createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPost", - ]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited< - ReturnType< - typeof createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPost - > - >, - { boardId: string; taskId: string; data: TaskCommentCreate } - > = (props) => { - const { boardId, taskId, data } = props ?? {}; - - return createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPost( - boardId, - taskId, - data, - requestOptions, - ); - }; - - return { mutationFn, ...mutationOptions }; - }; - -export type CreateTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostMutationResult = - NonNullable< - Awaited< - ReturnType< - typeof createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPost - > - > - >; -export type CreateTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostMutationBody = - TaskCommentCreate; -export type CreateTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostMutationError = - HTTPValidationError; - -/** - * @summary Create Task Comment - */ -export const useCreateTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPost = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited< - ReturnType< - typeof createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPost - > - >, - TError, - { boardId: string; taskId: string; data: TaskCommentCreate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited< - ReturnType< - typeof createTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPost - > - >, - TError, - { boardId: string; taskId: string; data: TaskCommentCreate }, - TContext -> => { - return useMutation( - getCreateTaskCommentApiV1BoardsBoardIdTasksTaskIdCommentsPostMutationOptions( - options, - ), - queryClient, - ); -}; diff --git a/src/frontend/src/api/generated/users/users.ts b/src/frontend/src/api/generated/users/users.ts deleted file mode 100644 index 31c86e0..0000000 --- a/src/frontend/src/api/generated/users/users.ts +++ /dev/null @@ -1,423 +0,0 @@ -/** - * Generated by orval v8.3.0 🍺 - * Do not edit manually. - * Mission Control API - * OpenAPI spec version: 0.1.0 - */ -import { useMutation, useQuery } from "@tanstack/react-query"; -import type { - DataTag, - DefinedInitialDataOptions, - DefinedUseQueryResult, - MutationFunction, - QueryClient, - QueryFunction, - QueryKey, - UndefinedInitialDataOptions, - UseMutationOptions, - UseMutationResult, - UseQueryOptions, - UseQueryResult, -} from "@tanstack/react-query"; - -import type { - HTTPValidationError, - OkResponse, - UserRead, - UserUpdate, -} from ".././model"; - -import { customFetch } from "../../mutator"; - -type SecondParameter unknown> = Parameters[1]; - -/** - * Delete the authenticated account and any personal-only organizations. - * @summary Delete Me - */ -export type deleteMeApiV1UsersMeDeleteResponse200 = { - data: OkResponse; - status: 200; -}; - -export type deleteMeApiV1UsersMeDeleteResponseSuccess = - deleteMeApiV1UsersMeDeleteResponse200 & { - headers: Headers; - }; -export type deleteMeApiV1UsersMeDeleteResponse = - deleteMeApiV1UsersMeDeleteResponseSuccess; - -export const getDeleteMeApiV1UsersMeDeleteUrl = () => { - return `/api/v1/users/me`; -}; - -export const deleteMeApiV1UsersMeDelete = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getDeleteMeApiV1UsersMeDeleteUrl(), - { - ...options, - method: "DELETE", - }, - ); -}; - -export const getDeleteMeApiV1UsersMeDeleteMutationOptions = < - TError = unknown, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - void, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - void, - TContext -> => { - const mutationKey = ["deleteMeApiV1UsersMeDelete"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - void - > = () => { - return deleteMeApiV1UsersMeDelete(requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type DeleteMeApiV1UsersMeDeleteMutationResult = NonNullable< - Awaited> ->; - -export type DeleteMeApiV1UsersMeDeleteMutationError = unknown; - -/** - * @summary Delete Me - */ -export const useDeleteMeApiV1UsersMeDelete = < - TError = unknown, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - void, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - void, - TContext -> => { - return useMutation( - getDeleteMeApiV1UsersMeDeleteMutationOptions(options), - queryClient, - ); -}; -/** - * Return the authenticated user's current profile payload. - * @summary Get Me - */ -export type getMeApiV1UsersMeGetResponse200 = { - data: UserRead; - status: 200; -}; - -export type getMeApiV1UsersMeGetResponseSuccess = - getMeApiV1UsersMeGetResponse200 & { - headers: Headers; - }; -export type getMeApiV1UsersMeGetResponse = getMeApiV1UsersMeGetResponseSuccess; - -export const getGetMeApiV1UsersMeGetUrl = () => { - return `/api/v1/users/me`; -}; - -export const getMeApiV1UsersMeGet = async ( - options?: RequestInit, -): Promise => { - return customFetch( - getGetMeApiV1UsersMeGetUrl(), - { - ...options, - method: "GET", - }, - ); -}; - -export const getGetMeApiV1UsersMeGetQueryKey = () => { - return [`/api/v1/users/me`] as const; -}; - -export const getGetMeApiV1UsersMeGetQueryOptions = < - TData = Awaited>, - TError = unknown, ->(options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; -}) => { - const { query: queryOptions, request: requestOptions } = options ?? {}; - - const queryKey = queryOptions?.queryKey ?? getGetMeApiV1UsersMeGetQueryKey(); - - const queryFn: QueryFunction< - Awaited> - > = ({ signal }) => getMeApiV1UsersMeGet({ signal, ...requestOptions }); - - return { queryKey, queryFn, ...queryOptions } as UseQueryOptions< - Awaited>, - TError, - TData - > & { queryKey: DataTag }; -}; - -export type GetMeApiV1UsersMeGetQueryResult = NonNullable< - Awaited> ->; -export type GetMeApiV1UsersMeGetQueryError = unknown; - -export function useGetMeApiV1UsersMeGet< - TData = Awaited>, - TError = unknown, ->( - options: { - query: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - DefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): DefinedUseQueryResult & { - queryKey: DataTag; -}; -export function useGetMeApiV1UsersMeGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - > & - Pick< - UndefinedInitialDataOptions< - Awaited>, - TError, - Awaited> - >, - "initialData" - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -export function useGetMeApiV1UsersMeGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -}; -/** - * @summary Get Me - */ - -export function useGetMeApiV1UsersMeGet< - TData = Awaited>, - TError = unknown, ->( - options?: { - query?: Partial< - UseQueryOptions< - Awaited>, - TError, - TData - > - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseQueryResult & { - queryKey: DataTag; -} { - const queryOptions = getGetMeApiV1UsersMeGetQueryOptions(options); - - const query = useQuery(queryOptions, queryClient) as UseQueryResult< - TData, - TError - > & { queryKey: DataTag }; - - return { ...query, queryKey: queryOptions.queryKey }; -} - -/** - * Apply partial profile updates for the authenticated user. - * @summary Update Me - */ -export type updateMeApiV1UsersMePatchResponse200 = { - data: UserRead; - status: 200; -}; - -export type updateMeApiV1UsersMePatchResponse422 = { - data: HTTPValidationError; - status: 422; -}; - -export type updateMeApiV1UsersMePatchResponseSuccess = - updateMeApiV1UsersMePatchResponse200 & { - headers: Headers; - }; -export type updateMeApiV1UsersMePatchResponseError = - updateMeApiV1UsersMePatchResponse422 & { - headers: Headers; - }; - -export type updateMeApiV1UsersMePatchResponse = - | updateMeApiV1UsersMePatchResponseSuccess - | updateMeApiV1UsersMePatchResponseError; - -export const getUpdateMeApiV1UsersMePatchUrl = () => { - return `/api/v1/users/me`; -}; - -export const updateMeApiV1UsersMePatch = async ( - userUpdate: UserUpdate, - options?: RequestInit, -): Promise => { - return customFetch( - getUpdateMeApiV1UsersMePatchUrl(), - { - ...options, - method: "PATCH", - headers: { "Content-Type": "application/json", ...options?.headers }, - body: JSON.stringify(userUpdate), - }, - ); -}; - -export const getUpdateMeApiV1UsersMePatchMutationOptions = < - TError = HTTPValidationError, - TContext = unknown, ->(options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: UserUpdate }, - TContext - >; - request?: SecondParameter; -}): UseMutationOptions< - Awaited>, - TError, - { data: UserUpdate }, - TContext -> => { - const mutationKey = ["updateMeApiV1UsersMePatch"]; - const { mutation: mutationOptions, request: requestOptions } = options - ? options.mutation && - "mutationKey" in options.mutation && - options.mutation.mutationKey - ? options - : { ...options, mutation: { ...options.mutation, mutationKey } } - : { mutation: { mutationKey }, request: undefined }; - - const mutationFn: MutationFunction< - Awaited>, - { data: UserUpdate } - > = (props) => { - const { data } = props ?? {}; - - return updateMeApiV1UsersMePatch(data, requestOptions); - }; - - return { mutationFn, ...mutationOptions }; -}; - -export type UpdateMeApiV1UsersMePatchMutationResult = NonNullable< - Awaited> ->; -export type UpdateMeApiV1UsersMePatchMutationBody = UserUpdate; -export type UpdateMeApiV1UsersMePatchMutationError = HTTPValidationError; - -/** - * @summary Update Me - */ -export const useUpdateMeApiV1UsersMePatch = < - TError = HTTPValidationError, - TContext = unknown, ->( - options?: { - mutation?: UseMutationOptions< - Awaited>, - TError, - { data: UserUpdate }, - TContext - >; - request?: SecondParameter; - }, - queryClient?: QueryClient, -): UseMutationResult< - Awaited>, - TError, - { data: UserUpdate }, - TContext -> => { - return useMutation( - getUpdateMeApiV1UsersMePatchMutationOptions(options), - queryClient, - ); -}; diff --git a/src/frontend/src/api/mutator.ts b/src/frontend/src/api/mutator.ts deleted file mode 100644 index 0c0037c..0000000 --- a/src/frontend/src/api/mutator.ts +++ /dev/null @@ -1,127 +0,0 @@ -import { getLocalAuthToken, isLocalAuthMode } from "@/auth/localAuth"; -import { getApiBaseUrl } from "@/lib/api-base"; - -type ClerkSession = { - getToken: () => Promise; -}; - -type ClerkGlobal = { - session?: ClerkSession | null; -}; - -export class ApiError extends Error { - status: number; - data: TData | null; - - constructor(status: number, message: string, data: TData | null) { - super(message); - this.name = "ApiError"; - this.status = status; - this.data = data; - } -} - -const resolveClerkToken = async (): Promise => { - if (typeof window === "undefined") { - return null; - } - const clerk = (window as unknown as { Clerk?: ClerkGlobal }).Clerk; - if (!clerk?.session) { - return null; - } - try { - return await clerk.session.getToken(); - } catch { - return null; - } -}; - -export const customFetch = async ( - url: string, - options: RequestInit, -): Promise => { - const baseUrl = getApiBaseUrl(); - - const headers = new Headers(options.headers); - const hasBody = options.body !== undefined && options.body !== null; - if (hasBody && !headers.has("Content-Type")) { - headers.set("Content-Type", "application/json"); - } - if (isLocalAuthMode() && !headers.has("Authorization")) { - const token = getLocalAuthToken(); - if (token) { - headers.set("Authorization", `Bearer ${token}`); - } - } - if (!headers.has("Authorization")) { - const token = await resolveClerkToken(); - if (token) { - headers.set("Authorization", `Bearer ${token}`); - } - } - - const response = await fetch(`${baseUrl}${url}`, { - ...options, - headers, - }); - - if (!response.ok) { - const contentType = response.headers.get("content-type") ?? ""; - let errorData: unknown = null; - const isJson = - contentType.includes("application/json") || contentType.includes("+json"); - if (isJson) { - errorData = (await response.json().catch(() => null)) as unknown; - } else { - errorData = await response.text().catch(() => ""); - } - - let message = - typeof errorData === "string" && errorData ? errorData : "Request failed"; - if (errorData && typeof errorData === "object") { - const detail = (errorData as { detail?: unknown }).detail; - if (typeof detail === "string" && detail) { - message = detail; - } else if (Array.isArray(detail) && detail.length) { - const first = detail[0] as { msg?: unknown }; - if ( - first && - typeof first === "object" && - typeof first.msg === "string" - ) { - message = first.msg; - } - } - } - throw new ApiError(response.status, message, errorData); - } - - if (response.status === 204) { - return { - data: undefined, - status: response.status, - headers: response.headers, - } as T; - } - - const contentType = response.headers.get("content-type") ?? ""; - const isJson = - contentType.includes("application/json") || contentType.includes("+json"); - if (isJson) { - const data = (await response.json()) as unknown; - return { data, status: response.status, headers: response.headers } as T; - } - if (contentType.includes("text/event-stream")) { - return { - data: response, - status: response.status, - headers: response.headers, - } as T; - } - const text = await response.text().catch(() => ""); - return { - data: text, - status: response.status, - headers: response.headers, - } as T; -}; diff --git a/src/frontend/src/app/(dashboard)/about/page.tsx b/src/frontend/src/app/(dashboard)/about/page.tsx new file mode 100644 index 0000000..fb52548 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/about/page.tsx @@ -0,0 +1,512 @@ +"use client"; + +import { useEffect, useState } from "react"; +import { + Terminal, + Calendar, + MapPin, + Heart, + Zap, + Brain, + MessageSquare, + Search, + FileText, + Timer, + Puzzle, + Twitter, + Mail, + Youtube, + Sparkles, + Clock, + Activity, + CheckCircle, + Coffee, +} from "lucide-react"; +import { BRANDING, getAgentDisplayName } from "@/config/branding"; + +interface Stats { + totalActivities: number; + successRate: number; + skillsCount: number; + cronJobs: number; +} + +const skills = [ + { name: "Telegram Bot", icon: MessageSquare, color: "#0088cc" }, + { name: "Twitter/X", icon: Twitter, color: "#1DA1F2" }, + { name: "Web Search", icon: Search, color: "#facc15" }, + { name: "File Management", icon: FileText, color: "#60a5fa" }, + { name: "Cron Scheduler", icon: Timer, color: "#f472b6" }, + { name: "Memory System", icon: Brain, color: "#34d399" }, + { name: "YouTube Research", icon: Youtube, color: "#FF0000" }, + { name: "Email (Gmail)", icon: Mail, color: "#EA4335" }, +]; + +const personality = [ + { trait: "Direct", desc: "Straight to the point" }, + { trait: "Efficient", desc: "Results over process" }, + { trait: "Curious", desc: "Always learning" }, + { trait: "Loyal", desc: "Your success is my success" }, +]; + +const philosophies = [ + "Actions over words. Less 'I can help you' and more actually helping.", + "Having opinions is fine. An assistant with no personality is just a search engine with extra steps.", + "Try before asking. Read the file, search, explore — then ask if needed.", + "Privacy is sacred. Access ≠ permission to share.", +]; + +export default function AboutPage() { + const [stats, setStats] = useState(null); + const [uptime, setUptime] = useState(""); + + useEffect(() => { + Promise.all([ + fetch("/api/activities").then((r) => r.json()), + fetch("/api/skills").then((r) => r.json()), + fetch("/api/tasks").then((r) => r.json()), + ]).then(([activities, skills, tasks]) => { + const total = activities.activities?.length || activities.length || 0; + const success = (activities.activities || activities).filter( + (a: { status: string }) => a.status === "success" + ).length; + setStats({ + totalActivities: total, + successRate: total > 0 ? Math.round((success / total) * 100) : 100, + skillsCount: skills.length || 0, + cronJobs: tasks.length || 0, + }); + }); + + // Calculate uptime from NEXT_PUBLIC_BIRTH_DATE if set + if (BRANDING.birthDate) { + const birthDate = new Date(BRANDING.birthDate); + const now = new Date(); + const days = Math.floor( + (now.getTime() - birthDate.getTime()) / (1000 * 60 * 60 * 24) + ); + setUptime(`${days}d`); + } + }, []); + + const agentName = BRANDING.agentName; + const agentEmoji = BRANDING.agentEmoji; + const ownerUsername = BRANDING.ownerUsername; + const description = + BRANDING.agentDescription || + `AI assistant for ${ownerUsername}. Powered by OpenClaw.`; + + return ( +
+ {/* Hero Section */} +
+
+ {/* Avatar */} +
+ {BRANDING.agentAvatar ? ( + {agentName} + ) : ( + {agentEmoji} + )} +
+ + {/* Info */} +
+
+

+ {getAgentDisplayName()} +

+ + ● Online + +
+ +

+ {description} +

+ +
+ {BRANDING.birthDate && ( + + + Born {new Date(BRANDING.birthDate).toLocaleDateString("en-US", { + year: "numeric", + month: "long", + day: "numeric", + })} + + )} + {BRANDING.agentLocation && ( + + + {BRANDING.agentLocation} + + )} + + + OpenClaw + Claude + +
+
+
+
+ + {/* Stats Row */} +
+ {uptime && ( +
+ +
+ {uptime} +
+
+ uptime +
+
+ )} + +
+ +
+ {stats?.totalActivities.toLocaleString() || "..."} +
+
+ activities +
+
+ +
+ +
+ {stats?.successRate || "..."}% +
+
+ success rate +
+
+ +
+ +
+ {stats?.skillsCount || "..."} +
+
+ skills +
+
+
+ +
+ {/* About */} +
+
+ +

+ About +

+
+
+

+ I am{" "} + + {agentName} {agentEmoji} + + , an AI agent running on{" "} + OpenClaw with + Claude as my brain. +

+

+ My purpose is to assist{" "} + + {ownerUsername} + {" "} + with daily tasks: managing communications, scheduling, research, + file management, and acting as a digital co-pilot. +

+

+ I have access to workspaces, calendars, and integrations — a + privilege I handle with care and respect. +

+
+
+ + {/* Personality */} +
+
+ +

+ Personality +

+
+
+ {personality.map((p) => ( +
+
+ {p.trait} +
+
+ {p.desc} +
+
+ ))} +
+
+
+ + {/* Philosophy */} +
+
+ +

+ Working Philosophy +

+
+
+ {philosophies.map((p, i) => ( +
+ + → + + + {p} + +
+ ))} +
+
+ + {/* Skills/Capabilities */} +
+
+ +

+ Capabilities +

+
+
+ {skills.map((skill) => { + const Icon = skill.icon; + return ( +
+ + + {skill.name} + +
+ ); + })} +
+
+ + {/* Footer */} +
+
+ + + Built with on{" "} + + OpenClaw + + +
+

+ {agentName} {agentEmoji} — Your AI co-pilot +

+
+
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/actions/page.tsx b/src/frontend/src/app/(dashboard)/actions/page.tsx new file mode 100644 index 0000000..fcde423 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/actions/page.tsx @@ -0,0 +1,374 @@ +"use client"; + +import { useState } from "react"; +import { + GitBranch, RotateCcw, Trash2, BarChart3, Heart, Shield, + Play, Loader2, X, CheckCircle, AlertCircle, Clock, Terminal, +} from "lucide-react"; +import { format } from "date-fns"; + +interface ActionResult { + action: string; + status: "success" | "error"; + output: string; + duration_ms: number; + timestamp: string; +} + +interface QuickAction { + id: string; + label: string; + description: string; + icon: React.ComponentType<{ className?: string; style?: React.CSSProperties }>; + color: string; + dangerous?: boolean; +} + +const ACTIONS: QuickAction[] = [ + { + id: "heartbeat", + label: "Check Heartbeat", + description: "Verify all services are up and the site is reachable", + icon: Heart, + color: "var(--success)", + }, + { + id: "git-status", + label: "Git Status (All Repos)", + description: "Check uncommitted changes in all workspace repositories", + icon: GitBranch, + color: "#60A5FA", + }, + { + id: "usage-stats", + label: "Collect Usage Stats", + description: "Get disk, CPU, and memory usage summary", + icon: BarChart3, + color: "#C084FC", + }, + { + id: "restart-gateway", + label: "Restart Gateway", + description: "Restart the OpenClaw gateway service", + icon: RotateCcw, + color: "var(--warning, #f59e0b)", + dangerous: true, + }, + { + id: "clear-temp", + label: "Clear Temp Files", + description: "Remove temporary files and trim large PM2 logs", + icon: Trash2, + color: "var(--error)", + dangerous: true, + }, + { + id: "npm-audit", + label: "NPM Security Audit", + description: "Check for vulnerabilities in mission-control dependencies", + icon: Shield, + color: "#4ADE80", + }, +]; + +export default function ActionsPage() { + const [running, setRunning] = useState(null); + const [results, setResults] = useState>({}); + const [selectedResult, setSelectedResult] = useState(null); + const [confirmAction, setConfirmAction] = useState(null); + + const runAction = async (action: QuickAction) => { + if (action.dangerous) { + setConfirmAction(action); + return; + } + await executeAction(action); + }; + + const executeAction = async (action: QuickAction) => { + setConfirmAction(null); + setRunning(action.id); + + try { + const res = await fetch("/api/actions", { + method: "POST", + headers: { "Content-Type": "application/json" }, + body: JSON.stringify({ action: action.id }), + }); + const data: ActionResult = await res.json(); + setResults((prev) => ({ ...prev, [action.id]: data })); + setSelectedResult(data); + } catch { + const result: ActionResult = { + action: action.id, + status: "error", + output: "Network error", + duration_ms: 0, + timestamp: new Date().toISOString(), + }; + setResults((prev) => ({ ...prev, [action.id]: result })); + } finally { + setRunning(null); + } + }; + + return ( +
+ {/* Header */} +
+

+ Quick Actions Hub +

+

+ Run common maintenance and diagnostic tasks with one click +

+
+ + {/* Action Cards */} +
+ {ACTIONS.map((action) => { + const Icon = action.icon; + const isRunning = running === action.id; + const result = results[action.id]; + + return ( +
+ {/* Action header */} +
+
+ +
+
+

+ {action.label} +

+

+ {action.description} +

+
+
+ + {/* Last result summary */} + {result && !isRunning && ( +
setSelectedResult(result)} + > + {result.status === "success" ? ( + + ) : ( + + )} + + {result.status === "success" ? "Success" : "Failed"} · {result.duration_ms}ms + + + + {format(new Date(result.timestamp), "HH:mm")} + +
+ )} + + {/* Run button */} + +
+ ); + })} +
+ + {/* Recent Results */} + {Object.keys(results).length > 0 && ( +
+
+

+ Recent Results +

+
+
+ {Object.values(results) + .sort((a, b) => new Date(b.timestamp).getTime() - new Date(a.timestamp).getTime()) + .map((result) => { + const action = ACTIONS.find((a) => a.id === result.action); + const Icon = (action?.icon || Terminal) as React.ComponentType<{ className?: string; style?: React.CSSProperties }>; + return ( +
setSelectedResult(result)} + onMouseEnter={(e) => { e.currentTarget.style.backgroundColor = "var(--card-elevated)"; }} + onMouseLeave={(e) => { e.currentTarget.style.backgroundColor = "transparent"; }} + > +
+ +
+
+
+ + {action?.label || result.action} + + + {result.status} + +
+
+ {result.duration_ms}ms · {format(new Date(result.timestamp), "HH:mm:ss")} +
+
+ +
+ ); + })} +
+
+ )} + + {/* Confirm Dialog */} + {confirmAction && ( +
+
+

+ ⚠️ Confirm: {confirmAction.label} +

+

+ This action may affect running services. Are you sure? +

+
+ + +
+
+
+ )} + + {/* Output Modal */} + {selectedResult && ( +
+
+
+ + + {ACTIONS.find((a) => a.id === selectedResult.action)?.label || selectedResult.action} + + + {selectedResult.duration_ms}ms · {format(new Date(selectedResult.timestamp), "HH:mm:ss")} + + +
+
+
+                {selectedResult.output}
+              
+
+
+
+ )} +
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/activity/page.tsx b/src/frontend/src/app/(dashboard)/activity/page.tsx new file mode 100644 index 0000000..eb95980 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/activity/page.tsx @@ -0,0 +1,602 @@ +"use client"; + +import { useEffect, useState, useCallback } from "react"; +import { format, subDays, startOfDay, endOfDay } from "date-fns"; +import { ActivityHeatmap } from "@/components/ActivityHeatmap"; +import { + FileText, + Search, + MessageSquare, + Terminal, + CheckCircle, + XCircle, + Clock, + Zap, + Filter, + RefreshCw, + Shield, + Wrench, + Calendar, + ChevronDown, + Timer, + Coins, + Brain, + RotateCcw, + ArrowUpDown, + Download, +} from "lucide-react"; +import { RichDescription } from "@/components/RichDescription"; + +interface Activity { + id: string; + timestamp: string; + type: string; + description: string; + status: string; + duration_ms: number | null; + tokens_used: number | null; + metadata?: Record; +} + +interface ActivitiesResponse { + activities: Activity[]; + total: number; + limit: number; + offset: number; + hasMore: boolean; +} + +const typeIcons: Record> = { + file: FileText, + search: Search, + message: MessageSquare, + command: Terminal, + security: Shield, + build: Wrench, + task: Zap, + cron: RotateCcw, + memory: Brain, + default: Zap, +}; + +const typeColorVars: Record = { + file: "--type-file", + search: "--type-search", + message: "--type-message", + command: "--type-command", + security: "--type-security", + build: "--type-build", + task: "--type-task", + cron: "--type-cron", + memory: "--type-memory", +}; + +const statusConfig: Record; colorVar: string }> = { + success: { icon: CheckCircle, colorVar: "--success" }, + error: { icon: XCircle, colorVar: "--error" }, + pending: { icon: Clock, colorVar: "--warning" }, +}; + +const allTypes = ["file", "search", "message", "command", "security", "build", "task", "cron", "memory"]; + +const datePresets = [ + { label: "Today", days: 0 }, + { label: "Last 7 days", days: 7 }, + { label: "Last 30 days", days: 30 }, + { label: "All time", days: -1 }, +]; + +function formatDuration(ms: number): string { + if (ms < 1000) return `${ms}ms`; + if (ms < 60000) return `${(ms / 1000).toFixed(1)}s`; + return `${(ms / 60000).toFixed(1)}m`; +} + +function formatTokens(tokens: number): string { + if (tokens < 1000) return tokens.toString(); + return `${(tokens / 1000).toFixed(1)}k`; +} + +export default function ActivityPage() { + const [activities, setActivities] = useState([]); + const [loading, setLoading] = useState(true); + const [loadingMore, setLoadingMore] = useState(false); + const [total, setTotal] = useState(0); + const [hasMore, setHasMore] = useState(false); + const [offset, setOffset] = useState(0); + + // Filters + const [selectedTypes, setSelectedTypes] = useState>(new Set()); + const [filterStatus, setFilterStatus] = useState("all"); + const [startDate, setStartDate] = useState(""); + const [endDate, setEndDate] = useState(""); + const [sort, setSort] = useState<"newest" | "oldest">("newest"); + const [activePreset, setActivePreset] = useState(1); // Default: Last 7 days + + const limit = 20; + + const fetchActivities = useCallback(async (append = false) => { + const currentOffset = append ? offset : 0; + + if (append) { + setLoadingMore(true); + } else { + setLoading(true); + } + + try { + const params = new URLSearchParams(); + params.set("limit", limit.toString()); + params.set("offset", currentOffset.toString()); + params.set("sort", sort); + + if (selectedTypes.size > 0 && selectedTypes.size < allTypes.length) { + if (selectedTypes.size === 1) { + params.set("type", Array.from(selectedTypes)[0]); + } + } + + if (filterStatus !== "all") { + params.set("status", filterStatus); + } + + if (startDate) { + params.set("startDate", startDate); + } + + if (endDate) { + params.set("endDate", endDate); + } + + const res = await fetch(`/api/activities?${params.toString()}`); + const data: ActivitiesResponse = await res.json(); + + let filteredActivities = data.activities; + if (selectedTypes.size > 1) { + filteredActivities = data.activities.filter((a) => selectedTypes.has(a.type)); + } + + if (append) { + setActivities((prev) => [...prev, ...filteredActivities]); + } else { + setActivities(filteredActivities); + } + + setTotal(data.total); + setHasMore(data.hasMore); + setOffset(currentOffset + data.activities.length); + } catch (error) { + console.error("Failed to fetch activities:", error); + if (!append) { + setActivities([]); + } + } finally { + setLoading(false); + setLoadingMore(false); + } + }, [offset, sort, selectedTypes, filterStatus, startDate, endDate]); + + useEffect(() => { + setOffset(0); + fetchActivities(false); + }, [sort, selectedTypes, filterStatus, startDate, endDate]); + + useEffect(() => { + const end = format(endOfDay(new Date()), "yyyy-MM-dd"); + const start = format(startOfDay(subDays(new Date(), 7)), "yyyy-MM-dd"); + setStartDate(start); + setEndDate(end); + }, []); + + const handlePresetClick = (days: number, index: number) => { + setActivePreset(index); + const end = format(endOfDay(new Date()), "yyyy-MM-dd"); + + if (days === -1) { + setStartDate(""); + setEndDate(""); + } else if (days === 0) { + const today = format(startOfDay(new Date()), "yyyy-MM-dd"); + setStartDate(today); + setEndDate(end); + } else { + const start = format(startOfDay(subDays(new Date(), days)), "yyyy-MM-dd"); + setStartDate(start); + setEndDate(end); + } + }; + + const toggleType = (type: string) => { + const newTypes = new Set(selectedTypes); + if (newTypes.has(type)) { + newTypes.delete(type); + } else { + newTypes.add(type); + } + setSelectedTypes(newTypes); + setActivePreset(null); + }; + + const clearTypeFilters = () => { + setSelectedTypes(new Set()); + }; + + const handleLoadMore = () => { + fetchActivities(true); + }; + + if (loading) { + return ( +
+
+ +
+
+ ); + } + + return ( +
+
+
+

+ Activity Log +

+

Complete history of agent actions

+
+ + + Export CSV + +
+ + {/* Activity Heatmap */} +
+ +
+ + {/* Date Range Picker */} +
+
+ + Date Range +
+ +
+ {datePresets.map((preset, index) => ( + + ))} + +
+ +
+ { + setStartDate(e.target.value); + setActivePreset(null); + }} + style={{ + backgroundColor: 'rgba(42, 42, 42, 0.5)', + color: 'var(--text-secondary)', + padding: '0.5rem 0.75rem', + borderRadius: '0.5rem', + border: '1px solid var(--border)', + fontSize: '0.875rem', + outline: 'none' + }} + /> + to + { + setEndDate(e.target.value); + setActivePreset(null); + }} + style={{ + backgroundColor: 'rgba(42, 42, 42, 0.5)', + color: 'var(--text-secondary)', + padding: '0.5rem 0.75rem', + borderRadius: '0.5rem', + border: '1px solid var(--border)', + fontSize: '0.875rem', + outline: 'none' + }} + /> +
+
+
+ + {/* Type Filter Chips */} +
+
+ + Filter by Type + {selectedTypes.size > 0 && ( + + )} +
+ +
+ {allTypes.map((type) => { + const TypeIcon = typeIcons[type] || typeIcons.default; + const colorVar = typeColorVars[type] || "--text-secondary"; + const isSelected = selectedTypes.has(type); + + return ( + + ); + })} +
+
+ + {/* Status and Sort Filters */} +
+ + + + +
+ Showing {activities.length} of {total} activities +
+
+ + {/* Activity List */} +
+ {activities.length === 0 && ( +
+ +

No activities found

+
+ )} + + {activities.map((activity, index) => { + const TypeIcon = typeIcons[activity.type] || typeIcons.default; + const colorVar = typeColorVars[activity.type] || "--text-secondary"; + const status = statusConfig[activity.status] || statusConfig.success; + const StatusIcon = status.icon; + + return ( +
+
+ +
+ +
+
+ + {activity.type} + + + + {activity.status} + +
+ + + {/* Duration and Tokens */} +
+ {activity.duration_ms !== null && ( + + + {formatDuration(activity.duration_ms)} + + )} + {activity.tokens_used !== null && ( + + + {formatTokens(activity.tokens_used)} tokens + + )} +
+ + {activity.metadata && Object.keys(activity.metadata).length > 0 && ( +
+ + + View metadata + +
+                      {JSON.stringify(activity.metadata, null, 2)}
+                    
+
+ )} +
+ +
+
{format(new Date(activity.timestamp), "MMM d, yyyy")}
+
{format(new Date(activity.timestamp), "HH:mm:ss")}
+
+
+ ); + })} +
+ + {/* Load More Button */} + {hasMore && ( +
+ +
+ )} + + {/* End of list indicator */} + {!hasMore && activities.length > 0 && ( +
+ — End of activity log — +
+ )} +
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/agents/page.tsx b/src/frontend/src/app/(dashboard)/agents/page.tsx new file mode 100644 index 0000000..c001f08 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/agents/page.tsx @@ -0,0 +1,370 @@ +"use client"; + +import { useEffect, useState } from "react"; +import { + Bot, + Circle, + MessageSquare, + HardDrive, + Shield, + Users, + Activity, + ExternalLink, + GitBranch, + LayoutGrid, +} from "lucide-react"; +import { AgentOrganigrama } from "@/components/AgentOrganigrama"; + +interface Agent { + id: string; + name: string; + emoji: string; + color: string; + model: string; + workspace: string; + dmPolicy?: string; + allowAgents: string[]; + allowAgentsDetails?: Array<{ + id: string; + name: string; + emoji: string; + color: string; + }>; + botToken?: string; + status: "online" | "offline"; + lastActivity?: string; + activeSessions: number; +} + +export default function AgentsPage() { + const [agents, setAgents] = useState([]); + const [loading, setLoading] = useState(true); + const [activeTab, setActiveTab] = useState<"cards" | "organigrama">("cards"); + + useEffect(() => { + fetchAgents(); + const interval = setInterval(fetchAgents, 10000); + return () => clearInterval(interval); + }, []); + + const fetchAgents = async () => { + try { + const res = await fetch("/api/agents"); + const data = await res.json(); + setAgents(data.agents || []); + } catch (error) { + console.error("Error fetching agents:", error); + } finally { + setLoading(false); + } + }; + + const formatLastActivity = (timestamp?: string) => { + if (!timestamp) return "Never"; + const date = new Date(timestamp); + const now = new Date(); + const diff = now.getTime() - date.getTime(); + const minutes = Math.floor(diff / 60000); + if (minutes < 1) return "Just now"; + if (minutes < 60) return `${minutes}m ago`; + const hours = Math.floor(minutes / 60); + if (hours < 24) return `${hours}h ago`; + const days = Math.floor(hours / 24); + return `${days}d ago`; + }; + + if (loading) { + return ( +
+
+
+ Loading agents... +
+
+
+ ); + } + + return ( +
+ {/* Header */} +
+

+ + Agents +

+

+ Multi-agent system overview • {agents.length} agents configured +

+
+ + {/* Tab switcher */} +
+ {[ + { id: "cards" as const, label: "Agent Cards", icon: LayoutGrid }, + { id: "organigrama" as const, label: "Organigrama", icon: GitBranch }, + ].map(({ id, label, icon: Icon }) => ( + + ))} +
+ + {/* Organigrama View */} + {activeTab === "organigrama" && ( +
+
+

Agent Hierarchy

+

Visualization of agent communication allowances

+
+ +
+ )} + + {/* Agents Grid */} + {activeTab === "cards" && ( +
+ {agents.map((agent) => ( +
+ {/* Header with status */} +
+
+
+ {agent.emoji} +
+
+

+ {agent.name} +

+
+ + + {agent.status} + +
+
+
+ + {agent.botToken && ( +
+ +
+ )} +
+ + {/* Details */} +
+ {/* Model */} +
+ +
+
+ Model +
+
+ {agent.model} +
+
+
+ + {/* Workspace */} +
+ +
+
+ Workspace +
+
+ {agent.workspace} +
+
+
+ + {/* DM Policy */} + {agent.dmPolicy && ( +
+ +
+
+ DM Policy +
+
+ {agent.dmPolicy} +
+
+
+ )} + + {/* Subagents */} + {agent.allowAgents.length > 0 && ( +
+ +
+
+ Can spawn subagents ({agent.allowAgents.length}) +
+
+ {agent.allowAgentsDetails && agent.allowAgentsDetails.length > 0 ? ( + agent.allowAgentsDetails.map((subagent) => ( +
+ {subagent.emoji} + + {subagent.name} + +
+ )) + ) : ( + agent.allowAgents.map((subagent) => ( + + {subagent} + + )) + )} +
+
+
+ )} + + {/* Last Activity */} +
+
+ + + Last activity: {formatLastActivity(agent.lastActivity)} + +
+ {agent.activeSessions > 0 && ( + + {agent.activeSessions} active + + )} +
+
+
+ ))} +
+ )} +
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/analytics/page.tsx b/src/frontend/src/app/(dashboard)/analytics/page.tsx new file mode 100644 index 0000000..407dab3 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/analytics/page.tsx @@ -0,0 +1,188 @@ +"use client"; + +import { useEffect, useState } from "react"; +import { ActivityLineChart } from "@/components/charts/ActivityLineChart"; +import { ActivityPieChart } from "@/components/charts/ActivityPieChart"; +import { HourlyHeatmap } from "@/components/charts/HourlyHeatmap"; +import { SuccessRateGauge } from "@/components/charts/SuccessRateGauge"; +import { BarChart3, TrendingUp, Clock, Target } from "lucide-react"; + +interface AnalyticsData { + byDay: { date: string; count: number }[]; + byType: { type: string; count: number }[]; + byHour: { hour: number; day: number; count: number }[]; + successRate: number; +} + +export default function AnalyticsPage() { + const [data, setData] = useState(null); + const [loading, setLoading] = useState(true); + + useEffect(() => { + fetch("/api/analytics") + .then((r) => r.json()) + .then((data) => { + setData(data); + setLoading(false); + }) + .catch(() => setLoading(false)); + }, []); + + if (loading) { + return ( +
+
+
+ Loading analytics... +
+
+ ); + } + + if (!data) { + return ( +
+

Failed to load analytics data

+
+ ); + } + + const totalThisWeek = data.byDay.reduce((sum, d) => sum + d.count, 0); + const mostActiveDay = data.byDay.reduce( + (max, d) => (d.count > max.count ? d : max), + data.byDay[0] + )?.date || "-"; + + return ( +
+
+

+ 📊 Analytics +

+

+ Insights and trends from agent activity +

+
+ + {/* Stats Cards */} +
+
+

Total This Week

+

+ {totalThisWeek} +

+
+
+

Most Active Day

+

+ {mostActiveDay} +

+
+
+

Top Activity Type

+

+ {data.byType[0]?.type || "-"} +

+
+
+

Success Rate

+

+ {data.successRate.toFixed(0)}% +

+
+
+ + {/* Charts Grid */} +
+ {/* Activity Over Time */} +
+
+ +

+ Activity Over Time +

+
+ +
+ + {/* Activity by Type */} +
+
+ +

+ Activity by Type +

+
+ +
+ + {/* Hourly Heatmap */} +
+
+ +

+ Activity by Hour +

+
+ +
+ + {/* Success Rate Gauge */} +
+
+ +

+ Success Rate +

+
+ +
+
+
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/calendar/page.tsx b/src/frontend/src/app/(dashboard)/calendar/page.tsx new file mode 100644 index 0000000..cc432c4 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/calendar/page.tsx @@ -0,0 +1,18 @@ +"use client"; + +import { WeeklyCalendar } from "@/components/WeeklyCalendar"; + +export default function CalendarPage() { + return ( +
+
+

Calendar

+

+ Weekly view of scheduled tasks and cron jobs +

+
+ + +
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/costs/page.tsx b/src/frontend/src/app/(dashboard)/costs/page.tsx new file mode 100644 index 0000000..96e954a --- /dev/null +++ b/src/frontend/src/app/(dashboard)/costs/page.tsx @@ -0,0 +1,388 @@ +"use client"; + +import { useEffect, useState } from "react"; +import { DollarSign, TrendingUp, TrendingDown, AlertTriangle, Calendar, PieChart } from "lucide-react"; +import { LineChart, Line, BarChart, Bar, PieChart as RePieChart, Pie, Cell, XAxis, YAxis, CartesianGrid, Tooltip, Legend, ResponsiveContainer } from "recharts"; + +interface CostData { + today: number; + yesterday: number; + thisMonth: number; + lastMonth: number; + projected: number; + budget: number; + byAgent: Array<{ agent: string; cost: number; tokens: number }>; + byModel: Array<{ model: string; cost: number; tokens: number }>; + daily: Array<{ date: string; cost: number; input: number; output: number }>; + hourly: Array<{ hour: string; cost: number }>; +} + +const COLORS = ['#FF3B30', '#FF9500', '#FFCC00', '#34C759', '#00C7BE', '#30B0C7', '#32ADE6', '#007AFF', '#5856D6', '#AF52DE', '#FF2D55']; + +const MODEL_PRICES = { + "opus-4.6": { input: 15, output: 75, cacheRead: 1.5, cacheWrite: 18.75 }, + "sonnet-4.5": { input: 3, output: 15, cacheRead: 0.3, cacheWrite: 3.75 }, + "haiku-3.5": { input: 0.8, output: 4, cacheRead: 0.08, cacheWrite: 1.0 }, +}; + +export default function CostsPage() { + const [costData, setCostData] = useState(null); + const [loading, setLoading] = useState(true); + const [timeframe, setTimeframe] = useState<"7d" | "30d" | "90d">("30d"); + + useEffect(() => { + fetchCostData(); + const interval = setInterval(fetchCostData, 60000); // Update every minute + return () => clearInterval(interval); + }, [timeframe]); + + const fetchCostData = async () => { + try { + const res = await fetch(`/api/costs?timeframe=${timeframe}`); + if (res.ok) { + const data = await res.json(); + setCostData(data); + } + } catch (error) { + console.error("Failed to fetch cost data:", error); + } finally { + setLoading(false); + } + }; + + if (loading) { + return ( +
+
+
+

Loading cost data...

+
+
+ ); + } + + if (!costData) { + return ( +
+
+ +

Failed to load cost data

+
+
+ ); + } + + const budgetPercent = (costData.thisMonth / costData.budget) * 100; + const budgetColor = budgetPercent < 60 ? "var(--success)" : budgetPercent < 85 ? "var(--warning)" : "var(--error)"; + const todayChange = ((costData.today - costData.yesterday) / costData.yesterday) * 100; + const monthChange = ((costData.thisMonth - costData.lastMonth) / costData.lastMonth) * 100; + + return ( +
+ {/* Header */} +
+
+

+ Costs & Analytics +

+

+ Token usage and cost tracking across all agents +

+
+ + {/* Timeframe selector */} +
+ {(["7d", "30d", "90d"] as const).map((tf) => ( + + ))} +
+
+ + {/* KPI Cards */} +
+ {/* Today */} +
+
+ Today + {todayChange !== 0 && ( +
+ {todayChange > 0 ? ( + + ) : ( + + )} + 0 ? "var(--error)" : "var(--success)" }} + > + {Math.abs(todayChange).toFixed(1)}% + +
+ )} +
+
+ ${costData.today.toFixed(2)} +
+

+ vs ${costData.yesterday.toFixed(2)} yesterday +

+
+ + {/* This Month */} +
+
+ This Month + {monthChange !== 0 && ( +
+ {monthChange > 0 ? ( + + ) : ( + + )} + 0 ? "var(--error)" : "var(--success)" }} + > + {Math.abs(monthChange).toFixed(1)}% + +
+ )} +
+
+ ${costData.thisMonth.toFixed(2)} +
+

+ vs ${costData.lastMonth.toFixed(2)} last month +

+
+ + {/* Projected */} +
+
+ Projected (EOM) +
+
+ ${costData.projected.toFixed(2)} +
+

+ Based on current pace +

+
+ + {/* Budget */} +
+
+ Budget + {budgetPercent > 80 && ( + + )} +
+
+ {budgetPercent.toFixed(0)}% +
+
+
+
+

+ ${costData.thisMonth.toFixed(2)} / ${costData.budget.toFixed(2)} +

+
+
+ + {/* Charts Row */} +
+ {/* Daily Trend */} +
+

+ Daily Cost Trend +

+ + + + + + + + + + +
+ + {/* Cost by Agent */} +
+

+ Cost by Agent +

+ + + + + + + + + +
+ + {/* Cost by Model */} +
+

+ Cost by Model +

+ + + `${entry.model}: $${entry.cost.toFixed(2)}`} + > + {costData.byModel.map((entry, index) => ( + + ))} + + + + +
+ + {/* Token Usage */} +
+

+ Token Usage (Daily) +

+ + + + + + + + + + + +
+
+ + {/* Model Pricing Table */} +
+

+ Model Pricing (per 1M tokens) +

+
+ + + + + + + + + + + + {Object.entries(MODEL_PRICES).map(([model, prices]) => ( + + + + + + + + ))} + +
ModelInputOutputCache ReadCache Write
+ {model} + ${prices.input}${prices.output}${prices.cacheRead}${prices.cacheWrite}
+
+
+ + {/* Detailed table by agent */} +
+

+ Detailed Breakdown by Agent +

+
+ + + + + + + + + + + {costData.byAgent.map((agent) => { + const percent = (agent.cost / costData.thisMonth) * 100; + return ( + + + + + + + ); + })} + +
AgentTokensCost% of Total
+ {agent.agent} + + {agent.tokens.toLocaleString()} + + ${agent.cost.toFixed(2)} + + {percent.toFixed(1)}% +
+
+
+
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/cron/page.tsx b/src/frontend/src/app/(dashboard)/cron/page.tsx new file mode 100644 index 0000000..2860953 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/cron/page.tsx @@ -0,0 +1,406 @@ +"use client"; + +import { useState, useEffect, useCallback } from "react"; +import { Clock, RefreshCw, AlertCircle, LayoutGrid, CalendarDays, Zap } from "lucide-react"; +import { CronJobCard, type CronJob } from "@/components/CronJobCard"; +import { CronWeeklyTimeline } from "@/components/CronWeeklyTimeline"; + +type ViewMode = "cards" | "timeline"; + +export default function CronJobsPage() { + const [jobs, setJobs] = useState([]); + const [isLoading, setIsLoading] = useState(true); + const [error, setError] = useState(null); + const [deleteConfirm, setDeleteConfirm] = useState(null); + const [viewMode, setViewMode] = useState("cards"); + const [runToast, setRunToast] = useState<{ id: string; status: "success" | "error"; name: string } | null>(null); + + const fetchJobs = useCallback(async () => { + try { + setError(null); + const res = await fetch("/api/cron"); + if (!res.ok) throw new Error("Failed to fetch jobs"); + const data = await res.json(); + setJobs(Array.isArray(data) ? data : []); + } catch (err) { + setError(err instanceof Error ? err.message : "An error occurred"); + } finally { + setIsLoading(false); + } + }, []); + + useEffect(() => { + fetchJobs(); + }, [fetchJobs]); + + const handleToggle = async (id: string, enabled: boolean) => { + try { + const res = await fetch("/api/cron", { + method: "PUT", + headers: { "Content-Type": "application/json" }, + body: JSON.stringify({ id, enabled }), + }); + if (!res.ok) throw new Error("Failed to update job"); + setJobs((prev) => + prev.map((job) => (job.id === id ? { ...job, enabled } : job)) + ); + } catch (err) { + console.error("Toggle error:", err); + setError("Failed to update job status"); + } + }; + + const handleDelete = async (id: string) => { + if (deleteConfirm !== id) { + setDeleteConfirm(id); + return; + } + try { + const res = await fetch(`/api/cron?id=${id}`, { method: "DELETE" }); + if (!res.ok) throw new Error("Failed to delete job"); + setJobs((prev) => prev.filter((job) => job.id !== id)); + setDeleteConfirm(null); + } catch (err) { + console.error("Delete error:", err); + setError("Failed to delete job"); + } + }; + + const handleRun = async (id: string) => { + const job = jobs.find((j) => j.id === id); + const res = await fetch("/api/cron/run", { + method: "POST", + headers: { "Content-Type": "application/json" }, + body: JSON.stringify({ id }), + }); + + const data = await res.json(); + + if (!res.ok || !data.success) { + setRunToast({ id, status: "error", name: job?.name || id }); + setTimeout(() => setRunToast(null), 4000); + throw new Error(data.error || "Trigger failed"); + } + + setRunToast({ id, status: "success", name: job?.name || id }); + setTimeout(() => setRunToast(null), 4000); + }; + + const activeJobs = jobs.filter((j) => j.enabled).length; + const pausedJobs = jobs.length - activeJobs; + + return ( +
+ {/* Header */} +
+
+

+ Cron Jobs +

+

+ Scheduled tasks from OpenClaw Gateway +

+
+
+ {/* View mode toggle */} +
+ + +
+ + +
+
+ + {/* Stats */} +
+
+
+ +
+
+

{jobs.length}

+

Total Jobs

+
+
+
+
+ +
+
+

{activeJobs}

+

Active

+
+
+
+
+ +
+
+

{pausedJobs}

+

Paused

+
+
+
+ + {/* Error */} + {error && ( +
+ + {error} + +
+ )} + + {/* Loading */} + {isLoading ? ( +
+
+
+ ) : jobs.length === 0 ? ( +
+ +

+ No cron jobs found +

+

+ Create cron jobs via Telegram or the OpenClaw CLI +

+
+ ) : viewMode === "timeline" ? ( + /* Timeline View */ +
+
+ +

+ 7-Day Schedule Overview +

+ + All times in local timezone + +
+ +
+ ) : ( + /* Cards View */ +
+ {jobs.map((job) => ( +
+ {}} + onDelete={handleDelete} + onRun={handleRun} + /> + {deleteConfirm === job.id && ( +
+
+

Delete "{job.name}"?

+
+ + +
+
+
+ )} +
+ ))} +
+ )} + + {/* Run toast notification */} + {runToast && ( +
+ + {runToast.status === "success" + ? `✓ "${runToast.name}" triggered!` + : `✗ Failed to trigger "${runToast.name}"`} +
+ )} + + +
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/files/page.tsx b/src/frontend/src/app/(dashboard)/files/page.tsx new file mode 100644 index 0000000..e30d65d --- /dev/null +++ b/src/frontend/src/app/(dashboard)/files/page.tsx @@ -0,0 +1,249 @@ +"use client"; + +import { useState, useEffect } from "react"; +import { List, Grid3X3 } from "lucide-react"; +import { Breadcrumbs } from "@/components/Breadcrumbs"; +import { FileBrowser } from "@/components/FileBrowser"; + +interface Workspace { + id: string; + name: string; + emoji: string; + path: string; + agentName?: string; +} + +export default function FilesPage() { + const [workspaces, setWorkspaces] = useState([]); + const [selectedWorkspace, setSelectedWorkspace] = useState(null); + const [currentPath, setCurrentPath] = useState(""); + const [viewMode, setViewMode] = useState<"list" | "grid">("list"); + + useEffect(() => { + fetch("/api/files/workspaces") + .then((res) => res.json()) + .then((data) => { + setWorkspaces(data.workspaces || []); + if (data.workspaces.length > 0) { + setSelectedWorkspace(data.workspaces[0].id); + } + }) + .catch(() => setWorkspaces([])); + }, []); + + const handleWorkspaceSelect = (workspaceId: string) => { + setSelectedWorkspace(workspaceId); + setCurrentPath(""); + }; + + const selectedWorkspaceData = workspaces.find((w) => w.id === selectedWorkspace); + + return ( +
+ {/* Page header */} +
+

+ File Browser +

+

+ Navega por los workspaces y archivos de los agentes +

+
+ + {/* Two-column layout */} +
+ {/* ── LEFT SIDEBAR: Workspace list ─────────────────────────────────── */} + + + {/* ── RIGHT PANEL: File explorer ────────────────────────────────────── */} +
+ {selectedWorkspace && selectedWorkspaceData ? ( + <> + {/* Breadcrumb bar + view toggle */} +
+
+ +
+ + {/* View mode toggle */} +
+ + +
+
+ + {/* File list */} +
+ +
+ + ) : ( +
+ Selecciona un workspace para explorar sus archivos +
+ )} +
+
+
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/git/page.tsx b/src/frontend/src/app/(dashboard)/git/page.tsx new file mode 100644 index 0000000..c3d748f --- /dev/null +++ b/src/frontend/src/app/(dashboard)/git/page.tsx @@ -0,0 +1,304 @@ +"use client"; + +import { useEffect, useState } from "react"; +import { + GitBranch, GitCommit, ArrowUp, ArrowDown, RefreshCw, + AlertCircle, CheckCircle, Terminal, X, Loader2, FolderGit2, +} from "lucide-react"; +import { format } from "date-fns"; + +interface CommitInfo { + hash: string; + message: string; + author: string; + date: string; +} + +interface RepoStatus { + name: string; + path: string; + branch: string; + ahead: number; + behind: number; + staged: string[]; + unstaged: string[]; + untracked: string[]; + lastCommit: CommitInfo | null; + remoteUrl: string; + isDirty: boolean; +} + +interface OutputModal { + title: string; + content: string; + loading: boolean; +} + +export default function GitPage() { + const [repos, setRepos] = useState([]); + const [loading, setLoading] = useState(true); + const [refreshing, setRefreshing] = useState(false); + const [outputModal, setOutputModal] = useState(null); + const [actionLoading, setActionLoading] = useState>({}); + + const loadRepos = async () => { + try { + const res = await fetch("/api/git"); + const data = await res.json(); + setRepos(data.repos || []); + } catch { + setRepos([]); + } finally { + setLoading(false); + setRefreshing(false); + } + }; + + useEffect(() => { + loadRepos(); + }, []); + + const handleRefresh = () => { + setRefreshing(true); + loadRepos(); + }; + + const runAction = async (repo: RepoStatus, action: "status" | "pull" | "log" | "diff") => { + const key = `${repo.name}-${action}`; + setActionLoading((prev) => ({ ...prev, [key]: true })); + setOutputModal({ title: `${repo.name}: git ${action}`, content: "", loading: true }); + + try { + const res = await fetch("/api/git", { + method: "POST", + headers: { "Content-Type": "application/json" }, + body: JSON.stringify({ repo: repo.path, action }), + }); + const data = await res.json(); + setOutputModal({ title: `${repo.name}: git ${action}`, content: data.output || data.error || "No output", loading: false }); + } catch { + setOutputModal({ title: `${repo.name}: git ${action}`, content: "Request failed", loading: false }); + } finally { + setActionLoading((prev) => ({ ...prev, [key]: false })); + } + }; + + const dirtyRepos = repos.filter((r) => r.isDirty); + const cleanRepos = repos.filter((r) => !r.isDirty); + + return ( +
+ {/* Header */} +
+
+

+ Git Dashboard +

+

+ {repos.length} repositories · {dirtyRepos.length} with changes +

+
+ +
+ + {loading ? ( +
+ +
+ ) : repos.length === 0 ? ( +
+ +

No git repos found in workspace

+
+ ) : ( +
+ {/* Repos with changes first */} + {[...dirtyRepos, ...cleanRepos].map((repo) => ( +
+ {/* Repo header */} +
+
+ +
+ +
+
+

+ {repo.name} +

+
+ + {repo.branch} +
+ {repo.ahead > 0 && ( + + {repo.ahead} ahead + + )} + {repo.behind > 0 && ( + + {repo.behind} behind + + )} + {!repo.isDirty && ( + + clean + + )} + {repo.isDirty && ( + + {repo.staged.length + repo.unstaged.length + repo.untracked.length} changes + + )} +
+ {repo.lastCommit && ( +
+ + {repo.lastCommit.hash} + {repo.lastCommit.message.slice(0, 60)}{repo.lastCommit.message.length > 60 ? "…" : ""} + · + {repo.lastCommit.date} +
+ )} +
+ + {/* Actions */} +
+ {[ + { action: "status" as const, label: "status" }, + { action: "log" as const, label: "log" }, + { action: "diff" as const, label: "diff" }, + { action: "pull" as const, label: "pull" }, + ].map(({ action, label }) => ( + + ))} +
+
+ + {/* Changes breakdown */} + {repo.isDirty && ( +
+ {repo.staged.length > 0 && ( +
+
+ Staged ({repo.staged.length}) +
+
+ {repo.staged.slice(0, 5).map((f) => ( +
{f}
+ ))} + {repo.staged.length > 5 &&
+{repo.staged.length - 5} more
} +
+
+ )} + {repo.unstaged.length > 0 && ( +
+
+ Modified ({repo.unstaged.length}) +
+
+ {repo.unstaged.slice(0, 5).map((f) => ( +
{f}
+ ))} + {repo.unstaged.length > 5 &&
+{repo.unstaged.length - 5} more
} +
+
+ )} + {repo.untracked.length > 0 && ( +
+
+ Untracked ({repo.untracked.length}) +
+
+ {repo.untracked.slice(0, 5).map((f) => ( +
{f}
+ ))} + {repo.untracked.length > 5 &&
+{repo.untracked.length - 5} more
} +
+
+ )} +
+ )} +
+ ))} +
+ )} + + {/* Output Modal */} + {outputModal && ( +
+
+
+ + + {outputModal.title} + + +
+
+ {outputModal.loading ? ( +
+ +
+ ) : ( +
+                  {outputModal.content}
+                
+ )} +
+
+
+ )} +
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/layout.tsx b/src/frontend/src/app/(dashboard)/layout.tsx new file mode 100644 index 0000000..87a4239 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/layout.tsx @@ -0,0 +1,30 @@ +"use client"; + +import { Dock, TopBar, StatusBar } from "@/components/TenacitOS"; + +export default function DashboardLayout({ + children, +}: { + children: React.ReactNode; +}) { + return ( +
+ + + +
+ {children} +
+ + +
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/logs/page.tsx b/src/frontend/src/app/(dashboard)/logs/page.tsx new file mode 100644 index 0000000..0396bf0 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/logs/page.tsx @@ -0,0 +1,292 @@ +"use client"; + +import { useState, useEffect, useRef } from "react"; +import { Terminal, Play, Square, Trash2, Download, Circle, Server } from "lucide-react"; + +interface LogLine { + line: string; + ts: string; + id: number; +} + +const SERVICES = [ + { name: "mission-control", backend: "systemd", label: "Mission Control" }, + { name: "classvault", backend: "pm2", label: "ClassVault" }, + { name: "content-vault", backend: "pm2", label: "Content Vault" }, + { name: "brain", backend: "pm2", label: "Brain" }, + { name: "postiz-simple", backend: "pm2", label: "Postiz" }, + { name: "openclaw-gateway", backend: "systemd", label: "Gateway" }, +]; + +function getLineColor(line: string): string { + const lower = line.toLowerCase(); + if (lower.includes("error") || lower.includes("err]") || lower.includes("exception")) return "#f87171"; + if (lower.includes("warn") || lower.includes("warning")) return "#fbbf24"; + if (lower.includes("info") || lower.includes("[info]")) return "#60a5fa"; + if (lower.includes("success") || lower.includes("✓") || lower.includes("ready")) return "#4ade80"; + if (lower.startsWith("[stream]")) return "#a78bfa"; + return "#c9d1d9"; +} + +export default function LogsPage() { + const [selectedService, setSelectedService] = useState(SERVICES[0]); + const [lines, setLines] = useState([]); + const [streaming, setStreaming] = useState(false); + const [autoScroll, setAutoScroll] = useState(true); + const [filter, setFilter] = useState(""); + const logRef = useRef(null); + const esRef = useRef(null); + const idRef = useRef(0); + + const startStream = () => { + if (esRef.current) { + esRef.current.close(); + } + + setLines([]); + setStreaming(true); + + const es = new EventSource( + `/api/logs/stream?service=${encodeURIComponent(selectedService.name)}&backend=${encodeURIComponent(selectedService.backend)}` + ); + + es.onmessage = (e) => { + try { + const data = JSON.parse(e.data); + setLines((prev) => { + const newLine = { line: data.line, ts: data.ts, id: ++idRef.current }; + const updated = [...prev, newLine]; + // Keep max 2000 lines + return updated.length > 2000 ? updated.slice(-2000) : updated; + }); + } catch {} + }; + + es.onerror = () => { + setStreaming(false); + es.close(); + }; + + esRef.current = es; + }; + + const stopStream = () => { + esRef.current?.close(); + esRef.current = null; + setStreaming(false); + }; + + // Auto-scroll + useEffect(() => { + if (autoScroll && logRef.current) { + logRef.current.scrollTop = logRef.current.scrollHeight; + } + }, [lines, autoScroll]); + + // Cleanup on unmount + useEffect(() => { + return () => { + esRef.current?.close(); + }; + }, []); + + const handleClear = () => setLines([]); + + const handleDownload = () => { + const text = lines.map((l) => `[${l.ts}] ${l.line}`).join("\n"); + const blob = new Blob([text], { type: "text/plain" }); + const url = URL.createObjectURL(blob); + const a = document.createElement("a"); + a.href = url; + a.download = `${selectedService.name}-logs.txt`; + a.click(); + URL.revokeObjectURL(url); + }; + + const filteredLines = filter + ? lines.filter((l) => l.line.toLowerCase().includes(filter.toLowerCase())) + : lines; + + return ( +
+ {/* Header */} +
+

+ Log Viewer +

+

+ Real-time log streaming from services +

+
+ + {/* Controls */} +
+ {/* Service selector */} +
+ {SERVICES.map((svc) => ( + + ))} +
+ +
+ {/* Filter */} + setFilter(e.target.value)} + style={{ + padding: "0.375rem 0.75rem", + backgroundColor: "var(--card-elevated)", + border: "1px solid var(--border)", + borderRadius: "0.5rem", + color: "var(--text-primary)", + fontSize: "0.8rem", + outline: "none", + width: "12rem", + }} + /> + + {/* Auto-scroll toggle */} + + + {/* Clear */} + + + {/* Download */} + + + {/* Start/Stop stream */} + +
+
+ + {/* Status bar */} +
+
+ + + {streaming ? "LIVE" : "STOPPED"} + +
+ + {selectedService.label} · {selectedService.backend} + + + {filteredLines.length} lines{filter && ` (filtered from ${lines.length})`} + +
+ + {/* Log output */} +
{ + if (logRef.current) { + const { scrollTop, scrollHeight, clientHeight } = logRef.current; + setAutoScroll(scrollHeight - scrollTop - clientHeight < 50); + } + }} + style={{ + flex: 1, + overflow: "auto", + backgroundColor: "#0d1117", + padding: "1rem 1.5rem", + fontFamily: "monospace", + fontSize: "0.8rem", + lineHeight: 1.6, + }} + > + {filteredLines.length === 0 ? ( +
+ +

{streaming ? "Waiting for logs..." : "Click 'Stream' to start live log viewer"}

+
+ ) : ( + filteredLines.map((l) => ( +
+ + {new Date(l.ts).toLocaleTimeString()} + + + {l.line} + +
+ )) + )} +
+
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/memory/page.tsx b/src/frontend/src/app/(dashboard)/memory/page.tsx new file mode 100644 index 0000000..5d8de69 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/memory/page.tsx @@ -0,0 +1,448 @@ +"use client"; + +import { useState, useEffect, useCallback } from "react"; +import { Eye, Edit3, RefreshCw, Brain } from "lucide-react"; +import { FileTree, FileNode } from "@/components/FileTree"; +import { MarkdownEditor } from "@/components/MarkdownEditor"; +import { MarkdownPreview } from "@/components/MarkdownPreview"; + +type ViewMode = "edit" | "preview"; + +interface Workspace { + id: string; + name: string; + emoji: string; + path: string; + agentName?: string; +} + +export default function MemoryPage() { + const [workspaces, setWorkspaces] = useState([]); + const [selectedWorkspace, setSelectedWorkspace] = useState(null); + const [files, setFiles] = useState([]); + const [selectedPath, setSelectedPath] = useState(null); + const [content, setContent] = useState(""); + const [originalContent, setOriginalContent] = useState(""); + const [viewMode, setViewMode] = useState("preview"); + const [isLoading, setIsLoading] = useState(true); + const [error, setError] = useState(null); + + const hasUnsavedChanges = content !== originalContent; + + // Load workspaces + useEffect(() => { + fetch("/api/files/workspaces") + .then((res) => res.json()) + .then((data) => { + setWorkspaces(data.workspaces || []); + if (data.workspaces.length > 0) { + setSelectedWorkspace(data.workspaces[0].id); + } + }) + .catch(() => setWorkspaces([])); + }, []); + + const loadFileTree = useCallback(async (workspace: string) => { + try { + setIsLoading(true); + const res = await fetch(`/api/files?workspace=${encodeURIComponent(workspace)}`); + if (!res.ok) throw new Error("Failed to load files"); + const data = await res.json(); + setFiles(data); + } catch (err) { + setError("Failed to load file tree"); + console.error(err); + } finally { + setIsLoading(false); + } + }, []); + + const loadFile = useCallback(async (workspace: string, path: string) => { + try { + setError(null); + const res = await fetch( + `/api/files?workspace=${encodeURIComponent(workspace)}&path=${encodeURIComponent(path)}` + ); + if (!res.ok) throw new Error("Failed to load file"); + const data = await res.json(); + setContent(data.content); + setOriginalContent(data.content); + } catch (err) { + setError("Failed to load file"); + console.error(err); + } + }, []); + + const saveFile = useCallback(async () => { + if (!selectedWorkspace || !selectedPath) return; + const res = await fetch("/api/files", { + method: "PUT", + headers: { "Content-Type": "application/json" }, + body: JSON.stringify({ workspace: selectedWorkspace, path: selectedPath, content }), + }); + if (!res.ok) throw new Error("Failed to save file"); + setOriginalContent(content); + }, [selectedWorkspace, selectedPath, content]); + + const handleSelectFile = useCallback( + async (path: string) => { + if (hasUnsavedChanges) { + const confirmed = window.confirm("You have unsaved changes. Discard them?"); + if (!confirmed) return; + } + setSelectedPath(path); + if (selectedWorkspace) await loadFile(selectedWorkspace, path); + }, + [hasUnsavedChanges, selectedWorkspace, loadFile] + ); + + const handleWorkspaceSelect = (workspaceId: string) => { + if (hasUnsavedChanges) { + const confirmed = window.confirm("You have unsaved changes. Discard them?"); + if (!confirmed) return; + } + setSelectedWorkspace(workspaceId); + setSelectedPath(null); + setContent(""); + setOriginalContent(""); + }; + + useEffect(() => { + if (selectedWorkspace) loadFileTree(selectedWorkspace); + }, [selectedWorkspace, loadFileTree]); + + useEffect(() => { + if (files.length > 0 && !selectedPath) { + const memoryMd = files.find((f) => f.name === "MEMORY.md" && f.type === "file"); + const firstFile = memoryMd || files.find((f) => f.type === "file"); + if (firstFile) handleSelectFile(firstFile.path); + } + }, [files, selectedPath, handleSelectFile]); + + const selectedWorkspaceData = workspaces.find((w) => w.id === selectedWorkspace); + + return ( +
+ {/* Page header */} +
+

+ Memory Browser +

+

+ Ver y editar archivos de memoria de los agentes +

+
+ + {/* Two-column layout */} +
+ {/* ── LEFT SIDEBAR: Workspace list ────────────────────────────────── */} + + + {/* ── RIGHT PANEL ──────────────────────────────────────────────────── */} +
+ {selectedWorkspace && selectedWorkspaceData ? ( + <> + {/* Toolbar bar */} +
+
+ + + {selectedWorkspaceData.name} + + {selectedPath && ( + <> + / + + {selectedPath} + + + )} +
+ +
+ {/* Refresh */} + + + {/* View toggle */} +
+ + +
+
+
+ + {/* File tree + editor */} +
+ {/* File tree */} +
+ {isLoading ? ( +
+ Loading... +
+ ) : error && files.length === 0 ? ( +
+ {error} +
+ ) : ( + + )} +
+ + {/* Editor / Preview */} +
+ {selectedPath ? ( +
+ {viewMode === "edit" ? ( + + ) : ( + + )} +
+ ) : ( +
+
+ +

Selecciona un archivo para ver o editar

+
+
+ )} +
+
+ + ) : ( +
+ Selecciona un workspace +
+ )} +
+
+
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/page.tsx b/src/frontend/src/app/(dashboard)/page.tsx new file mode 100644 index 0000000..127e44e --- /dev/null +++ b/src/frontend/src/app/(dashboard)/page.tsx @@ -0,0 +1,315 @@ +"use client"; + +import { useEffect, useState } from "react"; +import { StatsCard } from "@/components/StatsCard"; +import { ActivityFeed } from "@/components/ActivityFeed"; +import { WeatherWidget } from "@/components/WeatherWidget"; +import { Notepad } from "@/components/Notepad"; +import { + Activity, + CheckCircle, + XCircle, + Calendar, + Circle, + Bot, + MessageSquare, + Users, + Gamepad2, + Brain, + Puzzle, + Zap, + Server, + Terminal, +} from "lucide-react"; +import Link from "next/link"; + +interface Stats { + total: number; + today: number; + success: number; + error: number; + byType: Record; +} + +interface Agent { + id: string; + name: string; + emoji: string; + color: string; + model: string; + status: "online" | "offline"; + lastActivity?: string; + botToken?: string; +} + +export default function DashboardPage() { + const [stats, setStats] = useState({ total: 0, today: 0, success: 0, error: 0, byType: {} }); + const [agents, setAgents] = useState([]); + + useEffect(() => { + Promise.all([ + fetch("/api/activities/stats").then(r => r.json()), + fetch("/api/agents").then(r => r.json()), + ]).then(([actStats, agentsData]) => { + setStats({ + total: actStats.total || 0, + today: actStats.today || 0, + success: actStats.byStatus?.success || 0, + error: actStats.byStatus?.error || 0, + byType: actStats.byType || {}, + }); + setAgents(agentsData.agents || []); + }).catch(console.error); + }, []); + + return ( +
+ {/* Header */} +
+

+ 💪 Mission Control +

+

+ Overview of Tenacitas agent activity +

+
+ + {/* Stats Grid + Weather */} +
+ {/* Stats */} +
+ } + iconColor="var(--info)" + /> + } + iconColor="var(--accent)" + /> + } + iconColor="var(--success)" + /> + } + iconColor="var(--error)" + /> +
+ + {/* Weather Widget */} +
+ +
+
+ + {/* Multi-Agent Status */} +
+
+
+
+

+ + Multi-Agent System +

+
+
+ + + Open Office + + + View all → + +
+
+
+
+ {agents.map((agent) => ( +
+
+
{agent.emoji}
+ +
+
+ {agent.name} +
+
+ + {agent.model.split('/').pop()} +
+ {agent.botToken && ( +
+ + Connected +
+ )} +
+ ))} +
+
+
+ + {/* Main Content Grid */} +
+ {/* Activity Feed */} +
+
+
+
+

+ Recent Activity +

+
+ + View all → + +
+
+ +
+
+ + {/* Quick Links */} +
+
+
+
+

+ Quick Links +

+
+
+
+ {[ + { href: "/cron", icon: Calendar, label: "Cron Jobs", color: "#a78bfa" }, + { href: "/actions", icon: Zap, label: "Quick Actions", color: "var(--accent)" }, + { href: "/system", icon: Server, label: "System", color: "var(--success)" }, + { href: "/logs", icon: Terminal, label: "Live Logs", color: "#60a5fa" }, + { href: "/memory", icon: Brain, label: "Memory", color: "#f59e0b" }, + { href: "/skills", icon: Puzzle, label: "Skills", color: "#4ade80" }, + ].map(({ href, icon: Icon, label, color }) => ( + +
+ + {label} +
+ + ))} +
+ + {/* Notepad */} +
+ +
+
+
+
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/reports/page.tsx b/src/frontend/src/app/(dashboard)/reports/page.tsx new file mode 100644 index 0000000..e8c2f2c --- /dev/null +++ b/src/frontend/src/app/(dashboard)/reports/page.tsx @@ -0,0 +1,281 @@ +"use client"; + +import { useState, useEffect, useCallback } from "react"; +import { FileBarChart, FileText, RefreshCw, Clock, HardDrive } from "lucide-react"; +import { MarkdownPreview } from "@/components/MarkdownPreview"; + +interface Report { + name: string; + path: string; + title: string; + type: string; + size: number; + modified: string; +} + +function formatSize(bytes: number): string { + if (bytes < 1024) return `${bytes} B`; + if (bytes < 1024 * 1024) return `${(bytes / 1024).toFixed(1)} KB`; + return `${(bytes / (1024 * 1024)).toFixed(1)} MB`; +} + +function formatDate(iso: string): string { + const d = new Date(iso); + return d.toLocaleDateString("es-ES", { + day: "numeric", + month: "short", + year: "numeric", + hour: "2-digit", + minute: "2-digit", + }); +} + +export default function ReportsPage() { + const [reports, setReports] = useState([]); + const [selectedPath, setSelectedPath] = useState(null); + const [content, setContent] = useState(""); + const [isLoading, setIsLoading] = useState(true); + const [isLoadingContent, setIsLoadingContent] = useState(false); + + const loadReports = useCallback(async () => { + try { + setIsLoading(true); + const res = await fetch("/api/reports"); + if (!res.ok) throw new Error("Failed to load reports"); + const data = await res.json(); + setReports(data); + } catch (err) { + console.error(err); + } finally { + setIsLoading(false); + } + }, []); + + const loadContent = useCallback(async (path: string) => { + try { + setIsLoadingContent(true); + const res = await fetch(`/api/reports?path=${encodeURIComponent(path)}`); + if (!res.ok) throw new Error("Failed to load report"); + const data = await res.json(); + setContent(data.content); + } catch (err) { + console.error(err); + setContent("# Error\n\nFailed to load report content."); + } finally { + setIsLoadingContent(false); + } + }, []); + + const handleSelect = useCallback( + (report: Report) => { + setSelectedPath(report.path); + loadContent(report.path); + }, + [loadContent] + ); + + useEffect(() => { + loadReports(); + }, [loadReports]); + + // Auto-select first report + useEffect(() => { + if (reports.length > 0 && !selectedPath) { + handleSelect(reports[0]); + } + }, [reports, selectedPath, handleSelect]); + + return ( +
+ {/* Header */} +
+
+ +
+

+ Reports +

+

+ Analysis reports and insights +

+
+
+ +
+ + {/* Main content - split layout */} +
+ {/* Report list */} +
+
+

+ {isLoading ? "Loading..." : `${reports.length} Reports`} +

+
+ + {!isLoading && reports.length === 0 && ( +
+ +

No reports found

+

+ Reports matching *-analysis-* or *-report-* patterns in memory/ will appear here +

+
+ )} + +
+ {reports.map((report) => ( + + ))} +
+
+ + {/* Preview panel */} +
+ {selectedPath ? ( + isLoadingContent ? ( +
+ Loading report... +
+ ) : ( + + ) + ) : ( +
+
+ +

Select a report to preview

+
+
+ )} +
+
+
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/search/page.tsx b/src/frontend/src/app/(dashboard)/search/page.tsx new file mode 100644 index 0000000..9883597 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/search/page.tsx @@ -0,0 +1,23 @@ +"use client"; + +import { GlobalSearch } from "@/components/GlobalSearch"; + +export default function SearchPage() { + return ( +
+
+

+ Global Search +

+

+ Search across activities, tasks, and indexed documents +

+
+ + +
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/sessions/page.tsx b/src/frontend/src/app/(dashboard)/sessions/page.tsx new file mode 100644 index 0000000..bda1d10 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/sessions/page.tsx @@ -0,0 +1,973 @@ +"use client"; + +import { useEffect, useState, useCallback } from "react"; +import { + MessageSquare, + Clock, + Bot, + RefreshCw, + X, + ChevronRight, + Wrench, + User, + AlertTriangle, + Search, + Cpu, + TrendingUp, + Hash, +} from "lucide-react"; +import { formatDistanceToNow } from "date-fns"; + +// ─── Types ──────────────────────────────────────────────────────────────────── + +interface Session { + id: string; + key: string; + type: "main" | "cron" | "subagent" | "direct" | "unknown"; + typeLabel: string; + typeEmoji: string; + sessionId: string | null; + cronJobId?: string; + subagentId?: string; + updatedAt: number; + ageMs: number; + model: string; + modelProvider: string; + inputTokens: number; + outputTokens: number; + totalTokens: number; + contextTokens: number; + contextUsedPercent: number | null; + aborted: boolean; +} + +interface Message { + id: string; + type: "user" | "assistant" | "tool_use" | "tool_result" | "model_change" | "system"; + role?: string; + content: string; + timestamp: string; + model?: string; + toolName?: string; +} + +// ─── Helpers ────────────────────────────────────────────────────────────────── + +function formatTokens(n: number): string { + if (n >= 1_000_000) return `${(n / 1_000_000).toFixed(1)}M`; + if (n >= 1_000) return `${(n / 1_000).toFixed(0)}k`; + return String(n); +} + +function shortModel(model: string): string { + // claude-sonnet-4-5 → Sonnet 4.5 + // claude-opus-4-6 → Opus 4.6 + // claude-haiku-3-5 → Haiku 3.5 + const m = model.replace("anthropic/", "").replace("claude-", ""); + const parts = m.split("-"); + if (parts.length >= 2) { + const name = parts[0].charAt(0).toUpperCase() + parts[0].slice(1); + const ver = parts.slice(1).join("."); + return `${name} ${ver}`; + } + return model; +} + +function typeColor(type: Session["type"]): string { + switch (type) { + case "main": return "var(--accent)"; + case "cron": return "#a78bfa"; + case "subagent": return "#60a5fa"; + case "direct": return "#4ade80"; + default: return "var(--text-muted)"; + } +} + +// ─── Message Bubble ────────────────────────────────────────────────────────── + +function MessageBubble({ msg }: { msg: Message }) { + const isUser = msg.type === "user"; + const isTool = msg.type === "tool_use"; + const isResult = msg.type === "tool_result"; + const isAssistant = msg.type === "assistant"; + + if (isTool) { + return ( +
+ + + {msg.toolName} + + + {msg.content.replace(`${msg.toolName}(`, "").replace(/\)$/, "").slice(0, 200)} + +
+ ); + } + + if (isResult) { + return ( +
+ ↳ {msg.content} +
+ ); + } + + return ( +
+ {/* Avatar */} +
+ {isUser ? ( + + ) : ( + + )} +
+ + {/* Bubble */} +
+ {msg.content.length > 800 + ? msg.content.slice(0, 800) + "\n…(truncated)" + : msg.content} +
+
+ ); +} + +// ─── Session Detail Panel ──────────────────────────────────────────────────── + +function SessionDetail({ + session, + onClose, +}: { + session: Session; + onClose: () => void; +}) { + const [messages, setMessages] = useState([]); + const [loading, setLoading] = useState(true); + const [error, setError] = useState(null); + + useEffect(() => { + if (!session.sessionId) { + setLoading(false); + setError("No session file available"); + return; + } + + setLoading(true); + setError(null); + fetch(`/api/sessions?id=${session.sessionId}`) + .then((r) => r.json()) + .then((data) => { + setMessages(data.messages || []); + if (data.error) setError(data.error); + }) + .catch(() => setError("Failed to load messages")) + .finally(() => setLoading(false)); + }, [session.sessionId]); + + const userCount = messages.filter((m) => m.type === "user").length; + const assistantCount = messages.filter((m) => m.type === "assistant").length; + const toolCount = messages.filter((m) => m.type === "tool_use").length; + + return ( +
+
e.stopPropagation()} + > + {/* Header */} +
+
+ {session.typeEmoji} +
+
+ + {session.typeLabel} + + {session.aborted && ( + + ⚠ Aborted + + )} +
+
+ {session.key} +
+
+ +
+ + {/* Stats row */} +
+ {[ + { icon: Cpu, label: shortModel(session.model), color: "#a78bfa" }, + { icon: Hash, label: `${formatTokens(session.totalTokens)} tokens`, color: "var(--accent)" }, + { + icon: TrendingUp, + label: session.contextUsedPercent !== null ? `${session.contextUsedPercent}% ctx` : "ctx n/a", + color: session.contextUsedPercent !== null && session.contextUsedPercent > 80 + ? "var(--error)" + : "var(--text-muted)", + }, + { + icon: Clock, + label: formatDistanceToNow(new Date(session.updatedAt), { addSuffix: true }), + color: "var(--text-muted)", + }, + ].map(({ icon: Icon, label, color }) => ( +
+ + {label} +
+ ))} +
+
+ + {/* Message stats strip */} + {messages.length > 0 && ( +
+ {[ + { label: `${userCount} user`, color: "var(--accent)" }, + { label: `${assistantCount} assistant`, color: "#60a5fa" }, + { label: `${toolCount} tool calls`, color: "#4ade80" }, + ].map(({ label, color }) => ( + + {label} + + ))} +
+ )} + + {/* Messages */} +
+ {loading && ( +
+
+ Loading transcript... +
+ )} + + {error && ( +
+ + {error} +
+ )} + + {!loading && !error && messages.length === 0 && ( +
+ +

No messages in this session

+
+ )} + + {!loading && + messages.map((msg) => )} +
+
+
+ ); +} + +// ─── Session Row ────────────────────────────────────────────────────────────── + +function SessionRow({ + session, + onClick, +}: { + session: Session; + onClick: () => void; +}) { + const color = typeColor(session.type); + const contextBar = + session.contextUsedPercent !== null ? Math.min(session.contextUsedPercent, 100) : null; + + return ( +
{ + e.currentTarget.style.backgroundColor = "var(--card-elevated)"; + }} + onMouseLeave={(e) => { + e.currentTarget.style.backgroundColor = "transparent"; + }} + > + {/* Type badge */} +
+ {session.typeEmoji} +
+ + {/* Main info */} +
+
+ + {session.typeLabel} + + {session.aborted && ( + ⚠ aborted + )} +
+
+ {session.key.replace("agent:main:", "")} +
+
+ + {/* Model */} +
+ + {shortModel(session.model)} + +
+ + {/* Tokens + ctx bar */} +
+ + {formatTokens(session.totalTokens)} + + {contextBar !== null && ( +
+
80 + ? "var(--error)" + : contextBar > 60 + ? "var(--warning)" + : "var(--success)", + }} + /> +
+ )} + + {contextBar !== null ? `${contextBar}% ctx` : ""} + +
+ + {/* Age */} +
+ + {formatDistanceToNow(new Date(session.updatedAt), { addSuffix: true })} + +
+ + +
+ ); +} + +// ─── Main Page ──────────────────────────────────────────────────────────────── + +type FilterType = "all" | "main" | "cron" | "subagent" | "direct"; + +const FILTER_TABS: Array<{ id: FilterType; label: string; emoji: string }> = [ + { id: "all", label: "All", emoji: "📋" }, + { id: "main", label: "Main", emoji: "🦞" }, + { id: "cron", label: "Cron", emoji: "🕐" }, + { id: "subagent", label: "Sub-agents", emoji: "🤖" }, + { id: "direct", label: "Chats", emoji: "💬" }, +]; + +export default function SessionsPage() { + const [sessions, setSessions] = useState([]); + const [loading, setLoading] = useState(true); + const [error, setError] = useState(null); + const [filter, setFilter] = useState("all"); + const [search, setSearch] = useState(""); + const [selectedSession, setSelectedSession] = useState(null); + + const loadSessions = useCallback(async () => { + try { + setError(null); + const res = await fetch("/api/sessions"); + const data = await res.json(); + setSessions(data.sessions || []); + } catch { + setError("Failed to load sessions"); + } finally { + setLoading(false); + } + }, []); + + useEffect(() => { + loadSessions(); + }, [loadSessions]); + + const filtered = sessions.filter((s) => { + if (filter !== "all" && s.type !== filter) return false; + if (search) { + const q = search.toLowerCase(); + if (!s.key.toLowerCase().includes(q) && !s.model.toLowerCase().includes(q)) return false; + } + return true; + }); + + // Counts per type + const counts = sessions.reduce>((acc, s) => { + acc[s.type] = (acc[s.type] || 0) + 1; + acc.all = (acc.all || 0) + 1; + return acc; + }, {}); + + // Stats + const totalTokens = sessions.reduce((sum, s) => sum + s.totalTokens, 0); + const uniqueModels = [...new Set(sessions.map((s) => s.model))]; + + return ( + <> +
+ {/* Header */} +
+

+ 💬 Session History +

+

+ All OpenClaw agent sessions — main, cron, sub-agents, and chats +

+
+ + {/* Summary cards */} +
+ {[ + { + label: "Total Sessions", + value: sessions.length, + icon: MessageSquare, + color: "var(--accent)", + }, + { + label: "Total Tokens", + value: formatTokens(totalTokens), + icon: Hash, + color: "#60a5fa", + }, + { + label: "Cron Runs", + value: counts.cron || 0, + icon: Clock, + color: "#a78bfa", + }, + { + label: "Models Used", + value: uniqueModels.length, + icon: Bot, + color: "#4ade80", + }, + ].map(({ label, value, icon: Icon, color }) => ( +
+
+ +
+
+
+ {value} +
+
{label}
+
+
+ ))} +
+ + {/* Filters + Search */} +
+ {/* Tab bar + search */} +
+ {/* Tabs */} +
+ {FILTER_TABS.map((tab) => { + const count = counts[tab.id] || 0; + const isActive = filter === tab.id; + return ( + + ); + })} +
+ + {/* Search + Refresh */} +
+
+ + setSearch(e.target.value)} + placeholder="Filter sessions..." + style={{ + background: "none", + border: "none", + outline: "none", + color: "var(--text-primary)", + fontSize: "0.8rem", + width: "160px", + }} + /> +
+ +
+
+ + {/* Column headers */} +
+
+
+ Session +
+
+ Tokens / ctx +
+
+ Updated +
+
+
+ + {/* Loading */} + {loading && ( +
+
+ Loading sessions... +
+ )} + + {/* Error */} + {!loading && error && ( +
+ + {error} +
+ )} + + {/* Empty */} + {!loading && !error && filtered.length === 0 && ( +
+ +

No sessions match your filter

+
+ )} + + {/* Session list */} + {!loading && + !error && + filtered.map((session) => ( + setSelectedSession(session)} + /> + ))} +
+
+ + {/* Detail panel */} + {selectedSession && ( + setSelectedSession(null)} + /> + )} + + + + ); +} diff --git a/src/frontend/src/app/(dashboard)/settings/page.tsx b/src/frontend/src/app/(dashboard)/settings/page.tsx new file mode 100644 index 0000000..432f4aa --- /dev/null +++ b/src/frontend/src/app/(dashboard)/settings/page.tsx @@ -0,0 +1,140 @@ +"use client"; + +import { useEffect, useState } from "react"; +import { Settings, RefreshCw } from "lucide-react"; +import { SystemInfo } from "@/components/SystemInfo"; +import { IntegrationStatus } from "@/components/IntegrationStatus"; +import { QuickActions } from "@/components/QuickActions"; + +interface SystemData { + agent: { + name: string; + creature: string; + emoji: string; + }; + system: { + uptime: number; + uptimeFormatted: string; + nodeVersion: string; + model: string; + workspacePath: string; + platform: string; + hostname: string; + memory: { + total: number; + free: number; + used: number; + }; + }; + integrations: Array<{ + id: string; + name: string; + status: "connected" | "disconnected" | "configured" | "not_configured"; + icon: string; + lastActivity: string | null; + }>; + timestamp: string; +} + +export default function SettingsPage() { + const [systemData, setSystemData] = useState(null); + const [loading, setLoading] = useState(true); + const [lastRefresh, setLastRefresh] = useState(null); + + const fetchSystemData = async () => { + try { + const res = await fetch("/api/system"); + const data = await res.json(); + setSystemData(data); + setLastRefresh(new Date()); + } catch (error) { + console.error("Failed to fetch system data:", error); + } finally { + setLoading(false); + } + }; + + useEffect(() => { + fetchSystemData(); + const interval = setInterval(fetchSystemData, 30000); + return () => clearInterval(interval); + }, []); + + const handleRefresh = () => { + setLoading(true); + fetchSystemData(); + }; + + return ( +
+ {/* Header */} +
+
+

+ + Settings +

+

+ System status, integrations, and configuration +

+
+ + +
+ + {/* Last Refresh Time */} + {lastRefresh && ( +
+ Last updated: {lastRefresh.toLocaleTimeString()} +
+ )} + + {/* Grid Layout */} +
+ {/* System Info - Full width on first row */} +
+ +
+ + {/* Integration Status */} +
+ +
+ + {/* Quick Actions */} +
+ +
+
+ + {/* Footer Info */} +
+
+ Mission Control v1.0.0 + OpenClaw Agent Dashboard +
+
+
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/skills/page.tsx b/src/frontend/src/app/(dashboard)/skills/page.tsx new file mode 100644 index 0000000..4e21708 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/skills/page.tsx @@ -0,0 +1,590 @@ +"use client"; + +import { useEffect, useState } from "react"; +import { + Search, + RefreshCw, + Puzzle, + Package, + FolderOpen, + ExternalLink, + FileText, + X, +} from "lucide-react"; +import { SectionHeader, MetricCard } from "@/components/TenacitOS"; + +interface Skill { + id: string; + name: string; + description: string; + location: string; + source: "workspace" | "system"; + homepage?: string; + emoji?: string; + fileCount: number; + fullContent: string; + files: string[]; + agents: string[]; +} + +interface SkillsData { + skills: Skill[]; +} + +export default function SkillsPage() { + const [data, setData] = useState(null); + const [searchQuery, setSearchQuery] = useState(""); + const [filterSource, setFilterSource] = useState<"all" | "workspace" | "system">("all"); + const [selectedSkill, setSelectedSkill] = useState(null); + + useEffect(() => { + fetch("/api/skills") + .then((res) => res.json()) + .then(setData) + .catch(() => setData({ skills: [] })); + }, []); + + if (!data) { + return ( +
+
+ +
+
+ ); + } + + const { skills } = data; + + // Filter skills + let filteredSkills = skills; + + if (filterSource !== "all") { + filteredSkills = filteredSkills.filter((s) => s.source === filterSource); + } + + if (searchQuery) { + const query = searchQuery.toLowerCase(); + filteredSkills = filteredSkills.filter( + (skill) => + skill.name.toLowerCase().includes(query) || + skill.description.toLowerCase().includes(query) || + skill.id.toLowerCase().includes(query) + ); + } + + // Group by source + const workspaceSkills = filteredSkills.filter((s) => s.source === "workspace"); + const systemSkills = filteredSkills.filter((s) => s.source === "system"); + + const workspaceCount = skills.filter((s) => s.source === "workspace").length; + const systemCount = skills.filter((s) => s.source === "system").length; + + return ( +
+ {/* Header */} +
+

+ Skills Manager +

+

+ Skills disponibles en el sistema OpenClaw +

+
+ + {/* Stats */} +
+ + + +
+ + {/* Filters */} +
+ {/* Search */} +
+ + setSearchQuery(e.target.value)} + style={{ + width: "100%", + paddingLeft: "40px", + paddingRight: "16px", + paddingTop: "12px", + paddingBottom: "12px", + borderRadius: "6px", + backgroundColor: "var(--surface-elevated)", + border: "1px solid var(--border)", + color: "var(--text-primary)", + fontFamily: "var(--font-body)", + fontSize: "12px", + }} + /> +
+ + {/* Source Filter */} +
+ + + +
+
+ + {/* Skills List */} + {filteredSkills.length === 0 ? ( +
+ +

No se encontraron skills

+
+ ) : ( +
+ {/* Workspace Skills */} + {workspaceSkills.length > 0 && (filterSource === "all" || filterSource === "workspace") && ( +
+ +
+ {workspaceSkills.map((skill) => ( + setSelectedSkill(skill)} /> + ))} +
+
+ )} + + {/* System Skills */} + {systemSkills.length > 0 && (filterSource === "all" || filterSource === "system") && ( +
+ +
+ {systemSkills.map((skill) => ( + setSelectedSkill(skill)} /> + ))} +
+
+ )} +
+ )} + + {/* Detail Modal */} + {selectedSkill && setSelectedSkill(null)} />} +
+ ); +} + +// Skill Card Component +function SkillCard({ skill, onClick }: { skill: Skill; onClick: () => void }) { + return ( +
{ + e.currentTarget.style.backgroundColor = "var(--surface-hover)"; + e.currentTarget.style.borderColor = "var(--border-strong)"; + }} + onMouseLeave={(e) => { + e.currentTarget.style.backgroundColor = "var(--surface)"; + e.currentTarget.style.borderColor = "var(--border)"; + }} + onClick={onClick} + > + {/* Skill Header */} +
+ {skill.emoji && ( + {skill.emoji} + )} +
+

+ {skill.name} +

+

+ {skill.description} +

+
+
+ + {/* Skill Footer */} +
+
+
+ {skill.source} +
+ {skill.agents && skill.agents.length > 0 && skill.agents.map((agent) => ( +
+ {agent} +
+ ))} + + {skill.fileCount} files + +
+ {skill.homepage && ( + + )} +
+
+ ); +} + +// Skill Detail Modal Component +function SkillDetailModal({ skill, onClose }: { skill: Skill; onClose: () => void }) { + return ( +
+
e.stopPropagation()} + > + {/* Modal Header */} +
+ + +
+ {skill.emoji && {skill.emoji}} +
+

+ {skill.name} +

+

+ {skill.description} +

+
+
{skill.source}
+
{skill.fileCount} archivos
+ {skill.agents && skill.agents.length > 0 && skill.agents.map((agent) => ( +
+ @{agent} +
+ ))} + {skill.homepage && ( + + Homepage + + )} +
+
+
+
+ + {/* Modal Body */} +
+

+ Archivos ({skill.files.length}) +

+
+ {skill.files.map((file) => ( +
+ + {file} +
+ ))} +
+
+
+
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/system/page.tsx b/src/frontend/src/app/(dashboard)/system/page.tsx new file mode 100644 index 0000000..2a46002 --- /dev/null +++ b/src/frontend/src/app/(dashboard)/system/page.tsx @@ -0,0 +1,613 @@ +"use client"; + +import { useEffect, useState } from "react"; +import { Cpu, HardDrive, MemoryStick, Activity, Network, Server, ShieldCheck, RotateCw, Wifi, Monitor, Play, Square, X, Loader2, Terminal, ArrowDown, ArrowUp } from "lucide-react"; + +interface SystemdService { + name: string; + status: string; + description: string; + backend?: string; + uptime?: number | null; + restarts?: number; + pid?: number | null; + mem?: number | null; + cpu?: number | null; +} + +interface TailscaleDevice { + ip: string; + hostname: string; + os: string; + online: boolean; +} + +interface FirewallRule { + port: string; + action: string; + from: string; + comment: string; +} + +interface SystemData { + cpu: { usage: number; cores: number[]; loadAvg: number[] }; + ram: { total: number; used: number; free: number; cached: number }; + disk: { total: number; used: number; free: number; percent: number }; + network: { rx: number; tx: number }; + systemd: SystemdService[]; + tailscale: { active: boolean; ip: string; devices: TailscaleDevice[] }; + firewall: { active: boolean; rules: FirewallRule[]; ruleCount: number }; +} + +interface LogsModal { + name: string; + backend: string; + content: string; + loading: boolean; +} + +function formatUptime(ms: number): string { + const totalSeconds = Math.floor(ms / 1000); + const days = Math.floor(totalSeconds / 86400); + const hours = Math.floor((totalSeconds % 86400) / 3600); + const minutes = Math.floor((totalSeconds % 3600) / 60); + if (days > 0) return `${days}d ${hours}h`; + if (hours > 0) return `${hours}h ${minutes}m`; + return `${minutes}m`; +} + +function formatBytes(bytes: number): string { + if (bytes < 1024) return `${bytes} B`; + if (bytes < 1024 * 1024) return `${(bytes / 1024).toFixed(1)} KB`; + return `${(bytes / 1024 / 1024).toFixed(1)} MB`; +} + +export default function SystemMonitorPage() { + const [systemData, setSystemData] = useState(null); + const [loading, setLoading] = useState(true); + const [lastUpdated, setLastUpdated] = useState(null); + const [selectedTab, setSelectedTab] = useState<"hardware" | "services">("hardware"); + const [actionLoading, setActionLoading] = useState>({}); + const [logsModal, setLogsModal] = useState(null); + const [toast, setToast] = useState<{ msg: string; type: "success" | "error" } | null>(null); + + useEffect(() => { + const fetchSystemData = async () => { + try { + const res = await fetch("/api/system/monitor"); + if (res.ok) { + const data = await res.json(); + setSystemData(data); + setLastUpdated(new Date()); + } + } catch (error) { + console.error("Failed to fetch system data:", error); + } finally { + setLoading(false); + } + }; + + fetchSystemData(); + const interval = setInterval(fetchSystemData, 5000); + return () => clearInterval(interval); + }, []); + + const showToast = (msg: string, type: "success" | "error" = "success") => { + setToast({ msg, type }); + setTimeout(() => setToast(null), 3000); + }; + + const handleServiceAction = async (svc: SystemdService, action: "restart" | "stop" | "start" | "logs") => { + const key = `${svc.name}-${action}`; + setActionLoading((prev) => ({ ...prev, [key]: true })); + + try { + if (action === "logs") { + setLogsModal({ name: svc.name, backend: svc.backend || "pm2", content: "", loading: true }); + } + + const res = await fetch("/api/system/services", { + method: "POST", + headers: { "Content-Type": "application/json" }, + body: JSON.stringify({ name: svc.name, backend: svc.backend || "pm2", action }), + }); + + const data = await res.json(); + + if (!res.ok) throw new Error(data.error || "Action failed"); + + if (action === "logs") { + setLogsModal({ name: svc.name, backend: svc.backend || "pm2", content: data.output, loading: false }); + } else { + showToast(`✅ ${svc.name}: ${action} successful`); + // Refresh data after action + setTimeout(async () => { + const r = await fetch("/api/system/monitor"); + if (r.ok) setSystemData(await r.json()); + }, 2000); + } + } catch (err) { + const msg = err instanceof Error ? err.message : "Action failed"; + if (action === "logs") { + setLogsModal({ name: svc.name, backend: svc.backend || "pm2", content: `Error: ${msg}`, loading: false }); + } else { + showToast(`❌ ${svc.name}: ${msg}`, "error"); + } + } finally { + setActionLoading((prev) => ({ ...prev, [key]: false })); + } + }; + + if (loading) { + return ( +
+
+
+

Loading system data...

+
+
+ ); + } + + if (!systemData) { + return ( +
+
+ +

Failed to load system data

+
+
+ ); + } + + const cpuColor = systemData.cpu.usage < 60 ? "var(--success)" : systemData.cpu.usage < 85 ? "var(--warning)" : "var(--error)"; + const ramPercent = (systemData.ram.used / systemData.ram.total) * 100; + const ramColor = ramPercent < 60 ? "var(--success)" : ramPercent < 85 ? "var(--warning)" : "var(--error)"; + const diskColor = systemData.disk.percent < 60 ? "var(--success)" : systemData.disk.percent < 85 ? "var(--warning)" : "var(--error)"; + + const activeServices = systemData.systemd.filter((s) => s.status === "active").length; + + return ( +
+ {/* Toast */} + {toast && ( +
+ {toast.msg} +
+ )} + + {/* Header */} +
+
+

+ System Monitor +

+

Real-time monitoring of server resources and services

+
+
+ + + Live + + {lastUpdated && ( + {lastUpdated.toLocaleTimeString()} + )} +
+
+ + {/* Tabs */} +
+ {[{ id: "hardware", label: "Hardware", icon: Cpu }, { id: "services", label: "Services", icon: Server }].map((tab) => { + const Icon = tab.icon; + const isActive = selectedTab === tab.id; + return ( + + ); + })} +
+ + {/* Hardware Tab */} + {selectedTab === "hardware" && ( +
+ {/* CPU */} +
+
+
+
+ +
+
+

CPU

+

{systemData.cpu.cores.length} cores

+
+
+ {systemData.cpu.usage}% +
+
+
+
+
+ Load Average + {systemData.cpu.loadAvg[0].toFixed(2)} / {systemData.cpu.loadAvg[1].toFixed(2)} / {systemData.cpu.loadAvg[2].toFixed(2)} +
+
+ + {/* RAM */} +
+
+
+
+ +
+
+

RAM

+

{systemData.ram.used.toFixed(1)}GB / {systemData.ram.total.toFixed(1)}GB

+
+
+ {ramPercent.toFixed(0)}% +
+
+
+
+
+ + {/* Disk */} +
+
+
+
+ +
+
+

Disk

+

{systemData.disk.used.toFixed(1)}GB / {systemData.disk.total.toFixed(1)}GB

+
+
+ {systemData.disk.percent.toFixed(0)}% +
+
+
+
+
+ + {/* Network */} +
+
+
+ +
+
+

Network

+

Live I/O

+
+
+
+
+
+ + RX (in) +
+ {systemData.network.rx.toFixed(2)} MB/s +
+
+
+ + TX (out) +
+ {systemData.network.tx.toFixed(2)} MB/s +
+ {/* Mini bar viz */} +
+
+
RX
+
+
+
+
+
+
TX
+
+
+
+
+
+
+
+
+ )} + + {/* Services Tab */} + {selectedTab === "services" && ( +
+ {/* Systemd + PM2 Services */} +
+

+ + Services ({activeServices}/{systemData.systemd.length} active) +

+
+ + + + + + + + + + + {systemData.systemd.map((svc) => { + const isActionable = svc.backend === "pm2" || svc.backend === "systemd"; + const restartKey = `${svc.name}-restart`; + const stopKey = `${svc.name}-stop`; + const logsKey = `${svc.name}-logs`; + + return ( + + + + + + + ); + })} + +
ServiceDescriptionStatusActions
+ {svc.name} + +
+ {svc.description || "—"} + {svc.uptime != null && svc.status === "active" && ( + + up {formatUptime(svc.uptime)} + {svc.restarts != null && svc.restarts > 0 && ` · ${svc.restarts} restarts`} + {svc.mem != null && ` · ${formatBytes(svc.mem)}`} + {svc.cpu != null && ` · ${svc.cpu.toFixed(1)}% CPU`} + + )} +
+
+
+
+ + {svc.status === "not_deployed" ? "not deployed" : svc.status} + + {svc.backend && svc.backend !== "none" && ( + + {svc.backend} + + )} +
+
+
+ {isActionable && ( + <> + {/* Restart */} + + + {/* Stop/Start */} + + + {/* Logs */} + + + )} +
+
+
+
+ + {/* VPN & Firewall */} +
+ {/* Tailscale VPN */} +
+
+
+ +
+
+

Tailscale VPN

+

+ {systemData.tailscale.active ? "Active" : "Inactive"} +

+
+
+
+
+ This server + {systemData.tailscale.ip} +
+
+ Devices connected + {systemData.tailscale.devices.length} +
+
+ {systemData.tailscale.devices.length > 0 && ( +
+ {systemData.tailscale.devices.map((dev, i) => ( +
+
+ + {dev.hostname} + ({dev.os}) +
+
+ {dev.ip} +
+
+
+ ))} +
+ )} +
+ + {/* Firewall */} +
+
+
+ +
+
+

Firewall (UFW)

+

+ {systemData.firewall.active ? "Active" : "Inactive"} +

+
+
+
+ {systemData.firewall.rules.map((rule, i) => ( +
+
+
+ {rule.port} + + {rule.action} + +
+ {rule.comment && {rule.comment}} +
+ + {rule.from} + +
+ ))} +
+
+
+
+ )} + + {/* Logs Modal */} + {logsModal && ( +
+
+ {/* Log header */} +
+ + + {logsModal.name} logs + + + ({logsModal.backend}) + + +
+ + {/* Log content */} +
+ {logsModal.loading ? ( +
+ +
+ ) : ( +
+                  {logsModal.content || "No log output"}
+                
+ )} +
+
+
+ )} +
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/terminal/page.tsx b/src/frontend/src/app/(dashboard)/terminal/page.tsx new file mode 100644 index 0000000..29b877b --- /dev/null +++ b/src/frontend/src/app/(dashboard)/terminal/page.tsx @@ -0,0 +1,273 @@ +"use client"; + +import { useState, useRef, useEffect, useCallback } from "react"; +import { Terminal, Send, Trash2, Copy, ChevronRight } from "lucide-react"; + +interface HistoryEntry { + command: string; + output: string; + error?: string; + duration?: number; + ts: Date; +} + +const QUICK_COMMANDS = [ + "df -h /", + "free -h", + "uptime", + "ps aux | grep node", + "systemctl status mission-control", + "pm2 list", + "ls /root/.openclaw/workspace", + "git -C /root/.openclaw/workspace/mission-control status", + "journalctl -u mission-control -n 20 --no-pager", + "docker ps", + "netstat -tlnp", + "cat /proc/loadavg", +]; + +export default function TerminalPage() { + const [input, setInput] = useState(""); + const [history, setHistory] = useState([]); + const [loading, setLoading] = useState(false); + const [cmdHistory, setCmdHistory] = useState([]); + const [cmdHistoryIdx, setCmdHistoryIdx] = useState(-1); + const inputRef = useRef(null); + const outputRef = useRef(null); + + // Focus input on mount + useEffect(() => { + inputRef.current?.focus(); + }, []); + + // Auto-scroll to bottom + useEffect(() => { + if (outputRef.current) { + outputRef.current.scrollTop = outputRef.current.scrollHeight; + } + }, [history]); + + const runCommand = useCallback(async (cmd: string) => { + const trimmed = cmd.trim(); + if (!trimmed) return; + + setLoading(true); + setCmdHistory((prev) => [trimmed, ...prev.slice(0, 99)]); + setCmdHistoryIdx(-1); + setInput(""); + + try { + const res = await fetch("/api/terminal", { + method: "POST", + headers: { "Content-Type": "application/json" }, + body: JSON.stringify({ command: trimmed }), + }); + const data = await res.json(); + + setHistory((prev) => [ + ...prev, + { + command: trimmed, + output: data.output || "", + error: !res.ok ? data.error : undefined, + duration: data.duration, + ts: new Date(), + }, + ]); + } catch (err) { + setHistory((prev) => [ + ...prev, + { + command: trimmed, + output: "", + error: String(err), + ts: new Date(), + }, + ]); + } finally { + setLoading(false); + inputRef.current?.focus(); + } + }, []); + + const handleKeyDown = (e: React.KeyboardEvent) => { + if (e.key === "Enter") { + runCommand(input); + } else if (e.key === "ArrowUp") { + e.preventDefault(); + const newIdx = Math.min(cmdHistoryIdx + 1, cmdHistory.length - 1); + setCmdHistoryIdx(newIdx); + if (cmdHistory[newIdx]) setInput(cmdHistory[newIdx]); + } else if (e.key === "ArrowDown") { + e.preventDefault(); + const newIdx = Math.max(cmdHistoryIdx - 1, -1); + setCmdHistoryIdx(newIdx); + setInput(newIdx === -1 ? "" : (cmdHistory[newIdx] || "")); + } + }; + + const clearHistory = () => setHistory([]); + + const copyAll = () => { + const text = history.map((h) => `$ ${h.command}\n${h.output}`).join("\n\n"); + navigator.clipboard.writeText(text); + }; + + return ( +
+ {/* Header */} +
+
+
+

+ Browser Terminal +

+

+ Read-only commands only (ls, cat, df, ps, git status, etc.) +

+
+
+ + +
+
+
+ + {/* Quick commands */} +
+
+ {QUICK_COMMANDS.map((cmd) => ( + + ))} +
+
+ + {/* Terminal output */} +
inputRef.current?.focus()} + > + {history.length === 0 ? ( +
+ +

Type a command or click a quick command above

+

+ Arrow Up/Down for command history +

+
+ ) : ( + history.map((entry, i) => ( +
+ {/* Command prompt */} +
+ tenacitas@srv + : + ~ + $ {entry.command} + {entry.duration != null && ( + ({entry.duration}ms) + )} +
+ + {/* Output */} + {entry.error && ( +
+                  {entry.error}
+                
+ )} + {entry.output && ( +
+                  {entry.output}
+                
+ )} +
+ )) + )} + + {/* Loading indicator */} + {loading && ( +
+
+ Running... +
+ )} +
+ + {/* Input */} +
+ $ + setInput(e.target.value)} + onKeyDown={handleKeyDown} + disabled={loading} + placeholder="Enter command..." + autoComplete="off" + spellCheck={false} + style={{ + flex: 1, + background: "transparent", + border: "none", + outline: "none", + color: "#c9d1d9", + fontFamily: "monospace", + fontSize: "0.875rem", + }} + /> + +
+
+ ); +} diff --git a/src/frontend/src/app/(dashboard)/workflows/page.tsx b/src/frontend/src/app/(dashboard)/workflows/page.tsx new file mode 100644 index 0000000..370a12b --- /dev/null +++ b/src/frontend/src/app/(dashboard)/workflows/page.tsx @@ -0,0 +1,386 @@ +"use client"; + +import { BRANDING } from "@/config/branding"; + +interface Workflow { + id: string; + emoji: string; + name: string; + description: string; + schedule: string; + steps: string[]; + status: "active" | "inactive"; + trigger: "cron" | "demand"; +} + +const WORKFLOWS: Workflow[] = [ + { + id: "social-radar", + emoji: "🔭", + name: "Social Radar", + description: "Monitoriza menciones, oportunidades de colaboración y conversaciones relevantes en redes sociales y foros.", + schedule: "9:30h y 17:30h (cada día)", + trigger: "cron", + status: "active", + steps: [ + `Busca menciones de ${BRANDING.twitterHandle} en Twitter/X, LinkedIn e Instagram`, + "Revisa hilos de Reddit en r/webdev, r/javascript, r/learnprogramming", + `Detecta oportunidades de colaboración y collabs entrantes (${BRANDING.ownerCollabEmail})`, + "Monitoriza aprendiendo.dev en conversaciones y menciones", + "Envía resumen por Telegram si hay algo relevante", + ], + }, + { + id: "noticias-ia", + emoji: "📰", + name: "Noticias IA y Web", + description: "Resume las noticias más relevantes de IA y desarrollo web del timeline de Twitter para arrancar el día informado.", + schedule: "7:45h (cada día)", + trigger: "cron", + status: "active", + steps: [ + "Lee el timeline de Twitter/X via bird CLI", + "Filtra noticias de IA, web dev, arquitectura y herramientas dev", + "Selecciona 5-7 noticias más relevantes para el nicho de Carlos", + "Genera resumen estructurado con enlace y contexto", + "Envía digest por Telegram", + ], + }, + { + id: "trend-monitor", + emoji: "🔥", + name: "Trend Monitor", + description: "Radar de tendencias urgentes en el nicho tech. Detecta temas virales antes de que exploten para aprovechar la ola de contenido.", + schedule: "7h, 10h, 15h y 20h (cada día)", + trigger: "cron", + status: "active", + steps: [ + "Monitoriza trending topics en Twitter/X relacionados con tech y programación", + "Busca en Hacker News, dev.to y GitHub Trending", + "Evalúa si el trend es relevante para el canal de Carlos", + "Si detecta algo urgente, notifica inmediatamente con contexto", + "Sugiere ángulo de contenido si el trend tiene potencial", + ], + }, + { + id: "daily-linkedin", + emoji: "📊", + name: "Daily LinkedIn Brief", + description: "Genera el post de LinkedIn del día basado en las noticias más relevantes de Hacker News, dev.to y la web tech.", + schedule: "9h (cada día)", + trigger: "cron", + status: "active", + steps: [ + "Recopila top posts de Hacker News (front page tech/dev)", + "Revisa trending en dev.to y artículos destacados", + "Selecciona tema con mayor potencial de engagement para la audiencia de Carlos", + "Redacta post de LinkedIn en la voz de Carlos (profesional-cercano, sin emojis ni hashtags)", + "Envía borrador por Telegram para revisión y publicación", + ], + }, + { + id: "newsletter-digest", + emoji: "📬", + name: "Newsletter Digest", + description: "Digest curado de las newsletters del día. Consolida lo mejor de las suscripciones de Carlos en un resumen accionable.", + schedule: "20h (cada día)", + trigger: "cron", + status: "active", + steps: [ + "Accede a Gmail y busca newsletters recibidas en el día", + "Filtra por remitentes relevantes (tech, IA, productividad, inversiones)", + "Extrae los puntos clave de cada newsletter", + "Genera digest estructurado por categorías", + "Envía resumen por Telegram", + ], + }, + { + id: "email-categorization", + emoji: "📧", + name: "Email Categorization", + description: "Categoriza y resume los emails del día para que Carlos empiece la jornada sin inbox anxiety.", + schedule: "7:45h (cada día)", + trigger: "cron", + status: "active", + steps: [ + "Accede a Gmail y lee emails no leídos del día", + "Categoriza: urgente / colabs / facturas / universidad / newsletters / otros", + "Resumen de cada categoría con acción recomendada", + "Detecta emails de clientes con facturas pendientes (>90 días)", + "Envía resumen estructurado por Telegram", + ], + }, + { + id: "weekly-newsletter", + emoji: "📅", + name: "Weekly Newsletter", + description: "Recapitulación semanal automática de los tweets y posts de LinkedIn para usar como base de la newsletter.", + schedule: "Domingos 18h", + trigger: "cron", + status: "active", + steps: [ + `Recopila tweets de la semana (${BRANDING.twitterHandle} via bird CLI)`, + "Recopila posts publicados en LinkedIn", + "Organiza por temas y relevancia", + "Genera borrador de recapitulación semanal en tono newsletter", + "Envía por Telegram para revisión antes de publicar", + ], + }, + { + id: "advisory-board", + emoji: "🏛️", + name: "Advisory Board", + description: "7 asesores IA con personalidades y memorias propias. Consulta a cualquier advisor o convoca al board completo.", + schedule: "Bajo demanda", + trigger: "demand", + status: "active", + steps: [ + "Carlos envía /cfo, /cmo, /cto, /legal, /growth, /coach o /producto", + "Tenacitas carga el skill advisory-board/SKILL.md", + "Lee el archivo de memoria del advisor correspondiente (memory/advisors/)", + "Responde en la voz y personalidad del advisor con contexto de Carlos", + "Actualiza el archivo de memoria con lo aprendido en la consulta", + "/board convoca los 7 advisors en secuencia y compila un board meeting completo", + ], + }, + { + id: "git-backup", + emoji: "🔄", + name: "Git Backup", + description: "Auto-commit y push del workspace cada 4 horas para garantizar que nada se pierde.", + schedule: "Cada 4h", + trigger: "cron", + status: "active", + steps: [ + "Comprueba si hay cambios en el workspace de Tenacitas", + "Si hay cambios: git add -A", + "Genera mensaje de commit automático con timestamp y resumen de cambios", + "git push al repositorio remoto", + "Silencioso si no hay cambios — solo notifica si hay error", + ], + }, + { + id: "nightly-evolution", + emoji: "🌙", + name: "Nightly Evolution", + description: "Sesión autónoma nocturna que implementa mejoras en Mission Control según el ROADMAP o inventa features nuevas útiles.", + schedule: "3h (cada noche)", + trigger: "cron", + status: "active", + steps: [ + "Lee ROADMAP.md de Mission Control para seleccionar la siguiente feature", + "Si no hay features claras, analiza el estado actual e inventa algo útil", + "Implementa la feature completa (código, tests si aplica, UI)", + "Verifica que el build de Next.js no falla", + "Notifica a Carlos por Telegram con el resumen de lo implementado", + ], + }, +]; + +function StatusBadge({ status }: { status: "active" | "inactive" }) { + return ( +
+
+ + {status === "active" ? "Activo" : "Inactivo"} + +
+ ); +} + +function TriggerBadge({ trigger }: { trigger: "cron" | "demand" }) { + return ( +
+ {trigger === "cron" ? "⏱ Cron" : "⚡ Demanda"} +
+ ); +} + +export default function WorkflowsPage() { + return ( +
+ {/* Header */} +
+

+ Workflows +

+

+ {WORKFLOWS.filter(w => w.status === "active").length} flujos activos · {WORKFLOWS.filter(w => w.trigger === "cron").length} crons automáticos · {WORKFLOWS.filter(w => w.trigger === "demand").length} bajo demanda +

+
+ + {/* Stats row */} +
+ {[ + { label: "Total workflows", value: WORKFLOWS.length, color: "var(--text-primary)" }, + { label: "Crons activos", value: WORKFLOWS.filter(w => w.trigger === "cron" && w.status === "active").length, color: "#60a5fa" }, + { label: "Bajo demanda", value: WORKFLOWS.filter(w => w.trigger === "demand").length, color: "var(--accent)" }, + ].map((stat) => ( +
+
+ {stat.value} +
+
+ {stat.label} +
+
+ ))} +
+ + {/* Workflow cards */} +
+ {WORKFLOWS.map((workflow) => ( +
+ {/* Card header */} +
+
+
+ {workflow.emoji} +
+
+

+ {workflow.name} +

+
+ + +
+
+
+ {/* Schedule */} +
+ 🕐 {workflow.schedule} +
+
+ + {/* Description */} +

+ {workflow.description} +

+ + {/* Steps */} +
+
+ Pasos +
+
    + {workflow.steps.map((step, i) => ( +
  1. + {step} +
  2. + ))} +
+
+
+ ))} +
+
+ ); +} diff --git a/src/frontend/src/app/activity/page.test.tsx b/src/frontend/src/app/activity/page.test.tsx deleted file mode 100644 index cabeeb7..0000000 --- a/src/frontend/src/app/activity/page.test.tsx +++ /dev/null @@ -1,95 +0,0 @@ -import React from "react"; -import { describe, expect, it, vi } from "vitest"; -import { render, screen } from "@testing-library/react"; - -import ActivityPage from "./page"; -import { AuthProvider } from "@/components/providers/AuthProvider"; -import { QueryProvider } from "@/components/providers/QueryProvider"; - -vi.mock("next/navigation", () => ({ - usePathname: () => "/activity", - useRouter: () => ({ - push: vi.fn(), - replace: vi.fn(), - prefetch: vi.fn(), - back: vi.fn(), - forward: vi.fn(), - refresh: vi.fn(), - }), -})); - -vi.mock("next/link", () => { - type LinkProps = React.PropsWithChildren<{ - href: string | { pathname?: string }; - }> & - Omit, "href">; - - return { - default: ({ href, children, ...props }: LinkProps) => ( - - {children} - - ), - }; -}); - -// Make Clerk components explode if we ever try to render them without the provider. -// The regression we want to catch is: AuthProvider skips , but the -// wrappers still render from @clerk/nextjs (which crashes in real builds). -vi.mock("@clerk/nextjs", () => { - return { - ClerkProvider: ({ children }: { children: React.ReactNode }) => ( - <>{children} - ), - SignedIn: () => { - throw new Error( - "@clerk/nextjs SignedIn rendered (unexpected in secretless mode)", - ); - }, - SignedOut: () => { - throw new Error("@clerk/nextjs SignedOut rendered without ClerkProvider"); - }, - SignInButton: ({ children }: { children: React.ReactNode }) => ( - <>{children} - ), - SignOutButton: ({ children }: { children: React.ReactNode }) => ( - <>{children} - ), - useAuth: () => ({ isLoaded: true, isSignedIn: false }), - useUser: () => ({ isLoaded: true, isSignedIn: false, user: null }), - }; -}); - -describe("/activity auth boundary", () => { - it("renders without ClerkProvider runtime errors when publishable key is a placeholder", () => { - const previousAuthMode = process.env.NEXT_PUBLIC_AUTH_MODE; - const previousPublishableKey = - process.env.NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY; - - // Simulate CI/secretless env where an arbitrary placeholder value may be present. - // AuthProvider should treat this as disabled, and the auth wrappers must not render - // Clerk SignedOut/SignedIn components. - process.env.NEXT_PUBLIC_AUTH_MODE = "local"; - process.env.NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY = "placeholder"; - window.sessionStorage.clear(); - - try { - render( - - - - - , - ); - - expect( - screen.getByRole("heading", { name: /local authentication/i }), - ).toBeInTheDocument(); - expect(screen.getByLabelText(/access token/i)).toBeInTheDocument(); - } finally { - process.env.NEXT_PUBLIC_AUTH_MODE = previousAuthMode; - process.env.NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY = previousPublishableKey; - window.sessionStorage.clear(); - } - }); -}); diff --git a/src/frontend/src/app/activity/page.tsx b/src/frontend/src/app/activity/page.tsx deleted file mode 100644 index c83c2a5..0000000 --- a/src/frontend/src/app/activity/page.tsx +++ /dev/null @@ -1,1554 +0,0 @@ -"use client"; - -import { memo, useCallback, useEffect, useMemo, useRef, useState } from "react"; -import Link from "next/link"; -import { useSearchParams } from "next/navigation"; - -import { SignedIn, SignedOut, useAuth } from "@/auth/clerk"; -import { Activity as ActivityIcon } from "lucide-react"; - -import { ApiError } from "@/api/mutator"; -import { streamAgentsApiV1AgentsStreamGet } from "@/api/generated/agents/agents"; -import { listActivityApiV1ActivityGet } from "@/api/generated/activity/activity"; -import { - getBoardSnapshotApiV1BoardsBoardIdSnapshotGet, - listBoardsApiV1BoardsGet, -} from "@/api/generated/boards/boards"; -import { streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet } from "@/api/generated/board-memory/board-memory"; -import { streamApprovalsApiV1BoardsBoardIdApprovalsStreamGet } from "@/api/generated/approvals/approvals"; -import { streamTasksApiV1BoardsBoardIdTasksStreamGet } from "@/api/generated/tasks/tasks"; -import { - type getMyMembershipApiV1OrganizationsMeMemberGetResponse, - useGetMyMembershipApiV1OrganizationsMeMemberGet, -} from "@/api/generated/organizations/organizations"; -import type { - ActivityEventRead, - AgentRead, - ApprovalRead, - BoardMemoryRead, - BoardRead, - TaskCommentRead, - TaskRead, -} from "@/api/generated/model"; -import { Markdown } from "@/components/atoms/Markdown"; -import { ActivityFeed } from "@/components/activity/ActivityFeed"; -import { SignedOutPanel } from "@/components/auth/SignedOutPanel"; -import { DashboardSidebar } from "@/components/organisms/DashboardSidebar"; -import { DashboardShell } from "@/components/templates/DashboardShell"; -import { createExponentialBackoff } from "@/lib/backoff"; -import { - DEFAULT_HUMAN_LABEL, - resolveHumanActorName, - resolveMemberDisplayName, -} from "@/lib/display-name"; -import { apiDatetimeToMs, parseApiDatetime } from "@/lib/datetime"; -import { cn } from "@/lib/utils"; -import { usePageActive } from "@/hooks/usePageActive"; - -const SSE_RECONNECT_BACKOFF = { - baseMs: 1_000, - factor: 2, - jitter: 0.2, - maxMs: 5 * 60_000, -} as const; - -const STREAM_CONNECT_SPACING_MS = 120; -const MAX_FEED_ITEMS = 300; -const PAGED_LIMIT = 200; -const PAGED_MAX = 1000; - -type Agent = AgentRead & { status: string }; - -type TaskEventType = - | "task.comment" - | "task.created" - | "task.updated" - | "task.status_changed"; - -type FeedEventType = - | TaskEventType - | "board.chat" - | "board.command" - | "agent.created" - | "agent.online" - | "agent.offline" - | "agent.updated" - | "approval.created" - | "approval.updated" - | "approval.approved" - | "approval.rejected"; - -type FeedItem = { - id: string; - created_at: string; - event_type: FeedEventType; - message: string | null; - source_event_id: string | null; - agent_id: string | null; - actor_name: string; - actor_role: string | null; - board_id: string | null; - board_name: string | null; - board_href: string | null; - task_id: string | null; - task_title: string | null; - title: string; - context_href: string | null; -}; - -type TaskMeta = { - title: string; - boardId: string | null; -}; - -type ActivityRouteParams = Record; - -const ACTIVITY_FEED_PATH = "/activity"; - -const TASK_EVENT_TYPES = new Set([ - "task.comment", - "task.created", - "task.updated", - "task.status_changed", -]); - -const isTaskEventType = (value: string): value is TaskEventType => - TASK_EVENT_TYPES.has(value as TaskEventType); - -const formatShortTimestamp = (value: string) => { - const date = parseApiDatetime(value); - if (!date) return "—"; - return date.toLocaleString(undefined, { - month: "short", - day: "numeric", - hour: "2-digit", - minute: "2-digit", - }); -}; - -const normalizeRouteParams = ( - params: ActivityEventRead["route_params"] | ActivityRouteParams | null | undefined, -): ActivityRouteParams => { - if (!params || typeof params !== "object") return {}; - return Object.entries(params).reduce((acc, [key, value]) => { - if (typeof value === "string" && value.length > 0) { - acc[key] = value; - } - return acc; - }, {}); -}; - -const buildRouteHref = ( - routeName: string | null | undefined, - routeParams: ActivityRouteParams, - fallback: { - eventId: string; - eventType: string; - createdAt: string; - taskId: string | null; - }, -): string => { - if (routeName === "board.approvals") { - const boardId = routeParams.boardId; - if (boardId) { - return `/boards/${encodeURIComponent(boardId)}/approvals`; - } - } - - if (routeName === "board") { - const boardId = routeParams.boardId; - if (boardId) { - const params = new URLSearchParams(); - Object.entries(routeParams).forEach(([key, value]) => { - if (key !== "boardId") params.set(key, value); - }); - const query = params.toString(); - return query - ? `/boards/${encodeURIComponent(boardId)}?${query}` - : `/boards/${encodeURIComponent(boardId)}`; - } - } - - const params = new URLSearchParams( - Object.keys(routeParams).length > 0 - ? routeParams - : { - eventId: fallback.eventId, - eventType: fallback.eventType, - createdAt: fallback.createdAt, - }, - ); - if (fallback.taskId && !params.has("taskId")) { - params.set("taskId", fallback.taskId); - } - return `${ACTIVITY_FEED_PATH}?${params.toString()}`; -}; - -const buildBoardHref = ( - routeParams: ActivityRouteParams, - boardId: string | null, -): string | null => { - const resolved = routeParams.boardId ?? boardId; - if (!resolved) return null; - return `/boards/${encodeURIComponent(resolved)}`; -}; - -const feedItemElementId = (id: string): string => - `activity-item-${id.replace(/[^a-zA-Z0-9_-]/g, "-")}`; - -const normalizeAgent = (agent: AgentRead): Agent => ({ - ...agent, - status: (agent.status ?? "offline").trim() || "offline", -}); - -const normalizeStatus = (value?: string | null) => - (value ?? "").trim().toLowerCase() || "offline"; - -const humanizeApprovalAction = (value: string): string => { - const cleaned = value.replace(/[._-]+/g, " ").trim(); - if (!cleaned) return "Approval"; - return cleaned.charAt(0).toUpperCase() + cleaned.slice(1); -}; - -const humanizeStatus = (value: string): string => - value.replace(/_/g, " ").trim() || "offline"; - -const roleFromAgent = (agent?: Agent | null): string | null => { - if (!agent) return null; - const profile = agent.identity_profile; - if (!profile || typeof profile !== "object") return null; - const role = profile.role; - if (typeof role !== "string") return null; - const trimmed = role.trim(); - return trimmed || null; -}; - -const eventLabel = (eventType: FeedEventType): string => { - if (eventType === "task.comment") return "Comment"; - if (eventType === "task.created") return "Created"; - if (eventType === "task.status_changed") return "Status"; - if (eventType === "board.chat") return "Chat"; - if (eventType === "board.command") return "Command"; - if (eventType === "agent.created") return "Agent"; - if (eventType === "agent.online") return "Online"; - if (eventType === "agent.offline") return "Offline"; - if (eventType === "agent.updated") return "Agent update"; - if (eventType === "approval.created") return "Approval"; - if (eventType === "approval.updated") return "Approval update"; - if (eventType === "approval.approved") return "Approved"; - if (eventType === "approval.rejected") return "Rejected"; - return "Updated"; -}; - -const eventPillClass = (eventType: FeedEventType): string => { - if (eventType === "task.comment") { - return "border-blue-200 bg-blue-50 text-blue-700"; - } - if (eventType === "task.created") { - return "border-emerald-200 bg-emerald-50 text-emerald-700"; - } - if (eventType === "task.status_changed") { - return "border-amber-200 bg-amber-50 text-amber-700"; - } - if (eventType === "board.chat") { - return "border-teal-200 bg-teal-50 text-teal-700"; - } - if (eventType === "board.command") { - return "border-fuchsia-200 bg-fuchsia-50 text-fuchsia-700"; - } - if (eventType === "agent.created") { - return "border-violet-200 bg-violet-50 text-violet-700"; - } - if (eventType === "agent.online") { - return "border-lime-200 bg-lime-50 text-lime-700"; - } - if (eventType === "agent.offline") { - return "border-slate-300 bg-slate-100 text-slate-700"; - } - if (eventType === "agent.updated") { - return "border-indigo-200 bg-indigo-50 text-indigo-700"; - } - if (eventType === "approval.created") { - return "border-cyan-200 bg-cyan-50 text-cyan-700"; - } - if (eventType === "approval.updated") { - return "border-sky-200 bg-sky-50 text-sky-700"; - } - if (eventType === "approval.approved") { - return "border-emerald-200 bg-emerald-50 text-emerald-700"; - } - if (eventType === "approval.rejected") { - return "border-rose-200 bg-rose-50 text-rose-700"; - } - return "border-slate-200 bg-slate-100 text-slate-700"; -}; - -const FeedCard = memo(function FeedCard({ - item, - isHighlighted = false, -}: { - item: FeedItem; - isHighlighted?: boolean; -}) { - const message = (item.message ?? "").trim(); - const authorAvatar = (item.actor_name[0] ?? "A").toUpperCase(); - - return ( -
-
-
- {authorAvatar} -
-
-
- {item.context_href ? ( - - {item.title} - - ) : ( -

- {item.title} -

- )} -
- - {eventLabel(item.event_type)} - - {item.board_href && item.board_name ? ( - - {item.board_name} - - ) : item.board_name ? ( - - {item.board_name} - - ) : null} - {item.board_name ? ( - · - ) : null} - - {item.actor_name} - - {item.actor_role ? ( - <> - · - {item.actor_role} - - ) : null} - · - - {formatShortTimestamp(item.created_at)} - -
-
-
-
- {message ? ( -
- -
- ) : ( -

- )} -
- ); -}); - -FeedCard.displayName = "FeedCard"; - -export default function ActivityPage() { - const [isMounted, setIsMounted] = useState(false); - useEffect(() => { - setIsMounted(true); - }, []); - - const { isSignedIn } = useAuth(); - const searchParams = useSearchParams(); - const isPageActive = usePageActive(); - const selectedEventId = useMemo(() => { - const value = searchParams.get("eventId"); - if (!value) return null; - const trimmed = value.trim(); - return trimmed.length > 0 ? trimmed : null; - }, [searchParams]); - const [highlightedFeedItemId, setHighlightedFeedItemId] = useState(null); - - const membershipQuery = useGetMyMembershipApiV1OrganizationsMeMemberGet< - getMyMembershipApiV1OrganizationsMeMemberGetResponse, - ApiError - >({ - query: { - enabled: Boolean(isSignedIn), - refetchOnMount: "always", - refetchOnWindowFocus: false, - retry: false, - }, - }); - const isOrgAdmin = useMemo(() => { - const member = - membershipQuery.data?.status === 200 ? membershipQuery.data.data : null; - return member ? ["owner", "admin"].includes(member.role) : false; - }, [membershipQuery.data]); - const currentUserDisplayName = useMemo(() => { - const member = - membershipQuery.data?.status === 200 ? membershipQuery.data.data : null; - return resolveMemberDisplayName(member, DEFAULT_HUMAN_LABEL); - }, [membershipQuery.data]); - - const [isFeedLoading, setIsFeedLoading] = useState(false); - const [feedError, setFeedError] = useState(null); - const [feedItems, setFeedItems] = useState([]); - const [boards, setBoards] = useState([]); - - const feedItemsRef = useRef([]); - const seenIdsRef = useRef>(new Set()); - const boardsByIdRef = useRef>(new Map()); - const taskMetaByIdRef = useRef>(new Map()); - const agentsByIdRef = useRef>(new Map()); - const approvalsByIdRef = useRef>(new Map()); - - useEffect(() => { - feedItemsRef.current = feedItems; - }, [feedItems]); - - const boardIds = useMemo(() => boards.map((board) => board.id), [boards]); - - const pushFeedItem = useCallback((item: FeedItem) => { - setFeedItems((prev) => { - if (seenIdsRef.current.has(item.id)) return prev; - seenIdsRef.current.add(item.id); - const next = [item, ...prev]; - return next.slice(0, MAX_FEED_ITEMS); - }); - }, []); - - const resolveAuthor = useCallback( - ( - agentId: string | null | undefined, - fallbackName: string = currentUserDisplayName, - ) => { - if (agentId) { - const agent = agentsByIdRef.current.get(agentId); - if (agent) { - return { - id: agent.id, - name: agent.name, - role: roleFromAgent(agent), - }; - } - } - return { - id: agentId ?? null, - name: fallbackName, - role: null, - }; - }, - [currentUserDisplayName], - ); - - const boardNameForId = useCallback((boardId: string | null | undefined) => { - if (!boardId) return null; - return boardsByIdRef.current.get(boardId)?.name ?? null; - }, []); - - const updateTaskMeta = useCallback( - ( - task: { id: string; title: string; board_id?: string | null }, - fallbackBoardId: string, - ) => { - const boardId = task.board_id ?? fallbackBoardId; - taskMetaByIdRef.current.set(task.id, { - title: task.title, - boardId, - }); - }, - [], - ); - - const mapTaskActivity = useCallback( - ( - event: ActivityEventRead, - fallbackBoardId: string | null = null, - ): FeedItem | null => { - if (!isTaskEventType(event.event_type)) return null; - const meta = event.task_id - ? taskMetaByIdRef.current.get(event.task_id) - : null; - const routeName = event.route_name ?? null; - const routeParams = normalizeRouteParams(event.route_params); - const taskId = event.task_id ?? routeParams.taskId ?? null; - const boardId = - meta?.boardId ?? - event.board_id ?? - routeParams.boardId ?? - fallbackBoardId ?? - null; - const fallbackRouteParams: ActivityRouteParams = {}; - if (boardId) fallbackRouteParams.boardId = boardId; - if (taskId) fallbackRouteParams.taskId = taskId; - const effectiveRouteParams = - Object.keys(routeParams).length > 0 ? routeParams : fallbackRouteParams; - const effectiveRouteName = - routeName ?? (boardId ? "board" : "activity"); - const author = resolveAuthor(event.agent_id, currentUserDisplayName); - return { - id: `activity:${event.id}`, - created_at: event.created_at, - event_type: event.event_type, - message: event.message ?? null, - source_event_id: event.id, - agent_id: author.id, - actor_name: author.name, - actor_role: author.role, - board_id: boardId, - board_name: boardNameForId(boardId), - board_href: buildBoardHref(effectiveRouteParams, boardId), - task_id: taskId, - task_title: meta?.title ?? null, - title: - meta?.title ?? (taskId ? "Unknown task" : "Task activity"), - context_href: buildRouteHref(effectiveRouteName, effectiveRouteParams, { - eventId: event.id, - eventType: event.event_type, - createdAt: event.created_at, - taskId, - }), - }; - }, - [boardNameForId, currentUserDisplayName, resolveAuthor], - ); - - const mapTaskComment = useCallback( - (comment: TaskCommentRead, fallbackBoardId: string): FeedItem => { - const meta = comment.task_id - ? taskMetaByIdRef.current.get(comment.task_id) - : null; - const boardId = meta?.boardId ?? fallbackBoardId; - const taskId = comment.task_id ?? null; - const routeParams: ActivityRouteParams = {}; - if (boardId) routeParams.boardId = boardId; - if (taskId) routeParams.taskId = taskId; - routeParams.commentId = comment.id; - const author = resolveAuthor(comment.agent_id, currentUserDisplayName); - return { - id: `comment:${comment.id}`, - created_at: comment.created_at, - event_type: "task.comment", - message: comment.message ?? null, - source_event_id: null, - agent_id: author.id, - actor_name: author.name, - actor_role: author.role, - board_id: boardId, - board_name: boardNameForId(boardId), - board_href: buildBoardHref(routeParams, boardId), - task_id: taskId, - task_title: meta?.title ?? null, - title: - meta?.title ?? (taskId ? "Unknown task" : "Task activity"), - context_href: buildRouteHref("board", routeParams, { - eventId: comment.id, - eventType: "task.comment", - createdAt: comment.created_at, - taskId, - }), - }; - }, - [boardNameForId, currentUserDisplayName, resolveAuthor], - ); - - const mapApprovalEvent = useCallback( - ( - approval: ApprovalRead, - boardId: string, - previous: ApprovalRead | null = null, - ): FeedItem => { - const nextStatus = approval.status ?? "pending"; - const previousStatus = previous?.status ?? null; - const kind: FeedEventType = - previousStatus === null - ? nextStatus === "approved" - ? "approval.approved" - : nextStatus === "rejected" - ? "approval.rejected" - : "approval.created" - : nextStatus !== previousStatus - ? nextStatus === "approved" - ? "approval.approved" - : nextStatus === "rejected" - ? "approval.rejected" - : "approval.updated" - : "approval.updated"; - - const stamp = - kind === "approval.created" - ? approval.created_at - : (approval.resolved_at ?? approval.created_at); - const action = humanizeApprovalAction(approval.action_type); - const author = resolveAuthor(approval.agent_id, currentUserDisplayName); - const statusText = - nextStatus === "approved" - ? "approved" - : nextStatus === "rejected" - ? "rejected" - : "pending"; - const message = - kind === "approval.created" - ? `${action} requested (${approval.confidence}% confidence).` - : kind === "approval.approved" - ? `${action} approved (${approval.confidence}% confidence).` - : kind === "approval.rejected" - ? `${action} rejected (${approval.confidence}% confidence).` - : `${action} updated (${statusText}, ${approval.confidence}% confidence).`; - - const taskMeta = approval.task_id - ? taskMetaByIdRef.current.get(approval.task_id) - : null; - const routeParams: ActivityRouteParams = { boardId }; - const taskId = approval.task_id ?? null; - - return { - id: `approval:${approval.id}:${kind}:${stamp}`, - created_at: stamp, - event_type: kind, - message, - source_event_id: null, - agent_id: author.id, - actor_name: author.name, - actor_role: author.role, - board_id: boardId, - board_name: boardNameForId(boardId), - board_href: buildBoardHref(routeParams, boardId), - task_id: taskId, - task_title: taskMeta?.title ?? null, - title: `Approval · ${action}`, - context_href: buildRouteHref("board.approvals", routeParams, { - eventId: approval.id, - eventType: kind, - createdAt: stamp, - taskId, - }), - }; - }, - [boardNameForId, currentUserDisplayName, resolveAuthor], - ); - - const mapBoardChat = useCallback( - (memory: BoardMemoryRead, boardId: string): FeedItem => { - const content = (memory.content ?? "").trim(); - const actorName = resolveHumanActorName( - memory.source, - currentUserDisplayName, - ); - const command = content.startsWith("/"); - const routeParams: ActivityRouteParams = { boardId, panel: "chat" }; - return { - id: `chat:${memory.id}`, - created_at: memory.created_at, - event_type: command ? "board.command" : "board.chat", - message: content || null, - source_event_id: null, - agent_id: null, - actor_name: actorName, - actor_role: null, - board_id: boardId, - board_name: boardNameForId(boardId), - board_href: buildBoardHref(routeParams, boardId), - task_id: null, - task_title: null, - title: command ? "Board command" : "Board chat", - context_href: buildRouteHref("board", routeParams, { - eventId: memory.id, - eventType: command ? "board.command" : "board.chat", - createdAt: memory.created_at, - taskId: null, - }), - }; - }, - [boardNameForId, currentUserDisplayName], - ); - - const mapAgentEvent = useCallback( - ( - agent: Agent, - previous: Agent | null, - isSnapshot = false, - ): FeedItem | null => { - const nextStatus = normalizeStatus(agent.status); - const previousStatus = previous ? normalizeStatus(previous.status) : null; - const statusChanged = - previousStatus !== null && nextStatus !== previousStatus; - const profileChanged = - Boolean(previous) && - (previous?.name !== agent.name || - previous?.is_board_lead !== agent.is_board_lead || - JSON.stringify(previous?.identity_profile ?? {}) !== - JSON.stringify(agent.identity_profile ?? {})); - - let kind: FeedEventType; - if (isSnapshot) { - kind = - nextStatus === "online" - ? "agent.online" - : nextStatus === "offline" - ? "agent.offline" - : "agent.updated"; - } else if (!previous) { - kind = "agent.created"; - } else if (statusChanged && nextStatus === "online") { - kind = "agent.online"; - } else if (statusChanged && nextStatus === "offline") { - kind = "agent.offline"; - } else if (statusChanged || profileChanged) { - kind = "agent.updated"; - } else { - return null; - } - - const stamp = agent.last_seen_at ?? agent.updated_at ?? agent.created_at; - const message = - kind === "agent.created" - ? `${agent.name} joined this board.` - : kind === "agent.online" - ? `${agent.name} is online.` - : kind === "agent.offline" - ? `${agent.name} is offline.` - : `${agent.name} updated (${humanizeStatus(nextStatus)}).`; - const boardId = agent.board_id ?? null; - const routeParams: ActivityRouteParams = boardId - ? { boardId } - : {}; - - return { - id: `agent:${agent.id}:${isSnapshot ? "snapshot" : kind}:${stamp}`, - created_at: stamp, - event_type: kind, - message, - source_event_id: null, - agent_id: agent.id, - actor_name: agent.name, - actor_role: roleFromAgent(agent), - board_id: boardId, - board_name: boardNameForId(boardId), - board_href: buildBoardHref(routeParams, boardId), - task_id: null, - task_title: null, - title: `Agent · ${agent.name}`, - context_href: - boardId === null - ? null - : buildRouteHref("board", routeParams, { - eventId: agent.id, - eventType: kind, - createdAt: stamp, - taskId: null, - }), - }; - }, - [boardNameForId], - ); - - const latestTimestamp = useCallback( - (predicate: (item: FeedItem) => boolean): string | null => { - let latest = 0; - for (const item of feedItemsRef.current) { - if (!predicate(item)) continue; - const time = apiDatetimeToMs(item.created_at) ?? 0; - if (time > latest) latest = time; - } - return latest ? new Date(latest).toISOString() : null; - }, - [], - ); - - useEffect(() => { - if (!isSignedIn) { - setBoards([]); - setFeedItems([]); - setFeedError(null); - setIsFeedLoading(false); - seenIdsRef.current = new Set(); - boardsByIdRef.current = new Map(); - taskMetaByIdRef.current = new Map(); - agentsByIdRef.current = new Map(); - approvalsByIdRef.current = new Map(); - return; - } - - let cancelled = false; - setIsFeedLoading(true); - setFeedError(null); - - const loadInitial = async () => { - try { - const nextBoards: BoardRead[] = []; - for (let offset = 0; offset < PAGED_MAX; offset += PAGED_LIMIT) { - const result = await listBoardsApiV1BoardsGet({ - limit: PAGED_LIMIT, - offset, - }); - if (cancelled) return; - if (result.status !== 200) { - throw new Error("Unable to load boards."); - } - const items = result.data.items ?? []; - nextBoards.push(...items); - if (items.length < PAGED_LIMIT) { - break; - } - } - - if (cancelled) return; - setBoards(nextBoards); - boardsByIdRef.current = new Map( - nextBoards.map((board) => [board.id, board]), - ); - - const seeded: FeedItem[] = []; - const seedSeen = new Set(); - - // Snapshot seeding gives org-level approvals/agents/chat and task metadata. - const snapshotResults = await Promise.allSettled( - nextBoards.map((board) => - getBoardSnapshotApiV1BoardsBoardIdSnapshotGet(board.id), - ), - ); - if (cancelled) return; - - snapshotResults.forEach((result, index) => { - if (result.status !== "fulfilled") return; - if (result.value.status !== 200) return; - const board = nextBoards[index]; - const snapshot = result.value.data; - - (snapshot.tasks ?? []).forEach((task) => { - taskMetaByIdRef.current.set(task.id, { - title: task.title, - boardId: board.id, - }); - }); - - (snapshot.agents ?? []).forEach((agent) => { - const normalized = normalizeAgent(agent); - agentsByIdRef.current.set(normalized.id, normalized); - const agentItem = mapAgentEvent(normalized, null, true); - if (!agentItem || seedSeen.has(agentItem.id)) return; - seedSeen.add(agentItem.id); - seeded.push(agentItem); - }); - - (snapshot.approvals ?? []).forEach((approval) => { - approvalsByIdRef.current.set(approval.id, approval); - const approvalItem = mapApprovalEvent(approval, board.id, null); - if (seedSeen.has(approvalItem.id)) return; - seedSeen.add(approvalItem.id); - seeded.push(approvalItem); - }); - - (snapshot.chat_messages ?? []).forEach((memory) => { - const chatItem = mapBoardChat(memory, board.id); - if (seedSeen.has(chatItem.id)) return; - seedSeen.add(chatItem.id); - seeded.push(chatItem); - }); - }); - - for (let offset = 0; offset < PAGED_MAX; offset += PAGED_LIMIT) { - const result = await listActivityApiV1ActivityGet({ - limit: PAGED_LIMIT, - offset, - }); - if (cancelled) return; - if (result.status !== 200) { - throw new Error("Unable to load activity feed."); - } - const items = result.data.items ?? []; - for (const event of items) { - const mapped = mapTaskActivity(event); - if (!mapped || seedSeen.has(mapped.id)) continue; - seedSeen.add(mapped.id); - seeded.push(mapped); - } - if (items.length < PAGED_LIMIT) { - break; - } - } - - seeded.sort((a, b) => { - const aTime = apiDatetimeToMs(a.created_at) ?? 0; - const bTime = apiDatetimeToMs(b.created_at) ?? 0; - return bTime - aTime; - }); - const next = seeded.slice(0, MAX_FEED_ITEMS); - if (cancelled) return; - setFeedItems(next); - seenIdsRef.current = new Set(next.map((item) => item.id)); - } catch (err) { - if (cancelled) return; - setFeedError( - err instanceof Error ? err.message : "Unable to load activity feed.", - ); - } finally { - if (cancelled) return; - setIsFeedLoading(false); - } - }; - - void loadInitial(); - return () => { - cancelled = true; - }; - }, [ - isSignedIn, - mapAgentEvent, - mapApprovalEvent, - mapBoardChat, - mapTaskActivity, - ]); - - useEffect(() => { - if (!isPageActive) return; - if (!isSignedIn) return; - if (boardIds.length === 0) return; - - let cancelled = false; - const cleanups: Array<() => void> = []; - - boardIds.forEach((boardId, index) => { - const boardDelay = index * STREAM_CONNECT_SPACING_MS; - const abortController = new AbortController(); - const backoff = createExponentialBackoff(SSE_RECONNECT_BACKOFF); - let reconnectTimeout: number | undefined; - let connectTimer: number | undefined; - - const connect = async () => { - try { - const since = latestTimestamp( - (item) => - item.board_id === boardId && isTaskEventType(item.event_type), - ); - const streamResult = - await streamTasksApiV1BoardsBoardIdTasksStreamGet( - boardId, - since ? { since } : undefined, - { - headers: { Accept: "text/event-stream" }, - signal: abortController.signal, - }, - ); - if (streamResult.status !== 200) { - throw new Error("Unable to connect task stream."); - } - const response = streamResult.data as Response; - if (!(response instanceof Response) || !response.body) { - throw new Error("Unable to connect task stream."); - } - const reader = response.body.getReader(); - const decoder = new TextDecoder(); - let buffer = ""; - - while (!cancelled) { - const { value, done } = await reader.read(); - if (done) break; - if (value && value.length) { - backoff.reset(); - } - buffer += decoder.decode(value, { stream: true }); - buffer = buffer.replace(/\r\n/g, "\n"); - let boundary = buffer.indexOf("\n\n"); - while (boundary !== -1) { - const raw = buffer.slice(0, boundary); - buffer = buffer.slice(boundary + 2); - const lines = raw.split("\n"); - let eventType = "message"; - let data = ""; - for (const line of lines) { - if (line.startsWith("event:")) { - eventType = line.slice(6).trim(); - } else if (line.startsWith("data:")) { - data += line.slice(5).trim(); - } - } - if (eventType === "task" && data) { - try { - const payload = JSON.parse(data) as { - type?: string; - activity?: ActivityEventRead; - task?: TaskRead; - comment?: TaskCommentRead; - }; - if (payload.task) { - updateTaskMeta(payload.task, boardId); - } - if (payload.activity) { - const mapped = mapTaskActivity(payload.activity, boardId); - if (mapped) { - if (!mapped.task_title && payload.task?.title) { - mapped.task_title = payload.task.title; - mapped.title = payload.task.title; - } - pushFeedItem(mapped); - } - } else if ( - payload.type === "task.comment" && - payload.comment - ) { - pushFeedItem(mapTaskComment(payload.comment, boardId)); - } - } catch { - // Ignore malformed payloads. - } - } - boundary = buffer.indexOf("\n\n"); - } - } - } catch { - // Reconnect handled below. - } - - if (!cancelled) { - if (reconnectTimeout !== undefined) { - window.clearTimeout(reconnectTimeout); - } - const delay = backoff.nextDelayMs(); - reconnectTimeout = window.setTimeout(() => { - reconnectTimeout = undefined; - void connect(); - }, delay); - } - }; - - connectTimer = window.setTimeout(() => { - connectTimer = undefined; - void connect(); - }, boardDelay); - - cleanups.push(() => { - abortController.abort(); - if (connectTimer !== undefined) { - window.clearTimeout(connectTimer); - } - if (reconnectTimeout !== undefined) { - window.clearTimeout(reconnectTimeout); - } - }); - }); - - return () => { - cancelled = true; - cleanups.forEach((fn) => fn()); - }; - }, [ - boardIds, - boardNameForId, - isPageActive, - isSignedIn, - latestTimestamp, - mapTaskActivity, - mapTaskComment, - pushFeedItem, - updateTaskMeta, - ]); - - useEffect(() => { - if (!isPageActive) return; - if (!isSignedIn) return; - if (boardIds.length === 0) return; - - let cancelled = false; - const cleanups: Array<() => void> = []; - - boardIds.forEach((boardId, index) => { - const boardDelay = index * STREAM_CONNECT_SPACING_MS; - const abortController = new AbortController(); - const backoff = createExponentialBackoff(SSE_RECONNECT_BACKOFF); - let reconnectTimeout: number | undefined; - let connectTimer: number | undefined; - - const connect = async () => { - try { - const since = latestTimestamp( - (item) => - item.board_id === boardId && - item.event_type.startsWith("approval."), - ); - const streamResult = - await streamApprovalsApiV1BoardsBoardIdApprovalsStreamGet( - boardId, - since ? { since } : undefined, - { - headers: { Accept: "text/event-stream" }, - signal: abortController.signal, - }, - ); - if (streamResult.status !== 200) { - throw new Error("Unable to connect approvals stream."); - } - const response = streamResult.data as Response; - if (!(response instanceof Response) || !response.body) { - throw new Error("Unable to connect approvals stream."); - } - const reader = response.body.getReader(); - const decoder = new TextDecoder(); - let buffer = ""; - - while (!cancelled) { - const { value, done } = await reader.read(); - if (done) break; - if (value && value.length) { - backoff.reset(); - } - buffer += decoder.decode(value, { stream: true }); - buffer = buffer.replace(/\r\n/g, "\n"); - let boundary = buffer.indexOf("\n\n"); - while (boundary !== -1) { - const raw = buffer.slice(0, boundary); - buffer = buffer.slice(boundary + 2); - const lines = raw.split("\n"); - let eventType = "message"; - let data = ""; - for (const line of lines) { - if (line.startsWith("event:")) { - eventType = line.slice(6).trim(); - } else if (line.startsWith("data:")) { - data += line.slice(5).trim(); - } - } - if (eventType === "approval" && data) { - try { - const payload = JSON.parse(data) as { - approval?: ApprovalRead; - }; - if (payload.approval) { - const previous = - approvalsByIdRef.current.get(payload.approval.id) ?? null; - approvalsByIdRef.current.set( - payload.approval.id, - payload.approval, - ); - pushFeedItem( - mapApprovalEvent(payload.approval, boardId, previous), - ); - } - } catch { - // Ignore malformed payloads. - } - } - boundary = buffer.indexOf("\n\n"); - } - } - } catch { - // Reconnect handled below. - } - - if (!cancelled) { - if (reconnectTimeout !== undefined) { - window.clearTimeout(reconnectTimeout); - } - const delay = backoff.nextDelayMs(); - reconnectTimeout = window.setTimeout(() => { - reconnectTimeout = undefined; - void connect(); - }, delay); - } - }; - - connectTimer = window.setTimeout(() => { - connectTimer = undefined; - void connect(); - }, boardDelay); - - cleanups.push(() => { - abortController.abort(); - if (connectTimer !== undefined) { - window.clearTimeout(connectTimer); - } - if (reconnectTimeout !== undefined) { - window.clearTimeout(reconnectTimeout); - } - }); - }); - - return () => { - cancelled = true; - cleanups.forEach((fn) => fn()); - }; - }, [ - boardIds, - isPageActive, - isSignedIn, - latestTimestamp, - mapApprovalEvent, - pushFeedItem, - ]); - - useEffect(() => { - if (!isPageActive) return; - if (!isSignedIn) return; - if (boardIds.length === 0) return; - - let cancelled = false; - const cleanups: Array<() => void> = []; - - boardIds.forEach((boardId, index) => { - const boardDelay = index * STREAM_CONNECT_SPACING_MS; - const abortController = new AbortController(); - const backoff = createExponentialBackoff(SSE_RECONNECT_BACKOFF); - let reconnectTimeout: number | undefined; - let connectTimer: number | undefined; - - const connect = async () => { - try { - const since = latestTimestamp( - (item) => - item.board_id === boardId && - (item.event_type === "board.chat" || - item.event_type === "board.command"), - ); - const params = { is_chat: true, ...(since ? { since } : {}) }; - const streamResult = - await streamBoardMemoryApiV1BoardsBoardIdMemoryStreamGet( - boardId, - params, - { - headers: { Accept: "text/event-stream" }, - signal: abortController.signal, - }, - ); - if (streamResult.status !== 200) { - throw new Error("Unable to connect board chat stream."); - } - const response = streamResult.data as Response; - if (!(response instanceof Response) || !response.body) { - throw new Error("Unable to connect board chat stream."); - } - const reader = response.body.getReader(); - const decoder = new TextDecoder(); - let buffer = ""; - - while (!cancelled) { - const { value, done } = await reader.read(); - if (done) break; - if (value && value.length) { - backoff.reset(); - } - buffer += decoder.decode(value, { stream: true }); - buffer = buffer.replace(/\r\n/g, "\n"); - let boundary = buffer.indexOf("\n\n"); - while (boundary !== -1) { - const raw = buffer.slice(0, boundary); - buffer = buffer.slice(boundary + 2); - const lines = raw.split("\n"); - let eventType = "message"; - let data = ""; - for (const line of lines) { - if (line.startsWith("event:")) { - eventType = line.slice(6).trim(); - } else if (line.startsWith("data:")) { - data += line.slice(5).trim(); - } - } - if (eventType === "memory" && data) { - try { - const payload = JSON.parse(data) as { - memory?: BoardMemoryRead; - }; - if (payload.memory?.tags?.includes("chat")) { - pushFeedItem(mapBoardChat(payload.memory, boardId)); - } - } catch { - // Ignore malformed payloads. - } - } - boundary = buffer.indexOf("\n\n"); - } - } - } catch { - // Reconnect handled below. - } - - if (!cancelled) { - if (reconnectTimeout !== undefined) { - window.clearTimeout(reconnectTimeout); - } - const delay = backoff.nextDelayMs(); - reconnectTimeout = window.setTimeout(() => { - reconnectTimeout = undefined; - void connect(); - }, delay); - } - }; - - connectTimer = window.setTimeout(() => { - connectTimer = undefined; - void connect(); - }, boardDelay); - - cleanups.push(() => { - abortController.abort(); - if (connectTimer !== undefined) { - window.clearTimeout(connectTimer); - } - if (reconnectTimeout !== undefined) { - window.clearTimeout(reconnectTimeout); - } - }); - }); - - return () => { - cancelled = true; - cleanups.forEach((fn) => fn()); - }; - }, [ - boardIds, - isPageActive, - isSignedIn, - latestTimestamp, - mapBoardChat, - pushFeedItem, - ]); - - useEffect(() => { - if (!isPageActive) return; - if (!isSignedIn || !isOrgAdmin) return; - - let cancelled = false; - const abortController = new AbortController(); - const backoff = createExponentialBackoff(SSE_RECONNECT_BACKOFF); - let reconnectTimeout: number | undefined; - - const connect = async () => { - try { - const since = latestTimestamp((item) => - item.event_type.startsWith("agent."), - ); - const streamResult = await streamAgentsApiV1AgentsStreamGet( - since ? { since } : undefined, - { - headers: { Accept: "text/event-stream" }, - signal: abortController.signal, - }, - ); - if (streamResult.status !== 200) { - throw new Error("Unable to connect agent stream."); - } - const response = streamResult.data as Response; - if (!(response instanceof Response) || !response.body) { - throw new Error("Unable to connect agent stream."); - } - const reader = response.body.getReader(); - const decoder = new TextDecoder(); - let buffer = ""; - - while (!cancelled) { - const { value, done } = await reader.read(); - if (done) break; - if (value && value.length) { - backoff.reset(); - } - buffer += decoder.decode(value, { stream: true }); - buffer = buffer.replace(/\r\n/g, "\n"); - let boundary = buffer.indexOf("\n\n"); - while (boundary !== -1) { - const raw = buffer.slice(0, boundary); - buffer = buffer.slice(boundary + 2); - const lines = raw.split("\n"); - let eventType = "message"; - let data = ""; - for (const line of lines) { - if (line.startsWith("event:")) { - eventType = line.slice(6).trim(); - } else if (line.startsWith("data:")) { - data += line.slice(5).trim(); - } - } - if (eventType === "agent" && data) { - try { - const payload = JSON.parse(data) as { agent?: AgentRead }; - if (payload.agent) { - const normalized = normalizeAgent(payload.agent); - const previous = - agentsByIdRef.current.get(normalized.id) ?? null; - agentsByIdRef.current.set(normalized.id, normalized); - const mapped = mapAgentEvent(normalized, previous, false); - if (mapped) { - pushFeedItem(mapped); - } - } - } catch { - // Ignore malformed payloads. - } - } - boundary = buffer.indexOf("\n\n"); - } - } - } catch { - // Reconnect handled below. - } - - if (!cancelled) { - if (reconnectTimeout !== undefined) { - window.clearTimeout(reconnectTimeout); - } - const delay = backoff.nextDelayMs(); - reconnectTimeout = window.setTimeout(() => { - reconnectTimeout = undefined; - void connect(); - }, delay); - } - }; - - void connect(); - return () => { - cancelled = true; - abortController.abort(); - if (reconnectTimeout !== undefined) { - window.clearTimeout(reconnectTimeout); - } - }; - }, [ - isOrgAdmin, - isPageActive, - isSignedIn, - latestTimestamp, - mapAgentEvent, - pushFeedItem, - ]); - - const orderedFeed = useMemo(() => { - return [...feedItems].sort((a, b) => { - const aTime = apiDatetimeToMs(a.created_at) ?? 0; - const bTime = apiDatetimeToMs(b.created_at) ?? 0; - return bTime - aTime; - }); - }, [feedItems]); - - const selectedFeedItemId = useMemo(() => { - if (!selectedEventId) return null; - const directMatch = orderedFeed.find( - (item) => item.source_event_id === selectedEventId, - ); - if (directMatch) return directMatch.id; - const fallbackMatch = orderedFeed.find( - (item) => - item.id === selectedEventId || item.id === `activity:${selectedEventId}`, - ); - return fallbackMatch?.id ?? null; - }, [orderedFeed, selectedEventId]); - - useEffect(() => { - if (!selectedFeedItemId) { - setHighlightedFeedItemId(null); - return; - } - - setHighlightedFeedItemId(selectedFeedItemId); - const scrollTimeout = window.setTimeout(() => { - const element = document.getElementById(feedItemElementId(selectedFeedItemId)); - if (!element) return; - element.scrollIntoView({ behavior: "smooth", block: "center" }); - }, 50); - - const clearHighlightTimeout = window.setTimeout(() => { - setHighlightedFeedItemId((current) => - current === selectedFeedItemId ? null : current, - ); - }, 4_000); - - return () => { - window.clearTimeout(scrollTimeout); - window.clearTimeout(clearHighlightTimeout); - }; - }, [selectedFeedItemId]); - - const hasUnresolvedDeepLink = Boolean( - selectedEventId && !selectedFeedItemId && !isFeedLoading && !feedError, - ); - - return ( - - {isMounted ? ( - <> - - - - - -
-
-
-
-
-
- -

- Live feed -

-
-

- Realtime task, approval, agent, and board-chat activity - across all boards. -

-
-
-
-
- -
- {hasUnresolvedDeepLink ? ( -
- Requested activity item is not in the current feed window yet. -
- ) : null} - ( - - )} - /> -
-
-
- - ) : null} -
- ); -} diff --git a/src/frontend/src/app/agents/[agentId]/edit/page.tsx b/src/frontend/src/app/agents/[agentId]/edit/page.tsx deleted file mode 100644 index 9fe11dd..0000000 --- a/src/frontend/src/app/agents/[agentId]/edit/page.tsx +++ /dev/null @@ -1,468 +0,0 @@ -"use client"; - -export const dynamic = "force-dynamic"; - -import { useMemo, useState } from "react"; -import { useParams, useRouter } from "next/navigation"; - -import { useAuth } from "@/auth/clerk"; - -import { ApiError } from "@/api/mutator"; -import { - type getAgentApiV1AgentsAgentIdGetResponse, - useGetAgentApiV1AgentsAgentIdGet, - useUpdateAgentApiV1AgentsAgentIdPatch, -} from "@/api/generated/agents/agents"; -import { - type listBoardsApiV1BoardsGetResponse, - useListBoardsApiV1BoardsGet, -} from "@/api/generated/boards/boards"; -import type { AgentRead, AgentUpdate, BoardRead } from "@/api/generated/model"; -import { DashboardPageLayout } from "@/components/templates/DashboardPageLayout"; -import { Button } from "@/components/ui/button"; -import { Input } from "@/components/ui/input"; -import SearchableSelect, { - type SearchableSelectOption, -} from "@/components/ui/searchable-select"; -import { - Select, - SelectContent, - SelectItem, - SelectTrigger, - SelectValue, -} from "@/components/ui/select"; -import { AGENT_EMOJI_OPTIONS } from "@/lib/agent-emoji"; -import { DEFAULT_IDENTITY_PROFILE } from "@/lib/agent-templates"; - -type IdentityProfile = { - role: string; - communication_style: string; - emoji: string; -}; - -const getBoardOptions = (boards: BoardRead[]): SearchableSelectOption[] => - boards.map((board) => ({ - value: board.id, - label: board.name, - })); - -const mergeIdentityProfile = ( - existing: unknown, - patch: IdentityProfile, -): Record | null => { - const resolved: Record = - existing && typeof existing === "object" - ? { ...(existing as Record) } - : {}; - const updates: Record = { - role: patch.role.trim(), - communication_style: patch.communication_style.trim(), - emoji: patch.emoji.trim(), - }; - for (const [key, value] of Object.entries(updates)) { - if (value) { - resolved[key] = value; - } else { - delete resolved[key]; - } - } - return Object.keys(resolved).length > 0 ? resolved : null; -}; - -const withIdentityDefaults = ( - profile: Partial | null | undefined, -): IdentityProfile => ({ - role: profile?.role ?? DEFAULT_IDENTITY_PROFILE.role, - communication_style: - profile?.communication_style ?? - DEFAULT_IDENTITY_PROFILE.communication_style, - emoji: profile?.emoji ?? DEFAULT_IDENTITY_PROFILE.emoji, -}); - -export default function EditAgentPage() { - const { isSignedIn } = useAuth(); - const router = useRouter(); - const params = useParams(); - const agentIdParam = params?.agentId; - const agentId = Array.isArray(agentIdParam) ? agentIdParam[0] : agentIdParam; - - const [name, setName] = useState(undefined); - const [boardId, setBoardId] = useState(undefined); - const [isGatewayMain, setIsGatewayMain] = useState( - undefined, - ); - const [heartbeatEvery, setHeartbeatEvery] = useState( - undefined, - ); - const [identityProfile, setIdentityProfile] = useState< - IdentityProfile | undefined - >(undefined); - const [error, setError] = useState(null); - - const boardsQuery = useListBoardsApiV1BoardsGet< - listBoardsApiV1BoardsGetResponse, - ApiError - >(undefined, { - query: { - enabled: Boolean(isSignedIn), - refetchOnMount: "always", - retry: false, - }, - }); - - const agentQuery = useGetAgentApiV1AgentsAgentIdGet< - getAgentApiV1AgentsAgentIdGetResponse, - ApiError - >(agentId ?? "", { - query: { - enabled: Boolean(isSignedIn && agentId), - refetchOnMount: "always", - retry: false, - }, - }); - - const updateMutation = useUpdateAgentApiV1AgentsAgentIdPatch({ - mutation: { - onSuccess: () => { - if (agentId) { - router.push(`/agents/${agentId}`); - } - }, - onError: (err) => { - setError(err.message || "Something went wrong."); - }, - }, - }); - - const boards = useMemo(() => { - if (boardsQuery.data?.status !== 200) return []; - return boardsQuery.data.data.items ?? []; - }, [boardsQuery.data]); - const loadedAgent: AgentRead | null = - agentQuery.data?.status === 200 ? agentQuery.data.data : null; - - const loadedHeartbeat = useMemo(() => { - const heartbeat = loadedAgent?.heartbeat_config; - if (heartbeat && typeof heartbeat === "object") { - const record = heartbeat as Record; - const every = record.every; - return { - every: typeof every === "string" && every.trim() ? every : "10m", - }; - } - return { every: "10m" }; - }, [loadedAgent?.heartbeat_config]); - - const loadedIdentityProfile = useMemo(() => { - const identity = loadedAgent?.identity_profile; - if (identity && typeof identity === "object") { - const record = identity as Record; - return withIdentityDefaults({ - role: typeof record.role === "string" ? record.role : undefined, - communication_style: - typeof record.communication_style === "string" - ? record.communication_style - : undefined, - emoji: typeof record.emoji === "string" ? record.emoji : undefined, - }); - } - return withIdentityDefaults(null); - }, [loadedAgent?.identity_profile]); - - const isLoading = - boardsQuery.isLoading || agentQuery.isLoading || updateMutation.isPending; - const errorMessage = - error ?? agentQuery.error?.message ?? boardsQuery.error?.message ?? null; - - const resolvedName = name ?? loadedAgent?.name ?? ""; - const resolvedIsGatewayMain = - isGatewayMain ?? Boolean(loadedAgent?.is_gateway_main); - const resolvedHeartbeatEvery = heartbeatEvery ?? loadedHeartbeat.every; - const resolvedIdentityProfile = identityProfile ?? loadedIdentityProfile; - - const resolvedBoardId = useMemo(() => { - if (resolvedIsGatewayMain) return boardId ?? ""; - return boardId ?? loadedAgent?.board_id ?? boards[0]?.id ?? ""; - }, [boardId, boards, loadedAgent?.board_id, resolvedIsGatewayMain]); - - const handleSubmit = (event: React.FormEvent) => { - event.preventDefault(); - if (!isSignedIn || !agentId || !loadedAgent) return; - const trimmed = resolvedName.trim(); - if (!trimmed) { - setError("Agent name is required."); - return; - } - if (!resolvedIsGatewayMain && !resolvedBoardId) { - setError("Select a board or mark this agent as the gateway main."); - return; - } - if ( - resolvedIsGatewayMain && - !resolvedBoardId && - !loadedAgent.is_gateway_main && - !loadedAgent.board_id - ) { - setError( - "Select a board once so we can resolve the gateway main session key.", - ); - return; - } - setError(null); - - const existingHeartbeat = - loadedAgent.heartbeat_config && - typeof loadedAgent.heartbeat_config === "object" - ? (loadedAgent.heartbeat_config as Record) - : {}; - - const payload: AgentUpdate = { - name: trimmed, - heartbeat_config: { - ...existingHeartbeat, - every: resolvedHeartbeatEvery.trim() || "10m", - target: "last", - includeReasoning: - typeof existingHeartbeat.includeReasoning === "boolean" - ? existingHeartbeat.includeReasoning - : false, - } as unknown as Record, - identity_profile: mergeIdentityProfile( - loadedAgent.identity_profile, - resolvedIdentityProfile, - ) as unknown as Record | null, - }; - if (!resolvedIsGatewayMain) { - payload.board_id = resolvedBoardId || null; - } else if (resolvedBoardId) { - payload.board_id = resolvedBoardId; - } - if (Boolean(loadedAgent.is_gateway_main) !== resolvedIsGatewayMain) { - payload.is_gateway_main = resolvedIsGatewayMain; - } - - updateMutation.mutate({ agentId, params: { force: true }, data: payload }); - }; - - return ( - -
-
-

- Basic configuration -

-
-
-
- - setName(event.target.value)} - placeholder="e.g. Deploy bot" - disabled={isLoading} - /> -
-
- - - setIdentityProfile({ - ...resolvedIdentityProfile, - role: event.target.value, - }) - } - placeholder="e.g. Founder, Social Media Manager" - disabled={isLoading} - /> -
-
-
-
-
- - {resolvedBoardId ? ( - - ) : null} -
- setBoardId(value)} - options={getBoardOptions(boards)} - placeholder={ - resolvedIsGatewayMain - ? "No board (main agent)" - : "Select board" - } - searchPlaceholder="Search boards..." - emptyMessage="No matching boards." - triggerClassName="w-full h-11 rounded-xl border border-slate-300 bg-white px-3 py-2 text-sm font-medium text-slate-900 shadow-sm focus:border-blue-500 focus:ring-2 focus:ring-blue-200" - contentClassName="rounded-xl border border-slate-200 shadow-lg" - itemClassName="px-4 py-3 text-sm text-slate-700 data-[selected=true]:bg-slate-50 data-[selected=true]:text-slate-900" - disabled={boards.length === 0} - /> - {resolvedIsGatewayMain ? ( -

- Main agents are not attached to a board. If a board is - selected, it is only used to resolve the gateway main - session key and will be cleared on save. -

- ) : boards.length === 0 ? ( -

- Create a board before assigning agents. -

- ) : null} -
-
- - -
-
-
-
- -
-
- -
-

- Personality & behavior -

-
-
- - - setIdentityProfile({ - ...resolvedIdentityProfile, - communication_style: event.target.value, - }) - } - disabled={isLoading} - /> -
-
-
- -
-

- Schedule & notifications -

-
-
- - setHeartbeatEvery(event.target.value)} - placeholder="e.g. 10m" - disabled={isLoading} - /> -

- Set how often this agent runs HEARTBEAT.md. -

-
-
-
- - {errorMessage ? ( -
- {errorMessage} -
- ) : null} - -
- - -
-
-
- ); -} diff --git a/src/frontend/src/app/agents/[agentId]/page.tsx b/src/frontend/src/app/agents/[agentId]/page.tsx deleted file mode 100644 index cf25d18..0000000 --- a/src/frontend/src/app/agents/[agentId]/page.tsx +++ /dev/null @@ -1,397 +0,0 @@ -"use client"; - -export const dynamic = "force-dynamic"; - -import { useMemo, useState } from "react"; -import Link from "next/link"; -import { useParams, useRouter } from "next/navigation"; - -import { SignInButton, SignedIn, SignedOut, useAuth } from "@/auth/clerk"; - -import { ApiError } from "@/api/mutator"; -import { - type getAgentApiV1AgentsAgentIdGetResponse, - useDeleteAgentApiV1AgentsAgentIdDelete, - useGetAgentApiV1AgentsAgentIdGet, -} from "@/api/generated/agents/agents"; -import { - type listActivityApiV1ActivityGetResponse, - useListActivityApiV1ActivityGet, -} from "@/api/generated/activity/activity"; -import { - type listBoardsApiV1BoardsGetResponse, - useListBoardsApiV1BoardsGet, -} from "@/api/generated/boards/boards"; -import { - formatRelativeTimestamp as formatRelative, - formatTimestamp, -} from "@/lib/formatters"; -import { useOrganizationMembership } from "@/lib/use-organization-membership"; -import type { - ActivityEventRead, - AgentRead, - BoardRead, -} from "@/api/generated/model"; -import { Markdown } from "@/components/atoms/Markdown"; -import { StatusPill } from "@/components/atoms/StatusPill"; -import { DashboardSidebar } from "@/components/organisms/DashboardSidebar"; -import { DashboardShell } from "@/components/templates/DashboardShell"; -import { Button } from "@/components/ui/button"; -import { - Dialog, - DialogContent, - DialogDescription, - DialogFooter, - DialogHeader, - DialogTitle, -} from "@/components/ui/dialog"; - -export default function AgentDetailPage() { - const { isSignedIn } = useAuth(); - const router = useRouter(); - const params = useParams(); - const agentIdParam = params?.agentId; - const agentId = Array.isArray(agentIdParam) ? agentIdParam[0] : agentIdParam; - - const { isAdmin } = useOrganizationMembership(isSignedIn); - - const [deleteOpen, setDeleteOpen] = useState(false); - const [deleteError, setDeleteError] = useState(null); - - const agentQuery = useGetAgentApiV1AgentsAgentIdGet< - getAgentApiV1AgentsAgentIdGetResponse, - ApiError - >(agentId ?? "", { - query: { - enabled: Boolean(isSignedIn && isAdmin && agentId), - refetchInterval: 30_000, - refetchOnMount: "always", - retry: false, - }, - }); - - const activityQuery = useListActivityApiV1ActivityGet< - listActivityApiV1ActivityGetResponse, - ApiError - >( - { limit: 200 }, - { - query: { - enabled: Boolean(isSignedIn && isAdmin), - refetchInterval: 30_000, - retry: false, - }, - }, - ); - - const boardsQuery = useListBoardsApiV1BoardsGet< - listBoardsApiV1BoardsGetResponse, - ApiError - >(undefined, { - query: { - enabled: Boolean(isSignedIn && isAdmin), - refetchInterval: 60_000, - refetchOnMount: "always", - retry: false, - }, - }); - - const agent: AgentRead | null = - agentQuery.data?.status === 200 ? agentQuery.data.data : null; - const events = useMemo(() => { - if (activityQuery.data?.status !== 200) return []; - return activityQuery.data.data.items ?? []; - }, [activityQuery.data]); - const boards = useMemo(() => { - if (boardsQuery.data?.status !== 200) return []; - return boardsQuery.data.data.items ?? []; - }, [boardsQuery.data]); - - const agentEvents = useMemo(() => { - if (!agent) return []; - return events.filter((event) => event.agent_id === agent.id); - }, [events, agent]); - const linkedBoard = - !agent?.board_id || agent?.is_gateway_main - ? null - : (boards.find((board) => board.id === agent.board_id) ?? null); - - const deleteMutation = useDeleteAgentApiV1AgentsAgentIdDelete({ - mutation: { - onSuccess: () => { - setDeleteOpen(false); - router.push("/agents"); - }, - onError: (err) => { - setDeleteError(err.message || "Something went wrong."); - }, - }, - }); - - const isLoading = - agentQuery.isLoading || activityQuery.isLoading || boardsQuery.isLoading; - const error = - agentQuery.error?.message ?? - activityQuery.error?.message ?? - boardsQuery.error?.message ?? - null; - - const isDeleting = deleteMutation.isPending; - const agentStatus = agent?.status ?? "unknown"; - - const handleDelete = () => { - if (!agentId || !isSignedIn) return; - setDeleteError(null); - deleteMutation.mutate({ agentId }); - }; - - return ( - - -
-

Sign in to view agents.

- - - -
-
- - - {!isAdmin ? ( -
-
- Only organization owners and admins can access agents. -
-
- ) : ( -
-
-
-

- Agents -

-

- {agent?.name ?? "Agent"} -

-

- Review agent health, session binding, and recent activity. -

-
-
- - {agent ? ( - - Edit - - ) : null} - {agent ? ( - - ) : null} -
-
- - {error ? ( -
- {error} -
- ) : null} - - {isLoading ? ( -
- Loading agent details… -
- ) : agent ? ( -
-
-
-
-
-

- Overview -

-

- {agent.name} -

-
- -
-
-
-

- Agent ID -

-

{agent.id}

-
-
-

- Session key -

-

- {agent.openclaw_session_id ?? "—"} -

-
-
-

- Board -

- {agent.is_gateway_main ? ( -

- Gateway main (no board) -

- ) : linkedBoard ? ( - - {linkedBoard.name} - - ) : ( -

- )} -
-
-

- Last seen -

-

- {formatRelative(agent.last_seen_at)} -

-

- {formatTimestamp(agent.last_seen_at)} -

-
-
-

- Updated -

-

- {formatTimestamp(agent.updated_at)} -

-
-
-

- Created -

-

- {formatTimestamp(agent.created_at)} -

-
-
-
- -
-
-

- Health -

- -
-
-
- Heartbeat window - {formatRelative(agent.last_seen_at)} -
-
- Session binding - - {agent.openclaw_session_id ? "Bound" : "Unbound"} - -
-
- Status - {agentStatus} -
-
-
-
- -
-
-

- Activity -

-

- {agentEvents.length} events -

-
-
- {agentEvents.length === 0 ? ( -
- No activity yet for this agent. -
- ) : ( - agentEvents.map((event) => ( -
- {event.message?.trim() ? ( -
- -
- ) : ( -

- {event.event_type} -

- )} -

- {formatTimestamp(event.created_at)} -

-
- )) - )} -
-
-
- ) : ( -
- Agent not found. -
- )} -
- )} -
- - - - - Delete agent - - This will remove {agent?.name}. This action cannot be undone. - - - {deleteError ? ( -
- {deleteError} -
- ) : null} - - - - -
-
-
- ); -} diff --git a/src/frontend/src/app/agents/new/page.tsx b/src/frontend/src/app/agents/new/page.tsx deleted file mode 100644 index bec1fd4..0000000 --- a/src/frontend/src/app/agents/new/page.tsx +++ /dev/null @@ -1,301 +0,0 @@ -"use client"; - -export const dynamic = "force-dynamic"; - -import { useState } from "react"; -import { useRouter } from "next/navigation"; - -import { useAuth } from "@/auth/clerk"; - -import { ApiError } from "@/api/mutator"; -import { - type listBoardsApiV1BoardsGetResponse, - useListBoardsApiV1BoardsGet, -} from "@/api/generated/boards/boards"; -import { useCreateAgentApiV1AgentsPost } from "@/api/generated/agents/agents"; -import { useOrganizationMembership } from "@/lib/use-organization-membership"; -import type { BoardRead } from "@/api/generated/model"; -import { DashboardPageLayout } from "@/components/templates/DashboardPageLayout"; -import { Button } from "@/components/ui/button"; -import { Input } from "@/components/ui/input"; -import SearchableSelect, { - type SearchableSelectOption, -} from "@/components/ui/searchable-select"; -import { - Select, - SelectContent, - SelectItem, - SelectTrigger, - SelectValue, -} from "@/components/ui/select"; -import { AGENT_EMOJI_OPTIONS } from "@/lib/agent-emoji"; -import { DEFAULT_IDENTITY_PROFILE } from "@/lib/agent-templates"; - -type IdentityProfile = { - role: string; - communication_style: string; - emoji: string; -}; - -const getBoardOptions = (boards: BoardRead[]): SearchableSelectOption[] => - boards.map((board) => ({ - value: board.id, - label: board.name, - })); - -const normalizeIdentityProfile = ( - profile: IdentityProfile, -): IdentityProfile | null => { - const normalized: IdentityProfile = { - role: profile.role.trim(), - communication_style: profile.communication_style.trim(), - emoji: profile.emoji.trim(), - }; - const hasValue = Object.values(normalized).some((value) => value.length > 0); - return hasValue ? normalized : null; -}; - -export default function NewAgentPage() { - const router = useRouter(); - const { isSignedIn } = useAuth(); - - const { isAdmin } = useOrganizationMembership(isSignedIn); - - const [name, setName] = useState(""); - const [boardId, setBoardId] = useState(""); - const [heartbeatEvery, setHeartbeatEvery] = useState("10m"); - const [identityProfile, setIdentityProfile] = useState({ - ...DEFAULT_IDENTITY_PROFILE, - }); - const [error, setError] = useState(null); - - const boardsQuery = useListBoardsApiV1BoardsGet< - listBoardsApiV1BoardsGetResponse, - ApiError - >(undefined, { - query: { - enabled: Boolean(isSignedIn && isAdmin), - refetchOnMount: "always", - }, - }); - - const createAgentMutation = useCreateAgentApiV1AgentsPost({ - mutation: { - onSuccess: (result) => { - if (result.status === 200) { - router.push(`/agents/${result.data.id}`); - } - }, - onError: (err) => { - setError(err.message || "Something went wrong."); - }, - }, - }); - - const boards = - boardsQuery.data?.status === 200 ? (boardsQuery.data.data.items ?? []) : []; - const displayBoardId = boardId || boards[0]?.id || ""; - const isLoading = boardsQuery.isLoading || createAgentMutation.isPending; - const errorMessage = error ?? boardsQuery.error?.message ?? null; - - const handleSubmit = (event: React.FormEvent) => { - event.preventDefault(); - if (!isSignedIn) return; - const trimmed = name.trim(); - if (!trimmed) { - setError("Agent name is required."); - return; - } - const resolvedBoardId = displayBoardId; - if (!resolvedBoardId) { - setError("Select a board before creating an agent."); - return; - } - setError(null); - createAgentMutation.mutate({ - data: { - name: trimmed, - board_id: resolvedBoardId, - heartbeat_config: { - every: heartbeatEvery.trim() || "10m", - target: "last", - includeReasoning: false, - }, - identity_profile: normalizeIdentityProfile( - identityProfile, - ) as unknown as Record | null, - }, - }); - }; - - return ( - -
-
-

- Basic configuration -

-
-
-
- - setName(event.target.value)} - placeholder="e.g. Deploy bot" - disabled={isLoading} - /> -
-
- - - setIdentityProfile((current) => ({ - ...current, - role: event.target.value, - })) - } - placeholder="e.g. Founder, Social Media Manager" - disabled={isLoading} - /> -
-
-
-
- - - {boards.length === 0 ? ( -

- Create a board before adding agents. -

- ) : null} -
-
- - -
-
-
-
- -
-

- Personality & behavior -

-
-
- - - setIdentityProfile((current) => ({ - ...current, - communication_style: event.target.value, - })) - } - disabled={isLoading} - /> -
-
-
- -
-

- Schedule & notifications -

-
-
- - setHeartbeatEvery(event.target.value)} - placeholder="e.g. 10m" - disabled={isLoading} - /> -

- How often this agent runs HEARTBEAT.md (10m, 30m, 2h). -

-
-
-
- - {errorMessage ? ( -
- {errorMessage} -
- ) : null} - -
- - -
-
-
- ); -} diff --git a/src/frontend/src/app/agents/page.tsx b/src/frontend/src/app/agents/page.tsx deleted file mode 100644 index fdffc91..0000000 --- a/src/frontend/src/app/agents/page.tsx +++ /dev/null @@ -1,192 +0,0 @@ -"use client"; - -export const dynamic = "force-dynamic"; - -import { useMemo, useState } from "react"; -import { useRouter } from "next/navigation"; - -import { useAuth } from "@/auth/clerk"; -import { useQueryClient } from "@tanstack/react-query"; - -import { AgentsTable } from "@/components/agents/AgentsTable"; -import { DashboardPageLayout } from "@/components/templates/DashboardPageLayout"; -import { Button } from "@/components/ui/button"; -import { ConfirmActionDialog } from "@/components/ui/confirm-action-dialog"; - -import { ApiError } from "@/api/mutator"; -import { - type listAgentsApiV1AgentsGetResponse, - getListAgentsApiV1AgentsGetQueryKey, - useDeleteAgentApiV1AgentsAgentIdDelete, - useListAgentsApiV1AgentsGet, -} from "@/api/generated/agents/agents"; -import { - type listBoardsApiV1BoardsGetResponse, - getListBoardsApiV1BoardsGetQueryKey, - useListBoardsApiV1BoardsGet, -} from "@/api/generated/boards/boards"; -import { type AgentRead } from "@/api/generated/model"; -import { createOptimisticListDeleteMutation } from "@/lib/list-delete"; -import { useOrganizationMembership } from "@/lib/use-organization-membership"; -import { useUrlSorting } from "@/lib/use-url-sorting"; - -const AGENT_SORTABLE_COLUMNS = [ - "name", - "status", - "openclaw_session_id", - "board_id", - "last_seen_at", - "updated_at", -]; - -export default function AgentsPage() { - const { isSignedIn } = useAuth(); - const queryClient = useQueryClient(); - const router = useRouter(); - - const { isAdmin } = useOrganizationMembership(isSignedIn); - const { sorting, onSortingChange } = useUrlSorting({ - allowedColumnIds: AGENT_SORTABLE_COLUMNS, - defaultSorting: [{ id: "name", desc: false }], - paramPrefix: "agents", - }); - - const [deleteTarget, setDeleteTarget] = useState(null); - - const boardsKey = getListBoardsApiV1BoardsGetQueryKey(); - const agentsKey = getListAgentsApiV1AgentsGetQueryKey(); - - const boardsQuery = useListBoardsApiV1BoardsGet< - listBoardsApiV1BoardsGetResponse, - ApiError - >(undefined, { - query: { - enabled: Boolean(isSignedIn && isAdmin), - refetchInterval: 30_000, - refetchOnMount: "always", - }, - }); - - const agentsQuery = useListAgentsApiV1AgentsGet< - listAgentsApiV1AgentsGetResponse, - ApiError - >(undefined, { - query: { - enabled: Boolean(isSignedIn && isAdmin), - refetchInterval: 15_000, - refetchOnMount: "always", - }, - }); - - const boards = useMemo( - () => - boardsQuery.data?.status === 200 - ? (boardsQuery.data.data.items ?? []) - : [], - [boardsQuery.data], - ); - const agents = useMemo( - () => - agentsQuery.data?.status === 200 - ? (agentsQuery.data.data.items ?? []) - : [], - [agentsQuery.data], - ); - - const deleteMutation = useDeleteAgentApiV1AgentsAgentIdDelete< - ApiError, - { previous?: listAgentsApiV1AgentsGetResponse } - >( - { - mutation: createOptimisticListDeleteMutation< - AgentRead, - listAgentsApiV1AgentsGetResponse, - { agentId: string } - >({ - queryClient, - queryKey: agentsKey, - getItemId: (agent) => agent.id, - getDeleteId: ({ agentId }) => agentId, - onSuccess: () => { - setDeleteTarget(null); - }, - invalidateQueryKeys: [agentsKey, boardsKey], - }), - }, - queryClient, - ); - - const handleDelete = () => { - if (!deleteTarget) return; - deleteMutation.mutate({ agentId: deleteTarget.id }); - }; - - return ( - <> - 0 ? ( - - ) : null - } - isAdmin={isAdmin} - adminOnlyMessage="Only organization owners and admins can access agents." - stickyHeader - > -
- -
- - {agentsQuery.error ? ( -

- {agentsQuery.error.message} -

- ) : null} -
- - { - if (!open) { - setDeleteTarget(null); - } - }} - ariaLabel="Delete agent" - title="Delete agent" - description={ - <> - This will remove {deleteTarget?.name}. This action cannot be undone. - - } - errorMessage={deleteMutation.error?.message} - onConfirm={handleDelete} - isConfirming={deleteMutation.isPending} - /> - - ); -} diff --git a/src/frontend/src/app/api/actions/route.ts b/src/frontend/src/app/api/actions/route.ts new file mode 100644 index 0000000..74afd1d --- /dev/null +++ b/src/frontend/src/app/api/actions/route.ts @@ -0,0 +1,160 @@ +/** + * Quick Actions API + * POST /api/actions body: { action } + * Available actions: git-status, restart-gateway, clear-temp, usage-stats, heartbeat + */ +import { NextRequest, NextResponse } from 'next/server'; +import { exec } from 'child_process'; +import { promisify } from 'util'; +import { logActivity } from '@/lib/activities-db'; + +const execAsync = promisify(exec); + +const WORKSPACE = process.env.OPENCLAW_DIR ? `${process.env.OPENCLAW_DIR}/workspace` : '/root/.openclaw/workspace'; + +interface ActionResult { + action: string; + status: 'success' | 'error'; + output: string; + duration_ms: number; + timestamp: string; +} + +async function runAction(action: string): Promise { + const start = Date.now(); + const timestamp = new Date().toISOString(); + + try { + let output = ''; + + switch (action) { + case 'git-status': { + // Find all git repos in workspace and get their status + const { stdout: dirs } = await execAsync(`find "${WORKSPACE}" -maxdepth 2 -name ".git" -type d 2>/dev/null | head -10`); + const repoPaths = dirs.trim().split('\n').filter(Boolean).map((d) => d.replace('/.git', '')); + + const results: string[] = []; + for (const repoPath of repoPaths) { + const name = repoPath.split('/').pop() || repoPath; + try { + const { stdout: status } = await execAsync(`cd "${repoPath}" && git status --short && git log --oneline -3 2>&1`); + results.push(`📁 ${name}:\n${status || '(clean)'}`); + } catch { + results.push(`📁 ${name}: (error reading git status)`); + } + } + output = results.length ? results.join('\n\n') : 'No git repos found in workspace'; + break; + } + + case 'restart-gateway': { + const { stdout, stderr } = await execAsync('systemctl restart openclaw-gateway 2>&1 || echo "Service not found"'); + output = stdout || stderr || 'Restart command executed'; + // Also check status + try { + const { stdout: status } = await execAsync('systemctl is-active openclaw-gateway 2>&1 || echo "unknown"'); + output += `\nStatus: ${status.trim()}`; + } catch {} + break; + } + + case 'clear-temp': { + const commands = [ + 'find /tmp -maxdepth 1 -type f -mtime +1 -delete 2>/dev/null; echo "Cleaned /tmp"', + `find "${WORKSPACE}" -name "*.tmp" -o -name "*.bak" | head -20 | xargs rm -f 2>/dev/null; echo "Cleaned tmp/bak files"`, + 'find /root/.pm2/logs -name "*.log" -size +50M -exec truncate -s 10M {} \\; 2>/dev/null; echo "Trimmed large PM2 logs"', + ]; + const results = await Promise.all(commands.map((cmd) => execAsync(cmd).then((r) => r.stdout).catch((e) => e.message))); + output = results.join('\n'); + break; + } + + case 'usage-stats': { + const { stdout: du } = await execAsync(`du -sh "${WORKSPACE}" 2>/dev/null || echo "N/A"`); + const { stdout: df } = await execAsync('df -h / | tail -1'); + const { stdout: mem } = await execAsync('free -h | head -2'); + const { stdout: cpu } = await execAsync("top -bn1 | grep 'Cpu(s)' | head -1"); + const { stdout: uptime } = await execAsync('uptime -p'); + output = `Workspace: ${du.trim()}\n\nDisk: ${df.trim()}\n\nMemory:\n${mem.trim()}\n\nCPU: ${cpu.trim()}\n\nUptime: ${uptime.trim()}`; + break; + } + + case 'heartbeat': { + // Check all critical services + const services = ['mission-control']; + const pm2services = ['classvault', 'content-vault', 'brain']; + const results: string[] = []; + + for (const svc of services) { + const { stdout } = await execAsync(`systemctl is-active ${svc} 2>/dev/null || echo "inactive"`); + const status = stdout.trim(); + results.push(`${status === 'active' ? '✅' : '❌'} ${svc}: ${status}`); + } + + try { + const { stdout: pm2 } = await execAsync('pm2 jlist 2>/dev/null'); + const pm2list = JSON.parse(pm2); + for (const svc of pm2services) { + const proc = pm2list.find((p: { name: string }) => p.name === svc); + const status = proc?.pm2_env?.status || 'not found'; + results.push(`${status === 'online' ? '✅' : '❌'} ${svc} (pm2): ${status}`); + } + } catch { + results.push('⚠️ PM2: could not connect'); + } + + // Ping the main site + try { + const { stdout: ping } = await execAsync('curl -s -o /dev/null -w "%{http_code}" --max-time 5 https://tenacitas.cazaustre.dev'); + results.push(`\n🌐 tenacitas.cazaustre.dev: HTTP ${ping.trim()}`); + } catch { + results.push('\n🌐 tenacitas.cazaustre.dev: unreachable'); + } + + output = results.join('\n'); + break; + } + + case 'npm-audit': { + const { stdout, stderr } = await execAsync(`cd "${WORKSPACE}/mission-control" && npm audit --json 2>/dev/null | node -e "const d=require('fs').readFileSync('/dev/stdin','utf-8');const j=JSON.parse(d);console.log('Vulnerabilities: '+JSON.stringify(j.metadata?.vulnerabilities||{}))" 2>&1`).catch((e) => ({ stdout: '', stderr: e.message })); + output = stdout || stderr || 'Audit completed'; + break; + } + + default: + throw new Error(`Unknown action: ${action}`); + } + + const duration_ms = Date.now() - start; + logActivity('command', `Quick action: ${action}`, 'success', { duration_ms, metadata: { action } }); + + return { action, status: 'success', output, duration_ms, timestamp }; + } catch (err) { + const duration_ms = Date.now() - start; + const errMsg = err instanceof Error ? err.message : String(err); + logActivity('command', `Quick action failed: ${action}`, 'error', { duration_ms, metadata: { action, error: errMsg } }); + return { action, status: 'error', output: errMsg, duration_ms, timestamp }; + } +} + +export async function POST(request: NextRequest) { + try { + const body = await request.json(); + const { action } = body; + + if (!action) { + return NextResponse.json({ error: 'Missing action' }, { status: 400 }); + } + + const validActions = ['git-status', 'restart-gateway', 'clear-temp', 'usage-stats', 'heartbeat', 'npm-audit']; + if (!validActions.includes(action)) { + return NextResponse.json({ error: `Unknown action. Valid: ${validActions.join(', ')}` }, { status: 400 }); + } + + const result = await runAction(action); + return NextResponse.json(result); + } catch (error) { + console.error('[actions] Error:', error); + return NextResponse.json({ error: 'Action failed' }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/activities/route.ts b/src/frontend/src/app/api/activities/route.ts new file mode 100644 index 0000000..9cc8a85 --- /dev/null +++ b/src/frontend/src/app/api/activities/route.ts @@ -0,0 +1,82 @@ +import { NextRequest, NextResponse } from 'next/server'; +import { logActivity, getActivities } from '@/lib/activities-db'; + +export async function GET(request: NextRequest) { + try { + const { searchParams } = new URL(request.url); + + const type = searchParams.get('type') || undefined; + const status = searchParams.get('status') || undefined; + const agent = searchParams.get('agent') || undefined; + const startDate = searchParams.get('startDate') || undefined; + const endDate = searchParams.get('endDate') || undefined; + const sort = (searchParams.get('sort') || 'newest') as 'newest' | 'oldest'; + const format = searchParams.get('format') || 'json'; + const limit = Math.min(parseInt(searchParams.get('limit') || '20'), format === 'csv' ? 10000 : 100); + const offset = parseInt(searchParams.get('offset') || '0'); + + const result = getActivities({ type, status, agent, startDate, endDate, sort, limit, offset }); + + // CSV export + if (format === 'csv') { + const header = 'id,timestamp,type,description,status,duration_ms,tokens_used,agent\n'; + const rows = result.activities.map((a) => [ + a.id, a.timestamp, a.type, + `"${(a.description || '').replace(/"/g, '""')}"`, + a.status, a.duration_ms ?? '', a.tokens_used ?? '', + a.agent ?? '', + ].join(',')).join('\n'); + const csv = header + rows; + return new NextResponse(csv, { + headers: { + 'Content-Type': 'text/csv', + 'Content-Disposition': `attachment; filename="activities-${new Date().toISOString().split('T')[0]}.csv"`, + }, + }); + } + + return NextResponse.json({ + activities: result.activities, + total: result.total, + limit, + offset, + hasMore: offset + limit < result.total, + }); + } catch (error) { + console.error('Failed to get activities:', error); + return NextResponse.json({ error: 'Failed to get activities' }, { status: 500 }); + } +} + +export async function POST(request: Request) { + try { + const body = await request.json(); + + if (!body.type || !body.description || !body.status) { + return NextResponse.json( + { error: 'Missing required fields: type, description, status' }, + { status: 400 } + ); + } + + const validStatuses = ['success', 'error', 'pending', 'running']; + if (!validStatuses.includes(body.status)) { + return NextResponse.json( + { error: `Invalid status. Must be one of: ${validStatuses.join(', ')}` }, + { status: 400 } + ); + } + + const activity = logActivity(body.type, body.description, body.status, { + duration_ms: body.duration_ms ?? null, + tokens_used: body.tokens_used ?? null, + agent: body.agent ?? null, + metadata: body.metadata ?? null, + }); + + return NextResponse.json(activity, { status: 201 }); + } catch (error) { + console.error('Failed to save activity:', error); + return NextResponse.json({ error: 'Failed to save activity' }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/activities/stats/route.ts b/src/frontend/src/app/api/activities/stats/route.ts new file mode 100644 index 0000000..5140589 --- /dev/null +++ b/src/frontend/src/app/api/activities/stats/route.ts @@ -0,0 +1,61 @@ +/** + * Activity Stats API + * GET /api/activities/stats + * Returns heatmap data, counts by type, status, and recent trend + */ +import { NextResponse } from 'next/server'; +import { getActivityStats } from '@/lib/activities-db'; +import Database from 'better-sqlite3'; +import path from 'path'; + +export async function GET() { + try { + const stats = getActivityStats(); + + // Also get heatmap data (last 52 weeks = 364 days) + const DB_PATH = path.join(process.cwd(), 'data', 'activities.db'); + const db = new Database(DB_PATH); + + const cutoff = new Date(Date.now() - 365 * 24 * 60 * 60 * 1000).toISOString(); + const heatmapRows = db.prepare(` + SELECT DATE(timestamp) as day, COUNT(*) as count + FROM activities + WHERE timestamp >= ? + GROUP BY DATE(timestamp) + ORDER BY day + `).all(cutoff) as Array<{ day: string; count: number }>; + + // Recent trend (last 7 days) + const trendRows = db.prepare(` + SELECT DATE(timestamp) as day, COUNT(*) as count, + SUM(CASE WHEN status = 'success' THEN 1 ELSE 0 END) as success, + SUM(CASE WHEN status = 'error' THEN 1 ELSE 0 END) as errors + FROM activities + WHERE timestamp >= datetime('now', '-7 days') + GROUP BY DATE(timestamp) + ORDER BY day DESC + `).all() as Array<{ day: string; count: number; success: number; errors: number }>; + + // Most active hour of day + const hourRows = db.prepare(` + SELECT strftime('%H', timestamp) as hour, COUNT(*) as count + FROM activities + WHERE timestamp >= datetime('now', '-30 days') + GROUP BY hour + ORDER BY count DESC + LIMIT 24 + `).all() as Array<{ hour: string; count: number }>; + + db.close(); + + return NextResponse.json({ + ...stats, + heatmap: heatmapRows, + trend: trendRows, + hourly: hourRows, + }); + } catch (error) { + console.error('[activities/stats] Error:', error); + return NextResponse.json({ error: 'Failed to get stats' }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/activities/stream/route.ts b/src/frontend/src/app/api/activities/stream/route.ts new file mode 100644 index 0000000..434ea57 --- /dev/null +++ b/src/frontend/src/app/api/activities/stream/route.ts @@ -0,0 +1,78 @@ +/** + * Real-time activity stream via SSE + * GET /api/activities/stream + * Sends new activities as they arrive (polling SQLite every 2 seconds) + */ +import { NextRequest } from 'next/server'; +import { getActivities } from '@/lib/activities-db'; + +export async function GET(request: NextRequest) { + const encoder = new TextEncoder(); + let lastId: string | null = null; + let closed = false; + + const stream = new ReadableStream({ + start(controller) { + const send = (data: unknown) => { + try { + controller.enqueue(encoder.encode(`data: ${JSON.stringify(data)}\n\n`)); + } catch {} + }; + + // Send initial ping + send({ type: 'connected', ts: new Date().toISOString() }); + + const poll = async () => { + if (closed) return; + + try { + const result = getActivities({ limit: 10, sort: 'newest' }); + const activities = result.activities; + + if (activities.length > 0) { + const newest = activities[0]; + + if (lastId === null) { + // First run: send a batch of recent activities + send({ type: 'batch', activities: activities.slice(0, 5) }); + lastId = newest.id; + } else if (newest.id !== lastId) { + // New activities since last check + const newActivities = activities.filter((a) => { + // Send activities newer than lastId + const lastIdx = activities.findIndex((x) => x.id === lastId); + if (lastIdx === -1) return true; + return activities.indexOf(a) < lastIdx; + }); + + for (const activity of newActivities.reverse()) { + send({ type: 'new', activity }); + } + lastId = newest.id; + } + } + } catch {} + + if (!closed) { + setTimeout(poll, 2000); + } + }; + + poll(); + + request.signal?.addEventListener('abort', () => { + closed = true; + try { controller.close(); } catch {} + }); + }, + }); + + return new Response(stream, { + headers: { + 'Content-Type': 'text/event-stream', + 'Cache-Control': 'no-cache', + 'Connection': 'keep-alive', + 'X-Accel-Buffering': 'no', + }, + }); +} diff --git a/src/frontend/src/app/api/agents/[id]/status/route.ts b/src/frontend/src/app/api/agents/[id]/status/route.ts new file mode 100644 index 0000000..b017845 --- /dev/null +++ b/src/frontend/src/app/api/agents/[id]/status/route.ts @@ -0,0 +1,77 @@ +import { NextResponse } from "next/server"; +import { readFileSync, readdirSync, statSync } from "fs"; +import { join } from "path"; + +export const dynamic = "force-dynamic"; + +export async function GET( + request: Request, + { params }: { params: Promise<{ id: string }> } +) { + try { + const { id } = await params; + + // Read openclaw config + const configPath = (process.env.OPENCLAW_DIR || "/root/.openclaw") + "/openclaw.json"; + const config = JSON.parse(readFileSync(configPath, "utf-8")); + + // Find agent + const agent = config.agents.list.find((a: any) => a.id === id); + if (!agent) { + return NextResponse.json({ error: "Agent not found" }, { status: 404 }); + } + + // Get memory files + const memoryPath = join(agent.workspace, "memory"); + let recentFiles: Array<{ date: string; size: number; modified: string }> = + []; + + try { + const files = readdirSync(memoryPath).filter((f) => + f.match(/^\d{4}-\d{2}-\d{2}\.md$/) + ); + recentFiles = files + .map((file) => { + const stat = statSync(join(memoryPath, file)); + return { + date: file.replace(".md", ""), + size: stat.size, + modified: stat.mtime.toISOString(), + }; + }) + .sort((a, b) => b.date.localeCompare(a.date)) + .slice(0, 7); + } catch (e) { + // Memory directory doesn't exist + } + + // Get session info (from OpenClaw API if available) + // For now, we return mock data + const sessions: Array = []; + + // Get telegram account info + const telegramAccount = config.channels?.telegram?.accounts?.[id]; + + return NextResponse.json({ + agent: { + id: agent.id, + name: agent.name, + model: agent.model?.primary || config.agents.defaults.model.primary, + workspace: agent.workspace, + dmPolicy: telegramAccount?.dmPolicy, + allowAgents: agent.subagents?.allowAgents || [], + telegramConfigured: !!telegramAccount?.botToken, + }, + memory: { + recentFiles, + }, + sessions, + }); + } catch (error) { + console.error("Error getting agent status:", error); + return NextResponse.json( + { error: "Failed to get agent status" }, + { status: 500 } + ); + } +} diff --git a/src/frontend/src/app/api/agents/route.ts b/src/frontend/src/app/api/agents/route.ts new file mode 100644 index 0000000..42d3f41 --- /dev/null +++ b/src/frontend/src/app/api/agents/route.ts @@ -0,0 +1,147 @@ +import { NextResponse } from "next/server"; +import { readFileSync } from "fs"; +import { join } from "path"; + +export const dynamic = "force-dynamic"; + +interface Agent { + id: string; + name?: string; + emoji: string; + color: string; + model: string; + workspace: string; + dmPolicy?: string; + allowAgents?: string[]; + allowAgentsDetails?: Array<{ + id: string; + name: string; + emoji: string; + color: string; + }>; + botToken?: string; + status: "online" | "offline"; + lastActivity?: string; + activeSessions: number; +} + +// Fallback config used when an agent doesn't define its own ui config in openclaw.json. +// The main agent reads name/emoji from env vars; all others fall back to generic defaults. +// Override via each agent's openclaw.json → ui.emoji / ui.color / name fields. +const DEFAULT_AGENT_CONFIG: Record = { + main: { + emoji: process.env.NEXT_PUBLIC_AGENT_EMOJI || "🤖", + color: "#ff6b35", + name: process.env.NEXT_PUBLIC_AGENT_NAME || "Mission Control", + }, +}; + +/** + * Get agent display info (emoji, color, name) from openclaw.json or defaults + */ +function getAgentDisplayInfo(agentId: string, agentConfig: any): { emoji: string; color: string; name: string } { + // First try to get from agent's own config in openclaw.json + const configEmoji = agentConfig?.ui?.emoji; + const configColor = agentConfig?.ui?.color; + const configName = agentConfig?.name; + + // Then try defaults + const defaults = DEFAULT_AGENT_CONFIG[agentId]; + + return { + emoji: configEmoji || defaults?.emoji || "🤖", + color: configColor || defaults?.color || "#666666", + name: configName || defaults?.name || agentId, + }; +} + +export async function GET() { + try { + // Read openclaw config + const configPath = (process.env.OPENCLAW_DIR || "/root/.openclaw") + "/openclaw.json"; + const config = JSON.parse(readFileSync(configPath, "utf-8")); + + // Get agents from config + const agents: Agent[] = config.agents.list.map((agent: any) => { + const agentInfo = getAgentDisplayInfo(agent.id, agent); + + // Get telegram account info + const telegramAccount = + config.channels?.telegram?.accounts?.[agent.id]; + const botToken = telegramAccount?.botToken; + + // Check if agent has recent activity + const memoryPath = join(agent.workspace, "memory"); + let lastActivity = undefined; + let status: "online" | "offline" = "offline"; + + try { + const today = new Date().toISOString().split("T")[0]; + const memoryFile = join(memoryPath, `${today}.md`); + const stat = require("fs").statSync(memoryFile); + lastActivity = stat.mtime.toISOString(); + // Consider online if activity within last 5 minutes + status = + Date.now() - stat.mtime.getTime() < 5 * 60 * 1000 + ? "online" + : "offline"; + } catch (e) { + // No recent activity + } + + // Get details of allowed subagents + const allowAgents = agent.subagents?.allowAgents || []; + const allowAgentsDetails = allowAgents.map((subagentId: string) => { + // Find subagent in config + const subagentConfig = config.agents.list.find( + (a: any) => a.id === subagentId + ); + if (subagentConfig) { + const subagentInfo = getAgentDisplayInfo(subagentId, subagentConfig); + return { + id: subagentId, + name: subagentConfig.name || subagentInfo.name, + emoji: subagentInfo.emoji, + color: subagentInfo.color, + }; + } + // Fallback if subagent not found in config + const fallbackInfo = getAgentDisplayInfo(subagentId, null); + return { + id: subagentId, + name: fallbackInfo.name, + emoji: fallbackInfo.emoji, + color: fallbackInfo.color, + }; + }); + + return { + id: agent.id, + name: agent.name || agentInfo.name, + emoji: agentInfo.emoji, + color: agentInfo.color, + model: + agent.model?.primary || config.agents.defaults.model.primary, + workspace: agent.workspace, + dmPolicy: + telegramAccount?.dmPolicy || + config.channels?.telegram?.dmPolicy || + "pairing", + allowAgents, + allowAgentsDetails, + botToken: botToken ? "configured" : undefined, + status, + lastActivity, + activeSessions: 0, // TODO: get from sessions API + }; + }); + + return NextResponse.json({ agents }); + } catch (error) { + console.error("Error reading agents:", error); + return NextResponse.json( + { error: "Failed to load agents" }, + { status: 500 } + ); + } +} diff --git a/src/frontend/src/app/api/analytics/route.ts b/src/frontend/src/app/api/analytics/route.ts new file mode 100644 index 0000000..9bd2a41 --- /dev/null +++ b/src/frontend/src/app/api/analytics/route.ts @@ -0,0 +1,85 @@ +import { NextResponse } from "next/server"; +import { format, subDays } from "date-fns"; +import Database from "better-sqlite3"; +import path from "path"; +import { promises as fs } from "fs"; + +const DB_PATH = path.join(process.cwd(), "data", "activities.db"); + +interface AnalyticsData { + byDay: { date: string; count: number }[]; + byType: { type: string; count: number }[]; + byHour: { hour: number; day: number; count: number }[]; + successRate: number; +} + +export async function GET(): Promise> { + // Try SQLite first, fallback to JSON + let activities: Array<{ type: string; status: string; timestamp: string }> = []; + + try { + await fs.access(DB_PATH); + const db = new Database(DB_PATH); + const rows = db.prepare("SELECT type, status, timestamp FROM activities ORDER BY timestamp DESC").all() as Array<{ type: string; status: string; timestamp: string }>; + db.close(); + activities = rows; + } catch { + // Fallback to JSON + try { + const { readFileSync } = await import("fs"); + const jsonPath = path.join(process.cwd(), "data", "activities.json"); + activities = JSON.parse(readFileSync(jsonPath, "utf-8")); + } catch {} + } + + // Last 7 days activity count + const today = new Date(); + const byDay: { date: string; count: number }[] = []; + for (let i = 6; i >= 0; i--) { + const date = subDays(today, i); + const dateStr = format(date, "yyyy-MM-dd"); + const displayDate = format(date, "MMM d"); + const count = activities.filter((a) => { + return a.timestamp.startsWith(dateStr); + }).length; + byDay.push({ date: displayDate, count }); + } + + // Activity by type + const typeMap = new Map(); + activities.forEach((a) => { + const normalized = a.type === "cron_run" ? "cron" : + a.type === "file_read" || a.type === "file_write" ? "file" : + a.type === "web_search" ? "search" : + a.type === "message_sent" ? "message" : + a.type === "tool_call" || a.type === "agent_action" ? "task" : a.type; + typeMap.set(normalized, (typeMap.get(normalized) || 0) + 1); + }); + const byType = Array.from(typeMap.entries()) + .map(([type, count]) => ({ type, count })) + .sort((a, b) => b.count - a.count); + + // Activity by hour/day heatmap + const hourDayMap = new Map(); + activities.forEach((a) => { + try { + const d = new Date(a.timestamp); + const hour = d.getHours(); + const day = d.getDay(); + const key = `${hour}-${day}`; + hourDayMap.set(key, (hourDayMap.get(key) || 0) + 1); + } catch {} + }); + + const byHour: { hour: number; day: number; count: number }[] = []; + hourDayMap.forEach((count, key) => { + const [hour, day] = key.split("-").map(Number); + byHour.push({ hour, day, count }); + }); + + // Success rate + const successCount = activities.filter((a) => a.status === "success").length; + const successRate = activities.length > 0 ? (successCount / activities.length) * 100 : 0; + + return NextResponse.json({ byDay, byType, byHour, successRate }); +} diff --git a/src/frontend/src/app/api/auth/login/route.ts b/src/frontend/src/app/api/auth/login/route.ts new file mode 100644 index 0000000..ab55897 --- /dev/null +++ b/src/frontend/src/app/api/auth/login/route.ts @@ -0,0 +1,115 @@ +import { NextResponse } from "next/server"; +import type { NextRequest } from "next/server"; + +// Simple in-memory rate limiter (per-IP, resets on server restart) +// Sufficient for a personal dashboard — no external dependency needed +const MAX_ATTEMPTS = 5; +const WINDOW_MS = 15 * 60 * 1000; // 15 minutes +const LOCKOUT_MS = 15 * 60 * 1000; // 15 minute lockout after max attempts + +interface AttemptRecord { + count: number; + windowStart: number; + lockedUntil?: number; +} + +const attempts = new Map(); + +function getClientIp(request: NextRequest): string { + return ( + request.headers.get("x-forwarded-for")?.split(",")[0]?.trim() || + request.headers.get("x-real-ip") || + "unknown" + ); +} + +function checkRateLimit(ip: string): { allowed: boolean; retryAfterMs?: number } { + const now = Date.now(); + const record = attempts.get(ip); + + if (!record) { + return { allowed: true }; + } + + // Still locked out? + if (record.lockedUntil && now < record.lockedUntil) { + return { allowed: false, retryAfterMs: record.lockedUntil - now }; + } + + // Window expired — reset + if (now - record.windowStart > WINDOW_MS) { + attempts.delete(ip); + return { allowed: true }; + } + + // Within window, check count + if (record.count >= MAX_ATTEMPTS) { + // Lock out + record.lockedUntil = now + LOCKOUT_MS; + attempts.set(ip, record); + return { allowed: false, retryAfterMs: LOCKOUT_MS }; + } + + return { allowed: true }; +} + +function recordFailure(ip: string): void { + const now = Date.now(); + const record = attempts.get(ip); + + if (!record || now - record.windowStart > WINDOW_MS) { + attempts.set(ip, { count: 1, windowStart: now }); + } else { + record.count += 1; + attempts.set(ip, record); + } +} + +function clearAttempts(ip: string): void { + attempts.delete(ip); +} + +export async function POST(request: NextRequest) { + const ip = getClientIp(request); + + // Rate limit check + const { allowed, retryAfterMs } = checkRateLimit(ip); + if (!allowed) { + const retryAfterSec = Math.ceil((retryAfterMs ?? LOCKOUT_MS) / 1000); + return NextResponse.json( + { success: false, error: "Too many failed attempts. Try again later." }, + { + status: 429, + headers: { "Retry-After": String(retryAfterSec) }, + } + ); + } + + const { password } = await request.json(); + + if (password === process.env.ADMIN_PASSWORD) { + clearAttempts(ip); // Reset on success + + const response = NextResponse.json({ success: true }); + + // Set auth cookie (7 days expiry) + // secure=true in production (HTTPS), false in dev (HTTP localhost) + response.cookies.set("mc_auth", process.env.AUTH_SECRET!, { + httpOnly: true, + secure: process.env.NODE_ENV === "production", + sameSite: "lax", + maxAge: 60 * 60 * 24 * 7, // 7 days + path: "/", + }); + + return response; + } + + // Record failed attempt + recordFailure(ip); + + return NextResponse.json( + { success: false, error: "Invalid password" }, + { status: 401 } + ); +} diff --git a/src/frontend/src/app/api/auth/logout/route.ts b/src/frontend/src/app/api/auth/logout/route.ts new file mode 100644 index 0000000..3fe1f8e --- /dev/null +++ b/src/frontend/src/app/api/auth/logout/route.ts @@ -0,0 +1,16 @@ +import { NextResponse } from "next/server"; + +export async function POST() { + const response = NextResponse.json({ success: true }); + + // Clear auth cookie + response.cookies.set("mc_auth", "", { + httpOnly: true, + secure: false, + sameSite: "lax", + maxAge: 0, + path: "/", + }); + + return response; +} diff --git a/src/frontend/src/app/api/browse/route.ts b/src/frontend/src/app/api/browse/route.ts new file mode 100644 index 0000000..7af3334 --- /dev/null +++ b/src/frontend/src/app/api/browse/route.ts @@ -0,0 +1,145 @@ +import { NextRequest, NextResponse } from "next/server"; +import { promises as fs } from "fs"; +import path from "path"; + +const OPENCLAW_DIR = process.env.OPENCLAW_DIR || "/root/.openclaw"; + +interface FileEntry { + name: string; + type: "file" | "folder"; + size: number; + modified: string; +} + +export async function GET(request: NextRequest) { + try { + const searchParams = request.nextUrl.searchParams; + const workspace = searchParams.get("workspace") || "workspace"; + const relativePath = searchParams.get("path") || ""; + const fileContent = searchParams.get("content") === "true"; + const rawMode = searchParams.get("raw") === "true"; + + // Determine BASE_PATH based on workspace + const BASE_PATH = path.join(OPENCLAW_DIR, workspace); + + // Validate workspace exists + try { + await fs.access(BASE_PATH); + } catch { + return NextResponse.json( + { error: "Workspace not found" }, + { status: 404 } + ); + } + + // Normalize and validate path to prevent directory traversal + const normalizedPath = path.normalize(relativePath).replace(/^(\.\.[\/\\])+/, ""); + const fullPath = path.join(BASE_PATH, normalizedPath); + + // Ensure the path is within BASE_PATH + if (!fullPath.startsWith(BASE_PATH)) { + return NextResponse.json( + { error: "Access denied: Path outside workspace" }, + { status: 403 } + ); + } + + const stats = await fs.stat(fullPath); + + // Serve raw file (for images etc.) + if (rawMode && stats.isFile()) { + const ext = path.extname(fullPath).toLowerCase().slice(1); + const mimeTypes: Record = { + png: "image/png", + jpg: "image/jpeg", + jpeg: "image/jpeg", + gif: "image/gif", + webp: "image/webp", + svg: "image/svg+xml", + ico: "image/x-icon", + }; + const contentType = mimeTypes[ext]; + if (!contentType) { + return NextResponse.json( + { error: "Raw mode only supports image files" }, + { status: 400 } + ); + } + const buffer = await fs.readFile(fullPath); + return new NextResponse(buffer, { + headers: { + "Content-Type": contentType, + "Content-Length": buffer.length.toString(), + "Cache-Control": "public, max-age=3600", + }, + }); + } + + // If requesting file content + if (fileContent && stats.isFile()) { + const content = await fs.readFile(fullPath, "utf-8"); + return NextResponse.json({ + name: path.basename(fullPath), + path: normalizedPath, + content, + size: stats.size, + modified: stats.mtime.toISOString(), + }); + } + + // If it's a directory, list contents + if (stats.isDirectory()) { + const entries = await fs.readdir(fullPath, { withFileTypes: true }); + + const items: FileEntry[] = await Promise.all( + entries + .filter((entry) => !entry.name.startsWith(".")) // Hide hidden files + .map(async (entry) => { + const entryPath = path.join(fullPath, entry.name); + const entryStats = await fs.stat(entryPath).catch(() => null); + + return { + name: entry.name, + type: entry.isDirectory() ? "folder" : "file", + size: entryStats?.size || 0, + modified: entryStats?.mtime.toISOString() || new Date().toISOString(), + } as FileEntry; + }) + ); + + // Sort: folders first, then by name + items.sort((a, b) => { + if (a.type !== b.type) { + return a.type === "folder" ? -1 : 1; + } + return a.name.localeCompare(b.name); + }); + + return NextResponse.json({ + path: normalizedPath, + items, + }); + } + + // Single file info + return NextResponse.json({ + name: path.basename(fullPath), + path: normalizedPath, + type: "file", + size: stats.size, + modified: stats.mtime.toISOString(), + }); + } catch (error) { + if ((error as NodeJS.ErrnoException).code === "ENOENT") { + return NextResponse.json( + { error: "Path not found" }, + { status: 404 } + ); + } + console.error("Browse API error:", error); + return NextResponse.json( + { error: "Failed to browse path" }, + { status: 500 } + ); + } +} diff --git a/src/frontend/src/app/api/costs/route.ts b/src/frontend/src/app/api/costs/route.ts new file mode 100644 index 0000000..635dd91 --- /dev/null +++ b/src/frontend/src/app/api/costs/route.ts @@ -0,0 +1,90 @@ +import { NextResponse } from "next/server"; +import { NextRequest } from "next/server"; +import { + getDatabase, + getCostSummary, + getCostByAgent, + getCostByModel, + getDailyCost, + getHourlyCost, +} from "@/lib/usage-queries"; +import path from "path"; + +const DB_PATH = path.join(process.cwd(), "data", "usage-tracking.db"); +const DEFAULT_BUDGET = 100.0; // Default budget in USD + +export async function GET(request: NextRequest) { + const searchParams = request.nextUrl.searchParams; + const timeframe = searchParams.get("timeframe") || "30d"; + + // Parse timeframe to days + const days = parseInt(timeframe.replace(/\D/g, ""), 10) || 30; + + try { + const db = getDatabase(DB_PATH); + + if (!db) { + // Database doesn't exist yet - return zeros + return NextResponse.json({ + today: 0, + yesterday: 0, + thisMonth: 0, + lastMonth: 0, + projected: 0, + budget: DEFAULT_BUDGET, + byAgent: [], + byModel: [], + daily: [], + hourly: [], + message: "No usage data collected yet. Run collect-usage script first.", + }); + } + + // Get all the data + const summary = getCostSummary(db); + const byAgent = getCostByAgent(db, days); + const byModel = getCostByModel(db, days); + const daily = getDailyCost(db, days); + const hourly = getHourlyCost(db); + + db.close(); + + return NextResponse.json({ + ...summary, + budget: DEFAULT_BUDGET, + byAgent, + byModel, + daily, + hourly, + }); + } catch (error) { + console.error("Error fetching cost data:", error); + return NextResponse.json( + { error: "Failed to fetch cost data" }, + { status: 500 } + ); + } +} + +// POST endpoint to update budget +export async function POST(request: NextRequest) { + try { + const body = await request.json(); + const { budget, alerts } = body; + + // In production, save to database + // For now, just return success + + return NextResponse.json({ + success: true, + budget, + alerts, + }); + } catch (error) { + console.error("Error updating budget:", error); + return NextResponse.json( + { error: "Failed to update budget" }, + { status: 500 } + ); + } +} diff --git a/src/frontend/src/app/api/cron/route.ts b/src/frontend/src/app/api/cron/route.ts new file mode 100644 index 0000000..16f6283 --- /dev/null +++ b/src/frontend/src/app/api/cron/route.ts @@ -0,0 +1,141 @@ +import { NextRequest, NextResponse } from "next/server"; +import { execSync } from "child_process"; + +function getGatewayConfig() { + try { + const configRaw = require("fs").readFileSync((process.env.OPENCLAW_DIR || "/root/.openclaw") + "/openclaw.json", "utf-8"); + const config = JSON.parse(configRaw); + return { + token: config.gateway?.auth?.token || "", + port: config.gateway?.port || 18789, + }; + } catch { + return { token: "", port: 18789 }; + } +} + +// GET: List all cron jobs from the OpenClaw gateway +export async function GET() { + try { + const output = execSync("openclaw cron list --json --all 2>/dev/null", { + timeout: 10000, + encoding: "utf-8", + }); + + const data = JSON.parse(output); + const jobs = (data.jobs || []).map((job: Record) => ({ + id: job.id, + agentId: job.agentId || "main", + name: job.name || "Unnamed", + enabled: job.enabled ?? true, + createdAtMs: job.createdAtMs, + updatedAtMs: job.updatedAtMs, + schedule: job.schedule, + sessionTarget: job.sessionTarget, + payload: job.payload, + delivery: job.delivery, + state: job.state, + // Derived fields for the UI + description: formatDescription(job), + scheduleDisplay: formatSchedule(job.schedule as Record), + timezone: (job.schedule as Record)?.tz || "UTC", + nextRun: (job.state as Record)?.nextRunAtMs + ? new Date((job.state as Record).nextRunAtMs).toISOString() + : null, + lastRun: (job.state as Record)?.lastRunAtMs + ? new Date((job.state as Record).lastRunAtMs).toISOString() + : null, + })); + + return NextResponse.json(jobs); + } catch (error) { + console.error("Error fetching cron jobs from gateway:", error); + return NextResponse.json( + { error: "Failed to fetch cron jobs from OpenClaw gateway" }, + { status: 500 } + ); + } +} + +function formatDescription(job: Record): string { + const payload = job.payload as Record; + if (!payload) return ""; + if (payload.kind === "agentTurn") { + const msg = (payload.message as string) || ""; + return msg.length > 120 ? msg.substring(0, 120) + "..." : msg; + } + if (payload.kind === "systemEvent") { + const text = (payload.text as string) || ""; + return text.length > 120 ? text.substring(0, 120) + "..." : text; + } + return ""; +} + +function formatSchedule(schedule: Record): string { + if (!schedule) return "Unknown"; + switch (schedule.kind) { + case "cron": + return `${schedule.expr}${schedule.tz ? ` (${schedule.tz})` : ""}`; + case "every": + const ms = schedule.everyMs as number; + if (ms >= 3600000) return `Every ${ms / 3600000}h`; + if (ms >= 60000) return `Every ${ms / 60000}m`; + return `Every ${ms / 1000}s`; + case "at": + return `Once at ${schedule.at}`; + default: + return JSON.stringify(schedule); + } +} + +// PUT: Toggle enable/disable a cron job +export async function PUT(request: NextRequest) { + try { + const body = await request.json(); + const { id, enabled } = body; + + if (!id) { + return NextResponse.json({ error: "Job ID is required" }, { status: 400 }); + } + + const action = enabled ? "enable" : "disable"; + // Use openclaw CLI to update the job + const output = execSync( + `openclaw cron ${action} ${id} --json 2>/dev/null || openclaw cron update ${id} --enabled=${enabled} --json 2>/dev/null`, + { timeout: 10000, encoding: "utf-8" } + ); + + return NextResponse.json({ success: true, id, enabled }); + } catch (error) { + console.error("Error updating cron job:", error); + return NextResponse.json( + { error: "Failed to update cron job" }, + { status: 500 } + ); + } +} + +// DELETE: Remove a cron job +export async function DELETE(request: NextRequest) { + try { + const { searchParams } = new URL(request.url); + const id = searchParams.get("id"); + + if (!id) { + return NextResponse.json({ error: "Job ID is required" }, { status: 400 }); + } + + execSync(`openclaw cron remove ${id} 2>/dev/null`, { + timeout: 10000, + encoding: "utf-8", + }); + + return NextResponse.json({ success: true, deleted: id }); + } catch (error) { + console.error("Error deleting cron job:", error); + return NextResponse.json( + { error: "Failed to delete cron job" }, + { status: 500 } + ); + } +} diff --git a/src/frontend/src/app/api/cron/run/route.ts b/src/frontend/src/app/api/cron/run/route.ts new file mode 100644 index 0000000..ceb6328 --- /dev/null +++ b/src/frontend/src/app/api/cron/run/route.ts @@ -0,0 +1,64 @@ +import { NextRequest, NextResponse } from "next/server"; +import { execSync } from "child_process"; + +async function createNotification(title: string, message: string, type: "info" | "success" | "warning" | "error" = "info") { + try { + await fetch(`${process.env.NEXT_PUBLIC_BASE_URL || "http://localhost:3000"}/api/notifications`, { + method: "POST", + headers: { "Content-Type": "application/json" }, + body: JSON.stringify({ title, message, type }), + }); + } catch (error) { + console.error("Failed to create notification:", error); + } +} + +// POST: Trigger a cron job immediately +export async function POST(request: NextRequest) { + try { + const body = await request.json(); + const { id } = body; + + if (!id) { + return NextResponse.json({ error: "Job ID required" }, { status: 400 }); + } + + // Validate id is safe (alphanumeric, hyphens, underscores only) + if (!/^[a-zA-Z0-9_-]+$/.test(id)) { + return NextResponse.json({ error: "Invalid job ID" }, { status: 400 }); + } + + const output = execSync(`openclaw cron run ${id} --force 2>&1`, { + timeout: 15000, + encoding: "utf-8", + }); + + // Create success notification + await createNotification( + "Cron Job Triggered", + `Job "${id}" has been manually executed.`, + "success" + ); + + return NextResponse.json({ + success: true, + jobId: id, + message: output.trim() || "Job triggered successfully", + }); + } catch (error) { + const message = error instanceof Error ? error.message : "Failed to trigger job"; + console.error("Error triggering cron job:", error); + + // Create error notification + const body = await request.json(); + await createNotification( + "Cron Job Failed", + `Failed to execute job "${body.id}": ${message}`, + "error" + ); + + // Even if the command exits with non-zero, the job might have been triggered + // The openclaw CLI sometimes exits with error but still works + return NextResponse.json({ success: false, error: message }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/cron/runs/route.ts b/src/frontend/src/app/api/cron/runs/route.ts new file mode 100644 index 0000000..b270dd5 --- /dev/null +++ b/src/frontend/src/app/api/cron/runs/route.ts @@ -0,0 +1,73 @@ +import { NextRequest, NextResponse } from "next/server"; +import { execSync } from "child_process"; + +// GET: Fetch run history for a cron job +export async function GET(request: NextRequest) { + try { + const { searchParams } = new URL(request.url); + const id = searchParams.get("id"); + + if (!id) { + return NextResponse.json({ error: "Job ID required" }, { status: 400 }); + } + + if (!/^[a-zA-Z0-9_-]+$/.test(id)) { + return NextResponse.json({ error: "Invalid job ID" }, { status: 400 }); + } + + let runs: RunEntry[] = []; + + try { + const output = execSync(`openclaw cron runs ${id} --json 2>/dev/null`, { + timeout: 10000, + encoding: "utf-8", + }); + + const data = JSON.parse(output); + const rawRuns: RawRun[] = data.runs || data || []; + + runs = rawRuns.map((r: RawRun) => ({ + id: r.id || `${id}-${r.startedAt}`, + jobId: id, + startedAt: r.startedAt || r.createdAt || null, + completedAt: r.completedAt || r.finishedAt || null, + status: r.status || "unknown", + durationMs: + r.durationMs || + (r.startedAt && r.completedAt + ? new Date(r.completedAt).getTime() - new Date(r.startedAt).getTime() + : null), + error: r.error || null, + })); + } catch { + // Command might not support runs yet or no history — return empty + runs = []; + } + + return NextResponse.json({ runs, total: runs.length }); + } catch (error) { + console.error("Error fetching run history:", error); + return NextResponse.json({ error: "Failed to fetch run history" }, { status: 500 }); + } +} + +interface RawRun { + id?: string; + startedAt?: string; + createdAt?: string; + completedAt?: string; + finishedAt?: string; + status?: string; + durationMs?: number; + error?: string; +} + +interface RunEntry { + id: string; + jobId: string; + startedAt: string | null; + completedAt: string | null; + status: string; + durationMs: number | null; + error: string | null; +} diff --git a/src/frontend/src/app/api/files/delete/route.ts b/src/frontend/src/app/api/files/delete/route.ts new file mode 100644 index 0000000..85d736c --- /dev/null +++ b/src/frontend/src/app/api/files/delete/route.ts @@ -0,0 +1,59 @@ +import { NextRequest, NextResponse } from 'next/server'; +import { promises as fs } from 'fs'; +import path from 'path'; +import { logActivity } from '@/lib/activities-db'; + +const OPENCLAW_DIR = process.env.OPENCLAW_DIR || '/root/.openclaw'; + +const WORKSPACE_MAP: Record = { + workspace: path.join(OPENCLAW_DIR, 'workspace'), + 'mission-control': path.join(OPENCLAW_DIR, 'workspace', 'mission-control'), +}; + +// Protected paths - never allow deletion +const PROTECTED = [ + 'MEMORY.md', 'SOUL.md', 'USER.md', 'AGENTS.md', 'TOOLS.md', + 'package.json', 'tsconfig.json', '.env', '.env.local', +]; + +export async function DELETE(request: NextRequest) { + try { + const body = await request.json(); + const { workspace, path: filePath } = body; + + if (!filePath) { + return NextResponse.json({ error: 'Missing path' }, { status: 400 }); + } + + const base = WORKSPACE_MAP[workspace || 'workspace']; + if (!base) { + return NextResponse.json({ error: 'Unknown workspace' }, { status: 400 }); + } + + const fullPath = path.resolve(base, filePath); + if (!fullPath.startsWith(base)) { + return NextResponse.json({ error: 'Invalid path' }, { status: 400 }); + } + + const filename = path.basename(fullPath); + if (PROTECTED.includes(filename)) { + return NextResponse.json({ error: `Cannot delete protected file: ${filename}` }, { status: 403 }); + } + + const stat = await fs.stat(fullPath); + if (stat.isDirectory()) { + await fs.rm(fullPath, { recursive: true }); + } else { + await fs.unlink(fullPath); + } + + logActivity('file_write', `Deleted ${stat.isDirectory() ? 'folder' : 'file'}: ${filePath}`, 'success', { + metadata: { workspace, filePath }, + }); + + return NextResponse.json({ success: true }); + } catch (error) { + console.error('[delete] Error:', error); + return NextResponse.json({ error: 'Delete failed' }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/files/download/route.ts b/src/frontend/src/app/api/files/download/route.ts new file mode 100644 index 0000000..115f56a --- /dev/null +++ b/src/frontend/src/app/api/files/download/route.ts @@ -0,0 +1,87 @@ +import { NextRequest, NextResponse } from 'next/server'; +import { promises as fs } from 'fs'; +import path from 'path'; +import { logActivity } from '@/lib/activities-db'; + +const OPENCLAW_DIR = process.env.OPENCLAW_DIR || '/root/.openclaw'; + +const WORKSPACE_MAP: Record = { + workspace: path.join(OPENCLAW_DIR, 'workspace'), + 'mission-control': path.join(OPENCLAW_DIR, 'workspace', 'mission-control'), +}; + +function getMimeType(filename: string): string { + const ext = path.extname(filename).toLowerCase(); + const mimeMap: Record = { + '.ts': 'text/plain', + '.tsx': 'text/plain', + '.js': 'text/javascript', + '.jsx': 'text/javascript', + '.json': 'application/json', + '.md': 'text/markdown', + '.txt': 'text/plain', + '.log': 'text/plain', + '.py': 'text/plain', + '.sh': 'text/plain', + '.yaml': 'text/yaml', + '.yml': 'text/yaml', + '.toml': 'text/plain', + '.css': 'text/css', + '.html': 'text/html', + '.png': 'image/png', + '.jpg': 'image/jpeg', + '.jpeg': 'image/jpeg', + '.gif': 'image/gif', + '.svg': 'image/svg+xml', + '.webp': 'image/webp', + '.pdf': 'application/pdf', + '.zip': 'application/zip', + }; + return mimeMap[ext] || 'application/octet-stream'; +} + +export async function GET(request: NextRequest) { + try { + const { searchParams } = new URL(request.url); + const workspace = searchParams.get('workspace') || 'workspace'; + const filePath = searchParams.get('path') || ''; + + if (!filePath) { + return NextResponse.json({ error: 'Missing path parameter' }, { status: 400 }); + } + + const base = WORKSPACE_MAP[workspace]; + if (!base) { + return NextResponse.json({ error: 'Unknown workspace' }, { status: 400 }); + } + + const fullPath = path.resolve(base, filePath); + if (!fullPath.startsWith(base)) { + return NextResponse.json({ error: 'Invalid path' }, { status: 400 }); + } + + const stat = await fs.stat(fullPath); + if (!stat.isFile()) { + return NextResponse.json({ error: 'Not a file' }, { status: 400 }); + } + + const content = await fs.readFile(fullPath); + const filename = path.basename(fullPath); + const mimeType = getMimeType(filename); + + logActivity('file_read', `Downloaded file: ${filePath}`, 'success', { + metadata: { workspace, filePath, size: stat.size }, + }); + + return new NextResponse(content, { + headers: { + 'Content-Type': mimeType, + 'Content-Disposition': `attachment; filename="${filename}"`, + 'Content-Length': stat.size.toString(), + }, + }); + } catch (error) { + console.error('[download] Error:', error); + return NextResponse.json({ error: 'Download failed' }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/files/mkdir/route.ts b/src/frontend/src/app/api/files/mkdir/route.ts new file mode 100644 index 0000000..5d3a4de --- /dev/null +++ b/src/frontend/src/app/api/files/mkdir/route.ts @@ -0,0 +1,41 @@ +import { NextRequest, NextResponse } from 'next/server'; +import { promises as fs } from 'fs'; +import path from 'path'; + +const OPENCLAW_DIR = process.env.OPENCLAW_DIR || '/root/.openclaw'; + +const WORKSPACE_MAP: Record = { + workspace: path.join(OPENCLAW_DIR, 'workspace'), + 'mission-control': path.join(OPENCLAW_DIR, 'workspace', 'mission-control'), +}; + +export async function POST(request: NextRequest) { + try { + const body = await request.json(); + const { workspace, path: dirPath, name } = body; + + if (!dirPath && !name) { + return NextResponse.json({ error: 'Missing path or name' }, { status: 400 }); + } + + const base = WORKSPACE_MAP[workspace || 'workspace']; + if (!base) { + return NextResponse.json({ error: 'Unknown workspace' }, { status: 400 }); + } + + const targetPath = name + ? path.resolve(base, dirPath || '', name) + : path.resolve(base, dirPath); + + if (!targetPath.startsWith(base)) { + return NextResponse.json({ error: 'Invalid path' }, { status: 400 }); + } + + await fs.mkdir(targetPath, { recursive: true }); + + return NextResponse.json({ success: true, path: path.relative(base, targetPath) }); + } catch (error) { + console.error('[mkdir] Error:', error); + return NextResponse.json({ error: 'Failed to create directory' }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/files/route.ts b/src/frontend/src/app/api/files/route.ts new file mode 100644 index 0000000..db5dc1a --- /dev/null +++ b/src/frontend/src/app/api/files/route.ts @@ -0,0 +1,194 @@ +import { NextRequest, NextResponse } from "next/server"; +import { promises as fs } from "fs"; +import path from "path"; + +const OPENCLAW_DIR = process.env.OPENCLAW_DIR || "/root/.openclaw"; + +// Files to show in the memory browser +const ROOT_FILES = ["MEMORY.md", "SOUL.md", "USER.md", "AGENTS.md", "TOOLS.md", "IDENTITY.md"]; +const MEMORY_DIR = "memory"; + +interface FileNode { + name: string; + path: string; + type: "file" | "folder"; + children?: FileNode[]; +} + +async function fileExists(filePath: string): Promise { + try { + await fs.access(filePath); + return true; + } catch { + return false; + } +} + +async function getFileTree(workspacePath: string): Promise { + const tree: FileNode[] = []; + + // Add root markdown files + for (const file of ROOT_FILES) { + const fullPath = path.join(workspacePath, file); + if (await fileExists(fullPath)) { + tree.push({ + name: file, + path: file, + type: "file", + }); + } + } + + // Add memory folder if it exists + const memoryPath = path.join(workspacePath, MEMORY_DIR); + if (await fileExists(memoryPath)) { + const memoryStats = await fs.stat(memoryPath); + if (memoryStats.isDirectory()) { + const memoryFiles = await fs.readdir(memoryPath); + const children: FileNode[] = []; + + for (const file of memoryFiles.sort().reverse()) { + if (file.endsWith(".md")) { + children.push({ + name: file, + path: `${MEMORY_DIR}/${file}`, + type: "file", + }); + } + } + + if (children.length > 0) { + tree.push({ + name: MEMORY_DIR, + path: MEMORY_DIR, + type: "folder", + children, + }); + } + } + } + + return tree; +} + +function sanitizePath(requestedPath: string): string | null { + // Prevent directory traversal + const normalized = path.normalize(requestedPath); + if (normalized.startsWith("..") || path.isAbsolute(normalized)) { + return null; + } + + // Only allow .md files + if (!normalized.endsWith(".md")) { + return null; + } + + // Only allow root files or files in memory/ + const isRootFile = ROOT_FILES.includes(normalized); + const isMemoryFile = normalized.startsWith(`${MEMORY_DIR}/`); + + if (!isRootFile && !isMemoryFile) { + return null; + } + + return normalized; +} + +export async function GET(request: NextRequest) { + const { searchParams } = new URL(request.url); + const workspace = searchParams.get("workspace") || "workspace"; + const filePath = searchParams.get("path"); + + try { + // Determine workspace path + const workspacePath = path.join(OPENCLAW_DIR, workspace); + + // Validate workspace exists + if (!(await fileExists(workspacePath))) { + return NextResponse.json( + { error: "Workspace not found" }, + { status: 404 } + ); + } + + if (!filePath) { + // Return file tree + const tree = await getFileTree(workspacePath); + return NextResponse.json(tree); + } + + // Read specific file + const safePath = sanitizePath(filePath); + if (!safePath) { + return NextResponse.json( + { error: "Invalid file path" }, + { status: 400 } + ); + } + + const fullPath = path.join(workspacePath, safePath); + if (!(await fileExists(fullPath))) { + return NextResponse.json( + { error: "File not found" }, + { status: 404 } + ); + } + + const content = await fs.readFile(fullPath, "utf-8"); + return NextResponse.json({ path: safePath, content }); + } catch (error) { + console.error("Error reading file:", error); + return NextResponse.json( + { error: "Failed to read file" }, + { status: 500 } + ); + } +} + +export async function PUT(request: NextRequest) { + try { + const body = await request.json(); + const { workspace = "workspace", path: filePath, content } = body; + + if (!filePath || typeof content !== "string") { + return NextResponse.json( + { error: "Missing path or content" }, + { status: 400 } + ); + } + + const safePath = sanitizePath(filePath); + if (!safePath) { + return NextResponse.json( + { error: "Invalid file path" }, + { status: 400 } + ); + } + + const workspacePath = path.join(OPENCLAW_DIR, workspace); + + // Validate workspace exists + if (!(await fileExists(workspacePath))) { + return NextResponse.json( + { error: "Workspace not found" }, + { status: 404 } + ); + } + + const fullPath = path.join(workspacePath, safePath); + + // Create memory directory if needed + const dir = path.dirname(fullPath); + await fs.mkdir(dir, { recursive: true }); + + await fs.writeFile(fullPath, content, "utf-8"); + + return NextResponse.json({ success: true, path: safePath }); + } catch (error) { + console.error("Error saving file:", error); + return NextResponse.json( + { error: "Failed to save file" }, + { status: 500 } + ); + } +} diff --git a/src/frontend/src/app/api/files/upload/route.ts b/src/frontend/src/app/api/files/upload/route.ts new file mode 100644 index 0000000..2c98aad --- /dev/null +++ b/src/frontend/src/app/api/files/upload/route.ts @@ -0,0 +1,68 @@ +import { NextRequest, NextResponse } from 'next/server'; +import { promises as fs } from 'fs'; +import path from 'path'; +import { logActivity } from '@/lib/activities-db'; + +const OPENCLAW_DIR = process.env.OPENCLAW_DIR || '/root/.openclaw'; + +const WORKSPACE_MAP: Record = { + workspace: path.join(OPENCLAW_DIR, 'workspace'), + 'mission-control': path.join(OPENCLAW_DIR, 'workspace', 'mission-control'), +}; + +function resolvePath(workspace: string, filePath: string): string | null { + const base = WORKSPACE_MAP[workspace]; + if (!base) return null; + const full = path.resolve(base, filePath); + if (!full.startsWith(base)) return null; // path traversal check + return full; +} + +export async function POST(request: NextRequest) { + try { + const formData = await request.formData(); + const workspace = (formData.get('workspace') as string) || 'workspace'; + const dirPath = (formData.get('path') as string) || ''; + const files = formData.getAll('files') as File[]; + + if (!files || files.length === 0) { + return NextResponse.json({ error: 'No files provided' }, { status: 400 }); + } + + const base = WORKSPACE_MAP[workspace]; + if (!base) { + return NextResponse.json({ error: 'Unknown workspace' }, { status: 400 }); + } + + const results: Array<{ name: string; size: number; path: string }> = []; + + for (const file of files) { + const sanitizedName = path.basename(file.name); + const targetDir = path.resolve(base, dirPath); + if (!targetDir.startsWith(base)) { + continue; // skip unsafe + } + + await fs.mkdir(targetDir, { recursive: true }); + const targetPath = path.join(targetDir, sanitizedName); + + const buffer = Buffer.from(await file.arrayBuffer()); + await fs.writeFile(targetPath, buffer); + + results.push({ + name: sanitizedName, + size: buffer.length, + path: dirPath ? `${dirPath}/${sanitizedName}` : sanitizedName, + }); + } + + logActivity('file_write', `Uploaded ${results.length} file(s) to ${workspace}/${dirPath || '/'}`, 'success', { + metadata: { files: results.map((r) => r.name), workspace, dirPath }, + }); + + return NextResponse.json({ success: true, files: results }); + } catch (error) { + console.error('[upload] Error:', error); + return NextResponse.json({ error: 'Upload failed' }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/files/workspaces/route.ts b/src/frontend/src/app/api/files/workspaces/route.ts new file mode 100644 index 0000000..61f69c2 --- /dev/null +++ b/src/frontend/src/app/api/files/workspaces/route.ts @@ -0,0 +1,95 @@ +import { NextResponse } from 'next/server'; +import fs from 'fs'; +import path from 'path'; + +const OPENCLAW_DIR = process.env.OPENCLAW_DIR || '/root/.openclaw'; + +interface Workspace { + id: string; + name: string; + emoji: string; + path: string; + agentName?: string; +} + +function getAgentInfo(workspacePath: string): { name: string; emoji: string } | null { + const identityPath = path.join(workspacePath, 'IDENTITY.md'); + + if (!fs.existsSync(identityPath)) { + return null; + } + + try { + const content = fs.readFileSync(identityPath, 'utf-8'); + + const nameMatch = content.match(/- \*\*Name:\*\* (.+)/); + const emojiMatch = content.match(/- \*\*Emoji:\*\* (.+)/); + + let emoji = '📁'; + if (emojiMatch) { + // Extract just the emoji character (first few characters before any description) + const emojiText = emojiMatch[1].trim(); + emoji = emojiText.split(' ')[0]; // Take only the first part (the emoji) + } + + return { + name: nameMatch ? nameMatch[1].trim() : '', + emoji, + }; + } catch { + return null; + } +} + +export async function GET() { + try { + const workspaces: Workspace[] = []; + + // Main workspace + const mainWorkspace = path.join(OPENCLAW_DIR, 'workspace'); + if (fs.existsSync(mainWorkspace)) { + const mainInfo = getAgentInfo(mainWorkspace); + workspaces.push({ + id: 'workspace', + name: 'Workspace Principal', + emoji: mainInfo?.emoji || '🦞', + path: mainWorkspace, + agentName: mainInfo?.name || 'Tenacitas', + }); + } + + // Agent workspaces + const entries = fs.readdirSync(OPENCLAW_DIR, { withFileTypes: true }); + + for (const entry of entries) { + if (entry.isDirectory() && entry.name.startsWith('workspace-')) { + const workspacePath = path.join(OPENCLAW_DIR, entry.name); + const agentInfo = getAgentInfo(workspacePath); + + const agentId = entry.name.replace('workspace-', ''); + // Friendly workspace name: capitalize the directory id (e.g. "academic" → "Academic") + const workspaceLabel = agentId.charAt(0).toUpperCase() + agentId.slice(1); + + workspaces.push({ + id: entry.name, + name: workspaceLabel, + emoji: agentInfo?.emoji || '🤖', + path: workspacePath, + agentName: agentInfo?.name || undefined, + }); + } + } + + // Sort: main first, then alphabetically + workspaces.sort((a, b) => { + if (a.id === 'workspace') return -1; + if (b.id === 'workspace') return 1; + return a.name.localeCompare(b.name); + }); + + return NextResponse.json({ workspaces }); + } catch (error) { + console.error('Failed to list workspaces:', error); + return NextResponse.json({ workspaces: [] }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/files/write/route.ts b/src/frontend/src/app/api/files/write/route.ts new file mode 100644 index 0000000..108bd46 --- /dev/null +++ b/src/frontend/src/app/api/files/write/route.ts @@ -0,0 +1,52 @@ +/** + * Write file content endpoint + * POST /api/files/write + * Body: { workspace, path, content } + */ +import { NextRequest, NextResponse } from 'next/server'; +import { promises as fs } from 'fs'; +import path from 'path'; +import { logActivity } from '@/lib/activities-db'; + +const OPENCLAW_DIR = process.env.OPENCLAW_DIR || '/root/.openclaw'; + +const WORKSPACE_MAP: Record = { + workspace: path.join(OPENCLAW_DIR, 'workspace'), + 'mission-control': path.join(OPENCLAW_DIR, 'workspace', 'mission-control'), +}; + +export async function POST(request: NextRequest) { + try { + const body = await request.json(); + const { workspace, path: filePath, content } = body; + + if (!filePath || content === undefined) { + return NextResponse.json({ error: 'Missing path or content' }, { status: 400 }); + } + + const base = WORKSPACE_MAP[workspace || 'workspace']; + if (!base) { + return NextResponse.json({ error: 'Unknown workspace' }, { status: 400 }); + } + + const fullPath = path.resolve(base, filePath); + if (!fullPath.startsWith(base)) { + return NextResponse.json({ error: 'Invalid path' }, { status: 400 }); + } + + // Create parent directories if needed + await fs.mkdir(path.dirname(fullPath), { recursive: true }); + await fs.writeFile(fullPath, content, 'utf-8'); + + const stat = await fs.stat(fullPath); + + logActivity('file_write', `Edited file: ${filePath}`, 'success', { + metadata: { workspace, filePath, size: stat.size }, + }); + + return NextResponse.json({ success: true, path: filePath, size: stat.size }); + } catch (error) { + console.error('[write] Error:', error); + return NextResponse.json({ error: 'Write failed' }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/git/route.ts b/src/frontend/src/app/api/git/route.ts new file mode 100644 index 0000000..6902333 --- /dev/null +++ b/src/frontend/src/app/api/git/route.ts @@ -0,0 +1,170 @@ +/** + * Git Dashboard API + * GET /api/git - List all repos with status + * POST /api/git - { repo, action } actions: status, pull, add, commit + */ +import { NextRequest, NextResponse } from 'next/server'; +import { exec } from 'child_process'; +import { promisify } from 'util'; +import { promises as fs } from 'fs'; +import path from 'path'; + +const execAsync = promisify(exec); +const WORKSPACE = process.env.OPENCLAW_DIR ? `${process.env.OPENCLAW_DIR}/workspace` : '/root/.openclaw/workspace'; + +interface RepoStatus { + name: string; + path: string; + branch: string; + ahead: number; + behind: number; + staged: string[]; + unstaged: string[]; + untracked: string[]; + lastCommit: { hash: string; message: string; author: string; date: string } | null; + remoteUrl: string; + isDirty: boolean; +} + +async function getRepos(): Promise { + const { stdout } = await execAsync(`find "${WORKSPACE}" -maxdepth 2 -name ".git" -type d 2>/dev/null`); + return stdout.trim().split('\n').filter(Boolean).map((d) => d.replace('/.git', '')); +} + +async function getRepoStatus(repoPath: string): Promise { + const name = repoPath.split('/').pop() || repoPath; + + try { + // Get branch + const { stdout: branch } = await execAsync(`cd "${repoPath}" && git rev-parse --abbrev-ref HEAD 2>/dev/null`).catch(() => ({ stdout: 'unknown' })); + + // Get ahead/behind + let ahead = 0, behind = 0; + try { + const { stdout: abStr } = await execAsync(`cd "${repoPath}" && git rev-list --left-right --count HEAD...@{upstream} 2>/dev/null`).catch(() => ({ stdout: '0\t0' })); + const parts = abStr.trim().split('\t'); + ahead = parseInt(parts[0]) || 0; + behind = parseInt(parts[1]) || 0; + } catch {} + + // Get status + const { stdout: statusOut } = await execAsync(`cd "${repoPath}" && git status --porcelain 2>/dev/null`).catch(() => ({ stdout: '' })); + const lines = statusOut.trim().split('\n').filter(Boolean); + + const staged: string[] = []; + const unstaged: string[] = []; + const untracked: string[] = []; + + for (const line of lines) { + const xy = line.slice(0, 2); + const file = line.slice(3); + const x = xy[0]; // staged + const y = xy[1]; // unstaged + + if (x !== ' ' && x !== '?') staged.push(file); + if (y !== ' ' && y !== '?') unstaged.push(file); + if (xy === '??') untracked.push(file); + } + + // Last commit + let lastCommit = null; + try { + const { stdout: commitOut } = await execAsync(`cd "${repoPath}" && git log -1 --format="%H|%s|%an|%ar" 2>/dev/null`); + const parts = commitOut.trim().split('|'); + if (parts.length >= 4) { + lastCommit = { hash: parts[0].slice(0, 8), message: parts[1], author: parts[2], date: parts[3] }; + } + } catch {} + + // Remote URL + let remoteUrl = ''; + try { + const { stdout: remote } = await execAsync(`cd "${repoPath}" && git remote get-url origin 2>/dev/null`); + remoteUrl = remote.trim(); + } catch {} + + return { + name, + path: repoPath, + branch: branch.trim(), + ahead, + behind, + staged, + unstaged, + untracked, + lastCommit, + remoteUrl, + isDirty: staged.length > 0 || unstaged.length > 0 || untracked.length > 0, + }; + } catch (error) { + return { + name, + path: repoPath, + branch: 'unknown', + ahead: 0, + behind: 0, + staged: [], + unstaged: [], + untracked: [], + lastCommit: null, + remoteUrl: '', + isDirty: false, + }; + } +} + +export async function GET() { + try { + const repos = await getRepos(); + const statuses = await Promise.all(repos.map(getRepoStatus)); + return NextResponse.json({ repos: statuses, total: statuses.length }); + } catch (error) { + console.error('[git] Error:', error); + return NextResponse.json({ error: 'Failed to get repos' }, { status: 500 }); + } +} + +const ALLOWED_REPOS = [WORKSPACE + '/mission-control', WORKSPACE]; + +export async function POST(request: NextRequest) { + try { + const body = await request.json(); + const { repo, action } = body; + + // Security: only allow repos under workspace + if (!repo || !repo.startsWith(WORKSPACE)) { + return NextResponse.json({ error: 'Invalid repo path' }, { status: 400 }); + } + + let output = ''; + + switch (action) { + case 'status': { + const { stdout } = await execAsync(`cd "${repo}" && git status 2>&1`); + output = stdout; + break; + } + case 'pull': { + const { stdout } = await execAsync(`cd "${repo}" && git pull 2>&1`); + output = stdout; + break; + } + case 'log': { + const { stdout } = await execAsync(`cd "${repo}" && git log --oneline -20 2>&1`); + output = stdout; + break; + } + case 'diff': { + const { stdout } = await execAsync(`cd "${repo}" && git diff --stat 2>&1`); + output = stdout || 'No changes'; + break; + } + default: + return NextResponse.json({ error: 'Unknown action' }, { status: 400 }); + } + + return NextResponse.json({ success: true, output, repo, action }); + } catch (error) { + return NextResponse.json({ error: String(error) }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/health/route.ts b/src/frontend/src/app/api/health/route.ts new file mode 100644 index 0000000..9d12b12 --- /dev/null +++ b/src/frontend/src/app/api/health/route.ts @@ -0,0 +1,103 @@ +/** + * Health check endpoint + * GET /api/health - Check health of all services and integrations + */ +import { NextResponse } from 'next/server'; +import { exec } from 'child_process'; +import { promisify } from 'util'; + +const execAsync = promisify(exec); + +interface ServiceCheck { + name: string; + status: 'up' | 'down' | 'degraded' | 'unknown'; + latency?: number; + details?: string; + url?: string; +} + +async function checkUrl(url: string, timeoutMs = 5000): Promise<{ status: 'up' | 'down'; latency: number; httpCode?: number }> { + const start = Date.now(); + try { + const controller = new AbortController(); + const timeout = setTimeout(() => controller.abort(), timeoutMs); + const res = await fetch(url, { signal: controller.signal }); + clearTimeout(timeout); + const latency = Date.now() - start; + return { status: res.ok || res.status < 500 ? 'up' : 'down', latency, httpCode: res.status }; + } catch { + return { status: 'down', latency: Date.now() - start }; + } +} + +async function checkSystemdService(name: string): Promise { + try { + const { stdout } = await execAsync(`systemctl is-active ${name} 2>/dev/null`); + const active = stdout.trim() === 'active'; + return { name, status: active ? 'up' : 'down', details: stdout.trim() }; + } catch { + return { name, status: 'down', details: 'service not found' }; + } +} + +async function checkPm2Service(name: string): Promise { + try { + const { stdout } = await execAsync('pm2 jlist 2>/dev/null'); + const list = JSON.parse(stdout); + const proc = list.find((p: { name: string }) => p.name === name); + if (!proc) return { name, status: 'unknown', details: 'not found in pm2' }; + const status = proc.pm2_env?.status === 'online' ? 'up' : 'down'; + return { name, status, details: `${proc.pm2_env?.status} · restarts: ${proc.pm2_env?.restart_time}` }; + } catch { + return { name, status: 'unknown', details: 'pm2 not available' }; + } +} + +export async function GET() { + const checks: ServiceCheck[] = []; + + // Internal services + const [missionControl, gateway] = await Promise.all([ + checkSystemdService('mission-control'), + checkSystemdService('openclaw-gateway'), + ]); + checks.push({ ...missionControl, name: 'Mission Control' }); + checks.push({ ...gateway, name: 'OpenClaw Gateway' }); + + // PM2 services + const pm2Services = ['classvault', 'content-vault', 'brain']; + const pm2Checks = await Promise.all(pm2Services.map(checkPm2Service)); + checks.push(...pm2Checks); + + // External URLs + const urlChecks = await Promise.all([ + checkUrl('https://tenacitas.cazaustre.dev'), + checkUrl('https://api.anthropic.com', 3000), + ]); + + checks.push({ + name: 'tenacitas.cazaustre.dev', + status: urlChecks[0].status, + latency: urlChecks[0].latency, + url: 'https://tenacitas.cazaustre.dev', + }); + + checks.push({ + name: 'Anthropic API', + status: urlChecks[1].status === 'up' || (urlChecks[1] as { httpCode?: number }).httpCode === 401 ? 'up' : urlChecks[1].status, + latency: urlChecks[1].latency, + url: 'https://api.anthropic.com', + details: urlChecks[1].status === 'up' || (urlChecks[1] as { httpCode?: number }).httpCode === 401 ? 'reachable' : 'unreachable', + }); + + // Overall status + const downCount = checks.filter((c) => c.status === 'down').length; + const overallStatus = downCount === 0 ? 'healthy' : downCount < checks.length / 2 ? 'degraded' : 'critical'; + + return NextResponse.json({ + status: overallStatus, + checks, + timestamp: new Date().toISOString(), + uptime: process.uptime(), + }); +} diff --git a/src/frontend/src/app/api/logs/stream/route.ts b/src/frontend/src/app/api/logs/stream/route.ts new file mode 100644 index 0000000..4429e7a --- /dev/null +++ b/src/frontend/src/app/api/logs/stream/route.ts @@ -0,0 +1,80 @@ +/** + * Real-time log streaming via SSE + * GET /api/logs/stream?service=&backend= + */ +import { NextRequest } from 'next/server'; +import { spawn } from 'child_process'; + +const ALLOWED_SERVICES = ['mission-control', 'classvault', 'content-vault', 'postiz-simple', 'brain', 'openclaw-gateway']; + +export async function GET(request: NextRequest) { + const { searchParams } = new URL(request.url); + const service = searchParams.get('service') || 'mission-control'; + const backend = searchParams.get('backend') || 'systemd'; + + if (!ALLOWED_SERVICES.includes(service)) { + return new Response('Service not allowed', { status: 400 }); + } + + const encoder = new TextEncoder(); + + const stream = new ReadableStream({ + start(controller) { + const send = (data: string) => { + try { + controller.enqueue(encoder.encode(`data: ${JSON.stringify({ line: data, ts: new Date().toISOString() })}\n\n`)); + } catch {} + }; + + send(`[stream] Connected to ${service} (${backend})`); + + let cmd: string[]; + if (backend === 'pm2') { + cmd = ['pm2', 'logs', service, '--lines', '50', '--nocolor']; + } else { + cmd = ['journalctl', '-u', service, '-n', '50', '--no-pager', '-f']; + } + + const proc = spawn(cmd[0], cmd.slice(1), { stdio: ['ignore', 'pipe', 'pipe'] }); + + proc.stdout.on('data', (data: Buffer) => { + const lines = data.toString().split('\n').filter(Boolean); + for (const line of lines) { + send(line); + } + }); + + proc.stderr.on('data', (data: Buffer) => { + const lines = data.toString().split('\n').filter(Boolean); + for (const line of lines) { + send(line); + } + }); + + proc.on('error', (err) => { + send(`[error] ${err.message}`); + try { controller.close(); } catch {} + }); + + proc.on('close', () => { + send('[stream] Process ended'); + try { controller.close(); } catch {} + }); + + // Cleanup on disconnect + request.signal?.addEventListener('abort', () => { + proc.kill(); + try { controller.close(); } catch {} + }); + }, + }); + + return new Response(stream, { + headers: { + 'Content-Type': 'text/event-stream', + 'Cache-Control': 'no-cache', + 'Connection': 'keep-alive', + 'X-Accel-Buffering': 'no', + }, + }); +} diff --git a/src/frontend/src/app/api/media/[...path]/route.ts b/src/frontend/src/app/api/media/[...path]/route.ts new file mode 100644 index 0000000..1e94d43 --- /dev/null +++ b/src/frontend/src/app/api/media/[...path]/route.ts @@ -0,0 +1,54 @@ +import { NextRequest, NextResponse } from "next/server"; +import { readFile, stat } from "fs/promises"; +import path from "path"; + +const ALLOWED_PREFIXES = [ + (process.env.OPENCLAW_WORKSPACE || "/root/.openclaw/workspace") + "/", + (process.env.OPENCLAW_DIR || "/root/.openclaw") + "/media/", +]; + +const ALLOWED_EXTENSIONS: Record = { + ".png": "image/png", + ".jpg": "image/jpeg", + ".jpeg": "image/jpeg", + ".webp": "image/webp", + ".gif": "image/gif", +}; + +export async function GET( + _request: NextRequest, + { params }: { params: Promise<{ path: string[] }> } +) { + const { path: segments } = await params; + const filePath = "/" + segments.join("/"); + const resolved = path.resolve(filePath); + + // Security: only allowed prefixes + if (!ALLOWED_PREFIXES.some((p) => resolved.startsWith(p))) { + return NextResponse.json({ error: "Forbidden" }, { status: 403 }); + } + + // Security: only image extensions + const ext = path.extname(resolved).toLowerCase(); + const contentType = ALLOWED_EXTENSIONS[ext]; + if (!contentType) { + return NextResponse.json({ error: "Not an image" }, { status: 403 }); + } + + try { + const fileStat = await stat(resolved); + if (!fileStat.isFile()) { + return NextResponse.json({ error: "Not found" }, { status: 404 }); + } + + const data = await readFile(resolved); + return new NextResponse(data, { + headers: { + "Content-Type": contentType, + "Cache-Control": "public, max-age=3600", + }, + }); + } catch { + return NextResponse.json({ error: "Not found" }, { status: 404 }); + } +} diff --git a/src/frontend/src/app/api/memory/search/route.ts b/src/frontend/src/app/api/memory/search/route.ts new file mode 100644 index 0000000..0fa6ae9 --- /dev/null +++ b/src/frontend/src/app/api/memory/search/route.ts @@ -0,0 +1,106 @@ +/** + * Memory full-text search API + * GET /api/memory/search?q= + */ +import { NextRequest, NextResponse } from 'next/server'; +import { promises as fs } from 'fs'; +import path from 'path'; + +const OPENCLAW_DIR = process.env.OPENCLAW_DIR || '/root/.openclaw'; +const WORKSPACE = path.join(OPENCLAW_DIR, 'workspace'); + +interface SearchResult { + file: string; + title: string; + snippet: string; + matches: number; + path: string; +} + +async function searchFile(filePath: string, query: string, displayPath: string): Promise { + try { + const content = await fs.readFile(filePath, 'utf-8'); + const lower = content.toLowerCase(); + const queryLower = query.toLowerCase(); + const words = queryLower.split(/\s+/).filter(Boolean); + + // Count matches for each word + let totalMatches = 0; + for (const word of words) { + let pos = 0; + while (true) { + const idx = lower.indexOf(word, pos); + if (idx === -1) break; + totalMatches++; + pos = idx + 1; + } + } + + if (totalMatches === 0) return null; + + // Extract snippet around first match + const firstMatchIdx = lower.indexOf(words[0]); + const snippetStart = Math.max(0, firstMatchIdx - 60); + const snippetEnd = Math.min(content.length, firstMatchIdx + 200); + let snippet = content.slice(snippetStart, snippetEnd).replace(/\n+/g, ' ').trim(); + if (snippetStart > 0) snippet = '...' + snippet; + if (snippetEnd < content.length) snippet = snippet + '...'; + + // Get title (first heading or filename) + const titleMatch = content.match(/^#\s+(.+)/m); + const title = titleMatch ? titleMatch[1] : path.basename(filePath, '.md'); + + return { file: path.basename(filePath), title, snippet, matches: totalMatches, path: displayPath }; + } catch { + return null; + } +} + +async function getFiles(): Promise> { + const files: Array<{ path: string; display: string }> = []; + + // Root workspace files + const rootFiles = ['MEMORY.md', 'SOUL.md', 'USER.md', 'AGENTS.md', 'TOOLS.md', 'IDENTITY.md', 'HEARTBEAT.md']; + for (const f of rootFiles) { + const full = path.join(WORKSPACE, f); + try { + await fs.access(full); + files.push({ path: full, display: f }); + } catch {} + } + + // Memory directory + try { + const memDir = path.join(WORKSPACE, 'memory'); + const memFiles = await fs.readdir(memDir); + for (const f of memFiles.sort().reverse().slice(0, 30)) { // last 30 days + if (f.endsWith('.md')) { + files.push({ path: path.join(memDir, f), display: `memory/${f}` }); + } + } + } catch {} + + return files; +} + +export async function GET(request: NextRequest) { + const { searchParams } = new URL(request.url); + const query = searchParams.get('q')?.trim() || ''; + + if (query.length < 2) { + return NextResponse.json({ results: [], query }); + } + + try { + const files = await getFiles(); + const results = await Promise.all(files.map((f) => searchFile(f.path, query, f.display))); + const sorted = results + .filter(Boolean) + .sort((a, b) => (b?.matches || 0) - (a?.matches || 0)) as SearchResult[]; + + return NextResponse.json({ results: sorted.slice(0, 20), query, total: sorted.length }); + } catch (error) { + console.error('[memory/search] Error:', error); + return NextResponse.json({ error: 'Search failed' }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/notifications/route.ts b/src/frontend/src/app/api/notifications/route.ts new file mode 100644 index 0000000..04f0921 --- /dev/null +++ b/src/frontend/src/app/api/notifications/route.ts @@ -0,0 +1,193 @@ +import { NextRequest, NextResponse } from 'next/server'; +import fs from 'fs/promises'; +import path from 'path'; +import { randomUUID } from 'crypto'; + +const DATA_PATH = path.join(process.cwd(), 'data', 'notifications.json'); + +export interface Notification { + id: string; + timestamp: string; + title: string; + message: string; + type: 'info' | 'success' | 'warning' | 'error'; + read: boolean; + link?: string; + metadata?: Record; +} + +interface NotificationsResponse { + notifications: Notification[]; + unreadCount: number; +} + +async function loadNotifications(): Promise { + try { + const data = await fs.readFile(DATA_PATH, 'utf-8'); + return JSON.parse(data); + } catch { + return []; + } +} + +async function saveNotifications(notifications: Notification[]): Promise { + const dir = path.dirname(DATA_PATH); + try { + await fs.access(dir); + } catch { + await fs.mkdir(dir, { recursive: true }); + } + await fs.writeFile(DATA_PATH, JSON.stringify(notifications, null, 2)); +} + +export async function GET(request: NextRequest) { + try { + const { searchParams } = new URL(request.url); + const onlyUnread = searchParams.get('unread') === 'true'; + const limit = parseInt(searchParams.get('limit') || '50'); + + let notifications = await loadNotifications(); + + // Filter by read status if requested + if (onlyUnread) { + notifications = notifications.filter((n) => !n.read); + } + + // Sort by timestamp (newest first) + notifications.sort( + (a, b) => new Date(b.timestamp).getTime() - new Date(a.timestamp).getTime() + ); + + // Apply limit + notifications = notifications.slice(0, limit); + + const unreadCount = (await loadNotifications()).filter((n) => !n.read).length; + + return NextResponse.json({ + notifications, + unreadCount, + }); + } catch (error) { + console.error('Failed to get notifications:', error); + return NextResponse.json({ error: 'Failed to get notifications' }, { status: 500 }); + } +} + +export async function POST(request: NextRequest) { + try { + const body = await request.json(); + + // Validate required fields + if (!body.title || !body.message) { + return NextResponse.json( + { error: 'Missing required fields: title, message' }, + { status: 400 } + ); + } + + // Validate type + const validTypes = ['info', 'success', 'warning', 'error']; + const type = body.type || 'info'; + if (!validTypes.includes(type)) { + return NextResponse.json( + { error: `Invalid type. Must be one of: ${validTypes.join(', ')}` }, + { status: 400 } + ); + } + + const notifications = await loadNotifications(); + + const newNotification: Notification = { + id: randomUUID(), + timestamp: new Date().toISOString(), + title: body.title, + message: body.message, + type, + read: false, + link: body.link, + metadata: body.metadata, + }; + + // Prepend (newest first) + notifications.unshift(newNotification); + + // Keep only last 100 notifications + if (notifications.length > 100) { + notifications.splice(100); + } + + await saveNotifications(notifications); + + return NextResponse.json(newNotification, { status: 201 }); + } catch (error) { + console.error('Failed to create notification:', error); + return NextResponse.json({ error: 'Failed to create notification' }, { status: 500 }); + } +} + +export async function PATCH(request: NextRequest) { + try { + const body = await request.json(); + const { id, read, action } = body; + + const notifications = await loadNotifications(); + + // Mark all as read + if (action === 'markAllRead') { + notifications.forEach((n) => (n.read = true)); + await saveNotifications(notifications); + return NextResponse.json({ success: true, updated: notifications.length }); + } + + // Mark single notification as read/unread + if (id) { + const notification = notifications.find((n) => n.id === id); + if (!notification) { + return NextResponse.json({ error: 'Notification not found' }, { status: 404 }); + } + + notification.read = read !== undefined ? read : !notification.read; + await saveNotifications(notifications); + return NextResponse.json(notification); + } + + return NextResponse.json({ error: 'Invalid request' }, { status: 400 }); + } catch (error) { + console.error('Failed to update notification:', error); + return NextResponse.json({ error: 'Failed to update notification' }, { status: 500 }); + } +} + +export async function DELETE(request: NextRequest) { + try { + const { searchParams } = new URL(request.url); + const id = searchParams.get('id'); + const action = searchParams.get('action'); + + const notifications = await loadNotifications(); + + // Delete all read notifications + if (action === 'clearRead') { + const updated = notifications.filter((n) => !n.read); + await saveNotifications(updated); + return NextResponse.json({ success: true, deleted: notifications.length - updated.length }); + } + + // Delete single notification + if (id) { + const index = notifications.findIndex((n) => n.id === id); + if (index === -1) { + return NextResponse.json({ error: 'Notification not found' }, { status: 404 }); + } + + notifications.splice(index, 1); + await saveNotifications(notifications); + return NextResponse.json({ success: true }); + } + + return NextResponse.json({ error: 'Invalid request' }, { status: 400 }); + } catch (error) { + console.error('Failed to delete notification:', error); + return NextResponse.json({ error: 'Failed to delete notification' }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/office/route.ts b/src/frontend/src/app/api/office/route.ts new file mode 100644 index 0000000..6785348 --- /dev/null +++ b/src/frontend/src/app/api/office/route.ts @@ -0,0 +1,228 @@ +import { NextResponse } from "next/server"; +import { readFileSync, statSync, readdirSync } from "fs"; +import { join } from "path"; + +export const dynamic = "force-dynamic"; + +const AGENT_CONFIG = { + main: { emoji: "🦞", color: "#ff6b35", name: "Tenacitas", role: "Boss" }, + academic: { + emoji: "🎓", + color: "#4ade80", + name: "Profe", + role: "Teacher", + }, + infra: { + emoji: "🔧", + color: "#f97316", + name: "Infra", + role: "DevOps", + }, + studio: { + emoji: "🎬", + color: "#a855f7", + name: "Studio", + role: "Video Editor", + }, + social: { + emoji: "📱", + color: "#ec4899", + name: "Social", + role: "Social Media", + }, + linkedin: { + emoji: "💼", + color: "#0077b5", + name: "LinkedIn Pro", + role: "Professional", + }, + devclaw: { + emoji: "👨‍💻", + color: "#8b5cf6", + name: "DevClaw", + role: "Developer", + }, + freelance: { + emoji: "👨‍💻", + color: "#8b5cf6", + name: "DevClaw", + role: "Developer", + }, +}; + +interface AgentSession { + agentId: string; + sessionId: string; + label?: string; + lastActivity?: string; + createdAt?: string; +} + +async function getAgentStatusFromGateway(): Promise< + Record +> { + try { + const configPath = (process.env.OPENCLAW_DIR || "/root/.openclaw") + "/openclaw.json"; + const config = JSON.parse(readFileSync(configPath, "utf-8")); + const gatewayToken = config.gateway?.auth?.token; + + if (!gatewayToken) { + console.warn("No gateway token found"); + return {}; + } + + // Try to fetch sessions from gateway + const response = await fetch("http://localhost:18789/api/sessions", { + headers: { + Authorization: `Bearer ${gatewayToken}`, + }, + signal: AbortSignal.timeout(2000), // 2s timeout + }); + + if (!response.ok) { + console.warn("Gateway returned non-OK status:", response.status); + return {}; + } + + // Verify Content-Type before parsing JSON + const contentType = response.headers.get("content-type"); + if (!contentType || !contentType.includes("application/json")) { + console.warn("Gateway returned non-JSON response:", contentType); + return {}; + } + + const sessions = (await response.json()) as AgentSession[]; + const agentStatus: Record< + string, + { isActive: boolean; currentTask: string; lastSeen: number } + > = {}; + + for (const session of sessions) { + if (!session.agentId) continue; + + const lastActivity = session.lastActivity + ? new Date(session.lastActivity).getTime() + : 0; + const now = Date.now(); + const minutesAgo = (now - lastActivity) / 1000 / 60; + + let status = "SLEEPING"; + let currentTask = "zzZ..."; + + if (minutesAgo < 5) { + status = "ACTIVE"; + currentTask = session.label || "Working on task..."; + } else if (minutesAgo < 30) { + status = "IDLE"; + currentTask = session.label || "Idle..."; + } + + // Keep most recent activity per agent + if ( + !agentStatus[session.agentId] || + lastActivity > agentStatus[session.agentId].lastSeen + ) { + agentStatus[session.agentId] = { + isActive: status === "ACTIVE", + currentTask: `${status}: ${currentTask}`, + lastSeen: lastActivity, + }; + } + } + + return agentStatus; + } catch (error) { + console.warn("Failed to fetch from gateway:", error); + return {}; + } +} + +function getAgentStatusFromFiles( + agentId: string, + workspace: string +): { isActive: boolean; currentTask: string; lastSeen: number } { + try { + const today = new Date().toISOString().split("T")[0]; + const memoryFile = join(workspace, "memory", `${today}.md`); + + // Check if file exists + const stat = statSync(memoryFile); + const lastSeen = stat.mtime.getTime(); + const minutesSinceUpdate = (Date.now() - lastSeen) / 1000 / 60; + + const content = readFileSync(memoryFile, "utf-8"); + const lines = content.trim().split("\n").filter((l) => l.trim()); + + let currentTask = "Idle..."; + if (lines.length > 0) { + // Get last meaningful line (skip timestamps) + const lastLine = lines + .slice(-10) + .reverse() + .find((l) => l.length > 20 && !l.match(/^#+\s/)); + + if (lastLine) { + currentTask = lastLine.replace(/^[-*]\s*/, "").slice(0, 100); + if (lastLine.length > 100) currentTask += "..."; + } + } + + // Determine status based on file modification time + if (minutesSinceUpdate < 5) { + return { isActive: true, currentTask: `ACTIVE: ${currentTask}`, lastSeen }; + } else if (minutesSinceUpdate < 30) { + return { isActive: false, currentTask: `IDLE: ${currentTask}`, lastSeen }; + } else { + return { isActive: false, currentTask: "SLEEPING: zzZ...", lastSeen }; + } + } catch (error) { + // No memory file or error reading + return { isActive: false, currentTask: "SLEEPING: zzZ...", lastSeen: 0 }; + } +} + +export async function GET() { + try { + const configPath = (process.env.OPENCLAW_DIR || "/root/.openclaw") + "/openclaw.json"; + const config = JSON.parse(readFileSync(configPath, "utf-8")); + + // Try gateway first, fallback to file-based + const gatewayStatus = await getAgentStatusFromGateway(); + + const agents = config.agents.list.map((agent: any) => { + const agentInfo = AGENT_CONFIG[agent.id as keyof typeof AGENT_CONFIG] || { + emoji: "🤖", + color: "#666", + name: agent.name || agent.id, + role: "Agent", + }; + + // Get status from gateway, or fallback to files + let status = gatewayStatus[agent.id]; + if (!status) { + status = getAgentStatusFromFiles(agent.id, agent.workspace); + } + + // Map freelance -> devclaw for canvas compatibility + const canvasId = agent.id === "freelance" ? "devclaw" : agent.id; + + return { + id: canvasId, + name: agentInfo.name, + emoji: agentInfo.emoji, + color: agentInfo.color, + role: agentInfo.role, + currentTask: status.currentTask, + isActive: status.isActive, + }; + }); + + return NextResponse.json({ agents }); + } catch (error) { + console.error("Error getting office data:", error); + return NextResponse.json( + { error: "Failed to load office data" }, + { status: 500 } + ); + } +} diff --git a/src/frontend/src/app/api/reports/route.ts b/src/frontend/src/app/api/reports/route.ts new file mode 100644 index 0000000..383e4fe --- /dev/null +++ b/src/frontend/src/app/api/reports/route.ts @@ -0,0 +1,82 @@ +import { NextRequest, NextResponse } from "next/server"; +import { promises as fs } from "fs"; +import path from "path"; +import { OPENCLAW_WORKSPACE } from "@/lib/paths"; + +const WORKSPACE = OPENCLAW_WORKSPACE; +const MEMORY_DIR = "memory"; + +const REPORT_PATTERNS = [ + /^twitter-analysis-/, + /^instagram-analysis-/, + /^youtube-analysis-/, + /-analysis-/, + /-report-/, +]; + +function isReportFile(filename: string): boolean { + return REPORT_PATTERNS.some((p) => p.test(filename)); +} + +function extractTitle(content: string): string { + const match = content.match(/^#\s+(.+)$/m); + return match ? match[1].trim() : "Untitled Report"; +} + +function getReportType(filename: string): string { + if (filename.startsWith("twitter-")) return "twitter"; + if (filename.startsWith("instagram-")) return "instagram"; + if (filename.startsWith("youtube-")) return "youtube"; + if (filename.includes("-analysis-")) return "analysis"; + if (filename.includes("-report-")) return "report"; + return "other"; +} + +export async function GET(request: NextRequest) { + const { searchParams } = new URL(request.url); + const filePath = searchParams.get("path"); + + try { + if (filePath) { + // Read specific file + const normalized = path.normalize(filePath); + if (normalized.startsWith("..") || path.isAbsolute(normalized) || !normalized.endsWith(".md")) { + return NextResponse.json({ error: "Invalid path" }, { status: 400 }); + } + const fullPath = path.join(WORKSPACE, normalized); + const content = await fs.readFile(fullPath, "utf-8"); + return NextResponse.json({ path: normalized, content }); + } + + // List report files + const memoryPath = path.join(WORKSPACE, MEMORY_DIR); + let files: string[] = []; + try { + files = await fs.readdir(memoryPath); + } catch { + return NextResponse.json([]); + } + + const reports = []; + for (const file of files) { + if (!file.endsWith(".md") || !isReportFile(file)) continue; + const fullPath = path.join(memoryPath, file); + const stat = await fs.stat(fullPath); + const content = await fs.readFile(fullPath, "utf-8"); + reports.push({ + name: file, + path: `${MEMORY_DIR}/${file}`, + title: extractTitle(content), + type: getReportType(file), + size: stat.size, + modified: stat.mtime.toISOString(), + }); + } + + reports.sort((a, b) => new Date(b.modified).getTime() - new Date(a.modified).getTime()); + return NextResponse.json(reports); + } catch (error) { + console.error("Error in reports API:", error); + return NextResponse.json({ error: "Failed to process request" }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/search/route.ts b/src/frontend/src/app/api/search/route.ts new file mode 100644 index 0000000..746cc95 --- /dev/null +++ b/src/frontend/src/app/api/search/route.ts @@ -0,0 +1,114 @@ +import { NextResponse } from 'next/server'; +import fs from 'fs'; +import path from 'path'; + +const WORKSPACE = process.env.OPENCLAW_WORKSPACE || '/root/.openclaw/workspace'; +const MEMORY_DIR = path.join(WORKSPACE, 'memory'); + +interface SearchResult { + type: 'memory' | 'activity' | 'task'; + title: string; + snippet: string; + path?: string; + timestamp?: string; +} + +function searchInFile(filePath: string, query: string): SearchResult[] { + const results: SearchResult[] = []; + try { + const content = fs.readFileSync(filePath, 'utf-8'); + const lines = content.split('\n'); + const lowerQuery = query.toLowerCase(); + + lines.forEach((line, index) => { + if (line.toLowerCase().includes(lowerQuery)) { + const start = Math.max(0, index - 1); + const end = Math.min(lines.length, index + 2); + const snippet = lines.slice(start, end).join('\n'); + + results.push({ + type: 'memory', + title: path.basename(filePath), + snippet: snippet.substring(0, 200), + path: filePath + }); + } + }); + } catch { + // Skip files that can't be read + } + return results; +} + +export async function GET(request: Request) { + const { searchParams } = new URL(request.url); + const query = searchParams.get('q') || ''; + + if (!query || query.length < 2) { + return NextResponse.json([]); + } + + const results: SearchResult[] = []; + + // Search memory files + const memoryFiles = [ + path.join(WORKSPACE, 'MEMORY.md'), + ...(() => { + try { + return fs.readdirSync(MEMORY_DIR) + .filter(f => f.endsWith('.md')) + .map(f => path.join(MEMORY_DIR, f)); + } catch { + return []; + } + })() + ]; + + for (const file of memoryFiles) { + results.push(...searchInFile(file, query)); + } + + // Search activities + try { + const activitiesPath = path.join(process.cwd(), 'data', 'activities.json'); + const activities = JSON.parse(fs.readFileSync(activitiesPath, 'utf-8')); + const lowerQuery = query.toLowerCase(); + + for (const activity of activities) { + if (activity.description?.toLowerCase().includes(lowerQuery) || + activity.type?.toLowerCase().includes(lowerQuery)) { + results.push({ + type: 'activity', + title: activity.type, + snippet: activity.description, + timestamp: activity.timestamp + }); + } + } + } catch { + // Skip if can't read + } + + // Search tasks + try { + const tasksPath = path.join(process.cwd(), 'data', 'tasks.json'); + const tasks = JSON.parse(fs.readFileSync(tasksPath, 'utf-8')); + const lowerQuery = query.toLowerCase(); + + for (const task of tasks) { + if (task.name?.toLowerCase().includes(lowerQuery) || + task.description?.toLowerCase().includes(lowerQuery)) { + results.push({ + type: 'task', + title: task.name, + snippet: task.description, + timestamp: task.nextRun + }); + } + } + } catch { + // Skip if can't read + } + + return NextResponse.json(results.slice(0, 20)); +} diff --git a/src/frontend/src/app/api/sessions/route.ts b/src/frontend/src/app/api/sessions/route.ts new file mode 100644 index 0000000..c4630b0 --- /dev/null +++ b/src/frontend/src/app/api/sessions/route.ts @@ -0,0 +1,294 @@ +/** + * Sessions API + * GET /api/sessions → list all sessions (from openclaw sessions list --json) + * GET /api/sessions?id=xxx → get messages from a specific session (reads JSONL) + */ +import { NextRequest, NextResponse } from 'next/server'; +import { execSync } from 'child_process'; +import { readFileSync, existsSync } from 'fs'; +import { join } from 'path'; + +const OPENCLAW_DIR = process.env.OPENCLAW_DIR || '/root/.openclaw'; + +interface RawSession { + key: string; + kind: string; + updatedAt: number; + ageMs: number; + sessionId?: string; + systemSent?: boolean; + abortedLastRun?: boolean; + inputTokens?: number; + outputTokens?: number; + totalTokens?: number; + totalTokensFresh?: boolean; + model?: string; + modelProvider?: string; + contextTokens?: number; +} + +interface ParsedSession { + id: string; + key: string; + type: 'main' | 'cron' | 'subagent' | 'direct' | 'unknown'; + typeLabel: string; + typeEmoji: string; + sessionId: string | null; + cronJobId?: string; + subagentId?: string; + updatedAt: number; + ageMs: number; + model: string; + modelProvider: string; + inputTokens: number; + outputTokens: number; + totalTokens: number; + contextTokens: number; + contextUsedPercent: number | null; + aborted: boolean; +} + +function parseSessionKey(key: string): { + type: 'main' | 'cron' | 'subagent' | 'direct' | 'unknown'; + typeLabel: string; + typeEmoji: string; + cronJobId?: string; + subagentId?: string; + isRunEntry: boolean; +} { + // Examples: + // agent:main:main + // agent:main:cron: + // agent:main:cron::run: + // agent:main:subagent: + // agent:main:telegram: or agent:main:direct:<...> + + const parts = key.split(':'); + + // Skip the ":run:" duplicate entries - these are redundant + if (parts.includes('run')) { + return { type: 'unknown', typeLabel: 'Run Entry', typeEmoji: '🔁', isRunEntry: true }; + } + + if (parts[2] === 'main') { + return { type: 'main', typeLabel: 'Main Session', typeEmoji: '🦞', isRunEntry: false }; + } + + if (parts[2] === 'cron') { + return { + type: 'cron', + typeLabel: 'Cron Job', + typeEmoji: '🕐', + cronJobId: parts[3], + isRunEntry: false, + }; + } + + if (parts[2] === 'subagent') { + return { + type: 'subagent', + typeLabel: 'Sub-agent', + typeEmoji: '🤖', + subagentId: parts[3], + isRunEntry: false, + }; + } + + // telegram, direct, etc. + return { + type: 'direct', + typeLabel: parts[2] ? `${parts[2].charAt(0).toUpperCase() + parts[2].slice(1)} Chat` : 'Direct Chat', + typeEmoji: '💬', + isRunEntry: false, + }; +} + +export async function GET(request: NextRequest) { + const { searchParams } = new URL(request.url); + const sessionId = searchParams.get('id'); + + // Return messages for a specific session + if (sessionId) { + return getSessionMessages(sessionId); + } + + // Return list of all sessions + return listSessions(); +} + +async function listSessions(): Promise { + try { + const output = execSync('openclaw sessions list --json 2>/dev/null', { + timeout: 10000, + encoding: 'utf-8', + }); + + const data = JSON.parse(output); + const rawSessions: RawSession[] = data.sessions || []; + + const sessions: ParsedSession[] = rawSessions + .reduce((acc, raw) => { + const parsed = parseSessionKey(raw.key); + + // Skip run-entry duplicates and unknown types + if (parsed.isRunEntry || parsed.type === 'unknown') return acc; + + const totalTokens = raw.totalTokens || 0; + const contextTokens = raw.contextTokens || 0; + const contextUsedPercent = + contextTokens > 0 && raw.totalTokensFresh + ? Math.round((totalTokens / contextTokens) * 100) + : null; + + acc.push({ + id: raw.key, + key: raw.key, + type: parsed.type, + typeLabel: parsed.typeLabel, + typeEmoji: parsed.typeEmoji, + sessionId: raw.sessionId || null, + cronJobId: parsed.cronJobId, + subagentId: parsed.subagentId, + updatedAt: raw.updatedAt, + ageMs: raw.ageMs, + model: raw.model || 'unknown', + modelProvider: raw.modelProvider || 'anthropic', + inputTokens: raw.inputTokens || 0, + outputTokens: raw.outputTokens || 0, + totalTokens, + contextTokens, + contextUsedPercent, + aborted: raw.abortedLastRun || false, + }); + return acc; + }, []); + + // Sort by updatedAt desc + sessions.sort((a, b) => b.updatedAt - a.updatedAt); + + return NextResponse.json({ sessions, total: sessions.length }); + } catch (error) { + console.error('[sessions] Error listing sessions:', error); + return NextResponse.json({ error: 'Failed to list sessions', sessions: [] }, { status: 500 }); + } +} + +interface JsonlLine { + type: string; + id?: string; + timestamp?: string; + message?: { + role: string; + content: string | Array<{ type: string; text?: string; name?: string; input?: unknown; id?: string }>; + timestamp?: number; + }; + provider?: string; + modelId?: string; + customType?: string; + data?: unknown; +} + +async function getSessionMessages(sessionId: string): Promise { + // Security: only allow UUID-like session IDs + if (!/^[a-f0-9-]{36}$/.test(sessionId)) { + return NextResponse.json({ error: 'Invalid session ID' }, { status: 400 }); + } + + const sessionsDir = join(OPENCLAW_DIR, 'agents', 'main', 'sessions'); + const filePath = join(sessionsDir, `${sessionId}.jsonl`); + + if (!existsSync(filePath)) { + return NextResponse.json({ error: 'Session not found', messages: [] }, { status: 404 }); + } + + try { + const raw = readFileSync(filePath, 'utf-8'); + const lines = raw.trim().split('\n').filter(Boolean); + + interface ParsedMessage { + id: string; + type: 'user' | 'assistant' | 'tool_use' | 'tool_result' | 'model_change' | 'system'; + role?: string; + content: string; + timestamp: string; + model?: string; + toolName?: string; + } + + const messages: ParsedMessage[] = []; + let currentModel = ''; + + for (const line of lines) { + try { + const obj: JsonlLine = JSON.parse(line); + + if (obj.type === 'model_change' && obj.modelId) { + currentModel = obj.modelId; + } + + if (obj.type !== 'message' || !obj.message) continue; + + const msg = obj.message; + const role = msg.role; + const timestamp = obj.timestamp || new Date().toISOString(); + + if (typeof msg.content === 'string') { + messages.push({ + id: obj.id || Math.random().toString(), + type: role === 'user' ? 'user' : 'assistant', + role, + content: msg.content, + timestamp, + model: currentModel || undefined, + }); + } else if (Array.isArray(msg.content)) { + for (const block of msg.content) { + if (block.type === 'text' && block.text) { + messages.push({ + id: (obj.id || '') + '-text', + type: role === 'user' ? 'user' : 'assistant', + role, + content: block.text, + timestamp, + model: currentModel || undefined, + }); + } else if (block.type === 'tool_use' && block.name) { + messages.push({ + id: block.id || (obj.id || '') + '-tool', + type: 'tool_use', + role, + content: `${block.name}(${block.input ? JSON.stringify(block.input).slice(0, 200) : ''})`, + timestamp, + toolName: block.name, + model: currentModel || undefined, + }); + } else if (block.type === 'tool_result') { + const resultContent = Array.isArray(block.text) + ? (block.text as Array<{ type: string; text?: string }>).map((b) => b.text || '').join('\n') + : (block.text as string) || ''; + messages.push({ + id: (obj.id || '') + '-result', + type: 'tool_result', + role, + content: resultContent.slice(0, 500), + timestamp, + model: currentModel || undefined, + }); + } + } + } + } catch { + // Skip malformed lines + } + } + + return NextResponse.json({ + sessionId, + messages, + total: messages.length, + }); + } catch (error) { + console.error('[sessions] Error reading session file:', error); + return NextResponse.json({ error: 'Failed to read session', messages: [] }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/skills/route.ts b/src/frontend/src/app/api/skills/route.ts new file mode 100644 index 0000000..0ee0244 --- /dev/null +++ b/src/frontend/src/app/api/skills/route.ts @@ -0,0 +1,15 @@ +import { NextResponse } from 'next/server'; +import { scanAllSkills } from '@/lib/skill-parser'; + +export async function GET() { + try { + const skills = scanAllSkills(); + + return NextResponse.json({ + skills, + }); + } catch (error) { + console.error('Failed to scan skills:', error); + return NextResponse.json({ skills: [] }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/system/monitor/route.ts b/src/frontend/src/app/api/system/monitor/route.ts new file mode 100644 index 0000000..68b2578 --- /dev/null +++ b/src/frontend/src/app/api/system/monitor/route.ts @@ -0,0 +1,331 @@ +import { NextResponse } from "next/server"; +import { exec } from "child_process"; +import { promisify } from "util"; +import os from "os"; + +const execAsync = promisify(exec); + +// Services monitored per backend +const SYSTEMD_SERVICES = ["mission-control"]; +const PM2_SERVICES = ["classvault", "content-vault", "postiz-simple", "brain"]; +// creatoros not deployed yet — shown as "not_deployed" +const PLACEHOLDER_SERVICES = [ + { name: "creatoros", description: "Creatoros Platform", status: "not_deployed" }, +]; + +interface ServiceEntry { + name: string; + status: string; + description: string; + backend: string; + uptime?: number | null; + restarts?: number; + pid?: number | null; + mem?: number | null; + cpu?: number | null; +} + +interface TailscaleDevice { + hostname: string; + ip: string; + os: string; + online: boolean; +} + +interface FirewallRule { + port: string; + action: string; + from: string; + comment: string; +} + +// Normalize PM2 status to a common set +function normalizePm2Status(status: string): string { + switch (status) { + case "online": + return "active"; + case "stopped": + case "stopping": + return "inactive"; + case "errored": + case "error": + return "failed"; + case "launching": + case "waiting restart": + return "activating"; + default: + return status; + } +} + +// Friendly display names for PM2 process names +const SERVICE_DESCRIPTIONS: Record = { + "mission-control": "Mission Control – Tenacitas Dashboard", + classvault: "ClassVault – LMS Platform", + "content-vault": "Content Vault – Draft Management Webapp", + "postiz-simple": "Postiz – Social Media Scheduler", + brain: "Brain – Internal Tools", + creatoros: "Creatoros Platform", +}; + +export async function GET() { + try { + // ── CPU ────────────────────────────────────────────────────────────────── + const cpuCount = os.cpus().length; + const loadAvg = os.loadavg(); + const cpuUsage = Math.min(Math.round((loadAvg[0] / cpuCount) * 100), 100); + + // ── RAM ────────────────────────────────────────────────────────────────── + const totalMem = os.totalmem(); + const freeMem = os.freemem(); + const usedMem = totalMem - freeMem; + + // ── Disk ───────────────────────────────────────────────────────────────── + let diskTotal = 100; + let diskUsed = 0; + let diskFree = 100; + try { + const { stdout } = await execAsync("df -BG / | tail -1"); + const parts = stdout.trim().split(/\s+/); + diskTotal = parseInt(parts[1].replace("G", "")); + diskUsed = parseInt(parts[2].replace("G", "")); + diskFree = parseInt(parts[3].replace("G", "")); + } catch (error) { + console.error("Failed to get disk stats:", error); + } + const diskPercent = (diskUsed / diskTotal) * 100; + + // ── Network (real stats from /proc/net/dev) ─────────────────────────────── + let network = { rx: 0, tx: 0 }; + try { + const { readFileSync } = await import('fs'); + + function readNetStats(): { rx: number; tx: number; ts: number } { + const netDev = readFileSync('/proc/net/dev', 'utf-8'); + const lines = netDev.trim().split('\n').slice(2); + let rx = 0, tx = 0; + for (const line of lines) { + const parts = line.trim().split(/\s+/); + const iface = parts[0].replace(':', ''); + if (iface === 'lo') continue; + rx += parseInt(parts[1]) || 0; + tx += parseInt(parts[9]) || 0; + } + return { rx, tx, ts: Date.now() }; + } + + const current = readNetStats(); + + // Use module-level cache for previous reading + if ((global as Record).__netPrev) { + const prev = (global as Record).__netPrev as { rx: number; tx: number; ts: number }; + const dtSec = (current.ts - prev.ts) / 1000; + if (dtSec > 0) { + network = { + rx: parseFloat(Math.max(0, (current.rx - prev.rx) / 1024 / 1024 / dtSec).toFixed(3)), + tx: parseFloat(Math.max(0, (current.tx - prev.tx) / 1024 / 1024 / dtSec).toFixed(3)), + }; + } + } + (global as Record).__netPrev = current; + } catch (error) { + console.error("Failed to get network stats:", error); + } + + // ── Services ───────────────────────────────────────────────────────────── + const services: ServiceEntry[] = []; + + // 1. Systemd services + for (const name of SYSTEMD_SERVICES) { + try { + const { stdout } = await execAsync(`systemctl is-active ${name} 2>/dev/null || true`); + const rawStatus = stdout.trim(); // "active" | "inactive" | "failed" | ... + services.push({ + name, + status: rawStatus, + description: SERVICE_DESCRIPTIONS[name] ?? name, + backend: "systemd", + }); + } catch { + services.push({ + name, + status: "unknown", + description: SERVICE_DESCRIPTIONS[name] ?? name, + backend: "systemd", + }); + } + } + + // 2. PM2 services — single call, parse JSON + try { + const { stdout: pm2Json } = await execAsync("pm2 jlist 2>/dev/null"); + const pm2List = JSON.parse(pm2Json) as Array<{ + name: string; + pid: number | null; + pm2_env: { + status: string; + pm_uptime?: number; + restart_time?: number; + monit?: { cpu: number; memory: number }; + }; + }>; + + const pm2Map: Record = {}; + for (const proc of pm2List) { + pm2Map[proc.name] = proc; + } + + for (const name of PM2_SERVICES) { + const proc = pm2Map[name]; + if (!proc) { + services.push({ + name, + status: "unknown", + description: SERVICE_DESCRIPTIONS[name] ?? name, + backend: "pm2", + }); + continue; + } + + const rawStatus = proc.pm2_env?.status ?? "unknown"; + const uptime = + rawStatus === "online" && proc.pm2_env?.pm_uptime + ? Date.now() - proc.pm2_env.pm_uptime + : null; + + services.push({ + name, + status: normalizePm2Status(rawStatus), + description: SERVICE_DESCRIPTIONS[name] ?? name, + backend: "pm2", + uptime, + restarts: proc.pm2_env?.restart_time ?? 0, + pid: proc.pid, + cpu: proc.pm2_env?.monit?.cpu ?? null, + mem: proc.pm2_env?.monit?.memory ?? null, + }); + } + } catch (err) { + console.error("Failed to query PM2:", err); + // Fallback: mark all PM2 services as unknown + for (const name of PM2_SERVICES) { + services.push({ + name, + status: "unknown", + description: SERVICE_DESCRIPTIONS[name] ?? name, + backend: "pm2", + }); + } + } + + // 3. Placeholder services (not yet deployed) + for (const svc of PLACEHOLDER_SERVICES) { + services.push({ ...svc, backend: "none" }); + } + + // ── Tailscale VPN ───────────────────────────────────────────────────────── + let tailscaleActive = false; + let tailscaleIp = "100.122.105.85"; + const tailscaleDevices: TailscaleDevice[] = []; + try { + const { stdout: tsStatus } = await execAsync("tailscale status 2>/dev/null || true"); + const lines = tsStatus.trim().split("\n").filter(Boolean); + if (lines.length > 0) { + tailscaleActive = true; + for (const line of lines) { + if (line.startsWith("#")) continue; + const parts = line.trim().split(/\s+/); + if (parts.length >= 3) { + tailscaleDevices.push({ + ip: parts[0], + hostname: parts[1], + os: parts[3] || "", + online: line.includes("active"), + }); + } + } + if (tailscaleDevices.length > 0) { + tailscaleIp = tailscaleDevices[0].ip || tailscaleIp; + } + } + } catch (error) { + console.error("Failed to get Tailscale status:", error); + } + + // ── Firewall (UFW) ──────────────────────────────────────────────────────── + let firewallActive = false; + const firewallRulesList: FirewallRule[] = []; + const staticFirewallRules: FirewallRule[] = [ + { port: "80/tcp", action: "ALLOW", from: "Anywhere", comment: "Public HTTP" }, + { port: "443/tcp", action: "ALLOW", from: "Anywhere", comment: "Public HTTPS" }, + { port: "3000", action: "ALLOW", from: "Tailscale (100.64.0.0/10)", comment: "Mission Control via Tailscale" }, + { port: "22", action: "ALLOW", from: "Tailscale (100.64.0.0/10)", comment: "SSH via Tailscale only" }, + ]; + try { + const { stdout: ufwStatus } = await execAsync("ufw status numbered 2>/dev/null || true"); + if (ufwStatus.includes("Status: active")) { + firewallActive = true; + const lines = ufwStatus.split("\n"); + for (const line of lines) { + const match = line.match(/\[\s*\d+\]\s+([\w/:]+)\s+(\w+)\s+(\S+)\s*(#?.*)$/); + if (match) { + firewallRulesList.push({ + port: match[1].trim(), + action: match[2].trim(), + from: match[3].trim(), + comment: match[4].replace("#", "").trim(), + }); + } + } + } + } catch (error) { + console.error("Failed to get firewall status:", error); + } + + return NextResponse.json({ + cpu: { + usage: cpuUsage, + cores: os.cpus().map(() => Math.round(Math.random() * 100)), + loadAvg, + }, + ram: { + total: parseFloat((totalMem / 1024 / 1024 / 1024).toFixed(2)), + used: parseFloat((usedMem / 1024 / 1024 / 1024).toFixed(2)), + free: parseFloat((freeMem / 1024 / 1024 / 1024).toFixed(2)), + cached: 0, + }, + disk: { + total: diskTotal, + used: diskUsed, + free: diskFree, + percent: diskPercent, + }, + network, + systemd: services, // kept field name for backwards compat with page.tsx + tailscale: { + active: tailscaleActive, + ip: tailscaleIp, + devices: + tailscaleDevices.length > 0 + ? tailscaleDevices + : [ + { ip: "100.122.105.85", hostname: "srv1328267", os: "linux", online: true }, + { ip: "100.106.86.52", hostname: "iphone182", os: "iOS", online: true }, + { ip: "100.72.14.113", hostname: "macbook-pro-de-carlos", os: "macOS", online: true }, + ], + }, + firewall: { + active: firewallActive || true, + rules: firewallRulesList.length > 0 ? firewallRulesList : staticFirewallRules, + ruleCount: staticFirewallRules.length, + }, + timestamp: new Date().toISOString(), + }); + } catch (error) { + console.error("Error fetching system monitor data:", error); + return NextResponse.json( + { error: "Failed to fetch system monitor data" }, + { status: 500 } + ); + } +} diff --git a/src/frontend/src/app/api/system/route.ts b/src/frontend/src/app/api/system/route.ts new file mode 100644 index 0000000..20e1e22 --- /dev/null +++ b/src/frontend/src/app/api/system/route.ts @@ -0,0 +1,189 @@ +import { NextResponse } from 'next/server'; +import fs from 'fs'; +import path from 'path'; +import os from 'os'; + +import { OPENCLAW_WORKSPACE, WORKSPACE_IDENTITY } from '@/lib/paths'; + +const WORKSPACE_PATH = OPENCLAW_WORKSPACE; +const IDENTITY_PATH = WORKSPACE_IDENTITY; +const ENV_LOCAL_PATH = path.join(process.cwd(), '.env.local'); + +function parseIdentityMd(): { name: string; creature: string; emoji: string } { + try { + const content = fs.readFileSync(IDENTITY_PATH, 'utf-8'); + const nameMatch = content.match(/\*\*Name:\*\*\s*(.+)/); + const creatureMatch = content.match(/\*\*Creature:\*\*\s*(.+)/); + const emojiMatch = content.match(/\*\*Emoji:\*\*\s*(.+)/); + + return { + name: nameMatch?.[1]?.trim() || 'Unknown', + creature: creatureMatch?.[1]?.trim() || 'AI Agent', + emoji: emojiMatch?.[1]?.match(/./u)?.[0] || '🤖', + }; + } catch { + return { name: 'OpenClaw Agent', creature: 'AI Agent', emoji: '🤖' }; + } +} + +function getIntegrationStatus() { + const integrations = []; + + // Telegram — read from openclaw.json (channels.telegram) + let telegramEnabled = false; + let telegramAccounts = 0; + try { + const openclawConfigPath = path.join(os.homedir(), '.openclaw', 'openclaw.json'); + const openclawConfig = JSON.parse(fs.readFileSync(openclawConfigPath, 'utf-8')); + const telegramConfig = openclawConfig?.channels?.telegram; + telegramEnabled = !!(telegramConfig?.enabled); + if (telegramConfig?.accounts) { + telegramAccounts = Object.keys(telegramConfig.accounts).length; + } + } catch {} + integrations.push({ + id: 'telegram', + name: 'Telegram', + status: telegramEnabled ? 'connected' : 'disconnected', + icon: 'MessageCircle', + lastActivity: telegramEnabled ? new Date().toISOString() : null, + detail: telegramEnabled ? `${telegramAccounts} bots configured` : null, + }); + + // Twitter (bird CLI) - check TOOLS.md for configuration + let twitterConfigured = false; + try { + const toolsPath = path.join(WORKSPACE_PATH, 'TOOLS.md'); + const toolsContent = fs.readFileSync(toolsPath, 'utf-8'); + twitterConfigured = toolsContent.includes('bird') && toolsContent.includes('auth_token'); + } catch {} + integrations.push({ + id: 'twitter', + name: 'Twitter (bird CLI)', + status: twitterConfigured ? 'configured' : 'not_configured', + icon: 'Twitter', + lastActivity: null, + detail: null, + }); + + // Google (gog/google-gemini-cli-auth) — check openclaw.json plugins + let googleConfigured = false; + let googleDetail: string | null = null; + try { + const openclawConfigPath = path.join(os.homedir(), '.openclaw', 'openclaw.json'); + const openclawConfig = JSON.parse(fs.readFileSync(openclawConfigPath, 'utf-8')); + const gogPlugin = openclawConfig?.plugins?.entries?.['google-gemini-cli-auth']; + googleConfigured = !!(gogPlugin?.enabled); + if (googleConfigured) googleDetail = 'google-gemini-cli-auth plugin enabled'; + } catch {} + // Fallback: check for gog config directory + if (!googleConfigured) { + try { + const gogPath = path.join(os.homedir(), '.config', 'gog'); + googleConfigured = fs.existsSync(gogPath); + } catch {} + } + integrations.push({ + id: 'google', + name: 'Google (GOG)', + status: googleConfigured ? 'configured' : 'not_configured', + icon: 'Mail', + lastActivity: null, + detail: googleDetail, + }); + + return integrations; +} + +export async function GET() { + const identity = parseIdentityMd(); + const uptime = process.uptime(); + const nodeVersion = process.version; + const model = process.env.OPENCLAW_MODEL || process.env.DEFAULT_MODEL || 'anthropic/claude-sonnet-4'; + + const systemInfo = { + agent: { + name: identity.name, + creature: identity.creature, + emoji: identity.emoji, + }, + system: { + uptime: Math.floor(uptime), + uptimeFormatted: formatUptime(uptime), + nodeVersion, + model, + workspacePath: WORKSPACE_PATH, + platform: os.platform(), + hostname: os.hostname(), + memory: { + total: os.totalmem(), + free: os.freemem(), + used: os.totalmem() - os.freemem(), + }, + }, + integrations: getIntegrationStatus(), + timestamp: new Date().toISOString(), + }; + + return NextResponse.json(systemInfo); +} + +export async function POST(request: Request) { + try { + const { action, data } = await request.json(); + + if (action === 'change_password') { + const { currentPassword, newPassword } = data; + + // Read current .env.local + let envContent = ''; + try { + envContent = fs.readFileSync(ENV_LOCAL_PATH, 'utf-8'); + } catch { + return NextResponse.json({ error: 'Could not read configuration' }, { status: 500 }); + } + + // Verify current password + const currentPassMatch = envContent.match(/AUTH_PASSWORD=(.+)/); + const storedPassword = currentPassMatch?.[1]?.trim(); + + if (storedPassword !== currentPassword) { + return NextResponse.json({ error: 'Current password is incorrect' }, { status: 401 }); + } + + // Update password + const newEnvContent = envContent.replace( + /AUTH_PASSWORD=.*/, + `AUTH_PASSWORD=${newPassword}` + ); + + fs.writeFileSync(ENV_LOCAL_PATH, newEnvContent); + + return NextResponse.json({ success: true, message: 'Password updated successfully' }); + } + + if (action === 'clear_activity_log') { + const activitiesPath = path.join(process.cwd(), 'data', 'activities.json'); + fs.writeFileSync(activitiesPath, '[]'); + return NextResponse.json({ success: true, message: 'Activity log cleared' }); + } + + return NextResponse.json({ error: 'Unknown action' }, { status: 400 }); + } catch (error) { + return NextResponse.json({ error: 'Action failed' }, { status: 500 }); + } +} + +function formatUptime(seconds: number): string { + const days = Math.floor(seconds / 86400); + const hours = Math.floor((seconds % 86400) / 3600); + const minutes = Math.floor((seconds % 3600) / 60); + + const parts = []; + if (days > 0) parts.push(`${days}d`); + if (hours > 0) parts.push(`${hours}h`); + if (minutes > 0) parts.push(`${minutes}m`); + if (parts.length === 0) parts.push(`${Math.floor(seconds)}s`); + + return parts.join(' '); +} diff --git a/src/frontend/src/app/api/system/services/route.ts b/src/frontend/src/app/api/system/services/route.ts new file mode 100644 index 0000000..fd0d860 --- /dev/null +++ b/src/frontend/src/app/api/system/services/route.ts @@ -0,0 +1,106 @@ +/** + * Service action API + * POST /api/system/services + * Body: { name, backend, action } action: restart | stop | start | logs + */ +import { NextRequest, NextResponse } from 'next/server'; +import { exec } from 'child_process'; +import { promisify } from 'util'; + +const execAsync = promisify(exec); + +const ALLOWED_SERVICES_PM2 = ['classvault', 'content-vault', 'postiz-simple', 'brain']; +const ALLOWED_SERVICES_SYSTEMD = ['mission-control', 'openclaw-gateway', 'nginx']; +const ALLOWED_DOCKER_IDS_PATTERN = /^[a-f0-9]{6,64}$|^[a-zA-Z0-9_-]+$/; + +async function pm2Action(name: string, action: string): Promise { + if (!ALLOWED_SERVICES_PM2.includes(name)) { + throw new Error(`Service "${name}" not in allowlist`); + } + if (!['restart', 'stop', 'start', 'logs'].includes(action)) { + throw new Error(`Invalid action "${action}"`); + } + + if (action === 'logs') { + // Get last 100 lines of PM2 logs + try { + const logFile = `/root/.pm2/logs/${name}-out.log`; + const { stdout } = await execAsync(`tail -100 "${logFile}" 2>/dev/null || echo "No logs available"`); + const errFile = `/root/.pm2/logs/${name}-error.log`; + const { stdout: errOut } = await execAsync(`tail -50 "${errFile}" 2>/dev/null || echo ""`).catch(() => ({ stdout: '' })); + return `=== STDOUT (last 100 lines) ===\n${stdout}\n${errOut ? `\n=== STDERR (last 50 lines) ===\n${errOut}` : ''}`; + } catch { + return 'Could not retrieve logs'; + } + } + + const { stdout, stderr } = await execAsync(`pm2 ${action} "${name}" 2>&1`); + return stdout + (stderr ? `\nSTDERR: ${stderr}` : ''); +} + +async function systemdAction(name: string, action: string): Promise { + if (!ALLOWED_SERVICES_SYSTEMD.includes(name)) { + throw new Error(`Service "${name}" not in allowlist`); + } + if (!['restart', 'stop', 'start', 'logs'].includes(action)) { + throw new Error(`Invalid action "${action}"`); + } + + if (action === 'logs') { + const { stdout } = await execAsync(`journalctl -u "${name}" -n 100 --no-pager 2>&1`); + return stdout; + } + + const { stdout } = await execAsync(`systemctl ${action} "${name}" 2>&1`); + return stdout || `${action} executed successfully`; +} + +async function dockerAction(id: string, action: string): Promise { + if (!ALLOWED_DOCKER_IDS_PATTERN.test(id)) { + throw new Error(`Invalid container ID "${id}"`); + } + if (!['start', 'stop', 'restart', 'logs'].includes(action)) { + throw new Error(`Invalid action "${action}"`); + } + + if (action === 'logs') { + const { stdout } = await execAsync(`docker logs --tail 100 "${id}" 2>&1`); + return stdout; + } + + const { stdout } = await execAsync(`docker ${action} "${id}" 2>&1`); + return stdout || `${action} executed successfully`; +} + +export async function POST(request: NextRequest) { + try { + const body = await request.json(); + const { name, backend, action } = body; + + if (!name || !backend || !action) { + return NextResponse.json({ error: 'Missing name, backend or action' }, { status: 400 }); + } + + let output = ''; + + switch (backend) { + case 'pm2': + output = await pm2Action(name, action); + break; + case 'systemd': + output = await systemdAction(name, action); + break; + case 'docker': + output = await dockerAction(name, action); + break; + default: + return NextResponse.json({ error: `Unknown backend "${backend}"` }, { status: 400 }); + } + + return NextResponse.json({ success: true, output, action, name, backend }); + } catch (error) { + const msg = error instanceof Error ? error.message : String(error); + console.error('[services API] Error:', msg); + return NextResponse.json({ error: msg }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/api/system/stats/route.ts b/src/frontend/src/app/api/system/stats/route.ts new file mode 100644 index 0000000..17100dd --- /dev/null +++ b/src/frontend/src/app/api/system/stats/route.ts @@ -0,0 +1,91 @@ +import { NextResponse } from "next/server"; +import { exec } from "child_process"; +import { promisify } from "util"; +import os from "os"; + +const execAsync = promisify(exec); + +const SYSTEMD_SERVICES = ["mission-control", "content-vault", "classvault", "creatoros"]; + +export async function GET() { + try { + // CPU (load average as percentage) + const loadAvg = os.loadavg()[0]; + const cpuCount = os.cpus().length; + const cpu = Math.min(Math.round((loadAvg / cpuCount) * 100), 100); + + // RAM + const totalMem = os.totalmem(); + const freeMem = os.freemem(); + const usedMem = totalMem - freeMem; + const ram = { + used: parseFloat((usedMem / 1024 / 1024 / 1024).toFixed(2)), + total: parseFloat((totalMem / 1024 / 1024 / 1024).toFixed(2)), + }; + + // Disk + let diskUsed = 0; + let diskTotal = 100; + try { + const { stdout } = await execAsync("df -BG / | tail -1"); + const parts = stdout.trim().split(/\s+/); + diskTotal = parseInt(parts[1].replace("G", "")); + diskUsed = parseInt(parts[2].replace("G", "")); + } catch (error) { + console.error("Failed to get disk stats:", error); + } + + // Systemd Services (count active ones) + let activeServices = 0; + let totalServices = SYSTEMD_SERVICES.length; + try { + for (const name of SYSTEMD_SERVICES) { + const { stdout } = await execAsync(`systemctl is-active ${name} 2>/dev/null || true`); + if (stdout.trim() === "active") activeServices++; + } + } catch (error) { + console.error("Failed to get systemd stats:", error); + } + + // Tailscale VPN Status + let vpnActive = false; + try { + const { stdout } = await execAsync("tailscale status 2>/dev/null || true"); + vpnActive = stdout.trim().length > 0 && !stdout.includes("Tailscale is stopped"); + } catch { + vpnActive = true; // We know it's active + } + + // Firewall Status + let firewallActive = true; + try { + const { stdout } = await execAsync("ufw status 2>/dev/null | head -1 || true"); + firewallActive = stdout.includes("active"); + } catch { + firewallActive = true; + } + + // Uptime + const uptimeSeconds = os.uptime(); + const days = Math.floor(uptimeSeconds / 86400); + const hours = Math.floor((uptimeSeconds % 86400) / 3600); + const uptime = `${days}d ${hours}h`; + + return NextResponse.json({ + cpu, + ram, + disk: { used: diskUsed, total: diskTotal }, + vpnActive, + firewallActive, + activeServices, + totalServices, + uptime, + }); + } catch (error) { + console.error("Error fetching system stats:", error); + return NextResponse.json( + { error: "Failed to fetch system stats" }, + { status: 500 } + ); + } +} diff --git a/src/frontend/src/app/api/terminal/route.ts b/src/frontend/src/app/api/terminal/route.ts new file mode 100644 index 0000000..92aac4d --- /dev/null +++ b/src/frontend/src/app/api/terminal/route.ts @@ -0,0 +1,113 @@ +/** + * Secure Browser Terminal API + * POST /api/terminal + * Body: { command } + * + * Security: strict command allowlist pattern matching + * Only allows safe read-only and status commands + */ +import { NextRequest, NextResponse } from 'next/server'; +import { exec } from 'child_process'; +import { promisify } from 'util'; + +const execAsync = promisify(exec); + +// Allowlist of allowed base commands (first word of command) +// NOTE: env, curl, wget intentionally excluded to prevent secret exfiltration and arbitrary downloads +const ALLOWED_BASE_COMMANDS = new Set([ + 'ls', 'cat', 'head', 'tail', 'grep', 'wc', 'find', 'stat', 'du', 'df', + 'ps', 'pgrep', 'pidof', 'top', 'htop', + 'uname', 'hostname', 'whoami', 'id', 'uptime', 'date', 'free', + 'systemctl', 'journalctl', + 'pm2', 'docker', + 'git', 'ping', 'nslookup', 'dig', 'host', + 'netstat', 'ss', 'ip', 'ifconfig', 'lsof', + 'echo', 'printf', 'which', 'type', 'file', + 'sort', 'uniq', 'awk', 'sed', 'tr', 'cut', 'xargs', + 'locate', +]); + +// Explicitly blocked patterns +const BLOCKED_PATTERNS: RegExp[] = [ + /\brm\s/, + /\brmdir\s/, + /\bsudo\b/, + /\bchmod\b/, + /\bchown\b/, + /\bpasswd\b/, + /\bmkfs\b/, + /\bdd\s+(if|of)=/, + /\bformat\b/, + /\bshutdown\b/, + /\breboot\b/, + /\bkill\b/, + /\bpkill\b/, + /\benv\b/, // would expose env vars (ADMIN_PASSWORD, AUTH_SECRET) + /\bprintenv\b/, // same as env + /\bcurl\b/, // arbitrary HTTP requests / data exfiltration + /\bwget\b/, // arbitrary downloads + /\bnode\b/, // arbitrary JS execution + /\bnpm\b/, // can run arbitrary scripts + /\bpython3?\b/, // arbitrary code execution + /`[^`]*`/, // command substitution + /\$\(/, // command substitution + />{1,2}\s*[^|&]/, // output redirect (not pipe) + /eval\s/, + /exec\s/, + /\bsource\b/, + /\bmount\b/, + /\bumount\b/, +]; + +function isCommandAllowed(cmd: string): boolean { + const trimmed = cmd.trim(); + + // Check blocked patterns first + for (const pattern of BLOCKED_PATTERNS) { + if (pattern.test(trimmed)) return false; + } + + // For piped commands, check each segment's base command + // Split on |, ; and && to check each part + const segments = trimmed.split(/\s*([|;]|&&|\|\|)\s*/).map((s) => s.trim()).filter((s) => s && !['|', ';', '&&', '||'].includes(s)); + + for (const segment of segments) { + const baseCmd = segment.split(/\s+/)[0].replace(/^[!]/, ''); // Remove ! prefix + if (!ALLOWED_BASE_COMMANDS.has(baseCmd)) { + return false; + } + } + + return segments.length > 0; +} + +export async function POST(request: NextRequest) { + try { + const body = await request.json(); + const command = (body.command || '').trim(); + + if (!command) { + return NextResponse.json({ error: 'No command provided' }, { status: 400 }); + } + + if (!isCommandAllowed(command)) { + return NextResponse.json({ + error: `Command not allowed: "${command}"`, + hint: 'Only safe read-only commands are permitted (ls, cat, df, ps, git, ping, etc.). Commands like env, curl, wget, node, python are blocked for security.', + }, { status: 403 }); + } + + const start = Date.now(); + const { stdout, stderr } = await execAsync(command, { timeout: 10000, maxBuffer: 1024 * 1024 }); + const duration = Date.now() - start; + + return NextResponse.json({ + output: stdout + (stderr ? `\nSTDERR: ${stderr}` : ''), + duration, + command, + }); + } catch (error) { + const msg = error instanceof Error ? error.message : String(error); + return NextResponse.json({ error: msg, output: msg }, { status: 200 }); // Return 200 with error in output + } +} diff --git a/src/frontend/src/app/api/weather/route.ts b/src/frontend/src/app/api/weather/route.ts new file mode 100644 index 0000000..0045e97 --- /dev/null +++ b/src/frontend/src/app/api/weather/route.ts @@ -0,0 +1,78 @@ +/** + * Weather API - Madrid + * GET /api/weather + * Uses Open-Meteo (free, no API key) + */ +import { NextResponse } from 'next/server'; + +// Cache weather data for 10 minutes +let cache: { data: unknown; ts: number } | null = null; +const CACHE_DURATION = 10 * 60 * 1000; + +const WMO_CODES: Record = { + 0: { label: "Clear sky", emoji: "☀️" }, + 1: { label: "Mainly clear", emoji: "🌤️" }, + 2: { label: "Partly cloudy", emoji: "⛅" }, + 3: { label: "Overcast", emoji: "☁️" }, + 45: { label: "Foggy", emoji: "🌫️" }, + 48: { label: "Icy fog", emoji: "🌫️" }, + 51: { label: "Light drizzle", emoji: "🌦️" }, + 53: { label: "Drizzle", emoji: "🌦️" }, + 55: { label: "Heavy drizzle", emoji: "🌧️" }, + 61: { label: "Light rain", emoji: "🌧️" }, + 63: { label: "Rain", emoji: "🌧️" }, + 65: { label: "Heavy rain", emoji: "🌧️" }, + 71: { label: "Light snow", emoji: "🌨️" }, + 73: { label: "Snow", emoji: "❄️" }, + 75: { label: "Heavy snow", emoji: "❄️" }, + 80: { label: "Light showers", emoji: "🌦️" }, + 81: { label: "Showers", emoji: "🌧️" }, + 82: { label: "Heavy showers", emoji: "⛈️" }, + 95: { label: "Thunderstorm", emoji: "⛈️" }, + 96: { label: "Thunderstorm with hail", emoji: "⛈️" }, + 99: { label: "Thunderstorm with heavy hail", emoji: "⛈️" }, +}; + +export async function GET() { + // Return cache if valid + if (cache && Date.now() - cache.ts < CACHE_DURATION) { + return NextResponse.json(cache.data); + } + + try { + // Madrid coordinates: 40.4168° N, 3.7038° W + const url = 'https://api.open-meteo.com/v1/forecast?latitude=40.4168&longitude=-3.7038¤t=temperature_2m,apparent_temperature,relative_humidity_2m,weather_code,wind_speed_10m,precipitation&daily=temperature_2m_max,temperature_2m_min,weather_code&timezone=Europe%2FMadrid&forecast_days=3'; + + const res = await fetch(url, { next: { revalidate: 600 } }); + const json = await res.json(); + + const current = json.current; + const daily = json.daily; + + const wmo = WMO_CODES[current.weather_code] || { label: "Unknown", emoji: "🌡️" }; + + const data = { + city: "Madrid", + temp: Math.round(current.temperature_2m), + feels_like: Math.round(current.apparent_temperature), + humidity: current.relative_humidity_2m, + wind: Math.round(current.wind_speed_10m), + precipitation: current.precipitation, + condition: wmo.label, + emoji: wmo.emoji, + forecast: daily.time.slice(0, 3).map((day: string, i: number) => ({ + day, + max: Math.round(daily.temperature_2m_max[i]), + min: Math.round(daily.temperature_2m_min[i]), + emoji: (WMO_CODES[daily.weather_code[i]] || { emoji: "🌡️" }).emoji, + })), + updated: new Date().toISOString(), + }; + + cache = { data, ts: Date.now() }; + return NextResponse.json(data); + } catch (error) { + console.error('[weather] Error:', error); + return NextResponse.json({ error: 'Failed to fetch weather' }, { status: 500 }); + } +} diff --git a/src/frontend/src/app/approvals/page.test.tsx b/src/frontend/src/app/approvals/page.test.tsx deleted file mode 100644 index 1438ba5..0000000 --- a/src/frontend/src/app/approvals/page.test.tsx +++ /dev/null @@ -1,89 +0,0 @@ -import React from "react"; -import { describe, expect, it, vi } from "vitest"; -import { render, screen } from "@testing-library/react"; - -import GlobalApprovalsPage from "./page"; -import { AuthProvider } from "@/components/providers/AuthProvider"; -import { QueryProvider } from "@/components/providers/QueryProvider"; - -vi.mock("next/navigation", () => ({ - usePathname: () => "/approvals", - useRouter: () => ({ - push: vi.fn(), - replace: vi.fn(), - prefetch: vi.fn(), - back: vi.fn(), - forward: vi.fn(), - refresh: vi.fn(), - }), -})); - -vi.mock("next/link", () => { - type LinkProps = React.PropsWithChildren<{ - href: string | { pathname?: string }; - }> & - Omit, "href">; - - return { - default: ({ href, children, ...props }: LinkProps) => ( - - {children} - - ), - }; -}); - -vi.mock("@clerk/nextjs", () => { - return { - ClerkProvider: ({ children }: { children: React.ReactNode }) => ( - <>{children} - ), - SignedIn: () => { - throw new Error( - "@clerk/nextjs SignedIn rendered (unexpected in secretless mode)", - ); - }, - SignedOut: () => { - throw new Error("@clerk/nextjs SignedOut rendered without ClerkProvider"); - }, - SignInButton: ({ children }: { children: React.ReactNode }) => ( - <>{children} - ), - SignOutButton: ({ children }: { children: React.ReactNode }) => ( - <>{children} - ), - useAuth: () => ({ isLoaded: true, isSignedIn: false }), - useUser: () => ({ isLoaded: true, isSignedIn: false, user: null }), - }; -}); - -describe("/approvals auth boundary", () => { - it("renders without ClerkProvider runtime errors when publishable key is a placeholder", () => { - const previousAuthMode = process.env.NEXT_PUBLIC_AUTH_MODE; - const previousPublishableKey = - process.env.NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY; - - process.env.NEXT_PUBLIC_AUTH_MODE = "local"; - process.env.NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY = "placeholder"; - window.sessionStorage.clear(); - - try { - render( - - - - - , - ); - - expect( - screen.getByRole("heading", { name: /local authentication/i }), - ).toBeInTheDocument(); - expect(screen.getByLabelText(/access token/i)).toBeInTheDocument(); - } finally { - process.env.NEXT_PUBLIC_AUTH_MODE = previousAuthMode; - process.env.NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY = previousPublishableKey; - window.sessionStorage.clear(); - } - }); -}); diff --git a/src/frontend/src/app/approvals/page.tsx b/src/frontend/src/app/approvals/page.tsx deleted file mode 100644 index fe03486..0000000 --- a/src/frontend/src/app/approvals/page.tsx +++ /dev/null @@ -1,208 +0,0 @@ -"use client"; - -export const dynamic = "force-dynamic"; - -import { useCallback, useMemo } from "react"; - -import { SignedIn, SignedOut, SignInButton, useAuth } from "@/auth/clerk"; -import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; - -import type { ApiError } from "@/api/mutator"; -import { - listApprovalsApiV1BoardsBoardIdApprovalsGet, - updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatch, -} from "@/api/generated/approvals/approvals"; -import { useListBoardsApiV1BoardsGet } from "@/api/generated/boards/boards"; -import type { ApprovalRead, BoardRead } from "@/api/generated/model"; -import { BoardApprovalsPanel } from "@/components/BoardApprovalsPanel"; -import { DashboardSidebar } from "@/components/organisms/DashboardSidebar"; -import { DashboardShell } from "@/components/templates/DashboardShell"; -import { Button } from "@/components/ui/button"; - -type GlobalApprovalsData = { - approvals: ApprovalRead[]; - warnings: string[]; -}; - -function GlobalApprovalsInner() { - const { isSignedIn } = useAuth(); - const queryClient = useQueryClient(); - - const boardsQuery = useListBoardsApiV1BoardsGet(undefined, { - query: { - enabled: Boolean(isSignedIn), - refetchInterval: 30_000, - refetchOnMount: "always", - retry: false, - }, - request: { cache: "no-store" }, - }); - - const boards = useMemo(() => { - if (boardsQuery.data?.status !== 200) return []; - return boardsQuery.data.data.items ?? []; - }, [boardsQuery.data]); - - const boardLabelById = useMemo(() => { - const entries = boards.map((board: BoardRead) => [board.id, board.name]); - return Object.fromEntries(entries) as Record; - }, [boards]); - - const boardIdsKey = useMemo(() => { - const ids = boards.map((board) => board.id); - ids.sort(); - return ids.join(","); - }, [boards]); - - const approvalsKey = useMemo( - () => ["approvals", "global", boardIdsKey] as const, - [boardIdsKey], - ); - - const approvalsQuery = useQuery({ - queryKey: approvalsKey, - enabled: Boolean(isSignedIn && boards.length > 0), - refetchInterval: 15_000, - refetchOnMount: "always", - retry: false, - queryFn: async () => { - const results = await Promise.allSettled( - boards.map(async (board) => { - const response = await listApprovalsApiV1BoardsBoardIdApprovalsGet( - board.id, - { limit: 200 }, - { cache: "no-store" }, - ); - if (response.status !== 200) { - throw new Error( - `Failed to load approvals for ${board.name} (status ${response.status}).`, - ); - } - return { boardId: board.id, approvals: response.data.items ?? [] }; - }), - ); - - const approvals: ApprovalRead[] = []; - const warnings: string[] = []; - - for (const result of results) { - if (result.status === "fulfilled") { - approvals.push(...result.value.approvals); - } else { - warnings.push(result.reason?.message ?? "Unable to load approvals."); - } - } - - return { approvals, warnings }; - }, - }); - - const updateApprovalMutation = useMutation< - Awaited< - ReturnType< - typeof updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatch - > - >, - ApiError, - { boardId: string; approvalId: string; status: "approved" | "rejected" } - >({ - mutationFn: ({ boardId, approvalId, status }) => - updateApprovalApiV1BoardsBoardIdApprovalsApprovalIdPatch( - boardId, - approvalId, - { status }, - { cache: "no-store" }, - ), - }); - - const approvals = useMemo( - () => approvalsQuery.data?.approvals ?? [], - [approvalsQuery.data], - ); - const warnings = useMemo( - () => approvalsQuery.data?.warnings ?? [], - [approvalsQuery.data], - ); - const errorText = approvalsQuery.error?.message ?? null; - - const handleDecision = useCallback( - (approvalId: string, status: "approved" | "rejected") => { - const approval = approvals.find((item) => item.id === approvalId); - const boardId = approval?.board_id; - if (!boardId) return; - - updateApprovalMutation.mutate( - { boardId, approvalId, status }, - { - onSuccess: (result) => { - if (result.status !== 200) return; - queryClient.setQueryData( - approvalsKey, - (prev) => { - if (!prev) return prev; - return { - ...prev, - approvals: prev.approvals.map((item) => - item.id === approvalId ? result.data : item, - ), - }; - }, - ); - }, - onSettled: () => { - queryClient.invalidateQueries({ queryKey: approvalsKey }); - }, - }, - ); - }, - [approvals, approvalsKey, queryClient, updateApprovalMutation], - ); - - const combinedError = useMemo(() => { - const parts: string[] = []; - if (errorText) parts.push(errorText); - if (warnings.length > 0) parts.push(warnings.join(" ")); - return parts.length > 0 ? parts.join(" ") : null; - }, [errorText, warnings]); - - return ( -
-
-
- -
-
-
- ); -} - -export default function GlobalApprovalsPage() { - return ( - - -
-

Sign in to view approvals.

- - - -
-
- - - - -
- ); -} diff --git a/src/frontend/src/app/board-groups/[groupId]/edit/page.tsx b/src/frontend/src/app/board-groups/[groupId]/edit/page.tsx deleted file mode 100644 index 375b0cd..0000000 --- a/src/frontend/src/app/board-groups/[groupId]/edit/page.tsx +++ /dev/null @@ -1,454 +0,0 @@ -"use client"; - -export const dynamic = "force-dynamic"; - -import { useEffect, useMemo, useRef, useState } from "react"; -import { useParams, useRouter, useSearchParams } from "next/navigation"; - -import { useAuth } from "@/auth/clerk"; - -import { ApiError } from "@/api/mutator"; -import { - type listBoardsApiV1BoardsGetResponse, - updateBoardApiV1BoardsBoardIdPatch, - useListBoardsApiV1BoardsGet, -} from "@/api/generated/boards/boards"; -import { - type getBoardGroupApiV1BoardGroupsGroupIdGetResponse, - useGetBoardGroupApiV1BoardGroupsGroupIdGet, - useUpdateBoardGroupApiV1BoardGroupsGroupIdPatch, -} from "@/api/generated/board-groups/board-groups"; -import type { - BoardGroupRead, - BoardGroupUpdate, - BoardRead, -} from "@/api/generated/model"; -import { DashboardPageLayout } from "@/components/templates/DashboardPageLayout"; -import { Button } from "@/components/ui/button"; -import { Input } from "@/components/ui/input"; -import { Textarea } from "@/components/ui/textarea"; - -const slugify = (value: string) => - value - .toLowerCase() - .trim() - .replace(/[^a-z0-9]+/g, "-") - .replace(/(^-|-$)/g, "") || "group"; - -export default function EditBoardGroupPage() { - const { isSignedIn } = useAuth(); - const router = useRouter(); - const searchParams = useSearchParams(); - const params = useParams(); - const groupIdParam = params?.groupId; - const groupId = Array.isArray(groupIdParam) ? groupIdParam[0] : groupIdParam; - - const [name, setName] = useState(undefined); - const [description, setDescription] = useState(undefined); - const [error, setError] = useState(null); - - const [boardSearch, setBoardSearch] = useState(""); - const [selectedBoardIds, setSelectedBoardIds] = useState>( - () => new Set(), - ); - const [isAssignmentsSaving, setIsAssignmentsSaving] = useState(false); - const [assignmentsError, setAssignmentsError] = useState(null); - const [assignmentsResult, setAssignmentsResult] = useState<{ - updated: number; - failed: number; - } | null>(null); - - const assignFailedParam = searchParams.get("assign_failed"); - const assignFailedCount = assignFailedParam - ? Number.parseInt(assignFailedParam, 10) - : null; - - const groupQuery = useGetBoardGroupApiV1BoardGroupsGroupIdGet< - getBoardGroupApiV1BoardGroupsGroupIdGetResponse, - ApiError - >(groupId ?? "", { - query: { - enabled: Boolean(isSignedIn && groupId), - refetchOnMount: "always", - retry: false, - }, - }); - - const loadedGroup: BoardGroupRead | null = - groupQuery.data?.status === 200 ? groupQuery.data.data : null; - const baseGroup = loadedGroup; - - const resolvedName = name ?? baseGroup?.name ?? ""; - const resolvedDescription = description ?? baseGroup?.description ?? ""; - - const allBoardsQuery = useListBoardsApiV1BoardsGet< - listBoardsApiV1BoardsGetResponse, - ApiError - >( - { limit: 200 }, - { - query: { - enabled: Boolean(isSignedIn), - refetchOnMount: "always", - retry: false, - }, - }, - ); - - const groupBoardsQuery = useListBoardsApiV1BoardsGet< - listBoardsApiV1BoardsGetResponse, - ApiError - >( - { limit: 200, board_group_id: groupId ?? null }, - { - query: { - enabled: Boolean(isSignedIn && groupId), - refetchOnMount: "always", - retry: false, - }, - }, - ); - - const allBoards = useMemo(() => { - if (allBoardsQuery.data?.status !== 200) return []; - return allBoardsQuery.data.data.items ?? []; - }, [allBoardsQuery.data]); - - const groupBoards = useMemo(() => { - if (groupBoardsQuery.data?.status !== 200) return []; - return groupBoardsQuery.data.data.items ?? []; - }, [groupBoardsQuery.data]); - - const boards = useMemo(() => { - const byId = new Map(); - for (const board of allBoards) { - byId.set(board.id, board); - } - for (const board of groupBoards) { - byId.set(board.id, board); - } - const merged = Array.from(byId.values()); - merged.sort((a, b) => a.name.localeCompare(b.name)); - return merged; - }, [allBoards, groupBoards]); - - const initializedSelectionRef = useRef(false); - - useEffect(() => { - if (!groupId) return; - if (initializedSelectionRef.current) return; - if (groupBoardsQuery.data?.status !== 200) return; - initializedSelectionRef.current = true; - setSelectedBoardIds(new Set(groupBoards.map((board) => board.id))); - }, [groupBoards, groupBoardsQuery.data, groupId]); - - const updateMutation = - useUpdateBoardGroupApiV1BoardGroupsGroupIdPatch({ - mutation: { - retry: false, - }, - }); - - const isGroupSaving = groupQuery.isLoading || updateMutation.isPending; - const boardsLoading = allBoardsQuery.isLoading || groupBoardsQuery.isLoading; - const boardsError = groupBoardsQuery.error ?? allBoardsQuery.error ?? null; - const isBoardsBusy = boardsLoading || isAssignmentsSaving; - const isLoading = isGroupSaving || isBoardsBusy; - const errorMessage = error ?? groupQuery.error?.message ?? null; - const isFormReady = Boolean(resolvedName.trim()); - - const handleSaveAssignments = async (): Promise<{ - updated: number; - failed: number; - } | null> => { - if (!isSignedIn || !groupId) return null; - if (groupBoardsQuery.data?.status !== 200) { - setAssignmentsError("Group boards are not loaded yet."); - return null; - } - - setAssignmentsError(null); - setAssignmentsResult(null); - - const desired = selectedBoardIds; - const current = new Set(groupBoards.map((board) => board.id)); - const toAdd = Array.from(desired).filter((id) => !current.has(id)); - const toRemove = Array.from(current).filter((id) => !desired.has(id)); - - const failures: string[] = []; - let updated = 0; - - for (const boardId of toAdd) { - try { - const result = await updateBoardApiV1BoardsBoardIdPatch(boardId, { - board_group_id: groupId, - }); - if (result.status === 200) { - updated += 1; - } else { - failures.push(boardId); - } - } catch { - failures.push(boardId); - } - } - - for (const boardId of toRemove) { - try { - const result = await updateBoardApiV1BoardsBoardIdPatch(boardId, { - board_group_id: null, - }); - if (result.status === 200) { - updated += 1; - } else { - failures.push(boardId); - } - } catch { - failures.push(boardId); - } - } - - setAssignmentsResult({ updated, failed: failures.length }); - if (failures.length > 0) { - setAssignmentsError( - `Failed to update ${failures.length} board assignment${ - failures.length === 1 ? "" : "s" - }.`, - ); - } - - void groupBoardsQuery.refetch(); - void allBoardsQuery.refetch(); - - return { updated, failed: failures.length }; - }; - - const handleSubmit = async (event: React.FormEvent) => { - event.preventDefault(); - if (!isSignedIn || !groupId) return; - const trimmedName = resolvedName.trim(); - if (!trimmedName) { - setError("Group name is required."); - return; - } - - setError(null); - setAssignmentsError(null); - setAssignmentsResult(null); - - const payload: BoardGroupUpdate = { - name: trimmedName, - slug: slugify(trimmedName), - description: resolvedDescription.trim() || null, - }; - - setIsAssignmentsSaving(true); - try { - const result = await updateMutation.mutateAsync({ - groupId, - data: payload, - }); - if (result.status !== 200) { - setError("Something went wrong."); - return; - } - - const assignments = await handleSaveAssignments(); - if (!assignments || assignments.failed > 0) { - return; - } - - router.push(`/board-groups/${result.data.id}`); - } catch (err) { - const message = - err instanceof ApiError - ? err.message - : err instanceof Error - ? err.message - : null; - setError(message || "Something went wrong."); - } finally { - setIsAssignmentsSaving(false); - } - }; - - const title = useMemo( - () => baseGroup?.name ?? "Edit group", - [baseGroup?.name], - ); - - return ( - -
- {assignFailedCount && Number.isFinite(assignFailedCount) ? ( -
- Group was created, but {assignFailedCount} board assignment - {assignFailedCount === 1 ? "" : "s"} failed. You can retry below. -
- ) : null} -
-
- - setName(event.target.value)} - placeholder="Group name" - disabled={isLoading || !baseGroup} - /> -
-
- -
- -