:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
fix(hog-functions): use activity payload for actor in defaults (#58989)
Yasen771cd8b8c77e
diff --git a/frontend/src/scenes/hog-functions/sub-templates/sub-templates.ts b/frontend/src/scenes/hog-functions/sub-templates/sub-templates.tsindex 2f492f6b9c69..e295d02134f4 100644--- a/frontend/src/scenes/hog-functions/sub-templates/sub-templates.ts+++ b/frontend/src/scenes/hog-functions/sub-templates/sub-templates.ts@@ -270,7 +270,7 @@ export const HOG_FUNCTION_SUB_TEMPLATES: Record<HogFunctionSubTemplateIdType, Hodescription: 'Send a webhook when a team activity occurs',inputs: {content: {- value: "**{person.name ?? 'PostHog'}** {event.properties.activity} {event.properties.scope} `{event.properties.item_id}`",+ value: "**{event.properties.user.first_name ? event.properties.user.first_name : 'PostHog'}** {event.properties.activity} {event.properties.scope} `{event.properties.item_id}`",},},},@@ -281,7 +281,7 @@ export const HOG_FUNCTION_SUB_TEMPLATES: Record<HogFunctionSubTemplateIdType, Hodescription: 'Posts a message to Discord when a team activity occurs',inputs: {content: {- value: "**{person.name ?? 'PostHog'}** {event.properties.activity} {event.properties.scope} `{event.properties.item_id}`",+ value: "**{event.properties.user.first_name ? event.properties.user.first_name : 'PostHog'}** {event.properties.activity} {event.properties.scope} `{event.properties.item_id}`",},},},@@ -292,7 +292,7 @@ export const HOG_FUNCTION_SUB_TEMPLATES: Record<HogFunctionSubTemplateIdType, Hodescription: 'Posts a message to Microsoft Teams when a team activity occurs',inputs: {content: {- value: "**{person.name ?? 'PostHog'}** {event.properties.activity} {event.properties.scope} `{event.properties.item_id}`",+ value: "**{event.properties.user.first_name ? event.properties.user.first_name : 'PostHog'}** {event.properties.activity} {event.properties.scope} `{event.properties.item_id}`",},},},@@ -306,7 +306,7 @@ export const HOG_FUNCTION_SUB_TEMPLATES: Record<HogFunctionSubTemplateIdType, Hovalue: [{text: {- text: "*{person.name ?? 'PostHog'}* {event.properties.activity} {event.properties.scope} {event.properties.item_id}",+ text: "*{event.properties.user.first_name ? event.properties.user.first_name : 'PostHog'}* {event.properties.activity} {event.properties.scope} {event.properties.item_id}",type: 'mrkdwn',},type: 'section',@@ -314,7 +314,7 @@ export const HOG_FUNCTION_SUB_TEMPLATES: Record<HogFunctionSubTemplateIdType, Ho],},text: {- value: "*{person.name ?? 'PostHog'}* {event.properties.activity} {event.properties.scope} {event.properties.item_id}",+ value: "*{event.properties.user.first_name ? event.properties.user.first_name : 'PostHog'}* {event.properties.activity} {event.properties.scope} {event.properties.item_id}",},},},@@ -327,7 +327,7 @@ export const HOG_FUNCTION_SUB_TEMPLATES: Record<HogFunctionSubTemplateIdType, Hodescription: 'Send a webhook when a feature flag is changed',inputs: {content: {- value: "**{person.name ?? 'PostHog'}** {event.properties.activity} feature flag `{event.properties.item_id}`",+ value: "**{event.properties.user.first_name ? event.properties.user.first_name : 'PostHog'}** {event.properties.activity} feature flag `{event.properties.detail.name}`",},},},@@ -338,7 +338,7 @@ export const HOG_FUNCTION_SUB_TEMPLATES: Record<HogFunctionSubTemplateIdType, Hodescription: 'Posts a message to Discord when a feature flag is changed',inputs: {content: {- value: "**{person.name ?? 'PostHog'}** {event.properties.activity} feature flag `{event.properties.item_id}`",+ value: "**{event.properties.user.first_name ? event.properties.user.first_name : 'PostHog'}** {event.properties.activity} feature flag `{event.properties.detail.name}`",},},},@@ -349,7 +349,7 @@ export const HOG_FUNCTION_SUB_TEMPLATES: Record<HogFunctionSubTemplateIdType, Hodescription: 'Posts a message to Microsoft Teams when a feature flag is changed',inputs: {content: {- value: "**{person.name ?? 'PostHog'}** {event.properties.activity} feature flag `{event.properties.item_id}`",+ value: "**{event.properties.user.first_name ? event.properties.user.first_name : 'PostHog'}** {event.properties.activity} feature flag `{event.properties.detail.name}`",},},},@@ -363,7 +363,7 @@ export const HOG_FUNCTION_SUB_TEMPLATES: Record<HogFunctionSubTemplateIdType, Hovalue: [{text: {- text: "*{person.name ?? 'PostHog'}* {event.properties.activity} feature flag `{event.properties.item_id}`",+ text: "*{event.properties.user.first_name ? event.properties.user.first_name : 'PostHog'}* {event.properties.activity} feature flag `{event.properties.detail.name}`",type: 'mrkdwn',},type: 'section',@@ -381,7 +381,7 @@ export const HOG_FUNCTION_SUB_TEMPLATES: Record<HogFunctionSubTemplateIdType, Ho],},text: {- value: "*{person.name ?? 'PostHog'}* {event.properties.activity} feature flag `{event.properties.item_id}`",+ value: "*{event.properties.user.first_name ? event.properties.user.first_name : 'PostHog'}* {event.properties.activity} feature flag `{event.properties.detail.name}`",},},},