Skip to content

Numbers & SIP Trunks (Client Self-Care) Module Documentation

8 min readUpdated: Nov 29, 2026
View as Markdown
Role Primary Use Case Key Capabilities
Customer Account Administrator Corporate telecom self-service management. View account balance, purchase additional DIDs, manage subscribed plans, and configure company profile.
Finance / Accounts Payable Wallet replenishment & invoice payments. Add funds via credit card / bank transfer, download official PDF invoices, and monitor transaction ledgers.
End Subscriber Personal usage tracking. Review outbound call history, check message logs, and inspect plan quota consumption.

Module Code: billing/client/numbers-trunks
Route: /portal/telephony
Backend Service: clientService.ts (ring2all-billing-api)
Database Tables: dids, customer_ip_endpoints, customers
Brand Purity: 100% White-Label Compliant (Ring2All BSS)


  1. Executive Summary & Commercial Autonomy
  2. Technical Architecture & Real-Time Sync Pipeline
  3. Visual Interface & Screen Breakdown
  4. Inbound DID Routing Engine & Features
  5. SBC IP Whitelist & Trunk Peering Security
  6. Diagnostic CLI & Operational Playbooks
  7. Domain Glossary

The Numbers & SIP Trunks module provides enterprise PBX clients, wholesale VoIP aggregators, and commercial subscribers with total self-service sovereignty over their inbound telephone numbers (DIDs), outbound SIP trunk authentication credentials, and SBC IP whitelist endpoints.

+-------------------------------------------------------------------------------+
| COMMERCIAL & OPERATIONAL IMPACT |
+-------------------------------------------------------------------------------+
| β€’ Zero-Touch Trunk Turnup: Customers whitelist office IP addresses instantly |
| without engineering intervention or provisioning delays. |
| β€’ Granular DID Routing: Dynamically route calls to hosted PBX extensions, |
| external SIP URIs, or PSTN failover destinations in real time. |
| β€’ Multi-Channel Capacity: Real-time channel burst limits per number. |
| β€’ Regulatory Compliance: Self-service E911 emergency registration and CNAM. |
+-------------------------------------------------------------------------------+

The client portal interacts with the Ring2All BSS core API to inspect leased DIDs and manage IP-authenticated SIP trunks. When a client adds an IP endpoint, it is instantaneously committed to PostgreSQL and synced to the perimeter SBC cluster:

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Client Browser (Ring2All BSS Client Portal) β”‚
β”‚ Route: /portal/telephony β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”‚ HTTPS / JWT Auth
β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Ring2All BSS API Engine (Fastify 5 / Node.js 22) β”‚
β”‚ Endpoints: GET /api/client/dids, POST /ip-endpoints β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”‚ β”‚
SQL (Atomic) β”‚ RPC Dispatch β”‚ (sbc-cli / BINRPC)
β–Ό β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ PostgreSQL 17 (ss_billing) β”‚ β”‚ Ring2All Perimeter SBC β”‚
β”‚ β€’ DID inventory β”‚ β”‚ β€’ Ring2All SBC Engine 6.1 permissions β”‚
β”‚ β€’ customer IP authorization endpoints β”‚ β”‚ β€’ Real-Time Address Reload β”‚
β”‚ β€’ customer accounts store β”‚ β”‚ β€’ Sub-millisecond Anti-Fraud β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

The primary interface organizes numbers, credentials, and IP endpoints into structured, responsive data cards:

Numbers & SIP Trunks Overview

  • Leased DIDs Table: Displays formatted telephone numbers, state/city location, allocated channel capacity, current routing target (e.g., Mini-PBX, IP Endpoint), and action buttons.
  • SIP Credentials Card: Outlines the primary SIP Registrar host (sbc.carrier.com), port (5060), SIP username, and interactive copy/reveal controls.
  • SBC IP Whitelist: Lists authorized customer PBX IP addresses with active sync status badges.

Customers click Add IP Endpoint to whitelist an on-premise PBX or remote cloud gateway:

Add SBC IP Whitelist Modal

  • Endpoint Name: Friendly identifier (e.g., Miami Core SBC Trunk).
  • IP Address & Port: Public IPv4 address and signaling port (default 5060).
  • Signaling Protocol: Protocol selection between UDP, TCP, or TLS.
  • Subnet Mask: Prefix bitmask (default /32 for single host).

The routing modal offers 4 deterministic delivery paths:

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Incoming Call on Leased DID β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ β”‚ β”‚
β–Ό β–Ό β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Hosted PBX β”‚ β”‚ Customer Trunk β”‚ β”‚ External SIP URI β”‚
β”‚ Delivered to β”‚ β”‚ Dispatched to β”‚ β”‚ Forwarded via SIP β”‚
β”‚ Cloud Extension β”‚ β”‚ Whitelisted IP β”‚ β”‚ Proxy to URI β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
  1. Route to Hosted PBX Domain: Directly hands the call off to Ring2All PBX routing scripts for extension, IVR, or call center queue processing.
  2. Route to IP Trunk Endpoint: Bypasses PBX IVR logic and sends SIP INVITE directly to the customer’s on-premise SBC or IP PBX.
  3. Route to Smart DID (LΓ­nea Plus / AI Line): Hands the call to the stateless smart line engine (smart-lines.ring2all.internal) for autonomous call screening, interactive mini-IVR, call forwarding, and real-time voice AI.
  4. Emergency Failover Forwarding: If the primary IP PBX returns SIP 503 Service Unavailable or fails to respond within 20 seconds, the call automatically diverts to an external PSTN mobile number.
  5. E911 & CNAM Services: Includes self-service address provisioning for North American emergency caller location identification.

