A high-ranking North Korean official appears to be visiting Beijing, a source with knowledge of the matter said Thursday, as the country has been bolstering ties with China.

The purpose of the visit is unclear. The official was believed to be en route to Singapore for working-level talks with the United States reportedly later this week to prepare for the June 12 summit in the city-state between North Korean leader Kim Jong Un and U.S. President Donald Trump.

But Trump late Thursday abruptly called off the summit, citing what he called North Korea's recent "open hostility."

After arriving in Beijing by air, the official was picked up by a Chinese government vehicle and he could hold talks with Chinese officials, the source said.

China-North Korea relations have drastically improved recently. Kim traveled to Beijing in March to hold talks with Chinese President Xi Jinping, and earlier this month the two leaders met again for two days in the northeastern Chinese city of Dalian.

Kim, who wants the United States to ensure the survival of his regime in return for pledging denuclearization, has been trying to obtain support from Xi, analysts say.

Kim's visit to Beijing in March was his first foreign trip since becoming North Korea's supreme leader following the death of his father Kim Jong Il in December 2011.

Since the trip, several high-ranking Chinese and North Korean officials, including their foreign ministers, have made reciprocal visits.

However, North Korea has recently threatened to cancel the Kim-Trump summit, taking issue with ongoing joint military drills by South Korea and the United States, and accusing Washington of pushing for Pyongyang to unilaterally abandon its nuclear weapons.

In the run-up to the summit, Kim was apparently testing Trump, as some U.S. officials had still urged North Korea to agree to a "Libya-style" denuclearization process, in which Pyongyang first gives up all its nuclear weapons before receiving any benefits.