President Rodrigo Duterte and Chinese President Xi Jinping pose before the start of their bilateral meeting in Beijing on Thursday. Robinson Ninal, Presidential Photo

MANILA—President Rodrigo Duterte's recent trip to China was "successful," Palace spokesperson Salvador Panelo said Saturday.

"With the conclusion of President Duterte’s official visit to China, we wish to inform the public that the same has been successful and highly productive," Panelo said in a statement.

Duterte went to Beijing to meet Chinese President Xi Jinping for bilateral talks, in what was described as a high-stakes diplomatic engagement between the two leaders.

"The close relationship that President Duterte and Chinese President Xi Jinping have been able to foster through the years has enabled the two leaders to have frank exchanges on the respective positions of our two countries with regard to our territorial dispute," Panelo said.

Manila and Beijing have been embroiled in a territorial dispute over the West Philippine Sea, raising tensions in the area.

"Both of them (agreed) to exercise self-restraint and observe the UNCLOS (United Nations Convention on the Law of the Sea), particularly with respect to maritime navigation and overflight in the South China Sea," the spokesperson said.

Panelo reiterated Xi's desire for a binding South China Sea code of conduct crafted before Duterte steps down.

"China (recognized) the immediate need of the crafting of a definitive code of conduct for our regional waters, all with the intent of avoiding provocative acts that may impair friendly ties and threaten the peace and stability of the region," Panelo said.

Chinese warships have passed many times through Philippine waters without informing authorities.

Duterte had promised he would raise 2016 Manila’s arbitral victory, which upheld the country’s sovereign rights over the West Philippine Sea with Xi during the visit.

Xi, however, rejected the ruling again on Thursday.

The Philippines in 2016 won a case at the Permanent Court of Arbitration in The Hague, which invalidated China’s claim to sovereignty over most of the West Philippine Sea.

However, China didn't recognize the ruling and has instead ratcheted up militarizing the vital waterway.

—With reports from Arianne Merez and Davinci Maru, ABS-CBN News