Fix API reference and env var documentation drift against source code#63
Merged
MinecraftFuns merged 3 commits intomainfrom Feb 28, 2026
Merged
Conversation
…ssing endpoints and env vars - Fix wrong pagination params (offset→cursor) in README API examples - Fix wrong redirect status code (301→308 default, configurable) - Remove broken README.old.md link - Add all missing API endpoints to README (auth/mode, user/info, analytics, search) - Document ENABLE_TIMING_HEADERS condition for timing headers - Add X-Lynx-Timing-Handler-Ms to timing headers list - Add REDIRECT_STATUS_CODE and ENABLE_TIMING_HEADERS to README config table - Add ENABLE_TIMING_HEADERS to .env.example - Fix AUTH_MODE in workflows README (add cloudflare) - Add drift-prevention script scripts/check-docs-drift.sh - Add .jules/atlas.md journal Co-authored-by: MinecraftFuns <25814618+MinecraftFuns@users.noreply.github.com>
Co-authored-by: MinecraftFuns <25814618+MinecraftFuns@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Update onboarding documentation for new contributors
Fix API reference and env var documentation drift against source code
Feb 28, 2026
MinecraftFuns
approved these changes
Feb 28, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
README documented offset-based pagination, 301 redirects, and unconditional timing headers — none of which match the actual implementation. Several API endpoints and env vars were also missing from docs.
Fixes
GET /api/urls?limit=50&offset=0→ cursor-based (limit+cursorparams, perListQueryinsrc/api/handlers.rs)→ 301 Redirect→→ 308 Permanent Redirect(default fromRedirectMode::default()insrc/config/mod.rs)README.old.mdENABLE_TIMING_HEADERSenv var (src/main.rs:726). Added missingX-Lynx-Timing-Handler-Ms.GET /api/auth/mode,GET /api/user/info,GET /api/analytics/{code},GET /api/analytics/{code}/aggregate,GET /api/urls/searchREDIRECT_STATUS_CODEandENABLE_TIMING_HEADERSto README config table and.env.exampleAUTH_MODElistednoneandoauthonly — addedcloudflareDrift prevention
New
scripts/check-docs-drift.shthat verifies:.route()paths fromsrc/api/routes.rsandsrc/redirect/routes.rsappear in READMEstd::env::var()names fromsrc/config/mod.rsandsrc/main.rsappear in README or.env.examplebash scripts/check-docs-drift.sh # ✅ All documentation drift checks passed.🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.