### Start dSIPRouter Service Source: https://dsiprouter.readthedocs.io/en/latest/command_line_options.html Use this command to start the dSIPRouter service. Ensure dSIPRouter is installed and configured before starting. ```bash dsiprouter start ``` -------------------------------- ### Install dSIPRouter (Standard, One Line) Source: https://dsiprouter.readthedocs.io/en/latest/_sources/rhel_install.rst.txt A condensed version of the standard installation command, suitable for scripting. It installs git, clones the repository, changes directory, and runs the install script with default options. ```bash yum install -y git && cd /opt && git clone https://github.com/dOpensource/dsiprouter.git && cd dsiprouter && ./dsiprouter.sh install -kam -dsip ``` -------------------------------- ### Install dSIPRouter (Standard) Source: https://dsiprouter.readthedocs.io/en/latest/_sources/rhel_install.rst.txt Use this command for a standard installation where RTP traffic is not proxied. Ensure git is installed and the hostname is set to a FQDN prior to running. ```bash yum install -y git cd /opt git clone https://github.com/dOpensource/dsiprouter.git cd dsiprouter ./dsiprouter.sh install ``` -------------------------------- ### Install dSIPRouter (No RTP Proxy) Source: https://dsiprouter.readthedocs.io/en/latest/_sources/debian_install.rst.txt Installs dSIPRouter without proxying audio (RTP) traffic. Ensure Git is installed first. ```bash apt-get update -y apt-get install -y git cd /opt git clone https://github.com/dOpensource/dsiprouter.git cd dsiprouter ./dsiprouter.sh install ``` -------------------------------- ### Install dSIPRouter (Proxy RTP Traffic) Source: https://dsiprouter.readthedocs.io/en/latest/_sources/debian_install.rst.txt Installs dSIPRouter with the RTPEngine to proxy audio (RTP) traffic. Requires Git to be installed. ```bash apt-get update -y apt-get install -y git cd /opt git clone https://github.com/dOpensource/dsiprouter.git cd dsiprouter ./dsiprouter.sh install -all ``` -------------------------------- ### Install dsiprouter v0.51 Source: https://dsiprouter.readthedocs.io/en/latest/upgrading.html Commands to install version 0.51 from the official repository. ```bash cd /opt/ apt-get update apt-get install -y git curl cd /opt git clone -b v0.51 https://github.com/dOpensource/dsiprouter.git cd dsiprouter ./dsiprouter.sh install ``` -------------------------------- ### Install dSIPRouter (No RTP Proxy) - One Line Source: https://dsiprouter.readthedocs.io/en/latest/_sources/debian_install.rst.txt A condensed version of the standard dSIPRouter installation command, suitable for scripting. ```bash apt-get update -y && apt-get install -y git && cd /opt && git clone https://github.com/dOpensource/dsiprouter.git && cd dsiprouter && ./dsiprouter.sh install ``` -------------------------------- ### Install dSIPRouter (Proxy RTP) Source: https://dsiprouter.readthedocs.io/en/latest/_sources/rhel_install.rst.txt Install dSIPRouter with the capability to proxy RTP traffic using the '-all' option. This command also installs RTPEngine and automatically detects NAT configurations. ```bash yum install -y git cd /opt git clone https://github.com/dOpensource/dsiprouter.git cd dsiprouter ./dsiprouter.sh install -all ``` -------------------------------- ### Install dsiprouter v0.523 Source: https://dsiprouter.readthedocs.io/en/latest/upgrading.html Commands to install version 0.523 from the official repository. ```bash cd /opt/ apt-get update apt-get install -y git curl cd /opt git clone -b v0.523 https://github.com/dOpensource/dsiprouter.git cd dsiprouter ./dsiprouter.sh install ``` -------------------------------- ### Start dSIPRouter Source: https://dsiprouter.readthedocs.io/en/latest/_sources/command_line_options.rst.txt Use this command to initiate the dSIPRouter service. Ensure the service is not already running. ```bash dsiprouter start ``` -------------------------------- ### Install dSIPRouter (No RTP Proxy) Source: https://dsiprouter.readthedocs.io/en/latest/debian_install.html Installs dSIPRouter without proxying audio (RTP) traffic. Ensure your system's hostname is set correctly and has DNS records pointing to it prior to running this installation. ```bash apt-get update -y apt-get install -y git cd /opt git clone https://github.com/dOpensource/dsiprouter.git cd dsiprouter ./dsiprouter.sh install ``` ```bash apt-get update -y && apt-get install -y git && cd /opt && git clone https://github.com/dOpensource/dsiprouter.git && cd dsiprouter && ./dsiprouter.sh install ``` -------------------------------- ### Install dSIPRouter (Proxy RTP, One Line) Source: https://dsiprouter.readthedocs.io/en/latest/_sources/rhel_install.rst.txt A single-line command to install dSIPRouter and enable RTP traffic proxying. This is useful for automated deployments. ```bash yum install -y git && cd /opt && git clone https://github.com/dOpensource/dsiprouter.git && cd dsiprouter && ./dsiprouter.sh install -all ``` -------------------------------- ### Install dSIPRouter (Proxy RTP Traffic) - One Line Source: https://dsiprouter.readthedocs.io/en/latest/_sources/debian_install.rst.txt A one-line command to install dSIPRouter and configure it to proxy RTP traffic using RTPEngine. ```bash apt-get update -y && apt-get install -y git && cd /opt && git clone https://github.com/dOpensource/dsiprouter.git && cd dsiprouter && ./dsiprouter.sh install -all ``` -------------------------------- ### Install dSIPRouter (No RTP Proxy) Source: https://dsiprouter.readthedocs.io/en/latest/rhel_install.html Installs dSIPRouter without proxying audio (RTP) traffic. Ensure your hostname is a fully qualified domain name (FQDN) with DNS records pointing to the server before running. ```bash yum install -y git cd /opt git clone https://github.com/dOpensource/dsiprouter.git cd dsiprouter ./dsiprouter.sh install ``` ```bash yum install -y git && cd /opt && git clone https://github.com/dOpensource/dsiprouter.git && cd dsiprouter && ./dsiprouter.sh install -kam -dsip ``` -------------------------------- ### Set Hostname for dSIPRouter Installation Source: https://dsiprouter.readthedocs.io/en/latest/debian_install.html Before installing dSIPRouter, set the system's hostname to a fully qualified domain name (FQDN) with corresponding DNS records. This command configures the hostname. ```bash hostnamectl set-hostname ``` -------------------------------- ### Install dSIPRouter (Proxy RTP Traffic) Source: https://dsiprouter.readthedocs.io/en/latest/rhel_install.html Installs dSIPRouter and enables RTP traffic proxying using the RTPEngine. The script automatically detects if the server is behind NAT. Ensure your hostname is a fully qualified domain name (FQDN) with DNS records pointing to the server before running. ```bash yum install -y git cd /opt git clone https://github.com/dOpensource/dsiprouter.git cd dsiprouter ./dsiprouter.sh install -all ``` ```bash yum install -y git && cd /opt && git clone https://github.com/dOpensource/dsiprouter.git && cd dsiprouter && ./dsiprouter.sh install -all ``` -------------------------------- ### Install dSIPRouter (Proxy RTP Traffic) Source: https://dsiprouter.readthedocs.io/en/latest/debian_install.html Installs dSIPRouter and RTPEngine to proxy audio (RTP) traffic. This option is used when the server needs to handle RTP forwarding. The script automatically detects NAT configurations. ```bash apt-get update -y apt-get install -y git cd /opt git clone https://github.com/dOpensource/dsiprouter.git cd dsiprouter ./dsiprouter.sh install -all ``` ```bash apt-get update -y && apt-get install -y git && cd /opt && git clone https://github.com/dOpensource/dsiprouter.git && cd dsiprouter && ./dsiprouter.sh install -all ``` -------------------------------- ### Install and Import Microsoft Teams PowerShell Module Source: https://dsiprouter.readthedocs.io/en/latest/use-cases.html Installs the MicrosoftTeams PowerShell module and imports it. Use this to connect to Microsoft Teams. Ensure you have the necessary credentials. ```powershell Install-Module -Name MicrosoftTeams Import-Module MicrosoftTeams $userCredential = Get-Credential Connect-MicrosoftTeams -Credential $userCredential ``` -------------------------------- ### Set Hostname on Debian Source: https://dsiprouter.readthedocs.io/en/latest/_sources/debian_install.rst.txt Use this command to set the system's hostname to a fully qualified domain name (FQDN) before installation. ```bash hostnamectl set-hostname ``` -------------------------------- ### Remove or Move Old Directory Source: https://dsiprouter.readthedocs.io/en/latest/upgrading.html Clean up the old installation directory by either moving or deleting it. ```bash mv /dsiprouter /usr/local/src (moving directory) ``` ```bash rm -r /dsiprouter (removing directory) ``` -------------------------------- ### Restart dsiprouter Service Source: https://dsiprouter.readthedocs.io/en/latest/upgrading.html Restart the service after installation or database restoration. ```bash cd /opt/disprouter/ ./dsiprouter.sh restart ``` -------------------------------- ### Uninstall dsiprouter Source: https://dsiprouter.readthedocs.io/en/latest/upgrading.html Execute these commands to remove the existing dsiprouter installation. ```bash cd /opt/dsiprouter ./dsiprouter.sh uninstall ``` -------------------------------- ### Restart dSIPRouter Source: https://dsiprouter.readthedocs.io/en/latest/_sources/command_line_options.rst.txt This command stops and then starts the dSIPRouter service. It is useful for applying configuration changes or recovering from service issues. ```bash dsiprouter restart ``` -------------------------------- ### Bootstrap upgrade to dSIPRouter 0.721 Source: https://dsiprouter.readthedocs.io/en/latest/_sources/upgrading.rst.txt Execute this script to bootstrap the upgrade to dSIPRouter version 0.721 from version 0.70. ```bash curl -s https://raw.githubusercontent.com/dOpensource/dsiprouter/v0.721/resources/upgrade/v0.721/scripts/bootstrap.sh | bash ``` -------------------------------- ### Bootstrap upgrade to dSIPRouter 0.75 Source: https://dsiprouter.readthedocs.io/en/latest/_sources/upgrading.rst.txt Execute this script to bootstrap the upgrade to dSIPRouter version 0.75 from versions 0.72 or 0.721. ```bash curl -s https://raw.githubusercontent.com/dOpensource/dsiprouter/v0.75/resources/upgrade/v0.75/scripts/bootstrap.sh | bash ``` -------------------------------- ### Backup Kamailio Database Source: https://dsiprouter.readthedocs.io/en/latest/upgrading.html Use this command to create a SQL dump of the Kamailio database before performing an upgrade. ```bash cd /opt/ mysqldump kamailio > kamailio-bk.sql ``` -------------------------------- ### Execute Lease Point API - Create Lease Source: https://dsiprouter.readthedocs.io/en/latest/api.html Creates a new endpoint lease with a specified Time-To-Live (TTL) and email address. Requires API token for authentication. ```bash curl -k -H "Authorization: Bearer $DSIP_TOKEN" -H "Content-Type: application/json" -X GET "https://$DSIP_HOSTNAME:5000/api/v1/endpoint/lease?ttl=15&email=mack@dsiprouter.org" ``` -------------------------------- ### Bootstrap upgrade to dSIPRouter 0.73 Source: https://dsiprouter.readthedocs.io/en/latest/_sources/upgrading.rst.txt Execute this script to bootstrap the upgrade to dSIPRouter version 0.73 from versions 0.72 or 0.721. Ensure your OS is a supported version before proceeding. ```bash curl -s https://raw.githubusercontent.com/dOpensource/dsiprouter/v0.73/resources/upgrade/v0.73/scripts/bootstrap.sh | bash ``` -------------------------------- ### Set dSIPRouter Credentials Source: https://dsiprouter.readthedocs.io/en/latest/api.html Use this command to set your API token. Ensure DSIP_HOSTNAME and DSIP_TOKEN environment variables are set. ```bash DSIP_HOSTNAME= DSIP_TOKEN= dsiprouter setcredentials -ac $DSIP_TOKEN ``` -------------------------------- ### Bootstrap dSIPRouter 0.73 Upgrade from 0.72/0.721 Source: https://dsiprouter.readthedocs.io/en/latest/upgrading.html Run this command to bootstrap the upgrade to dSIPRouter version 0.73 from versions 0.72 or 0.721. Ensure you are SSH'd into your dSIPRouter instance before execution. ```bash curl -s https://raw.githubusercontent.com/dOpensource/dsiprouter/v0.73/resources/upgrade/v0.73/scripts/bootstrap.sh | bash ``` -------------------------------- ### Upgrade dSIPRouter to version 0.76 via CLI Source: https://dsiprouter.readthedocs.io/en/latest/_sources/upgrading.rst.txt Use this command to perform an upgrade to version 0.76 using the command-line interface. ```bash dsiprouter upgrade -rel 0.76 ``` -------------------------------- ### Upgrade dSIPRouter to version 0.77 via CLI Source: https://dsiprouter.readthedocs.io/en/latest/_sources/upgrading.rst.txt Use this command to perform an upgrade to version 0.77 using the command-line interface. ```bash dsiprouter upgrade -rel 0.77 ``` -------------------------------- ### Connect to Microsoft Teams via PowerShell Source: https://dsiprouter.readthedocs.io/en/latest/_sources/use-cases.rst.txt Initializes the Microsoft Teams module and establishes a connection using user credentials. ```powershell Install-Module -Name MicrosoftTeams Import-Module MicrosoftTeams $userCredential = Get-Credential Connect-MicrosoftTeams -Credential $userCredential ``` -------------------------------- ### Bootstrap dSIPRouter 0.75 Upgrade from 0.72/0.721 Source: https://dsiprouter.readthedocs.io/en/latest/upgrading.html Execute this script via curl to bootstrap the upgrade to dSIPRouter version 0.75 from versions 0.72 or 0.721. ```bash curl -s https://raw.githubusercontent.com/dOpensource/dsiprouter/v0.75/resources/upgrade/v0.75/scripts/bootstrap.sh | bash ``` -------------------------------- ### Upgrade dSIPRouter to version 0.75 via CLI Source: https://dsiprouter.readthedocs.io/en/latest/_sources/upgrading.rst.txt Use this command to perform an upgrade to version 0.75 using the command-line interface. ```bash dsiprouter upgrade ``` -------------------------------- ### Upgrade dSIPRouter to version 0.78 via CLI Source: https://dsiprouter.readthedocs.io/en/latest/_sources/upgrading.rst.txt Use this command to perform an upgrade to version 0.78 using the command-line interface. ```bash dsiprouter upgrade -rel 0.78 ``` -------------------------------- ### Restore Kamailio Database (v0.51) Source: https://dsiprouter.readthedocs.io/en/latest/upgrading.html Restore the database from backup for the v0.51 upgrade. ```bash cd /opt/ mysql kamailio < kamailio-bk.sql ``` -------------------------------- ### Bootstrap dSIPRouter 0.721 Upgrade from 0.70 Source: https://dsiprouter.readthedocs.io/en/latest/upgrading.html Execute this script via curl to bootstrap the upgrade to dSIPRouter version 0.721 from version 0.70. Ensure you are SSH'd into your dSIPRouter instance before execution. ```bash curl -s https://raw.githubusercontent.com/dOpensource/dsiprouter/v0.721/resources/upgrade/v0.721/scripts/bootstrap.sh | bash ``` -------------------------------- ### Connect to Microsoft Teams Source: https://dsiprouter.readthedocs.io/en/latest/_sources/use-cases.rst.txt Establishes a connection to Microsoft Teams. Use this command when MFA/2FA is enabled. ```powershell # Get Credentials, if using MFA/2FA just run Connect-MicrosoftTeams $userCredential = Get-Credential Connect-MicrosoftTeams -Credential $userCredential ``` -------------------------------- ### Manage Endpoint Leases Source: https://dsiprouter.readthedocs.io/en/latest/_sources/api.rst.txt Commands for creating and revoking endpoint leases via the API. ```bash curl -k -H "Authorization: Bearer $DSIP_TOKEN" -H "Content-Type: application/json" -X GET "https://$DSIP_HOSTNAME:5000/api/v1/endpoint/lease?ttl=15&email=mack@dsiprouter.org" ``` ```bash curl -k -H "Authorization: Bearer $DSIP_TOKEN" -H "Content-Type: application/json" -X PUT "https://$DSIP_HOSTNAME:5000/api/v1/endpoint/lease/1/revoke" ``` -------------------------------- ### Edit RTPEngine Main Configuration Source: https://dsiprouter.readthedocs.io/en/latest/_sources/troubleshooting.rst.txt Configure RTPEngine logging verbosity by editing its main configuration file and adjusting the 'debug' variable. ```bash vi /etc/rtpengine/rtpengine.conf ``` -------------------------------- ### Set dSIPRouter Credentials Source: https://dsiprouter.readthedocs.io/en/latest/_sources/api.rst.txt Configures the API token for the dSIPRouter CLI tool. ```bash DSIP_HOSTNAME= DSIP_TOKEN= dsiprouter setcredentials -ac $DSIP_TOKEN ``` -------------------------------- ### Upgrade dSIPRouter from 0.621 to 0.63 Source: https://dsiprouter.readthedocs.io/en/latest/upgrading.html This sequence of commands upgrades dSIPRouter from version 0.621 to 0.63, involving stashing changes, checking out the new version, and running the upgrade command. ```bash cd /opt/dsiprouter git stash git checkout v0.63 dsiprouter upgrade -rel 0.63 ``` -------------------------------- ### Proxy FusionPBX UI with Nginx Source: https://dsiprouter.readthedocs.io/en/latest/_sources/resources.rst.txt Add this Nginx location block to proxy the FusionPBX UI through dSIPRouter. This configuration is typically added to `/opt/dsiprouter/gui/modules/fusionpbx/dsiprouter.nginx.tpl`. ```nginx location / { proxy_pass https://fusionpbx; proxy_redirect off; proxy_next_upstream error timeout http_404 http_403 http_500 http_502 http_503 http_504 non_idempotent; } ``` -------------------------------- ### Default STIR/SHAKEN Key Path Source: https://dsiprouter.readthedocs.io/en/latest/_sources/use-cases.rst.txt Specifies the default file path for the STIR/SHAKEN private key on the dSIPRouter instance. ```bash /etc/dsiprouter/certs/stirshaken/sp-key.pem ``` -------------------------------- ### Edit RTPEngine Syslog Configuration Source: https://dsiprouter.readthedocs.io/en/latest/_sources/troubleshooting.rst.txt Edit the RTPEngine syslog configuration file. Uncomment the line for the local1 facility to enable RTPEngine logging. ```bash vi /etc/rsyslog.d/rtpengine.conf ``` -------------------------------- ### Restore and Update Kamailio Database Source: https://dsiprouter.readthedocs.io/en/latest/upgrading.html Restore the database from backup and apply necessary schema changes for v0.523. ```bash cd /opt/ mysql kamailio < kamailio-bk.sql mysql kamailio -e "alter table dsip_multidomain_mapping add column domain_list_hash varchar(255) after domain_list;" ``` -------------------------------- ### Uninstall dSIPRouter Source: https://dsiprouter.readthedocs.io/en/latest/_sources/command_line_options.rst.txt Use this command to completely remove dSIPRouter and its related services from the system. The `-all` flag ensures all components are uninstalled. ```bash dsiprouter uninstall -all ``` -------------------------------- ### Proxy FusionPBX UI Configuration Source: https://dsiprouter.readthedocs.io/en/latest/resources.html Add this Nginx configuration stanza to proxy the FusionPBX UI through dSIPRouter. This allows access to the FusionPBX GUI via HTTPS. ```nginx location / { proxy_pass https://fusionpbx; proxy_redirect off; proxy_next_upstream error timeout http_404 http_403 http_500 http_502 http_503 http_504 non_idempotent; } ``` -------------------------------- ### Generate STIR/SHAKEN Self-Signed Certificate Source: https://dsiprouter.readthedocs.io/en/latest/_sources/use-cases.rst.txt Generates a self-signed certificate for testing STIR/SHAKEN. This script is run on the dSIPRouter instance. ```bash /opt/dsiprouter/resources/stir_shaken/generate_self_signed_cert.sh ``` -------------------------------- ### Edit dSIPRouter GUI Settings Source: https://dsiprouter.readthedocs.io/en/latest/_sources/troubleshooting.rst.txt Adjust the logging verbosity for the dSIPRouter GUI by editing the settings file and changing the 'DSIP_LOG_LEVEL' variable. ```bash vi /etc/dsiprouter/gui/settings.py ``` -------------------------------- ### Execute Kamailio Stats API Source: https://dsiprouter.readthedocs.io/en/latest/api.html This curl command retrieves statistics from the Kamailio service. It requires the API token for authorization. ```bash curl -k -H "Authorization: Bearer $DSIP_TOKEN" -X GET https://$DSIP_HOSTNAME:5000/api/v1/kamailio/stats ``` -------------------------------- ### Restart dSIPRouter Service Source: https://dsiprouter.readthedocs.io/en/latest/command_line_options.html Use this command to restart the dSIPRouter service. This is useful after configuration changes or to resolve service issues. ```bash dsiprouter restart ``` -------------------------------- ### Edit Kamailio Syslog Configuration Source: https://dsiprouter.readthedocs.io/en/latest/_sources/troubleshooting.rst.txt Use this command to edit the Kamailio syslog configuration file. Ensure the local0 facility line is uncommented to enable logging. ```bash vi /etc/rsyslog.d/kamailio.conf ``` -------------------------------- ### Configure User for Enterprise Voice and Voicemail Source: https://dsiprouter.readthedocs.io/en/latest/_sources/use-cases.rst.txt Sets an outgoing phone number (DID) for a user and enables Enterprise Voice and Voicemail. Replace placeholders with actual values. ```powershell # Define a outgoing phone number (aka DID) and set Enterprise Voice and Voicemail Set-CsUser -Identity "user@example.com" -OnPremLineURI tel:+13137175555 -EnterpriseVoiceEnabled $true -HostedVoiceMail $true ``` -------------------------------- ### Edit dSIPRouter Syslog Configuration Source: https://dsiprouter.readthedocs.io/en/latest/_sources/troubleshooting.rst.txt Modify the dSIPRouter syslog configuration file. Ensure the local2 facility line is not commented out to enable its logging. ```bash vi /etc/rsyslog.d/dsiprouter.conf ``` -------------------------------- ### Configure Microsoft Teams Voice Routing Source: https://dsiprouter.readthedocs.io/en/latest/_sources/use-cases.rst.txt Sets up PSTN usage, voice routes, and assigns routing policies to users for Direct Routing. ```powershell Set-CsOnlinePstnUsage -Identity Global -Usage @{Add="US and Canada"} Set-CsOnlineVoiceRoute -Identity "LocalRoute" -NumberPattern ".*" -OnlinePstnGatewayList sbc.example.com New-CsOnlineVoiceRoutingPolicy "US Only" -OnlinePstnUsages "US and Canada" # This is suppose to stop MSTeams from using the Microsoft Dialing Plan and using the routing policies that was defined above Set-CsTenantHybridConfiguration -UseOnPremDialPlan $False # Apply and the US Only Voice Routing Policy to the user Grant-CsOnlineVoiceRoutingPolicy -Identity “user@example.com“ -PolicyName "US Only" ``` -------------------------------- ### Edit Kamailio Main Configuration Source: https://dsiprouter.readthedocs.io/en/latest/_sources/troubleshooting.rst.txt Modify the main Kamailio configuration file to adjust the syslog logging verbosity by changing the 'debug' variable. ```bash vi /etc/kamailio/kamailio.conf ``` -------------------------------- ### Configure PSTN Usage and Voice Routing for Teams Source: https://dsiprouter.readthedocs.io/en/latest/use-cases.html Sets a PSTN usage, defines a voice route, and creates a voice routing policy for US and Canada. This configuration is intended to direct calls through your dSIPRouter SBC. ```powershell Set-CsOnlinePstnUsage -Identity Global -Usage @{Add="US and Canada"} Set-CsOnlineVoiceRoute -Identity "LocalRoute" -NumberPattern ".*" -OnlinePstnGatewayList sbc.example.com New-CsOnlineVoiceRoutingPolicy "US Only" -OnlinePstnUsages "US and Canada" # This is suppose to stop MSTeams from using the Microsoft Dialing Plan and using the routing policies that was defined above Set-CsTenantHybridConfiguration -UseOnPremDialPlan $False # Apply and the US Only Voice Routing Policy to the user Grant-CsOnlineVoiceRoutingPolicy -Identity “user@example.com“ -PolicyName "US Only" # If it doesn’t return a value of US Only, then wait 15 minutes and try it again. It sometime takes a while for the policy to be ready. Get-CsOnlineUser “user@example.com" | select OnlineVoiceRoutingPolicy # Define a outgoing phone number (aka DID) and set Enterprise Voice and Voicemail Set-CsUser -Identity "user@example.com" -OnPremLineURI tel:+13137175555 -EnterpriseVoiceEnabled $true -HostedVoiceMail $true ``` -------------------------------- ### Retrieve Kamailio Statistics Source: https://dsiprouter.readthedocs.io/en/latest/_sources/api.rst.txt Fetches Kamailio statistics using the Bearer token authentication method. ```bash curl -k -H "Authorization: Bearer $DSIP_TOKEN" -X GET https://$DSIP_HOSTNAME:5000/api/v1/kamailio/stats ``` -------------------------------- ### Access STIR/SHAKEN Certificate Source: https://dsiprouter.readthedocs.io/en/latest/_sources/use-cases.rst.txt Verifies that the STIR/SHAKEN certificate is accessible via HTTPS. Replace the placeholder with your dSIPRouter's IP or hostname. ```bash https://:5000/stirshaken_certs/sp-cert.pem ``` -------------------------------- ### Stop dSIPRouter Source: https://dsiprouter.readthedocs.io/en/latest/_sources/command_line_options.rst.txt Use this command to gracefully shut down the dSIPRouter service. This ensures all processes are terminated correctly. ```bash dsiprouter stop ``` -------------------------------- ### Add Single Teams User with Voice Routing Policy Source: https://dsiprouter.readthedocs.io/en/latest/use-cases.html Applies a voice routing policy and configures a user's phone number, enabling Enterprise Voice and Voicemail. This is used to add an additional user to an existing dSIPRouter SBC configuration in Teams. ```powershell # Get Credentials, if using MFA/2FA just run Connect-MicrosoftTeams $userCredential = Get-Credential Connect-MicrosoftTeams -Credential $userCredential # Apply and the US Only Voice Routing Policy to the user Grant-CsOnlineVoiceRoutingPolicy -Identity “user@example.com“ -PolicyName "US Only" # Define a outgoing phone number (aka DID) and set Enterprise Voice and Voicemail Set-CsUser -Identity "user@example.com" -OnPremLineURI tel:+13137175555 -EnterpriseVoiceEnabled $true -HostedVoiceMail $true ``` -------------------------------- ### Stop dSIPRouter Service Source: https://dsiprouter.readthedocs.io/en/latest/command_line_options.html Use this command to stop the dSIPRouter service. This will halt all dSIPRouter processes. ```bash dsiprouter stop ``` -------------------------------- ### Apply US Only Voice Routing Policy Source: https://dsiprouter.readthedocs.io/en/latest/_sources/use-cases.rst.txt Grants the 'US Only' voice routing policy to a specified user. Ensure the user identity is correct. ```powershell # Apply and the US Only Voice Routing Policy to the user Grant-CsOnlineVoiceRoutingPolicy -Identity “user@example.com“ -PolicyName "US Only" ``` -------------------------------- ### Restart Rsyslog Service Source: https://dsiprouter.readthedocs.io/en/latest/_sources/troubleshooting.rst.txt Restart the rsyslog service to apply changes to the syslog configuration. This command is common for all services. ```bash systemctl restart rsyslog ``` -------------------------------- ### Execute Lease Point API - Revoke Lease Source: https://dsiprouter.readthedocs.io/en/latest/api.html Revokes an existing endpoint lease using its ID. This operation requires the API token for authorization. ```bash curl -k -H "Authorization: Bearer $DSIP_TOKEN" -H "Content-Type: application/json" -X PUT "https://$DSIP_HOSTNAME:5000/api/v1/endpoint/lease/1/revoke" ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.