Download the PHP package bitdreamit/laravel-mikopbx without Composer
On this page you can find all versions of the php package bitdreamit/laravel-mikopbx. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download bitdreamit/laravel-mikopbx
More information about bitdreamit/laravel-mikopbx
Files in bitdreamit/laravel-mikopbx
Package laravel-mikopbx
Short Description The most complete Laravel package for MikoPBX โ CRM-ready call center with auto dialer, campaigns, live agent panel, web softphone, IVR builder, analytics, recordings, blacklist, callbacks & more.
License MIT
Homepage https://github.com/bitdreamit/laravel-mikopbx
Informations about the package laravel-mikopbx
bitdreamit/laravel-mikopbx
The most complete open-source Laravel package for MikoPBX โ a full call center CRM platform with a real browser softphone (WebRTC/JsSIP), auto dialer, live agent panel, IVR builder, analytics, recordings, blacklist, callbacks, conference rooms, and system health monitoring.
Table of Contents
- Features
- Requirements
- Installation
- MikoPBX Setup
- Environment Variables
- Web Dialer Setup (WebRTC / JsSIP)
- Start AMI Listener
- Pages & Routes
- Facade Usage
- Livewire Components
- Artisan Commands
- REST API v3 Endpoints Reference
- How Call Control Works (AMI, not REST)
- CDR Field Names & Nested Structure
- Live Agent Online Status
- Testing with MikoPBXFake
- Database Tables
- Real-time Events (Laravel Echo)
- Package Structure
- Publishing to GitHub & Packagist
- Troubleshooting
Features
| Feature | Description |
|---|---|
| ๐ Live Call Board | Real-time active calls with transfer, mute, hangup via AMI |
| ๐ฑ Web Dialer | Real browser softphone โ WebRTC calling via JsSIP, no desk phone required |
| ๐ Incoming Call Popup | Native Answer/Reject alert with ringtone, driven directly by JsSIP's newRTCSession event |
| ๐ฅ Agent Management | Status grid, click-to-call, sync from MikoPBX, DND/away support |
| ๐ข Auto Dialer | Create campaigns, upload number lists, voice broadcast, IVR survey |
| ๐ฟ IVR Builder | Visual node editor โ Press 1 for Sales, Press 2 for Support |
| ๐ Analytics | Daily trend, peak hours, ASR %, agent performance, Chart.js |
| ๐๏ธ Recordings | Audio player, proxy stream with Bearer auth, download, search by number/date |
| ๐ซ Blacklist | Block inbound/outbound numbers with expiry |
| ๐ Callbacks | Schedule, prioritise, attempt, assign to agent |
| ๐๏ธ Conference | Room list, kick/mute participants |
| โค๏ธ Health Monitor | AMI + SIP + REST API status check with 60-second auto-poll |
| ๐งช Dialer Debug Page | Step-by-step diagnostic tool for WebSocket, mic, and SIP registration issues |
| ๐งช MikoPBXFake | Full test double โ assertOriginated, assertTransferred etc. |
Requirements
| Requirement | Version | Notes |
|---|---|---|
| PHP | 8.2+ | Required for enums |
| Laravel | 11 or 12 | Tested on both |
| Livewire | 3.x | For real-time components |
| MikoPBX | 2024.2+ | REST API v3 and WebRTC must be enabled |
| A modern browser | any | Chrome/Firefox/Edge โ WebRTC requires HTTPS in production |
| MySQL / PostgreSQL / SQLite | any | For local CDR storage |
Installation
Step 1 โ Install the package
Step 2 โ Run the installer
This command:
- Publishes
config/mikopbx.php - Runs database migrations โ 10
mikopbx_*tables plus two new columns on youruserstable (pbx_extension,pbx_sip_password) used by the web dialer - Publishes the self-hosted JsSIP client library to
public/vendor/mikopbx/jssip.min.js - Writes
docs/supervisor-mikopbx-ami.conf - Writes
.env.mikopbx.examplewith all required variables
If installing manually instead of via the command:
Step 3 โ Add to .env
Copy .env.mikopbx.example and add the values to your .env file. See Environment Variables below.
Step 4 โ Set up MikoPBX admin panel
See MikoPBX Setup below.
Step 5 โ Assign extensions to your users
The web dialer needs to know which MikoPBX extension belongs to each logged-in user. This is stored directly on your users table:
Add the trait to your User model for convenience helpers (callNumber(), callLogs(), pendingCallbacks()):
Step 6 โ Start the AMI listener
See Start AMI Listener below.
Step 7 โ Sync extensions and open the dashboard
Visit https://yourapp.com/pbx in your browser.
MikoPBX Setup
1. Enable AMI User
Go to: MikoPBX Admin Panel โ System โ AMI Users โ Add
| Field | Value |
|---|---|
| Username | laravelapp |
| Secret | your-strong-ami-secret |
| Allowed IP | Your Laravel server IP |
| Permissions | all (or: call, originate, reporting, system) |
Save and Apply Config.
2. Get REST API Key
Go to: MikoPBX Admin Panel โ Settings โ API Keys โ Generate
Copy the JWT token and set it as MIKOPBX_API_KEY in your .env.
The REST API v3 uses Bearer token authentication in the
Authorizationheader. The oldX-Auth-Tokenheader is not used in v3.
3. Enable WebRTC for the Web Dialer
This is required for the browser softphone to work at all:
- MikoPBX Admin โ Network โ WebRTC โ Enable WebRTC (this turns on the
/asterisk/wsWebSocket endpoint on port 8088/8089) - MikoPBX Admin โ Extensions โ (each extension used by the web dialer) โ enable "Use WebRTC" on that specific extension
MikoPBX registers WebRTC endpoints with a -WS suffix internally (e.g. extension 121 becomes 121-WS for WebRTC registrations). The package handles this automatically โ you only ever store the plain number (121) in users.pbx_extension.
4. Optional โ Create ARI User
Go to: MikoPBX Admin Panel โ System โ ARI Users โ Add
Needed only if you use the ARIService for WebSocket channel control beyond what the web dialer needs.
Environment Variables
All config values are documented in config/mikopbx.php.
Web Dialer Setup (WebRTC / JsSIP)
The package includes a full browser-based softphone built on JsSIP โ no desk phone or separate SIP client required. It is self-hosted (no CDN dependency) and lives at public/vendor/mikopbx/jssip.min.js.
How it works
Required per-user setup
Each user who will use the web dialer needs both fields set:
Important: the SIP password is not the user's login password โ it is the extension's SIP secret, found in MikoPBX Admin โ Extensions โ edit โ SIP password.
Critical JsSIP configuration detail
The JsSIP.UA must be created with authorization_user set to the plain extension number (not the -WS suffixed one), and must not manually override the contact option:
This is already handled correctly by the package's shipped layouts/app.blade.php โ documented here so you don't reintroduce the bug if you customize the dialer.
Diagnosing dialer issues โ /pbx/dialer/debug
Visit https://yourapp.com/pbx/dialer/debug for a step-by-step diagnostic tool that checks, in order:
- Config API โ confirms your user has
pbx_extensionset and the backend returns valid SIP config - WebSocket connection โ tests raw connectivity to
wss://.../asterisk/ws(catches firewall/port issues) - JsSIP library loaded โ confirms
public/vendor/mikopbx/jssip.min.jsis reachable - Microphone permission โ WebRTC requires HTTPS (except on
localhost) or mic access is silently blocked - SIP registration โ attempts a real REGISTER and shows the raw SIP response
- Test call โ places a real WebRTC call to a number you specify, so you can confirm two-way audio end-to-end
Console diagnostics on the live dashboard
From any page under /pbx, open DevTools and run:
This inspects the actual production JsSIP.UA instance (not a separate test one) and prints its live registration state โ useful for confirming the softphone is still registered at the exact moment a call comes in.
Start AMI Listener (Supervisor)
The AMI listener is the daemon that connects to MikoPBX port 5038, receives real-time events (incoming calls, hangups, agent status changes), and dispatches Laravel events for the UI.
The supervisor config runs:
This command connects to AMI, subscribes to all events, and loops forever. It auto-restarts on crash.
Pages & Routes
All routes are under the configurable prefix (default /pbx).
| URL | Route Name | Description |
|---|---|---|
/pbx |
mikopbx.dashboard |
Dashboard โ live calls, task manager, campaigns, follow-up list |
/pbx/calls |
mikopbx.calls.index |
CDR table with real-time filters (Livewire) |
/pbx/calls/{id} |
mikopbx.calls.show |
Single call detail + recording player + actions |
/pbx/campaigns |
mikopbx.campaigns.index |
Campaign cards grid |
/pbx/campaigns/create |
mikopbx.campaigns.create |
Create campaign with number upload |
/pbx/campaigns/{id} |
mikopbx.campaigns.show |
Live campaign detail with number list |
/pbx/agents |
mikopbx.agents.index |
Agent table with status change and click-to-call |
/pbx/analytics |
mikopbx.analytics.index |
Chart.js analytics dashboard |
/pbx/recordings |
mikopbx.recordings.index |
Recordings with sticky audio player |
/pbx/blacklist |
mikopbx.blacklist.index |
Blacklist manager |
/pbx/callbacks |
mikopbx.callbacks.index |
Callback scheduler |
/pbx/conference |
mikopbx.conference.index |
Conference rooms |
/pbx/ivr/builder |
mikopbx.ivr.builder |
Visual IVR builder |
/pbx/health |
mikopbx.health.index |
System health monitor |
/pbx/dialer/debug |
mikopbx.dialer.debug |
Web dialer diagnostic tool |
Internal API / AJAX routes (used by the frontend)
| Method | URL | Description |
|---|---|---|
| GET | /pbx/calls/active/json |
Active calls list, polled by the dashboard header |
| POST | /pbx/calls/originate |
AMI fallback originate (used when WebRTC isn't registered) |
| POST | /pbx/calls/transfer |
Transfer call (AMI) |
| POST | /pbx/calls/hangup |
Hangup call (AMI) |
| POST | /pbx/calls/mute |
Mute/unmute (AMI) |
| GET | /pbx/agents/statuses |
Agent status list, polled by the header |
| POST | /pbx/agents/status |
Manual status change (from the Agents page dropdown) |
| POST | /pbx/agents/web-dialer-status |
Reports browser softphone online/busy/offline โ see Live Agent Online Status |
| POST | /pbx/agents/sync |
Pull extensions from MikoPBX |
| GET | /pbx/dialer/config |
SIP/JsSIP config for the current user's browser softphone |
Webhook route (no auth)
| URL | Description |
|---|---|
POST /mikopbx-webhook/call |
Receive call events pushed from MikoPBX (closures, secured by header secret) |
Facade Usage
Livewire Components
All components can be used standalone in any Blade view:
Note on incoming calls: the Answer/Reject popup is not a Livewire component. It's handled natively by Alpine.js directly in
layouts/app.blade.php, driven by JsSIP's ownnewRTCSessionevent โ this avoids the latency of a server round-trip for something as time-sensitive as a ringing call. If you're looking forIncomingCallPopup.php, it exists insrc/Livewire/but is unused by the default layout; it's kept for anyone who prefers a server-driven popup instead.
Artisan Commands
| Command | Description |
|---|---|
php artisan mikopbx:install |
Full setup wizard (publish config, run migrations, publish JsSIP, write Supervisor config) |
php artisan mikopbx:listen |
AMI daemon โ run via Supervisor in production |
php artisan mikopbx:cdr-sync --days=1 |
Pull CDR from MikoPBX REST API v3 and store locally |
php artisan mikopbx:sync-extensions |
Pull extensions from MikoPBX and upsert local DB |
php artisan mikopbx:campaign-run |
Start campaigns that are scheduled and due |
php artisan mikopbx:campaign-run --sync |
Sync progress of all running campaigns |
php artisan mikopbx:health |
Run health check (exit code 1 on critical) |
Scheduler (optional)
Add to your routes/console.php or App\Console\Kernel:
REST API v3 Endpoints Reference
Authentication: All requests need Authorization: Bearer {API_KEY} header.
Response envelope (every endpoint):
CDR โ Call Records
| Method | Endpoint | Description |
|---|---|---|
| GET | /pbxcore/api/v3/cdr |
List CDR with filters |
| GET | /pbxcore/api/v3/cdr/{id} |
Single CDR record |
| DELETE | /pbxcore/api/v3/cdr/{id} |
Delete CDR record |
| GET | /pbxcore/api/v3/cdr:playback |
Stream recording audio (token-based URL) |
| GET | /pbxcore/api/v3/cdr:download |
Download recording file (token-based URL) |
| GET | /pbxcore/api/v3/cdr:getMetadata |
CDR column metadata |
| GET | /pbxcore/api/v3/cdr:getStatsByProvider |
Stats by SIP provider |
GET /pbxcore/api/v3/cdr query parameters:
| Parameter | Required | Description |
|---|---|---|
limit |
No | Max records (default 20, max 100) |
offset |
No | Skip N records for pagination |
dateFrom |
No | Start date: 2026-06-01 00:00:00 |
dateTo |
No | End date: 2026-06-30 23:59:59 |
src_num |
No | Filter by caller number |
dst_num |
No | Filter by called number |
PBX Status
| Method | Endpoint | Description |
|---|---|---|
| GET | /pbxcore/api/v3/pbx-status:getActiveCalls |
Active calls right now (grouped display data, no channel names โ see below) |
| GET | /pbxcore/api/v3/pbx-status:getActiveChannels |
Active Asterisk channels (has real channel names, needed for AMI hangup/transfer) |
getActiveCalls()alone does not return a usable channel name field for AMI actions. The package'sLiveCallBoardcomponent cross-references it againstgetActiveChannels()to resolve the real channel string (e.g.PJSIP/121-00000010) before allowing Transfer/Hangup.
Extensions & Employees
| Method | Endpoint | Description |
|---|---|---|
| GET | /pbxcore/api/v3/extensions:getForSelect |
Extensions as {value, text} |
| GET | /pbxcore/api/v3/extensions |
Full extension list |
| GET | /pbxcore/api/v3/extensions/{id} |
Single extension |
| GET | /pbxcore/api/v3/employees |
All employees |
| POST | /pbxcore/api/v3/employees |
Create employee |
| PUT | /pbxcore/api/v3/employees/{id} |
Update employee |
MikoPBX sometimes embeds HTML (Semantic UI icon tags) inside the
textfield ofgetForSelectresponses โ the package strips these withstrip_tags()before storing display names.
SIP Peer Status
| Method | Endpoint | Description |
|---|---|---|
| GET | /pbxcore/api/v3/sip:getPeersStatuses |
All SIP peers with state |
| GET | /pbxcore/api/v3/sip:getRegistry |
SIP registration status |
| GET | /pbxcore/api/v3/sip/{id}:getStatus |
Single peer status |
| GET | /pbxcore/api/v3/sip/{id}:getStats |
Peer call statistics |
SIP peer state values: OK | REGISTERED | UNREACHABLE | LAGGED | UNKNOWN | OFF
SIP Providers (trunks)
| Method | Endpoint | Description |
|---|---|---|
| GET | /pbxcore/api/v3/sip-providers:getStatuses |
All trunk registration states |
| GET | /pbxcore/api/v3/sip-providers |
Full trunk list |
| GET | /pbxcore/api/v3/sip-providers/{id}:getStatus |
Single trunk status |
| POST | /pbxcore/api/v3/sip-providers/{id}:forceCheck |
Force re-registration |
IVR Menu
| Method | Endpoint | Description |
|---|---|---|
| GET | /pbxcore/api/v3/ivr-menu |
All IVR menus |
| POST | /pbxcore/api/v3/ivr-menu |
Create IVR menu |
| PUT | /pbxcore/api/v3/ivr-menu/{id} |
Update IVR menu |
| DELETE | /pbxcore/api/v3/ivr-menu/{id} |
Delete IVR menu |
Conference Rooms
| Method | Endpoint | Description |
|---|---|---|
| GET | /pbxcore/api/v3/conference-rooms |
All conference rooms |
| POST | /pbxcore/api/v3/conference-rooms |
Create room |
Sound Files
| Method | Endpoint | Description |
|---|---|---|
| GET | /pbxcore/api/v3/sound-files:getForSelect |
As {value, text} list |
| POST | /pbxcore/api/v3/sound-files:uploadFile |
Upload audio (multipart) |
System
| Method | Endpoint | Description |
|---|---|---|
| GET | /pbxcore/api/v3/sysinfo:getInfo |
System info, disk, CPU, version |
| GET | /pbxcore/api/v3/system:ping |
Health ping (no auth needed) |
| GET | /pbxcore/api/v3/system:checkAuth |
Verify API key is valid |
How Call Control Works (AMI, not REST)
Critical: MikoPBX REST API v3 has no originate, transfer, hangup, or mute endpoints. All call control goes through AMI (Asterisk Manager Interface) on TCP port 5038.
The web dialer (browser softphone) is a third path entirely โ it doesn't go through Laravel at all for call setup. JsSIP talks directly to MikoPBX over the WebRTC WebSocket, and Laravel is only used to hand out SIP credentials (/pbx/dialer/config) and to report status changes (/pbx/agents/web-dialer-status).
AMI Event โ Laravel Event
The mikopbx:listen daemon receives these AMI events and fires Laravel Events:
| AMI Event | Trigger | Laravel Event | Echo Channel |
|---|---|---|---|
Newchannel |
Phone rings | IncomingCallEvent |
mikopbx.calls .incoming |
Bridge |
Call answered | CallAnsweredEvent |
mikopbx.calls .answered |
Hangup |
Call ended | CallEndedEvent |
mikopbx.calls .ended |
PeerStatus |
Agent login/out | AgentStatusChangedEvent |
mikopbx.agents .status |
CDR Field Names & Nested Structure
Important: MikoPBX REST API v3's CDR response is nested by call, not a flat list โ this trips up most first attempts at integration.
Real response shape from GET /pbxcore/api/v3/cdr:
Each top-level item in data.records[] is one call (grouped by linkedid); the actual per-channel-leg detail โ including UNIQUEID, playback_url, and recordingfile โ is nested one level deeper inside that item's own records[] array. php artisan mikopbx:cdr-sync flattens this correctly and merges group-level fields (src_num, dst_num) into each inner record before saving.
| Our DB Column | MikoPBX v3 Field | Notes |
|---|---|---|
caller |
src_num |
Caller phone number |
callee |
dst_num |
Called phone number |
uniqueid |
UNIQUEID |
Capital letters, and one level deeper than the group |
channel |
src_chan |
e.g. PJSIP/121-00000004 |
started_at |
start |
Has microseconds (20:37:18.896) โ stripped before saving to MySQL |
answered_at |
answer |
Empty string if not answered |
ended_at |
endtime |
Call end time |
status |
disposition |
ANSWERED / NOANSWER (no space) / BUSY / FAILED |
duration |
duration |
Total seconds (inner record) or totalDuration (group level) |
billsec |
billsec |
Answered seconds (inner record) or totalBillsec (group level) |
recording_file |
recordingfile |
Full server path โ package stores just the basename |
recording_url |
playback_url |
Relative, token-based URL โ proxied through Laravel with Bearer auth so the browser never needs the API key |
Pagination uses data.pagination.hasMore (not a simple record-count comparison) to know when to fetch the next page.
Live Agent Online Status
The Live Call Board and CDR sync (server-side, via REST API) and the web dialer's own registration state (client-side, via JsSIP in the browser) are two entirely separate systems. A browser can be fully registered and able to make/receive WebRTC calls while MikoPBX's own sip:getPeersStatuses endpoint doesn't cleanly reflect that -WS registration โ which would otherwise make agents appear offline in the Agent Status Grid even while actively on a call.
To fix this, the web dialer actively reports its own state to the server:
AgentService::all() trusts a browser-reported status for 90 seconds before letting the next AMI/REST poll overwrite it โ this prevents the status flickering between "online" and "offline" on every 10-second poll cycle just because MikoPBX's peer-status endpoint doesn't recognize the WebRTC contact the same way it does a desk phone.
Testing with MikoPBXFake
MikoPBXFake replaces the MikoPBX service container binding. No real API or AMI calls during tests.
Available assertions
| Method | Description |
|---|---|
assertOriginated($from, $to) |
Assert a call was originated |
assertNotOriginated($from, $to) |
Assert call was NOT made |
assertOriginateCount($n) |
Assert exactly N originate calls |
assertNothingOriginated() |
Assert zero calls were originated |
assertTransferred($channel, $to) |
Assert a transfer was performed |
assertHungUp($channel) |
Assert a channel was hung up |
assertCampaignStarted() |
Assert a campaign was started |
failOnNextCall() |
Make next originate throw exception |
reset() |
Clear all recorded calls between tests |
Database Tables
All tables use the prefix mikopbx_ (configurable in config/mikopbx.php), plus two new columns added directly to your existing users table.
| Table / Column | Description |
|---|---|
mikopbx_extensions |
Agents / SIP extensions synced from MikoPBX |
mikopbx_call_logs |
CDR โ local copy of call records |
mikopbx_campaigns |
Auto dialer campaigns |
mikopbx_campaign_numbers |
Numbers in each campaign with per-number status |
mikopbx_blacklist |
Blocked numbers with direction and expiry |
mikopbx_callbacks |
Scheduled callback tasks |
mikopbx_ivr_trees |
IVR node definitions |
mikopbx_conference_rooms |
Conference room config |
mikopbx_agent_status_log |
Agent status change history |
mikopbx_health_logs |
Health check results over time |
users.pbx_extension |
The MikoPBX extension number for this user's web dialer |
users.pbx_sip_password |
The SIP password for that extension (hidden from JSON output) |
Real-time Events (Laravel Echo)
Set up Laravel Echo in your resources/js/bootstrap.js:
If Echo is not configured, you will see Laravel Echo cannot be found logged by Livewire in the browser console โ this is harmless. Livewire.on() listeners (used for the ringtone and toast events) work over Livewire's own local event bus and do not require Echo/broadcasting to function.
| Channel | Event | Trigger |
|---|---|---|
mikopbx.calls |
.incoming |
Incoming call detected via AMI (server-side CDR/board updates) |
mikopbx.calls |
.answered |
Call was answered |
mikopbx.calls |
.ended |
Call ended/missed |
mikopbx.agents |
.status |
Agent went online/offline/busy |
Note: the browser's own incoming-call popup does not depend on these Echo events โ it's driven directly by JsSIP's
newRTCSessionevent for near-instant response. Echo/AMI events update the server-side dashboard widgets (Live Call Board, Agent Status Grid) in parallel.
Package Structure
Anyone installs it
Troubleshooting
Outbound call connects but has NO audio on either side
This is the single most common WebRTC failure mode and almost always points to one cause: missing or unreachable TURN server.
Symptom: you click Call, the other side picks up, the call timer is counting, but neither party can hear the other. The SIP signaling completed (the call is "connected" because the INVITE/200 OK/ACK handshake travels through the WebSocket), but the RTP media path was never established because ICE could not traverse NAT using STUN alone.
Diagnostics (in this order):
- Open browser DevTools โ Console. Look for
[ICE] iceConnectionState:lines.connectedorcompleted= good.failed= ICE failed โ TURN issue.- If you never see this log line at all, the layout is stale โ republish views (
php artisan vendor:publish --tag=mikopbx-views --force).
- Look for
[ICE] โ No TURN server configuredwarning. If present, no TURN env vars are set. - Look at
[MikoPBX] ICE servers in use:โ confirm it includes aturn:entry.
Fix:
Also confirm:
- UDP egress from the browser is not blocked (corporate firewalls often block UDP โ only TURN-over-TCP/443 will work in that case)
- The TURN server is reachable:
curl -v https://your-turn-host:3478(or use https://webrtc.github.io/samples/src/content/peerconnection/trickle-ice/) MIKOPBX_STUNis set to a reachable STUN server
Other causes (less common):
- Browser autoplay policy blocked
audio.play()โ a red "๐ Browser blocked call audio" banner now appears at the bottom of the page; click Enable Audio to resume. - HTTPS not enforced โ
getUserMediais blocked onhttp://(exceptlocalhost), so the local mic track is never captured. Force HTTPS. - MikoPBX WebRTC endpoint codec mismatch โ MikoPBX's PJSIP WebRTC module defaults to Opus; ensure the browser also offers Opus (Chrome/Firefox/Edge all do).
Incoming calls don't ring or show a popup, but outbound calls work fine
Step 1 โ Confirm JsSIP actually received the INVITE.
Open DevTools โ Console on a /pbx page (any page that uses the softphone layout). Place a real inbound call to the user's extension. You should see:
- If you DO see this log but the popup doesn't appear โ it's a code bug; report it. (The fixed layout in this version handles this case correctly, so a republish should resolve it:
php artisan vendor:publish --tag=mikopbx-views --force.) -
If you do NOT see this log โ JsSIP never received the INVITE. The problem is on the MikoPBX side, not in this code:
- MikoPBX Admin โ Extensions โ
โ "Use WebRTC" toggle is OFF. Turn it ON, save, then refresh the browser page so JsSIP re-registers. - The same extension is also registered on a desk phone (Zoiper, Linphone, hardware SIP phone). MikoPBX may deliver the call to the desk-phone contact only and never fork it to the
-WSWebRTC contact. Either unbind the desk phone, or configure MikoPBX to ring all contacts simultaneously (MikoPBX Admin โ Extensions โ "Call settings" โ "Ring simultaneously"). - The inbound route / IVR in MikoPBX points to a single extension number, not a ring-group that includes the
-WSvariant. Edit the inbound route to ring the extension (which MikoPBX will fork to all its registered contacts). - The WebSocket (
wss://...:8089/asterisk/ws) dropped silently. Check the "Softphone Ready" pill in the header โ if it's red, refresh the page. If it stays red, see Web dialer shows "Softphone Offline" below.
- MikoPBX Admin โ Extensions โ
Step 2 โ Confirm authorization_user is the plain extension.
The JsSIP.UA config must use the plain extension number (e.g. "121") for authorization_user, and the SIP URI uses the -WS suffix (sip:[email protected]). The shipped layout does this correctly โ do not override contact: manually, or every incoming INVITE will be silently rejected.
Step 3 โ Confirm ringtone is not autoplay-blocked.
If the popup appears but you hear no ringtone, the browser's autoplay policy blocked audio.play() because the user hasn't interacted with the page yet. Click anywhere on the page (or just the Answer button) โ the ringtone will start, and the call will be answered in one motion.
Web dialer shows "Softphone Offline" and never registers
Open /pbx/dialer/debug and run all checks in order. The most common causes, in order of likelihood:
- No
pbx_extensionset for the logged-in user โ Step 1 (Config API) will showextension: null. Fix:$user->update(['pbx_extension' => '121', 'pbx_sip_password' => '...']) - WebSocket port blocked by firewall โ Step 2 will time out or error; open port 8089 (or 8088 for non-SSL)
- Site is served over plain HTTP โ Step 4 (Microphone) will fail; WebRTC requires HTTPS except on
localhost - Wrong SIP password โ Step 5 will show a
401/403in the raw SIP response - Multiple UAs registered to the same extension โ if you have the dashboard open in two browser tabs, or you've previously visited
/pbx/dialer/debugand started a test UA, MikoPBX may be forking the INVITE to the wrong contact. Close all tabs, refresh, and re-test.
AMI connection failed
Checks:
- Port 5038 is open on MikoPBX VPS firewall
MIKOPBX_AMI_HOSTpoints to the correct IP- AMI user created in MikoPBX Admin โ System โ AMI Users
- Laravel server IP is in the allowed IP list
API key 401 Unauthorized
SSL certificate error
Set MIKOPBX_VERIFY_SSL=false โ MikoPBX uses a self-signed certificate by default.
CDR sync inserting only 1 row, or wrong field names
MikoPBX v3's CDR response is nested (data.records[].records[]) โ see CDR Field Names & Nested Structure above. If you're on an older copy of this package that expected a flat array, update CdrSyncCommand.php to the current version, then re-run:
Live Call Board shows calls but Transfer/Hangup do nothing
getActiveCalls() alone does not include a channel name field, so Transfer/Hangup have nothing to act on unless the channel is resolved via getActiveChannels() first. Confirm you're on the current LiveCallBoard.php, which cross-references both endpoints automatically.
Extensions not syncing
License
MIT โ free for commercial use.
Built by BitDream IT, Bangladesh.