The Mechanical Eye is a consumable item that summons the boss The Twins anywhere in both pre-hard mode and Hard mode worlds, but must be used at Night. As of 1.2, this item has a small chance of dropping from any enemy entity in Hard Mode worlds.
The Twins are sometimes known to not appear after being summoned. (This is a very common bug on Multiplayer servers, but this could also be caused by an anti-boss spawning system used on a lot of servers)
If one attempts to use the Mechanical Eye (or the other mechanical summoning items) at dusk, the item will not be used (which is supposed to happen) but when that night begins the respective boss will spawn naturally. This is a way to summon the hard mode bosses without using the item.
Sometimes only one eye will spawn.
If summoned from high altitudes, The Twins may not appear.