powershell
8 TopicsAutomatic update holidays in AutoAttendant!
On thursday Microsoft anounced some new features for Auto Attendant in preview. One of them beeing able to create holiday schedules. I have created a script that gets holiday dates automaticaly from the web, and creates schedules in Auto Attendant. Hope you find it usefull. Please leave me any feedback you have. https://alexholmeset.blog/2017/11/12/automatic-update-holidays-in-autoattendant/2.8KViews1like2CommentsPowershell New-CsOnlineSession with AccessToken
Hello guys, I am trying to run 'New-CsOnlineSession' with -OAuthAccessToken parameter in a Powershell script. The oauth token comes from a WebApp that authenticates the user. This WebApp uses Microsoft Identity Platform so the user accepts our app to access user's resorces. The WebApp uses OAuth2 to communicate with Microsoft Identity Platform. This WebApp is registered in the Azure Portal. The problem is that I cannot create the session and the error is: "OAuthAccessToken has invalid audience" I've tried to use -OverrideAccessTokenResourceUri parameter too, in conjunction with OAuthAccessToken, but it doesn't allow the script to get a session. When I use New-CsOnlineSession with user/password, everything works fine, I can import the session and use the commands perfectly. Logs: VERBOSE: OAuthAccessToken is provided. VERBOSE: Determining domain to administer VERBOSE: AdminDomain = 'xxxxxxxx.onmicrosoft.com' VERBOSE: Discovering PowerShell endpoint URI VERBOSE: TargetUri = 'https://admin1e.online.lync.com/OcsPowershellOAuth' VERBOSE: AuthUri = 'https://login.windows.net/common/oauth2/authorize', ClientId = 7716031e-6f8b-45a4-b82b-922b1af0fbb4 VERBOSE: Validating authentication token. New-CsOnlineSession : OAuthAccessToken has invalid audience 00000003-0000-0000-c000-000000000000, expected https://admin1e.online.lync.com/OcsPowershellOAuth. At G:\server-8000.ps1:20 char:12 + $session = New-CsOnlineSession -OAuthAccessToken $token -Verbose -Deb ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,New-CsOnlineSession Thanks in advance for any help. Hernan6KViews0likes6CommentsSet-CsMeetingConfiguration parameters
I was setting information in my meeting configurations and noticed a couple parameters that I can't seem to find any information on. what are: AllowCloudRecordingService and EnableMeetingReport do in the Set-CsMeetingConfiguration? Assuming they are as described is interesting, but I don't want to test turning them on as they seem to be tenant wide configurations.1.6KViews2likes1CommentAssignment of default conferencing policies - Skype Powershell
I've been working a lot recently with both CSConferencingpolicy and CSExternalAccess to assign policies to my users rather than rely solely on the Skype admin portal. My question is related to how defaults policies are applied to new users. There are two of the default system policies that randomly seem to get applied for external access - NoFedarationAndPIC and FederationAndPICDefault. Does anyone know the criteria that decides which gets applied? In probably 95% of cases NoFederation is applied but I found 10 or so users this morning that had the Federation policy applied. We are strictly controlling our external federation by user groups so it's pretty important and currently I'm having to check each new user that's been created what policy has been applied.846Views0likes1CommentUpdated Automatic Australian RGS/Response Groups Holiday Sets v.2.20
Update 19/05/2018 Released Version 2.2 to fix an issue with multiple pool selection, typos and even cleaning up my code with ISESteriods About the tool For those that don't know, I've been writing and maintaining this script for a few years over on TechNet This is a script that adds/maintains the relevant Australian Holidays to your Skype4B / Lync environment for the next 12 months based on data available from the Australian Government Website. I re-wrote most of the script from scratch and added a whole bunch of code to try and catch a lot of the errors etc that happened in the older versions. I’ve also tried to make it alot simpler to use for everyone that’s not me. Data is taken from http://www.australia.gov.au/about-australia/special-dates-and-events/public-holidays and I have done my best to be as error free as possible. Shout of to Greig in Sydney for beta testing and providing the red pen. That guy would have made a brilliant English teacher. Instructions Download, and run on a Frontend or any machine with the Lync / Skype4B management tools installed The script will attempt to detect your Skype4B Setup and proceed accordingly If it only detects a single FrontEnd it will prompt you to confirm the selected pool and then configure new Holiday sets Should it detect multiple pools it will ask you to confirm which pool to use and configure new Holiday sets If it finds Holiday sets with the same name they will automatically have any existing entries removed If you already have holiday sets with the name names or you need to add a country code. You can specify a string with the -RGSPrepend parameter to prepend to the Holiday set names. Unattended (Scheduled Task) execution You can also use the script on a scheduled task to automatically pull and update the latest holidays on a monthly basis if your server has internet access. Simply specify -FrontEndPool <FEPoolFQDN> and -Unattended in the scheduled task. You can also still specify the -ServiceID and -Unattended parameters at the commandline if you want to specify the ServiceID directly. Use Get-CsRgsConfiguration -Identity Frontend.Skype4bAdmin.com to see valid service id’s Note either of these options will disable script update checking. So it pays to check manually every now and again. Applying the Holiday sets After you have run the script, you can find the time frames in the Response Groups Editor, Simply tick the states you want the workflow closed for. Note: each of the states already includes the National holiday set, so there is no need to tick both. Fork Me As alot of my code is open source, I’ve moved from storing my Git repo on VSTS over to GitHub. Feel free to fork the code for your own purposes over here https://github.com/Atreidae/New-CsRgsAustralianHolidayList Advanced The default holiday set names are “National”,”Victoria”,”New South Wales”,”Queensland”,”ACT”,”Northern Territory”,”South Australia”,”Western Australia”,”Tasmania” If you need to change these for whatever reason update the following lines in the script 1 2 3 4 5 6 7 8 9 $National = $RGSPrepend+"National" $Vic = $RGSPrepend+"Victoria" $NSW = $RGSPrepend+"New South Wales" $QLD = $RGSPrepend+"Queensland" $ACT = $RGSPrepend+"ACT" $NT = $RGSPrepend+"Northern Territory" $SA = $RGSPrepend+"South Australia" $WA = $RGSPrepend+"Western Australia" $Tas = $RGSPrepend+"Tasmania" Version history Update 19/05/2018 Released Version 2.2 Fixed a bug with logging system culture Removed some old redundant code Passed script through ISESteriods PSSharper and applied corrections Fixed a few typos Fixed a few bugs introduced cleaning up my dodgy code Fixed a bug with multiple pools using the same holiday set names Deprecated the ServiceID parameter, Specify the pool FQDN instead Added warning for deprecated ServiceID Updated Pat Richard's website Removed PowerShell 5.1 cmdlet (Get-Timezone), now using a WMI query instead Update 11/05/2018 Released Version 2.1 with TLS 1.2 support Added Script logging Updated to use my new autoupdate code Added ability to switch between devel/master branches Added timezone offset detection / warning Added TLS 1.2 support for the new Govt website requirements Update 09/10/2017 Released Version 2.0 with a Massive Overhaul, updated for 2018! Added Autodetecton of single RGS pool : Added Autodetecton of single RGS pool Complete Rewrite of existing rule rewrite code , Should make for alot less red text! More User friendly and better instructions Fixed a few typo’s causing dates to be incorrect. You no longer need to “Reassign” the holiday sets to response groups anymore. Update 2/11/2016: Released Version 1.1 of the script. Fixed Onedrive download link Fix for Typo in Victora Holiday set causing import to fail Fix ForEach loop not correctly removing old time frames Fix Documentation not including the SID for ServiceID parameter Update 26/09/2016: Fixed some Typo’s. Thanks Grieg6.7KViews1like1CommentSkype For Business Blocked Contacts Through PowerShell
I had an interesting request. Output users within the company that are blocking other users within the company. I looked through PowerShell attributes and couldn't find anything, and then I posted on https://www.experts-exchange.com/questions/29086846/Skype-For-Business-Blocked-Contacts-Through-PowerShell.html. I figured that since it follows the user it would be an attribute somewhere that I could pull. Has anyone seen or run into this before?Solved2.6KViews0likes1Comment