I have built motor RPM sensor from Melexis MLX90217 chip and door magnet. The Melexis chip was ordered from DigiKey a while ago and cylindrical magnet has taken from door magnet and reed switch pair which is used in house alarm systems.
I made an enclosure of the sensor from 30x30x2 square steel tube of approx 60mm length. I welded on the 2 mm sheet cover on one end and two holder arms with holes on other end. Then made a 14mm hole on one side and welded in a piece of steel tube. Then I glued in the magnet with MLX sensor on its end directed to the inside of the box with three short wires running out to the outside. These wires are connected to shielded microphone cable which is running from the sensor to control box. I've painted the sensor with hammered black Hammerite, let it dry for a day and attached to motor on accessory axis side. Here are couple of photos of finished sensor. Sorry - didn't have time to capture whole manufacturing process.
The sensor serves second purpose too - it covers the shaft from dirt and moisture to prevent its corrosion.