Last active
March 15, 2025 13:46
-
-
Save expiscornovus/07a1db004fbf8e8018fb928acb5479ef to your computer and use it in GitHub Desktop.
Add Call to Action Web Part on Page
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"id":"b498d6f8-be58-4005-81ba-3d4a8427056e","brandColor":"#036C70","connectionReferences":{"shared_sharepointonline":{"connection":{"id":"/exp_sharedsharepointonline_e5efa"}}},"connectorDisplayName":"SharePoint","icon":"https://conn-afd-prod-endpoint-bmc9bqahasf3grgk.b01.azurefd.net/releases/v1.0.1738/1.0.1738.4131/sharepointonline/icon.png","isTrigger":false,"operationName":"Send_an_HTTP_request_to_SharePoint","operationDefinition":{"type":"OpenApiConnection","inputs":{"host":{"connectionName":"shared_sharepointonline","operationId":"HttpRequest","apiId":"/providers/Microsoft.PowerApps/apis/shared_sharepointonline"},"parameters":{"dataset":"@parameters('SPOSiteCollection_PowerUsers (exp_SPOSiteCollection_PowerUsers)')","parameters/method":"PATCH","parameters/uri":"_api/v2.0/sites('@{variables('SiteId')}')/pages/@{variables('SitePageId')}/oneDrive.page","parameters/headers":{"Accept":"application/json;odata=verbose","Content-Type":"application/json;odata=verbose"},"parameters/body":"{\n \"@odata.type\": \"#microsoft.graph.sitePage\",\n \"title\": \"Call to Action Example\",\n \"canvasLayout\": {\n \"horizontalSections\": [\n {\n \"layout\": \"oneColumn\",\n \"id\": \"1\",\n \"emphasis\": \"none\",\n \"columns\": [\n {\n \"id\": \"1\",\n \"webparts\": [\n {\n \"id\": \"665084dc-3477-4a35-a628-b031c55a24ef\",\n \"webPartType\": \"df8e44e7-edd5-46d5-90da-aca1539313b8\",\n \"data\": {\n \"dataVersion\": \"1.1\",\n \"title\": \"Call to action\",\n \"description\": \"Add a line to divide areas on your page.\",\n \"properties\": {\n \"alignment\": \"Left\",\n \"minimumLayoutWidth\": 10,\n \"button\": {\n \"@odata.type\": \"#graph.Json\"\n },\n \"overlayText\": {\n \"@odata.type\": \"#graph.Json\"\n },\n \"image\": {\n \"@odata.type\": \"#graph.Json\",\n \"zoomRatio\": 1\n }\n },\n \"serverProcessedContent\": {\n \"htmlStrings\": [],\n \"searchablePlainTexts\": [\n {\n \"key\": \"button.label\",\n \"value\": \"Submit here\"\n },\n {\n \"key\": \"overlayText.text\",\n \"value\": \"We want your feedback\"\n }\n ],\n \"links\": [\n {\n \"key\": \"button.linkUrl\",\n \"value\": \"https://forms.office.com/Pages/ResponsePage.aspx?id=somerandomidentifier\"\n }\n ],\n \"imageSources\": [\n {\n \"key\": \"image.url\",\n \"value\": \"https://cdn.hubblecontent.osi.office.net/m365content/publish/60f0f9cd-049c-4534-a5d2-b5b08b8ed62e/1220117316.jpg\"\n }\n ]\n }\n }\n }\n ]\n }\n ]\n }\n]\n}\n}"},"authentication":{"type":"Raw","value":"@json(decodeBase64(triggerOutputs().headers['X-MS-APIM-Tokens']))['$ConnectionKey']"}},"runAfter":{"Initialize_variable_-_SitePageId":["Succeeded"]},"metadata":{"operationMetadataId":"a9d3189e-1ed6-436a-bca6-d109d8a2888b"}}} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment