German-Japanese Pact : Nazi Germany
In November, 1936, Germany and Japan had signed an Anti-Comintern Pact that declared the hostility of the two countries to international communism. In case of an unprovoked attack by the Soviet Union against Germany or Japan, the two nations agreed to consult on what measures to take "to safeguard their common interests". It also agreed that neither nation would make any political treaties with the Soviet Union.
Adolf Hitler broke the terms of the pact when he signed the Nazi-Soviet Pact in August, 1939. He did this because he was attempting to avoid a war on two-fronts. By 1940 Hitler once again began to consider invading the Soviet Union and the German foreign minister, Joachim von Ribbentrop, was sent to negotiate a new treaty with Japan.
On 25th September, 1940, Ribbentrop sent a telegram to Vyacheslav Molotov, the Soviet foreign minister, informing him that Germany, Italy and Japan were about to sign a military alliance. Ribbentrop pointed out that the alliance was to be directed towards the United States and not the Soviet Union. "Its exclusive purpose is to bring the elements pressing for America's entry into the war to their senses by conclusively demonstrating to them if they enter the present struggle they will automatically have to deal with the three great powers as adversaries."
Molotov already knew about the proposed German-Japanese Pact. Richard Sorge, a German journalist working in Tokyo, was a Soviet spy and had already told Molotov that Adolf Hitler was involved in negotiations with Japan. In Sorge's view, the pact was directed against the Soviet Union but it was not until December, 1940, that he was able to send Molotov full details of Operation Barbarossa.
Primary Sources
(1) Joachim von Ribbentrop sent this telegram to Vyacheslav Molotov about the proposed German-Japanese Pact on 25th September, 1940.
This alliance is directed exclusively against American warmongers. To be sure that is, as usual, not expressly stated in the treaty, but can be unmistakably inferred from its terms. Its exclusive purpose is to bring the elements pressing for America's entry into the war to their senses by conclusively demonstrating to them if they enter the present struggle they will automatically have to deal with the three great powers as adversaries.