Herbert O. Yardley, the author of The American Black Chamber (1931), also wrote several novels. I recently read one of them, Red Sun of Nippon (1934) (HathiTrust).
The following may include a spoiler.
The story is set in contemporary Washington, D.C. Japan had started its aggression in China in the Mukden Incident in 1931. Japanese invasion of Manchuria led to diplomatic isolation of Japan, but as of the publication of the novel (1934), nobody yet knew that the United States would be in an all-out war with Japan. The story develops around an important document which would be evidence of the Japanese intention of establishing a buffer state in Manchuria.
When Bruce Caldwell, a young diplomat, was with his half-Chinese, half-white girlfriend, Cherry Garden, he was robbed of a political memorandum. Cherry was under the tutelage of her Japanese guardian, Dr. Tonomutu, and without her knowledge, she was used as a decoy.
When the Russians, seeking recognition of the Soviet government by the U.S., offered to hand over an important document, it was Cherry who secured it before Bruce. After a quarrel with Bruce, it seemed she had no qualms in acting for the Japanese. The document was evidence of the Japanese intention in Manchuria. The Japanese were expected to return it home rather than destroying it. It had to be intercepted somehow.
As expected from Yardley, codebreaking plays a role here.
In order to find out how the document was to be sent back, Bruce obtained the Japanese embassy's telegrams from the telegraph company, but the Japanese diplomatic code was not easy to break, even with the help of Nathaniel Greenleaf, an ex-employee of the State Department, skilled in codebreaking.
A social technique came into play. Bruce asked the Japanese embassy to enquire the home ministry, as if it were part of information exchange on routine matters, about whether a Russian official who visited them was real. The embassy secretary turned out to be so obliging that he even provided the decoding of the reply from the home ministry. Thus, Greenleaf could use matching plaintext-ciphertext pairs, which allowed him to reconstruct the code, though it was not before he realized the plaintext was English rather than Japanese. (Of course, Yardley couldn't have known the Japanese diplomatic telegrams had adopted machine cipher, RED.)
Among the decoded telegrams, one indicated that the document would be sent to Japan in a diplomatic pouch.
The diplomatic bag was secretly intercepted before being sent to the west coast for embarkation to Japan and the diplomatic seal was broken (before which they made sure to duplicate the seal). But nothing was found.
Then, Goldleaf realized that his decryption "by the pouch" should be actually "by the Prince." The document was to be conveyed to Japan personally by a Japanese prince, who was unofficially staying in the U.S. on his way home from Europe.
(Notes on history: This setting may be inspired by Prince Takamatsu, Emperor Hirohito's brother, who went on a tour of Europe and the United States in 1930-1931. Manchukuo, a puppet state of Japan, was established in March 1932. References to the president-elect (p.185, p.238) indicate the scene was after the presidential election in November 1932. It seems Yardley somewhat changed the timeline. It would be in 1933 that the United States recognized the Soviet government.)
Bruce went to the farewell party of the Prince, during which unexpectedly, Prudence, his sister, succeeded in obtaining the document by picking the pocket of the Prince.
They had thought there was some chance that the document might be useful to check Japanese aggression. The Japanese intention revealed in the document, however, was worse than they expected and might involve the U.S. in a war by mischief of the warlike Under Secretary or just mishandling. Bruce and Greenleaf endeavour to prevent a war with Japan ----
After everything was done, the reaction of the President and the Secretary of State was something that might remind one of Yardley's own dismssal in 1929. The parallel is clearer in the codebreaker Greenleaf's previous carrier: after saving the country from a war, he had had to leave the State Department with words "gentlemen don't use such methods" and his force was dismissed overnight (p.47).
Cherry Garden, a school girl, half-Chinese, half-white
Dr. Tonomutu, Cherry's Japanese guardian,
Prudence Caldwell, Cherry's schoolmate
Bruce Caldwell, a diplomat in the State Department, age 28, Prudence's brother
Willow, Cherry's mother from Manchu
Stuyvesant Kipp, Under Secretary of State, Bruce's superior
Blane, Bruce's chief operative
Nathaniel Greenleaf, ex-employee, who left the State Department under 30
Orlof, accredited Soviet envoy
Koko, Secretary of the Japanese embassy
Bill Bailey, a journalist
Mr. Min, a Chinese student, a son of a merchant in Hong Kong
Hildebrand Hotchkiss, Chief of the Far Eastern Division in the State Department
the Prince, a Japanese prince unofficially staying in the U.S. on his way back from Europe
Clayton, a man from the Dead Letter Office
Jimson, Secretary of State
McCready, President