# nimanyatta — vendored chat server This crate is the vendoring target for the **nimanyatta** real-time chat server currently living at `../nimanyatta` (sibling checkout). `nigig-site` and `nigig-chat` both speak to the same server: - Creating a **project group** for a construction site in `nigig-site` (`POST /api/v1/rooms/create`) creates a normal nimanyatta room. That room automatically appears in `nigig-chat` via `POST /api/v1/sync`. - A room created in `nigig-chat` is likewise visible in `nigig-site`'s *Project chat* tab — same room_id, same server. ## Current state (Phase 1) The server is **not yet copied** into this repo. `crates/apps/nigig-site` and `crates/nigig-chat` talk to the sibling checkout at ``` ../nimanyatta → http://127.0.0.1:8080 (default) ``` Override with `NIMANYATTA_BASE_URL` (e.g. staging URL) and share the same `PASETO_KEY` / `DATABASE_PATH` across both checkouts. ## Vendoring plan 1. Copy `../nimanyatta/src`, `../nimanyatta/crates/nimanyatta-protocol`, `../nimanyatta/crates/kra-etims-sdk`, and `../nigig-lite/crates/common` into this folder preserving history (`git subtree` or `git filter-repo`). 2. Add it to the workspace (`[workspace] members += "crates/nimanyatta"`). 3. Replace `nigig-site/src/nimanyatta_client.rs` typed shims with `nigig_common::{CreateRoomRequest, …}` and the shared `TestClient`. 4. Wire a `cargo xtask` that runs `cargo run -p nimanyatta --bin broadcast_server --features b_server` alongside `cargo run -p nigig-site` for local dev. Until step 1 lands, this folder is a stub so docs/links resolve.