diff --git a/function/notification/notification.py b/function/notification/notification.py index 887cbd9..383ef44 100644 --- a/function/notification/notification.py +++ b/function/notification/notification.py @@ -1,13 +1,13 @@ -import json import fcm def lambda_handler(event, context): for record in event["Records"]: payload = record["kinesis"]["data"] + token = payload["registration_token"] title = payload["title"] body = payload["body"] - result = fcm.send_message(token, title, body) - return {"statusCode": 200, "body": json.dumps(result)} + result = fcm.send_message(token, title, body) + print(f'"statusCode": 200, "body": {result}')