From 424c6bf6786442b1eac60eea87e8c6acc1200a08 Mon Sep 17 00:00:00 2001 From: dennemark Date: Thu, 12 Dec 2024 13:49:28 +0100 Subject: [PATCH] chore(docs): Add additional hints to serverless functions (#11751) Co-authored-by: Tobbe Lundberg --- docs/docs/serverless-functions.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/docs/serverless-functions.md b/docs/docs/serverless-functions.md index a5753b376d81..2808502e16a4 100644 --- a/docs/docs/serverless-functions.md +++ b/docs/docs/serverless-functions.md @@ -846,7 +846,7 @@ Content-Type: application/json ### Other security considerations -In addition to securing your serverless functions, you may consider logging, rate limiting and whitelisting as ways to protect your functions from abuse or misuse. +In addition to securing your serverless functions, you may consider logging, rate limiting and whitelisting as ways to protect your functions from abuse or misuse. Some of these benefits can be achieved with middleware like [middy](https://middy.js.org/), since our functions should be compatible with the lambda functions ecosystem. #### Visibility via Logging @@ -916,3 +916,7 @@ export const handler = async (event: APIGatewayEvent, context: Context) => { } } ``` + +## How-To + +We have prepared a simple [How-To](how-to/custom-function/) for you on how to setup a custom function to retrieve the server time, including consideration of CORS.