According to the Reichsverfassung from 1871 the legislative was the "Reichstag", assembled by elections and the "Bundesrat", the assembly of the nobles (similar to the British "House of Lords"). The King of Prussia was the Kaiser. The Kaiser had the right and the duty on demand of the Reichstag to declare war and peace and to be responsible for matters of international relations and law.
When in 1918 the high command proposed peace negotiations based on Wilson's 14 points the latter demanded that the Kaiser would abdict. Wilhelm II, who was in Ypern at the time being, on request of the Reichswehr high command didn't return to Berlin but went into exile in the Netherlands. On January 8, 1919 he abdicted. The Reichstag's candidate Ebert on the 10th of November 1918 declared the Kaiser to be removed from office, assigned another Chancellor and convinced the Crown-Prince of Baden to overtake the foreign relations, who on the 11.11.1918 signed the armistice treaty. Ebert then developped another constiuton which led to the Weimar Republic.
The problem: In no way Ebert, as a simple deputy had any right or the authority to remove the Kaiser, dissolve the legislative organ "Reichstag" and to declare any new republic. When the peace treaty was signed,Wilhelm II.even officially still was Kaiser. That signature by national and international law therefore is invalid, it has the same value as I would have signed it.
If the Reich signed a valid peace treaty or not: it didn't cease to exist. Politically the old Reich was a representative monarchy, not a totalitarian system. There was neither a democratic vote nor any assembly dissolving it. The Weimar Republic therefore was based on a disputable legacy, it was simply unconstitutional but existed in the absence of a higher authority to remove it from power. The second mistake of Weimar was to replace the "Kaiser" by the Reichspresident. The balance of powers, in the old Reich between chancellor and Kaiser, was replaced by the separation of Reich's President and Reich's Chancellor, without prohibiting that one person would have both assignments, leading to total power. That was misused by Hitler. In the old system it would have been impossible for him to get there, because first he had to become the King of Prussia. The return to the old name of "Reich" showed that he was aware of the illegal state of his Reich. However that didn't resolve the basic problem. The 3. Reich was the illegal prologation of the illegal Repblic of Weimar.
In summary in 1945 another non-constitutional system was removed and an illegal state of constitution, existing since 1919 was ended. When the allied occupation, also suspending German souvereignity, ended, the old Reich from 1871 came into existence again and presently is supressed by another unconstitutional temporary government.
That is why still the "Grundgesetz", an allied occupation law, replaces a German constitution although itself demands to be replaced by one, as soon as the German people are reunified and free to decide. However: that is not necessary, there is a valid existing constitution since 1871 which first officially and lawfully has to be abandonned, then another one can replace it. Might sound ridiculous, but if I would be another state or organisation having contracts or treaties with the present so-called government, I would hire some advocates of international law to investigate their validity.