Skip to main content

send

plugin.dynamicPanel.send(panelId: string, data: any): Promise<DynamicPanelResponse>

Pushes arbitrary data into the panel's iframe via postMessage. The iframe receives this in its window.addEventListener('message', ...) handler.

Parameters

ParameterTypeRequiredDescription
panelIdstringYesThe target panel
dataanyYesAny JSON-serializable payload

Returns

Promise<DynamicPanelResponse>

Example

import plugin from '@codebolt/plugin-sdk';

const result = await plugin.dynamicPanel.send('panelId', /* any */);
console.log(result);