Home

Set retention label using flow or auto create retention on a folder

%3CLINGO-SUB%20id%3D%22lingo-sub-572153%22%20slang%3D%22en-US%22%3ESet%20retention%20label%20using%20flow%20or%20auto%20create%20retention%20on%20a%20folder%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-572153%22%20slang%3D%22en-US%22%3E%3CP%3EHave%20already%20posted%20this%20on%20the%20Flow%20Community%20but%20keen%20to%20see%20if%20anyone%20has%20solved%20this%20sort%20of%20issue%20for%20SharePoint%20Online%2C%20automating%20folder%20creation%20and%20applying%20retention%20policies%20(labels)%20from%20compliance%20center.%3C%2FP%3E%3CP%3E%26nbsp%3BHave%20been%20creating%20a%20Flow%20to%20create%20folders%20in%20SharePoint%20Online%20using%20the%20Send%20a%20HTTP%20request%20to%20SharePoint.%3C%2FP%3E%3CP%3EFlow%20starts%20with%20Input%20Employee%20Name.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F113661iD7C1980884BE54E2%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20alt%3D%22Flow%20Employee%20Name.PNG%22%20title%3D%22Flow%20Employee%20Name.PNG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EDeclares%20the%20relative%20path.%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F113662i9D0A06818F035517%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20alt%3D%22relativepath.PNG%22%20title%3D%22relativepath.PNG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3ECreates%20the%20folder%20using%20Send%20http%20request%20to%20create%20a%20folder.%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F113663i1307B9480E06F205%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20alt%3D%22Sendhttp1.PNG%22%20title%3D%22Sendhttp1.PNG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThen%20I'm%20trying%20to%20see%20if%20I%20can%20use%20the%20Send%20http%20request%20to%20SharePoint%20to%20set%20the%20Retention%20Label.%20%23Note%20-this%20is%20not%20a%20SharePoint%20classic%20retention%20label%20but%20the%20one%20that%20comes%20from%20the%20Compliance%20center%20labels.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F113664i32786F3CADEB4790%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20alt%3D%22sendhttpretention.PNG%22%20title%3D%22sendhttpretention.PNG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ESo%20the%20flow%20doesn't%20error.%20But%20the%20retention%20label%20is%20not%20set.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIs%20this%20actually%20possible%3F%3C%2FP%3E%3CP%3EAm%20I%20using%20the%20correct%20uri%20API%3F%3C%2FP%3E%3CP%3EDoes%20the%20body%20look%20correct%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EHave%20you%20solved%20this%20another%20way%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAny%20help%20would%20be%20greatly%20appreciated.%20Thanks%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-572153%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EAdmin%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ESharePoint%20Online%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
Highlighted
Sam Gray
Senior Member

Have already posted this on the Flow Community but keen to see if anyone has solved this sort of issue for SharePoint Online, automating folder creation and applying retention policies (labels) from compliance center.

 Have been creating a Flow to create folders in SharePoint Online using the Send a HTTP request to SharePoint.

Flow starts with Input Employee Name. 

 

Flow Employee Name.PNG

 

Declares the relative path.relativepath.PNG

Creates the folder using Send http request to create a folder.

Sendhttp1.PNG

 

Then I'm trying to see if I can use the Send http request to SharePoint to set the Retention Label. #Note -this is not a SharePoint classic retention label but the one that comes from the Compliance center labels. 

 

sendhttpretention.PNG

 

So the flow doesn't error. But the retention label is not set.

 

Is this actually possible?

Am I using the correct uri API?

Does the body look correct?

 

Have you solved this another way?

 

Any help would be greatly appreciated. Thanks

Related Conversations
flashing a white screen while open new tab
cntvertex in Discussions on
13 Replies
Stable version of Edge insider browser
HotCakeX in Discussions on
35 Replies
Tabs and Dark Mode
cjc2112 in Discussions on
22 Replies
How to Prevent Teams from Auto-Launch
chenrylee in Microsoft Teams on
28 Replies