The Senate rattled the saber yesterday and, in a victory for its conservatives, went on record 68 to 28 in favor of "whatever means may be necessary, including the use of arms," to contain Cuban aggression or subversion in the Western Hemisphere.

Then, after some second thoughts, it toned down the tough-talking measure by including language to the effect that the Senate did not mean to be providing statutory authority for introduction of troops under the War Powers Act.

But there were no such qualms earlier in the day when Sen. Steve Symms (R-Idaho) and other sponsors, claiming administration support, overrode objections from critics that the resolution amounted to a surrender of congressional war powers and defeated a move by Foreign Relations Committee Chairman Charles H. Percy (R-Ill.) to delete the reference to use of force.

Percy was defeated, 52 to 47, but, after the second thoughts set in, the qualifying language was approved, 97 to 2, with Sens. Barry Goldwater (R-Ariz.) and John P. East (R-N.C.) voting against any softening of the measure. Earlier in the day, Percy had lost even the support of other Senate leaders such as Majority Leader Howard H. Baker Jr. (R-Tenn.) as he argued, with little apparent effect, that the Symms-sponsored measure would mean abandonment of congressional prerogatives under the decade-old War Powers Act restricting the president's authority to wage war.

Percy also charged that the Symms proposal amounted to a "Gulf of Tonkin Resolution for Cuba," a reference to the congressional resolution that President Johnson used in the mid-1960s as justification for expanding U.S. involvement in the Vietnam war.

But conservatives had made a symbol of the resolution after it was set aside earlier this year, and to no avail, Percy tried to win over election-jittery colleagues by urging them to "have the best of all possible worlds" by supporting both the Symms measure and his own proposal to reassert congressional powers over dispatching of troops.

Before the vote, Sen. Jesse Helms (R-N.C.), saying that "it's time America started acting like America again," said he had spoken by telephone with Secretary of State George P. Shultz and quoted Shultz as saying the administration favored the Symms proposal.

The administration flip-flopped on a similar Symms resolution last spring, first opposing it and then endorsing it after the Senate voted narrowly to shelve the Symms language in connection with another bill. A Senate aide, anticipating Senate support for Symms' latest proposal, explained, "They're not going to get burned again by the administration on this one."

The Symms resolution that the Senate approved yesterday as a rider to a supplemental appropriations bill for the rest of fiscal 1982 asserts that the United States is "determined" to:

* "Prevent by whatever means may be necessary, including the use of arms, the Marxist- Leninist regime in Cuba from extending by force or the threat of force its aggressive or subversive activities to any part of this hemisphere.

* "Prevent in Cuba the creation or use of an externally supported military capability endangering the security of the United States.

* "Work with the Organization of American States and with freedom-loving Cubans to support the aspirations of the Cuban people for self-determination."

Percy's unsuccessful alternative proposal, which had been endorsed 14 to 1 by the Foreign Relations Committee, used much of the same strongly worded language about Cuba but avoided any reference to use of force to contain Cuban ventures in other Latin American countries.

Instead, it reaffirmed the "longstanding determination" on the part of the United States to "resist efforts by Cuba to extend its Marxist-Leninist ideology or political system in the hemisphere by force or the threat of force in violation of the Charter of the United Nations." It also specifically stated American resolve to "prevent in Cuba the stationing of nuclear weapons by the Soviet Union."

Sen. Joseph R. Biden Jr. (D-Del.) ridiculed Symms' proposal, saying that if the Senate "wants to get tough," it should direct its fire at the Soviet Union rather than Cuba.

"Let's go after the big guy," said Biden. "Let's go after someone our own size." He added, "Hysteria has set in, and we're all showing we can be tough."

The House-approved appropriations bill does not contain similar anti-Cuba language and House-Senate conferees will have to decide whether it stays in the measure.