https://retellai.com/?utm_source=discord&utm_medium=seo logo
stopConversation() from retell-client-js-sdk doesn...
# ❓・bug-report
u
Anybody else experiencing this?
retell-client-js-sdk@^1.3.2
Copy code
import { RetellWebClient } from 'retell-client-js-sdk';

function WebCall() {
  let retellWebClient = new RetellWebClient();
  const [isCallActive, setIsCallActive] = useState(false);

  retellWebClient.on(ClientEventNames.conversationEnded, ({ code, reason }) => {
    console.log('Conversation ended with code "%d" and reason "%s"', code, reason);
    setIsCallActive(false);
  });

  retellWebClient.on(ClientEventNames.error, error => {
    console.error('Conversation error occurred', error);
    setIsCallActive(false);
  });

  async function toggleCall() {
    if (isCallActive) {
      retellWebClient.stopConversation();
      // stop doesn't work, so refresh the page instead
      window.location.reload();
    } else {
      // ... start the call
    }
  }
r
Could you try again?
i
We are also experiencing this issue on an MVP we are developing. When can we expect a solution?
u
Still broken
r
@Todd - Cofounder@Retell AI cc
t
seems working for me
u
yep!
a
any updates on this? Our front-end team was facing a similar issue
u
Just for reproducability, I'm using
next.js
not sure if that makes a difference
l
can't reproduce via next.js on my end. are you still exp this issue?
a
Yes
u
Solved by @arthurpex https://github.com/RetellAI/retell-client-js-sdk/issues/3 Thank you Arthur!!
a
No problem!! glad to help out