Posted November 27, 2024Nov 27 FPCH Staff so im trying to do what the title says but i keep getting the error from the flow that the group cannot be found although it exists and i can find it connected to the sharepoint site here is the http request i have been trying :{ "inputs": { "host": { "connectionName": "shared_sharepointonline", "operationId": "HttpRequest", "apiId": "/providers/Microsoft.PowerApps/apis/shared_sharepointonline" }, "parameters": { "dataset": "https://xxxtest.sharepoint.com/teams/@{body('Parse_JSON')?['groupAlias']}", "parameters/method": "POST", "parameters/uri": "_api/web/sitegroups/getbyname('Site Collection Administrators')/users", "parameters/headers": { "Accept": "application/json;odata=verbose", "Content-Type": "application/json" }, "parameters/body": "{\n \"LoginName\": \"i:0#.f|membership|THE_GROUP_NAME\"\n}\n" }, "authentication": "@parameters('$authentication')" }, "metadata": { "operationMetadataId": "new-operation-id" } }I presume im writing something wrong in the api request or in the body but i couldnt find any helpful resources that does exactly what im doing , the closest thing i found is this (adding a role permission which worked when i tried it and it could find the group , but i want it to add the group to the site collection admins not just give it a permission):https://ganeshsanapblogs.wordpress.com/2022/11/05/sharepoint-online-grant-permissions-to-azure-ad-security-group-using-power-automate-and-rest-api/
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.