Skip to content

Commit a6d45c4

Browse files
Cleanup: auth consistency hardening and review-item consolidation (#23)
Co-authored-by: Thiago Ramalho <thiago.nramalho@gmail.com>
1 parent b9c2872 commit a6d45c4

File tree

41 files changed

+2347
-1929
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+2347
-1929
lines changed

AGENTS.md

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
# AGENTS.md
2+
3+
Canonical agent instructions for this repository.
4+
5+
`CLAUDE.md` is intentionally a symlink to this file so different agents load the same project guidance.
6+
7+
## Start Here
8+
9+
1. Read `development-guides/ROCKETS_AI_INDEX.md` first.
10+
2. Pick only the one guide needed for the task (avoid loading all guides).
11+
3. Keep `.context/notes.md` updated with findings for other parallel agents.
12+
13+
## Scope & Precedence
14+
15+
- This root `AGENTS.md` is the default instruction set for the whole repository.
16+
- If a future subdirectory adds its own `AGENTS.md`, treat that as a scoped override for files in that subtree.
17+
- Keep broad policy here, and put package-specific rules close to package code when needed.
18+
- When instructions conflict, prefer the most specific instruction file for the file path being edited.
19+
20+
## Repository Map
21+
22+
- `packages/rockets-server`: minimal auth-provider + `/me` metadata endpoints.
23+
- `packages/rockets-server-auth`: complete auth system (token, signup, recovery, otp, oauth, admin).
24+
- `development-guides/`: implementation patterns and AI-oriented playbooks.
25+
- `.context/`: shared scratchpad for multi-agent collaboration (gitignored).
26+
27+
## Source of Truth Rules
28+
29+
- Behavior and API truth: `packages/*/src/**`.
30+
- Public API surface for auth package: `packages/rockets-server-auth/swagger/swagger.json`.
31+
- Guides and READMEs are helpful, but when docs conflict with code, prefer code.
32+
33+
## Build, Test, Lint
34+
35+
Run checks in this order after code changes:
36+
37+
1. `yarn build`
38+
2. `yarn test`
39+
3. `yarn test:e2e`
40+
4. `yarn lint`
41+
42+
CI also runs:
43+
44+
- `yarn lint:all`
45+
- `yarn test:ci`
46+
47+
## Auth Integration Invariants
48+
49+
- If app uses both modules, import order is required:
50+
1. `RocketsAuthModule`
51+
2. `RocketsModule`
52+
- `RocketsModule` consumes an injected auth provider (commonly `RocketsJwtAuthProvider` from `rockets-server-auth`).
53+
- Keep auth endpoint docs and generated swagger aligned when controllers change.
54+
55+
## Editing Guidelines
56+
57+
- Prefer minimal, scoped diffs.
58+
- Do not refactor unrelated code in the same change.
59+
- Keep naming and patterns consistent with nearby module code.
60+
- If adding/changing endpoint behavior, update relevant docs and tests in the same change.
61+
62+
## Collaboration Files
63+
64+
- `.context/notes.md`: concise findings, caveats, and decisions.
65+
- `.context/todos.md`: actionable follow-ups for parallel agents.
66+
67+
## Guide Index (Use As Needed)
68+
69+
- Setup/config: `development-guides/CONFIGURATION_GUIDE.md`
70+
- Package choice and bootstrap: `development-guides/ROCKETS_PACKAGES_GUIDE.md`
71+
- CRUD patterns: `development-guides/CRUD_PATTERNS_GUIDE.md`
72+
- Auth deep dives: `development-guides/AUTHENTICATION_ADVANCED_GUIDE.md`
73+
- Access control: `development-guides/ACCESS_CONTROL_GUIDE.md`
74+
- Testing: `development-guides/TESTING_GUIDE.md`

CLAUDE.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
AGENTS.md

coverage/coverage-final.json

Lines changed: 80 additions & 79 deletions
Large diffs are not rendered by default.

coverage/coverage-summary.json

Lines changed: 81 additions & 80 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)