李元吉
In summer 626, the Eastern Tujue were making another attack. Li Yuan was initially inclined to send Li Shimin to resist them, but at Li Jiancheng's suggestion sent Li Yuanji instead. Li Yuanji was given command of much of the army previously under Li Shimin's control. This further troubled Li Shimin, who believed that with the army in Li Yuanji's hands he would be unable to resist an attack. Li Shimin had Yuchi secretly summon Fang and Du back to his mansion, then sent an accusation to Li Yuan that Li Jiancheng and Li Yuanji were committing adultery with Li Yuan's concubines. Li Yuan responded by issuing summonses to Li Jiancheng and Li Yuanji for the next morning, convening the senior officials Pei Ji, Xiao Yu, and Chen Shuda to examine Li Shimin's accusations. As Li Jiancheng and Li Yuanji approached the central gate leading to Li Yuan's palace, Xuanwu Gate (玄武門), Li Shimin ambushed them. He personally fired the arrow that killed Li Jiancheng, and Yuchi killed Li Yuanji. Li Shimin's forces entered the palace and, under this intimidation, Li Yuan agreed to make Li Shimin crown prince. Two months later, Li Shimin succeeded to the throne. Li Jiancheng's five sons were all executed.