The German government is trying to save Uniper with a 15 billion euro bailout deal as the struggling energy company becomes the first major victim of Russian gas shortages, CNBC writes.

As part of the bailout package, the German state will buy a 30 percent stake in Uniper. The energy company was the first in Germany to sound the alarm about skyrocketing energy bills and applied for government aid earlier this month.

As Germany's largest importer of gas, it has been hit hard by a significant reduction in flows from Russia, which has led to a sharp rise in prices.

In a statement, Finnish majority owner Fortum said Uniper and the German government have agreed on a "comprehensive stabilization package" to provide it with financial assistance.  “Uniper's gas trading activities are critical for Germany's energy supply and play an important role for the European energy sector,” the statement said.

"It is therefore of utmost importance to stabilize Uniper by immediately addressing the company’s loss-making and substantial liquidity needs, while at the same time initiating measures to de-risk its gas business model and secure a credit rating to support a path to longer-term viability."