Franz Josef I was Emperor of Austria/ king of Hungary, when Austria entered WW1. The last emperor was Charles I of Austria (also written Karl I of Austria) who ascended the throne when Franz Josef died in 1916. He abdicated Nov 11 1918 and died in exile.
By the time of the Anschluss in 1938, there had been no emperor for 20 years.
The emperor of Austria was shot in a car. Then russia declared war on them and Germany helped their allied Austria and then France was attacked by Germany too (Why I dont know) And then GB attacked Germany. Then we joined in and beat the crap out of them!
This was called the "Anschluss", thus pretending that Austria voluntarily joined Germany.
Austria was part of Germany for a brief period just before the end of World War One. However, after the war the Treaty of Versailles prohibited the two countries from joining together. The 1930s saw the rise of National Socialism (Nazism) in Germany as well as in Austria. In 1938 Germany annexed Austria, in violation of the Treaty of Versailles, amidst widespread (though controversial) support of the action from both countries.
Austria-Hungary declared war on serbia and Germany joined because it was allied with austria.
Bulgaria
Joined the Allies.
Germany actually did not encourage Austria-Hungary to declare with Serbia since it was not the first country to declare war on another during World War I. Austria-Hungary and Serbia were the first countries to enter World War I, only weeks before Germany joined in to help Austria-Hungary and the other Central Powers.
Germany joined Austria-Hungary and Italy to create the triple alliance.
Ottoman Empire
Italy
Germany and Austria share a frontier. They are both German-speaking countries, of course, and also members of the EU. At the same time, both are independent, sovereign states.
Austria-Hungary. They were subsequently joined by the Ottoman Empire and (in 1915) Bulgaria.