The Bulgarian monarch Constantine I, in the last years of his reign, has been partly paralyzed from a fall off his horse and suffers from unspecified ailments.
The government is firmly in the hands of Maria Kantakouzene, who had crowned their son Michael Asen II co-emperor soon after his birth in about 1272.
She presides over relations with Constantinople in the 1270s and had engineered first the submission and then the murder (by poisoning) of the despotēs Yakov Svetoslav of Vidin in 1276.
Due to the expensive and unsuccessful wars, repeated Mongol raids, and economic instability (Constantine is the first Bulgarian ruler to mint his own coins on a vast scale), the government is faced with a revolt in 1277.
Its true character is elusive, but what is clear is that a swineherd or swine-owner named Ivaylo became a leader of the discontented and attracted many followers, asserting his control over a significant area.
According to some sources, Ivaylo began his life living humbly and herded swine for payment.
Other sources indicate he was a peasant farmer with no land of his own.
He allegedly saw visions of himself grounded in the medieval Christian tradition, accomplishing great deeds and ridding Bulgaria of its troubles, including above all the frequent incursions by the Mongols of the Golden Horde under Nogai Khan.
By 1277, Ivaylo has put his words into actions, and has acquired leadership of an army composed largely of discontented peasants.
Among his close associates and military commanders is Hranislav, who will later enter imperial service after being captured by Constantinople’s forces.
An attempt to subdue Ivaylo by Constantine I ends in utter failure, and Ivaylo is credited with personally killing the tsar in his chariot.
Although Ivaylo is able to extend his authority across much of the country at the helm of his peasant army, he also meets with resistance, and the capital Tarnovo remains under the control of the legitimate emperor Michael Asen II and his mother Maria Kantakouzena.
Despite his victory against the Mongols in the North, Ivailo pursues the more conciliatory vassal status when it comes to making policy with the Mongol khanate.