Enable Transformations
Transformations are configured per endpoint:1
Open your endpoint
Go to Dashboard → Developers → Webhooks and select an endpoint.
2
Navigate to Advanced
Click the Advanced tab.
3
Enable Transformations
Toggle Enable Transformation and click Edit to write your code.
Write a Transformation
Transformations declare ahandler function that receives the webhook object and returns a modified version.
Input properties
Output properties
Return the same object with modifications. You can also set:Examples
Redirect to custom URL
Route webhooks to a URL specified in the payload:Add custom headers
Include authentication or tracking headers:Filter events
Cancel delivery for specific conditions:Transform payload structure
Reshape the payload to match your system’s expected format:Change HTTP method
Some systems expect PUT instead of POST:Testing Transformations
Before saving, test your transformation against sample payloads:- Click Test in the transformation editor
- Select an event type or enter a custom payload
- Review the transformed output
- Verify the URL, method, headers, and payload are correct