The Central American country led by populist President Nayib Bukele is selling a new bond that will include a world-first clause to pay investors more if it fails to get either a new IMF programme or its credit rating lifted significantly by two of the big three agencies in the next 18 months.

"I think it is more likely that you'll get an IMF programme rather than the rating upgrades," Moody's analyst for the country Jaime Reusche said in an interview.

"Our rating level is Caa3, so (hitting the target rating of B2) would be a four-notch upgrade, which is very ambitious."

While S&P's B- score is only one notch away from the target, the other of the big rating firms, Fitch, is currently 2 notches from it at CCC+, meaning getting to the target looks unlikely.

"It is a warrant-like structure but it's strange," Reusche added about the bond's clause that ramps up the interest rate to 4% from 0.25% if neither the IMF nor rating targets are hit. "You are paying a penalty rather than getting a bonus."

The alternative target of an IMF programme looks more possible he said, although there is the key stumbling block of Bukele's decision to make bitcoin an official currency in El Salvador, something the IMF has been highly critical of.

"The 18-month time frame for an IMF programme is quite lengthy, so they are giving themselves a cushion," said Reusche.

"There is probably a degree of political calculus there as it takes them past the U.S. election" he added, pointing to Donald Trump - seen as politically closer in views to Bukele - potentially regaining the White House in November and perhaps softening the IMF's stance.

He said that while the new bond was the first time rating agencies' scores will directly determine a country's debt cost, it would not impact their decisions.

"Authorities can always put in whatever clause they want," he added. "It doesn't affect our independence."

Reusche also speculated that the pioneering "step-up" feature of the bond may even have been the thing that made the whole sale possible for El Salvador, which has been locked out of international bond markets for a number of years.

"They were very near to re-achieving market access but it was going to be a bit of a test, so I think this works as a bit of a sweetener," Reusche said.

"It might be a model that other countries without market access start to consider - but we have wait to see how successful this is."

(Reporting by Marc Jones; Editing by Sandra Maler)