The Dark Hills Divide by Patrick Carman
During an annual visit to Bridewell with her father, Alexa Daley witnesses the death of the town leader, Thomas Warvold. Thrown into a mystery about Warvold’s life work—the walls enclosing their cities—Alexa searches for clues left behind that might lead to her own life’s work and maybe to the world beyond.
It made sense that he would be the keeper of a hidden key. He was the keeper of so much of our history and so many of our deepest secrets.