What connector did this IBM Model M keyboard have?
Here is the pinout you need:


+5 V - black 
data - red 
clock - yellow 
ground - white 
ground/shield - silver


That black as +5 V is not what you would call industry standard and if you salvage a PS/2 (mini-DIN) or DIN cable elsewhere, be sure to match the pinout and not the colors.

Here is a pinout for both DIN and mini-DIN


Ready-made cables for the very purpose are sold online too:


(Side note: I wrote in a comment above that it existed with both mini-DIN and DIN. This may have not been 100 % accurate. My old PS/1 (or was ut just called personal system?) came with bucking coil keyboard and PS/2 connector which was very similar but more compact than an actual and original model M.)