2604 Incoming Webhooks
Incoming Webhooks
Overview
Incoming webhooks allow external systems to send data directly into your Tadabase application. They're the bridge that connects your website forms, payment processors, third-party services, and other external systems to Tadabase, enabling automatic record creation and updates without manual data entry.
This article provides a comprehensive, hands-on guide to setting up, configuring, and troubleshooting incoming webhooks in Tadabase.
What Incoming Webhooks Do
Incoming webhooks transform external events into Tadabase records:
The Transformation Process
- Event occurs: Something happens in external system (form submission, payment, etc.)
- External system sends POST request: Data sent to your Tadabase webhook URL
- Tadabase receives data: Webhook endpoint accepts the request
- Data mapping: Incoming fields mapped to Tadabase table fields
- Record creation: New record created in specified table
- Optional actions: Trigger additional rules or notifications
Common Use Cases
1. Form submissions- Website contact forms → Create leads
- Registration forms → Create customer accounts
- Survey responses → Create survey records
- Application forms → Create applicant records
- Stripe payments → Create transaction records
- PayPal notifications → Update order status
- Subscription renewals → Update membership records
- Failed payments → Create alert records
- Shopify orders → Create order records
- WooCommerce purchases → Update inventory
- Cart abandonment → Create follow-up tasks
- Product reviews → Create review records
- Zapier automations → Create various records
- IoT devices → Send sensor data
- Mobile apps → Submit data to Tadabase
- API integrations → Receive updates from partners
Setting Up Incoming Webhooks
Let's walk through the complete setup process:
Step 1: Create Incoming Webhook
- Navigate to webhooks:
- Go to Builder → Settings → Webhooks
- Click Incoming Webhooks tab
- Add new webhook:
- Click Add Incoming Webhook
- Give it a descriptive name (e.g., "Contact Form Submissions")
- Select target table:
- Choose which table will receive the data
- Example: "Leads" table for contact form
- Choose action:
- Create new record: Always create new record
- Update existing record: Update based on unique identifier
- Create or update: Update if exists, create if not
- Save to generate URL:
- Click Save
- Tadabase generates unique webhook URL
- Example:
https://api.tadabase.io/webhooks/abc123def456
Step 2: Configure Field Mapping
Purpose: Tell Tadabase which incoming data goes into which table fields.- View incoming fields:
- See list of fields in target table
- Each field can be mapped to incoming webhook data
- Map fields:
- For each table field, specify the corresponding webhook field
- Use exact field names from incoming payload
- Case-sensitive matching
- Example mapping:
Tadabase Field Webhook Field First Name first_name Last Name last_name Email email Company company Phone phone - Nested field mapping:
- Use dot notation for nested objects
- Example:
customer.email,address.city
- Array handling:
- Access array elements by index
- Example:
items[0].name - Or map entire array to connection field
Step 3: Configure Authentication (Optional but Recommended)
Why authentication matters:- Prevents unauthorized webhook submissions
- Verifies webhooks come from legitimate source
- Protects against malicious data injection
- Generate a secret key in Tadabase
- Provide secret to external service
- External service includes signature in webhook
- Tadabase verifies signature before processing
- Generate API key in Tadabase
- External service includes key in Authorization header
- Example:
Authorization: Bearer YOUR_API_KEY
- Set username and password
- External service includes credentials
- Less secure, use only if required by external service
Step 4: Test the Webhook
Using webhook testing tools:- Prepare test payload:
{ "first_name": "John", "last_name": "Smith", "email": "john@email.com", "company": "Acme Corp", "phone": "555-1234" } - Send test request using cURL:
curl -X POST https://api.tadabase.io/webhooks/YOUR_WEBHOOK_ID \ -H "Content-Type: application/json" \ -d '{ "first_name": "John", "last_name": "Smith", "email": "john@email.com", "company": "Acme Corp", "phone": "555-1234" }' - Or use Postman:
- Create new POST request
- Enter webhook URL
- Set header:
Content-Type: application/json - Enter JSON body with test data
- Click Send
- Verify in Tadabase:
- Check target table for new record
- Verify all fields populated correctly
- Review webhook logs for any errors
Step 5: Configure External Service
Once webhook works in testing, configure the external service:- Locate webhook settings in external service
- Most services have webhook or API notification settings
- Look for "Webhooks", "Notifications", "Integrations", or "API"
- Add webhook URL
- Paste your Tadabase webhook URL
- Select events to trigger webhook (if applicable)
- Configure authentication
- Add API key or secret if required
- Configure headers as needed
- Test from external service
- Use their test/send feature if available
- Perform actual action (submit form, make payment, etc.)
- Verify data arrives in Tadabase
Creating Records from Webhooks
Let's explore different record creation scenarios:
Simple Record Creation
Scenario: Contact form submission creates lead record. Incoming payload:{
"name": "John Smith",
"email": "john@email.com",
"phone": "555-1234",
"message": "Interested in your product",
"source": "website"
}
Field mapping:
- Name → Full Name field
- Email → Email field
- Phone → Phone field
- Message → Notes field
- Source → Lead Source field
- Status: Set default "New Lead"
- Created Date: Auto-populated by Tadabase
- Assigned To: Use record rule to auto-assign
Complex Data Structures
Scenario: E-commerce order with nested customer and items data. Incoming payload:{
"order_id": "ORD-12345",
"order_date": "2026-01-28T10:30:00Z",
"customer": {
"id": "CUST-789",
"name": "Jane Doe",
"email": "jane@email.com"
},
"items": [
{
"product_id": "PROD-123",
"name": "Widget",
"quantity": 2,
"price": 49.99
}
],
"totals": {
"subtotal": 99.98,
"tax": 8.00,
"total": 107.98
}
}
Mapping nested fields:
- Order ID → order_id
- Customer Name → customer.name
- Customer Email → customer.email
- Subtotal → totals.subtotal
- Tax → totals.tax
- Total → totals.total
- Option 1: Store as JSON in long text field
- Option 2: Create separate line item records using record rules
- Option 3: Concatenate item names into single field
Conditional Record Creation
Scenario: Only create record if certain conditions are met. Implementation:- Webhook always receives data
- Use record rule to check conditions
- If conditions not met, delete the record
- Or mark as "Pending Review" for manual processing
- Only create if email domain is corporate (not gmail, yahoo, etc.)
- Only create if order total exceeds threshold
- Only create if all required fields are present
Creating Related Records
Scenario: Single webhook creates records in multiple tables. Example: Order webhook creates both Order and Customer records. Implementation:- Primary webhook: Creates Order record
- Record rule on Order: When Order created:
- Check if Customer exists (search by email)
- If not exists, create Customer record
- Link Customer to Order
- Additional rules: Create line items, update inventory, etc.
- Single webhook endpoint to maintain
- Complex data structures handled automatically
- All related records created in proper sequence
Webhook Logging
Tadabase provides detailed logging for all incoming webhooks:
Accessing Logs
- Go to Builder → Settings → Webhooks
- Click Incoming Webhooks tab
- Select the webhook you want to review
- Click View Logs
Log Information
Each log entry includes:- Timestamp: Exact date and time webhook received
- Status: Success (green) or Failed (red)
- Payload: Complete JSON data received
- Headers: HTTP headers included in request
- Response: What Tadabase sent back (200, 400, 500, etc.)
- Record created: Link to record if successful
- Error message: Detailed error if failed
- Processing time: How long processing took
Using Logs for Debugging
Troubleshooting failed webhooks: 1. Check the payload:- Is the JSON properly formatted?
- Are field names spelled correctly?
- Are all required fields present?
- Are data types correct (string, number, etc.)?
- "Field not found": Mapping incorrect, check field names
- "Validation failed": Data doesn't meet field requirements
- "Authentication failed": Webhook secret/key incorrect
- "Record not created": Check record rules, may be blocking
- Look at successful webhook payload
- Compare to failed payload
- Identify differences
Log Retention
- Logs retained for 30 days
- Export important logs for long-term storage
- Use for compliance and audit purposes
Error Handling
Proper error handling ensures reliable webhook processing:
Common Errors and Solutions
1. Invalid JSON format- Error: "Unable to parse JSON"
- Cause: Malformed JSON in payload
- Solution:
- Validate JSON using online validator
- Check for missing commas, brackets, quotes
- Ensure external service sending valid JSON
- Error: "Required field 'email' is missing"
- Cause: Payload doesn't include all required fields
- Solution:
- Make Tadabase fields optional if external data may be missing
- Or configure external service to always include required fields
- Or use default values in Tadabase
- Error: "Expected number, received string"
- Cause: Field expecting number but gets text
- Solution:
- Ensure external service sends correct data types
- Use text field in Tadabase, convert using record rule
- Add data transformation in external service
- Error: "Email format invalid"
- Cause: Data doesn't meet field validation rules
- Solution:
- Adjust validation rules to accept incoming format
- Or clean data in external service before sending
- Or use record rule to clean data after receipt
- Error: "Unauthorized" (401) or "Forbidden" (403)
- Cause: Invalid or missing authentication
- Solution:
- Verify webhook secret/key is correct
- Check authentication headers are properly configured
- Ensure external service includes auth in each request
- Issue: Multiple webhooks creating duplicate records
- Cause: External service sending same webhook multiple times
- Solution:
- Use "Create or Update" mode with unique identifier
- Add record rule to check for duplicates before creating
- Implement idempotency using external transaction ID
Retry Behavior
When webhook fails:- External service typically retries automatically
- Retry schedule varies by service (immediate, 5min, 15min, etc.)
- Tadabase logs each attempt
- Once succeeds, retries stop
- Design webhooks to be idempotent (safe to process multiple times)
- Check if record already exists before creating
- Use unique identifiers to prevent duplicates
Failure Notifications
Set up alerts for webhook failures:- Configure email notifications for failed webhooks
- Set threshold (alert after X consecutive failures)
- Include error details in notification
- Alert appropriate team members
- Some failures can be automatically retried
- Use scheduled task to reprocess failed webhooks
- Check webhook logs for failures
- Attempt to create records from logged payloads
Advanced Techniques
Take your incoming webhook skills to the next level:
Data Transformation
Problem: Incoming data format doesn't match Tadabase needs. Solutions: 1. Use record rules for transformation:- Webhook creates record with raw data
- Record rule processes and transforms data
- Updates fields with cleaned/formatted values
- Incoming: Various formats (555-1234, (555) 1234, 5551234)
- Record rule: Strip non-numeric characters, format as (555) 123-4567
- Create hidden fields to store raw webhook data
- Use calculated fields to transform for display
- Keeps original data for reference
Conditional Routing
Problem: Different webhook types should create different records. Solution: Use event type field to route appropriately. Example: Payment webhook handling Incoming payload includes event type:{
"event": "payment.succeeded",
"data": {...}
}
// or
{
"event": "payment.failed",
"data": {...}
}
Implementation:
- Single webhook receives all payment events
- Map
eventfield to "Event Type" in Tadabase - Record rule checks Event Type:
- If "payment.succeeded" → Create transaction, update order
- If "payment.failed" → Create alert, notify customer service
- If "payment.refunded" → Update accounting, adjust inventory
Batch Webhook Processing
Problem: External service sends multiple records in single webhook. Example payload:{
"leads": [
{"name": "John", "email": "john@email.com"},
{"name": "Jane", "email": "jane@email.com"},
{"name": "Bob", "email": "bob@email.com"}
]
}
Solution options:
1. Store as single record:
- Save entire array as JSON in long text field
- Use scheduled task to parse and create individual records later
- Webhook creates temporary processing record
- Record rule loops through array
- Creates individual record for each item
- Deletes temporary record when done
Webhook Chaining
Scenario: Incoming webhook triggers outgoing webhooks. Example: Order processing workflow- External order webhook → Creates Order in Tadabase
- Record rule triggers → Outgoing webhook to warehouse system
- Another outgoing webhook → Notification to customer
- Another outgoing webhook → Update accounting system
- Single incoming webhook triggers multiple downstream actions
- Tadabase orchestrates complex workflows
- All integrations logged and monitored centrally
Data Enrichment
Scenario: Enhance incoming data with additional information. Example: Lead enrichment workflow- Form webhook creates Lead with basic info (name, email)
- Record rule triggers pipe to lookup company information
- Pipe uses email domain to find company details
- Record updated with company name, size, industry
- Additional rule assigns lead to appropriate sales rep based on industry
Real-World Examples
Let's look at complete, real-world webhook implementations:
Example 1: Stripe Payment Webhook
Objective: Process payment notifications from Stripe. Setup:- Create Transactions table in Tadabase:
- Transaction ID (text, unique)
- Customer Email (email)
- Amount (currency)
- Status (dropdown: Succeeded, Failed, Refunded)
- Payment Method (text)
- Created Date (date/time)
- Create incoming webhook:
- Name: "Stripe Payments"
- Target table: Transactions
- Action: Create or Update (based on Transaction ID)
- Configure field mapping:
Tadabase Field Stripe Webhook Field Transaction ID data.object.id Customer Email data.object.receipt_email Amount data.object.amount Status data.object.status Payment Method data.object.payment_method_details.type - Configure webhook in Stripe:
- Go to Stripe Dashboard → Developers → Webhooks
- Add endpoint with your Tadabase webhook URL
- Select events:
payment_intent.succeeded,payment_intent.payment_failed - Copy webhook signing secret
- Add signing secret to Tadabase webhook authentication
- Add record rules for automation:
- When status = "Succeeded" → Send receipt email
- When status = "Failed" → Alert customer service
- Update related Order record status
Example 2: Website Contact Form
Objective: Capture leads from website contact form. HTML form example:<form id="contactForm">
<input type="text" name="name" required>
<input type="email" name="email" required>
<input type="text" name="company">
<input type="tel" name="phone">
<textarea name="message" required></textarea>
<button type="submit">Submit</button>
</form>
<script>
document.getElementById('contactForm').addEventListener('submit', function(e) {
e.preventDefault();
// Get form data
const formData = {
name: document.querySelector('[name="name"]').value,
email: document.querySelector('[name="email"]').value,
company: document.querySelector('[name="company"]').value,
phone: document.querySelector('[name="phone"]').value,
message: document.querySelector('[name="message"]').value,
source: 'Website Contact Form',
submitted_at: new Date().toISOString()
};
// Send to Tadabase webhook
fetch('https://api.tadabase.io/webhooks/YOUR_WEBHOOK_ID', {
method: 'POST',
headers: {
'Content-Type': 'application/json'
},
body: JSON.stringify(formData)
})
.then(response => {
if (response.ok) {
alert('Thank you! We will contact you soon.');
document.getElementById('contactForm').reset();
} else {
alert('Sorry, there was an error. Please try again.');
}
});
});
</script>
Tadabase configuration:
- Create Leads table
- Map form fields to table fields
- Add record rule to auto-assign leads to sales reps
- Send confirmation email to lead
- Notify assigned sales rep
Example 3: Zapier Integration
Objective: Create Tadabase records from various Zapier triggers. Setup in Tadabase:- Create incoming webhook
- Copy webhook URL
- Configure field mapping for expected Zapier data
- Create new Zap
- Choose trigger (Google Forms, Gmail, Slack, etc.)
- Add action: Webhooks by Zapier
- Choose POST
- Enter Tadabase webhook URL
- Map fields from trigger to webhook payload
- Test and activate
- Trigger: New Google Form response
- Action: POST to Tadabase webhook
- Field mapping: Form questions → Tadabase fields
- Result: Form responses automatically create Tadabase records
Security Best Practices
Protect your incoming webhooks with these security measures:
Authentication
- Always use webhook secrets: Verify authenticity of incoming requests
- Rotate secrets regularly: Change secrets periodically (quarterly or after staff changes)
- Use different secrets: Each webhook should have unique secret
- Secure storage: Store secrets securely, never in code or public repos
Data Validation
- Validate all inputs: Never trust incoming data
- Type checking: Ensure fields are expected data types
- Range validation: Check numbers are within acceptable ranges
- Format validation: Verify emails, URLs, dates are properly formatted
- Sanitize text: Remove potentially malicious content
Rate Limiting
- Implement limits: Prevent abuse with rate limits
- Monitor usage: Track webhook frequency
- Alert on anomalies: Unusual spike in webhooks may indicate attack
Monitoring
- Review logs regularly: Check for suspicious activity
- Set up alerts: Notify on failed authentication attempts
- Track patterns: Identify unusual sources or payloads
Troubleshooting Checklist
When webhooks aren't working, check these items:
Webhook Not Receiving Data
- ☐ Is webhook URL correct in external service?
- ☐ Is external service actually sending webhooks?
- ☐ Are webhooks enabled in external service?
- ☐ Is firewall blocking incoming requests?
- ☐ Check webhook logs - any requests received?
Authentication Failures
- ☐ Is webhook secret correct?
- ☐ Is authentication header formatted correctly?
- ☐ Does external service support the auth method?
- ☐ Check case sensitivity of headers
Records Not Creating
- ☐ Are all required fields mapped?
- ☐ Are field names spelled correctly (case-sensitive)?
- ☐ Is data format valid (JSON)?
- ☐ Are data types compatible?
- ☐ Check validation rules on fields
- ☐ Review record rules - any blocking creation?
Incorrect Data
- ☐ Verify field mapping is correct
- ☐ Check for nested fields (use dot notation)
- ☐ Review actual webhook payload in logs
- ☐ Compare expected vs actual structure
Best Practices Summary
Follow these guidelines for reliable incoming webhooks:
- Security first: Always use authentication
- Test thoroughly: Test with various scenarios before production
- Document everything: Document webhook configuration and mapping
- Monitor actively: Review logs regularly
- Handle errors gracefully: Plan for failures
- Idempotency: Design to handle duplicate webhooks safely
- Validate data: Never trust incoming data without validation
- Log everything: Comprehensive logging aids troubleshooting
Next Steps
You now have comprehensive knowledge of incoming webhooks. The next article covers outgoing webhooks—how to send data from Tadabase to external systems when specific events occur.
Key Takeaways
Remember these core concepts:
- Purpose: Receive data from external systems into Tadabase
- Setup: Create webhook, configure mapping, test thoroughly
- Field mapping: Use dot notation for nested data
- Security: Always use authentication, validate all inputs
- Logging: Use logs for debugging and monitoring
- Error handling: Plan for failures, design for idempotency
- Testing: Test with various scenarios before going live
Next: Article 7.6 - Outgoing Webhooks
We'd love to hear your feedback.