-
Notifications
You must be signed in to change notification settings - Fork 20
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
Ship more detailed types? Codegen from OpenAPI-spec? #277
Comments
Hello checkout.com team, Please don't do typechecking with primitives. |
Thanks for the feedback @christos97 Will look into updating this. |
@KATT The very minimal type defs were intentional. You can use our API reference to see details about the payloads. We are also exploring generators or full types support as well. |
Type safety reduces the maintenance burden on consumers of SDKs enormously. It would be great to see an improvement as suggested here. |
We will try to implement this improvement soon. |
Hey gang!
Looking at the typedefs of this SDK, I see a big void of actual type-safety:
Even looking at the docs I still don't know what different endpoints are supposed to return without actually invoking the call. The problem with that is that we won't have any reconciliation reports in our sandbox environment.
This example above is just in order to showcase and issue and grokking that is a separate issue.
Suggestion: You shouldn't need to manually write the implementation of every endpoint and instead be able to automatically generate a typesafe SDK based on your OpenAPI-schema using something like the openapi-generator.
Automating this would likely:
The text was updated successfully, but these errors were encountered: