Skip to content

Instantly share code, notes, and snippets.

@chandra-prakash-meghwal
Last active December 7, 2022 10:14
Show Gist options
  • Save chandra-prakash-meghwal/e9a5f2255b4f365f6311ce7673db0d92 to your computer and use it in GitHub Desktop.
Save chandra-prakash-meghwal/e9a5f2255b4f365f6311ce7673db0d92 to your computer and use it in GitHub Desktop.
Python handler for AWS Lambda function
import json
def lambda_handler(event, context):
# TODO implement
user_name = event.get('name')
message = 'Hello {}'.format(user_name)
return {
'statusCode': 200,
'message': message,
'body': json.dumps('This message is from Lambda!')
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment