The first electronic device
The first electronic device ever invented is the relay, a remote switch controlled by electricity that was invented in 1835 by Joseph Henry, an American scientist, although it is also claimed that the English inventor Edward Davy "certainly invented the electric relay" in his electric telegraph c.1835.
It made modern telegraphy possible and evolved into the repeater- thus the relay- a remote controlled switch, was in effect the first ( Electronic) device, though not anything involving crystals, diodes, vacuum tubes etc.
The first invented Relay was used as part of his telegraph system circa 1844. It was used in long distance telegraph circuits, repeating the signal coming in from one circuit and re-transmitting it to another.
Since then, relays found extensive use in telephone exchanges and early computers to perform logical operations.
References and useful resources: