Wiring a flycolor 160a to a bec to the flipsky receiver connector

I had saltwater in my box and the flipsky receiver and the bec are being replaced. I did not do the original build

It is a bec 12s pro. One of the wires to the bec is missing (the input) and I found a random red wire laying connected to nothing this morning and a black ground wire is connected to the bec but not to anything else. I have two brand new connectors that go into the receiver one has 3 wires and one has 4. I think I am using the 4 wire version since my original setup is using a green wire. I am thinking the random red wire is the “in wire” but which wire should it be spliced into?

The input on the bec should connect to the battery red connection and the black ground that isn’t connected to anything should go to the black battery connection?

pictures attached

I am grateful for any guidance as this whole process has been 1 step forward two steps back