<aside>
๐ต
At a glance. All prices were checked on Sep 29, 2026. They don't include sales tax or shipping.
- One-time startup, Raspberry Pi route: about $218.23 at the lowest prices I could verify. If the HT813 comes from Grandstream Direct instead, it's about $243.41.
- One-time startup, spare-PC route (no Pi): about $69.38. That's the HT813, a phone cord, and one Ethernet cable.
- Monthly cost at 100 AI minutes: about $12.76 all-in. $3.58 of that is magicJack, which you already pay, so the new money is about $9.18 a month.
- At 300 minutes: about $28.76 all-in ($25.18 new). At 1,000 minutes: about $84.76 all-in ($81.18 new).
- Status: this is a plan only. Nothing has been bought, installed, or signed up for. It's a Budget item, and it waits until after THE GATE (the IRS 1023-EZ fee) is funded.
</aside>
<aside>
โ ๏ธ
Three changes to our earlier plan (found while checking sources today)
- FreePBX 17 won't install on a Raspberry Pi. Its official installer only runs on Debian 12 on a regular 64-bit Intel/AMD computer (amd64), and it refuses to run on ARM. So on the Pi we use plain Asterisk. FreePBX 17 is still a good choice if you use a spare PC with Debian 12.
- Asterisk isn't in the normal Debian 12 or 13 package lists. Debian only carries it for old Debian 11 (version 16) and for its test branches (version 22). So on the Pi we build Asterisk 22 from its official source code.
- xAI's SIP route needs a public web address. When a call reaches sip.voice.x.ai, xAI sends a webhook to your server, and that server must be reachable from the internet. That breaks our "no public server" rule. xAI also expects a number you own, and magicJack says its numbers stay theirs. So the main plan uses Asterisk AudioSocket plus a small bridge script on the Pi. The script opens an outgoing WebSocket to xAI, and no ports are opened inbound.
</aside>
1. Overview
Right now your magicJack turns internet calls into an ordinary phone line for your desk phone. This plan adds three small pieces so an AI assistant can answer that same number, while your desk phone keeps working.
- Grandstream HT813: a small box. Its FXO port plugs into magicJack's phone jack and "listens" to the line like a phone would. It turns each call into a computer call (SIP). Its FXS port gives your regular desk phone a place to plug in.
- Asterisk on a Raspberry Pi: free, open-source phone-system software on a tiny computer in the office. It answers the call, plays the "AI assistant, this call may be recorded" notice, and connects the caller to the AI.
- Bridge script plus xAI Grok Voice: a short program on the Pi. It streams the caller's voice to Grok Voice and plays Grok's spoken replies back. It can also save a message or lead.
Everything sits behind your router. The Pi only makes outgoing connections: to xAI, and later to Salesforce. Nobody on the internet can reach your phone system directly.
Diagram
flowchart LR
Caller["Caller (any phone)"] -->|"phone network"| MJ["magicJack<br>(stays on the router)"]
MJ -->|"RJ11 phone cord"| FXO["HT813 FXO port"]
Desk["Desk phone"] -->|"RJ11"| FXS["HT813 FXS port"]
FXO --- HT["Grandstream HT813"]
FXS --- HT
HT -->|"SIP over office network"| AST["Asterisk on Raspberry Pi"]
AST -->|"AudioSocket (inside the Pi)"| BR["Bridge script"]
BR -->|"outgoing secure WebSocket"| XAI["xAI Grok Voice"]
BR -.->|"optional, outgoing HTTPS"| SF["Salesforce"]
The same thing as a text flow: Caller โ phone network โ magicJack (on the router) โ phone cord โ HT813 FXO port โ office network (SIP) โ Asterisk on the Pi โ AudioSocket โ bridge script โ outgoing secure WebSocket โ xAI Grok Voice. The desk phone plugs into the HT813 FXS port and becomes extension "desk" on Asterisk.
Outbound calls go the other way: the AI asks the bridge script to place a call โ Asterisk โ HT813 FXO โ magicJack โ the person's phone.
Why this design is good
- It's safe by design. Everything is behind the router, all connections go out, and there's no public server and no port forwarding. That means almost no toll-fraud exposure. Also, magicJack only allows international calls with prepaid credits (magicJack terms ยง3b), so keep that balance at $0.
- It uses the line and number you already pay for.
- Your desk phone keeps working. If the HT813 loses power, Grandstream says its FXS port is hard-wired through to the FXO port ("lifeline"), so the desk phone connects straight to magicJack (Grandstream).
Limits to know up front
- One call at a time. magicJack is a single line.
- No texting. SMS can't pass through magicJack's phone jack.