(ABC) -- Injecting confusion into already perilous shutdown negotiations, President Donald Trump undercut his own administration's stance by tweeting Thursday that a children's health insurance program should not be part of a short-term budget agreement.
The president's tweet came as Republicans and Democrats were scrambling to avert the shutdown, which could come at midnight Friday. The administration had previously expressed support for GOP-drafted legislation that includes money for the popular children's program for six years, a tactic aimed at winning some Democratic support for the bill.
The House was to vote later Thursday.
After Trump tweeted, aides from both parties expressed bafflement at exactly what he meant and why he took his position. It was the latest instance that has raised doubts in Washington about the president's unpredictable approach to legislation, policy and political decisions.
The White House did not immediately respond to questions about the tweet, which said simply: "CHIP should be part of a long term solution, not a 30 Day, or short term, extension!"
Just Wednesday, the White House budget office sent Congress a letter expressing support for the overall bill and expressly wrote, "The Administration supports the bill's multiyear funding extension of the Children's Health Insurance Program (CHIP)."
Federal financing for the program that serves nearly 9 million children expired in October and several states are close to exhausting their money, and Congress has passed several short-term patches to keep their programs afloat.
Trump's comments came amid a flurry of tweets Thursday. He also insisted his views on a border wall with Mexico have not evolved, pushing back against his own chief of staff's comments to lawmakers.
Trump said on Twitter: "The Wall is the Wall, it has never changed or evolved from the first day I conceived of it."
Some Democrats who met with White House chief of staff John Kelly on Wednesday say Kelly told them parts of the border don't need a wall — and that Trump didn't know that when making campaign promises.
Trump tweeted Thursday that some of the wall will be "see through," and he wrote that the wall was never supposed to be built where there are natural barriers. He added that it "will be paid for, directly or indirectly, or through longer term reimbursement, by Mexico, which has a ridiculous $71 billion dollar trade surplus with the U.S."
Kelly's assertion that Trump's views on immigration had evolved came as lawmakers try to reach accord on protecting hundreds of thousands of young immigrants from deportation, a push the White House and Republicans say they would back, if it's coupled with tough border security measures and other restrictions.
Trump tweeted Thursday, "If there is no Wall, there is no Deal!" He said the U.S. needs a wall "to help stop the massive inflow of drugs from Mexico, now rated the number one most dangerous country in the world."
Kelly made the remarks about Trump and the wall Wednesday at a closed-door meeting with members of the Congressional Hispanic Caucus, participants said, and he made similar comments later on Fox News Channel.
Kelly said on Fox he told the caucus that "they all say things during the course of campaigns that may or may not be fully informed." He said Trump has "very definitely changed his attitude" toward protecting the young immigrants, "and even the wall, once we briefed him."
"So he has evolved in the way he's looked at things," Kelly said. "Campaign to governing are two different things and this president has been very, very flexible in terms of what is within the realms of the possible."
Kelly's comments were noteworthy because they openly acknowledged the difference between campaign promises and governing, and even suggested that Trump needed to be educated on the subject.
They also come as lawmakers struggle to reach a bipartisan deal protecting "dreamers" — around 800,000 people who arrived in the U.S. illegally as children and could be deported without legal protections. Part of negotiators' problem has been uncertainty over what Trump would accept.
"He's not yet indicated what measure he's willing to sign," Senate Majority Leader Mitch McConnell, R-Ky., told reporters Wednesday. "As soon as we figure out what he is for, then I will be convinced that we would not just be spinning our wheels going to this issue on the floor."
Trump's tweets on Thursday were hardly the first time his words have been in conflict with comments by a senior aide. Among other clashes, he has repeatedly undercut Secretary of State Rex Tillerson.
Some lawmakers who met with Kelly Wednesday recounted his remarks.
"He specifically said that there's some areas of the border that didn't need the wall, and that the president didn't know that when he was making his campaign promises," Rep. Ruben Gallego, D-Ariz., said in a brief interview.
Another lawmaker, Rep. Luis, Gutierrez, D-Ill., said Kelly told them that "there were statements made about the wall that were not informed statements. In other words, I've informed the president of what it takes to build a wall, so here's how we're going to do it. That's what I understood, and all of that was helpful."
Many Democrats have said that without an immigration deal in sight, they'll vote against a Republican bill preventing a weekend government shutdown. Congressional passage must come by Friday to prevent an election-year shutdown of federal agencies that could be damaging to both parties.
During his presidential campaign, Trump made it a mantra to promise to build a "beautiful" wall that would be paid for by Mexico. Supporters at his rallies often chanted, "Build that wall."
White House officials have repeatedly said it doesn't have to be a concrete wall from coast to coast but could include large stretches of fencing, technology or other systems. Trump also now wants Congress to provide taxpayer money to finance it.
Trump ended the legal shields on "Dreamers" last year and gave Congress until March to renew them.
Last week, he rejected a compromise by three Democratic and three Republican senators to restore those protections, a deal that included money to begin building the wall and other security steps. Trump's rejection angered the bargainers, and partisan feelings worsened after participants in a White House meeting last week said Trump had referred to African nations as "shitholes."
Another group of high-level lawmakers has also started talks aimed at brokering an immigration deal, adding an additional level of uncertainty.
Kelly said on Fox that "there's no doubt in my mind there's going to be a deal" protecting the Dreamers.
Meanwhile, Senate Minority Leader Chuck Schumer, D-N.Y., said there's "very, very strong" sentiment among Democrats in the chamber to oppose GOP-drafted legislation to keep the government's doors open.
His comments underscored the problems GOP leaders face in winning congressional passage of that legislation. The bill would keep agencies open until mid-February and finance a popular children's health insurance program for a year.
Democrats' votes are needed to advance the stopgap measure through the Senate. It's even unclear whether GOP leaders have nailed down enough votes to prevail in the House, where conservatives and strong boosters of the Pentagon have been unhappy.
Conservative leader Rep. Mark Meadows, R-N.C., said he wants GOP leaders to add additional defense money. But he said he was pessimistic leaders would grant other conservative-backed ideas, such as the promise of a vote on a more conservative immigration bill authored by Judiciary Committee Chairman Robert Goodlatte, R-Va.