Pakistani intelligence officials had earlier said that an US pilotless aircraft fired missiles on a camp of Pakistani militants in Afghanistan's eastern Kunar province and killed 21 militants.
"An American drone struck a religious school along the Pak-Afghan border on March 7, 2018," said a Tehrik-e-Taliban Pakistan (TTP) statement that was emailed to the local media.
The statement said the attack killed Abdullah, 17-year son of the TTP chief and 20 other students and teachers.
Pakistani intelligence officials said on Thursday that the US drone fired two missiles on the militants of in Shaltan area of Kunar province of Afghanistan on Wednesday morning.
Senior TTP commander Yasin was also among those killed. He was the teacher of the suicide bombers, according to a Taliban source.
They said the drone struck the camp of suicide bombers when they were busy in physical training in the rugged mountainous region, bordering Pakistan's Bajaur tribal region.
Pakistani officials have long been saying that members of the TTP and other Pakistani groups have fled to Afghanistan following major military operations in the country's tribal regions and Swat Valley in the northwest.
Intelligence officials said that those killed in Wednesday's strike belonged to different areas of northwestern Khyber Pakhtunkhwa province.