But the deal - which allowed the bank to avoid taking a taxpayer bailout - was allegedly covered up by the bankers to protect their enormous bonuses.

Prosecutors allege they knowingly hid £322m in fees, paid in return for the Qatari investment to avoid looking weak and triggering a loss of confidence in the bank.

A loss of confidence could have threatened the company's future as an independent bank, requiring direct government intervention, which would likely have led to the dismissal of Barclays top brass.

It is alleged by prosecutors that they hid the vast fees in a separate agreement that was purportedly for 'advisory services,' but that this was really a cover to hide the higher investment commission fees.

Today (January 24) jurors heard a recording of a conversation between former Barclays executives Kalaris and Boath where Kalaris joked he didn't want to go to jail as a result of the secret payments because "the food sucks and sex is worse".

In the call played to the jury, they discuss how the services agreement, supposedly for advice from the Qataris, would be kept distinct from the investment fees, called the subscription agreement.

Boath explains to Kalaris that the bank's position will be that "whatever we do will not be related to this subscription agreement, but frankly we all know that whatever we enter into we are entering into in exchange for the subscription agreement."

Earlier today Prosecutor Ed Brown QC said: "The Qataris wanted a trade, they wanted a return on their capital investment in Barclays and it was agreed to be by Barclays 3.25 per cent.

"In early June (2008) a colleague was to say to Boath, 'They've got us by the balls' to which Boath agreed."

Mr Brown added that later in June, Boath said of a Qatari negotiator: "What he doesn't realise is that if he doesn't come through with his money we're f**ked."

The four all deny conspiracy to commit fraud by false representation in relation to the emergency fundraising which allowed Barclays to avoid direct governmental intervention.

The prosecutor told the jury how senior staff at the bank had expressed concern at the scheme, fearing that it would be unacceptable to shareholders whose dividends were half what the Gulf state was being paid for their investments.

The jury heard how Joanna Baker, the head of the bank's corporate development, was asked to come up with a way of paying the Qataris the inflated rate.