Zhang Renyuan (張仁愿) (died 714), né Zhang Rendan (張仁亶), formally the Duke of Han (韓公), was an official and general of the Chinese dynasty Tang Dynasty and Wu Zetian's Zhou Dynasty, serving as a chancellor during the reigns of Wu Zetian's sons Emperor Zhongzong and Emperor Ruizong and grandson Emperor Shang.
It is not known when Zhang Renyuan, whose name was initially Zhang Rendan, was born. It is known that his family was from Hua Prefecture (華州, roughly modern Weinan, Shaanxi) and that his grandfather Zhang Deyan (張德言) was a prefectural prefect during early Tang Dynasty, but nothing is known about his father Zhang Rong (張榮) beside the name.
During Wu Zetian's reign
It was said that Zhang Rendan was talented in both civil and military matters when he was young, and early in Wu Zetian's Zhou Dynasty, he was made Dianzhong Shi Yushi (殿中侍御史), a low-level imperial censor. Around this time, there was another censor, Guo Ba (郭霸), who submitted a report to Wu Zetian claiming that she was the incarnation of Maitreya Buddha, and there was another official, Zhang Jiafu, who instigated the civilian Wang Qingzhi (王慶之) into submitting a petition asking that Wu Zetian make her nephew Wu Chengsi the Prince of Wei crown prince, instead of her son Li Dan, formerly emperor until he yielded the throne to her in 690. Zhang Rendan was asked to cosign both documents and refused to do so, and he became known for this.
In 696, when Wu Zetian commissioned the chancellor Wang Xiaojie to attack Tufan, Zhang Rendan was made the auditor for the campaign. Zhang submitted a report on the failures of the campaign, and as a result Wang was removed from his office. Zhang was thereafter promoted in his censor rank to Shi Yushi (侍御史).
In 697, another censor, Sun Chengjing (孫承景) served as an auditor of the border defense forces during a campaign, and after he returned from the campaign, he submitted a number of drawings showing him fighting and prevailing in battle. Wu Zetian was initially amazed, stating, "How can a censor be this faithful?" and promoted him to be deputy chief censor in charge of reviewing central government affairs. She asked Zhang to review the rolls of Sun's subordinates to see who should be rewarded. Zhang interviewed Sun and asked him to describe the battles—and Sun could not, because, in reality, he did not fight in the battles. Zhang submitted an indictment accusing Sun of fraud. Sun was demoted to be a county magistrate, and Zhang was promoted in his stead, and sometime thereafter was made acting commandant at You Prefecture (幽州, roughly modern Beijing). When Eastern Tujue's khan Ashina Mochuo subsequently invaded and, after capturing Zhao (趙州, roughly modern Shijiazhuang, Hebei) and Ding (roughly modern Baoding, Hebei) Prefectures but then withdrew through You Prefecture, Zhang tried to intercept him, and in the battle suffered an arrow wound to the hand. Wu Zetian sent messengers to praise him and physicians to treat him. He was subsequently made the secretary general at Bing Prefecture (并州, roughly modern Taiyuan, Shanxi).
During Emperor Zhongzong's second reign
In 705, Wu Zetian was overthrown in a coup, and her son and crown prince Li Xian (Li Dan's older brother, also former emperor, who had replaced him as crown prince in 698) was restored (as Emperor Zhongzong). In 706, when Emperor Zhongzong was returning from Luoyang, which Wu Zetian had made capital, to the old Tang capital Chang'an, he made Zhang Rendan one of the commanding generals of the imperial guards and the acting secretary general of Luo Prefecture (洛州, i.e., Luoyang), in charge of Luoyang. At that time, grain was expensive at Luoyang, and there were many grain thieves. Zhang captured them and caned them to death, and after the bodies stacked up, no one dared to steal grain any more.
In 707, after another Eastern Tujue incursion that saw the Tang general Shazha Zhongyi (沙吒忠義) defeated by Ashina Mochuo, Emperor Zhongzong commissioned Zhang to replace Shazha as the general in charge of the Shuofang region (i.e., northern Shanxi and northern Shaanxi). When he arrived at the army camp, Eastern Tujue forces were withdrawing, and he made a surprise attack against them, inflicting much losses.
In 708, while Ashina Mochuo was busy fighting with Tuqishi (突騎施) forces in the Western Regions (Xiyu), Zhang wanted to take advantage of Ashina Mochuo's absence to cross the Yellow River in the bend region (in modern western central Inner Mongolia), which had served as the de facto border of Tang and Eastern Tujue, and he submitted a proposal to build three forts north of the river to cut off the route that Eastern Tujue usually took in invading Tang territory. (Under the proposal, the eastern fort would be built in modern Hohhot; the central fort would be built in modern Baotou; and the western fort would be built in modern Bayan Nur.) The chancellor Tang Xiujing, himself a successful general, opposed, believing that the forts would be difficult to defend and would eventually fall into Eastern Tujue hands, but after repeated requests by Zhang, Emperor Zhongzong approved. The forts were completed in 60 days, and Zhang further built scout stations north of Mount Niutouchaona (牛頭朝那山, in modern Baotou). Apparently also at his suggestion, the ethnically Tufan general Lun Gongren (論弓仁) was made the forward commander of an army that patrolled the Nuozhen River (諾真水, flowing through modern Baotou). It was said that thereafter, Eastern Tujue forces did not dare to cross the Yin Mountains, and the northern prefectures of the empire no longer needed to worry about Eastern Tujue attacks, allowing defense forces to be decreased in size.
The three forts built by Zhang had gates that did not have a secondary gate inside the primary gate, and also did not have defensive bulwarks. When he was asked the reason, he stated:
Military action calls for acting conduct, not defense. If enemies emerged, the soldiers need to fight hard, and those who even dared to look back at the walls should be beheaded. Why should there be defensive bulwarks to allow soldiers to have fearful hearts?
It was only later when another general, Chang Yuankai (常元楷), replaced him that the secondary gates were built, and it was said that the people at the time, as a result, respected Zhang and disrespected Chang. It was also said that while he was commanding the forces in Shuofang, he had retained on his staff such officials as Zhang Jingzhong (張敬中), He Luan (何鸞), Kou Ci (寇泚), Wang Yicong (王易從), Liu Tiwei (劉體微), Liu Yanzhao (柳彥昭), and Chao Liangzhen (晁良貞). These officials were capable, and later became important officials in the administration, leading to people praising Zhang Rendan for his ability to select officials.
Later in 708, Zhang was given the designation Tong Zhongshu Menxia Sanpin (同中書門下三品), making him a chancellor de facto. He was also created the Duke of Han. Under this arrangement, he would return to Chang'an in the spring to serve as chancellor, and in the fall he would again go to Shuofang to defend the border. On an occasion when he departed, Emperor Zhongzong personally wrote a poem to send him off and awarded him with much treasure.
During Emperor Shang's reign, Emperor Ruizong's second reign, and Emperor Xuanzong's reign
In 710, Emperor Zhongzong died suddenly—a death that traditional historians believed to be poisoning carried out by his powerful wife Empress Wei and daughter Li Guo'er the Princess Anle. His son by a concubine, Li Chongmao the Prince of Wen, was made emperor (as Emperor Shang). Empress Wei retained power as empress dowager and regent. Less than a month later, a coup led by Emperor Zhongzong's sister Princess Taiping and nephew Li Longji the Prince of Linzi (son of Li Dan, who was then Prince of Xiang) killed Empress Dowager Wei and Li Guo'er, and Li Dan was returned to the throne (as Emperor Ruizong), displacing Emperor Shang, who was demoted back to the title of Prince of Wen. Zhang Renyuan, in order to observe naming taboo (even though the Dan character in his name (亶) was not the same as Emperor Ruizong's (旦)), changed his name to Zhang Renyuan. A month after Emperor Ruizong took the throne, Zhang Renyuan requested retirement, and Emperor Ruizong allowed him to do so and further let him, in retirement, continue to carry the titles of minister of defense (兵部尚書) and Guanglu Daifu (光祿大夫) with full salaries. He died in 713, when Li Longji was emperor (as Emperor Xuanzong) and was buried with honor.
It was said that as a commanding general, Zhang was strict but fair. Later generals admired him and built a temple in his honor at the central fort that he built, and whenever there were military campaigns, sacrifices would be made to him. He, along with Li Jing, Guo Yuanzhen, and Tang Xiujing, were considered the few chancellors in Tang history who were capable in both civil and military matters.