Sometimes a customer wants to create a custom notification report, not only including error messages, but also warning messages.
I checked Bamboo's API (https://docs.atlassian.com/atlassian-bamboo/latest/). There, I searched for the class ExtraBuildResultsData. The only two methods available are:
I also noticed that the only implementation for that interface (BuildResultsImpl) has been deprecated. So let's go to the actual one: BuildResultsSummary. That class handles all information regarding build results. Long story short: I went through the classes being called here. No methods to retrieve warnings.
Have a method like the one above for warnings (getBuildWarnings()).