Last active
March 5, 2022 18:18
-
-
Save DavidDeCoding/1c988673012a936c97f2f22acc02a8c2 to your computer and use it in GitHub Desktop.
Building Coupon Reminders - Part 2 Serverless and Secured Image Storage and Processing - coupon_processor.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Coupon | |
def handler(event, context): | |
for event in event["Records"]: | |
if event["eventName"] == "ObjectCreated:Put": | |
image_full_name = event["s3"]["object"]["key"] | |
Coupon.process_and_store(image_full_name) | |
return |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment