"Unlike Burma and the Philippines, Indonesia was not granted formal independence by the Japanese in 1943. No Indonesian representative was sent to the Greater East Asia Conference in Tokyo in November 1943. But as the war became more desperate, Japan announced in September 1944 that not only Java but the entire archipelago would become independent.
On August 15, 1945, Japan surrendered. The Indonesian leadership, pressured by radical youth groups (the pemuda), were obliged to move quickly. With the cooperation of individual Japanese navy and army officers (others feared reprisals from the Allies or were not sympathetic to the Indonesian cause), Sukarno and Hatta formally declared the nation's independence on August 17 at the former's residence in Jakarta, raised the red and white national flag, and sang the new nation's national anthem, Indonesia Raya (Greater Indonesia). The following day a new constitution was promulgated. "
And then there were some fighting with brittish and dutch occupational forces until they were formally recognized by those in 1947.
So you seem to be right, atleast partially.
