Drinking alcohol is haram:
They ask you about wine and gambling. Say, "In them is great sin and [yet, some] benefit for people. But their sin is greater than their benefit." And they ask you what they should spend. Say, "The excess [beyond needs]." Thus Allah makes clear to you the verses [of revelation] that you might give thought. -- Qur'an 2:219
O you who have believed, do not approach prayer while you are intoxicated until you know what you are saying or in a state of janabah, except those passing through [a place of prayer], until you have washed [your whole body]. And if you are ill or on a journey or one of you comes from the place of relieving himself or you have contacted women and find no water, then seek clean earth and wipe over your faces and your hands [with it]. Indeed, Allah is ever Pardoning and Forgiving. -- Qur'an 4:43
O you who have believed, indeed, intoxicants, gambling, [sacrificing on] stone alters [to other than Allah], and divining arrows are but defilement from the work of Satan, so avoid it that you may be successful. -- Qur'an 5:90
I'm not entirely sure about the timeline in which these ayah were revealed, but as I understand, they were revealed to Muhammad, so would not have been accessible to the other prophets and messengers who predate Muhammad. As such, it seems plausible that they drank alcohol. It may be they didn't; they're prophets and messengers after all. (Or maybe they were declared haram in a prior holy book.)
Question: Which of the prophets and messengers are known to have drunk alcohol (if any)?