Two months before President Donald Trump’s July phone call with Ukrainian President Volodymyr Zelensky, top officials in Kyiv were so concerned about the fate of U.S. political and military support for the country that at least two inquired about the matter with Washington, according to three sources with knowledge of those conversations.

Despite a strong showing of American support at Zelensky’s inauguration in May, Ukrainian officials were growing increasingly concerned about Rudy Giuliani’s public comments on investigations into Hunter Biden and the gas company he worked for, Burisma.

Two of those Ukrainian officials inquired with current and former U.S. officials, including an official at the State Department, about whether Giuliani’s efforts aligned with Washington’s thinking, and if the pressure campaign from Trump’s personal lawyer would impact a presidential White House meeting or the delivery of U.S. military aid, the sources said.

One of the Ukrainian officials who was wary about the mixed messages from Washington and the fate of U.S. support for the country was Oleksandr Danylyuk, the chairman of the country’s National Security and Defense Council.

Danylyuk, appointed to his post May 26, participated in several at least one key meeting with U.S. officials that is now under scrutiny by House impeachment investigators on Capitol Hill. Danylyuk’s tenure in the Zelensky administration was short lived. He resigned in September after transcript between President Trump and President Zelensky was released. He told Ukrainain media outlets that he stepped down because of efforts by billionaire Ihor Kolomoisky to influence banking regulation.

The details of Danylyuk’s conversations with current and former U.S. officials, some of which are reported here for the first time, underscore how officials close to Zelensky were worried about Giuliani’s efforts, and U.S. support faltering earlier than previously understood.

“ The concern was really over Giuliani appearing on TV all the time talking about corruption, Ukraine and the Bidens. And so here’s this guy who represents the president of the United States out there making these claims. People began to worry about what Trump was thinking about it all. ” — a former senior official close to Oleksandr Danylyuk, the Chairman of the Ukraine’s National Security and Defense Council

As early as May, Danylyuk was in conversation with current and former U.S. officials about “what to do with Giuliani” and his associates Lev Parnas and Igor Fruman, according to one former senior official close to Danylyuk.

“The concern was really over Giuliani appearing on TV all the time talking about corruption, Ukraine and the Bidens,” the official said. “And so here’s this guy who represents the president of the United States out there making these claims. People began to worry about what Trump was thinking about it all.”

At the time of Danylyuk’s conversations, the communication channel between Kyiv and Washington was far from solid. Weeks earlier, in late April, U.S. Ambassador Marie Yovanovitch had been recalled back to the U.S. The Ukraine portfolio was taken over, at least temporarily, by U.S. Ambassador to the EU Gordon Sondland, former top diplomat to Ukraine Kurt Volker and Trump Energy Secretary Rick Perry, according to the testimony transcripts of multiple impeachment inquiry witnesses.

The changing diplomatic landscape had Ukrainian officials, including Danylyuk, on edge.

“It was really all anyone could talk about at the time,” one U.S. official said, referring to Giuliani’s public messaging on Ukraine. “This conversation was happening all over the place—in the business community. In the political circles. And so when you’re that confused about what’s going on, it’s only natural that you begin to worry about this huge aid package that’s on the line.”

The concerns about Giuliani weren’t just circling in Kyiv. In Washington, senior officials were fielding calls and meetings about the situation. Fiona Hill, the former top Russia adviser to the National Security Council, testified that she was hearing reports that the Ukrainians were “very concerned” that they were receiving pressure from Giuliani and his team to launch investigations.

One of Danylyuk’s earliest reported official meetings with a U.S. representative was on May 30 with Rep. Tim Walberg (R-MI). Walberg had flown to Ukraine to attend the Ukrainian National Prayer Breakfast where he gave a speech. The two were scheduled to talk for an hour, according to a disclosure form Walberg filed with the House Ethics Committee.

According to three sources with knowledge of that conversation, Walberg and Danylyuk spoke about corruption in the country, including ongoing efforts to pressure Ukrainian officials to launch investigations into the country’s energy sector. And Danylyuk asked Walberg about the timing of a White House visit and the importance of the speedy delivery of U.S. military aid, one of those sources said. There’s no indication that Walberg and Danylyuk discussed a quid pro quo.

Danylyuk did not respond to a request for comment for this story. Dan Kotman, a spokesperson for Walberg said his meetings in Kyiv while at the prayer breakfast were “in no way related to the current news surrounding Ukraine.” When pressed for more information about his visit to Ukraine at a town hall meeting in Michigan last month Walberg said he communicates with Ukrainian officials about “issues of concern” regularly, including how to deal with corruption in the country.

When asked if the trip was taxpayer-paid Walberg said: “Of course”. But Walberg’s trip was not taxpayer-funded. It was paid for by the Ukrainian organizers of the prayer breakfast, according to his own disclosure form with the House Ethics Committee.

While in Kyiv, Walberg also met with the former chairman of the Ukrainian parliament, Andriy Parubiy. Parubiy spoke with Walberg about how U.S. support for the “sphere of security and defense and in carrying out reforms is important for Ukraine,” according to a translated version of an official press release of the meeting. Former congressman Bob McEwen and Dan Burleigh, the organizer of the U.S. National Prayer Breakfast, also attended the meeting.

The Daily Beast previously reported that McEwen helped arrange a meeting between Giuliani and former Ukrainian Prime Minister Yulia Tymoshenko to talk about security issues and Russian aggression in Ukraine. McEwen is a contractor for the Livingston Group, run by former congressman Bob Livingston, which represents multiple Ukrainian clients. Former National Security Council official Catherine Croft told House investigators that Livingston called her several times in an attempt to remove Ambassador Yovanovitch from her post. Livingston told The Daily Beast in an interview last week that he began “to get complaints about the ambassador a year and a half ago”.

Walberg was scheduled to meet with President Zelensky during his trip to Ukraine, but the meeting ultimately fell through.

Following his meeting with Walberg, Danylyuk continued to speak with Trump officials about Giuliani’s campaign to convince Ukraine to open up investigations into Hunter Biden, Burisma and unsubstantiated claims Ukrainian officials interfered in the 2016 election on behalf of Hillary Clinton.

“Danylyuk was negotiating President Zelensky's visit in Washington. That to me sounded strange since managers of our law enforcement agencies normally do not negotiate diplomatic events,” said Valentyn Nalyvaichenko, a member of Ukraine’s parliament and the former head of the country’s security service. “I think that it’s time both for Danylyuk and the head of [security service], Ivan Bakanov to give… the U.S. Congress all details about their negotiations with the United States.”

On July 10, Danylyuk attended a meeting in the White House with Zelensky aide Andri Yermak and then-National Security Adviser John Bolton, Ambassador Sondland, Volker, Hill and Lt. Col. Alexander Vindman, the deputy secretary of European Affairs at the State Department.

According to multiple individuals who testified in the impeachment inquiry, Sondland told Danylyuk and Yermak that Zelensky would not be able to meet with President Trump unless they publicly agreed to the investigations Giuliani had been pushing for.

By late July, Danyluk had made clear to top State Department officials that he and President Zelensky were aware of what Washington was up to.

“Gordon, one thing Kurt and I talked about yesterday was Sasha Danylyuk's point that President Zelensky is sensitive about Ukraine being taken seriously, not merely as an instrument in Washington’s domestic reelection politics,” Ambassador Wiliam Taylor wrote Sondland July 20.

When asked by investigators what Danylyuk was referring to in his comment about Zelensky, Taylor said: “I’m sure that was a reference to the investigations that Mr. Giuliani wanted to pursue.”

—additional reporting by Anna Nemtsova