From e5957106ba43645778abad154dcbb8e574250dc6 Mon Sep 17 00:00:00 2001 From: Yamini Chittygori Date: Sun, 25 Oct 2026 11:58:34 +0530 Subject: [PATCH] added async fn --- README.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/README.md b/README.md index d564ad92..40a093e7 100644 --- a/README.md +++ b/README.md @@ -91,6 +91,24 @@ Or send requests to this function using `curl` from another terminal window: curl localhost:8080 # Output: Hello world! ``` +### Quickstart: Async HTTP Function + +The Functions Framework supports asynchronous HTTP functions using the `aio` decorator. + +```python +import logging +import functions_framework + +logger = logging.getLogger(__name__) + + +@functions_framework.aio.http +async def hello(request): + logger.warning("Received async HTTP request") + return "Hello from an async function!" +``` + +Standard Python logging can be used inside async HTTP handlers just as with synchronous handlers. ### Quickstart: CloudEvent Function