Germany on Tuesday defended itself at the International Court of Justice against accusations that its arms shipments to Israel were furthering genocide in Gaza, arguing that most of the equipment it has supplied since Oct. 7 was nonlethal and that it has also been one of the largest donors of humanitarian aid to the Palestinians.

At the U.N. court in The Hague, lawyers for Germany said that the allegations brought by Nicaragua had “no basis in fact or law” and rested on an assessment of military conduct by Israel, which is not a party to the case.

“Germany firmly rejects Nicaragua’s accusations,” Tania von Uslar-Gleichen, an official at Germany’s Foreign Ministry and lead counsel in the case, told the 15-judge bench, adding that Nicaragua had “rushed this case to court on the basis of flimsiest evidence.”

On Monday, Nicaragua had argued that Germany was facilitating the commission of genocide against Palestinians in Gaza by providing Israel with military and financial aid, and it asked for emergency measures ordering the German government to halt its support. The court is expected to decide within weeks whether to issue emergency measures.

The proceedings, which concluded Tuesday, were the third time in recent months that the U.N. court became a forum for nations to put pressure on Israel and support Palestinians.

Earlier this year, the court heard arguments by South Africa that Israel was committing genocide in Gaza and ordered the Israeli government to take steps to prevent such atrocities. The court has not ruled on whether genocide was in fact taking place, an allegation that Israel has strongly denied.

The latest case, brought by a Nicaraguan government that itself has been widely accused of repression and human rights violations, has placed a spotlight on Germany, Israel’s second-largest arms supplier after the United States. Germany’s leadership calls support for Israel a “Staatsräson,” a national reason for existence, as a way of atoning for the Holocaust.

But the mounting death toll and humanitarian crisis in Gaza have led some German officials to ask whether that backing has gone too far.

Lawyers for Germany urged the court to throw out the case. They argued that Germany has tried to balance the interests of both Israel and the Palestinians, and presented figures showing that Berlin was among the largest individual donors to the U.N. and other agencies that provide humanitarian aid to Gaza.

“Germany has always been a strong supporter of the rights of the Palestinian people,” Ms. von Uslar-Gleichen said. “This is, alongside Israel’s security, the second principle that has guided Germany’s response to the Middle East conflict in general, and to its current escalation in particular.”

In 2023, Germany approved arms exports to Israel valued at 326.5 million euros, or about $353.7 million, according to figures published by the economics ministry. That is roughly 10 times the sum approved the previous year.

Germany’s legal team argued on Tuesday that most of its exports were nonlethal support, such as protective gear, communications equipment and defense equipment against chemical hazards. Christian Tams, a lawyer for Germany, denied Nicaragua’s claims that Germany had increased weapons supplies to Israel since the Oct. 7 Hamas attack, saying that since then “no artillery shells, no munitions had been licensed.”

“The picture presented by Nicaragua is at best inaccurate, and at worst it is a deliberate misrepresentation of the actual situation,” he said.

While it was not possible to independently verify the figures presented by Mr. Tams, they were roughly in line with those provided earlier this year by the German government, in response to a question from a lawmaker, when it said that only about 6 percent of its military exports to Israel were for what it called “weapons of war.”

Critics have said that there is little distinction between the types of weapons provided to Israel while it is at war. On Monday, Carlos Jose Arguello Gomez, Nicaragua’s ambassador to the Netherlands, told the court that “it does not matter if an artillery shell is delivered straight from Germany to an Israeli tank shelling a hospital” or goes to replenish Israel’s stockpiles.

Pieter D. Wezeman, a senior researcher at the Stockholm International Peace Research Institute, which tracks global arms exports, said the German position is in line with typical arms exports to Israel.

“While they don’t do the killing directly, they are an essential part of the overall system, the armed forces of a country, which actually make it possible to engage in warfare,” he said.

Lawyers say that Germany is an easier target for a suit than is the United States, by far Israel’s main military supporter. Germany has granted full jurisdiction to the International Court of Justice. But the United States denies its jurisdiction, except in cases where Washington explicitly gives its consent.