KANDAHAR, Afghanistan — A longtime deputy in the Taliban who was arrested in a joint intelligence raid by American and Pakistani agents eight years ago has been freed, the insurgent group confirmed on Thursday.The release of the deputy, Mullah Abdul Ghani Baradar, who is in Pakistan, appeared to be the most tangible result of talks held recently by the Taliban and American diplomats.Mullah Baradar, who seemed interested in exploring peace negotiations before his capture in January 2010, was the Taliban’s most senior military leader at the time.American diplomats held talks this month with the Taliban in the Gulf state of Qatar for a second time since the White House ordered direct engagement with the insurgents.“Mullah Baradar reached his relatives last evening,” Zabihullah Mujahid, a Taliban spokesman, said. “This is the result of the recent contacts with the Americans.”Just how much impact Mullah Baradar’s return to the insurgency, which has gone through two leadership transitions while he was in detention, will have over any peace talks remains unclear.His release comes days after Gen. Abdul Raziq, the police chief of Kandahar who led the resistance against the Taliban in the south, was killed in a brazen insider attack.Mullah Baradar, before his arrest, led the operations in the southern provinces where the Taliban movement originated and which remain central to the group’s recruitment and financing.“He was an important figure in the Taliban, but it’s been a long time that he has been away from the Taliban system. His friends remain active in the ranks and they still trust him,” said Ahmad Shah Safr, an Afghan analyst. “He is under Pakistan influence now.”How Mullah Baradar acts going forward, the analyst said, will be “a sign of what Pakistan wants to do — whether Pakistan wants to move this process toward peace talks positively, or to stall them again.”At the time of his arrest, Mullah Baradar had initiated secret contacts with the Afghan government, then led by Hamid Karzai, a move that had angered Pakistan, which has long provided the Taliban leadership with sanctuary.By arresting him, and a dozen more Taliban commanders in the weeks after, Pakistan made clear to the insurgent leaders that they could not negotiate independently.In recent years, the Afghan government has sought unsuccessfully to initiate peace talks with the Taliban both directly and through Pakistan. But Taliban officials have insisted on speaking with the Americans first.The American diplomats seem to be moving with a sense of urgency in their efforts to convince the Taliban to engage in peace negotiations, partly reflecting President Trump’s weariness for the war.The American efforts faced a hiccup recently when the Afghan president, Ashraf Ghani, learned that United States diplomats had met with the Taliban and tried to hide news of the meeting from him.Afghan officials have since demanded clarity from the Americans and reassurances that their government is not excluded from such talks.