Photo electric sensor

How do I add or create photo electric sensor to the circuito