JAKARTA -- Indonesia's election commission has confirmed President Joko "Jokowi" Widodo took more votes than his opponent, former general Prabowo Subianto, in April's presidential election, opening the way for the incumbent to lead the country for the next five years.

Widodo's camp took 55.5% of votes cast, beating Prabowo for the second presidential race in a row, the General Elections Commission, or KPU, said early Tuesday. Prabowo's share came to 44.5%, according to the official results.

The announcement confirms the results of quick counts that showed Widodo securing around 55% of the vote.

The Subianto camp now has three days to challenge the official count in the constitutional court. His team has claimed the election was riddled with irregularities such as modified tallies, invalid voter lists and the burning of ballot papers by Widodo supporters.

Should he lodge a complaint, the court will be forced to look into evidence provided by the opposition and come up with a verdict before a late June deadline. He also contested the results of the July 2014 election, and it took the court another month to formally reject the claims.

Barring such an appeal, Widodo and his vice presidential pick, the influential Muslim cleric Ma'ruf Amin, will officially be confirmed the winner on Friday.

The constitutional court has the power to overrule the result and order a partial or full rerun of the election as needed. Regardless of its decision, the world's third-largest democracy will welcome its new president in October.

The Prabowo camp said in a statement last week that it will "reject the result of the KPU count of the votes" as there had been "countless acts of fraud in the election." But senior figures in the opposition have also said they will not dispute the results in the court as they view the process as a "waste of time," local media have reported.

Subianto and his supporters may take other steps such as taking to the streets to protest the official count. Security was stepped up around the election agency ahead of the announcement.

While the former general has been careful not to incite violence as that may land him in hot water, he has repeatedly called for "People Power" to protest against the interim vote count. Analysts warn this could lead to civil unrest similar to that in 1998, which led to the fall of dictator Suharto's autocratic regime, and a tense political standoff that lasts weeks.

Some opposition politicians have urged supporters to take steps such as not paying taxes in protest at the Jokowi administration.

Meanwhile, Indonesia's security apparatus continues to be on high alert after receiving intelligence of possible terrorist attacks in Jakarta during and after the release of the official counts.

As of Friday, national police had detained 29 people suspected of plotting strikes in May alone. All them were associated with Jamaah Ansharut Daulah, or JAD, the largest Indonesian pro-Islamic State cell.

"We call on the people not to go to the street in massive numbers because these groups are unpredictable," Muhammad Iqbal, spokesperson for the national police, said on Friday. "They are targeting the democracy event where large numbers of people gather. There should be no mass gathering... because it will be very prone to bomb and other kind of attacks."