Handling webhook retries when your AI agent takes 18 seconds to reply
We connected our support agent to Slack and WhatsApp webhooks using FastAPI.
Because a multi-step tool turn takes anywhere from 10 to 20 seconds, the webhook caller hits its 3-second timeout, assumes our server dropped the event, and retries the exact same payload 3 times. Our users end up getting the same answer three times in a row.
We don't want to stand up Kafka or Celery just for a handful of webhooks per minute. What's the cleanest lightweight pattern in FastAPI + Redis to return 200 OK immediately and make sure retries are ignored?