Skip to content

feat: expose Markdown fields in webhook payload #14931

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Oct 2, 2024
Merged

feat: expose Markdown fields in webhook payload #14931

merged 4 commits into from
Oct 2, 2024

Conversation

mtojek
Copy link
Member

@mtojek mtojek commented Oct 2, 2024

Fixes: #14930

Integrations with webhook handlers can render Markdown accordingly to their formatting rules. This PR adds the original (with Markdown) body and title fields to payloads.

@mtojek mtojek self-assigned this Oct 2, 2024
@@ -28,17 +28,15 @@ func TestWebhook(t *testing.T) {
t.Parallel()

const (
titleTemplate = "this is the title ({{.Labels.foo}})"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for reviewer:

Dispatch can't render Go templates, it expects already rendered arguments.

@mtojek mtojek marked this pull request as ready for review October 2, 2024 12:38
@mtojek mtojek requested a review from dannykopping October 2, 2024 12:38
Copy link
Contributor

@dannykopping dannykopping left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@mtojek mtojek merged commit 0aa84b1 into main Oct 2, 2024
27 checks passed
@mtojek mtojek deleted the 14930-markdown branch October 2, 2024 13:38
@github-actions github-actions bot locked and limited conversation to collaborators Oct 2, 2024
@matifali
Copy link
Member

matifali commented Oct 2, 2024

@EdwardAngert, we need to take these docs changes into restructure-new

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Notifications: expose markdown text in webhook payload
3 participants