Documentation

Pydantic uses MkDocs for documentation, together with mkdocstrings. As such, you can make use of Pydantic's Sphinx object inventory to cross-reference the Pydantic API documentation.

In your Sphinx configuration, add the following to the intersphinx extension configuration:

intersphinx_mapping = {
    'pydantic': ('https://docs.pydantic.dev/latest', None),  # (1)!
}
  1. You can also use dev instead of latest to target the latest documentation build, up to date with the main branch.

In your MkDocs configuration, add the following import to your mkdocstrings plugin configuration:

plugins:
- mkdocstrings:
    handlers:
      python:
        import:
        - https://docs.pydantic.dev/latest/objects.inv  # (1)!
  1. You can also use dev instead of latest to target the latest documentation build, up to date with the main branch.