Skip to content

Add Effect v4 schema and HttpApiClient plugins - #696

Draft
nmnmcc wants to merge 4 commits into
kubb-labs:mainfrom
nmnmcc:effect-httpapiclient
Draft

Add Effect v4 schema and HttpApiClient plugins#696
nmnmcc wants to merge 4 commits into
kubb-labs:mainfrom
nmnmcc:effect-httpapiclient

Conversation

@nmnmcc

@nmnmcc nmnmcc commented Jul 15, 2026

Copy link
Copy Markdown

🎯 Changes

  • add @kubb/plugin-effect for generating Effect v4 beta schemas from OpenAPI models
  • represent OpenAPI date-time values with Effect DateTime.Utc and JSON int64 values with a number-to-bigint codec
  • add @kubb/plugin-effect-httpapiclient for generating typed HttpApi, endpoint groups, clients, parameter serialization, cookies, and security layers
  • add runnable examples and regression coverage for nested references, date-time annotations, JSON int64 codecs, default responses, and security middleware

The two plugins are kept separate so schema generation can be used independently while the HttpApiClient plugin composes the generated Effect schemas into an Effect HTTP API client.

Related documentation Draft PR: kubb-labs/docs#145

✅ Checklist

  • I have followed the steps in the Contributing guide.
  • I have tested this code locally with pnpm run test.

Additional verification:

  • pnpm --filter @kubb/plugin-effect test
  • pnpm --filter @kubb/plugin-effect typecheck
  • pnpm --filter @kubb/plugin-effect build
  • pnpm --filter @kubb/plugin-effect-httpapiclient test
  • pnpm --filter @kubb/plugin-effect-httpapiclient typecheck
  • pnpm --filter @kubb/plugin-effect-httpapiclient build
  • pnpm format
  • pnpm lint:fix

🚀 Release Impact

  • This change affects published code, and I have generated a changeset.
  • This change is for the docs (no release).

This PR is intentionally a draft pending maintainer review.

@codesandbox

codesandbox Bot commented Jul 15, 2026

Copy link
Copy Markdown

Review or Edit in CodeSandbox

Open the branch in Web EditorVS CodeInsiders

Open Preview

1 similar comment
@codesandbox

codesandbox Bot commented Jul 15, 2026

Copy link
Copy Markdown

Review or Edit in CodeSandbox

Open the branch in Web EditorVS CodeInsiders

Open Preview

@changeset-bot

changeset-bot Bot commented Jul 15, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7463a12

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

This PR includes changesets to release 2 packages
Name Type
@kubb/plugin-effect-httpapiclient Minor
@kubb/plugin-effect Minor

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

@nmnmcc
nmnmcc marked this pull request as ready for review July 15, 2026 05:12
@dosubot dosubot Bot added the size:XL This PR changes 500-999 lines, ignoring generated files. label Jul 15, 2026
@stijnvanhulle

Copy link
Copy Markdown
Contributor

@nmnmcc Thanks for having a look at adding Effect support in Kubb. We are preparing for Kubb v5 which means I will postpone this after the v5 release (planned in a couple of weeks). Could you also create a Github issue in why you think this would be a good fit for adding to Kubb so other users know that this is coming soon :)

@nmnmcc
nmnmcc marked this pull request as draft July 15, 2026 12:01
@nmnmcc

nmnmcc commented Jul 15, 2026

Copy link
Copy Markdown
Author

Thanks for the context. Waiting until after Kubb v5 works for me. I opened #706 to explain the motivation and proposed plugin split for Effect support. I'll keep this PR as a draft and rebase and update the implementation once v5 is released.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XL This PR changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants