Basic examples for serverless functions

As a starter I just want to have a single function that responds on a POST.

  const response = {
    statusCode: 200,
    headers: {
      'Content-Type': 'text/html; charset=utf-8'
    body: '<p>Hello world!</p>'

And I want to deploy to AWS Lambda and Google Firebase. But I am really struggling with finding good examples and comprehensive documentation.

Maybe I am just not looking at the right place?
Thanks for any pointers.