Zoom embedded in iframe: detect redirect to leave url

We’ve embedded a Zoom meeting with the web sdk on a seperate site and embedded then this site in an iframe on our site. I know this is not the recommended way, but the web sdk could not cover our requirements. As we need to integrate the meeting in a page and we don’t want to open the meeting in full screen mode.
Now we want to redirect the whole page when someone leaves the meeting or the meeting ends instead of opening the leave url in the iframe. However, I don’t want the page to be redirected on a refresh. Is there any way to detect when Zoom loads the leave url, a participant leaves a meeting or a meeting ends?
Thank you for your reply!

Hey @kim.s,

Thank you for reaching out to the Zoom Developer Forum. The best option here is likely to listen for changes to the iframe src property using the onload event. If the URL changes to your redirect URL, you can redirect the entire page as needed from there. I found a StackOverflow post that goes over this:

Let me know if that helps.

Thanks,
Max

Thanks @MaxM , this post has helped me a lot, especially this answer.

Hey @kim.s,

I’m glad to hear that answered your questions! If you encounter any further issues or questions, please don’t hesitate to reach out.

Thanks,
Max