-
Notifications
You must be signed in to change notification settings - Fork 72
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
Add OpenAPI (Swagger) documentation for Fides Privacy Center API endpoints (/fides.js
)
#3341
Conversation
Great, now I'm getting a mysterious build error in CI...
Seems to be an open issue affecting folks like us developing on Macs and running CI in Linux: |
Passing run #2146 ↗︎
Details:
This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. |
Seems like an unrelated test failure for
This is failing on |
return { props: {} }; | ||
}; | ||
|
||
const Docs: NextPage = () => <SwaggerUI url="/api/openapi.json" />; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add this page to the README.md of privacy center?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great suggestion, I'll do that! I already wrote some nice words in the PR description I can copypasta
Closes #3275
Code Changes
next-swagger-doc
andswagger-react-ui
modules for the OpenAPI docs/fides.js
route using special@swagger
JSdoc syntax/docs
page to show the API docs, but only in development modeSteps to Confirm
cd clients/privacy-center && npm install && turbo dev
nox -s "fides_env(test)"
and confirm that the API documentation is not there (should only be dev builds)Pre-Merge Checklist
CHANGELOG.md
Description Of Changes
This adds some in-app documentation for how to use the
/fides.js
route to generate the Fides.js bundle.