US President Donald Trump has ordered "new vetting measures" to keep "radical Islamic terrorists" out of the country.

On a day he alternated tough talk with kind words in his diplomatic stand-off with Mexico, Mr Trump travelled to the Pentagon for the signing of an executive action to bring sweeping changes to the nation's refugee policies and put in motion his plans to build up the nation's military.

"I'm establishing new vetting measures to keep radical Islamic terrorists out of the United States of America. We don't want 'em here," Mr Trump declared.

"We want to ensure that we are not admitting into our country the very threats our soldiers are fighting overseas. We only want to admit those into our country who will support our country and love deeply our people."

During his election campaign Mr Trump pledged to put in place "extreme vetting" procedures to screen people coming to the US from countries with terrorism ties.

The White House did not immediately release details on the order the president signed, but a draft of the order called for suspending the issuing of visas to people from Iran, Iraq, Libya, Somalia, Sudan, Syria and Yemen for at least 30 days.

Earlier at the White House Mr Trump was asked about a more contentious issue: his recent statements that torture "does work" in prying information out of terror suspects.

Giving ground, he said US defence secretary James Mattis's opposition would override his own belief. Hours later he stood at the Pentagon as the retired general was sworn in as the military's chief.

But Mr Trump held firm on another controversy - trade and illegal immigration from Mexico. He told reporters that he had a "very good call" with Mexican President Enrique Pena Nieto earlier in the day, but reaffirmed his belief that Mexico has "out-negotiated and beat us to a pulp" on trade - and that would change.

"We're no longer going to be the country that doesn't know what it's doing," he declared a day after the Mexican leader cancelled his visit to Washington in response to Mr Trump's plans to build a border wall and have Mexico pay for it.

The flurry of national security and foreign police moves capped a hectic first week for Mr Trump at the White House, giving Americans an initial look at how the new president intends to position the United States around the globe.

AP