The US Senate has completed congressional approval of a sweeping $1.3tn (£921bn) package to fund the government until September.
Senators passed the 2,232-page bill in a 65-32 vote early on Friday, hours after the House gave backed it.
To become a law, the bill needs to be signed by President Donald Trump ahead of a Friday midnight deadline.
This would fund the federal government until 30 September, and avert another government shutdown.
Republican Speaker of the House Paul Ryan celebrated the package as a means to enact President Trump’s policy positions.
“This bill starts construction on the wall,” he told reporters in a news conference on Capitol Hill.
“It funds our war on opioids. It invests in infrastructure. It funds school safety and mental health,” he continued.
It provides $1.6bn in funding for Mr Trump’s border wall, far short of the $25bn the White House had sought.
It also includes a provision that would legally allow the slaughter of wild horses roaming the American West.
In a last-minute addition, it added funds to include the National Instant Criminal Background Check System (NICS) for gun sales.
It includes a 9% budget increase for the US National Park Service to address a repair backlog that advocates say are urgently needed.
“This is a necessary investment with broad returns, and we hope this trend continues,” in future spending bills, said Kristen Brengel of the non-profit National Parks Conservation Association.
The bill also boosts military spending.
House Democratic leader Nancy Pelosi called it “a tremendous victory for the American people”.
“If you want to think you’re getting a wall, just think it and sign the bill,” she said, in a remark aimed at Mr Trump’s Republican supporters in Congress.
But despite cross-party support, at least 90 conservative Republicans objected to the measure, calling it government spending run amok.
“This omnibus [spending bill] doesn’t just forget the promises we made to voters, it flatly rejects them,” Representative Mark Meadows, head of the hardline House Freedom Caucus, said after the vote.
“This is wrong. This is not the limited government conservatism our voters demand.”