What happened

Shares of Nikola (NKLA 7.23%) saw huge gains early in Friday's trading thanks to a new deal, but then, nearly all of that surge evaporated. While the electric vehicle company's stock was at one point up by as much as 32.9%, according to data from S&P Global Market Intelligence, it closed out the session up by just 1.4%.

Nikola published a press release on Thursday announcing that would be selling up to 50 of its Nikola Class 8 hydrogen fuel-cell electric vehicles to BayoTech. Additionally, it will be purchasing low-emission hydrogen from BayoTech and buying up to 10 of its HyFill transportation trailers.

So what

Nikola anticipates that it will receive BayoTech's low-carbon-emission hydrogen in Missouri this year, and will receive additional deliveries in California next year. In order to facilitate the delivery of gaseous hydrogen from BayoTech's production sites, Nikola intends to acquire up to 10 of the company's HyFill transport trailers. 

In turn, BayoTech intends to purchase up to 50 of the EV company's Class 8 fuel-cell electric trucks over a five-year period. The first 12 trucks are scheduled to be delivered in 2023 and 2024; BayoTech will use the vehicles to deliver hydrogen to customers. 

Given that Nikola has been having trouble raising capital, the deal looks to be a positive development for the EV specialist. To some extent, it will essentially allow the company to trade its vehicles for needed resources at a time when it's strapped for cash.

The initial surge in Nikola's share price likely triggered a short squeeze that sent its stock even higher. But short squeezes don't tend to last long -- and this one didn't. 

Now what

In addition to helping Nikola secure hydrogen and transportation trailers, the new partnership also represents a vote of confidence in the company's electric trucks. Thanks to excitement surrounding the deal and a broader rally for smaller EV stocks, Nikola stock ended the week trading up by roughly 59%. If the company can hold onto those gains, it could help it in raising some much-needed cash. 

Nikola last tried to gain approval from shareholders to sell new shares on July 6. While a majority voted to approve the secondary stock offering, support for the measure fell short of the necessary threshold to proceed. The company is scheduled to hold another vote next month, and will also publish second-quarter results on Aug. 4.