5.1 Smart DIDs: LΓ­nea Plus vs. LΓ­nea Plus + AI (Autonomous Virtual Lines)

Section titled β€œ5.1 Smart DIDs: LΓ­nea Plus vs. LΓ­nea Plus + AI (Autonomous Virtual Lines)”

For businesses, professionals, and remote agents who do not require a complex multi-tenant PBX with dozens of extensions, Ring2All BSS provides Smart DIDs (Autonomous Virtual Lines). These lines eliminate the need to provision dedicated subdomains, Nginx SSL certificates, or heavy PBX configurations.

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Smart Line Delivery & Fallback Architecture β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”‚ Inbound PSTN Call
β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Ring2All SBC Engine 6.1 β”‚
β”‚ Dispatches to: smart-lines.ring2all.internal β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”‚ Stateless Load Balancing
β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Telephony Smart Router (Lua Engine) β”‚
β”‚ β€’ Time Schedule Filter (e.g. 09:00 - 18:00) β”‚
β”‚ β€’ Personal Assistant (Interactive Mini-IVR DTMF) β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”‚ β”‚
[Plan: LΓ­nea Plus + AI] [Plan: LΓ­nea Plus]
β–Ό β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ RealTime Voice AI Agent β”‚ β”‚ Direct Telecom Routing β”‚
β”‚ β€’ OpenAI Natural Speech (Alloy) β”‚ β”‚ β€’ 100% Traditional Telephony β”‚
β”‚ β€’ RAG Knowledge Base Injection β”‚ β”‚ β€’ 0 Tokens / $0.00 AI Cost β”‚
β”‚ β€’ Assisted Transfer to Mobile β”‚ β”‚ β€’ Low-latency Local Bridging β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”‚ β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”‚ Call Bridge to Destination
β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Target 1: Registered Softphone (SBC) β”‚
β”‚ Target 2: Customer IP PBX (SIP URI) β”‚
β”‚ Target 3: Mobile Phone (PSTN Cellular) β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”‚
Unanswered / Busy / Offline
β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Cloud Smart Voicemail Rescue β”‚
β”‚ β€’ Audio WAV saved in BSS Cloud Portal β”‚
β”‚ β€’ Instant Voicemail Transcription (AI) β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
  • πŸ“¦ LΓ­nea Plus (Standard Telecom):
    • Included Capabilities: Personal Assistant (Mini-IVR with custom DTMF options), Follow-Me call forwarding with customizable ring timeouts (5-60s), time-of-day scheduling, and digital Cloud Voicemail (WAV audio player in client portal).
    • Resource Consumption: 100% native Telephony Engine / SBC Engine processing with $0.00 OpenAI cost and 0 tokens consumed.
  • πŸ€– LΓ­nea Plus + AI (Pro AI Assistant):
    • Included Capabilities: Everything in LΓ­nea Plus plus the RealTime Voice AI Agent (OpenAI), selectable neural voices, natural conversation pacing, document knowledge base injection (RAG with vector embeddings), live transfer to mobile, and automated voicemail transcription.

A Smart DID is not restricted to cell phones; subscribers can choose how they answer incoming calls:

  1. Registered Mobile Softphone / IP Deskphone: The user registers any SIP terminal (Zoiper, Grandstream Wave, Yealink) against the Ring2All SBC. When a call arrives, the softphone rings directly.
  2. Customer On-Premise PBX: Bridges directly via SIP URI (e.g., sip:sales@pbx.customer.com).
  3. PSTN Cellular Phone: Rings the user’s mobile cellular number directly.
  4. Cloud Voicemail Rescue Fallback: In all three options, if the softphone is asleep/offline, the PBX is down, or the mobile user does not answer within the configured timeout, Ring2All retrieves the call immediately and sends the caller to the Cloud Voicemail box.

Subscribers do not need to enter an Outbound Proxy in their softphones or IP hardware. Thanks to RFC 3263 DNS discovery and Ring2All SBC Engine routing:

  • SIP Domain: sip.ring2all.com
  • Username / Account: Provided in the SIP Trunk Connection Details card.
  • Password: Generated securely in the client portal.
  • Outbound Proxy: (Leave Blank)

To prevent unauthorized call termination and toll fraud:

  • Carrier SBC Enforcement: Every outbound call arriving at the SBC is cross-checked against customer_ip_endpoints. If the source IP does not match the customer’s registered trunk, the call is rejected immediately with SIP/2.0 403 Forbidden.
  • Zero Registration Overhead: IP-authenticated trunks require no SIP REGISTER packets, eliminating CPU overhead on Telephony Server and SBC Engine.
  • Instant In-Memory Invalidation: When a customer deletes an IP endpoint in the portal, an atomic RPC command deletes the IP from SBC Engine’s permissions htable in less than 50 milliseconds.

To verify that a customer’s IP endpoint has been pushed to Ring2All SBC Engine memory:

Terminal window
# Execute on Perimeter SBC host
sbc-cli permissions.addressDump
Terminal window
# Filter ESL events for customer DID
fs_cli -x "sofia status profile external"
fs_cli -x "luarun show_did_routing.lua +13058904421"

  • DID (Direct Inward Dialing): Virtual telephone number routed over IP to a subscriber terminal.
  • IP Endpoint: Public IP address authorized to peer with the SBC without digest authentication.
  • CNAM: Caller ID Name database lookup protocol providing 15-character caller names.
  • E911: Enhanced 911 location identification protocol transmitting physical address data to PSAP dispatchers.