/openapi-codegen

Using automatically generated API schema and query from OpenAPI json that generates React Query code in Next.js

Primary LanguageTypeScript

Autogenerated API's from OpenAPI schema

See this repo for backend setup.

Steps

  1. Point your OpenAPI schema.json file in .env
NEXT_PUBLIC_API_URL=http://localhost:8000/swagger/json
  1. Generate the queries and schema
pnpm codegen
  1. Start your server
pnpm dev