"The Purloined Letter" is the last of three stories written about the detective character Dupin. To determine the possible inspiration for this story, we must go back to the first of the three stories, "The Murders in the Rue Morgue." In this story, Dupin makes mention of another detective:
Vidocq, for example, was a good guesser, and the persevering man. But, without educated thought, he erred continually by the very intensity of his investigations. He impaired his vision by holding the object too close. He might see, perhaps, one or two points with unusual clearness, but in so doing he, necessarily, lost sight of the matter as a whole. Thus there is such a thing as being too profound.
Vidocq, whom he considers his rival, was also a real person and a real detective. He is often considered to be Europe's first private detective. Vidocq was still alive when "The Murders in the Rue Morgue" was written. He was known to write about his adventures as a detective in his memoirs. These are the earliest versions of detective literature.
Poe's three stories are considered to be the first detective stories. It seems that Poe was inspired by a real life detective. In turn, Sir Arthur Conan Doyle once admitted that the famous Sherlock Holmes character was inspired by Poe's Dupin.