Businessmen counting bundles of banknotes on video, ministers describing systematic looting — over the past three years, South Africans have been alternatively gripped and outraged by an inquiry into the country’s biggest post-apartheid scandal.

But as the commission into the so-called “capture” of the state under former president Jacob Zuma enters its final weeks, the biggest drama lies ahead — the country’s highest court has been asked to jail Zuma for his refusal to show up. It will be a moment of truth not just for the inquiry and Zuma but also for the rule of law in South Africa’s young democracy.

“If it is allowed to prevail, there would be lawlessness and chaos in the courts,” said Raymond Zondo, the South African deputy chief justice, after the former president again defied a summons last week to answer for his alleged role.

“The state capture commission of inquiry is so important because it goes to the heart of the legacy, or survival, of the constitutional project,” said Nicole Fritz, chief executive of Freedom Under Law, a legal NGO. “It is potentially a constitutional crisis if action isn’t taken against [Zuma] . . . you’re asking the average South African to adhere to and respect this law,” she added.

Zuma, who was unseated by Cyril Ramaphosa three years ago, set up the inquiry on the orders of a government ombudsman who in 2016 compiled evidence that Zuma had manipulated ministerial appointments and contracts to favour the business empire of the Indian-born Gupta family. The Guptas have always denied wrongdoing.

The inquiry, which will wrap up in a few weeks and make formal recommendations by the middle of the year, has fleshed out this state capture, said Lawson Naidoo, executive secretary of the Council for the Advancement of the South African Constitution, a legal watchdog.

Around 40 of more than 250 witnesses at the inquiry have directly implicated Zuma in systematic corruption, including one of his own former ministers, who alleged that he “auctioned” off executive authority to the Guptas. Zuma has always denied corruption and says none of the witnesses have implicated him in any wrongdoing.

Last year, the inquiry, which has cost about R800m ($55m) to date, secured tens of millions of dollars in fees repaid to the South African state by McKinsey, the consultancy firm. While the inquiry has already filed criminal charges over the former president’s defiance, it has also been criticised by the constitutional court for its delay in only resorting to “compulsion by summons when it was too late in the day”.

Zuma did volunteer to appear for one brief stint before the inquiry in 2019 to claim that his accusers were in the pockets of foreign governments. He returned, but only to stage a walkout. “It is not our law that I defy, but a few lawless judges who have left their constitutional post for political expediency,” Zuma said this month after the commission decided to seek his imprisonment. “I protest against our black, red and green robes, dressing up some individuals that have long betrayed the constitution and their oath of office.”

Analysts have said that these attacks on judges seem aimed at pre-empting future court cases. Zuma is already facing trial this year on charges of corruption relating to a 1990s arms deal. There could be grist for many more such cases arising from the inquiry.

The inquiry will not need Zuma’s testimony to finish its work — and his failure to take the opportunity to give his side of the story will weaken any attempt by him to challenge the inquiry’s findings in court, Naidoo said.

More defining may be the inquiry’s picture of the ANC — a portrait of a party that has governed South Africa for almost three decades but has become riddled with patronage and middlemen who rise to be “overnight billionaires” with access to state favours, said Khaya Sithole, an independent analyst. With the inquiry’s ability to delve into bank accounts and trace illicit financial flows, “the great discovery for all of us has been how pervasive the reach of the ANC’s tentacles are in all parts of the state”, he added.

Ramaphosa, who was Zuma’s deputy for four years, is expected to give a mea culpa at the head of an ANC delegation to the inquiry in the next few weeks, before it finishes hearings. But he is also struggling to win an internal party battle to make officials step aside while they are being prosecuted for alleged graft. They include Ace Magashule, the ANC secretary-general who is Zuma’s most powerful remaining ally. For many officials, tension exists between loyalty to the former liberation movement and duty to South Africa’s constitution, Sithole said.

“I think [the ANC] are shattered, nervous, divided, and will become more so as the commission reaches its last mile,” said Ferial Haffajee, a journalist who has been covering the state capture inquiry since it began in 2018.

Whether or not the inquiry’s recommendations are acted on, the relentless exposure of corruption makes it a success of sorts. “It has been a national theatre of exposure, and what the democrat in me hopes is a cautionary tale,” said Haffajee.