Edgar Allan Poe was the undisputed "Father" of the Detective Story. He created so much that is of importance in the field -- literally creating the template for all of detective fiction to follow. (Years later, Sir Arthur Conan Doyle was to say that Poe "was a model for all time.")
In just three stories, Poe created the amateur detective and his narrator friend, the locked-room mystery, the talented but eccentric amateur sleuth outwitting the official police force, what Haycraft calls the "catalogue of minutia," interviews with witnesses, the first fictional case of an animal committing a perceived murder, the first armchair detective, the first fictional case which claimed to solve a real murder mystery previously unsolved by police, the concept of hiding something in plain sight so that it is overlooked by everyone who is searching for it (except for the detective, of course), scattering of false clues by the criminal, accusing someone unjustly, the concept of "ratiocination" (later called "observation and deduction" by Sherlock Holmes and others!), solution and explanation by the detective, and more. Other stories by Poe introduced cryptic ciphers, surveillance, the least-likely person theme (in one case, the narrator of the story is the murderer!), and other ingredients that have spiced up many a recipe for a crime story.
Poe also began the tradition so fondly embraced by connoisseurs of crime fiction -- what became known as "The Rules of the Game," which state, among other things:
(1) The detective story must play fair.
(2) The detective story must be readable.
The Detective Story, per se, was invented in the three stories which feature "the Chevalier C. Auguste Dupin." These are:
Other Poe stories, although embracing crime and/or mystery, are not true detective stories because they don't introduce all the clues (and so fail to meet the criterion of "playing fair" with the reader) until after the dénouement. Nevertheless, they introduced elements which have become standard in detective and crime fiction. These stories include:
Poe's stories are available in his Tales.