Skip to content

Commit 6cde04e

Browse files
committed
fix: replace deprecated Slack actions with mrkdwn link field
The actions array in Slack attachments requires Interactive Components to be configured on the Slack app, which causes notifications to fail. Replaces with a Details field using mrkdwn hyperlink syntax and adds mrkdwn_in to ensure the link renders as clickable. Closes #4053
1 parent 4077af1 commit 6cde04e

File tree

2 files changed

+8
-10
lines changed

2 files changed

+8
-10
lines changed

packages/server/src/utils/notifications/build-error.ts

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -240,14 +240,13 @@ export const sendBuildErrorNotifications = async ({
240240
value: `\`\`\`${errorMessage}\`\`\``,
241241
short: false,
242242
},
243-
],
244-
actions: [
245243
{
246-
type: "button",
247-
text: "View Build Details",
248-
url: buildLink,
244+
title: "Details",
245+
value: `<${buildLink}|View Build Details>`,
246+
short: false,
249247
},
250248
],
249+
mrkdwn_in: ["fields"],
251250
},
252251
],
253252
});

packages/server/src/utils/notifications/build-success.ts

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -256,14 +256,13 @@ export const sendBuildSuccessNotifications = async ({
256256
value: date.toLocaleString(),
257257
short: true,
258258
},
259-
],
260-
actions: [
261259
{
262-
type: "button",
263-
text: "View Build Details",
264-
url: buildLink,
260+
title: "Details",
261+
value: `<${buildLink}|View Build Details>`,
262+
short: false,
265263
},
266264
],
265+
mrkdwn_in: ["fields"],
267266
},
268267
],
269268
});

0 commit comments

Comments
 (0)