Microswitches are useful for detecting passage of a moving part or for implementing an electronic limit stop. Set up the switch so that your mechanism wipes the lever and closes the switch as it moves by.
Here are pictures of typical microswitches.
Most microswitches have three terminals labelled C, NO, and NC, standing for Common, Normally Open, and Normally Closed, as shown below.
For regular switch action, connect to the C and NO terminals. The switch will be open when not pressed and closed when pressed.
Interface your microswitch to the Arduino in the usual manner as shown here.
In ME2011 lecture, Durfee has a demo showing a motor driven wheel that stops precisely at a pre-determined position because of a microswitch. The code for the demo is listed here.
Robot store, or Ax-man, or Radio Shack 275-017 (SPDT, 5A contacts, lever arm with roller, $1.99), or many other sources.