Skip to main content

Overview

When a user interacts with a widget, the widget fires an event through FormHostProvider. Each event type calls a specific endpoint and sends a JSON payload to your backend.

How It Works

Each section executes a single API endpoint:

Endpoint actionUsed by
runFormEventField changes, button clicks, table events, autocomplete
runFormUploadFilesFile upload widget
runFormDeleteFileEventFile deletion
runFormDownloadFileEventFile download
runFormGetLinkedFileEventFile preview
runFormGetLinkedFileMetaEventFile metadata
runFormGetLinkedFileByChunksChunked (large file) download
runFormGetPresignedUrlPresigned URL for large file preview
runLoadFormEventForm definition load

Common Fields

All runFormEvent requests share this base structure. Event-specific fields are noted in each section.

{
"pluginCode": "construct",
"formCode": "documents",
"guid": "550e8400-e29b-41d4-a716-446655440000",
"projectGuid": "38I9rEPw1BmxP75XcxgzD5WGOk1",
"pGuid": "38I9rEPw1BmxP75XcxgzD5WGOk1",
"formData": { "field1": "value1" },
"widgetsState": null,
"widgetName": "WIDGETNAME",
"widgetValue": null,
"widgetEvent": "eventName",
"widgetContext": {
"referer": "/forms/documents/550e8400",
"parentWidgetId": null,
"hasParentForm": false,
"originator": null,
"parent": null
}
}
note

widgetContext is transmitted as a JSON-encoded string on the wire. The values shown above are the deserialized structure.

Your backend identifies the event using widgetName and widgetEvent from the request body.