Personal tools
Namespaces

Variants
Actions

SMS Center For WHMCS

From ModulesGarden Wiki
(Difference between revisions)
Jump to: navigation, search
(About SMS Center For WHMCS)
 
(111 intermediate revisions by 7 users not shown)
Line 5: Line 5:
 
{|
 
{|
 
|style="padding: 10px 0px 5px 0px;"|'''SMS Center For WHMCS''' is a module created to send text messages to your clients and administrators.<br />
 
|style="padding: 10px 0px 5px 0px;"|'''SMS Center For WHMCS''' is a module created to send text messages to your clients and administrators.<br />
You will be able to choose from ten different SMS gateways, define SMS templates in various languages and manage bulk text messaging.<br />
+
You will be given the possibility to choose from over 60 different SMS gateways, define SMS templates in various languages and manage bulk text messaging.<br />
The module will allow you to verify new clients and orders as well as enable SMS codes as a part of two-factor authentication while logging in to your system.<br />
+
The module will also allow you to verify new clients and orders as well as enable SMS codes as part of two-factor authentication while logging in to your system.<br />
You will also get the access to SMS messages logs in order to verify the status of each sent text message.<br />
+
Finally, your customers will be enabled to decide whether they wish to receive certain notifications or not.
 
|}
 
|}
 
<!-- fixed -->
 
<!-- fixed -->
 
*'''Admin Area Features:'''
 
*'''Admin Area Features:'''
 
{|
 
{|
|style="padding: 10px 0px 0px 30px;"|✔ Notify Both Your Clients And Administrators via SMS Message
+
|style="padding: 10px 0px 0px 30px;"|✔ Notify Your Clients And Administrators Via SMS Messages
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ Define SMS Gateway To Be Used Per Country
+
|style="padding: 0px 0px 0px 30px;"|✔ Use Single Or Multiple Configurations Per SMS Gateway
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Define SMS Gateway Rules Per Country
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Send SMS Using Client's Phone Number Field Or Custom Filed
 
|}
 
|}
 
