To get to the Afro Summer Jam, SBB and ZVV recommend taking the S-Bahn or streetcar no. 7 via Wollishofen station. The S2 also stops at Wollishofen during the festival.
Extra trains from Wollishofen station to Zurich main station are available for the return journey in the evening. You can find your best connections in the ZVV or SBB app.