Right before a short holiday =I had the opportunity to present on the DIWUG. The night was sponsored by Ilionix and Bram de Jager and me both did a session. We both focused on Office 365 topics. I did a session on the Office 365 Groups and what you as a developer can achieve with them. The slides are in Dutch yet a short write up can be found in this blog.
#@ Manage your groups with PowerShell
A while ago I already posted on Governance and Groups – retrieving inactive Office 365 Groups and disabling groups for specific users. You can find an overview of all group related PowerShell commandlets on Office Support. Keep in mind though that in order to work with groups you will need the Exchange Commandlets available. You can easily load them by using the following command:
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection Import-PSSession $Session
Without having connected to Exchange you cannot use the group commandlets. In order to work with the site that is linked to your group you will also have to connect to SharePoint Online by using the Connect-SPOService that is available in the SharePoint Online Managementshell.
Connect-SPOService -Url "https://tenant-admin.sharepoint.com"
Enrich groups with Connectors
Connectors are a great way to enrich or add content in your groups, yet they are in preview. In order to enable them and start playing around with them you will need to add
To your URL and you can start having fun. A great start is to read up on dev.office but Wictor Willen has a great article called: Enhancing your Office 365 Groups using custom Connectors and Cards for Groups as well. In my demo I used PostMan to post some requests to show how to work with custom cards. In order to work with PostMan all you have to do is install it, and set the set the type to JSON (application/json) and put in the JSON you want to post. As webhooks do not require extra authorization you can quickly test and modify your JSON and see how it looks:
Build add-ins with the Microsoft Graph
Finally we ended up on working with Groups by using the Microsoft Graph. To start working with the Microsoft Graph you can go to graph.microsoft.io. In the demo I used Yo Office to generate a simple webapp based on angular. My old colleague Waldek Mastykarz did a great write-up on working with groups with the Beta endpoint. Currently the endpoints are publicly available so there is no longer a need to use the /beta/ endpoint for your actions. All that remains is to make sure the add-in has the proper rights and you are ready to retrieve groups and group files.