Updated on PowerShell Module for 3CX 16.0.676 - your inputs needed

Status
Not open for further replies.

HermanRas

Forum User
Joined
Nov 26, 2019
Messages
3
Reaction score
0
I used the info from the below thread @Togadude
https://www.3cx.com/community/threads/3cx-api-with-powershell.56973/

and patched the already coded PSModule from @happy_admin:)
https://www.3cx.com/community/threads/powershell-module-for-3cx.41481/

the below commands are working:), I will be renaming some command and adding a bunch more... please let me know if there is any features you would like included and I will see what I can do ;) within the scope of "3cxpscomcpp2.dll" the provided API from 3CX themselves.

====================================================
Add-ExtensionGroupMember,
Add-RingGroupMember,
Get-DN,
Get-Extension,
Get-ExtensionGroup,
Get-ExtensionGroupMember,
Get-RingGroup,
Get-RingGroupMember,
New-Extension,
New-ExtensionGroup,
New-RingGroup,
Remove-Extension,
Remove-ExtensionGroup,
Remove-ExtensionGroupMember,
Remove-RingGroup,
Remove-RingGroupMember,
Set-Extension,
Set-ExtensionGroup,
Set-RingGroup


READ ME INCLUDED in the install ZIP
#####################################################

please open your install dir and local the config file:
C:\Program Files\3CX Phone System\Bin\3cxSystemService.exe.config

open "3cxSystemService.exe.config" with a text editor and copy the CfgServer password
copy the 3CXShell.psd1 & 3CXShell.psm1 files to "%Windir%\System32\WindowsPowerShell\v1.0\Modules\3CXShell"
now open 3CXShell.psm1 and update "your password here" on line 7

open PowerShell and run:

import-module 3CXShell
get-help 3CXShell
 

Attachments

Hi everyone,

We have to put a stern warning for using this API may result in undesired behavior and may go as far as to break your system and your future backups.

Validation checks are not made when using this API and we do not recommend anyone use it today on modern 3CX systems because of the high risk associated. The V16 system is generations ahead in changes made under the hood from when the API was available as well as new features, and the management console will ensure that any necessary checks and background operations are carried out when performing various actions. The above method does not employ such checks and can allow you to do things that may break the services or the whole system.
 
Thanks, JohnS for your warning, just (And this might be me not understanding a thing) checking, however, are there any plans to make the official API accessible from Powershell?
 
  • Like
Reactions: HermanRas
Thanks, JohnS for your warning, just (And this might be me not understanding a thing) checking, however, are there any plans to make the official API accessible from Powershell?


Is there any Officially supported API (WEB / TCP / PowerShell) ?
 
For the moment no, but we have it in our plans to provide a REST API in the future.

At the moment I cannot provide any information on this, as it is still very early.
 
  • Like
Reactions: HermanRas
For the moment no, but we have it in our plans to provide a REST API in the future.

At the moment I cannot provide any information on this, as it is still very early.

Thanks
 
There is a company out there (not going to say whom), providing a web API for 3CX, but fees are double that of the actual 3CX license so I won't advertise for them.

*Forever waiting for REST API

Once it's out, you'll see the community build some of the tools that other users are looking for. Either look at this one of two ways, more features, more customers. Less control, maybe less money
 
  • Like
Reactions: MSternfeld
Status
Not open for further replies.

Latest Posts

Forum statistics

Threads
112,324
Messages
591,897
Members
165,475
Latest member
lastshadow