{|
 
{|
Line 22: Line 28:
 
{|
 
{|
 
|style="padding: 0px 0px 0px 30px;"|✔ Manage List Of Queued SMS
 
|style="padding: 0px 0px 0px 30px;"|✔ Manage List Of Queued SMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Send Single SMS To Chosen Client Or Type In Any Number Manually
 
|}
 
|}
 
{|
 
{|
Line 27: Line 36:
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ Define SMS Template Counterpart For Each Email Template
+
|style="padding: 0px 0px 0px 30px;"|✔ Define SMS Template Counterpart Of Each Email Template
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ Define Mass SMS Template
+
|style="padding: 0px 0px 0px 30px;"|✔ Define Mass SMS Templates
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ Define Default SMS Template Version For Each Language
+
|style="padding: 0px 0px 0px 30px;"|✔ Estimate Message Length Using Character Counter
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ Define Notifications To Receive Per Administrator
+
|style="padding: 0px 0px 0px 30px;"|✔ Create Different Language Versions Of Each SMS Template
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ Choose Products To Notify Administrator When They Are Ordered
+
|style="padding: 0px 0px 0px 30px;"|✔ Choose SMS Notifications To Be Received By Each Administrator
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ Notify Chosen Administrator When:
+
|style="padding: 0px 0px 0px 30px;"|✔ Notify Chosen Administrators Via SMS When:
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 45px;"|✔ Selected Product is Ordered
+
|style="padding: 0px 0px 0px 45px;"|✔ Specified Product Is Ordered
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 45px;"|✔ Specified Product Addon is Ordered
+
|style="padding: 0px 0px 0px 45px;"|✔ Specified Product Addon Is Ordered
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 45px;"|✔ Specified Domain is Ordered
+
|style="padding: 0px 0px 0px 45px;"|✔ Specified Domain Is Ordered
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 45px;"|✔ Ticket With Specified Priority is Opened
+
|style="padding: 0px 0px 0px 45px;"|✔ Ticket With Specified Priority Is Opened Or Flagged
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ Enable/Disable Administrator Notifications Per Admin
+
|style="padding: 0px 0px 0px 45px;"|✔ Support Ticket Have Response
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 45px;"|✔ Support Ticket Department Reassigned
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 45px;"|✔ Specified Administrator Or Client Logs In
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 45px;"|✔ Product Automatic Setup Failed Or Succeeded
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 45px;"|✔ Service Is Suspended
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 45px;"|✔ Service Unsuspension Failed Or Succeeded
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 45px;"|✔ Domain Renewal Failed Or Succeeded
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 45px;"|✔ New Order Is  Submitted
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 45px;"|✔ New Cancellation Request Is Submitted
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Enable/Disable SMS Notifications Per Administrator
 
|}
 
|}
 
{|
 
{|
Line 69: Line 105:
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ View Clients And Orders Verification Status
+
|style="padding: 0px 0px 0px 30px;"|✔ View Verification Status Of Clients And Orders On WHMCS Lists
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Manage Clients Verification Status, Accepting SMS And Marketing SMS Agreements From Addon
 
|}
 
|}
 
{|
 
{|
Line 79: Line 118:
 
{|
 
{|
 
|style="padding: 0px 0px 0px 30px;"|✔ SMS Templates - Merge Fields Support
 
|style="padding: 0px 0px 0px 30px;"|✔ SMS Templates - Merge Fields Support
|}
 
{|
 
|style="padding: 0px 0px 0px 30px;"|✔ Characters Counter - Trace Length Of Your Messages
 
 
|}
 
|}
 
{|
 
{|
Line 91: Line 127:
 
{|
 
{|
 
|style="padding: 0px 0px 0px 30px;"|✔ Adjust Format Number To International Automatically
 
|style="padding: 0px 0px 0px 30px;"|✔ Adjust Format Number To International Automatically
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ View SMS History
 
|}
 
|}
 
{|
 
{|
Line 97: Line 136:
 
*'''Client Area Features:'''
 
*'''Client Area Features:'''
 
{|
 
{|
|style="padding: 10px 0px 0px 30px;"|✔ Define SMS Notifications To Receive
+
|style="padding: 10px 0px 0px 30px;"|✔ Choose To Opt-In/Out From Receiving SMS Messages
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Choose SMS Notifications To Receive
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ View SMS History
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 10px 30px;"|✔ Request SMS Token To Resend
+
|style="padding: 0px 0px 10px 30px;"|✔ Request SMS Token To Be Resent
 
|}
 
|}
 
*'''Security And Verification:'''
 
*'''Security And Verification:'''
Line 116: Line 161:
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 10px 30px;"|✔ Verify New Orders With SMS Token
+
|style="padding: 0px 0px 0px 30px;"|✔ Verify New Orders With SMS Token:
 +
|}
 +
{|
 +
|style="padding: 0px 0px 10px 45px;"|✔ Before And/Or After Checkout
 
|}
 
|}
 
*'''Mass SMS Recipient Filtering:'''
 
*'''Mass SMS Recipient Filtering:'''
Line 130: Line 178:
 
{|
 
{|
 
|style="padding: 0px 0px 0px 45px;"|✔ Account Languages
 
|style="padding: 0px 0px 0px 45px;"|✔ Account Languages
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 45px;"|✔ Account Brand
 
|}
 
|}
 
{|
 
{|
Line 158: Line 209:
 
|style="padding: 0px 0px 10px 45px;"|✔ Purchased Product Servers
 
|style="padding: 0px 0px 10px 45px;"|✔ Purchased Product Servers
 
|}
 
|}
*'''Supported Gateways:'''
+
*'''Supported SMS Gateways:'''
 
{|
 
{|
|style="padding: 10px 0px 0px 30px;"|✔ BearSMS
+
|style="padding: 10px 0px 0px 30px;"|✔ 4jawaly
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Africa's Talking
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Amazon SNS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Aruba Network
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Atomic SMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Bandwidth.com
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ BearSMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Beem Africa
 
|}
 
|}
 
{|
 
{|
 
|style="padding: 0px 0px 0px 30px;"|✔ BoxisSMS
 
|style="padding: 0px 0px 0px 30px;"|✔ BoxisSMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ BudgetSMS
 
|}
 
|}
 
{|
 
{|
 
|style="padding: 0px 0px 0px 30px;"|✔ BulkSMS
 
|style="padding: 0px 0px 0px 30px;"|✔ BulkSMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Burst SMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ BYTEHAND
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Cheap Global SMS
 
|}
 
|}
 
{|
 
{|
Line 172: Line 256:
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ Fastsms
+
|style="padding: 0px 0px 0px 30px;"|✔ ClickSend
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ CommzGate
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Dialpad
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ EBulkSMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ eSMS.vn
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ FastSMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ FireText
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Geez SMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Grameenphone
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Gretor SMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Hajana One
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ HostPinnacle
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ ICOMBD
 
|}
 
|}
 
{|
 
{|
 
|style="padding: 0px 0px 0px 30px;"|✔ InfoBip
 
|style="padding: 0px 0px 0px 30px;"|✔ InfoBip
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ IT Core
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Kavenega
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ MEDIA SAT
 
|}
 
|}
 
{|
 
{|
 
|style="padding: 0px 0px 0px 30px;"|✔ MessageBird
 
|style="padding: 0px 0px 0px 30px;"|✔ MessageBird
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ MiM SMS-eSMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Mobishastra
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Mocean SMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Msegat
 
|}
 
|}
 
{|
 
{|
 
|style="padding: 0px 0px 0px 30px;"|✔ Nexmo
 
|style="padding: 0px 0px 0px 30px;"|✔ Nexmo
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ OnnoRokom SMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ OVH SMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Releans
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ SemySMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ SerwerSMS.pl
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Sinch
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ sms77.io
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ SMSAPI.com - [https://www.smsapi.com/en/signup#UNKM Sign up now on preferential terms]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ SMSAPI.pl - [https://www.smsapi.pl/rejestracja#JTMT Sign up now on preferential terms]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ SMS Bao
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ SMS Broadcast
 
|}
 
|}
 
{|
 
{|
 
|style="padding: 0px 0px 0px 30px;"|✔ SMSEagle
 
|style="padding: 0px 0px 0px 30px;"|✔ SMSEagle
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ SMS Gateway Me
 
|}
 
|}
 
{|
 
{|
Line 190: Line 367:
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 10px 30px;"|✔ Twilio
+
|style="padding: 0px 0px 0px 30px;"|✔ SMS Maldives (SMSMV)
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ SMSO.ro
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ SMSPortal
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ SMSpubli
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ smss.co.il
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Sozuri
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Telenor
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Telnyx
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ TextAnywhere
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Textlocal
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Textplode
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ TraiTel
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Trio Mobile
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ TurboSMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Twilio
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Unifonic
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ VasPro
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ VoIP.ms
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Voodoo SMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ WebSMS.lk
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ WinSMS
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Yamamah
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Yunpian
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Zettatel
 +
|}
 +
{|
 +
|style="padding: 0px 0px 10px 30px;"|✔ Missing your favorite SMS gateway? [https://www.blog.modulesgarden.com/sms-center-for-whmcs-free-gateway We will integrate it for free!]
 
|}
 
|}
 
*'''General Info:'''
 
*'''General Info:'''
 
{|
 
{|
|style="padding: 10px 0px 0px 30px;"|✔ Module API - Integrate Other SMS Gateways
+
|style="padding: 10px 0px 0px 30px;"|✔ Meets GDPR Requirements
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ Integrated With <u>Client Profile Viewer For WHMCS</u> -  Send SMS From Any WHMCS Place [http://www.modulesgarden.com/products/whmcs/client-profile-viewer (read more)]
+
|style="padding:0px 0px 0px 30px;"|✔ Module API - Integrate Other SMS Gateways
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Integrated With <u>Client Profile Viewer For WHMCS</u> -  Send SMS From Any WHMCS Place [https://www.modulesgarden.com/products/whmcs/client-profile-viewer (read more)]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Integrated With <u>Multibrand For WHMCS</u> -  Send Personalized SMS Messages Based On Clients Brands [https://www.modulesgarden.com/products/whmcs/multibrand (read more)]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Fully Integrated With [https://lagom.rsstudio.net/extensions/whmcs-modules-integration/sms-center-by-modulesgarden Lagom WHMCS Client Theme]
 
|}
 
|}
 
{|
 
{|
Line 203: Line 461:
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ Supports PHP 5.4 Up To PHP 7
+
|style="padding: 0px 0px 0px 30px;"|✔ Supports PHP 8.1 Back To PHP 7.4
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 0px 30px;"|✔ Supports WHMCS Templates Five and Six
+
|style="padding: 0px 0px 0px 30px;"|✔ Supports WHMCS Themes "Six" And "Twenty-One"
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 30px;"|✔ Supports WHMCS V6 and V7
+
|style="padding: 0px 0px 0px 30px;"|✔ Supports WHMCS V8.10 Back To WHMCS V8.6
 +
|}
 +
{|
 +
|style="padding: 0px 0px 0px 30px;"|✔ Requires ionCube Loader V12 Or Later
 +
|}
 +
{|
 +
|style="padding: 0px 0px 30px 30px;"|✔ Easy [https://www.docs.modulesgarden.com/How_To_Upgrade_WHMCS_Module Module Upgrade] To [https://www.modulesgarden.com/products/whmcs/sms-center#open-source-version Open Source Version]
 
|}
 
|}
  
 
=Installation=
 
=Installation=
 
{|
 
{|
|style="padding: 10px 0px 30px 15px;"|'''This tutorial will show you how to successfully install and configure SMS Center For WHMCS.''' <br />
+
|style="padding: 10px 0px 30px 15px;"|'''This tutorial will show you how to successfully install and configure [https://www.modulesgarden.com/products/whmcs/sms-center SMS Center For WHMCS.]''' <br />
We will guide you step by step through the whole installation and configuration process.  
+
We will guide you step by step through the whole installation and configuration process.<br/><br/>
 +
'' '''Note:''' If you are still using any versions of SMS Center For WHMCS '''prior to v3.x''', [https://www.docs.modulesgarden.com/SMS_Center_2.X_For_WHMCS read about it here].''
 
|}
 
|}
 
==Installation==
 
==Installation==
 
{|
 
{|
|style="padding: 10px 0px 20px 15px;"|'''1. Log in to your client area and download the module.'''
+
|style="padding: 10px 0px 20px 15px;"|'''1. Log in to our client area and download the module.'''
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_1.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_1.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 10px 15px;"|'''2. In the downloaded file you will find two packages that support different PHP versions.'''<br/>As presented on the screen below, the first one is dedicated to PHP 7, while the second one is aimed at PHP 5.4 up to PHP 5.6.<br/>It does not apply to open source versions.<br/>
+
|style="padding: 0px 0px 20px 15px;"|'''2. In the downloaded file you will find a package that supports PHP 7.4 up to 8.1.'''
'' '''Note''': You can check current PHP version in your WHMCS. To do so proceed to ''' 'Utilities' → 'System' → 'PHP Info'.'''
+
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_2.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:PHP74_81.png]]
 
|}
 
|}
 +
<!--
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|'''3. Extract the downloaded file and choose the one with the right PHP version. Upload and extract the PHP file into the main WHMCS directory.'''<br />
+
|style="padding: 0px 0px 15px 15px;"|'''Previous updates of the module may contain two packages dedicated to various PHP versions.'''<br/>
The content of PHP version files should look like this.  
+
The first one that supports PHP 5.6 up to PHP 7.1, and the second one addressed to PHP 7.2 up to PHP 7.4.<br/>
 +
'''''Note:''' Keep in mind that PHP versions 5.6 up to 7.1 are no longer officially supported and their security issues are not fixed or released any more. Find more info [http://php.net/supported-versions.php here].''
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_2_2.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:PHP56_74.png]]
 
|}
 
|}
 +
-->
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|'''4. When you install SMS Center For WHMCS for the first time you have to rename '' 'license_RENAME.php' '' file.'''<br />
+
|style="padding: 0px 0px 10px 15px;"|<!-- '' '''Important''': This situation does not affect [https://www.modulesgarden.com/products/whmcs/sms-center#open-source-version '''the open source version'''] of this module which can be applied to any PHP from version 5.6 and later.''<br/>'''''Note''': You can check the current PHP version in your WHMCS. To do so, proceed to ''' 'Utilities' 'System' → 'PHP Info'.'''-->
File is located in '' 'modules/addons/sms_center/license_RENAME.php'.'' Rename it from '' 'license_RENAME.php' '' to '' 'license.php'. ''
+
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_3.png]]
+
|style="padding: 0px 0px 15px 15px;"|'''3. Extract the package and upload its content into the main WHMCS directory.
 +
The content of the package to upload should look like this.
 +
|}
 +
{|
 +
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_2_2.png]]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 15px 15px;"|'''4. When you install SMS Center For WHMCS for the first time, you have to rename the '' 'license_RENAME.php' '' file.'''<br />
 +
The file is located in '' 'modules/addons/sms_center/license_RENAME.php'.'' Rename it from '' 'license_RENAME.php' '' to '' 'license.php'. ''
 +
|}
 +
{|
 +
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_3.png]]
 
|}
 
|}
 
{|
 
{|
 
|style="padding: 0px 0px 15px 15px;"|'''5. In order to configure your license key, you have to edit the previously renamed '' 'license.php' file. '' '''<br />
 
|style="padding: 0px 0px 15px 15px;"|'''5. In order to configure your license key, you have to edit the previously renamed '' 'license.php' file. '' '''<br />
Enter your license key between quotation marks as presented on the following screen. You can find your license key in your client area → '' 'My Products'. ''  
+
Enter your license key between the quotation marks as presented on the following screen. You can find your license key in our client area → '' 'My Products'. ''  
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_4.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_4.png]]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 15px 15px;"|'''6. In the next step, set up the  '' 'storage' '' folder as recursively writable.'''<br />
 +
This folder is available at '' 'yourWHMCS/modules/addons/sms_center/' ''.
 +
|}
 +
{|
 +
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_4_2.png]]
 
|}
 
|}
  
Line 257: Line 541:
 
|style="padding: 10px 0px 15px 15px;"|'''5. Now, you have to activate the module in your WHMCS system.'''<br/>
 
|style="padding: 10px 0px 15px 15px;"|'''5. Now, you have to activate the module in your WHMCS system.'''<br/>
 
Log in to your WHMCS admin area and proceed to '' 'Setup' '' → '' 'Addon Modules'. ''<br/>
 
Log in to your WHMCS admin area and proceed to '' 'Setup' '' → '' 'Addon Modules'. ''<br/>
Afterwards, find '' 'SMS Center' '' and press '' 'Activate' '' button.
+
Afterwards, find '' 'SMS Center' '' and press the '' 'Activate' '' button.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_5.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_5.png]]
 
|}
 
|}
 
{|
 
{|
 
|style="padding: 0px 0px 15px 15px;"|'''6. In the next step you need to permit access to this module.'''<br/>
 
|style="padding: 0px 0px 15px 15px;"|'''6. In the next step you need to permit access to this module.'''<br/>
To do so, click on '' 'Configure' '' button, tick checkboxes to assign desired admin roles.<br/>
+
To do so, click on the '' 'Configure' '' button and select the admin roles which should have access to the module.<br/>
Choose a country code prefix that will be automatically added to the client's SMS number if it has not been specified. Press '' 'Save Changes'. ''
+
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_6.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_6.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|'''7. Now, proceed to the addon → '' 'Integration Code' '' and follow integration instructions.'''<br/>
+
|style="padding: 0px 0px 15px 15px;"|'''7. Finally, set up the cron command line provided below and define its frequency (10 minutes interval is suggested).'''
Remember that integration depends on the WHMCS version and template that you are using.<br/>If your system used is WHMCS V6.x.x and template: '' 'Six', '' there is no need for you to do any integration.<br/>
+
php -q /yourWHMCS/modules/addons/sms_center/cron/cron.php SmsTask
However, if you are working with WHMCS V6.x.x template '' 'Five' '' or WHMCS V5 then you must insert the code snippets as it is explained on the screen below.
+
This will allow the module to send text messages.<br/>
 +
'' '''Important:''' Make sure that the 'exec' function is not blocked in your PHP configuration.''<br/><br/>
 +
<br/>
 +
'' '''Note:''' Once the cron is executed, '''it operates continuously'''. ''<br/>
 +
If you '''stop''' the cron processes manually, please also delete the entire content of the '' '/yourWHMCS/modules/addons/sms_center/storage/crons/' '' folder or execute the below command:
 +
rm -r /yourWHMCS/modules/addons/sms_center/storage/crons/*
 +
This will allow you to run the cron process again next time. Do not forget to replace '' 'yourWHMCS' '' with your WHMCS root location.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_8.png]]
+
|style="padding: 0px 0px 30px 15px;"|'''8. Congratulations, you have just successfully installed SMS Center For WHMCS!'''
|}
+
{|
+
|style="padding: 0px 0px 10px 15px;"|'''8. The last thing you need to still do is setting up a cron job. It is advised to set the cron job with a 1 or 2 minutes interval.'''<br/>
+
/your_whmcs_dir/modules/addons/sms_center/crons/cron.php
+
Remember to replace ''your_whmcs_dir'' with a correct directory of your system.
+
|}
+
{|
+
|style="padding: 0px 0px 30px 15px;"|'''9. You have just successfully installed SMS Center For WHMCS!'''
+
 
|}
 
|}
  
Line 293: Line 574:
 
==Configuration==
 
==Configuration==
 
{|
 
{|
|style="padding: 10px 0px 30px 15px;"|Under '' 'Configuration' '' tab you will find  '' 'Submodules', 'Administrators' '' and '' 'General' '' sections. Configure each of them to allow full usage of SMS Center For WHMCS module.<br/>
+
|style="padding: 10px 0px 30px 15px;"|Under '' 'Configuration' '' tab you will find  '' 'General', 'SMS Gateways', 'Administrators' '' and '' 'Rules' '' sections. Configure each of them to allow full usage of SMS Center For WHMCS module.<br/>
Press the first one '' 'Submodules' '' to configure and check connection with SMS gateways.
+
Press the first one '' 'SMS Gateways' '' to configure and check connection with SMS gateways.
 
|}
 
|}
===Submodules Configuration===
+
===SMS Gateways Configuration===
 +
====Simple Gateway Configuration====
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|Find here all possible gateways that can be used in our module.<br/>
+
|style="padding: 10px 0px 15px 15px;"|Here you will find all possible gateways that can be used in our module.<br/>
You can use a recommended '' 'FastSMS' '' gateway:
+
Press '' 'Simple Configuration' '' next to a gateway you wish to use.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_9_1.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_9.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 15px;"|Or choose form other acceptable gateways:
+
|style="padding: 0px 0px 15px 15px;"|Configuration of each gateway may vary depending on its requirements.<br/>
 +
Apart from connection details, you may here also enable debug mode to log API requests and responses.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_9_2.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_10.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 15px;"|Press '' 'Configuration' '' next to a gateway you wish to use.
+
|style="padding: 0px 0px 20px 15px;"|You can check whether configuration is correct through pressing '' 'Check Connection'.''
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_9.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_11.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|Configuration of each gateway may vary depending on its requirements.<br/>
+
|style="padding: 0px 0px 15px 15px;"|If connection is successful, you can proceed further.<br/>
As an example we will configure SMSEagle gateway.<br/>
+
Press '' 'Enable' '' next to the gateway to activate it.
Apart from connection details, you may here define which countries the gateway shall be used in.<br/>
+
In case you are going to activate more than one gateway, you must point one of them as default.
+
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_10.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_12.png]]
 
|}
 
|}
 +
 +
====Advanced Gateway Configuration====
 
{|
 
{|
|style="padding: 0px 0px 20px 15px;"|You can check whether configuration is correct through pressing '' 'Check Connection'.''
+
|style="padding: 10px 0px 15px 15px;"|Advanced gateway configuration allows you to use multiple credentials for the chosen gateway type.<br/>
 +
This feature can prove useful when you want to use a single gateway submodule with configurations from accounts dedicated to various countries.
 +
<br/><br/>
 +
To start, to go to '' 'Configuration' '' → '' 'General', '' enable the '' 'Advanced Settings' '' option and save changes.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_11.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_9_2.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|If connection is successful, we can proceed.<br/>
+
|style="padding: 0px 0px 15px 15px;"|When you go back to the '' 'SMS Gateways' '' section, press the '' 'Advanced Configuration' '' button next to the chosen gateway and you will notice it has replaced the '' 'Simple Configuration'.''<br/>
Activate the gateway, press '' 'Enable' '' next to it.
+
Now you will be redirected to a new section, where you can add multiple configurations for a chosen gateway.<br/>
 +
Simply, press the '' 'Add Settings' '' button to add a new configuration option.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_12.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_10_2.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|As mentioned before, you may activate more than one gateway.<br/>
+
|style="padding: 0px 0px 20px 15px;"|Next, add your gateway configuration in the same way as you would do during a simple configuration. Additionally, enter your '' 'Settings Name' '' to be able to distinguish this configuration from others afterward.<br/>
All you need to remember is to set one gateway as default, assignment of countries to a gateway is not obligatory.<br/>
+
'' '''Note:''' You can have as many configurations as you want. You will determine which configuration will be used in which case later on, in the [https://www.docs.modulesgarden.com/SMS_Center_For_WHMCS#Rules rules] section.''
If a gateway has no countries assigned, but is set as default, then text messaged will be sent via this gateway and localization requirements are not fulfilled with any other gateway.<br>
+
If active gateway is not set as default and there are no countries assigned to it, such gateway will simply be not used.
+
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_12_1.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_11_2.png]]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 15px 15px;"|To check if your configurations have been saved properly, go back to the gateway list and press the '' 'Check Connection' '' button next to the gateway you had configured.<br/>
 +
Then, in the newly opened window you will be able to select one of your saved configurations and perform a connection test.
 +
|}
 +
{|
 +
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_12_2.png]]
 
|}
 
|}
  
===Administrators Configuration===
+
===Administrator Notifications===
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|This section contains a list of all staff administrators.<br/>
+
|style="padding: 10px 0px 15px 15px;"|This section contains a list of all administrators.<br/>
You have the possibility here to decide who of them will receive SMS notifications and which notifications exactly.<br/>Follow the steps described below to configure staff notifications properly.<br/>
+
Here you can choose who exactly will receive particular SMS notifications.<br/>Follow the steps described below to configure staff notifications properly.<br/>
  
Press '' 'Administrators' '' under '' 'Configuration' '' tab.
+
Find the '' 'Administrator Notifications' '' section  under the '' 'Configuration' '' menu. Next, press '' 'Edit' '' next to the chosen administrator.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_22.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_22.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|In order to enable SMS notifications for administrators individually, firstly set configuration for them.<br/>
+
|style="padding: 0px 0px 15px 15px;"|In order to enable SMS notifications for each administrator individually, firstly set configuration for every one of them.<br/>
1. Fill in the administrator's phone number, where text messages with notifications will be sent.<br/>
+
1. Fill in the administrator's country code and phone number to which text messages with notifications will be sent.<br/>
2. Choose which of the available admin messages shall be sent to that administrator.<br/>
+
2. Choose which of the available admin messages will be sent to this particular administrator.<br/>
3. Choose products to notify when they are ordered.<br/>
+
3. Choose addons, products and domains which ordering will result in sending a notification to the specified administrator.<br/>
4. Select Ticket priority, you will be informed when a new ticket with selected priority is opened.  
+
4. Select ticket priorities to send notifications to the administrator whenever a ticket with such priority is opened.<br/>
Save changes.
+
5. Decide if you want to receive clients login notifications (you can select these clients in the '' 'Tools' ' '' → '' 'Clients' '' section).<br/>
 +
Confirm changes.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_23.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_23.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|Press '' 'Enable Notifications.' ''<br/>
+
|style="padding: 0px 0px 15px 15px;"|Finally, enable all remaining notifications you wish to receive.<br/>
Repeat these steps for every administrator you wish to receive admin notifications.
+
Repeat these steps for every administrator you wish to receive individual admin notifications.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_24.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_24.png]]
 
|}
 
|}
  
===General Settings===
+
===Rules===
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|In '' 'General' '' section there are specific SMS configuration possibilities. Configure those you wish to activate and '' 'Save' '' the changes once ready!<br/>
+
|style="padding: 10px 0px 15px 15px;"|The rules allow you to use different gateways (or their configurations) depending on the customer's country.<br/>
By default, '' 'SMS Center' '' for client area is enabled, you may disable it here.<br/>
+
You can find them under the '' 'Configuration' '' '' 'Rules' '' menu. To add a rule, press '' 'Edit' '' next to the chosen gateway configuration.<br/>
''Note for WHMCS V5: You must insert integration code snippets to properly use SMS Center in your client area.<br/> If you disable it once codes are inserted, the button will still be visible in your client area but you will not be able to access it.''
+
 
 +
'' '''Note:''' Make sure that you have already your [https://www.docs.modulesgarden.com/SMS_Center_For_WHMCS#SMS_Gateways_Configuration SMS gateways] configured and enabled. Otherwise, the rules will not show up.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_24_1.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_24_2.png]]
 
|}
 
|}
====Order SMS Activation====
 
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|Enable '' 'Order SMS Activation' '' to allow activating orders once placed.<br/>
+
|style="padding: 0px 0px 15px 15px;"|Now, select countries for which a particular gateway configuration will be applied. The selected country may only be assigned to one rule.<br/>You can also mark the gateway as default, which means that it will also be used if no other rule concerning the customer's country is met.<br/>
Once an order is placed a client will receive a text message with a token, which must be then used to finish the order.<br/>
+
'' '''Note:''' Only '''one''' rule can be set as default. If you want the gateway to be used only when other rules are not met, set it as 'Default' and leave the 'Countries' field empty.''
You may define here how many times a client will be allowed to ask the token to sent again within one hour.<br/>
+
''Note, this option does not support orders upgrades!''
+
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_24_2.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_24_3.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|If the above option is enabled, a client when placing an order before being able to complete it must enter a valid token that was sent via SMS.<br/>Only then the order can be completed.<br/>
+
|style="padding: 0px 0px 20px 15px;"|Finally, toggle the status to enable your newly created rules.<br/>
Depending on the settings, you may allow clients to ask for resending the token.<br/>The client only needs to press '' 'Resend Token' '' button and they will receive another text message.
+
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_37.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_24_4.png]]
 
|}
 
|}
 +
 +
===General Configuration ===
 +
{|
 +
|style="padding: 10px 0px 30px 15px;"|In the '' 'General' '' section you can find specific SMS configuration possibilities. Configure those you wish to activate and save changes when ready.
 +
|}
 +
 +
====General Settings====
 
{|
 
{|
|style="padding: 0px 0px 20px 15px;"|If provided token is correct, the order's verification status is changed to '' 'Confirmed'.''
+
|style="padding: 10px 0px 15px 15px;"|By default, the '' 'SMS Center' '' section in the client area is disabled. You may enable it here.<br/>
 +
You can also toggle the advanced settings used for [https://www.docs.modulesgarden.com/Working_Area#Advanced_Gateway_Configuration advanced gateway configuration].<br/>
 +
Choose a country code prefix that will be automatically added to the client's SMS number if it had not been specified, or select '' "None" '' if the code prefix is already stored. <br/>
 +
If you want to use a dedicated custom field for your client's SMS number, you can enable this feature here.<br/>
 +
Otherwise, the default phone number from the client's profile will be used for sending SMS notifications.<br/>
 +
'' '''Note:''' If you enable this feature, do not forget to select which custom fields from the 'Custom Fields' box you wish to use specifically.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_37_1.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_24_0.png]]
 
|}
 
|}
  
 
====Client SMS Activation====
 
====Client SMS Activation====
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|Enable '' 'Client SMS Activation' '' and every newly activated client will receive a token, which must be used to end up the activation process.<br/>
+
|style="padding: 10px 0px 15px 15px;"|Enable '' 'Client SMS Activation' '' to grant each newly activated client a token which they will use to complete the activation process.<br/>
Declare time intervals for sending tokens here and allowed number of attempts to resend the token.
+
Determine time intervals for sending tokens and maximum number of attempts to resend a token.<br/>
 +
''Token Validity Period (Days)'' - define the number of days the token remains valid. After the provided here number of days, a client is marked as unverified. <br/> Type in "0" to disable this option.  
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_24_4.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_36.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 15px;"|With the above option enabled, the process of a new client's activation is a little bit different. Start with filling out the client's details.
+
|style="padding: 0px 0px 20px 15px;"|When you enable the above option, the activation process of a new client proceeds in a slightly different way. Start with filling out your client's details.<br/>
 +
You can also accept the SMS agreements, but it is not required to receive the account activation token through SMS.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_36.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_36_0.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 15px;"|When added, the client's verification status will be '' 'Unconfirmed'.''
+
|style="padding: 0px 0px 20px 15px;"|When registered, the client's verification status will be '' 'Unconfirmed'.''
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_36_1.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_36_1.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|To verify activation the new client needs to log in to their client area page and type in a token received via SMS.<br/>
+
|style="padding: 0px 0px 15px 15px;"|To verify activation after registration, the new client will have to type in a token received via SMS.<br/>
If allowed by the administrator, client may request sending the token again by pressing '' 'Resend Token' '' button.
+
If the administrator enables such possibility, the client may request sending the token again by pressing the '' 'Resend Token' '' button.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_36_2.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_36_2.png]]
 
|}
 
|}
 
{|
 
{|
 
|style="padding: 0px 0px 15px 15px;"|
 
|style="padding: 0px 0px 15px 15px;"|
As an administrator you can also verify client's account manually.
+
As an administrator you can also verify the client's account manually.
 
<br/>To do so, go to your client's profile and click the '' 'Verify' '' button:
 
<br/>To do so, go to your client's profile and click the '' 'Verify' '' button:
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_36_4.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_36_4.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 15px;"|Client's status has now changed to '' 'Confirmed'.''
+
|style="padding: 0px 0px 20px 15px;"|After successful verification, the client's status will change to '' 'Confirmed'.''
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_36_3.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_36_3.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 15px;"|Please be advised that whenever the client changes their phone number - the status will revert to '' 'Unconfirmed' '' and the verification process will have to be repeated.
+
|style="padding: 0px 0px 30px 15px;"|Please be advised that whenever the client changes their phone number, their status will change back to '' 'Unconfirmed' '' and the verification process will have to be repeated.
 +
|}
 +
 
 +
====Order SMS Activation====
 +
{|
 +
|style="padding: 10px 0px 15px 15px;"|Enable '' 'Order SMS Activation' '' to allow activating orders.<br/>
 +
Decide when the order verification shall be forced:
 +
* before checkout
 +
* after checkout
 +
* before & after checkout<br/>
 +
A client will receive a text message with a token, which must be then used to move to the next step.<br/>
 +
Here you can also define how many times within one hour a client will be allowed to ask for a token to be sent again.<br/>
 +
'' '''Note:''' This option does not support order upgrades!''
 +
|}
 +
{|
 +
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_24_1.png]]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 15px 15px;"|If the above option is enabled, a client will have to enter a valid token received via SMS in order to complete the placed order.<br/>
 +
Depending on the settings, you may allow clients to ask for resending the token.<br/>If such option is enabled, your client will simply need to press the '' 'Resend Token' '' button and they will receive another text message.
 +
|}
 +
{|
 +
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_37.png]]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 20px 15px;"|If the provided token is correct, the order's verification status will change to '' 'Confirmed'.''
 +
|}
 +
{|
 +
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_37_1.png]]
 
|}
 
|}
  
 
====SMS Queuing====
 
====SMS Queuing====
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|Enable this option to allow text messages queues.<br/>
+
|style="padding: 10px 0px 15px 15px;"|Enable this option to allow queuing of text messages. Note that this will not cover tokens sent for activations.<br/>
Declare time intervals between attempts to send text messages and the number of messages that can be sent in one attempt.<br/>Finally, choose time period when text messages can be sent to clients.
+
Determine time intervals between next resending attempts and the total number of messages that can be sent in one attempt.<br/>Finally, choose the time period when text messages will be sent to clients.<br/>
Detailed information on this function is described [http://www.docs.modulesgarden.com/SMS_Center_For_WHMCS#SMS_Queue here.]
+
'' '''Note:''' Time intervals are based on your current WHMCS server time.''<br/>
 +
 
 +
Detailed information on this function is provided [https://www.docs.modulesgarden.com/SMS_Center_For_WHMCS#SMS_Queue here.]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_24_3.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_24_5.png]]
 
|}
 
|}
 +
 
====Token Configuration====
 
====Token Configuration====
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|In this section you can also change default token settings by defining own token length and available characters set.<br/>
+
|style="padding: 10px 0px 15px 15px;"|In this section you can also change default token settings by providing your own token length as well as allowed character sets.<br/>
 
Please note that allowed set of characters used for generating a token may contain chars from the following range only:  
 
Please note that allowed set of characters used for generating a token may contain chars from the following range only:  
 
  1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
 
  1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
 +
Any other special characters like: ", &, >, < or similar may cause unpredictable errors.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_24_6.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_24_6.png]]
 
|}
 
|}
  
 
====Custom Fields====
 
====Custom Fields====
 
{|
 
{|
|style="padding: 10px 0px 20px 15px;"|Finally, select which of the existing client custom fields should be used to provide the client phone number to send messages.
+
|style="padding: 10px 0px 20px 15px;"|Finally, select which of the existing client custom fields should be used to provide the client phone number to send messages.<br/>
 +
'' '''Note:''' Choose only if you had enabled the 'Use Custom Number' from the 'General Settings', because otherwise the default WHMCS number will be used and any additional custom fields will not be required.  
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_24_5.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_24_7.png]]
 
|}
 
|}
  
==Management==
+
====Skip Queue====
===Templates===
+
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|'' 'Templates' '' tab contains the list of message templates. Each email template in your system has its text message counterpart.<br/>
+
|style="padding: 10px 0px 20px 15px;"|If you want the messages that are sent from the client's profile to skip the queue then enable the '' 'Skip Queue' '' option.  
Any of these messages can be enabled/disabled through marking/unmarking checkbox next to them and pressing '' 'Save'. ''<br/>
+
''Note: Titles of the messages templates can be translated in the module language file. ''
+
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_13.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_24_8.png]]
 
|}
 
|}
 +
====Invoice Activation====
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|Module comes with default message templates, but you can edit each of them.<br/>
+
|style="padding: 10px 0px 20px 15px;"|If you want clients to check invoices that are not assigned to any order using a token delivered via SMS, then enable the '' 'Invoice Without Order Activation' '' option.  
Press '' 'Edit' '' to do so.
+
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_13_1.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_24_9.png]]
 
|}
 
|}
 +
 +
====Logs====
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|The first field is a default message of the template. Our module allows you to define messages for selected languages.<br/>
+
|style="padding: 10px 0px 15px 15px;"|Logs are by default turned on, if you want to hide the "Logs" section from the top menu, you may do it here.<br/>
In order to prepare a message in an additional language, select desired language from a dropdown menu and press '' 'Add' '' as shown on the following screen.
+
It is also possible to set up the logs to be automatically cleared after the specified here number of days.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_14.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_25_0.png]]
 
|}
 
|}
 +
 +
==Management==
 +
===Templates===
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|As you can see on the screen below, a new field for chosen language appeared.<br/>
+
|style="padding: 10px 0px 15px 15px;"|The '' 'Templates' '' tab contains the list of message templates. Each email template in your system has its text message counterpart.<br/>
You can remove any additional language through pressing '' 'x' '' icon next to it.<br/>
+
Any of these messages can be enabled/disabled by the '' 'Status' '' toggle or using the mass actions feature.<br/>
''Note: Language of a message sent is based on client's language, if message for client's language is not defined, default message will be sent.''
+
Every enabled template in admin area will then be also visible in the client area, where your clients can decide whether or not they want to receive chosen SMS notifications.<br/>
 +
 
 +
'' '''Note:''' Titles of the message templates can be translated in the module language file. ''
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_15.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_13.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|Module template supports merge fields which can be easily injected into messages.<br/>
+
|style="padding: 0px 0px 15px 15px;"|By default, the module comes with simplified message templates, but you can edit each of them.<br/>
Simply, click on the wanted merge field, it will be injected into currently edited version of the message.
+
First, choose the message category from the tabs above, and then press '' 'Edit' '' next to the chosen template.<br/>
 +
'''''Note:''' Custom templates include no content, please add the custom template message by yourself.''
 +
|}
 +
{|
 +
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_13_1.png]]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 15px 15px;"|The first record on the list is a default message of the template. Our module allows you to define messages in selected languages.<br/>
 +
In order to prepare a message in an additional language, press '' 'Add New Template Language' '' as shown on the following screen.
 +
|}
 +
{|
 +
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_14.png]]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 15px 15px;"|As you can see on the screen below, a new window appeared.<br/>
 +
Select the desired language from the dropdown menu and add your translated massage.<br/>
 +
 
 +
Module template supports merge fields which can be easily inserted into messages.<br/>
 +
Simply click on the desired merge field and it will be added into the currently edited version of the message.<br/>
 +
 
 +
Below the message field, there is a characters counter which helps to estimate the message length. <br/>
 +
The fixed message characters are counted, if there is a variable used, then the counter estimates the length and displays e.g. "104+".
 +
 
 +
'' '''Note:''' The Language of sent messages is the client's language. If you do not define a message in your client's language, the default message will be sent instead.''
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_16.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_15.png]]
 
|}
 
|}
  
Line 525: Line 889:
 
{|
 
{|
 
|style="padding: 10px 0px 15px 15px;"|In this section you will find a list of all text messages waiting for a cron run to be sent.<br/>
 
|style="padding: 10px 0px 15px 15px;"|In this section you will find a list of all text messages waiting for a cron run to be sent.<br/>
Specific details on messages that can be sent in one attempt are specified in '' 'General' '' section.<br/>If SMS Queues are enabled every single message before being sent is placed on this list. With every cron run a previously set up number of messages is sent.<br/>If message sending fails (because the number is incorrect, there are problems with gate, no funds etc.) such SMS stays on the list for the next attempt.<br/>After three failed attempts its status is changed to '' 'Aborted'. ''
+
Specific details on messages that can be sent in one attempt are specified in the '' '[https://www.docs.modulesgarden.com/SMS_Center_For_WHMCS#SMS_Queuing General]' '' section.<br/>If SMS queues are enabled, every single message (except activation tokens) is placed on this list before being sent. With every cron run a previously set number of messages is sent.<br/>If message sending fails (because the number is incorrect, there are problems with gate, no funds etc.), such SMS remains on the list until the next attempt.<br/>After three failed attempts its status is changed to '' 'Aborted'. ''
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|Actions:<br/>
+
|style="padding: 0px 0px 15px 15px;"|Available actions:<br/>
1. Send - send message manually.<br/>
+
1. Start - send message manually.<br/>
2. Reload - use when status has changed to '' 'Aborted' '' to bring it back to the queue.<br/>
+
2. Refresh - use when status has changed to '' 'Aborted' '' to bring it back to the queue.<br/>
 
3. Delete - remove message form the list.
 
3. Delete - remove message form the list.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_16_1.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_16_1.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 15px;"|Select multiple entries and remove them in bulk to save the time.
+
|style="padding: 0px 0px 20px 15px;"|To save time, you can also use mass actions.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_16_2.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_16_2.png]]
 
|}
 
|}
  
 
===Mass SMS===
 
===Mass SMS===
 
{|
 
{|
|style="padding: 10px 0px 30px 15px;"|Sending mass text messaged to your clients is a convenient tool that allows preparing ready made messages that will be delivered to group of clients according to specified configuration.  
+
|style="padding: 10px 0px 30px 15px;"|Sending mass text messages to your clients is a convenient tool that allows preparing messages that will be delivered to a group of clients according to a specified configuration.  
 
|}
 
|}
 
====Mass SMS Templates====
 
====Mass SMS Templates====
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|Firstly, move to '' 'Mass SMS' → 'Templates', '' there create templates for mass texting.<br/>
+
|style="padding: 10px 0px 15px 15px;"|Firstly, move to '' 'Mass SMS' → 'Templates', '' and create templates for mass messages there.<br/>
Press '' 'Create New Template' '' to begin.
+
To start with, choose a group to which the template will be connected and then press '' 'Add New Template' ''.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_44.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_44.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|You are moved to template creation site.<br/>
+
|style="padding: 0px 0px 15px 15px;"|Enter your template name and type in the message content. Use merge fields available for the group.<br/> Follow characters counter current rate to estimate the message length.<br/>
Enter your template name, choose a group it will belong to and type in the message text. Use available for the group merge fields.<br/>Do not forget to save the changes.
+
Do not forget to confirm changes.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_45.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_45.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 15px;"|All created templates are available to edit or remove when no longer used.
+
|style="padding: 0px 0px 20px 15px;"|All created templates are free to edit or remove when no longer used.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_46.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_46.png]]
 
|}
 
|}
  
 
====Mass SMS Configuration====
 
====Mass SMS Configuration====
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|Now, that you have created the templates move to  '' 'Mass SMS', '' there configure the recipient group. Use filtering fields to set it up as you need.<br/>
+
|style="padding: 10px 0px 20px 15px;"|Now that you have created the templates, move to  '' 'Mass SMS Configuration' '' to configure the recipient group. <br/>
Select the type of filtering, you can choose from:
+
Start by adding new settings.
*'' 'General' '' filtering
+
|}
 +
{|
 +
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_40.png]]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 15px 15px;"|Use filtering fields to set it up as you need. Enter the configuration name and select the type of filtering. You can choose from:
 +
*'' 'Client Filters' '' filtering
 
*filtering according to '' 'Addons', 'Domains' '' or '' 'Products'.'' <br/><br/>
 
*filtering according to '' 'Addons', 'Domains' '' or '' 'Products'.'' <br/><br/>
 
Each filter type configuration differs slightly, but there are some general settings available for each type. These are:
 
Each filter type configuration differs slightly, but there are some general settings available for each type. These are:
*Custom Fields - enable available custom fields;
+
*Custom Fields - enable available custom fields
*:'' 'Marketing SMS' '' is a default addon custom field, if you enable it, clients will receive marketing notifications
+
*:'' 'Marketing SMS' '' is a default addon custom field. If you enable it, the message will be sent only to customers who have given their agreement for SMS marketing.
 
*Client Group - select which of your client groups will receive the text message
 
*Client Group - select which of your client groups will receive the text message
 
*Client Status - you may choose clients to receive messages depending on their status in your system
 
*Client Status - you may choose clients to receive messages depending on their status in your system
*Language - select default language for the messages.<br/>
+
*Language - select default language for the messages
All the above sections are available for '' 'General' '' client filter.
+
*Brand Filtering - if you have Multibrand For WHMCS module active, here choose which brand this mass SMS configuration shall be applied to<br/>
 +
All above sections are available for '' 'General' '' client filter.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 25px;"|[[File:SMSC_40.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_40_2.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|Every other filter includes these options as well, but there are also some additional filters to choose form for each of the types:<br/>
+
|style="padding: 0px 0px 15px 15px;"|In the next step you can select a SMS mass template created earlier and add some additional filters depending on which of the '' 'Client Filters' '' you had selected in the previous step:<br/>
 
'''Client Filter - Addon'''<br/>
 
'''Client Filter - Addon'''<br/>
 
*select purchased addon
 
*select purchased addon
Line 593: Line 964:
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_41.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_41.png]]
 
|}
 
|}
 
{|
 
{|
Line 600: Line 971:
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_42.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_42.png]]
 
|}
 
|}
 
{|
 
{|
 
|style="padding: 0px 0px 15px 15px;"|'''Client Filter - Product'''
 
|style="padding: 0px 0px 15px 15px;"|'''Client Filter - Product'''
*select products from purchased ones
+
*select products from the list of purchased ones
 
*select product status
 
*select product status
 
*select assigned server<br/>
 
*select assigned server<br/>
Press '' 'Compose Message' '' to continue sending mass messages.
 
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_43.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_43.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|When you have your filter ready, you will be moved to the next step where you may create a new text message or upload one of your previously prepared templates.<br/>Choose it from dropdown menu and press '' 'Load'.'' When message is ready, press '' 'Next'. ''
+
|style="padding: 0px 0px 15px 15px;"|In the next step you will see what the final SMS will look like and preview the list of clients will receive the message (based on the previously selected filters).<br/>
 +
 
 +
If you want to save this filter for later use, click '' 'Save Filters' ''.<br/>
 +
Surely, you may edit here the list. Add/remove clients from the list to keep it up to date.
 +
 
 +
If everything is correct, press '' 'Send' to start sending messages to the clients.''  
 +
 
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_47.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_47.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|You can see now how the final SMS looks like and see the list of clients that will receive the message.<br/>
+
 
If everything is correct, press '' 'Send Message'.''  
+
===Tools===
 +
====Send SMS====
 +
{|
 +
|style="padding: 10px 0px 15px 15px;"|In the '' 'Tools' '' → '' 'Send SMS' '' you can send your custom SMS directly to any client or phone number using any of your gateways.<br/>
 +
Simply type in your message, you may use the available '' 'Client Related' '' and '' 'Other' '' variables to compose a dedicated message.<br/> Choose the client's default phone or SMS number from the list and choose which of your gateway configurations you want to use to send this message.
 +
|}
 +
{|
 +
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_49.png]]
 +
|}
 +
{|
 +
|style="padding: 10px 0px 20px 15px;"|Instead of selecting a client's number, you can also enter any number you want. In such case remember to leave the '' 'Client' '' field empty and provide a custom number in the field below.<br/>
 +
The '' 'Brand' '' field is available only if you have the Multibrand For WHMCS module active. Once you select a client, you may choose the brand within which the sms message will be sent.<br/> If the client is assigned to one brand only, the brand field is filled in automatically and has no impact on sending the message.<br/> Keep in mind that some of the variables such as {$company_name} will be branded in the message.
 +
 
 +
When the message is ready, press the '' 'Send' '' button which will add it to the '' '[https://www.docs.modulesgarden.com/SMS_Center_For_WHMCS#SMS_Queue SMS Queue]' ''.
 +
|}
 +
{|
 +
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_50.png]]
 +
|}
 +
 
 +
====Clients====
 +
{|
 +
|style="padding: 10px 0px 15px 15px;"|In the '' 'Tools' '' → '' 'Clients' '' you can find list of all your WHMCS clients with their current SMS verification status.<br/>
 +
From here you can easily manage the verification status as well as toggle [https://www.docs.modulesgarden.com/SMS_Center_For_WHMCS#Administrator_Notifications SMS notifications for administrators] to receive when a specified customer logs in to the client area.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_48.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_48.png]]
 
|}
 
|}
  
 
===Logs===
 
===Logs===
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|Messages sent to your clients are logged under '' 'Logs' '' tab.<br/>
+
|style="padding: 10px 0px 15px 15px;"|Messages sent to your clients are logged under the '' 'Logs' '' tab.<br/>
As you can see on the following screen, here you can find detailed information about each message sent automatically to a client after certain actions.
+
As you can see on the following screen, here you can find detailed information on each message sent automatically to a client notifying about certain actions.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_17.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_17.png]]
 +
|}
 +
 
 +
===SMS History===
 +
{|
 +
|style="padding: 10px 0px 15px 15px;"|In this section you will find a precise list of all SMS messages sent recently. If you want to find a particular client or mobile phone number, simply use the search box.
 +
|}
 +
{|
 +
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_17_1.png]]
 
|}
 
|}
  
Line 638: Line 1,044:
 
{|
 
{|
 
|style="padding: 10px 0px 15px 15px;"|From the clients' summary page you can send text messages to clients using only a simple box.<br/>
 
|style="padding: 10px 0px 15px 15px;"|From the clients' summary page you can send text messages to clients using only a simple box.<br/>
Type in the message text into the text field like on the screen below and press '' 'Send'. ''
+
Type in the message content into the text field like on the screen below and press '' 'Send'. ''
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_25.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_25.png]]
 
|}
 
|}
  
 
==Client Area==
 
==Client Area==
 +
===Opt-In/Out Agreements===
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|After placing integration code, a new position appears in the client area navigation menu.<br/>
+
|style="padding: 10px 0px 15px 15px;"|To meet the GDPR requirements, the client can decide to opt-in/out from receiving SMS message notifications and marketing massages during the registration process.<br/>
Through pressing it your client will be moved to configuration of SMS notification.
+
'' '''Note:''' You can edit the description of these rules in your 'WHMCS' → 'Setup' → 'Custom Client Fields' section.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_18.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_51.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|In this place your client can choose which notifications to receive.<br/>
+
|style="padding: 0px 0px 15px 15px;"|After registration, the options can later be changed in the client's profile.<br/>
''Note! Provide SMS Number in the client's profile. Otherwise SMS Notifications will be unavailable for that client.''
+
'' '''Important:''' The 'Accept SMS' field will be enabled by default for the already existing clients when you install the module for the first time.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_19.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_52.png]]
 
|}
 
|}
 +
 +
===Notifications Templates===
 +
{|
 +
|style="padding: 10px 0px 15px 15px;"|If enabled in [https://www.docs.modulesgarden.com/SMS_Center_For_WHMCS#General_Settings general settings], a new position will appear in the client area navigation menu.<br/>
 +
Through pressing it, your client will be moved to configuration of SMS notification.
 +
|}
 +
{|
 +
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_18.png]]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 15px 15px;"|Here, your client can choose which notifications to receive. Remember that only templates with the status enabled set in [https://www.docs.modulesgarden.com/SMS_Center_For_WHMCS#Templates templates configuration] will be visible to the clients.<br/>
 +
'' '''Note:''' If you are using a custom number field to store clients SMS numbers, make sure they are provided in their profiles. Otherwise, SMS notifications will be unavailable for that clients.''
 +
|}
 +
{|
 +
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_19.png]]
 +
|}
 +
 
==SMS Center Two-Factor Authentication==
 
==SMS Center Two-Factor Authentication==
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|'''SMS center For WHMCS consists of two parts, the actual SMS Center addon and the authentication addon.'''<br/>
+
|style="padding: 10px 0px 15px 15px;"|'''SMS center For WHMCS consists of two parts: the actual SMS Center addon and the authentication addon.'''<br/>
Two-Factor Authentication adds an extra layer of protection while logging in.<br/>Once enabled and configured, each time they sign in they will be asked to enter both username and password as well as the second factor like a security code.<br/>
+
Two-Factor Authentication adds an extra layer of protection while logging in.<br/>Once enabled and configured, each time your client signs in, they will be asked to enter both username and password as well as the second factor like a security code.<br/>
In order to activate it proceed to '' 'Setup' '' → '' 'Staff Management' '' → '' 'Two-Factor Authentication'. ''<br/>
+
In order to activate it, proceed to '' 'System Settings' '' → '' 'Two-Factor Authentication'. ''<br/>
Afterwards, find '' 'SMS Center Two-Factor Authentication,' '' and press '' 'Activate' '' button.
+
Afterwards, find '' 'SMS Center Two-Factor Authentication,' '' and press the '' 'Activate' '' button.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_20.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_20.png]]
 
|}
 
|}
 
{|
 
{|
 
|style="padding: 0px 0px 15px 15px;"|'''In the next step you need to configure the addon settings. '''<br/>
 
|style="padding: 0px 0px 15px 15px;"|'''In the next step you need to configure the addon settings. '''<br/>
 
To do so, fill out the data:
 
To do so, fill out the data:
*Enable for Clients - choose this option if you wish all clients to authenticate while logging in their account.
+
*Enable for Clients - choose this option if you wish all clients to authenticate while logging in to their accounts.
*Enable for Staff - choose this option if you wish all administrators to authenticate while logging in their account.
+
*Enable for Staff - choose this option if you wish all administrators to authenticate while logging in to their accounts.
*Activation Code Valid For - decide how long a received code shall be valid, in minutes. Used once before the first log in.
+
*Activation Code Valid For - decide how long (in minutes) a received code will be valid. Used once before the first log in.
*SMS Code Valid For - decide how long a received via SMS code shall be valid, in minutes. Used every time to log in after the first authentication.
+
*SMS Code Valid For - decide how long (in minutes) a received via SMS code will be valid. Used every time to log in after the first authentication.
*Code Length - specify of how many characters a code will be composed.
+
*Code Length - specify how many characters will be required by a code.
*Allowed Characters - define which characters can used to generate the codes. Please note that some of special characters may cause unpredictable errors.<br/> Keep that in min when selecting chars like: '' ", &, >, < '' or similar.
+
*Allowed Characters - define which characters can be used to generate codes. Please note that the allowed set of characters used for generating a token may contain chars from the following range only: <pre>1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz</pre> Any other special characters like: ", &, >, < or similar may cause unpredictable errors.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_21.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_21.png]]
 
|}
 
|}
  
==Security Settings==
+
===Security Settings===
===Clients===
+
====Clients====
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|If you have activated '' 'SMS Two-Factor Authentication' '' addon, your clients will be allowed now to decide if they wish to use such security opportunity.<br/>
+
|style="padding: 10px 0px 15px 15px;"|If you have activated the '' 'SMS Two-Factor Authentication' '' addon, your clients will be allowed to decide if they wish to use such a security option.<br/>
Here is how to enable such functionality:<br/>
+
Here is how to enable this functionality:<br/>
1. Log in to your client area, proceed to '' 'Account Details' '' → '' 'Security Settings'. '' <br/>There is a button, which once pressed enables two factors authentication configuration for the client.
+
1. Log in to your client area, proceed to '' 'Account Details' '' → '' 'Security Settings'. '' <br/>There is a button which enables two factors authentication configuration for the client.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_26.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_26.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 15px;"|2. Press '' 'Get Started' '' button to proceed with the process.
+
|style="padding: 0px 0px 20px 15px;"|2. Press the '' 'Get Started' '' button to proceed with the process.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_27.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_27.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|3. Provide phone number to proceed with SMS Two-Factors Authentication. Press '' 'Activate.' ''<br/>
+
|style="padding: 0px 0px 15px 15px;"|3. Provide a phone number to proceed with SMS Two-Factors Authentication. Press '' 'Activate.' ''<br/>
''This step will be skipped if the client entered a valid SMS number in the profile before!''
+
'' '''Note:''' This step is obligatory, no matter if the client has already provided a valid SMS number in the profile.''
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_28.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_28.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|4. A client should receive now an authentication code via SMS.<br/> Type in the code in the field and  press '' 'Activate'. ''<br/> ''Remember that the code is valid only temporarily, according to the addon settings!''  
+
|style="padding: 0px 0px 15px 15px;"|4. A client should receive now an authentication code via SMS.<br/> Provide the code in the field and  press '' 'Activate'. ''<br/> '' '''Note:''' Remember that the code is valid only temporarily, according to the addon settings!''  
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_29.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_29.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 15px;"|5. Two-Factor Authentication is now complete.  
+
|style="padding: 0px 0px 5px 15px;"|Two-Factor Authentication is now complete. <br/>
 +
'' '''Important:''' Remember to note and keep your backup code in a secure place!''
 
|}
 
|}
 +
<!--
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_30.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_30.png]]
 
|}
 
|}
 +
-->
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|6. The second factor is now required to log in. Wait for the SMS with verification code and enter it in the field. Press '' 'Login'. '' <br/>If you have any problems with receiving/entering the verification code, you can use your backup code. <br/> ''Remember to note and keep your new backup code in a secure place!''
+
|style="padding: 0px 0px 15px 15px;"|The second factor will now be required in the next login attempt. Wait for the SMS with verification code and enter it in the appropriate field. <br/>
 +
If you have any problems with receiving/entering the verification code, you can use your backup code. <br/>'' '''Important:''' In such situation remember to note and keep your new backup code in a secure place!''
 
|}
 
|}
 +
<!--
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_31.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_31.png]]
 +
|}
 +
-->
 +
{|
 +
|style="padding: 0px 0px 30px 15px;"|In case there are clients who, for some reasons, do not have the required phone number provided, you may turn off 2FA for such clients only.<br/>
 +
Use the below script to turn off the 2FA for such clients: 
 +
 
 +
php -q /yourWHMCS/modules/addons/sms_center/cron/cron.php Reset2FA 
 +
 
 +
Please make sure you have used a full and correct path to the module cron file.<br/>
 +
 
 +
Once you run this script, you will find information in the '' 'Logs' '' section about the 2FA being turned off for a particular client account. <br/> After the script turns off the 2FA, the client may log into the client area without the need to provide the 2FA token.<br/>
 +
 
 +
If the client wants to use 2FA security, he must turn it on again for his account ''(Security Settings).''<br/> He will get the option to provide the required phone number to be able to receive the authentication token during future login attempts.
 
|}
 
|}
  
===Administrators===
+
====Administrators====
 
{|
 
{|
|style="padding: 10px 0px 15px 15px;"|If  '' 'SMS Two-Factor Authentication' '' addon has been activated and enabled for staff, as an administrator you can decide if you wish to use such security opportunity. <br/>
+
|style="padding: 10px 0px 15px 15px;"|If the '' 'SMS Two-Factor Authentication' '' addon has been activated and enabled for staff, you will be able to decide as administrator if you wish to use such a security option. <br/>
Here is how to enable such functionality: <br/>
+
Here is how to enable this functionality: <br/>
 
1. Proceed to '' 'My Account.' '' Find '' 'Two-Factor Authentication' '' and enable it to start the Two-Factor Authentication process.
 
1. Proceed to '' 'My Account.' '' Find '' 'Two-Factor Authentication' '' and enable it to start the Two-Factor Authentication process.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_32.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_32.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 15px;"|2. Press '' 'Get Started' '' button to proceed with the process.
+
|style="padding: 0px 0px 20px 15px;"|2. Press the '' 'Get Started' '' button to proceed with the process.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_33.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_33.png]]
 
|}
 
|}
 
{|
 
{|
Line 744: Line 1,186:
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_34.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_34.png]]
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 15px 15px;"|4. If entered code is correct, you will see a proper information.<br/> There will also be a backup code which must be copied and saved securely to log in with in case of some issues.
+
|style="padding: 0px 0px 15px 15px;"|4. If entered code is correct, you will see proper information.<br/> There will also be a backup code which must be copied and saved securely to log in with in case of some issues.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC_35.png]]
+
|style="padding: 0px 0px 20px 25px;"|[[File:SMSC3_35.png]]
 
|}
 
|}
 
{|
 
{|
Line 756: Line 1,198:
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC_35_1.png]]
+
|style="padding: 0px 0px 30px 25px;"|[[File:SMSC3_35_1.png]]
 
|}
 
|}
  
==SMS Center And WHMCS API Integration==
+
==SMS Center and WHMCS API Integration==
 
{|
 
{|
|style="padding: 10px 0px 20px 15px;"|Underneath you can find a short instruction on how to integrate your SMS Center For WHMCS with the WHMCS API.
+
|style="padding: 10px 0px 20px 15px;"|Below you can find a short instruction on how to integrate your SMS Center For WHMCS with the WHMCS API.
 
|}
 
|}
 
{|
 
{|
Line 775: Line 1,217:
 
''(Relid)'' for ''(adminid)'' is an ''' 'array' '''<br/>
 
''(Relid)'' for ''(adminid)'' is an ''' 'array' '''<br/>
 
<br/>
 
<br/>
4. A typical usage example for sending an SMS with a specified message to the user with a given ID:<br/>
+
4. A typical example for sending an SMS with a specified message to the user with a given ID:<br/>
 
   
 
   
 
  localAPI('sendsms', array('userid' => $_POST['userid'], 'message' => $_POST['message']), 'admin');
 
  localAPI('sendsms', array('userid' => $_POST['userid'], 'message' => $_POST['message']), 'admin');
Line 786: Line 1,228:
 
In case you add ''phonenumber'' in the message, you have to specify whether it is an admin's number by entering: '' 'admin' => 1,'' just like in the example above.<br/> You do not need to add the above parameter for a user's number.<br/>
 
In case you add ''phonenumber'' in the message, you have to specify whether it is an admin's number by entering: '' 'admin' => 1,'' just like in the example above.<br/> You do not need to add the above parameter for a user's number.<br/>
 
<br/>
 
<br/>
6. SMS Center For WHMCS does also support '' 'force' '' parameter. If set to '' 'true' '' it allows to skip the queue for sending SMS messages and proceed with the task immediately.<br/><br/>
+
6. SMS Center For WHMCS does also support the '' 'force' '' parameter. If set to '' 'true' '', it allows to skip the queue for sending SMS messages and proceed with the task immediately.<br/><br/>
 
As an example:<br/>
 
As an example:<br/>
 
  localAPI('sendsms', array('userid' => $_POST['userid'], 'message' => $_POST['message'], 'force'=> true), 'admin');
 
  localAPI('sendsms', array('userid' => $_POST['userid'], 'message' => $_POST['message'], 'force'=> true), 'admin');
 +
|}
 +
==Custom Gateway In SMS Center==
 +
{|
 +
|style="padding: 10px 0px 15px 15px;"|Below you can find a short instruction on how to implement a new SMS gateway into the SMS Center For WHMCS module by yourself.<br/>
 +
Follow the below steps:
 +
'''1. Firstly, create a new PHP class in the directory:''' <pre>/modules/addons/sms_center/app/Libs/Sms</pre>
 +
which inherits the class: <pre>''ModulesGarden\SmsCenter\App\Libs\AbstractSms\AbstractSubmodule</pre>
 +
'''2. Inside that class, create the following two fields:'''
 +
* ''$name'' -  the name of the SMS gateway that will display in the "SMS Module" column inside the addon (marked as "1." on the screenshot below).
 +
* ''$description'' - a link to the SMS Gateway's website - this link will be displayed in the column "Description" (marked as "2."' on the screenshot below).<br/> Here is an example of what those fields should look like in the file:
 +
<pre> 
 +
public static $name                = "Gateway Name";
 +
public static $description        = '<a href="https://gatewayName.com/" target="_blank">www.gatewayName.com</a>';
 +
</pre>
 +
|}
 +
{|
 +
|style="padding: 0px 0px 20px 25px;"|[[File:SMS_36.png]]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 15px 15px;"|'''3. The next steps to follow here will be to define various functions inside the class.'''<br/>
 +
The first one to define is ''getConfiguration()'', which is used to build the gateway configuration form. The field types available to build this form can be found in the following class:
 +
<pre>
 +
ModulesGarden\SmsCenter\App\Helper\SubmodulesHelper\MG_SMS_SubmoduleConfiguration
 +
</pre>
 +
Here is an example of a function that can be defined here - adding this block to your file will create a form comparable to one you can view in the screenshot below:
 +
<pre>
 +
public static function getConfiguration()
 +
{
 +
    return array(
 +
        'username'    => array(
 +
            'validators' => array('required'),
 +
            'description' => true;
 +
        ),
 +
        'public_key'  => array(
 +
            'validators' => array('required'),
 +
        ),
 +
        'from'        => array(
 +
           
 +
        ),
 +
        'debug_mode'  => array(
 +
            'type'    => MG_SMS_SubmoduleConfiguration::TYPE_SELECT,
 +
            'options' => array('disable', 'enable'),
 +
        ),
 +
    );
 +
}
 +
</pre>
 +
|}
 +
{|
 +
|style="padding: 0px 0px 20px 25px;"|[[File:SMS_37.png]]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 15px 15px;"|'''4. Another function to define is ''checkConnection()'' - this button is usually used to send a request that returns the information concerning the available balance on the SMS Gateway account.'''<br/>
 +
The button in question can be seen here:
 +
|}
 +
{|
 +
|style="padding: 0px 0px 20px 25px;"|[[File:SMS_38.png]]
 +
|}
 +
{|
 +
|style="padding: 0px 0px 15px 15px;"|'''5. The function ''sendMessage($message, $number)'' should contain the logic used to send SMS messages - i.e. this function is used to handle the API of the gateway.'''<br/>
 +
The parameters:
 +
* ''$message'' - contains the main content of the SMS message
 +
* ''$number'' - the phone number onto which the message will be sent (including the country code)<br/>
 +
 +
'''6. Some additional tips:'''
 +
* You can access the gateway configuration data via
 +
$this>configuration['{name_of_configuration_field}'];
 +
You can replace "name_of_configuration_field" with any field, for example
 +
$this->configuration['username'];
 +
* Any time the module throws out an exception, you will receive the following error message: '' 'The connection test has failed:' ''
 +
|}
 +
{|
 +
|style="padding: 0px 0px 15px 15px;"|'''7. Below, you can find an example of a full class that contains all the above described functions. You can use that example as reference when adding your own gateway to the module.'''
 +
 +
<pre>
 +
<?php
 +
 +
namespace ModulesGarden\SmsCenter\App\Libs\Sms;
 +
 +
use ModulesGarden\SmsCenter\App\Libs\AbstractSms\AbstractSubmodule;
 +
use \ModulesGarden\SmsCenter\App\Helper\SubmodulesHelper\MG_SMS_SubmoduleConfiguration;
 +
 +
class Exmaple extends AbstractSubmodule{
 +
   
 +
    public static $name                = "Exmaple";
 +
    public static $description        = '<a href="https://example.com/" target="_blank">www.example.com</a>';
 +
   
 +
   
 +
    public function checkConnection()
 +
    {     
 +
        $username = $this->configuration['username'];
 +
        $url = 'https://payments.example.com/query/wallet/balance?username='.$username;
 +
        $this->sendRequest($url);
 +
    }
 +
   
 +
    public static function getConfiguration()
 +
    {
 +
        return array(
 +
            'username'    => array(
 +
                'validators' => array('required'),
 +
            ),
 +
            'public_key'  => array(
 +
                'validators' => array('required'),
 +
            ),
 +
            'from'        => array(
 +
               
 +
            ),
 +
            'debug_mode'  => array(
 +
                'type'    => MG_SMS_SubmoduleConfiguration::TYPE_SELECT,
 +
                'options' => array('disable', 'enable'),
 +
            ),
 +
        );
 +
    }
 +
   
 +
    public function sendMessage($message, $numbers)
 +
    {
 +
       
 +
        $username = $this->configuration['username'];
 +
        $url = 'https://api.example.com/version1/messaging';
 +
        $params = [
 +
            'username' => $username,
 +
            'to' => $numbers,
 +
            'message' => $message,                       
 +
        ];
 +
       
 +
        if($this->configuration['from'])
 +
        {
 +
            $params['from'] = $this->configuration['from'];
 +
        }
 +
 +
        $this->sendRequest($url, $params);
 +
    }
 +
       
 +
    private function sendRequest($url, $postFields = null)
 +
    {
 +
        $apikey = $this->configuration['public_key'];
 +
        $ch = curl_init();
 +
        curl_setopt($ch, CURLOPT_URL, $url);
 +
        if($postFields){
 +
            curl_setopt($ch, CURLOPT_POST, 1);
 +
            curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($postFields));
 +
        }
 +
        curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
 +
        curl_setopt($ch, CURLOPT_TIMEOUT, 60);
 +
        $header[] = "apiKey: $apikey";
 +
        $header[] = 'Accept: application/json';
 +
        curl_setopt($ch, CURLOPT_HTTPHEADER, $header);
 +
 +
 +
        $response = curl_exec($ch);
 +
 +
        if ($response == false)
 +
        {
 +
            $curlError = curl_error($ch);
 +
            if ($this->configuration['debug_mode'] == "enable")
 +
            {
 +
                $this->saveLog($url, $postFields, 'Curl error: ' . $curlError);
 +
            }
 +
            throw new \Exception('Curl error: ' . $curlError);
 +
        }
 +
        $jsonResponse = json_decode($response, true);
 +
       
 +
        if ($this->configuration['debug_mode'] == "enable")
 +
        {
 +
            $this->saveLog($url, $postFields, $response);
 +
        }
 +
 +
        if(empty($jsonResponse)){
 +
            throw new \Exception($response);
 +
        }
 +
       
 +
        if(!empty($response['SMSMessageData'])){
 +
            if($response['SMSMessageData']['Recipients'][0]['status'] != 'Success'){
 +
                throw new \Exception($response['SMSMessageData']['Recipients'][0]['status']);
 +
            }
 +
        }
 +
   
 +
        return $response;
 +
    }
 +
   
 +
 
 +
    private function saveLog($endpoint, $request ,$response)
 +
    {
 +
        logModuleCall(
 +
                'MG_SMS_Example', $endpoint, $request, $response, ""
 +
        );
 +
    }
 +
}
 +
</pre>
 
|}
 
|}
  
 
=Additional Information=
 
=Additional Information=
 
{|
 
{|
|style="padding: 10px 0px 20px 15px;"|1. SMS Center For WHMCS has been integrated with our [http://www.docs.modulesgarden.com/Client_Profile_Viewer_For_WHMCS Client Profile Viewer For WHMCS] module - enabling you to send messages to your clients in a faster and even more convenient way.
+
|style="padding: 10px 0px 20px 15px;"|1. SMS Center For WHMCS has been integrated with our [https://www.docs.modulesgarden.com/Client_Profile_Viewer_For_WHMCS Client Profile Viewer For WHMCS] module enabling you to send messages to your clients in a faster and even more convenient way.
 
|}
 
|}
 
{|
 
{|
 
|style="padding: 0px 0px 30px 15px;"|2. The messages sent by our module are divided into four categories:
 
|style="padding: 0px 0px 30px 15px;"|2. The messages sent by our module are divided into four categories:
* Messages sent automatically to clients after occurrence of specified actions (activity is logged in the addon '' 'Logs' '' tab).<br/>
+
* Messages sent automatically to clients after occurrence of specified actions (activity is logged in the addon's '' 'Logs' '' tab).<br/>
 
* Messages sent automatically to administrators after occurrence of specified actions (activity is logged in WHMCS '' 'Module Log' '').<br/>
 
* Messages sent automatically to administrators after occurrence of specified actions (activity is logged in WHMCS '' 'Module Log' '').<br/>
 
* Messages sent manually from client's profile (activity is logged in WHMCS '' 'Module Log' '').<br/>
 
* Messages sent manually from client's profile (activity is logged in WHMCS '' 'Module Log' '').<br/>
Line 805: Line 1,435:
 
=Tips=
 
=Tips=
 
{|
 
{|
|style="padding: 10px 0px 30px 15px;"|1. You may customize the text of '' 'Two-Factor Authentication' '' verification message delivered to a user.  <br/>
+
|style="padding: 10px 0px 5px 15px;"|1. You may customize the '' 'Two-Factor Authentication' '' verification message text delivered to a user.  <br/>
'' Default message: 'Your account activation token is: erkhq34j329' ''<br/>
+
E.g. the default messages are: '' 'Your activation code is: erkhq34j329' '' and  '' 'Your login code is erkhq34j329' ''<br/>
Change the message content in the addon language file.
+
Change the messages content in the addon language file by editing the following records:
 +
$_LANG['clientArea']['2FA']['loginCode']    = 'Your login code is :token:';
 +
$_LANG['clientArea']['2FA']['activateCode'] = 'Your activation code is :token:';
 
|}
 
|}
 +
{|
 +
|style="padding: 0px 0px 5px 15px;"|2. Invoice special merge fields clarification:
 +
*'''$invoice_items''' merge field is an array and should always be used within a '' 'foreach' '' clause to be displayed correctly<br/>
 +
*'''$invoice_items''' used with '''{$i.description}'''  displays all content including dates and domain name<br/>
 +
Example of usage:
 +
<pre>
 +
{foreach from=$invoice_items item=i} 
 +
{$i.description}
 +
{/foreach}
 +
</pre>
  
=Common Problems=
+
*'''$invoice_domains_registered''' special merge field that shows only the domain name.<br/>
 +
Example of usage:
 +
<pre>
 +
{foreach from=$invoice_domains_registered item=i} 
 +
<p>DOMAIN REGISTERED: {$i}</p>
 +
{/foreach}
 +
</pre>
 +
|}
 
{|
 
{|
|style="padding: 10px 0px 10px 15px;"|'''1. When you have problems with connection, check whether your SELinux or firewall does not block ports.'''
+
|style="padding: 0px 0px 5px 15px;"|3. Information on any errors that a cron task might encounter while being executred are stored in the following file:<br/>'' 'storage/logs/cron_log' ''<br/>
 +
Check the file content for cron errors details.
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 10px 15px;"|2. The module is not compatible with Multibrand For WHMCS: there are no contradictions to use the two products together, <br/>however, they are not integrated which means that a client may for example choose from (SMS) templates for every brand (text messages are not branded).
+
|style="padding: 0px 0px 15px 15px;"|4. There is the possibility to switch on all templates for all your clients. To do so, please follow these steps:
 +
*Log in by ssh
 +
*Proceed to '''your_whmcs/modules/addons/sms_center/shell'''
 +
*Enter this command if you want to set the default templates for clients that have the '''Accept SMS' '' option enabled:
 +
<pre> php -q runTask.php --taskName templates --taskAction setDefault </pre>
 +
*Provide this command if you want to set the default templates for all your clients:
 +
<pre>php -q runTask.php --taskName templates --taskAction setDefaultAll</pre>
 
|}
 
|}
 
{|
 
{|
|style="padding: 0px 0px 30px 15px;"|3. The module is not compatible with Resellers Center For WHMCS functionality.
+
|style="padding: 0px 0px 15px 15px;"|5. If you want to delete logs, you may need the following command. Firstly, proceed to '''<whmcs>/modules/addons/sms_center/shell''' and run the task:
 +
<pre> php runTask.php --taskName clear --taskAction logs </pre>
 +
|}
 +
{|
 +
|style="padding: 0px 0px 30px 15px;"|6. You may turn on/ turn off '' 'Accept SMS' '' and '' 'Marketing SMS' '' options for all clients using the following commands.
 +
Firstly, go to this folder  '''<whmcs>/modules/addons/sms_center/shell''' and run an appropriate task: <br/>
 +
*To enable or disable the '' 'Marketing SMS' '' option, use:
 +
<pre>php -q runTask.php --taskName marketingSms --taskAction enable
 +
php -q runTask.php --taskName marketingSms --taskAction disable </pre>
 +
* To enable or disable the '' 'Accept SMS' '' option, use:
 +
<pre>php -q runTask.php --taskName acceptSms --taskAction enable
 +
php -q runTask.php --taskName acceptSms --taskAction disable </pre>
 +
|}
 +
 
 +
=Update Instructions=
 +
{|
 +
|style="padding: 10px 0px 30px 15px;"|An essential guidance through the process of updating the module is offered '''[https://www.docs.modulesgarden.com/How_To_Update_WHMCS_Module here]'''.<br/><br/>
 +
'''Important:''' When updating the module from version 2.x to '''3.x''', you need to start the migration process to move settings from the previous version to the new one.<br/>To do this, first update your module files to the newest version and set '''recursively writable permissions''' for '''storage''' directory in '' 'yourWHMCS/modules/addons/sms_center/' '' location.<br/>
 +
Next, execute the following script in your server's console:
 +
php -q /yourWHMCS/modules/addons/sms_center/shell/migrationTo3_0_0.php
 +
Do not forget to replace '' 'yourWHMCS' '' with your WHMCS root location. <br/>
 +
The migration process covers: the configuration of SMS gateways, general settings, chosen template notifications by clients, administrators' phone numbers, SMS queues, SMS templates and Mass SMS templates. <br/>Any other settings might '''not''' be migrated!<br/>
 +
 
 +
If you are using [https://www.modulesgarden.com/products/whmcs/client-profile-viewer Client Profile Viewer For WHMCS] integration, you will also need to update it to the version 1.5.8 or later.
 +
|}
 +
=Upgrade Guide=
 +
{|
 +
|style="padding: 10px 0px 30px 15px;"|Seeking a solution that offers greater flexibility, customization tailored to your precise needs, and unrestricted availability?<br/> There is an option that not only proves to be cost-effective in the long run but also includes prioritized support services, making it a truly valuable investment.<br/>
 +
 
 +
Opt for the [https://www.modulesgarden.com/products/whmcs/sms-center#open-source-version Open Source version] of your SMS Center For WHMCS module to unlock these benefits.<br/> Simply click on either the '''Get Source Code''' or '''Upgrade To Lifetime''' button found on the product's page in our client area to complete the one-step upgrade process, with a '''dedicated discount''' already applied.<br/>
 +
 
 +
Follow a [https://www.docs.modulesgarden.com/How_To_Upgrade_WHMCS_Module comprehensive guide] covering the transition process, the advantages it brings, and step-by-step instructions on what to do next after the order has been successfully finalized.
 +
|}
 +
 
 +
=Common Problems=
 +
{|
 +
|style="padding: 10px 0px 10px 15px;"|'''1. When you have problems with connection, check whether your SELinux or firewall does not block ports.'''
 +
|}
 +
{|
 +
|style="padding: 0px 0px 30px 15px;"|2. The module is currently '''not''' compatible with:
 +
*[https://www.modulesgarden.com/products/whmcs/resellers-center Resellers Center For WHMCS]
 +
*[https://www.modulesgarden.com/products/whmcs/lagom-one-step-order-form Lagom One Step Order Form For WHMCS]
 +
 
 +
It is advised not to use the modules mentioned above at once.
 
|}
 
|}

Latest revision as of 14:06, 26 April 2024

Contents

[edit] About SMS Center For WHMCS

SMS Center For WHMCS is a module created to send text messages to your clients and administrators.

You will be given the possibility to choose from over 60 different SMS gateways, define SMS templates in various languages and manage bulk text messaging.
The module will also allow you to verify new clients and orders as well as enable SMS codes as part of two-factor authentication while logging in to your system.
Finally, your customers will be enabled to decide whether they wish to receive certain notifications or not.

  • Admin Area Features:
✔ Notify Your Clients And Administrators Via SMS Messages
✔ Use Single Or Multiple Configurations Per SMS Gateway
✔ Define SMS Gateway Rules Per Country
✔ Send SMS Using Client's Phone Number Field Or Custom Filed
✔ Use SMS Queue To Send SMS Within Defined Time Period
✔ Manage List Of Queued SMS
✔ Send Single SMS To Chosen Client Or Type In Any Number Manually
✔ Send Mass SMS Using Recipient Filtering
✔ Define SMS Template Counterpart Of Each Email Template
✔ Define Mass SMS Templates
✔ Estimate Message Length Using Character Counter
✔ Create Different Language Versions Of Each SMS Template
✔ Choose SMS Notifications To Be Received By Each Administrator
✔ Notify Chosen Administrators Via SMS When:
✔ Specified Product Is Ordered
✔ Specified Product Addon Is Ordered
✔ Specified Domain Is Ordered
✔ Ticket With Specified Priority Is Opened Or Flagged
✔ Support Ticket Have Response
✔ Support Ticket Department Reassigned
✔ Specified Administrator Or Client Logs In
✔ Product Automatic Setup Failed Or Succeeded
✔ Service Is Suspended
✔ Service Unsuspension Failed Or Succeeded
✔ Domain Renewal Failed Or Succeeded
✔ New Order Is Submitted
✔ New Cancellation Request Is Submitted
✔ Enable/Disable SMS Notifications Per Administrator
✔ Enable/Disable SMS Gateways
✔ Check Connection With SMS Gateways
✔ Enable/Disable SMS Templates
✔ View Verification Status Of Clients And Orders On WHMCS Lists
✔ Manage Clients Verification Status, Accepting SMS And Marketing SMS Agreements From Addon
✔ Manually Verify Client Status On Client Summary Page
✔ Send SMS From Client Summary Page
✔ SMS Templates - Merge Fields Support
✔ Choose Client Custom Field To Be Used As Client Phone Number
✔ Set Custom Token Length And Characters Set
✔ Adjust Format Number To International Automatically
✔ View SMS History
✔ View Logs
  • Client Area Features:
✔ Choose To Opt-In/Out From Receiving SMS Messages
✔ Choose SMS Notifications To Receive
✔ View SMS History
✔ Request SMS Token To Be Resent
  • Security And Verification:
✔ Two-Factor Authentication Submodule - Use Second Layer Of Security:
✔ Client Area Login
✔ Admin Area Login
✔ Verify New Client Accounts With SMS Token
✔ Verify New Orders With SMS Token:
✔ Before And/Or After Checkout
  • Mass SMS Recipient Filtering:
✔ Client Account Filter:
✔ Account Statuses
✔ Account Custom Fields
✔ Account Languages
✔ Account Brand
✔ Addon Filter:
✔ Purchased Addons
✔ Purchased Addon Statuses
✔ Domain Filter:
✔ Domain Statuses
✔ Product Filter:
✔ Purchased Products
✔ Purchased Product Statuses
✔ Purchased Product Servers
  • Supported SMS Gateways:
✔ 4jawaly
✔ Africa's Talking
✔ Amazon SNS
✔ Aruba Network
✔ Atomic SMS
✔ Bandwidth.com
✔ BearSMS
✔ Beem Africa
✔ BoxisSMS
✔ BudgetSMS
✔ BulkSMS
✔ Burst SMS
✔ BYTEHAND
✔ Cheap Global SMS
✔ Clickatell
✔ ClickSend
✔ CommzGate
✔ Dialpad
✔ EBulkSMS
✔ eSMS.vn
✔ FastSMS
✔ FireText
✔ Geez SMS
✔ Grameenphone
✔ Gretor SMS
✔ Hajana One
✔ HostPinnacle
✔ ICOMBD
✔ InfoBip
✔ IT Core
✔ Kavenega
✔ MEDIA SAT
✔ MessageBird
✔ MiM SMS-eSMS
✔ Mobishastra
✔ Mocean SMS
✔ Msegat
✔ Nexmo
✔ OnnoRokom SMS
✔ OVH SMS
✔ Releans
✔ SemySMS
✔ SerwerSMS.pl
✔ Sinch
✔ sms77.io
✔ SMSAPI.com - Sign up now on preferential terms
✔ SMSAPI.pl - Sign up now on preferential terms
✔ SMS Bao
✔ SMS Broadcast
✔ SMSEagle
✔ SMS Gateway Me
✔ SMSGlobal
✔ SMS Maldives (SMSMV)
✔ SMSO.ro
✔ SMSPortal
✔ SMSpubli
✔ smss.co.il
✔ Sozuri
✔ Telenor
✔ Telnyx
✔ TextAnywhere
✔ Textlocal
✔ Textplode
✔ TraiTel
✔ Trio Mobile
✔ TurboSMS
✔ Twilio
✔ Unifonic
✔ VasPro
✔ VoIP.ms
✔ Voodoo SMS
✔ WebSMS.lk
✔ WinSMS
✔ Yamamah
✔ Yunpian
✔ Zettatel
✔ Missing your favorite SMS gateway? We will integrate it for free!
  • General Info:
✔ Meets GDPR Requirements
✔ Module API - Integrate Other SMS Gateways
✔ Integrated With Client Profile Viewer For WHMCS - Send SMS From Any WHMCS Place (read more)
✔ Integrated With Multibrand For WHMCS - Send Personalized SMS Messages Based On Clients Brands (read more)
✔ Fully Integrated With Lagom WHMCS Client Theme
✔ Multi-Language Support
✔ Supports PHP 8.1 Back To PHP 7.4
✔ Supports WHMCS Themes "Six" And "Twenty-One"
✔ Supports WHMCS V8.10 Back To WHMCS V8.6
✔ Requires ionCube Loader V12 Or Later
✔ Easy Module Upgrade To Open Source Version

[edit] Installation

This tutorial will show you how to successfully install and configure SMS Center For WHMCS.

We will guide you step by step through the whole installation and configuration process.

Note: If you are still using any versions of SMS Center For WHMCS prior to v3.x, read about it here.

[edit] Installation

1. Log in to our client area and download the module.
SMSC3 1.png
2. In the downloaded file you will find a package that supports PHP 7.4 up to 8.1.
PHP74 81.png
3. Extract the package and upload its content into the main WHMCS directory.

The content of the package to upload should look like this.

SMSC3 2 2.png
4. When you install SMS Center For WHMCS for the first time, you have to rename the 'license_RENAME.php' file.

The file is located in 'modules/addons/sms_center/license_RENAME.php'. Rename it from 'license_RENAME.php' to 'license.php'.

SMSC3 3.png
5. In order to configure your license key, you have to edit the previously renamed 'license.php' file.

Enter your license key between the quotation marks as presented on the following screen. You can find your license key in our client area → 'My Products'.

SMSC3 4.png
6. In the next step, set up the 'storage' folder as recursively writable.

This folder is available at 'yourWHMCS/modules/addons/sms_center/' .

SMSC3 4 2.png

[edit] Activate The Addon

5. Now, you have to activate the module in your WHMCS system.

Log in to your WHMCS admin area and proceed to 'Setup' 'Addon Modules'.
Afterwards, find 'SMS Center' and press the 'Activate' button.

SMSC3 5.png
6. In the next step you need to permit access to this module.

To do so, click on the 'Configure' button and select the admin roles which should have access to the module.

SMSC3 6.png
7. Finally, set up the cron command line provided below and define its frequency (10 minutes interval is suggested).
php -q /yourWHMCS/modules/addons/sms_center/cron/cron.php SmsTask

This will allow the module to send text messages.
Important: Make sure that the 'exec' function is not blocked in your PHP configuration.


Note: Once the cron is executed, it operates continuously.
If you stop the cron processes manually, please also delete the entire content of the '/yourWHMCS/modules/addons/sms_center/storage/crons/' folder or execute the below command:

rm -r /yourWHMCS/modules/addons/sms_center/storage/crons/*

This will allow you to run the cron process again next time. Do not forget to replace 'yourWHMCS' with your WHMCS root location.

8. Congratulations, you have just successfully installed SMS Center For WHMCS!

[edit] Configuration and Management

SMS Center For WHMCS is a module which allows you to send predefined text messages to your clients the same way emails are sent.

[edit] Configuration

Under 'Configuration' tab you will find 'General', 'SMS Gateways', 'Administrators' and 'Rules' sections. Configure each of them to allow full usage of SMS Center For WHMCS module.

Press the first one 'SMS Gateways' to configure and check connection with SMS gateways.

[edit] SMS Gateways Configuration

[edit] Simple Gateway Configuration

Here you will find all possible gateways that can be used in our module.

Press 'Simple Configuration' next to a gateway you wish to use.

SMSC3 9.png
Configuration of each gateway may vary depending on its requirements.

Apart from connection details, you may here also enable debug mode to log API requests and responses.

SMSC3 10.png
You can check whether configuration is correct through pressing 'Check Connection'.
SMSC3 11.png
If connection is successful, you can proceed further.

Press 'Enable' next to the gateway to activate it.

SMSC3 12.png

[edit] Advanced Gateway Configuration

Advanced gateway configuration allows you to use multiple credentials for the chosen gateway type.

This feature can prove useful when you want to use a single gateway submodule with configurations from accounts dedicated to various countries.

To start, to go to 'Configuration' 'General', enable the 'Advanced Settings' option and save changes.

SMSC3 9 2.png
When you go back to the 'SMS Gateways' section, press the 'Advanced Configuration' button next to the chosen gateway and you will notice it has replaced the 'Simple Configuration'.

Now you will be redirected to a new section, where you can add multiple configurations for a chosen gateway.
Simply, press the 'Add Settings' button to add a new configuration option.

SMSC3 10 2.png
Next, add your gateway configuration in the same way as you would do during a simple configuration. Additionally, enter your 'Settings Name' to be able to distinguish this configuration from others afterward.

Note: You can have as many configurations as you want. You will determine which configuration will be used in which case later on, in the rules section.

SMSC3 11 2.png
To check if your configurations have been saved properly, go back to the gateway list and press the 'Check Connection' button next to the gateway you had configured.

Then, in the newly opened window you will be able to select one of your saved configurations and perform a connection test.

SMSC3 12 2.png

[edit] Administrator Notifications

This section contains a list of all administrators.

Here you can choose who exactly will receive particular SMS notifications.
Follow the steps described below to configure staff notifications properly.

Find the 'Administrator Notifications' section under the 'Configuration' menu. Next, press 'Edit' next to the chosen administrator.

SMSC3 22.png
In order to enable SMS notifications for each administrator individually, firstly set configuration for every one of them.

1. Fill in the administrator's country code and phone number to which text messages with notifications will be sent.
2. Choose which of the available admin messages will be sent to this particular administrator.
3. Choose addons, products and domains which ordering will result in sending a notification to the specified administrator.
4. Select ticket priorities to send notifications to the administrator whenever a ticket with such priority is opened.
5. Decide if you want to receive clients login notifications (you can select these clients in the 'Tools' ' 'Clients' section).
Confirm changes.

SMSC3 23.png
Finally, enable all remaining notifications you wish to receive.

Repeat these steps for every administrator you wish to receive individual admin notifications.

SMSC3 24.png

[edit] Rules

The rules allow you to use different gateways (or their configurations) depending on the customer's country.

You can find them under the 'Configuration' 'Rules' menu. To add a rule, press 'Edit' next to the chosen gateway configuration.

Note: Make sure that you have already your SMS gateways configured and enabled. Otherwise, the rules will not show up.

SMSC3 24 2.png
Now, select countries for which a particular gateway configuration will be applied. The selected country may only be assigned to one rule.
You can also mark the gateway as default, which means that it will also be used if no other rule concerning the customer's country is met.

Note: Only one rule can be set as default. If you want the gateway to be used only when other rules are not met, set it as 'Default' and leave the 'Countries' field empty.

SMSC3 24 3.png
Finally, toggle the status to enable your newly created rules.
SMSC3 24 4.png

[edit] General Configuration

In the 'General' section you can find specific SMS configuration possibilities. Configure those you wish to activate and save changes when ready.

[edit] General Settings

By default, the 'SMS Center' section in the client area is disabled. You may enable it here.

You can also toggle the advanced settings used for advanced gateway configuration.
Choose a country code prefix that will be automatically added to the client's SMS number if it had not been specified, or select "None" if the code prefix is already stored.
If you want to use a dedicated custom field for your client's SMS number, you can enable this feature here.
Otherwise, the default phone number from the client's profile will be used for sending SMS notifications.
Note: If you enable this feature, do not forget to select which custom fields from the 'Custom Fields' box you wish to use specifically.

SMSC3 24 0.png

[edit] Client SMS Activation

Enable 'Client SMS Activation' to grant each newly activated client a token which they will use to complete the activation process.

Determine time intervals for sending tokens and maximum number of attempts to resend a token.
Token Validity Period (Days) - define the number of days the token remains valid. After the provided here number of days, a client is marked as unverified.
Type in "0" to disable this option.

SMSC3 36.png
When you enable the above option, the activation process of a new client proceeds in a slightly different way. Start with filling out your client's details.

You can also accept the SMS agreements, but it is not required to receive the account activation token through SMS.

SMSC3 36 0.png
When registered, the client's verification status will be 'Unconfirmed'.
SMSC3 36 1.png
To verify activation after registration, the new client will have to type in a token received via SMS.

If the administrator enables such possibility, the client may request sending the token again by pressing the 'Resend Token' button.

SMSC3 36 2.png

As an administrator you can also verify the client's account manually.
To do so, go to your client's profile and click the 'Verify' button:

SMSC3 36 4.png
After successful verification, the client's status will change to 'Confirmed'.
SMSC3 36 3.png
Please be advised that whenever the client changes their phone number, their status will change back to 'Unconfirmed' and the verification process will have to be repeated.

[edit] Order SMS Activation

Enable 'Order SMS Activation' to allow activating orders.

Decide when the order verification shall be forced:

  • before checkout
  • after checkout
  • before & after checkout

A client will receive a text message with a token, which must be then used to move to the next step.
Here you can also define how many times within one hour a client will be allowed to ask for a token to be sent again.
Note: This option does not support order upgrades!

SMSC3 24 1.png
If the above option is enabled, a client will have to enter a valid token received via SMS in order to complete the placed order.

Depending on the settings, you may allow clients to ask for resending the token.
If such option is enabled, your client will simply need to press the 'Resend Token' button and they will receive another text message.

SMSC3 37.png
If the provided token is correct, the order's verification status will change to 'Confirmed'.
SMSC3 37 1.png

[edit] SMS Queuing

Enable this option to allow queuing of text messages. Note that this will not cover tokens sent for activations.

Determine time intervals between next resending attempts and the total number of messages that can be sent in one attempt.
Finally, choose the time period when text messages will be sent to clients.
Note: Time intervals are based on your current WHMCS server time.

Detailed information on this function is provided here.

SMSC3 24 5.png

[edit] Token Configuration

In this section you can also change default token settings by providing your own token length as well as allowed character sets.

Please note that allowed set of characters used for generating a token may contain chars from the following range only:

1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz

Any other special characters like: ", &, >, < or similar may cause unpredictable errors.

SMSC3 24 6.png

[edit] Custom Fields

Finally, select which of the existing client custom fields should be used to provide the client phone number to send messages.

Note: Choose only if you had enabled the 'Use Custom Number' from the 'General Settings', because otherwise the default WHMCS number will be used and any additional custom fields will not be required.

SMSC3 24 7.png

[edit] Skip Queue

If you want the messages that are sent from the client's profile to skip the queue then enable the 'Skip Queue' option.
SMSC3 24 8.png

[edit] Invoice Activation

If you want clients to check invoices that are not assigned to any order using a token delivered via SMS, then enable the 'Invoice Without Order Activation' option.
SMSC3 24 9.png

[edit] Logs

Logs are by default turned on, if you want to hide the "Logs" section from the top menu, you may do it here.

It is also possible to set up the logs to be automatically cleared after the specified here number of days.

SMSC3 25 0.png

[edit] Management

[edit] Templates

The 'Templates' tab contains the list of message templates. Each email template in your system has its text message counterpart.

Any of these messages can be enabled/disabled by the 'Status' toggle or using the mass actions feature.
Every enabled template in admin area will then be also visible in the client area, where your clients can decide whether or not they want to receive chosen SMS notifications.

Note: Titles of the message templates can be translated in the module language file.

SMSC3 13.png
By default, the module comes with simplified message templates, but you can edit each of them.

First, choose the message category from the tabs above, and then press 'Edit' next to the chosen template.
Note: Custom templates include no content, please add the custom template message by yourself.

SMSC3 13 1.png
The first record on the list is a default message of the template. Our module allows you to define messages in selected languages.

In order to prepare a message in an additional language, press 'Add New Template Language' as shown on the following screen.

SMSC3 14.png
As you can see on the screen below, a new window appeared.

Select the desired language from the dropdown menu and add your translated massage.

Module template supports merge fields which can be easily inserted into messages.
Simply click on the desired merge field and it will be added into the currently edited version of the message.

Below the message field, there is a characters counter which helps to estimate the message length.
The fixed message characters are counted, if there is a variable used, then the counter estimates the length and displays e.g. "104+".

Note: The Language of sent messages is the client's language. If you do not define a message in your client's language, the default message will be sent instead.

SMSC3 15.png

[edit] SMS Queue

In this section you will find a list of all text messages waiting for a cron run to be sent.

Specific details on messages that can be sent in one attempt are specified in the 'General' section.
If SMS queues are enabled, every single message (except activation tokens) is placed on this list before being sent. With every cron run a previously set number of messages is sent.
If message sending fails (because the number is incorrect, there are problems with gate, no funds etc.), such SMS remains on the list until the next attempt.
After three failed attempts its status is changed to 'Aborted'.

Available actions:

1. Start - send message manually.
2. Refresh - use when status has changed to 'Aborted' to bring it back to the queue.
3. Delete - remove message form the list.

SMSC3 16 1.png
To save time, you can also use mass actions.
SMSC3 16 2.png

[edit] Mass SMS

Sending mass text messages to your clients is a convenient tool that allows preparing messages that will be delivered to a group of clients according to a specified configuration.

[edit] Mass SMS Templates

Firstly, move to 'Mass SMS' → 'Templates', and create templates for mass messages there.

To start with, choose a group to which the template will be connected and then press 'Add New Template' .

SMSC3 44.png
Enter your template name and type in the message content. Use merge fields available for the group.
Follow characters counter current rate to estimate the message length.

Do not forget to confirm changes.

SMSC3 45.png
All created templates are free to edit or remove when no longer used.
SMSC3 46.png

[edit] Mass SMS Configuration

Now that you have created the templates, move to 'Mass SMS Configuration' to configure the recipient group.

Start by adding new settings.

SMSC3 40.png
Use filtering fields to set it up as you need. Enter the configuration name and select the type of filtering. You can choose from:
  • 'Client Filters' filtering
  • filtering according to 'Addons', 'Domains' or 'Products'.

Each filter type configuration differs slightly, but there are some general settings available for each type. These are:

  • Custom Fields - enable available custom fields
    'Marketing SMS' is a default addon custom field. If you enable it, the message will be sent only to customers who have given their agreement for SMS marketing.
  • Client Group - select which of your client groups will receive the text message
  • Client Status - you may choose clients to receive messages depending on their status in your system
  • Language - select default language for the messages
  • Brand Filtering - if you have Multibrand For WHMCS module active, here choose which brand this mass SMS configuration shall be applied to

All above sections are available for 'General' client filter.

SMSC3 40 2.png
In the next step you can select a SMS mass template created earlier and add some additional filters depending on which of the 'Client Filters' you had selected in the previous step:

Client Filter - Addon

  • select purchased addon
  • select addon status
SMSC3 41.png
Client Filter - Domain
  • select domain status
SMSC3 42.png
Client Filter - Product
  • select products from the list of purchased ones
  • select product status
  • select assigned server
SMSC3 43.png
In the next step you will see what the final SMS will look like and preview the list of clients will receive the message (based on the previously selected filters).

If you want to save this filter for later use, click 'Save Filters' .
Surely, you may edit here the list. Add/remove clients from the list to keep it up to date.

If everything is correct, press 'Send' to start sending messages to the clients.

SMSC3 47.png

[edit] Tools

[edit] Send SMS

In the 'Tools' 'Send SMS' you can send your custom SMS directly to any client or phone number using any of your gateways.

Simply type in your message, you may use the available 'Client Related' and 'Other' variables to compose a dedicated message.
Choose the client's default phone or SMS number from the list and choose which of your gateway configurations you want to use to send this message.

SMSC3 49.png
Instead of selecting a client's number, you can also enter any number you want. In such case remember to leave the 'Client' field empty and provide a custom number in the field below.

The 'Brand' field is available only if you have the Multibrand For WHMCS module active. Once you select a client, you may choose the brand within which the sms message will be sent.
If the client is assigned to one brand only, the brand field is filled in automatically and has no impact on sending the message.
Keep in mind that some of the variables such as {$company_name} will be branded in the message.

When the message is ready, press the 'Send' button which will add it to the 'SMS Queue' .

SMSC3 50.png

[edit] Clients

In the 'Tools' 'Clients' you can find list of all your WHMCS clients with their current SMS verification status.

From here you can easily manage the verification status as well as toggle SMS notifications for administrators to receive when a specified customer logs in to the client area.

SMSC3 48.png

[edit] Logs

Messages sent to your clients are logged under the 'Logs' tab.

As you can see on the following screen, here you can find detailed information on each message sent automatically to a client notifying about certain actions.

SMSC3 17.png

[edit] SMS History

In this section you will find a precise list of all SMS messages sent recently. If you want to find a particular client or mobile phone number, simply use the search box.
SMSC3 17 1.png

[edit] Client's Summary Page

From the clients' summary page you can send text messages to clients using only a simple box.

Type in the message content into the text field like on the screen below and press 'Send'.

SMSC3 25.png

[edit] Client Area

[edit] Opt-In/Out Agreements

To meet the GDPR requirements, the client can decide to opt-in/out from receiving SMS message notifications and marketing massages during the registration process.

Note: You can edit the description of these rules in your 'WHMCS' → 'Setup' → 'Custom Client Fields' section.

SMSC3 51.png
After registration, the options can later be changed in the client's profile.

Important: The 'Accept SMS' field will be enabled by default for the already existing clients when you install the module for the first time.

SMSC3 52.png

[edit] Notifications Templates

If enabled in general settings, a new position will appear in the client area navigation menu.

Through pressing it, your client will be moved to configuration of SMS notification.

SMSC3 18.png
Here, your client can choose which notifications to receive. Remember that only templates with the status enabled set in templates configuration will be visible to the clients.

Note: If you are using a custom number field to store clients SMS numbers, make sure they are provided in their profiles. Otherwise, SMS notifications will be unavailable for that clients.

SMSC3 19.png

[edit] SMS Center Two-Factor Authentication

SMS center For WHMCS consists of two parts: the actual SMS Center addon and the authentication addon.

Two-Factor Authentication adds an extra layer of protection while logging in.
Once enabled and configured, each time your client signs in, they will be asked to enter both username and password as well as the second factor like a security code.
In order to activate it, proceed to 'System Settings' 'Two-Factor Authentication'.
Afterwards, find 'SMS Center Two-Factor Authentication,' and press the 'Activate' button.

SMSC3 20.png
In the next step you need to configure the addon settings.

To do so, fill out the data:

  • Enable for Clients - choose this option if you wish all clients to authenticate while logging in to their accounts.
  • Enable for Staff - choose this option if you wish all administrators to authenticate while logging in to their accounts.
  • Activation Code Valid For - decide how long (in minutes) a received code will be valid. Used once before the first log in.
  • SMS Code Valid For - decide how long (in minutes) a received via SMS code will be valid. Used every time to log in after the first authentication.
  • Code Length - specify how many characters will be required by a code.
  • Allowed Characters - define which characters can be used to generate codes. Please note that the allowed set of characters used for generating a token may contain chars from the following range only:
    1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
    Any other special characters like: ", &, >, < or similar may cause unpredictable errors.
SMSC3 21.png

[edit] Security Settings

[edit] Clients

If you have activated the 'SMS Two-Factor Authentication' addon, your clients will be allowed to decide if they wish to use such a security option.

Here is how to enable this functionality:
1. Log in to your client area, proceed to 'Account Details' 'Security Settings'.
There is a button which enables two factors authentication configuration for the client.

SMSC3 26.png
2. Press the 'Get Started' button to proceed with the process.
SMSC3 27.png
3. Provide a phone number to proceed with SMS Two-Factors Authentication. Press 'Activate.'

Note: This step is obligatory, no matter if the client has already provided a valid SMS number in the profile.

SMSC3 28.png
4. A client should receive now an authentication code via SMS.
Provide the code in the field and press 'Activate'.
Note: Remember that the code is valid only temporarily, according to the addon settings!
SMSC3 29.png
Two-Factor Authentication is now complete.

Important: Remember to note and keep your backup code in a secure place!

The second factor will now be required in the next login attempt. Wait for the SMS with verification code and enter it in the appropriate field.

If you have any problems with receiving/entering the verification code, you can use your backup code.
Important: In such situation remember to note and keep your new backup code in a secure place!

In case there are clients who, for some reasons, do not have the required phone number provided, you may turn off 2FA for such clients only.

Use the below script to turn off the 2FA for such clients:

php -q /yourWHMCS/modules/addons/sms_center/cron/cron.php Reset2FA  

Please make sure you have used a full and correct path to the module cron file.

Once you run this script, you will find information in the 'Logs' section about the 2FA being turned off for a particular client account.
After the script turns off the 2FA, the client may log into the client area without the need to provide the 2FA token.

If the client wants to use 2FA security, he must turn it on again for his account (Security Settings).
He will get the option to provide the required phone number to be able to receive the authentication token during future login attempts.

[edit] Administrators

If the 'SMS Two-Factor Authentication' addon has been activated and enabled for staff, you will be able to decide as administrator if you wish to use such a security option.

Here is how to enable this functionality:
1. Proceed to 'My Account.' Find 'Two-Factor Authentication' and enable it to start the Two-Factor Authentication process.

SMSC3 32.png
2. Press the 'Get Started' button to proceed with the process.
SMSC3 33.png
3. You will receive now an authentication code via SMS.
Type in the code in the field and press 'Activate.'
Remember that the code is valid only temporarily, according to the addon settings!
SMSC3 34.png
4. If entered code is correct, you will see proper information.
There will also be a backup code which must be copied and saved securely to log in with in case of some issues.
SMSC3 35.png
5. The second factor is now required to log in. Wait for the SMS with verification code and enter it in the field. Press 'Login.'
If you have any problems with receiving/entering the verification code, you can use your backup code.
Remember to note and keep your new backup code in a secure place!
SMSC3 35 1.png

[edit] SMS Center and WHMCS API Integration

Below you can find a short instruction on how to integrate your SMS Center For WHMCS with the WHMCS API.
1. Function name: 'sendsms'

2. Required parameters:

  • (phonenumber) OR (userid) OR (adminid)
    AND
  • (messagename) with (relid) - ID of relation, for example invoice or service OR (message) - text of the message


3. Where:
(Relid) for (userid) is an 'integer'
(Relid) for (adminid) is an 'array'

4. A typical example for sending an SMS with a specified message to the user with a given ID:

localAPI('sendsms', array('userid' => $_POST['userid'], 'message' => $_POST['message']), 'admin');

5. An example of usage for admin 'array' with parameters:

array('admin' => 1,'phonenumber' => $number, 'messagename' => 'Service Unsuspension Successful',
'relid' => array('client' => $params['params']['userid'], 'service' => $params['params']['serviceid']))

In case you add phonenumber in the message, you have to specify whether it is an admin's number by entering: 'admin' => 1, just like in the example above.
You do not need to add the above parameter for a user's number.

6. SMS Center For WHMCS does also support the 'force' parameter. If set to 'true' , it allows to skip the queue for sending SMS messages and proceed with the task immediately.

As an example:

localAPI('sendsms', array('userid' => $_POST['userid'], 'message' => $_POST['message'], 'force'=> true), 'admin');

[edit] Custom Gateway In SMS Center

Below you can find a short instruction on how to implement a new SMS gateway into the SMS Center For WHMCS module by yourself.

Follow the below steps:

1. Firstly, create a new PHP class in the directory:
/modules/addons/sms_center/app/Libs/Sms
which inherits the class:
''ModulesGarden\SmsCenter\App\Libs\AbstractSms\AbstractSubmodule

2. Inside that class, create the following two fields:

  • $name - the name of the SMS gateway that will display in the "SMS Module" column inside the addon (marked as "1." on the screenshot below).
  • $description - a link to the SMS Gateway's website - this link will be displayed in the column "Description" (marked as "2."' on the screenshot below).
    Here is an example of what those fields should look like in the file:
   
public static $name                = "Gateway Name";
public static $description         = '<a href="https://gatewayName.com/" target="_blank">www.gatewayName.com</a>'; 
SMS 36.png
3. The next steps to follow here will be to define various functions inside the class.

The first one to define is getConfiguration(), which is used to build the gateway configuration form. The field types available to build this form can be found in the following class:

 ModulesGarden\SmsCenter\App\Helper\SubmodulesHelper\MG_SMS_SubmoduleConfiguration

Here is an example of a function that can be defined here - adding this block to your file will create a form comparable to one you can view in the screenshot below:

public static function getConfiguration()
{
     return array(
         'username'    => array(
             'validators' => array('required'),
             'description' => true;
         ),
         'public_key'  => array(
             'validators' => array('required'),
         ),
         'from'        => array(
             
         ),
         'debug_mode'  => array(
             'type'    => MG_SMS_SubmoduleConfiguration::TYPE_SELECT,
             'options' => array('disable', 'enable'),
         ),
     );
}
SMS 37.png
4. Another function to define is checkConnection() - this button is usually used to send a request that returns the information concerning the available balance on the SMS Gateway account.

The button in question can be seen here:

SMS 38.png
5. The function sendMessage($message, $number) should contain the logic used to send SMS messages - i.e. this function is used to handle the API of the gateway.

The parameters:

  • $message - contains the main content of the SMS message
  • $number - the phone number onto which the message will be sent (including the country code)

6. Some additional tips:

  • You can access the gateway configuration data via
$this>configuration['{name_of_configuration_field}']; 

You can replace "name_of_configuration_field" with any field, for example

$this->configuration['username'];
  • Any time the module throws out an exception, you will receive the following error message: 'The connection test has failed:'
7. Below, you can find an example of a full class that contains all the above described functions. You can use that example as reference when adding your own gateway to the module.
<?php

namespace ModulesGarden\SmsCenter\App\Libs\Sms;

use ModulesGarden\SmsCenter\App\Libs\AbstractSms\AbstractSubmodule;
use \ModulesGarden\SmsCenter\App\Helper\SubmodulesHelper\MG_SMS_SubmoduleConfiguration;

class Exmaple extends AbstractSubmodule{
    
    public static $name                = "Exmaple";
    public static $description         = '<a href="https://example.com/" target="_blank">www.example.com</a>';
    
    
    public function checkConnection()
    {       
        $username = $this->configuration['username'];
        $url = 'https://payments.example.com/query/wallet/balance?username='.$username;
        $this->sendRequest($url);
    }
    
    public static function getConfiguration()
    {
        return array(
            'username'    => array(
                'validators' => array('required'),
            ),
            'public_key'  => array(
                'validators' => array('required'),
            ),
            'from'        => array(
                
            ),
            'debug_mode'  => array(
                'type'    => MG_SMS_SubmoduleConfiguration::TYPE_SELECT,
                'options' => array('disable', 'enable'),
            ),
        );
    }
    
     public function sendMessage($message, $numbers)
    {
         
        $username = $this->configuration['username'];
         $url = 'https://api.example.com/version1/messaging';
         $params = [
             'username' => $username,
             'to' => $numbers,
             'message' => $message,                        
         ];
         
         if($this->configuration['from'])
         {
             $params['from'] = $this->configuration['from'];
         }

        $this->sendRequest($url, $params);
    }
        
    private function sendRequest($url, $postFields = null)
    {
        $apikey = $this->configuration['public_key'];
        $ch = curl_init();
        curl_setopt($ch, CURLOPT_URL, $url);
        if($postFields){
            curl_setopt($ch, CURLOPT_POST, 1);
            curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($postFields));
        }
        curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
        curl_setopt($ch, CURLOPT_TIMEOUT, 60);
        $header[] = "apiKey: $apikey";
        $header[] = 'Accept: application/json';
        curl_setopt($ch, CURLOPT_HTTPHEADER, $header);


        $response = curl_exec($ch);

        if ($response == false)
        {
            $curlError = curl_error($ch);
            if ($this->configuration['debug_mode'] == "enable")
            {
                $this->saveLog($url, $postFields, 'Curl error: ' . $curlError);
            }
            throw new \Exception('Curl error: ' . $curlError);
        }
        $jsonResponse = json_decode($response, true);
        
        if ($this->configuration['debug_mode'] == "enable")
        {
            $this->saveLog($url, $postFields, $response);
        }

        if(empty($jsonResponse)){
            throw new \Exception($response);
        }
        
        if(!empty($response['SMSMessageData'])){
            if($response['SMSMessageData']['Recipients'][0]['status'] != 'Success'){
                throw new \Exception($response['SMSMessageData']['Recipients'][0]['status']);
            }
        }
     
        return $response;
    }
    
   
    private function saveLog($endpoint, $request ,$response)
    {
        logModuleCall(
                'MG_SMS_Example', $endpoint, $request, $response, ""
        );
    }
}

[edit] Additional Information

1. SMS Center For WHMCS has been integrated with our Client Profile Viewer For WHMCS module enabling you to send messages to your clients in a faster and even more convenient way.
2. The messages sent by our module are divided into four categories:
  • Messages sent automatically to clients after occurrence of specified actions (activity is logged in the addon's 'Logs' tab).
  • Messages sent automatically to administrators after occurrence of specified actions (activity is logged in WHMCS 'Module Log' ).
  • Messages sent manually from client's profile (activity is logged in WHMCS 'Module Log' ).
  • Messages sent manually from Client Profile Viewer For WHMCS widget (activity is logged in WHMCS 'Module Log' ).

[edit] Tips

1. You may customize the 'Two-Factor Authentication' verification message text delivered to a user.

E.g. the default messages are: 'Your activation code is: erkhq34j329' and 'Your login code is erkhq34j329'
Change the messages content in the addon language file by editing the following records:

$_LANG['clientArea']['2FA']['loginCode']    = 'Your login code is :token:';
$_LANG['clientArea']['2FA']['activateCode'] = 'Your activation code is :token:';
2. Invoice special merge fields clarification:
  • $invoice_items merge field is an array and should always be used within a 'foreach' clause to be displayed correctly
  • $invoice_items used with {$i.description} displays all content including dates and domain name

Example of usage:

{foreach from=$invoice_items item=i}  
{$i.description} 
{/foreach} 
  • $invoice_domains_registered special merge field that shows only the domain name.

Example of usage:

{foreach from=$invoice_domains_registered item=i}  
<p>DOMAIN REGISTERED: {$i}</p> 
{/foreach} 
3. Information on any errors that a cron task might encounter while being executred are stored in the following file:
'storage/logs/cron_log'

Check the file content for cron errors details.

4. There is the possibility to switch on all templates for all your clients. To do so, please follow these steps:
  • Log in by ssh
  • Proceed to your_whmcs/modules/addons/sms_center/shell
  • Enter this command if you want to set the default templates for clients that have the 'Accept SMS' option enabled:
 php -q runTask.php --taskName templates --taskAction setDefault 
  • Provide this command if you want to set the default templates for all your clients:
php -q runTask.php --taskName templates --taskAction setDefaultAll
5. If you want to delete logs, you may need the following command. Firstly, proceed to <whmcs>/modules/addons/sms_center/shell and run the task:
 php runTask.php --taskName clear --taskAction logs 
6. You may turn on/ turn off 'Accept SMS' and 'Marketing SMS' options for all clients using the following commands.

Firstly, go to this folder <whmcs>/modules/addons/sms_center/shell and run an appropriate task:

  • To enable or disable the 'Marketing SMS' option, use:
php -q runTask.php --taskName marketingSms --taskAction enable
php -q runTask.php --taskName marketingSms --taskAction disable 
  • To enable or disable the 'Accept SMS' option, use:
php -q runTask.php --taskName acceptSms --taskAction enable
php -q runTask.php --taskName acceptSms --taskAction disable 

[edit] Update Instructions

An essential guidance through the process of updating the module is offered here.

Important: When updating the module from version 2.x to 3.x, you need to start the migration process to move settings from the previous version to the new one.
To do this, first update your module files to the newest version and set recursively writable permissions for storage directory in 'yourWHMCS/modules/addons/sms_center/' location.
Next, execute the following script in your server's console:

php -q /yourWHMCS/modules/addons/sms_center/shell/migrationTo3_0_0.php

Do not forget to replace 'yourWHMCS' with your WHMCS root location.
The migration process covers: the configuration of SMS gateways, general settings, chosen template notifications by clients, administrators' phone numbers, SMS queues, SMS templates and Mass SMS templates.
Any other settings might not be migrated!

If you are using Client Profile Viewer For WHMCS integration, you will also need to update it to the version 1.5.8 or later.

[edit] Upgrade Guide

Seeking a solution that offers greater flexibility, customization tailored to your precise needs, and unrestricted availability?
There is an option that not only proves to be cost-effective in the long run but also includes prioritized support services, making it a truly valuable investment.

Opt for the Open Source version of your SMS Center For WHMCS module to unlock these benefits.
Simply click on either the Get Source Code or Upgrade To Lifetime button found on the product's page in our client area to complete the one-step upgrade process, with a dedicated discount already applied.

Follow a comprehensive guide covering the transition process, the advantages it brings, and step-by-step instructions on what to do next after the order has been successfully finalized.

[edit] Common Problems

1. When you have problems with connection, check whether your SELinux or firewall does not block ports.
2. The module is currently not compatible with:

It is advised not to use the modules mentioned above at once.

Navigation
WHMCS Modules
WHMCS Widgets
Translations
cPanel Modules
General
FAQ
Community
SMS Center For WHMCS