Han Sui
In 209, Han Sui sent him as an emissary to meet the warlord Cao Cao, who controlled the Han central government and the figurehead Emperor Xian. Cao Cao treated Yan Xing well and appointed him as the Administrator () of Jianwei Commandery (犍為郡; around present-day Meishan, Sichuan). Yan Xing received permission to bring his family to the imperial capital, Xu (許; present-day Xuchang, Henan), after which he returned to Han Sui. He advised Han Sui to become a vassal under Cao Cao and send one of his sons to Xu as a "hostage", so as to express his loyalty to the central government. Although Han Sui was initially reluctant to do so, he eventually agreed and sent his family to Xu as hostages.