After the Japanese occupied Indonesia in 1942, Santoso left her work as a teacher and found employment as legal assistant to Soepomo, who later became the country's first minister of justice. In 1945, with the Japanese preparing to withdraw from the Indies and the proclamation of independence looming, Santoso became a member of the Committee for Preparatory Work for Indonesian Independence. On 12 March 1946, Santoso became the first ever female cabinet member when she was selected as services minister in the Second Sjahrir Cabinet. Working quickly and efficiently, she found herself organising the return of internees from Japanese-run camps. She was kept on through the Third Sjahrir Cabinet, but when it dissolved on 26 June 1947, Santoso refused another term as social minister. She instead chose to work as head of prime minister Amir Sjarifuddin's secretariat. She kept this position into the First Hatta Cabinet. During Operation Kraai, a Dutch-led offensive on the city of Yogyakarta on 19 December 1948, her husband was killed outside Maguwo.