koxudaxi/datamodel-code-generator
Generate Python data models from schema definitions (OpenAPI, JSON Schema, GraphQL, and more)
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Stale
- License
- None
Inputs
| name | description | required | default |
|---|---|---|---|
| input | Input schema file or directory | yes | — |
| output | Output file or directory | yes | — |
| input-file-type | Input file type (openapi, asyncapi, jsonschema, mcp-tools, xmlschema, graphql, protobuf, avro, json, yaml, csv) | yes | — |
| output-model-type | Output model type (pydantic_v2.BaseModel, pydantic_v2.dataclass, dataclasses.dataclass, typing.TypedDict, msgspec.Struct) | yes | — |
| check | Validate that existing output is up to date (no generation) | no | true |
| working-directory | Working directory (where pyproject.toml is located) | no | . |
| profile | Named profile from pyproject.toml [tool.datamodel-codegen.profiles.<name>] | no | "" |
| extra-args | Additional CLI arguments | no | "" |
| version | Specific version to install (defaults to action tag version if tag looks like a version, otherwise latest) | no | "" |
| extras | Optional extras to install (comma-separated: graphql, http, validation, ruff, all) | no | "" |
Outputs
no outputs