Repository navigation
fix(codegen)!: name a GET of /me as one item, -get, not -list - #636
Merged
Merged
Conversation
Notion's GET /v1/users/me came out as users-me-list from names.fromPath.
A path ending in /me reads the caller's own record, never a list. A path
whose last fixed word follows a parameter stays -list: the path alone
cannot tell /pages/{id}/markdown from /blocks/{id}/children.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
leemour
force-pushed
the
fix/codegen-me-is-get
branch
from
November 17, 2026 21:22
94b6337 to
9d4b4d9
Compare
Merged
leemour
added a commit
that referenced
this pull request
Nov 17, 2026
Dates Unreleased as 0.116.0: GET /me is named -get (#636). 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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.
Task
Notion's official OpenAPI description, generated with
@wirecat/cli-template0.27.0, gaveusers-me-listforGET /v1/users/me.Why
A path ending in
/mereads the caller's own record, never a list. Command names are a contract, so this is under "Changed — may break callers".What
commandFromPath: a GET whose last segment ismegets the verbget./pages/{id}/markdown) stays-list, since the path alone cannot tell it from a real list (/blocks/{id}/children,/data-sources/{id}/templates, Stripe's/customers/{id}/sources). A CLI names it incommands.Testing
src/codegen/swagger.test.ts:users-list,users-me-get,blocks-children-list.vitest run src/codegen: 120 passed. Lint, typecheck,docs:checkpass.🤖 Generated with Claude Code