From what I hear, The Glass Key  was Dashiell Hammett’s personal favorite among the books he wrote. That said, it is something of an outlier. In all of the other Hammett stories and novels, the main character is or had been a private detective (the Continental Op in Red Harvest  and The Dain Curse ; Sam Spade in The Maltese Falcon  and Nick Charles in The Thin Man ). Hammett himself had been a Pinkerton detective years before he set his mind to writing.
The main character in this novel, Ned Beaumont, is a fixer for Paul Madvig, a political boss of some midsize city in upstate NY. He is not a private detective — so far as we can tell, Beaumont made and makes most of his money (and loses a lot of it too) gambling.
The novel is also unusual among Hammett’s works in that it alone presents the close relationship of Beaumont and Madvig as one axis on which the story revolves. In the rest of his work, with the exception of The Thin Man, the detective is a man alone, whose loneliness sets him apart from the rest of the world, all balled-up in decay and corruption. This concept of the man alone is something later authors, especially Raymond Chandler, will use to suggest a knight on a quest in a dying world. Hammett, though, does not share Chandler’s romanticism. His heroes, though men apart, have no romantic illusions about the world. They have all learned the lesson of cynicism well.
Inasmuch as we do have a deep friendship between Beaumont and his boss, we have in Beaumont something perhaps nobler than in Hammett’s earlier work. The unnamed operative of the Continental Detective Agency shows some loyalty to “the old man,” his boss, but primarily he’s a guy with a dirty job to do, and he does it. And Sam Spade, in The Maltese Falcon, though feeling some sexual attraction towards his client, Brigid O’Shaughnessy, demonstrates no strong connection to anyone. Beaumont, though, grew up with Paul, knows his family, and tries to do right by him and his family.
The plot of the novel can be quickly summarized. Paul Madvig is a political boss in an unnamed city not far from New York. Ned Beaumont, his lieutenant, comes upon the dead body of Taylor Henry, son of a prominent senator, a politician of the old school, a man of patrician stock, with whom Madvig has chosen to join forces. Madvig hopes to marry the senator’s daughter, while the senator hopes Madvig’s political organization can put him over the top in the next election. To complicate matters, some think that Madvig himself murdered young Henry — Madvig’s daughter, Opal, who was in love with young Henry, among them. And someone has been sending anonymous letters to the DA, to Opal, to Senator Henry, and to the newspapers suggesting Madvig’s involvement and calling for action.
Hammett began his life writing fiction for Black Mask magazine, a pulp magazine focused on gritty tales of urban crime. It was a magazine that literary people were quick to dismiss, but Hammett’s stories (featuring the Continental Op) were different than the run-of-the-mill pulp fiction, and he was said to have taken a disdained form and made it into a literary genre. All subsequent hard-boiled detective fiction takes its cue from Hammett’s lead.
Beaumont is no boy scout. He has no qualms, even as he pursues his investigation into the murder of Taylor Henry, to cast suspicion on a bookie named Bernie, who owes him money. Though he doubts the bookie committed the crime, he figures accusing him of it (even framing him for it) will help him get his money. Outwardly, Beaumont’s chief value is looking out for Ned Beaumont.
Still, Beaumont always tries to do right by Madvig, whom he thinks just might be guilty of the murder. When Madvig, to get in better with the upstanding Senator Henry, cracks down on vice in the city, he falls afoul of Shad O’Rory, who runs a gambling place. O’Rory tries to get at Madvig through Beaumont, first through bribery, and then through coercion by having his dimwitted and psychopathic bodyguard, Jeff, beat Beaumont almost to death (the violence of the beating scene is easily as violent as the violence one might see in today’s detective fiction, but must have been quite shocking in 1930, when the first version of the story appeared in Black Mask). But Beaumont refuses to give his friend up.
The title of the novel comes from a dream Janet Henry describes to Ned Beaumont, in which the two of them are trapped in a cellar full of snakes, and when they try to unlock the cellar door with the glass key they have, it breaks in the lock. The image of people yearning to escape a corrupt world, but ultimately unable to do so is a powerful one, and lends this novel, which has something of a happy resolution, a fatalistic backdrop. For Hammett, the world is a terrible place, and as we are part of the world, we have no escape, nor any way to make a lasting impression for good. It is a difficult and sobering message.
After you’ve read the book, I’d heartily recommend the film version – the 1942 Glass Key with Alan Ladd and Veronica Lake is the most famous and readily available, but there is an earlier version (1935) with George Raft. And this novel has served as the inspiration for Akira Kurosawa’s Yojimbo  (1961), and Sergio Leone’s remake of that film, A Fistful of Dollars  (1964), and for the Coen Brothers’ breakthrough film, Miller’s Crossing  (1990).