docs(readme): surface exact password validation error messages#183
Merged
veverkap merged 1 commit intoMay 3, 2026
Merged
Conversation
The handler docs (docs/handler/auth.md, docs/handler/password-reset.md) were recently updated to document the exact JSON error bodies returned for out-of-range passwords. Mirror the same information in README.md so that API clients reading the README also see the exact error strings they will receive. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the project’s primary documentation entry point (README.md) to explicitly document the exact JSON error bodies returned when password length validation fails, matching the handler-specific docs added in #181.
Changes:
- AuthHandler section: documents exact
{"error": "password must be at least 8 bytes"}/{"error": "password must be at most 72 bytes"}responses alongside the 8–72 byte constraint (and bcrypt cost note). - PasswordResetHandler section: replaces the cross-reference with the same explicit error messages inline to keep the section self-contained.
Show a summary per file
| File | Description |
|---|---|
| README.md | Adds the exact password length validation error JSON bodies to the AuthHandler and PasswordResetHandler documentation sections. |
Copilot's findings
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 1/1 changed files
- Comments generated: 0
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.
The previous commit (#181) updated
docs/handler/auth.mdanddocs/handler/password-reset.mdto document the exact JSON error bodies returned for out-of-range passwords. The README was not updated at that time, leaving it with vaguer descriptions.This PR mirrors the same information into
README.mdso that API clients reading the README (the most commonly consulted entry point) also see the exact error strings they will receive — and can display or localize them appropriately.Changes
README.md— AuthHandler section (line ~523): updated"Password constraints: 8–72 bytes. Bcrypt cost 12."to also include the exact error bodies:README.md— PasswordResetHandler section (line ~1095): replaced the vague(same 8–72 byte password constraint as AuthHandler)cross-reference with the explicit error messages inline, keeping the section self-contained.No code changes. No other docs were affected — the dedicated handler docs were already updated in #181.
Warning
The following domain was blocked by the firewall during workflow execution:
proxy.golang.orgTo allow these domains, add them to the
network.allowedlist in your workflow frontmatter:See Network Configuration for more information.
Greptile Summary
This PR updates
README.mdto surface the exact JSON error bodies returned for out-of-range passwords in both theAuthHandlerandPasswordResetHandlersections, mirroring changes already made to the dedicated handler docs in #181. The documented error strings ("password must be at least 8 bytes"/"password must be at most 72 bytes") and the{"error": "..."}envelope match the actual implementation inhandler/helpers.goexactly.Confidence Score: 5/5
Safe to merge — documentation-only change with no code modifications
The documented error strings, byte bounds (8–72), and JSON envelope format all match handler/helpers.go exactly. No code paths are affected.
No files require special attention
Important Files Changed
Flowchart
%%{init: {'theme': 'neutral'}}%% flowchart TD A[Client sends password] --> B{len < 8 bytes?} B -->|Yes| C[HTTP 400 - password must be at least 8 bytes] B -->|No| D{len > 72 bytes?} D -->|Yes| E[HTTP 400 - password must be at most 72 bytes] D -->|No| F[bcrypt cost 12 - password accepted]Reviews (1): Last reviewed commit: "docs(readme): surface exact password val..." | Re-trigger Greptile