# AGENTS.md — Polaris Task Force > **Sub-AGENTS.md files** (read these for domain-specific context): > > - `src/components/frontend/AGENTS.md` — Frontend component patterns, server/client split, Item primitive > - `src/collections/AGENTS.md` — Payload collection map, RBAC, hooks, relationship graph > - `src/lib/AGENTS.md` — Shared business logic, domain services, dependency graph > - `src/utils/AGENTS.md` — Access control layers, event log, utilities > - `src/bot/AGENTS.md` — Discord bot architecture, commands, services ## What this is Next.js 16 + Payload CMS 3.88.0 app for an Arma 3 unit. PostgreSQL database via `@payloadcms/db-postgres` + Drizzle. Tailwind CSS v4 (no config file — CSS-based). shadcn/ui (new-york style, `lucide` icons). Dark-themed frontend. ## Production data (read-only MCP) This app exposes its Payload collections over MCP (`@payloadcms/plugin-mcp`). The project's `.opencode/opencode.json` connects this workspace to the production instance as `polaris-task-force-prod` (`https://arma.onyxsimple.com/api/mcp`). **Prefer it for read-only reference data.** When you need to look at current production state (open tickets, a structure's contents, live market listings, a user's profile, and so on) reach for the MCP `find` / `find` tools first: it is the fastest path to live prod data and needs no local setup. - **Read-only by construction.** The key is minted by `bun run mcp:key prd` (`src/tools/cli/create-mcp-key.ts`), which enables only the `find` capability. It cannot create, update, or delete anything. - **Tool shape.** One `find` tool per collection (camel-cased, e.g. `findGameStructures`, `findMarketListings`), plus `find` for globals. Args accept a Payload `where` clause as a JSON string, plus `limit` (max 100), `sort`, `select`, `depth`, `page`. - **Not authoritative for logic.** Read the repo for business rules; the MCP is a reference snapshot. - **Not a test target, and never a reason to skip tests.** - **Writes are unchanged.** Updates go through the normal channels (local/stg DB, server actions, Payload migrations via `bun run payload migrate`), verified by tests. The live connection config is gitignored (`.opencode/`), which is fine for a single-developer setup. ## Package manager **Bun** is the primary package manager (`bun.lock`; `bunfig.toml` is empty). `package.json` declares `packageManager: pnpm@9.15.4` and several scripts internally invoke pnpm (`db`, `test`, `test:e2e`) — always invoke them via `bun run