CRM Sync
Bidirectional sync between Keva customer profiles and your CRM
Keva supports bidirectional sync with Salesforce and HubSpot, keeping your customer data in sync across systems automatically.
Overview
CRM sync connects your Keva customer profiles to your CRM contacts. When a customer submits a ticket, Keva can:
- Look up existing CRM records for context
- Create new contacts if they don't exist
- Update contact information bidirectionally
- Enrich AI responses with CRM data
Supported Platforms
| Platform | Objects Synced | Sync Direction |
|---|---|---|
| Salesforce | Contacts, Accounts | Bidirectional |
| HubSpot | Contacts, Companies | Bidirectional |
How Sync Works
Outbound (Keva to CRM)
When a customer profile is created or updated in Keva:
- Keva checks if the customer has a linked CRM record
- If linked, updates the existing record
- If not linked, searches by email
- If found, links and updates; if not found, creates new contact
Inbound (CRM to Keva)
When a contact is updated in your CRM:
- CRM sends webhook notification to Keva
- Keva looks up the linked customer profile
- Updates Keva profile with new data
- Changes are logged in sync history
Field Mapping
Field mapping controls how data flows between Keva and your CRM.
Default Mappings
These fields sync automatically without configuration:
| Keva Field | Salesforce | HubSpot |
|---|---|---|
| Name | FirstName + LastName | firstname + lastname |
| Phone | Phone | phone |
| Company | Company | company |
| Job Title | Title | jobtitle |
Custom Mappings
Map any Keva field to any CRM field:
- Go to Settings then CRM Sync
- Select the CRM object (Contact, Account, etc.)
- Click Add Mapping
- Choose Keva field and CRM field
- Set sync direction
- Optionally add transformation
Sync Direction Options
| Direction | Behavior |
|---|---|
| Bidirectional | Changes sync both ways (recommended) |
| To CRM | Keva updates CRM, but not vice versa |
| From CRM | CRM updates Keva, but not vice versa |
Field Transformations
Apply transformations during sync:
| Transform | Description | Example |
|---|---|---|
| Uppercase | Convert to uppercase | "john" to "JOHN" |
| Lowercase | Convert to lowercase | "JOHN" to "john" |
| Trim | Remove whitespace | " john " to "john" |
| Default | Use fallback value | null to "Unknown" |
| Split Name | Extract first/last | "John Doe" to "John" or "Doe" |
| Date Format | Convert date format | ISO to YYYY-MM-DD |
| Value Map | Map discrete values | "vip" to "Premium" |
Sync Triggers
Automatic Triggers
- Customer profile created (from new ticket)
- Customer profile updated
- Webhook received from CRM
Manual Triggers
- Click Sync Now on customer profile
- Run batch sync from settings
- API trigger via
/api/crm/sync
Conflict Resolution
When the same field is updated in both systems:
- Last write wins - Most recent update takes precedence
- Timestamp comparison - Keva compares
lastCrmSyncAtwith CRM modification time - Logged for review - Conflicts appear in sync history
Sync History
All sync operations are logged:
- Operation: create, update, delete, link
- Direction: to_crm, from_crm
- Status: pending, success, failed
- Changes: What fields changed
- Error: If failed, why
View sync history in Settings then CRM Sync then History.
Batch Sync
Sync all customers at once:
- Go to Settings then CRM Sync
- Click Batch Sync
- Confirm (this may take several minutes)
- Monitor progress in sync history
Batch sync processes up to 100 customers at a time and is rate-limited to avoid CRM API limits.
Security
Credentials
- OAuth tokens stored encrypted (AES-256-GCM)
- Tokens refreshed automatically
- Never stored in plain text
Webhooks
- Salesforce: HMAC signature validation
- HubSpot:
X-HubSpot-Signature-v3verification - All webhook endpoints require authentication
Audit Trail
Every sync operation is logged with:
- Tenant ID
- Customer profile ID
- CRM record ID
- Request/response payloads
- Timestamp
Getting Started
- Connect your CRM - Salesforce or HubSpot
- Configure field mappings - Map Keva fields to CRM fields
- Enable sync - Turn on automatic sync
- Test - Sync a single customer to verify
- Batch sync - Sync existing customers