Partisan politics underlying the farm-credit debate boiled over on the House floor yesterday as angry Republicans accused Democrats of using credit-hungry farmers as pawns while forcing President Reagan into an embarrassing veto of farm-aid legislation.

From the beginning of the fight, Democrats have seen the farm-credit issue as an opportunity to make political gains against Reagan and put vulnerable Republican farm-state lawmakers facing reelection next year on the defensive.

At issue is whether, in seeking immediate gains at Reagan's expense, Democrats risk longer-term damage by being cast again as spenders and defenders of special interests while opposing a president who says that he is determined to reduce massive federal budget deficits.

For Reagan, the farm-credit fight has complicated efforts to cut the budget his way. Faced with possible other votes in which nervous GOP senators side with Democrats, the White House must consider a veto strategy or yield completely to Congress in setting budget priorities.

The Senate can be counted on to sustain such vetoes. But a successful veto would come at a cost of offending other Republican constituencies.

To an unusual degree, Democrats in both chambers have presented a united front in the face of veto threats, believing that the more they help publicize problems in rural America, the more they can tarnish the president.

"It's the first chink in the armor of a president who tries to portray everything as rosy," Rep. Leon E. Panetta (D-Calif.) said. "If it is rosy , why are farmers hurting?"

Administration officials concede that they are worried that increasing exposure of farmers' plight means increasing danger to the president. "No question that a veto will certainly heighten the risk," said presidential assistant Edward J. Rollins.

Administration officials say that Reagan's political rating has not been touched by farmers' anger. They cite a recent survey of rural areas in eight farm states by White House pollster Richard B. Wirthlin.

Taken as the congressional farm debate was heating up, the poll showed that Reagan's popularity ratings remain at more than 60 percent and are higher among farmers than nonfarmers, according to one GOP official.

Democrats say they think that those findings could change quickly if Reagan vetoes the legislation. "Up to this point, [the anger] has stopped with [Agriculture Secretary John R.] Block," one Democratic aide said. "This veto will carry it to Reagan."

Administration officials have argued that they must signal determination to press forward with their budget strategy. "This is the [year's] first major issue," Rollins said. "If we get broken on this . . . then every other special interest will know you can mobilize on Capitol Hill and raise the 1986 [reelection] issue. We've got to draw the line in the sand."

But Rep. E. Thomas Coleman (R-Mo.), who cosponsored the farm-aid bill passed by the House, said yesterday that the White House "misperceived" the issue from the start.

"Their whole attitude has been, since this is the first issue up this year, if they give an inch, they'll lose every budget vote." he said. "That's not true. It's a unique situation."

Coleman nevertheless blasted Democrats for rushing the farm bill to Reagan and virtually begging for a veto. "The farmers are being used as pawns in a political chess game," he said.

Sen. Robert W. Kasten Jr. (R-Wis.) said, "It is clearly a political effort . . . by Democrats to box in the administration and farm-state legislators."

Several GOP senators tried to avoid political damage by going against Reagan and Senate Majority Leader Robert J. Dole (R-Kan.) on close votes last week.

Eight Republicans, four of them facing reelection races next year, deserted the administration on one amendment. On another, five voted with the Democrats, and three of them face reelection in 1986.

"I think the farm-state senators did what they had to do to protect themselves politically, without damage to the deficit," said Sen. John Heinz (R-Pa.), who chairs the National Republican Senatorial Committee. "The president's veto won't hurt them. They'll vote to override."

Whether Republicans can turn the debate back on the Democrats by stressing the budget issue is not clear.

Democrats argue that the farm-aid bill has minimal impact on the deficit, but Republicans say they think that, once the heat of the moment begins to fade, even farmers may be susceptible to arguments that Reagan, not the Democrats, is doing more to cut the deficit.