But it turned out to be enough for the visitors although the home team almost managed to force the game into overtime by cutting the 0-3 deficit to one in the final stretch.
Firmino doubled the hosts' lead by sliding home from close range after being fed by Atletico Madrid left-back Renan Lodi.
Argentina have not beaten Bolivia at the Hernando Siles stadium - located 3,600 meters above sea level - since 2005, when Jose Pekerman's side won 2-1 on the road to the 2006 World Cup in Germany.
The Swiss kept trying to play the ball out from the back, but Spain didn't allow them any time on the ball and Sommer redeemed himself with a good save to parry Ferran Torres' header after a flowing move ended with Jesus Navas putting a good cross into the Swiss area.
The reigning Australian Open champion will contest for her second major title with Polish teenager Iga Swiatek, who needed only 70 minutes to storm to a 6-2, 6-1 victory over Argentine qualifier Nadia Podoroska.
Dybala missed the team's 1-0 win over Ecuador on Thursday but was expected to be fit in time for the clash at Hernando Siles stadium in La Paz on Tuesday.
Ji revealed that prior to Friday's game, she didn't prepare anything from a tactical aspect, but just told players to go fighting.
Gracia had been close to resigning from the club he only joined in the summer due to his frustration over the club's work in this summer's transfer window, which saw key first team regulars such as Ferran Torres, Dani Parejo, Ezequiel Garay, Francis Coqueilin, Rodrigo Moreno and Cristiano Piccini all leave with nobody signed to replace them.
Li Yueru shot 13 of 17 from the field to contribute 27 points and 20 rebounds for the winner. Shanxi was unable to contain Li Yueru's glittering play, thus seeing little hope of a comeback in the second half.
However, the 50-year-old was told that if he left the club of his own accord, he would have to pay three million euros in compensation. Gracia had a two-hour meeting with Murthy but was unable to speak to the club's owner.
In a video message released by the Tokyo 2020 organizing committee, Bach told Chef de Missions of all national Olympic committees, "I am sure the question today in your mind is: will the athletes make their Olympic dream come true in 10 months from now? In this regard, I can reassure you that we are working at full speed with our Japanese partners and friends to ensure safe Olympic Games that are fit for the post-corona world."