AI Import Settings
The AI Import Settings tab configures the AI-powered email import feature, which allows customers to send declaration documents via email for automated processing and draft creation using Claude AI.
Overview
The AI Import feature enables:
- Customers email declaration documents (invoices, packing lists, etc.) to a unique email address
- MailerSend receives and routes the email to Borderbolt
- Claude AI extracts declaration data from PDF attachments
- System creates draft declaration with extracted data
- User reviews in AI Workbench, makes corrections, and finalizes
Enable AI Import
AI Import Enabled
Master toggle to enable or disable the AI import feature.
When Enabled:
- Unique inbound email address is generated for your organization
- Incoming emails are processed and queued
- AI extraction runs on attachments
- Draft declarations are created in AI Workbench
When Disabled:
- Inbound email address remains but emails are not processed
- Existing drafts are retained
- AI extraction is paused
- Incoming emails are logged but not acted upon
Email Import Configuration
Auto-Process Emails
Automatically process incoming emails without manual approval.
When Enabled:
- Emails are processed immediately upon receipt
- AI extraction runs automatically
- Drafts created without user intervention
- Fastest turnaround time
When Disabled:
- Emails are queued for manual review
- User must approve before AI processing
- More control over what gets processed
- Useful for testing or quality control
Recommended: Enable for production use after testing period.
Auto-Create Confidence Threshold
The minimum AI confidence score required to automatically create a draft declaration.
Default: 0.85 (85% confidence)
How It Works:
- AI extraction returns confidence score (0.0 to 1.0)
- If score ≥ threshold, draft is auto-created
- If score < threshold, requires manual review before creation
Threshold Guidelines:
| Threshold | Behavior | When to Use |
|---|---|---|
| 0.70 | Lenient - creates drafts with moderate confidence | High volume, user reviews all drafts anyway |
| 0.85 | Balanced - default setting | Standard production use |
| 0.95 | Strict - only very confident extractions | High accuracy required, low volume |
Best Practice: Start with default (0.85) and adjust based on draft accuracy. Monitor AI Workbench for frequently rejected drafts.
Send Confirmation Emails
Send email confirmations to senders when their email is processed.
When Enabled:
- Sender receives confirmation email after processing
- Includes draft declaration number
- Links to customer portal (if enabled)
- Professional customer experience
When Disabled:
- No confirmation sent
- Silent processing
- Reduces email volume
Confirmation Email Includes:
- Subject: “Declaration Import Received - [Reference]”
- Declaration draft number
- Estimated processing time
- Link to track status (customer portal)
- Contact information for questions
Default Settings
Default Customer
The customer to assign to imported declarations when sender cannot be matched.
Matching Logic:
- Borderbolt attempts to match sender email to existing customer
- If match found, declaration assigned to that customer
- If no match, uses default customer
When to Set:
- You have a primary customer for imports
- Most imports come from the same customer
- Fallback for unmatched senders
Best Practice: Create a customer named “Import Pending” or “Unassigned” as default, then manually reassign after review.
Default Declarant
The declarant to assign to imported declarations.
Purpose:
- Pre-fills declarant field on draft declarations
- Ensures correct EORI and customs registration
- Required for declaration submission
When to Set:
- You operate with single declarant
- Most imports use the same declarant
- Simplifies draft review process
Multiple Declarants: If you operate with multiple declarants, leave blank and assign manually during review.
Confirmation Email Template
Customize Confirmation Email
Configure the content and appearance of confirmation emails sent to customers.
Customizable Elements:
- Subject line
- Email body text
- Branding and logo
- Footer information
- Call-to-action links
Available Placeholders:
{draft_number}- Draft declaration number{customer_name}- Customer name{reference}- Email subject or reference{date}- Import date{company_name}- Your company name{portal_link}- Link to customer portal
Example Template:
Subject: Declaration Import Received - {draft_number}
Dear {customer_name},
We have received your declaration documents and created draft {draft_number} for review.
Reference: {reference}
Received: {date}
Our team will review the draft and finalize your declaration shortly. You can track the status in the customer portal:
{portal_link}
If you have questions, please contact us at declarations@yourdomain.com.
Best regards,
{company_name}Allowed Senders Filter
Email Address Whitelist
Restrict AI import to specific sender email addresses or domains.
Format Options:
- Specific emails:
customer@example.com - Domain wildcards:
*@example.com - Multiple entries: Comma-separated
Examples:
customer@example.com, supplier@acme.com
*@example.com
*@example.com, *@acme.com, specific@other.comWhen to Use:
- Security: Only allow known customers
- Compliance: Restrict to authorized senders
- Testing: Limit to internal email addresses during setup
When Left Blank: All senders are allowed (not recommended for production).
Security Best Practice: Always configure allowed senders in production to prevent unauthorized import attempts and potential spam/abuse.
Weight Distribution
Weight Distribution Enabled
Automatically distribute total weight across declaration lines.
When Enabled:
- AI extracts total net weight from documents
- Weight is distributed proportionally across line items
- Each line receives weight based on quantity or value
- Saves manual weight entry
When Disabled:
- Weight per line must be entered manually
- AI does not calculate weight distribution
- Useful when line-specific weights are available
Distribution Methods:
- By Quantity: Weight distributed based on quantity ratios
- By Value: Weight distributed based on line value ratios
- Equal: Weight divided equally across lines
Net Weight Calculation
Net Weight Calculation Enabled
Calculate net weight from gross weight using a percentage.
When Enabled:
- AI extracts gross weight from documents
- Net weight calculated as percentage of gross
- Useful when net weight not explicitly stated
When Disabled:
- AI must find net weight directly in documents
- No calculation performed
- More accurate but requires explicit data
Net Weight Calculation Method
Currently supports: Percentage
Net Weight = Gross Weight × (Percentage / 100)
Percentage Value
The percentage of gross weight to use for net weight calculation.
Default: 90 (90% of gross weight)
Example:
- Gross weight: 1000 kg
- Percentage: 90%
- Net weight: 900 kg
Industry Standards:
- General cargo: 85-95%
- Palletized goods: 90-95%
- Heavy packaging: 75-85%
Best Practice: Adjust based on your typical packaging ratios. Review and correct in AI Workbench if needed.
Inbound Email Address
Unique Email Address
Each organization receives a unique, auto-generated email address for AI imports.
Format: {uuid}@aideclarations.borderbolt.com
Example: a7f3e2d1-4c5b-6789-0abc-def123456789@aideclarations.borderbolt.com
Characteristics:
- UUID-based for uniqueness
- Cannot be changed (permanent per organization)
- Automatically configured with MailerSend
- Subdomain:
aideclarations.borderbolt.com
How to Use:
- Copy the email address from Settings
- Share with customers who will submit declarations
- Customers forward/send declaration documents to this address
- Borderbolt automatically processes incoming emails
Email Subdomain: The subdomain aideclarations.borderbolt.com is configured globally. It cannot be customized per organization.
MailerSend Integration
Borderbolt uses MailerSend to handle inbound email routing.
How It Works
- Customer sends email to your unique address
- MailerSend receives email and parses content/attachments
- MailerSend sends webhook to Borderbolt with email data
- Borderbolt processes webhook and queues AI extraction
- Claude AI extracts data from PDF attachments
- System creates draft declaration in AI Workbench
- Confirmation email sent to customer (if enabled)
Environment Configuration
MailerSend integration is configured globally by your system administrator.
Note: These settings are configured at the application level and cannot be changed per organization.
Upload Size Configuration
Important: If you encounter errors when uploading large email attachments, contact your system administrator to increase the maximum upload size to at least 50MB.
Best Practices
Initial Setup
- Start with auto-process disabled to manually review initial emails
- Set high confidence threshold (0.95) during testing
- Configure allowed senders with test email addresses only
- Enable confirmation emails to verify routing works
- Test with sample documents before sharing with customers
- Lower threshold gradually (0.95 → 0.85) based on accuracy
Production Use
- Enable auto-process for efficiency
- Use default threshold (0.85) for balanced accuracy
- Whitelist customer domains for security
- Monitor AI Workbench for draft quality
- Review rejected drafts to improve confidence
- Adjust weight calculation based on industry
Customer Communication
Share with Customers:
- Unique email address for imports
- Supported document types (PDF, Excel, etc.)
- Expected document format (invoice, packing list, etc.)
- Turnaround time expectations
- Contact information for questions
Document Requirements:
- PDF format preferred for best AI extraction
- Clear, legible scans (not photos)
- Complete information (HS codes, values, weights)
- Invoice and packing list together in one email
Updating Settings
- Navigate to Settings → AI Import
- Toggle “AI Import Enabled” on
- Configure auto-process, threshold, and defaults
- Set allowed senders filter
- Customize confirmation email template
- Save changes (auto-save on blur)
- Copy inbound email address and share with customers
Permissions
To edit AI Import settings, users must have the Settings permission. This is typically assigned to:
- Admin role
- Manager role
To review and approve drafts, users must have the AI Import permission.
Related Configuration
- Email Settings - Configure outbound email for confirmations
- Notification Settings - Control notification preferences
- Customers - Manage customer email addresses for matching
Troubleshooting
Emails Not Being Processed
Problem: Customer sends email but no draft created.
Solutions:
- Verify AI Import is enabled in settings
- Check sender is in allowed senders list (if configured)
- Review email has PDF attachments
- Contact your administrator to check system logs
- Contact your administrator to verify the email webhook is configured correctly
- Test with internal email first
Low Confidence Scores
Problem: AI extractions consistently below threshold.
Solutions:
- Review document quality (clear scans, not photos)
- Ensure documents contain all required information
- Check PDF is text-based, not scanned image
- Verify document language is supported (EN, NL, DE, PL)
- Consider lowering threshold temporarily
- Manually review and correct to train expectations
413 Payload Too Large
Problem: Email import fails with upload size error.
Solution: Contact your system administrator to increase the maximum upload size to at least 50MB.
Wrong Customer Assigned
Problem: Draft assigned to incorrect customer.
Solutions:
- Verify sender email matches customer email in system
- Check default customer is set appropriately
- Add sender email to correct customer record
- Use allowed senders filter to limit matching
- Manually reassign in AI Workbench after creation
Confirmation Emails Not Sent
Problem: Drafts created but customers don’t receive confirmation.
Solutions:
- Verify “Send Confirmation Emails” is enabled
- Check email settings are configured (Settings → Email)
- Test email functionality (Settings → Email → Test Email)
- Contact your administrator to check email logs for send failures
- Check customer email address is valid
- Contact your administrator to verify background processes are running