China has agreed to return the underwater drone that was taken earlier this week, the Pentagon announced on Saturday.

"We have registered our objection to China's unlawful seizure of a US unmanned underwater vehicle operating in international waters in the South China Sea. Through direct engagement with Chinese authorities, we have secured an understanding that the Chinese will return the UUV to the United States," Pentagon spokesman Peter Cook said in a statement.

Details were not immediately available on when or how it may be returned.

President-elect Donald Trump made it clear on Saturday that China’s seizure of a U.S. Navy drone in international waters was "stolen" and an "unprecedented act."

Trump tweeted the message Saturday morning saying, “China steals United States Navy research drone in international waters - rips it out of water and takes it to China in unprecedented act.”