system.util.sendMessage() perspective scripting

So, scope in this situation is a little tricky, but you have options. You could either supply a scope of 'session" and allow the “broadcast” to be heard by all Pages/Views in all Sessions (because you haven’t filtered this in any way at this point), or you could specify a scope of “page”. If you specify a scope of “page”, however, you MUST supply a sessionId argument as well, which means that you need to already know the session you want to target (potentially passed as part of the payload), or you need to supply logic to locate valid sessions which meet some sort of logical condition using system.perspective.getSessionInfo(). So scope is important, even if you supply a pageId - supplying that argument does not mean that we will locate an appropriate Page from available Sessions.