From f17c007e58af06df3fc074e1098efb368e648d18 Mon Sep 17 00:00:00 2001 From: Zunair <zunair@hotmail.com> Date: Wed, 13 Nov 2024 17:49:48 -0500 Subject: [PATCH 1/8] Create microsoft-powerautomate-post-adaptivecard.json Allows sending AdaptiveCard to Microsoft Teams via Microsoft Power Automate. --- ...osoft-powerautomate-post-adaptivecard.json | 137 ++++++++++++++++++ 1 file changed, 137 insertions(+) create mode 100644 step-templates/microsoft-powerautomate-post-adaptivecard.json diff --git a/step-templates/microsoft-powerautomate-post-adaptivecard.json b/step-templates/microsoft-powerautomate-post-adaptivecard.json new file mode 100644 index 00000000..ee1abf22 --- /dev/null +++ b/step-templates/microsoft-powerautomate-post-adaptivecard.json @@ -0,0 +1,137 @@ +{ + "Id": "707e6dae-0d6f-4121-ab8d-6961039c4162", + "Name": "Microsoft Automate - Post AdaptiveCard", + "Description": "Posts a message to Microsoft Teams using Microsoft Power Automate webhook.", + "ActionType": "Octopus.Script", + "Version": 1, + "CommunityActionTemplateId": null, + "Packages": [], + "GitDependencies": [], + "Properties": { + "Octopus.Action.Script.ScriptBody": "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12\n\n# Helper functions\nfunction Retry-Command {\n [CmdletBinding()]\n Param(\n [Parameter(Position=0, Mandatory=$true)]\n [scriptblock]$ScriptBlock,\n \n [Parameter(Position=1, Mandatory=$false)]\n [int]$Maximum = 5,\n\n [Parameter(Position=2, Mandatory=$false)]\n [int]$Delay = 100\n )\n\n Begin {\n $count = 0\n }\n\n Process {\n \t$ex=$null\n do {\n $count++\n \n try {\n Write-Verbose \"Attempt $count of $Maximum\"\n $ScriptBlock.Invoke()\n return\n } catch {\n $ex = $_\n Write-Warning \"Error occurred executing command (on attempt $count of $Maximum): $($ex.Exception.Message)\"\n Start-Sleep -Milliseconds $Delay\n }\n } while ($count -lt $Maximum)\n\n throw \"Execution failed (after $count attempts): $($ex.Exception.Message)\"\n }\n}\n# End Helper functions\n\n[int]$timeoutSec = $null\n[int]$maximum = 1\n[int]$delay = 100\n\nif(-not [int]::TryParse($OctopusParameters['Timeout'], [ref]$timeoutSec)) { $timeoutSec = 60 }\n\nif ($OctopusParameters[\"AutomatePostMessage.RetryPosting\"] -eq $True) {\n\tif(-not [int]::TryParse($OctopusParameters['RetryCount'], [ref]$maximum)) { $maximum = 1 }\n\tif(-not [int]::TryParse($OctopusParameters['RetryDelay'], [ref]$delay)) { $delay = 100 }\n\t\n Write-Verbose \"Setting maximum retries to $maximum using a $delay ms delay\"\n}\n\n# Create the payload for Power Automate\n$payload = @{\n type = \"message\" # Fixed value for message type\n attachments = @(\n @{\n contentType = \"application/vnd.microsoft.card.adaptive\"\n content = @{\n type = \"AdaptiveCard\"\n body = @(\n @{\n type = \"TextBlock\"\n text = $OctopusParameters['Title']\n weight = \"bolder\"\n size = \"medium\"\n color= $OctopusParameters['TitleColor']\n },\n @{\n type = \"TextBlock\"\n text = $OctopusParameters['Body']\n wrap = $true\n color= $OctopusParameters['BodyColor']\n }\n )\n actions = @(\n @{\n type = \"Action.OpenUrl\"\n title = $OctopusParameters['ButtonTitle']\n url = $OctopusParameters['ButtonUrl']\n }\n )\n \"`$schema\" = \"http://adaptivecards.io/schemas/adaptive-card.json\"\n version = \"1.0\"\n }\n }\n )\n}\n\nRetry-Command -Maximum $maximum -Delay $delay -ScriptBlock {\n #Write-Output ($payload | ConvertTo-Json -Depth 6)\n \n # Prepare parameters for the POST request\n $invokeParameters = @{\n Method = \"POST\"\n Uri = $OctopusParameters['HookUrl']\n Body = ($payload | ConvertTo-Json -Depth 6 -Compress)\n ContentType = \"application/json; charset=utf-8\"\n TimeoutSec = $timeoutSec\n }\n\n # Check for UseBasicParsing (needed for some environments)\n if ((Get-Command Invoke-RestMethod).Parameters.ContainsKey(\"UseBasicParsing\")) {\n $invokeParameters.Add(\"UseBasicParsing\", $true)\n }\n\n # Send the request to the Power Automate webhook\n $Response = Invoke-RestMethod @invokeParameters\n Write-Verbose \"Response: $Response\"\n}\n", + "Octopus.Action.Script.Syntax": "PowerShell", + "Octopus.Action.Script.ScriptSource": "Inline" + }, + "Parameters": [ + { + "Id": "5d460a15-4052-44f7-85a2-f75cdf77da03", + "Name": "HookUrl", + "Label": "Webhook Url", + "HelpText": "The specific URL created by Microsoft Power Automate using 'When a Teams webhook request is received' flow template. Copy and paste the full HTTP URL from Microsoft Power Automate.", + "DefaultValue": "", + "DisplaySettings": { + "Octopus.ControlType": "SingleLineText" + } + }, + { + "Id": "53b1de0d-261e-464f-91e1-b7307fd5d1a2", + "Name": "Title", + "Label": "Message title", + "HelpText": "The title of the message that will be posted to your Microsoft Teams channel.", + "DefaultValue": "#{Octopus.Project.Name} #{Octopus.Release.Number} deployed to #{Octopus.Environment.Name}#{if Octopus.Deployment.Tenant.Id} for #{Octopus.Deployment.Tenant.Name}#{/if}", + "DisplaySettings": { + "Octopus.ControlType": "SingleLineText" + } + }, + { + "Id": "14c34ec8-5e44-40c6-bf93-7d4920a78b80", + "Name": "Body", + "Label": "Message body", + "HelpText": "The message body of post being added to your Microsoft Teams channel.", + "DefaultValue": "For more information, please see [deployment details](#{if Octopus.Web.ServerUri}#{Octopus.Web.ServerUri}#{else}#{Octopus.Web.BaseUrl}#{/if}#{Octopus.Web.DeploymentLink})!", + "DisplaySettings": { + "Octopus.ControlType": "MultiLineText" + } + }, + { + "Id": "60d65627-fa61-4203-becf-ae316488a774", + "Name": "TitleColor", + "Label": "Title Color", + "HelpText": "The color to use for the title of the adaptive card.", + "DefaultValue": "default", + "DisplaySettings": { + "Octopus.ControlType": "Select", + "Octopus.SelectOptions": "default|Default\ndark|Dark\nlight|Light\naccent|Accent\ngood|Good\nwarning|Warning\nattention|Attention" + } + }, + { + "Id": "1491e7d2-2677-4119-a159-09715173af25", + "Name": "Timeout", + "Label": "Timeout in seconds", + "HelpText": "The maximum timeout in seconds for each request.", + "DefaultValue": "60", + "DisplaySettings": { + "Octopus.ControlType": "SingleLineText" + } + }, + { + "Id": "0c5e5a4a-35c2-48f7-b0e3-6e2e2b14b383", + "Name": "TeamsPostMessage.RetryPosting", + "Label": "Retry posting message", + "HelpText": "Should retries be made? If this option is enabled, the step will attempt to retry the posting of message to teams up to the set retry count. Default: `False`.", + "DefaultValue": "False", + "DisplaySettings": { + "Octopus.ControlType": "Checkbox" + } + }, + { + "Id": "b1d2acda-5e82-42a9-bd05-6cc4827f5974", + "Name": "TeamsPostMessage.RetryCount", + "Label": "Retry Count", + "HelpText": "The maximum number of times to retry the post before allowing failure. Default 1", + "DefaultValue": "1", + "DisplaySettings": { + "Octopus.ControlType": "SingleLineText" + } + }, + { + "Id": "bc9438f7-3c74-4f2e-a5a5-4cb4c38767d9", + "Name": "TeamsPostMessage.RetryDelay", + "Label": "Retry delay in milliseconds", + "HelpText": "The amount of time in milliseconds to wait between retries. Default 100", + "DefaultValue": "100", + "DisplaySettings": { + "Octopus.ControlType": "SingleLineText" + } + }, + { + "Id": "e1606576-d9af-489f-a343-916cc809c1c3", + "Name": "BodyColor", + "Label": "Body Color", + "HelpText": "The color to use for the body of the adaptive card.", + "DefaultValue": "default", + "DisplaySettings": { + "Octopus.ControlType": "Select", + "Octopus.SelectOptions": "default|Default\ndark|Dark\nlight|Light\naccent|Accent\ngood|Good\nwarning|Warning\nattention|Attention" + } + }, + { + "Id": "6222bf83-af8b-40dd-a504-eb7ab0208981", + "Name": "ButtonTitle", + "Label": "Button Title", + "HelpText": "The button title of post being added to your Microsoft Teams channel.", + "DefaultValue": "Adaptive Card Designer", + "DisplaySettings": { + "Octopus.ControlType": "SingleLineText" + } + }, + { + "Id": "a550bde0-e622-457c-b2b6-6a6089cf2fa8", + "Name": "ButtonUrl", + "Label": "Button url", + "HelpText": "The button url of post being added to your Microsoft Teams channel.", + "DefaultValue": "https://adaptivecards.io/designer/", + "DisplaySettings": { + "Octopus.ControlType": "SingleLineText" + } + } + ], + "StepPackageId": "Octopus.Script", + "$Meta": { + "ExportedAt": "2024-11-13T22:40:25.875Z", + "OctopusVersion": "2024.3.12828", + "Type": "ActionTemplate" + }, + "LastModifiedBy": "Zunair", + "Category": "microsoft-powerautomate" +} From 4ca0e4dea92122bc49489cd4b36a0a0f68204d26 Mon Sep 17 00:00:00 2001 From: Zunair <zunair@hotmail.com> Date: Wed, 13 Nov 2024 17:56:02 -0500 Subject: [PATCH 2/8] Add files via upload --- .../logos/microsoft-power-automate.png | Bin 0 -> 3894 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 step-templates/logos/microsoft-power-automate.png diff --git a/step-templates/logos/microsoft-power-automate.png b/step-templates/logos/microsoft-power-automate.png new file mode 100644 index 0000000000000000000000000000000000000000..6b8c1ed1b98e2334354f290d3a8a2e4ba7f405a8 GIT binary patch literal 3894 zcmZ`+XHb({wEYmN1`tp>Qlv@I(1Z)2NHa)RdJ9F0^b!REBvCpjp(sU~paLSjNG~e6 zlz>5k1PDdMOK;Lc%gcT5*ZuM4%-L(s-h0hCb7sw+SxM%mcUhSEm;nG_F@);fr=rWh zn~|Oxf8~U!QsJW49g{l%P=~p6>PkmF3%f(_n*abp0szpl0B}rAp_c*RF&F?=T>wBW z2LQN(^4lyR)B?Sm(Oo@&^6z@nS(Zu7Fu)B>^cj}v*+Gin<W&0&0AN)!)VpIDKDFWG z8}wi)7ugjmR&aeXD{zO7<l^AsM`ots2gPeMUmSIFVG_Z8GHmysk(iM%Qo+H?CX>nt zv8BWBS#HEO7I+$Y85Wz2j$F=q7c0xeZ=1-1ZG6P}%rI+w+Rv_QIpo{nCL1mzD%;Nx z=2_vj_}qWxNL>vdNuFJb#?U~8pI+qnPv{m01JJpn6Cbn&NQV~PI04H7n90a~2c^9Z zkvZ0Aj6vl*WiX=u@!r!=8uZ#ZvEQkCD!3=#4RM6MRa(UEgKlJ5^5OX^58Nn{8h!L~ z*FZcv$e-B`hYDi7z|fBZ0J!C?+<h8xlIOEGUS(~3&PO_%>Lnmy`Ja(>*XPWJe#%2Z zaeokrHk@>rV50CQC70ImFtdh%ZS(7TMScoo;C5yxn)A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0Jon?^=(mYD3{J(SWhUQ7xXmvpTMuRfwHkCt*4yjHyGu5~os{vT`he@^XJEQR5e zA#ZwxQ|}YiSc=2-ZQ&1H;T~%4As$o!6u=5fa^Tx?@+y|{3Tn#oYD%gyV6Yk(>^^ht f(tim4fe#;fM*RN-4s>ZVl>iv(o9b2TxIFtG(du*g literal 0 HcmV?d00001 From 13c57819647077e1865ed7d04b61e79155c57537 Mon Sep 17 00:00:00 2001 From: Zunair <zunair@hotmail.com> Date: Wed, 13 Nov 2024 18:00:00 -0500 Subject: [PATCH 3/8] Update gulpfile.babel.js Adds Microsoft Power Automate in humanize. --- gulpfile.babel.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gulpfile.babel.js b/gulpfile.babel.js index 31d5ac99..114233eb 100644 --- a/gulpfile.babel.js +++ b/gulpfile.babel.js @@ -203,6 +203,8 @@ function humanize(categoryId) { return "MariaDB"; case "microsoft-teams": return "Microsoft Teams"; + case "microsoft-power-automate": + return "Microsoft Power Automate"; case "mongodb": return "MongoDB"; case "mulesoft": From 1024a800e06d6b1a65bea313e9d70f99e0288ff5 Mon Sep 17 00:00:00 2001 From: Zunair <zunair@hotmail.com> Date: Wed, 13 Nov 2024 18:03:34 -0500 Subject: [PATCH 4/8] Update microsoft-powerautomate-post-adaptivecard.json --- step-templates/microsoft-powerautomate-post-adaptivecard.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/step-templates/microsoft-powerautomate-post-adaptivecard.json b/step-templates/microsoft-powerautomate-post-adaptivecard.json index ee1abf22..85738663 100644 --- a/step-templates/microsoft-powerautomate-post-adaptivecard.json +++ b/step-templates/microsoft-powerautomate-post-adaptivecard.json @@ -1,6 +1,6 @@ { "Id": "707e6dae-0d6f-4121-ab8d-6961039c4162", - "Name": "Microsoft Automate - Post AdaptiveCard", + "Name": "Microsoft Power Automate - Post AdaptiveCard", "Description": "Posts a message to Microsoft Teams using Microsoft Power Automate webhook.", "ActionType": "Octopus.Script", "Version": 1, From bad023aacb027a6dbb285687c493f48635743e6b Mon Sep 17 00:00:00 2001 From: Zunair <zunair@hotmail.com> Date: Wed, 13 Nov 2024 18:07:14 -0500 Subject: [PATCH 5/8] Update microsoft-powerautomate-post-adaptivecard.json --- ...osoft-powerautomate-post-adaptivecard.json | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/step-templates/microsoft-powerautomate-post-adaptivecard.json b/step-templates/microsoft-powerautomate-post-adaptivecard.json index 85738663..38ff98bb 100644 --- a/step-templates/microsoft-powerautomate-post-adaptivecard.json +++ b/step-templates/microsoft-powerautomate-post-adaptivecard.json @@ -15,7 +15,7 @@ "Parameters": [ { "Id": "5d460a15-4052-44f7-85a2-f75cdf77da03", - "Name": "HookUrl", + "Name": "PowerAutomatePostAdaptiveCard.HookUrl", "Label": "Webhook Url", "HelpText": "The specific URL created by Microsoft Power Automate using 'When a Teams webhook request is received' flow template. Copy and paste the full HTTP URL from Microsoft Power Automate.", "DefaultValue": "", @@ -25,7 +25,7 @@ }, { "Id": "53b1de0d-261e-464f-91e1-b7307fd5d1a2", - "Name": "Title", + "Name": "PowerAutomatePostAdaptiveCard.Title", "Label": "Message title", "HelpText": "The title of the message that will be posted to your Microsoft Teams channel.", "DefaultValue": "#{Octopus.Project.Name} #{Octopus.Release.Number} deployed to #{Octopus.Environment.Name}#{if Octopus.Deployment.Tenant.Id} for #{Octopus.Deployment.Tenant.Name}#{/if}", @@ -35,7 +35,7 @@ }, { "Id": "14c34ec8-5e44-40c6-bf93-7d4920a78b80", - "Name": "Body", + "Name": "PowerAutomatePostAdaptiveCard.Body", "Label": "Message body", "HelpText": "The message body of post being added to your Microsoft Teams channel.", "DefaultValue": "For more information, please see [deployment details](#{if Octopus.Web.ServerUri}#{Octopus.Web.ServerUri}#{else}#{Octopus.Web.BaseUrl}#{/if}#{Octopus.Web.DeploymentLink})!", @@ -45,7 +45,7 @@ }, { "Id": "60d65627-fa61-4203-becf-ae316488a774", - "Name": "TitleColor", + "Name": "PowerAutomatePostAdaptiveCard.TitleColor", "Label": "Title Color", "HelpText": "The color to use for the title of the adaptive card.", "DefaultValue": "default", @@ -56,7 +56,7 @@ }, { "Id": "1491e7d2-2677-4119-a159-09715173af25", - "Name": "Timeout", + "Name": "PowerAutomatePostAdaptiveCard.Timeout", "Label": "Timeout in seconds", "HelpText": "The maximum timeout in seconds for each request.", "DefaultValue": "60", @@ -66,7 +66,7 @@ }, { "Id": "0c5e5a4a-35c2-48f7-b0e3-6e2e2b14b383", - "Name": "TeamsPostMessage.RetryPosting", + "Name": "PowerAutomatePostAdaptiveCard.RetryPosting", "Label": "Retry posting message", "HelpText": "Should retries be made? If this option is enabled, the step will attempt to retry the posting of message to teams up to the set retry count. Default: `False`.", "DefaultValue": "False", @@ -76,7 +76,7 @@ }, { "Id": "b1d2acda-5e82-42a9-bd05-6cc4827f5974", - "Name": "TeamsPostMessage.RetryCount", + "Name": "PowerAutomatePostAdaptiveCard.RetryCount", "Label": "Retry Count", "HelpText": "The maximum number of times to retry the post before allowing failure. Default 1", "DefaultValue": "1", @@ -86,7 +86,7 @@ }, { "Id": "bc9438f7-3c74-4f2e-a5a5-4cb4c38767d9", - "Name": "TeamsPostMessage.RetryDelay", + "Name": "PowerAutomatePostAdaptiveCard.RetryDelay", "Label": "Retry delay in milliseconds", "HelpText": "The amount of time in milliseconds to wait between retries. Default 100", "DefaultValue": "100", @@ -96,7 +96,7 @@ }, { "Id": "e1606576-d9af-489f-a343-916cc809c1c3", - "Name": "BodyColor", + "Name": "PowerAutomatePostAdaptiveCard.BodyColor", "Label": "Body Color", "HelpText": "The color to use for the body of the adaptive card.", "DefaultValue": "default", @@ -107,7 +107,7 @@ }, { "Id": "6222bf83-af8b-40dd-a504-eb7ab0208981", - "Name": "ButtonTitle", + "Name": "PowerAutomatePostAdaptiveCard.ButtonTitle", "Label": "Button Title", "HelpText": "The button title of post being added to your Microsoft Teams channel.", "DefaultValue": "Adaptive Card Designer", @@ -117,7 +117,7 @@ }, { "Id": "a550bde0-e622-457c-b2b6-6a6089cf2fa8", - "Name": "ButtonUrl", + "Name": "PowerAutomatePostAdaptiveCard.ButtonUrl", "Label": "Button url", "HelpText": "The button url of post being added to your Microsoft Teams channel.", "DefaultValue": "https://adaptivecards.io/designer/", From 45266db70fb5d298b0443e058d0b93ad7dc2977f Mon Sep 17 00:00:00 2001 From: Zunair <zunair@hotmail.com> Date: Wed, 13 Nov 2024 18:09:24 -0500 Subject: [PATCH 6/8] Update microsoft-powerautomate-post-adaptivecard.json --- step-templates/microsoft-powerautomate-post-adaptivecard.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/step-templates/microsoft-powerautomate-post-adaptivecard.json b/step-templates/microsoft-powerautomate-post-adaptivecard.json index 38ff98bb..24b45638 100644 --- a/step-templates/microsoft-powerautomate-post-adaptivecard.json +++ b/step-templates/microsoft-powerautomate-post-adaptivecard.json @@ -133,5 +133,5 @@ "Type": "ActionTemplate" }, "LastModifiedBy": "Zunair", - "Category": "microsoft-powerautomate" + "Category": "microsoft-power-automate" } From 6d05123386fcb2fba5c51f0e163bb04dfcaa2e70 Mon Sep 17 00:00:00 2001 From: Zunair <zunair@hotmail.com> Date: Wed, 13 Nov 2024 18:25:48 -0500 Subject: [PATCH 7/8] Update microsoft-powerautomate-post-adaptivecard.json --- step-templates/microsoft-powerautomate-post-adaptivecard.json | 1 - 1 file changed, 1 deletion(-) diff --git a/step-templates/microsoft-powerautomate-post-adaptivecard.json b/step-templates/microsoft-powerautomate-post-adaptivecard.json index 24b45638..2c2fe789 100644 --- a/step-templates/microsoft-powerautomate-post-adaptivecard.json +++ b/step-templates/microsoft-powerautomate-post-adaptivecard.json @@ -126,7 +126,6 @@ } } ], - "StepPackageId": "Octopus.Script", "$Meta": { "ExportedAt": "2024-11-13T22:40:25.875Z", "OctopusVersion": "2024.3.12828", From 08f8c054becc075b82b485934625cb558362bf04 Mon Sep 17 00:00:00 2001 From: Zunair <zunair@hotmail.com> Date: Wed, 13 Nov 2024 18:26:42 -0500 Subject: [PATCH 8/8] Rename microsoft-powerautomate-post-adaptivecard.json to microsoft-power-automate-post-adaptivecard.json file rename --- ...ecard.json => microsoft-power-automate-post-adaptivecard.json} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename step-templates/{microsoft-powerautomate-post-adaptivecard.json => microsoft-power-automate-post-adaptivecard.json} (100%) diff --git a/step-templates/microsoft-powerautomate-post-adaptivecard.json b/step-templates/microsoft-power-automate-post-adaptivecard.json similarity index 100% rename from step-templates/microsoft-powerautomate-post-adaptivecard.json rename to step-templates/microsoft-power-automate-post-adaptivecard.json