Three armed men entered the Spanish consulate in Bern, injuring a guard and briefly holding two people hostage, but escaped before Swiss police mounted a massive security cordon around the building.
Thinking that the trio were still inside the consulate, police surrounded the premises for seven hours before discovering that it was empty.
"We believe the three left the building before 8:00 o'clock (0700 GMT) and (then) the police arrived," the head of Bern's municipal police, Peter Theilkas, told a news conference.
Earlier, two staff members who had been held in a room of the building were allowed to leave the villa in central Bern's Kirchenfeld district. Another employee was stabbed in the head with a knife when he arrived at the scene, but he managed to escape and alert the police.
Police said they were not yet certain whether the men intended to rob the consulate or were seeking hostages to ransom.
"The motive from our point of view is not clear: it ranges from burglary to classic hostage-taking," said Theilkas, although police believe the trio were not politically motivated, according to <i>AFP</i>.
Consulate staff quoted by Switzerland's French-language Radio Suisse Romande said the intruders wanted to snatch passports or visa stamps which are sold on the black market for between 6,000 and 8,000 Swiss francs (4,000 to 6,000 euros, 5,000 dollars to 7,700 dollars).
The consulate had been the target of several break-in attempts, staff said.
Late on Monday in Madrid Spanish Foreign Minister Miguel Angel said that "nothing had been taken" by the armed men. He said Spanish authorities also believed that the attack was not politically motivated, but was unsure whether the men were after passports, visas and stamps or out to take hostages to ransom.