Skip to content

fix(sdk): preserve required body properties in flat params signatures#3456

Open
vcombey wants to merge 1 commit intohey-api:mainfrom
mailmeteor:feat/fix-flat-body-requiredness
Open

fix(sdk): preserve required body properties in flat params signatures#3456
vcombey wants to merge 1 commit intohey-api:mainfrom
mailmeteor:feat/fix-flat-body-requiredness

Conversation

@vcombey
Copy link

@vcombey vcombey commented Feb 26, 2026

Summary

Fix flattened body requiredness in SDK signatures when using paramsStructure: 'flat'.

Closes #3455.

Problem

For object request bodies, flattened properties were marked required by checking property.required, which is not valid at property level in OpenAPI schema objects.

OpenAPI requiredness for object properties is defined by the parent schema required array. A property schema does not have its own required flag.

@pullfrog
Copy link

pullfrog bot commented Feb 26, 2026

Leaping into action...

Pullfrog  | View workflow run | Using OpenCode | Triggered by Pullfrogpullfrog.com𝕏

@bolt-new-by-stackblitz
Copy link

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@vercel
Copy link

vercel bot commented Feb 26, 2026

@vincentcombey-design is attempting to deploy a commit to the Hey API Team on Vercel.

A member of the Team first needs to authorize it.

@changeset-bot
Copy link

changeset-bot bot commented Feb 26, 2026

⚠️ No Changeset found

Latest commit: f482160

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. bug 🔥 Broken or incorrect behavior. labels Feb 26, 2026
@codecov
Copy link

codecov bot commented Feb 26, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 40.37%. Comparing base (11f5470) to head (f482160).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3456      +/-   ##
==========================================
+ Coverage   40.11%   40.37%   +0.25%     
==========================================
  Files         478      478              
  Lines       17488    17489       +1     
  Branches     5294     5301       +7     
==========================================
+ Hits         7016     7061      +45     
+ Misses       8425     8392      -33     
+ Partials     2047     2036      -11     
Flag Coverage Δ
unittests 40.37% <100.00%> (+0.25%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@vcombey vcombey force-pushed the feat/fix-flat-body-requiredness branch from b02916d to 56d6517 Compare February 26, 2026 10:32
@vcombey vcombey force-pushed the feat/fix-flat-body-requiredness branch from 56d6517 to f482160 Compare February 26, 2026 10:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug 🔥 Broken or incorrect behavior. size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

sdk(flat): required requestBody object properties become optional

2 participants