Disable 3CX Talk in V.20

Status
Not open for further replies.

OmniCall

Bronze Partner
Basic Certified
Joined
Dec 19, 2023
Messages
1
Reaction score
1
Is there an option to disable 3CX Talk so that an outsider can't reach the "talk url" generated in the user configuration?
 
  • Like
Reactions: NCIA
There is no option to disable it, but the link is customisable, so you can put a random link there which is not able to be guessed by an outsider.

1702993290996.png
 
This is terrible. So many options are required now or have different allowed value ranges that it's become a real chore to make any change to anything in the latest version.
 
Hello there. Same request here as well, we need a way to completely disable this feature as we dont want our users to be able to chat with people outside the organization and we could achieve this by completely disabling chat, however, we want the users to have the chat enabled so they can chat with each other. Is there any other option to achieve this as this is a huge bummer
 
Yep - +1 for me too... The requirement for unique email addresses I can understand (although it's bit of a pain) -- but the *requirement* to add a random value to a field in order to make an unrelated change - rather than assuming that if it's not provided then the feature should be disabled.... :-(

Arg!!!
 
+1

You're a voice platform, not a replacement for Teams
 
If you want to block this feature for all users, it's simple: set the number of LiveChat connections per visitor IP address to 0.

As a result, visitors won’t be able to establish a connection with the users.

admin > advanced > anti-hacking
Change 'Maximum allowed requests per IP Address' to 0.
Save

It makes sense, really. As soon as I saw the discussion thread, considering there's no ON/OFF switch, my first instinct was to check where to limit the number of connections per IP.

v20 is actually well-designed when you take the time to understand the logic behind it. Personally, I like it a lot.
 
+1

You're a voice platform, not a replacement for Teams
Humm no ! 3CX is not a ONLY Voice Plateform.
I think you should revisit the product you're supposed to be promoting.

https://www.3cx.com/company/

3CX is a modern and revolutionary unified communications system, not just a simple voice platform. I know many companies that choose 3CX specifically because of its WebMeeting and chat capabilities, in addition to technologies that make phone communications easier (softphone). This allows you to reach a broader customer base and maximize your sales. And this, without the client's system administrator needing to support multiple platforms.

Additionally, an increasing number of commercial clients want to offer chat support on their websites. Teams is not the ideal solution because the visitor must have a Teams account to chat, and there is no queueing solution to chat with a customer service agent, for example. Moreover, it is not possible for supervisors to monitor chat logs of Teams conversations.

So, maybe in your case, MS Teams is more suitable for your clients' needs, but don’t underestimate the unified communications solution that 3CX offers, which is one of its many competitive advantages.

Next time, before telling a company what it is, do some research. For a first-time participation in the forum, you missed the mark. That said, don't hesitate to contribute with constructive comments next time :p .
 
Last edited:
If you want to block this feature for all users, it's simple: set the number of LiveChat connections per visitor IP address to 0.

Doesn't stop you having to add a link name every time you edit a user without one. It would make much more sense that if the link name was blank, chat was disabled for that user.

Making it a mandatory field is a PITA for general admin.
 
  • Like
Reactions: NCIA and Gasha
Doesn't stop you having to add a link name every time you edit a user without one. It would make much more sense that if the link name was blank, chat was disabled for that user.

Making it a mandatory field is a PITA for general admin.

Okay, yes, the field is indeed mandatory. The good news is that when creating the extension, it gets filled in automatically.

You're referring to extensions created before V20. Yes, it would be great if 3CX added enable/disable parameter, but I believe the developers at 3CX have done an outstanding job, and sometimes, we have to choose our battles.

I think this is such a "minor" situation.

Anyway, that said, I've created a small script for you to run in the 3CX "Call Processing Script" to automatically fill in the "Link Name" field if it's empty.

Of course, you might say that it would be better if 3CX added the deactivation parameter, and I agree. But if 3CX has to choose between developing a new feature that offers more benefits or implementing a simple parameter to "disable" the "Link Name" field, I’d much prefer the new feature.

Disclaimer:
It is recommended to perform a backup of your 3CX system before implementing any third-party scripts.
This script is provided as is without support from 3CX. Use at your own risk.

You can't say I'm not being honest :p



You follow the same steps as described in the guide:
https://www.3cx.com/docs/intercept-call-example/


but instead, select "Dial Code" and choose a code of your choice to trigger it.
1722866188209.png


1722866231154.png




Once saved, you can "start" it by call the dialcode you haved set.


In my example, I chose *8*8


The action is limited to extensions :

C#:
// Guillaume Bourgeois, 2024-08-05
// Objective: Update Talk Link names in a telephony system for extensions only, play a goodbye message, and terminate the call.
// Script language: C#
// Disclaimer: This script is provided as is without support from 3CX. Use at your own risk.
// Note: It is recommended to perform a backup of your 3CX system before implementing any third-party scripts.

#nullable disable

using CallFlow;
using System;
using System.Threading.Tasks;
using TCX.Configuration;

namespace UpdateTalkLinkNames
{
    public class TalkLinkNameScript : ScriptBase<TalkLinkNameScript>
    {
        // Define the PhoneSystem variable and the path for the goodbye audio file.
        private PhoneSystem ps = null;
        private readonly string goodbyeAudioPath = "/var/lib/3cxpbx/Instance1/Data/Ivr/Prompts/Sets/8210986B-9412-497f-AD77-3A554F4A9BDB/thankyou_goodbye.wav";

        // Override the StartAsync method from ScriptBase to provide the script's main logic.
        public override async Task<bool> StartAsync()
        {
            // Attempt to retrieve the PhoneSystem instance.
            ps = MyCall.PS as PhoneSystem;
            try
            {
                // Update the Talk Link names for extensions only.
                UpdateTalkLinkNameForExtensions();
                MyCall.Debug("Talk Link names for extensions updated successfully.");
                // Play the goodbye message and terminate the call.
                return await PlayGoodbyeMessageAndTerminate();
            }
            catch (Exception ex)
            {
                // Log an error if there is an issue during the Talk Link name update.
                MyCall.Error("Error during Talk Link name update for extensions: {0}", ex);
                // Ensure the goodbye message is played and the call is terminated even in case of an error.
                await PlayGoodbyeMessageAndTerminate();
                return false;
            }
        }

        // Method to update Talk Link names for extensions only.
        private void UpdateTalkLinkNameForExtensions()
        {
            // Ensure that the PhoneSystem is initialized.
            ps = PhoneSystem.Root;
            if (ps == null)
            {
                throw new InvalidOperationException("PhoneSystem is not initialized.");
            }

            // Retrieve all DNs and update their properties if they are of type 'Extension'.
            var allDNs = ps.GetDN();
            foreach (var dn in allDNs)
            {
                if (dn is Extension)
                {
                    string C2CID = dn.GetPropertyValue("C2CID");
                    string WM_FRIENDLYNAME = dn.GetPropertyValue("WM_FRIENDLYNAME");

                    // Check if either C2CID or WM_FRIENDLYNAME is empty or missing, and update accordingly.
                    if (string.IsNullOrEmpty(C2CID) || string.IsNullOrEmpty(WM_FRIENDLYNAME))
                    {
                        string newValue = dn.Number;
                        C2CID = string.IsNullOrEmpty(C2CID) ? newValue : C2CID;
                        WM_FRIENDLYNAME = string.IsNullOrEmpty(WM_FRIENDLYNAME) ? newValue : WM_FRIENDLYNAME;

                        dn.SetProperty("C2CID", C2CID);
                        dn.SetProperty("WM_FRIENDLYNAME", WM_FRIENDLYNAME);
                    }
                    else if (C2CID != WM_FRIENDLYNAME)
                    {
                        // Ensure C2CID and WM_FRIENDLYNAME are identical.
                        WM_FRIENDLYNAME = string.IsNullOrEmpty(WM_FRIENDLYNAME) ? C2CID : WM_FRIENDLYNAME;
                        C2CID = WM_FRIENDLYNAME;

                        dn.SetProperty("C2CID", C2CID);
                        dn.SetProperty("WM_FRIENDLYNAME", WM_FRIENDLYNAME);
                    }

                    // Save the changes to the DN.
                    dn.Save();
                }
            }
        }

        // Method to play the goodbye message and terminate the call.
        private async Task<bool> PlayGoodbyeMessageAndTerminate()
        {
            // Ensure media is ready before playing the prompt.
            await MyCall.AssureMedia();
            // Play the goodbye prompt in a blocking manner.
            await MyCall.PlayPrompt(null, [goodbyeAudioPath], PlayPromptOptions.Blocked);
            // Terminate the call after the prompt is played.
            TerminateCall();
            return true;
        }

        // Method to terminate the current call.
        private void TerminateCall()
        {
            // Terminate the call effectively.
            MyCall.Terminate();  // This method ends the current call.
        }
    }
}
 
  • Like
Reactions: Evolute IT
@Guillaume Bourgeois Thank you for the heads-up and support. In update 3 we are making an easy way to disable the 3CX talk link
 
Status
Not open for further replies.

Forum statistics

Threads
112,147
Messages
590,959
Members
165,167
Latest member
Finatra.us