The chairman of Kenya's election commission declared Deputy President William Ruto president-elect on Monday after a closely fought contest against opposition leader Raila Odinga.
Odinga has said he would mount a legal challenge to the outcome, calling the results "null and void." He has been down this road before, having petitioned the court twice, in 2013 and 2017, when the presidential election was overturned.
Here is the legal procedure for resolving election disputes:
HOW DOES KENYA RESOLVE PRESIDENTIAL ELECTIONS DISPUTES?
In 2010, a new constitution was approved outlining the procedures to be followed for settling election disputes. It followed a disputed election in December 2007, when more than 1,200 people were killed in the East African country.
The violence was partially blamed on the losing candidate's lack of trust in the courts at the time.
The new constitution established a seven-member Supreme Court, whose duties include resolving presidential election disputes.
WHAT IS THE TIMELINE OF PRESIDENTIAL ELECTION PETITIONS?
Petitioners must submit their complaint to the Supreme Court within seven days of the results being declared.
The court next conducts a status conference with all parties to define the hearing schedule and ground rules.
The constitution requires the nation's highest court to issue its decision within 14 days of the lawsuit being filed.
Due to the tight schedule, it normally issues a summary judgment within 14 days, followed by more thorough decisions from each of the seven judges at a later date.
HOW IS THE COURT LIKELY TO RULE?
When confronted with a presidential election petition, the court has three alternatives.
If it finds sufficient grounds to call the legality of the result into question it can invalidate the election result and order a new election within 60 days; or it can criticize the process but conclude that there were insufficient grounds to overturn the result; and finally, it can uphold the election if it finds it was held in accordance with the constitution.
To reach a decision, the court may require a review of the ballots, including a recount.
WHAT HAPPENED IN THE LAST ELECTION?
The court invalidated President Uhuru Kenyatta's original re-election in August 2017, finding irregularities, particularly in the transmission of polling station results.
The court also took issue with the disparity in the number of votes cast for president and other down-ballot elections, such as for members of parliament, in a majority verdict.
Three of the justices who nullified the election remain on the court, while the chief justice retired last year. Martha Koome, the first Kenyan female chief justice, took his post.
One of the dissenting judges is still on the bench, while the other retired and was replaced.
After the repeat presidential election in October of that year, a second challenge was filed, but the court dismissed it and affirmed the results, resulting in Kenyatta's inauguration for a final five-year term.
(Reporting by Duncan Miriri; Editing by James Macharia Chege and Alex Richardson)