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

Generate OpenAPI definitions for HTTP API #117

Open
tstirrat15 opened this issue Sep 6, 2024 · 1 comment
Open

Generate OpenAPI definitions for HTTP API #117

tstirrat15 opened this issue Sep 6, 2024 · 1 comment

Comments

@tstirrat15
Copy link
Contributor

Problem Statement

We have a Postman collection, but updating it is a manual task.

Additionally, we have users who want to use HTTP clients but also want type safety for those clients. If we export OpenAPI definitions, we can let users generate a typed API client using their tool of choice.

Solution Brainstorm

I'm not entirely sure where in the toolchain this should live - if it's a build-time thing that generates a static file or if it becomes something that's served alongside the HTTP API. I think I'd lean towards the latter but I'm not entirely sure.

@jzelinskie jzelinskie transferred this issue from authzed/spicedb Sep 18, 2024
@holgerstolzenberg
Copy link
Contributor

I am currently exactly facing this problem.

I started to put together a GitHub project that provides these prepackaged clients: https://github.com/ewerk/authzed-http-client

It is currently incubating but snapshot libs for Java and Typescript are already available.

Essentially it is a a collection of GitHub actions leveraging https://github.com/openapi-generators/openapitools-generator-action. It uses the OpenAPI spec file that you already create from authzed/api into authzed/go.

Please see following PR for reference: authzed/authzed-go#255

If you are interested we could shift the project into authzed project responsibility once it has the necessary maturity.

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

No branches or pull requests

2 participants