Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add HttpApi modules to /platform #3495

Merged
merged 59 commits into from
Aug 30, 2024
Merged

add HttpApi modules to /platform #3495

merged 59 commits into from
Aug 30, 2024

Conversation

tim-smart
Copy link
Member

No description provided.

Copy link

changeset-bot bot commented Aug 22, 2024

🦋 Changeset detected

Latest commit: 11118f9

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

This PR includes changesets to release 31 packages
Name Type
@effect/platform Major
effect Minor
@effect/cli Major
@effect/cluster-node Major
@effect/cluster-workflow Major
@effect/cluster Major
@effect/experimental Major
@effect/platform-browser Major
@effect/platform-bun Major
@effect/platform-node-shared Major
@effect/platform-node Major
@effect/rpc-http Major
@effect/rpc Major
@effect/sql-d1 Major
@effect/sql-mssql Major
@effect/sql-mysql2 Major
@effect/sql-pg Major
@effect/sql-sqlite-bun Major
@effect/sql-sqlite-node Major
@effect/sql Major
@effect/cluster-browser Major
@effect/opentelemetry Major
@effect/printer-ansi Major
@effect/printer Major
@effect/schema Major
@effect/sql-drizzle Major
@effect/sql-kysely Major
@effect/sql-sqlite-react-native Major
@effect/sql-sqlite-wasm Major
@effect/typeclass Major
@effect/vitest 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

@tim-smart tim-smart force-pushed the http-api branch 2 times, most recently from 9622fc8 to 498f23c Compare August 23, 2024 12:22
@github-actions github-actions bot changed the base branch from main to next-minor August 24, 2024 09:57
@tim-smart tim-smart marked this pull request as ready for review August 26, 2024 01:41
),
ApiGroup.add(
ApiEndpoint.post("create", "/").pipe(
ApiEndpoint.setPayload(ApiSchema.Multipart(Schema.Struct({
Copy link
Contributor

Choose a reason for hiding this comment

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

Are all this supposed to set validation schemas? If that is the case (and I'm being a bit nitpicking here) reflecting that in the name will be easier to understand and more consistent with the rest of the methods of the platform package (eg setCookiesSchema or setHeadersSchema)

Copy link
Member Author

Choose a reason for hiding this comment

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

All Api* modules are schema only, and the ApiBuilder module is for the implementation side.

The Api naming might change to make it more obvious that everything is a schema.

@kattsushi
Copy link

I'm not sure if it makes sense (im consider my self very new on effect and fp paradigms), but I would like the @effect/RPC API to eventually be as similar to this HttpApi as possible. While RPC is currently very composable, I understand that it is not as declarative as this (HttpApi) in terms of separating the blueprint or declaration (with the help of schemas) from the implementation.

Great work, congratulations! 🚀

@tim-smart tim-smart changed the title add Api modules to /platform add HttpApi modules to /platform Aug 27, 2024
@github-actions github-actions bot force-pushed the next-minor branch 3 times, most recently from 59d9522 to 9d8acac Compare August 27, 2024 22:27
@tim-smart tim-smart merged commit c25118d into next-minor Aug 30, 2024
11 checks passed
@tim-smart tim-smart deleted the http-api branch August 30, 2024 09:18
@github-actions github-actions bot mentioned this pull request Aug 30, 2024
github-actions bot pushed a commit that referenced this pull request Aug 30, 2024
tim-smart added a commit that referenced this pull request Aug 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants