Setting External access options via powershell

Copper Contributor

Hi.

I'm trying to set External access for Teams, but via powershell. Specifically the "Users can communicate with Skype users" option.

 mskrgulja_0-1600162406593.png

I can successfully set the  "Users can communicate with other Skype for Business and Teams users", but I can't find a solution for the other option ("Users can communicate with Skype users").

 

I have read numbers of blog postings, tutorials for the mentioned subject but it just doesn't work, the option won't switch.

 

Most mentioned powershell command for doing it, is the following:

 

 

 

 

    Set-CsExternalAccessPolicy -EnableOutsideAccess $False
    Set-CsExternalAccessPolicy -EnableFederationAccess $False
    Set-CsExternalAccessPolicy -EnablePublicCloudAccess $False
    Set-CsExternalAccessPolicy -EnablePublicCloudAudioVideoAccess $False

 

 

 

 

 

And while the script changes the targeted parameters successfully, the switch in the GUI still remains in "ON" position. 

 

I Have set the switch to the "OFF" position by hand, but underlying parameters quoted in code block above, haven't changed (their values retrieved with Get-CsExternalAccessPolicy powershell command. So, from that, it seems that those commands aren't for that option after all..

 

Any help is appreciated.

Br

11 Replies

@mskrgulja Hi, you are using the correct switch as described here.

 

https://docs.microsoft.com/en-us/microsoftteams/teams-skype-interop#using-powershell

 

Bear in mind that it can take several days for settings in Teams to take effect.

@ChristianBergstrom 

Hi. thank you for your response.

I thought that it needed several days for settings to become effective, but I assumed that the GUI switch position would reflect the underlying (powershell changed) change immediately (just like is the case with the first setting).

 

I will try to make the setting with powershell as I did before, but I will wait a few day to see if the changes will be reflected in the teams admin user interface.

 

Br.

@mskrgulja Hello again, I agree. The GUI should show what setting is set. Please verify the settings if you are on-premise, online or hybrid.

 

https://docs.microsoft.com/en-US/microsoftteams/manage-external-access?WT.mc_id=TeamsAdminCenterCSH#... 

 

*edit* just want to add that this preview has not been very well managed. It was rolled out and withdrawn etc. I'm doing some testing of my own and it doesn't look as it should, meaning the GUI says one thing and PowerShell another. So perhaps it isn't working properly now either. Please let me know if it is any difference when following the above prerequisites for Skype consumer federation.

@ChristianBergstrom 

Hi.

I did verify the setting (AllowPublicUsers and EnablePublicCloudAccess), and it's set as I left it (the change I made with powershell is applied, but not in the GUI).

 

I also experimented changing the setting directly in GUI (flipping the switch) but the underlying parameters (CsExternalAccessPolicy -EnablePublicCloudAccess) did not change. 

Is there a bug possibility (since Communicate with Skype users is label "in preview")?

 

Thank you.

Br

 

@mskrgulja See my edit above :)

@ChristianBergstrom 

I'm dealing with this problem for days now.. I followed a few posts (including the one you linked). Nothing worked.

The first setting(Users can communicate with other Skype for Business and Teams users) is correctly set with powershell and reflected in GUI, just like described in the post you linked (Step 1).

 

Br

 

P.S. Thanks for bearing with me.

 

@mskrgulja No worries! I think we can assume that this preview is still experiencing issues.

@mskrgulja 

 

I'm trying to do something similar. However, how did you manage to use the Set-CsExternalAccessPolicy command? 

 

I keep getting a not found error: ObjectNotFound: (Set-CsExternalAccessPolicy:String)

 

Thanks.

 

*Updated post*

 

They mention that you can toggle it on using Teams admin center

Manage external access (federation) - Microsoft Teams | Microsoft Docs

 

But I've never actually heard of anyone succeeding in doing that so that's why we use PowerShell as also mentioned here 

Manage external access (federation) - Microsoft Teams | Microsoft Docs 

 

But that's not all steps required and the others are instead listed here

Teams and Skype interoperability - Microsoft Teams | Microsoft Docs

 

So you would have to verify these settings (1, 2, 3) and also be aware of the online vs hybrid scenario Manage external access (federation) - Microsoft Teams | Microsoft Docs

 

1. Set-CsExternalAccessPolicy
-EnablePublicCloudAccess

 

"Indicates whether the user is allowed to communicate with people who have SIP accounts with a public Internet connectivity provider such as MSN. The default value is False."

 

2. Set-CsTenantFederationConfiguration
-AllowPublicUsers

 

"When set to True (the default value) users will be potentially allowed to communicate with users who have accounts on public IM and presence providers such as Windows Live, Yahoo, and AOL. The collection of public providers that users can actually communicate with is managed by using the Set-CsTenantPublicProvider cmdlet."

 

3. Set-CsTenantPublicProvider
-Provider

 

"Indicates the public provider (or providers) that users will be allowed to communicate with. Valid values are:"

 

  • AOL
  • WindowsLive
  • Yahoo

@Ken_M5 

Hi ken.
I couldn't find a solution. We concluded that the documentation was incomplete, and possibly not supported (since the option was still in the "preview" phase) so we didn't want to waste any more time on this.

Also, the project (of which we had to change the Teams settings was part of) was abandoned so I never come back to this problem anymore.

 

Br,
Matija

@mskrgulja , @ChristianBergstrom please note the updated documentation for external access. External access is controlled by both a tenant configuration and a policy. In the case of TAC, the toggles control the tenant configuration which then enables/disables users. Additional refinement can be done using PowerShell and the policy.