nigig-org/nigig-lite
2026-09-27 16:25:50 +03:00
..
crates/common wip(daily-reports): preserve local site/report/worker, ocr and lite-common updates for Phase 0 freeze 2026-09-27 16:25:50 +03:00
README.md nimanyatta: Phase 8 — reconstruct nigig-common, repair load suites, close REST coverage gaps 2026-09-26 16:24:41 +00:00

nigig-lite

Shared, dependency-light crates for the nigig / nimanyatta family.

crates/common — nigig-common

The shared foundation crate consumed by the nimanyatta chat/sync server (as a path dependency from nimanyatta/Cargo.toml) and by its load-test suites:

  • ids — strongly-typed ULID identifiers (UserId, RoomId, EventId, DeviceId) that serialise in prefixed wire form (user_01H…).
  • errors — the unified AppError model: HTTP status mapping, stable machine-readable codes, and an xitca-web Service impl that renders JSON error bodies.
  • auth — REST DTOs for register/login/refresh/logout, token pairs, and the UserProfile record shape.
  • rooms — room, membership, timeline-event and message-content models plus the rooms REST DTOs.
  • roles — server/room/custom role and permission model (PermissionSet, ResolvedPermissions).
  • sync — the /sync request/response contract (filters, pagination tokens).
  • protocol — the WebSocket chat protocol (ClientToServerMsg, ServerToClientMsg, presence, receipts) mirrored from nimanyatta/crates/nimanyatta-protocol.
  • validatable — shared input validators (username/password/message body rules).

The crate is standalone (empty [workspace] table) and has its own unit tests (cargo test → 21 tests).

The WebSocket wire shapes are kept byte-compatible with nimanyatta/crates/nimanyatta-protocol — the client library — so both sides of the socket agree on field names and tagging.