WASHINGTON - US President Donald Trump turned up the heat Thursday on Republican leaders in Congress accusing them of foot-dragging on his key priorities, in an intensifying feud that puts his policy agenda in jeopardy.

When lawmakers return from summer recess on September 5, a deeply divided Congress will need to come together by the end of the month to fund the government into 2018 and raise the legal cap on federal borrowing in order to avoid a debt default.

Further weighing down Congress’s autumn load, Republicans desperate for a major legislative victory under the new president want to rewrite the tax code and improve American infrastructure.

But as the critical showdown looms in Washington, Trump has clashed with and antagonized members of his own party, while threatening a shutdown of the federal government unless he gets funding for his promised US-Mexico border wall.

Over the past week Trump has widened an already-yawning rift with congressional leaders like top Republican Senator Mitch McConnell - who he attacked once again Thursday using the bully pulpit of Twitter.

The president castigated both the Senate majority leader and Paul Ryan, the speaker of the House of Representatives, for not taking his advice to tie crucial debt ceiling legislation to a popular veterans bill that recently passed Congress. “Could have been so easy - now a mess!” Trump tweeted.

Further complicating the task ahead is the threat of a government shutdown.

The White House is demanding that the government funding bill include credits for Trump’s border wall - a call opposed by Democrats who have the power to block the bill in the Senate, triggering a shutdown on October 1.

“Believe me, if we have to close down our government we’re building that wall,” Trump warned Tuesday in an angry and divisive speech that made some Republicans wince.

Both McConnell and Ryan have sought to downplay divisions with Trump - and talk of either any shutdown or a debt default, which would be the first in US history. “I don’t think a government shutdown is necessary, and I don’t think most people want to see a government shutdown, ourselves included,” Ryan told reporters Wednesday.

McConnell has meanwhile insisted he and the president are on the same page, after an explosive New York Times report depicted a rapidly deteriorating relationship. “Anyone who suggests otherwise is clearly not part of the conversation,” he said in a statement Wednesday.

Seeking to quell talk of a spectacular fallout, the White House issued its own statement late Wednesday insisting Trump and McConnell were “united” on their political priorities.

But Trump appeared unwilling to draw a line under their feud , going on to berate McConnell Thursday for coming up short in an effort to dismantle Barack Obama’s health care law.

“The only problem I have with Mitch McConnell is that, after hearing Repeal & Replace for 7 years, he failed!” Trump tweeted.

Beyond the party leadership, the US president has publicly attacked a string of Republican lawmakers - including senators John McCain, Jeff Flake, Dean Heller and Lisa Murkowski - at the risk of weakening his chances of driving legislation through Congress.

Other Republicans have meanwhile grown more assertive in their criticism of the president, following the furor triggered by his equivocal response to the violence at a white nationalist rally in Charlottesville, Virginia earlier this month.

House Republican Tom Cole sounded a warning call to Trump , saying on CNN that shutting down the government is “always a mistake” that “shows political dysfunction,” especially when the president’s party controls Congress.

Ryan sent a rallying call out to the party ranks on Wednesday, saying “I think it’s important that we all stay unified as Republicans, to complete our agenda .”

Top Democrats meanwhile urged Republican leaders to act responsibly and commit to avoiding a government default.

“Republicans need to stop the chaos and sort themselves out in a hurry,” House Minority Leader Nancy Pelosi said Thursday.

Passage of the government spending bill will require support from Democrats, who oppose inserting border wall funding into the legislation, and are also opposed to spending cuts as a condition for raising the debt ceiling, as some conservatives want.