The first Borg attack on Federation space, in which a single cube destroyed a colony, assimilated Captain Picard as Locutus, smashed a fleet at Wolf 359 and reached Earth before being stopped.
The Borg invasion of 2366-2367 is told in the two-part Next Generation story The Best of Both Worlds. It begins when the New Providence colony is found scooped from its planet's surface. Admiral Hanson and the Borg specialist Lieutenant Commander Shelby join the Enterprise-D as a cube enters Federation territory.
The Borg abduct Jean-Luc Picard and turn him into Locutus, a spokesman who carries all his knowledge of Starfleet's defences. With that knowledge the cube destroys thirty-nine starships at Wolf 359 and sets course for Earth.
Riker, now in command, has Picard recovered by Worf and Data. Data links to the collective through Locutus and plants a command that puts the drones into a regeneration cycle, and the cube destroys itself above Earth. The losses shape Starfleet for years, and the Deep Space Nine pilot Emissary shows the battle through the eyes of Benjamin Sisko.