Inbound SMS webhook only gets called once per number

Hello,

We are trying to set up an SMS agent with our own hosted LLM. We have a phone number set up with an inbound SMS webhook and a chat agent attached to inbound SMS. When I first texted the agent’s number, I got an automated response from the chat agent, and a call into our webhook which was able to interact with the chat object via the API. That worked once, and now the webhook does NOT get called in response to in bound SMS messages from my phone. What could be the problem? It looks like we have everything set up correctly based on your support Ask AI bot responses.

Based on the available sources, there are several known issues and complexities with SMS inbound webhooks that match your situation.

The inbound webhook is only fired at the start of a conversation(1). For the webhook to fire again on subsequent messages, the chat conversation must properly transition to an end state(1).

There’s also a documented edge case: if a user replies to the chat after the conversation has ended, the agent will reply back but no webhook will fire and no chat ID is assigned to the new communication(1). This creates what’s described as a “ghost conversation without a log anywhere”(1).

Additionally, there’s a requirement that may not be obvious: the agent needs to have at least one post chat analysis variable configured, otherwise the webhook will not fire(1). This was verified by adding a post chat analysis variable (which caused the webhook to fire), then deleting it (which stopped the webhook from firing)(1).

Steps to resolve:

  1. Verify your chat agent has at least one post chat analysis variable configured(1)
  2. Ensure your previous conversation properly transitioned to an end state(1)
  3. Check if you’re replying to an ended conversation, which would trigger the ghost conversation issue(1)

If the webhook still doesn’t fire after verifying these configurations, there may be a caching or binding issue with your phone number configuration similar to what’s been reported with voice webhooks(2).

Hello @matt

The inbound webhook will execute only once per chat/call.

Thanks, is our use case a supported one? We aim to reply with SMS output from our own LLM. It’s hard to tell from the docs if this is something we can even do with Retell.

Unfortunately, we don’t support custom LLM for chat agents.