https://github.com/mansenfranzen/autodoc_pydantic
Seamlessly integrate pydantic models in your Sphinx documentation.
https://github.com/mansenfranzen/autodoc_pydantic
autodoc documentation pydantic python sphinx sphinx-extension
Last synced: 29 days ago
JSON representation
Seamlessly integrate pydantic models in your Sphinx documentation.
- Host: GitHub
- URL: https://github.com/mansenfranzen/autodoc_pydantic
- Owner: mansenfranzen
- License: mit
- Created: 2021-03-24T09:26:41.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2025-04-01T12:58:43.000Z (about 1 month ago)
- Last Synced: 2025-04-07T05:00:45.418Z (about 1 month ago)
- Topics: autodoc, documentation, pydantic, python, sphinx, sphinx-extension
- Language: Python
- Homepage:
- Size: 2.7 MB
- Stars: 165
- Watchers: 5
- Forks: 27
- Open Issues: 39
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
- Codeowners: CODEOWNERS
Awesome Lists containing this project
- awesome-pydantic - autodoc_pydantic - Seamlessly integrate pydantic models in your Sphinx documentation. (Utilities)
- awesome-pydantic - autodoc_pydantic - Seamlessly integrate pydantic models in your Sphinx documentation. (Utilities)
README

[](https://pypi.org/project/autodoc_pydantic/)
[](https://www.python.org/)
[](https://pypistats.org/packages/autodoc-pydantic)[](https://github.com/mansenfranzen/autodoc_pydantic/actions)
[](https://app.codecov.io/gh/mansenfranzen/autodoc_pydantic)
[](https://autodoc-pydantic.readthedocs.io/en/stable/)[](https://github.com/mansenfranzen/autodoc_pydantic/blob/main/LICENSE)
[](https://github.com/astral-sh/ruff)
[](https://github.com/python/mypy)
[](https://github.com/mansenfranzen/autodoc_pydantic?tab=readme-ov-file#-acknowledgements)You love [pydantic](https://pydantic-docs.helpmanual.io/) β€ and you want to
document your models and configuration settings with [sphinx](https://www.sphinx-doc.org/en/master/)?Perfect, let's go. But wait, sphinx' [autodoc](https://www.sphinx-doc.org/en/master/usage/extensions/autodoc.html)
does not integrate too well with pydantic models π.Don't worry - just `pip install autodoc_pydantic` βΊ.
# π Features
- π¬ provides default values, alias and constraints for model fields
- π adds hyperlinks between validators and corresponding fields
- π includes collapsable model json schema
- π natively integrates with autodoc and autosummary extensions
- π defines explicit pydantic prefixes for models, settings, fields, validators and model config
- π shows summary section for model configuration, fields and validators
- π hides overloaded and redundant model class signature
- π± visualizes entity-relationship-diagrams for class hierarchies
- π¨ allows complete configurability on global and per-model level
- π supports `pydantic >= 1.5.0` and `sphinx >= 4.0.0`# π Documentation
| Section | Description |
|-----------------------------------------|-----------------------------------------|
| [π Landing Page](https://autodoc-pydantic.readthedocs.io/en/stable/) | Guides and detailed information. |
| [π οΈ Installation](https://autodoc-pydantic.readthedocs.io/en/stable/users/installation.html) | Setup and installation procedures. |
| [π§ Configuration](https://autodoc-pydantic.readthedocs.io/en/stable/users/configuration.html) | System or application settings. |
| [π‘ Usage](https://autodoc-pydantic.readthedocs.io/en/stable/users/usage.html) | How to use the application or tool. |
| [π Examples](https://autodoc-pydantic.readthedocs.io/en/stable/users/examples.html) | Showcase and usage examples. |
| [π¨βπ» Developer Guide](https://autodoc-pydantic.readthedocs.io/en/stable/developers/setup.html) | In-depth guide for developers. |# π Acknowledgements
Thanks to great open source projects [sphinx](https://www.sphinx-doc.org/en/master/),
[pydantic](https://pydantic-docs.helpmanual.io/) and
[poetry](https://python-poetry.org/) (and so many more) β€ in addition to the following contributors:
Franz WΓΆllert
π§ π β οΈ π
Yves Renier
π β οΈ π
TheBeardedBerserkr
π€
Jan VlΔinskΓ½
π‘οΈ
antvig
π π
Hugo O Rivera
π€
yura bondarenko
π π
Trevor Howard
π π
thomas-pedot
π π
Mat Utter
π π
David C Hall
π€ π
Josh A. Mitchell
π€ β οΈ
Roderick Go
β οΈ
Lily Wang
π π
j-carson
π π» β οΈ
Jakob Lykke Andersen
π»
Juan Luis Cano RodrΓguez
π
Mikalai Chaly
π β οΈ
Stig Korsnes
π π€
Ilia Kurenkov
π
Grzegorz Bokota
π
jgunstone
π
iwyrkore
π»
spacemanspiff2007
π π€
Luke Hsiao
π
Daniel Walker
π
Evgeniy Lupashin
π
Jan-Hendrik Ewers
π
Jonny Saunders
π
Charles Machalow
π¬
Thomas Karaouzene
π
caseyzak24
π
Priscila Oliveira
π π
Arthur WoimbΓ©e
π π π» β οΈ
Chris Markiewicz
π
David B. Nagle
π
JerryJia
π»
Mike D
π» π β οΈ
Dario Quintero (Flexcompute)
π
Rafael Guedes
π»
Andrew Linzie
π»
Altay Sansal
π€
Tony Narlock
π» π
Xuan (Sean) Hu
π
Christian Riedel
π
morcef
π
alejandro-yousef
π€
exs-dwoodward
π»
Leah Wasser
π
Allan Galarza
π
Carson-Shaar
π
Kyle Finley
π
brunocruz
π
Anne Rademacher
π΅
Γloi Rivard
π π¬
Mitchell Blyth
π¬
John-Luke Navarro
π¬
This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!