Skip to content

feat(codegen): generate go doc comments for client wrappers from openapi spec - #225

Open
tharropoulos wants to merge 4 commits into
typesense:masterfrom
tharropoulos:doc-gen
Open

tharropoulos wants to merge 4 commits into
typesense:masterfrom
tharropoulos:doc-gen

Conversation

@tharropoulos

Copy link
Copy Markdown
Collaborator

Change Summary

  • add typesense/api/generator/docgen.go post-pass that walks each wrapper file, resolves methods to operations via their apiClient.<Op> call, and injects doc comments above the impl and matching interface declaration
  • wire docgen into typesense/api/generator/main.go after generateClient() so go generate produces hover docs from the openapi summary/description/method/path/tag
  • annotate 30 wrapper files using the spec's verbatim text plus a See: link derived from the operation's tag
  • hand-write hover docs and See: links for top-level Client accessor methods and the MultiSearch field in typesense/client.go

PR Checklist

@tharropoulos

Copy link
Copy Markdown
Collaborator Author

some linting errors, will update and mark it for review

@tharropoulos

Copy link
Copy Markdown
Collaborator Author

CC: @kishorenc

@jamietanna

jamietanna commented Sep 28, 2026 •

Copy link
Copy Markdown

This should be (mostly) available in upstream oapi-codegen now 🤞🏼

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.

2 participants