Methods and Events
Instance Methods
Note: If initializing a File Manager application, the only supported method is beePluginInstance.start()
without parameters.
Assuming that beePluginInstance
is the instance of your embedded builder application, here are the methods you can call:
Method | Description |
---|---|
| Starts the builder, loading the |
| Loads the JSON template string specified in the |
| Loads the JSON template string specified in the |
If you use a paid plan, you can hide the top toolbar and control the builder from your application’s user interface. For example, it’s up to you at that point to have buttons above or below the builder. Here’s some useful methods for this scenario:
Method | Description |
---|---|
| Triggers the message preview behavior within the builder. |
| Open/close the message preview behavior within the builder. |
| Controls the visibility of the structure outlines in the message editing portion of the builder. |
| Invokes the |
| Invokes the |
| Invokes the |
| Controls the visibility of sample content for merge tags in the message editing portion of the builder. |
Instance Events
The top toolbar displayed by default within the builder contains buttons that trigger certain actions. These are the callbacks that are triggered when the buttons are clicked.
Event | Description | Returned values |
---|---|---|
onSave | Fired when the Save button is clicked. | JSON and HTML documents |
onSaveAsTemplate | Fired when “Save as template” is clicked. | JSON document |
onAutoSave | Fired automatically based on | JSON document |
onSend | Fired when the “Send a test button” is clicked. | HTML document |
onLoad | Fired when the JSON is loaded in the builder. | JSON document |
onError | Fired every time an error occurs. | Error message |
onPreview | Fired every time the preview button is pressed. | Status (Boolean) |
onTogglePreview | Fired every time the preview is opened or closed. | Status (Boolean) |
onChange | Fired every time a change on the message is performed. | |
onComment | Fired every time a thread or comment changes. | |
onFilePickerInsert | Fired when the “insert” button is clicked. This property must be defined by the host application for the insert button to appear within the user interface. Available for File Manager applications only. | Object with file info |
onFilePickerCancel | Fired when the “X” button is clicked. This property must be defined by the host application for the cancel “X” button to appear within the user interface. Available for File Manager applications only. | None |
Last updated