To get current exteriors list send this postMessage:
iframeRoomtodo.contentWindow.postMessage(JSON.stringify({action:"get_exteriorsList"}), "*");
After that planner will return "send_floorList" message:
<iframe
frameborder="0"
id="iframe"
src="https://example.com/planner/matconfig">
</iframe>
<script>
window.addEventListener("message", messageListener);
function messageListener(e) {
try {
const dataObj = JSON.parse(e.data);
if (dataObj.action === "send_exteriorsList") {
let exteriorsArray = data.exteriors;// Looks like: ['First exterior', 'Second exterior']
}
} catch (error) {
console.error("Error parse JSON string!");
}
}
</script>