Adhnan Khalid, of Wellesley Road, Buckhaven, appeared at Kirkcaldy Sheriff Court.
Khalid, 37, was furious after Spanish airline company Vueling, lost his luggage, which contained vital documents for his wedding.
As a result, he had to cancel the ceremony.
After believing the company was ignoring his communications, Khalid posted messages on its Facebook page hinting that a bomb was on board one of its planes.
Khalid admitted that on January 31, 2020 at his home address and elsewhere he behaved in a threatening manner by posting on the Facebook wall of the Spanish airline Vueling that he hoped they’d find the bombs onboard flights leaving Spain and he also posted on the same Facebook wall that the same airline ignores information about health and safety.
The Procurator Fiscal Depute told the court: “On October 1, 2019, the accused travelled to Tangier via Barcelona using Spanish airline Vueling.
“During the journey, his luggage was lost in transit and, as a result, he arrived in Tangier without it which caused him to cancel his planned wedding due to required documentation being lost with it.
"On returning from the trip he submitted a claim with Vueling and was awarded £277 in compensation, but he was not satisfied with this and believed the costs incurred, as well as the inconvenience, amounted to far more than the sum he was paid.”
The Depute said that over the coming weeks the accused sent an email and a number of messages to Vueling via Facebook, but that none of these were threatening or abusive.
However, he said Khalid was of the opinion he was being ignored.
The Depute continued: “At 9.40am on January 31, 2020, a post by a Facebook profile in the name of the accused appeared on the Facebook wall of Vueling airlines.
“It read: ‘U hope you find the bombs that have been set on Vueling flights going out of Spain. Good luck, you will need it. I was told next week it will be a flight from France.’
“At about 10.05am the following was posted from the same account: ‘Amazing how Vueling ignores information about the health and safety of the crew and passengers. Do not fly with Vueling or Iberia’.
“When a security manager for Vueling saw the posts he hid them from public view to avoid causing alarm to the public and contacted the UK Border Force at Gatwick Airport as he believed the accused was a British citizen.”
The information was passed on to Police Scotland’s counter terrorism department who felt there was no credible threat.
Khalid’s defence lawyer said his client has since managed to get married.
He said: “He was travelling to Morocco to get married. His documents were in his luggage, as well as his clothes.
“The loss of his luggage meant his marriage could not go ahead.
“It was unspeakably foolish of him to do what he did – but it was fully borne out of frustration rather than something more than that.”
Due to the seriousness of the charges, Sheriff Timothy Niven-Smith remanded Khalid in custody while reports are prepared.