Guide: Connecting AI Engine → Jambonz → FluentCRM
Turn Your WordPress Audio Chatbot into a Voice- & SMS-Powered CRM Machine
Overview
- AI Engine (Pro) gives you an on-site audio chatbot.
- Jambonz places/receives calls & texts.
- A lightweight “middleware” service glues them together and pushes data into FluentCRM.
Result → A visitor can: • Chat by voice → request a call/SMS
• Speak or text answers during that conversation
• See their FluentCRM profile auto-updated with tags, custom fields, notes, etc.
1. Prerequisites
| Item | Why |
|---|---|
| WordPress + AI Engine (Pro) | Audio chatbot & webhook support |
| Jambonz account (cloud or self-host) | Voice/SMS CPaaS |
| FluentCRM (free or pro) | WordPress-based CRM |
| Middleware server (Node, Python, etc.) | Receives webhooks & calls Jambonz + FluentCRM APIs |
| Public HTTPS URL (ngrok/Tunnel if testing locally) | Required for webhooks |
2. Configure AI Engine Audio Chatbot
- Install / activate AI Engine and upgrade to Pro.
- WP Admin →
Meow Apps ▸ AI Engine ▸ Chatbot
• Enable Realtime Audio Chatbot
• Craft a prompt such as “Hi! Want us to call or text you? Just say ‘Call me’ or ‘Text me’ with your phone number.” - Webhook / Function-call settings
• When the user provides a phone number + “call” or “text”, send a POST tohttps://your-middleware.com/ai-hook• Example payload structure AI Engine will emit:{ "action": "call", // or "sms" "phone": "+15551234567", "contact_email": "jane@ex.com", // if collected "conversation_id": "xyz123" }
3. Spin Up the Middleware (Node.js example)
# .env (never commit to Git)
JAMBONZ_ACCT=ACxxxxxxxx
JAMBONZ_KEY=key_xxxxxxxxx
JAMBONZ_APP=APxxxxxxxx # Outbound-call application SID
JAMBONZ_FROM=+15559876543 # Your Jambonz DID
FLUENTCRM_TOKEN=xxxxxxxxxxx
FLUENTCRM_URL=https://yourwp.com/wp-json/fluent-crm/v2
PORT=3000
// server.js
require('dotenv').config();
const express = require('express');
const axios = require('axios');
const app = express();
app.use(express.json());
/* ---------- Utility: update FluentCRM -------------- */
async function updateCRM(phone, data = {}) {
await axios.put(
`${process.env.FLUENTCRM_URL}/contacts/phone/${encodeURIComponent(phone)}`,
data,
{ headers: { Authorization: `Bearer ${process.env.FLUENTCRM_TOKEN}` } }
).catch(()=>{});
}
/* ---------- AI Engine webhook ---------------------- */
app.post('/ai-hook', async (req,res)=>{
const {action, phone, contact_email} = req.body;
// ensure contact exists or create
await updateCRM(phone, {
email: contact_email || `${phone}@example.com`,
phone,
tags: ['from_chatbot']
});
if (action === 'call') {
await axios.post(`https://api.jambonz.cloud/v1/Accounts/${process.env.JAMBONZ_ACCT}/Calls`, {
to: phone,
from: process.env.JAMBONZ_FROM,
application_sid: process.env.JAMBONZ_APP
},{
headers:{Authorization:`Bearer ${process.env.JAMBONZ_KEY}`}
});
} else if (action === 'sms') {
await axios.post(`https://api.jambonz.cloud/v1/Accounts/${process.env.JAMBONZ_ACCT}/Messages`, {
to: phone,
from: process.env.JAMBONZ_FROM,
body: "Thanks for reaching out! Reply with your preferred meeting time."
},{
headers:{Authorization:`Bearer ${process.env.JAMBONZ_KEY}`}
});
}
res.sendStatus(200);
});
/* ---------- Jambonz: gather results / SMS replies --- */
app.post('/jambonz-hook', async (req,res)=>{
const {from, speech, dtmf, text} = req.body; // depending on call or sms
const phone = from;
// Simple example: store last response in a custom field
await updateCRM(phone,{
meta: { last_response: speech || dtmf || text },
tags: ['replied']
});
res.sendStatus(200);
});
app.listen(process.env.PORT, ()=> console.log('middleware up'));
4. Create Your Jambonz Application
- Outbound Application
• Type: “voice”
• POST-GATHER URL →https://your-middleware.com/jambonz-hook
• JAML sample to collect DTMF or speech:
<?xml version="1.0" encoding="UTF-8"?>
<application>
<say>Hi there! Press 1 for sales, 2 for support.</say>
<gather action="/jambonz-hook" method="POST" input="speech dtmf" timeout="5"/>
<say>We didn't get your input. Goodbye.</say>
</application>
- SMS Webhook
• Your DID → SMS → Webhook URLhttps://your-middleware.com/jambonz-hook
5. Testing the Flow
- Visit the page with the AI Engine audio chatbot.
- Say: “Please call me at 555-123-4567.”
- Watch network logs:
• AI Engine →/ai-hook(phone + action)
• Middleware → Jambonz outbound call - During the call, press “1”.
• Jambonz →/jambonz-hookwithdtmf=1
• Middleware tags the contact replied + last_response=1 in FluentCRM. - Confirm in FluentCRM that the contact record shows the new tag & meta-field.
6. Security & Compliance Checklist
- Use HTTPS everywhere (Let’s Encrypt).
- Validate phone numbers (E.164) before dialing.
- Store API keys as environment variables.
- Add a secret token header on all webhooks and verify it.
- Obtain explicit consent for calls/texts; honor opt-outs (update tags like do-not-call).
7. Useful Links
- AI Engine docs – https://meowapps.com/ai-engine/
- Jambonz docs – https://www.jambonz.org/docs/
- FluentCRM REST API – https://fluentcrm.com/docs/rest-api/
- E.164 phone validation – https://libphonenumber.appspot.com/
Final Thoughts
With about 100 lines of middleware code you have:
- Conversational voice AI on WordPress.
- Real phone calls & SMS handled by an open-source CPaaS.
- Automatic CRM enrichment inside FluentCRM.
Scale it up with NLP, multi-step IVRs, appointment booking APIs—your chatbot is now a true omnichannel sales rep. Happy building!