TOKYO — Both President Trump and North Korean leader Kim Jong Un believe “substantive progress” can be made at a second summit meeting, Secretary of State Mike Pompeo said Monday, adding that arrangements for the leaders to meet are close to being finalized.

Pompeo spent around 3.5 hours with Kim in Pyongyang on Sunday, in a formal meeting and then at lunch, talks he later described as “productive” and “another step forward” in negotiations to persuade North Korea to give up its nuclear weapons program.

The two sides agreed to set up “working-level” negotiating teams to finalize the date and time for a summit, as well as set the stage for a successful summit meeting, he said.

“Most importantly both the leaders believe there is real progress that can be made, substantive progress that can be made at the next summit, and so we are going to get it at a time that works for each of the two leaders and at a place that works for both of them,” Pompeo told reporters in South Korea, where he flew after his visit to Pyongyang. 

“We really hope we can deliver some good outcomes from that when the summit takes place,” he added. “But we do think, right, that this is a place where ultimately some of these big difficult issues have to be resolved by the nation’s most senior leaders and hope to have those presented in a way that the two leaders can resolve them when they get together.”

The secretary of state’s previous trip to North Korea, in July, did not go so well. He came away from it saying the two sides had made progress, only for North Korea to denounce him for making “gangster-like” demands and raising “cancerous” issues. On that occasion, he did not meet with Kim.

But this time, the North Korean reaction to the talks was much more positive. Korean Central News Agency (KCNA) reported that Kim had “warmly welcomed” Pompeo in Pyongyang and “spoke highly of him.”

Kim said progress is being made implementing the decisions he reached with Trump in Singapore in June, according to KCNA, and expressed his gratitude to Trump, adding that an agreement had been reached to hold a second summit “as soon as possible.”

“The supreme leader expressed his will and conviction that a great progress would surely be made in solving the issues of utmost concern of the world and in attaining the goal set forth at the last talks with the projected second DPRK-U.S. summit talks as an occasion,” KCNA reported.

North Korea’s official name is the Democratic People’s Republic of Korea, or DPRK.

“Kim Jong Un expressed satisfaction over the productive and wonderful talks with Mike Pompeo at which mutual stands were fully understood and opinions exchanged,” KCNA said. 

Kim also expressed the belief that — “based on the deep confidence between the top leaders of the two countries” — dialogue and negotiations would continue to develop favorably and a “good program” for a second summit would be developed.

During Pompeo’s meeting in Pyongyang, Kim also invited inspectors to visit the Punggye-ri nuclear test site to “confirm that it has been irreversibly dismantled,” the State Department said. 

Pompeo said this could happen “as soon as we get it logistically worked out,” adding: “Chairman Kim said he’s ready to allow them to come in.”

The secretary of state also confirmed that inspectors would be invited to a separate missile test site at Tongchang-ri, but declined to comment on which organization might be allowed in to either site. 

Kim made a commitment to allow inspectors into both sites when he met South Korean President Moon Jae-in last month, but experts said it was important to have him explicitly reiterate that promise to Pompeo.

After that inter-Korean summit, Kim also said he was prepared to permanently dismantle his country’s main nuclear site at Yongbyon, but only if the United States took “corresponding steps” to build trust.

Pompeo declined to comment on the status of talks over Yongbyon or the details of negotiations generally, saying “we’re not going to talk about where we are in these negotiations, except for things we have agreed to release with the North Koreans.”