anticipated absence, he did not actually intend to depart for the capital Chang'an, so he delayed his departure several times, despite urgings by the imperial eunuch and Wang for him to depart. Li Qi instead submitted a petition claiming illness and asking to delay the journey to 808. When Emperor Xianzong requested the chancellors' comments, Wu Yuanheng pointed out that Emperor Xianzong needed to assert imperial authority — and that Li Qi's offer to pay homage to him and then refusal to do so was a challenge to imperial authority. Emperor Xianzong agreed, and issued an edict summoning Li Qi to Chang'an. Li Qi, unable to think of anything else, decided to rebel. Meanwhile, Li Qi was also angered by how Wang, after being made acting military governor, was making decisions that changed his policies, and thus incited the soldiers to kill Wang. On a day when Wang and the imperial eunuch were meeting him, he had some several soldiers proclaim, "Who is this Wang Dan who dares to give orders?" The soldiers rushed into the headquarters and killed Wang, eating his body. When the officer Zhao Qi () tried to comfort and stop the soldiers, the soldiers also killed Zhao and ate his body. When the soldiers dragged the imperial eunuch out, Li Qi pretended to be surprised and personally went to rescue the eunuch. Meanwhile, on November 8, 807, Emperor Xianzong, issued an edict recalling Li Qi to serve as Zuo Pushe (), one of the heads of the executive bureaus of government (尚書省, Shangshu Sheng) and naming the official Li Yuansu () as his replacement as military governor of Zhenghai. The next day, Li Qi submitted a report claiming that a mutiny had led to Wang's and Zhao's deaths, apparently seeking to be allowed to remain. Meanwhile, though, he also secretly ordered five military officers that he had stationed at five prefectures under his jurisdiction — Su, Chang, Hu, Hang, and Mu (睦州, in modern Hangzhou) — to kill the prefects and seize control, and further ordered his officer Yu Boliang () to prepare Shitou in anticipation of an imperial attack. However, Yan Fang () the prefect of Chang Prefecture had already heard of this and killed the officer Li Qi sent to monitor him, Li Shen (). Yan sent communiques to the other four prefectures ordering the other four prefects to attack the rebels, and those