Skip to content
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

Native support for Pydantic models for function_framework.typed #289

Open
haizaar opened this issue Nov 30, 2023 · 0 comments · May be fixed by #293
Open

Native support for Pydantic models for function_framework.typed #289

haizaar opened this issue Nov 30, 2023 · 0 comments · May be fixed by #293
Labels
enhancement New feature or request P3

Comments

@haizaar
Copy link

haizaar commented Nov 30, 2023

Following #208 (comment),
it will be great to have Pydantic models supported natively. E.g.

from pydantic import BaseModel

class HelloRequest(BaseModel):
    name: str

@functions_framework.typed
def hello(hr: HelloRequest):
    return f"Hello, {hr.name}"

Thank you!

@haizaar haizaar linked a pull request Nov 30, 2023 that will close this issue
@HKWinterhalter HKWinterhalter added enhancement New feature or request P3 labels Dec 4, 2023
@HKWinterhalter HKWinterhalter removed their assignment Jun 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request P3
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants