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

feat: client generation #103

Draft
wants to merge 9 commits into
base: main
Choose a base branch
from
Draft

Conversation

Karitham
Copy link
Collaborator

Not tested enough, but I'm throwing the idea out there.

This is WIP, and uses an external package for building requests.

We could technically copy over the external code, or generate it alongside the client, but I thought relying on a battle tested library was worth it, even though it makes for an extra dependency.

The generated code is decent. The only thing I'm unhappy about is how API errors don't get coalesced into an error, because we would have to figure out what errors are (500s+ only?).

We could also pattern match on ($error^ i). It's still decent to work with though.

@Karitham Karitham linked an issue Aug 26, 2023 that may be closed by this pull request
4 tasks
we only handle json. users can handle other content types with custom response handlers
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Idiomatic Client
1 participant