A parks department wants AI-written confirmation emails when a reservation system creates a new booking. Which integration approach best triggers that GenAI step?
Select an answer to reveal the explanation.
Short Explanation
When you get a new shelter booking, you want the reservation system to ring a doorbell—not make a ranger retype the details into a chatbot. A webhook to Lambda is that doorbell, triggering AI-written confirmation emails when bookings are created.
Full Explanation
Use a webhook—for example, API Gateway plus Lambda—on booking-created events to invoke the GenAI drafting service. The reservation platform emits a domain event; the webhook handler calls Bedrock to draft the confirmation and hands the result to email. Rangers manually copying each booking into a chatbot fails automation and consistency, and is unrealistic during busy picnic seasons. A continuous full-table scan of all reservations every second from an EC2 cron loop wastes compute, can race with writes, and replaces event-driven integration with polling. Storing Bedrock credentials inside reservation database triggers with no intermediary service weakens secret management and couples the OLTP database to FM IAM material. Exam caveat: webhook handlers must validate signatures or mutual authentication so arbitrary callers cannot create confirmation emails. Keep prompts templated with booking fields, run Guardrails before sending, and design for at-least-once delivery with idempotent email keys per booking ID. Practical check: confirm booking-created events reach API Gateway and Lambda; verify Lambda’s role can invoke Bedrock only as needed; ensure credentials are not in the reservation database; monitor the DLQ and email bounce rates; and sample confirmations for accuracy against booking records.