@@ -132,6 +132,8 @@ def lambda_handler(event, context):
132132
133133 certificates_results_messagens .append ({
134134 "order_id" : result .get ('participant' , {}).get ('event' , {}).get ('order_id' , "" ),
135+ "validation_code" : result .get ('participant' , {}).get ('validation_code' , "" ),
136+ "authenticity_verification_url" : result .get ('participant' , {}).get ('authenticity_verification_url' , "" ),
135137 "product_id" : result .get ('participant' , {}).get ('event' , {}).get ('product_id' , "" ),
136138 "product_name" : result .get ('participant' , {}).get ('event' , {}).get ('product_name' , "" ),
137139 "email" : result .get ('participant' , {}).get ('email' , "" ),
@@ -169,3 +171,34 @@ def lambda_handler(event, context):
169171 'message' : 'Erro ao gerar certificados'
170172 })
171173 }
174+
175+
176+ if __name__ == "__main__" :
177+ # Test event for local execution
178+ test_event = {
179+ "Records" : [
180+ {
181+ "body" : [
182+ {
183+ "order_id" : 2266 ,
184+ "first_name" : "Maxson" ,
185+ "last_name" : "Almeida Ferovante" ,
186+ "email" : "maxsonferovante@gmail.com" ,
187+ "phone" : "(48) 99223-8206" ,
188+ "cpf" : "" ,
189+ "city" : "Florianópolis" ,
190+ "product_id" : 316 ,
191+ "product_name" : "Evento de Teste" ,
192+ "certificate_details" : "In recognition of their participation in the 90st edition of the Python Floripa Community Meeting, held on Sep 27, 2025, in Florianópolis, Brazil, with a total duration of 5 hours." ,
193+ "certificate_logo" : "https://tech.floripa.br/wp-content/uploads/2025/03/logo-certificado.png" ,
194+ "certificate_background" : "https://tech.floripa.br/wp-content/uploads/2025/03/certificado-python-floripa.png" ,
195+ "order_date" : "2025-08-28 02:44:54" ,
196+ "checkin_latitude" : "-27.5460492" ,
197+ "checkin_longitude" : "-48.6227075" ,
198+ "time_checkin" : "2025-03-26 20:55:44"
199+ },
200+ ]
201+ }
202+ ]
203+ }
204+ lambda_handler (test_event , None )
0 commit comments