The short version, then the thing that catches people out.
rtmp://a.rtmp.youtube.com/live2
YouTube gives you two kinds of key. A key from a scheduled broadcast works once, for that broadcast. The one on the Stream tab is reusable, which is what a 24/7 channel needs. If your stream worked yesterday and refuses to connect today, you almost certainly copied the single-use one.
With Beamd you can skip all of this: connect your YouTube account and it reads the reusable key straight from the API, so there is nothing to copy and nothing to keep track of.
Your key is stored encrypted and is never shown back to you, on screen or in email.
Stream 24/7 with your computer off