[3/4] docs: show each request body's example in the API reference - #148
Merged
Merged
Conversation
This was referenced Sep 29, 2026
dazzatronus
added this pull request to stack #150
September 29, 2026 13:18
dazzatronus
force-pushed
the
derk/reference-request-examples
branch
2 times, most recently
from
September 29, 2026 23:02
1dcd5f3 to
5b1637b
Compare
dazzatronus
marked this pull request as draft
September 30, 2026 00:01
dazzatronus
force-pushed
the
derk/reference-request-examples
branch
from
September 30, 2026 00:06
5b1637b to
4633012
Compare
dazzatronus
marked this pull request as ready for review
September 30, 2026 00:07
dazzatronus
force-pushed
the
derk/reference-request-examples
branch
from
September 30, 2026 00:19
4633012 to
03a4ae8
Compare
dazzatronus
force-pushed
the
derk/reference-request-examples
branch
from
September 30, 2026 00:29
03a4ae8 to
5d097eb
Compare
|
🎉 This PR is included in version 1.20.2 🎉 The release is available on: Your semantic-release bot 📦🚀 |
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 reference shows only a request body's
examples, and widdershins ignores the singularexamplethe spec uses (which the published types need for their@exampledocs). So the body panels and code samples show generated placeholder bodies instead of the spec's examples.scripts/promote-request-examples.cjscopies eachexampletoexamplesin a temporary copy of the spec that only widdershins reads. The spec and package are unchanged, and the existing check that the reference'sapi.bundled.jsonmatchesdiststill holds.The page check confirms every request body panel shows the spec's example.
Merge #151 first: this branch contains its commit, so until #151 lands the diff here shows both.
Verify:
pnpm build:docs && node tests/reference-code-samples.cjs→Request body panels: 7 show their example.Stack (merge in order)
<?phpin rendered PHP samples