(arg: ArgModel)
| 15 | |
| 16 | @app.task(pydantic=True) |
| 17 | def x(arg: ArgModel) -> ReturnModel: |
| 18 | # args/kwargs type hinted as Pydantic model will be converted |
| 19 | assert isinstance(arg, ArgModel) |
| 20 | # The returned model will be converted to a dict automatically |
| 21 | return ReturnModel(value=f"example: {arg.value}") |