Open kimdwkimdw opened 2 years ago
Can this also be exposed to Jenkins Scripting Pipeline?
EDIT: After reading the changelog of PR #92, I realized that there probably is an undocumented way. You can probably use like so:
discordSend([
webhookURL: 'Your URL',
fields: ["Key1:Value1", "Key2:Value2"]
])
Later this week I'll try and come back with my results.
EDIT: There is! I managed to get it working. All private fields of DiscordPipelineStep.java
can be used as fields. And looking at the code, I realized that you just need to do the following:
discordSend([
webhookURL: 'Your URL',
fields: "Key1:Value1, Key2:Value2, Key 3:Value 3a; Value 3b"
])
To get it looking like:
Key1 Value1
Key2 Value2
Key3 Value3a; Value 3b
Sadly, there's no way to make them inline. At least not with how this was set up.
What feature do you want to see added?
Add additional
fields
arguments. Check belowhttps://birdie0.github.io/discord-webhooks-guide/structure/embed/fields.html https://leovoel.github.io/embed-visualizer/
Upstream changes
No response