Skip to content

feat(openapi-fetch): add support for pathSerializer option#2362

Merged
drwpow merged 7 commits intoopenapi-ts:mainfrom
luxass:support-custom-path-serializer
Feb 8, 2026
Merged

feat(openapi-fetch): add support for pathSerializer option#2362
drwpow merged 7 commits intoopenapi-ts:mainfrom
luxass:support-custom-path-serializer

Conversation

@luxass
Copy link
Copy Markdown
Contributor

@luxass luxass commented Jun 28, 2025

Changes

What does this PR change? Link to any related issue(s).

This PR adds support for setting path serializers yourself, either globally or per request. Similar to how bodySerializers & querySerializers work.

resolves #1660

How to Review

How can a reviewer review your changes? What should be kept in mind for this review?

Checklist

  • Unit tests updated
  • docs/ updated (if necessary)
  • pnpm run update:examples run (only applicable for openapi-typescript)

@netlify
Copy link
Copy Markdown

netlify Bot commented Jun 28, 2025

👷 Deploy request for openapi-ts pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 05c2762

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Jun 28, 2025

🦋 Changeset detected

Latest commit: 05c2762

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
openapi-fetch Minor
openapi-react-query Major
swr-openapi Major

Not sure what this means? Click here to learn what changesets are.

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

@luxass luxass marked this pull request as ready for review June 28, 2025 07:01
@luxass luxass requested a review from a team as a code owner June 28, 2025 07:01
@luxass luxass requested a review from drwpow June 28, 2025 07:01
@gzm0 gzm0 added the openapi-fetch Relevant to the openapi-fetch library label Oct 2, 2025
luxass added 6 commits October 9, 2025 04:16
- Introduced `pathSerializer` to `ClientOptions` for enhanced path handling.
- Updated `createClient` function to utilize `pathSerializer` from options.
- Modified `createFinalURL` to apply the provided `pathSerializer`.
@luxass luxass force-pushed the support-custom-path-serializer branch from c650990 to ce1961e Compare October 9, 2025 02:17
Copy link
Copy Markdown
Contributor

@drwpow drwpow left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for the extreme delay here; this seemed to have slipped between the cracks.

As you may have seen, we’ll be putting openapi-fetch into maintenance mode but before we do, happy to have a few final releases with backwards-compatible changes & improvements like this. Thanks for your work on this! I think this fits nicely into the existing API and is a great addition

@drwpow drwpow merged commit 9002418 into openapi-ts:main Feb 8, 2026
7 checks passed
@openapi-ts-bot openapi-ts-bot mentioned this pull request Feb 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

openapi-fetch Relevant to the openapi-fetch library

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow for custom types in path params serialization (and maybe other places serialization too)

3 participants