Shantha Kumar T
Clone your Team using Microsoft Graph API
Most of the time, we need to do a replica of the same Office 365 group with settings and so on. Microsoft Graph API comes with an awesome feature to do the same.
By using that we can clone the following items,
- Apps installed in the Team
- Tabs within each Channels
- All settings within the Team, along with key group settings
- Structure of the channel. (But messages won’t be copied)
- The members and owners of the team
Follow the below steps to clone the Team using Microsoft Graph Explorer,
- Navigate to Microsoft graph Explorer aka.ms/ge
- Then find out the team id/group id, you want to clone or copy
- Select the Post method in Graph explorer
- Select beta or v1.0 version
- Enter the Graph API endpoint in the below format
https://graph.microsoft.com/v1.0/teams/<team id>/clone
- Add the Content-Type : application/json as Request headers
- Add the body in the below format,
[code lang=”js”]
{
"displayName": "Cloned Graph Team",
"description": "Testing the cloning feature from Microsoft Graph API",
"mailNickname": "clonegraphteam",
"partsToClone": "apps,tabs,settings,channels,members",
"visibility": "public"
}
[/code]
- Then click the Run query button to clone the Group/team based on the provided settings.
We can use the parts to clone parameter to define, which objects need to copy into the new group. Below is the screenshot in MS Team after few seconds.
Thanks for the Post Shantha..
Do you know any way we can configure tabs and bringing folder structure automatically using Graph API/Power Automate after cloning the team .?
-Purna
Hi Kumar,
We have tried using Graph API to clone Team sites, but the lists (we have 4 lists and 1 planner) are showing up with a permissions error when the new sites are created.
FYI – we have 3 template sites, each with 4 custom lists and 1 custom calendar list.
Any idea why this is happening? Happy to share more specifics if required.