Skip to content

Instantly share code, notes, and snippets.

@mushketyk
Created August 7, 2019 16:42
Show Gist options
  • Save mushketyk/b17bda90ac8c3eb60738df2604cfe118 to your computer and use it in GitHub Desktop.
Save mushketyk/b17bda90ac8c3eb60738df2604cfe118 to your computer and use it in GitHub Desktop.
import json
print('Loading function')
def lambda_handler(event, context):
#print("Received event: " + json.dumps(event, indent=2))
for record in event['Records']:
print(record['eventID'])
print(record['eventName'])
print("DynamoDB Record: " + json.dumps(record['dynamodb'], indent=2))
return 'Successfully processed {} records.'.format(len(event['Records']))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment