API Integration
Load dynamic field options from external APIs and configure webhook submissions.
Dynamic Options API
Select, Multi-Select, and Radio fields can load their options from an external JSON API endpoint at form render time. Configure this using the dynamicOptions property:
"dynamicOptions": {
"url": "https://api.example.com/countries",
"method": "GET",
"headers": {
"Authorization": "Bearer {{API_KEY}}"
},
"labelKey": "name",
"valueKey": "iso_code",
"dependsOn": "region_field_name"
}The API must return a JSON array. Use labelKey and valueKey to specify which object properties map to the option's label and value. Use dependsOn to make the options depend on another field's value (for cascading dropdowns).
Submission Webhooks
Configure a webhook URL in Form Settings → Integrations → Webhooks. When a form is submitted, DynamicFormBuilder will POST the full submission JSON to your webhook URL within seconds. This enables real-time integration with Zapier, Make (formerly Integromat), Slack, or any custom backend.
// Webhook payload format
{
"event": "form.submission",
"form_id": "abc123",
"form_name": "Customer Feedback",
"submitted_at": "2024-01-15T10:30:00Z",
"submission": {
"full_name": "John Doe",
"email": "john@example.com",
"rating": 5,
"comments": "Great service!"
}
}Authentication
Webhook requests can be authenticated using an HMAC signature. Enable webhook signing in Form Settings → Integrations to generate a secret key. Each webhook request will include an X-DFB-Signature header containing the HMAC-SHA256 signature of the payload. Verify this signature on your server to confirm the request is genuine.
