docs(openai): generate mintlify docs for openai - #601
Conversation
|
@yuvanvk is attempting to deploy a commit to the corsair Team on Vercel. A member of the Team first needs to authorize it. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughChangesOpenAI Credential Documentation
Estimated code review effort: 1 (Trivial) | ~2 minutes Possibly related PRs
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
🧪 Generate unit tests (beta)
Comment |
Greptile SummaryAdds generated Mintlify documentation for the OpenAI plugin and makes it discoverable in the documentation navigation.
Confidence Score: 5/5The PR appears safe to merge. No blocking failure remains. Important Files Changed
Reviews (2): Last reviewed commit: "chore: CI-rerun" | Re-trigger Greptile |
There was a problem hiding this comment.
Actionable comments posted: 8
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@docs/plugins/openai/api.mdx`:
- Around line 22-24: Update the standard documentation generator that produces
the assistants.create example and other operation snippets so each emitted call
satisfies its documented required inputs, including model fields, IDs, files,
and request bodies; otherwise mark the block as non-runnable pseudocode.
Regenerate the page from the generator and avoid maintaining a hand-written
layout.
- Around line 4067-4099: Update the standard type-summary generator to preserve
scalar branches in union types, then regenerate all affected documentation. In
docs/plugins/openai/api.mdx lines 4067-4099, render messages.create content as
string | object[]; in lines 4619-4629, include moderation input’s string and
string-array branches; in lines 4977-4999 and 6683-6695, include each Responses
API input’s string branch.
- Around line 43-66: Update the generator that emits TypeScript discriminator
examples so all listed string values are quoted, then regenerate
docs/plugins/openai/api.mdx: lines 43-66 must quote code_interpreter,
file_search, and function; lines 985-1024 must quote the role and content type
values; lines 4077-4098 must quote text, image_file, and image_url; and lines
7497-7516 must quote auto and static.
In `@docs/plugins/openai/get-credentials.mdx`:
- Around line 20-24: The documentation example shows passing credentials as
command-line arguments to the `pnpm corsair setup --plugin=openai` command,
which is a security vulnerability. Replace the insecure process.argv
credential-reading approach in the setup command with a secure input flow using
prompts or stdin to request credentials interactively from the user. Update the
bash example in this documentation to reflect the new secure prompt-based flow,
and apply the same secure pattern to other plugin guides that may have similar
credential-passing examples. Verify the documentation generator reflects this
secure input approach for all plugin setup examples.
In `@docs/plugins/openai/overview.mdx`:
- Around line 117-121: Update the assistants.create example to include the
required model field, using the smallest valid payload and a suitable model
value instead of passing an empty object.
- Around line 128-130: Update the Hooks section to document only the supported
hooks API: keep the `hooks` guidance, remove `webhookHooks`, incoming-events
wording, and the `/concepts/webhooks` link, while preserving the
`/concepts/hooks` reference.
- Line 69: Update the credential instructions in the OpenAI plugin documentation
to reference only the supported api_key authentication field. Remove bot_token
and OAuth client-field references from the credential examples at both affected
locations, while preserving the link to Get Credentials.
- Around line 62-69: The documentation in the Store credentials section
references the Get Credentials page but does not specify a secure input method
for credentials. Update the documentation to explicitly instruct users to
provide credentials through an interactive prompt or stdin input rather than as
command-line arguments (such as `api_key=`). Ensure the pnpm corsair setup
command example and any referenced examples in the Get Credentials documentation
clearly show interactive or stdin-based credential entry to prevent exposure of
API keys in shell history and process inspection.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: be27945b-6080-4256-9b36-6d8ca2aaae70
📒 Files selected for processing (5)
docs/docs.jsondocs/plugins/openai/api.mdxdocs/plugins/openai/database.mdxdocs/plugins/openai/get-credentials.mdxdocs/plugins/openai/overview.mdx
|
@ambikeesshh addressed all the Greptile issues and opened a new PR as the previous one got closed by mistake. |
|
@greptile-apps re-run yourself with conclusions we made |
|
Closing as Docs are in production by this commit |
Description
Adds the missing OpenAI plugin documentation.
packages/openaihas been onmainfor a while, butdocs/plugins/openainever existed and the plugin wasn't listed in the Mintlify nav — so anyone browsing the docs had no way to find it.This PR runs the standard doc generator against the
openaiplugin and commits the output, rather than hand-writing a one-off page.Fixes #541
Changes
pnpm generate:docs -- --plugin=openaito generate the plugin docsdocs/plugins/openai/docs/docs.jsonto add theopenainav entry under Plugins via scriptdocs/docs.jsonto add the/plugins/openai/get-credentialsTests
Ran the verification steps from the issue:
docs/plugins/openai/exists with the usual pagesopenaishows up under Plugins indocs/docs.jsonScreenshots / Demo
Summary by CodeRabbit