Police said they have thwarted a plot to carry out beheadings in Australia by supporters of Islamic State (IS) by detaining 15 people and raiding more than a dozen properties across Sydney.
The raids involving 800 federal and state police officers - the largest in the country's history - came in response to intelligence that an IS leader in the Middle East was calling on Australian supporters to kill, said prime minister Tony Abbott.
Mr Abbott was asked about reports that the detainees were planning to behead a random person in Sydney.
"That's the intelligence we received," he told reporters. "The exhortations - quite direct exhortations - were coming from an Australian who is apparently quite senior in Isil (IS) to networks of support back in Australia to conduct demonstration killings here in this country.
"This is not just suspicion, this is intent and that's why the police and security agencies decided to act in the way they have," Mr Abbott said.
The raids came just days after the country raised its terrorism threat to the second highest level in response to the domestic threat posed by supporters of IS. At the time, Mr Abbott stressed that there was no information suggesting a terror attack was imminent.
Later, attorney general George Brandis confirmed that a person born in Afghanistan who had spent time in Australia and is now working with IS in the Middle East ordered supporters in Australia to behead people and videotape the executions.
"If the ... police had not acted today, there is a likelihood that this would have happened," Mr Brandis told the Australian Broadcasting Corp.
Mr Abbott and Mr Brandis did not name the Australian. But Mohammad Ali Baryalei, who is believed to be Australia's most senior member of IS, was named as a co-conspirator in court documents. Police have issued an arrest warrant for the 33-year-old former Sydney nightclub bouncer.
One of those detained, 22-year-old Omarjan Azari of Sydney, appeared briefly in a Sydney court.
Prosecutor Michael Allnutt said Azari was involved in a plan to "gruesomely" kill a randomly selected person - something that was "clearly designed to shock and horrify" the public. That plan involved an "unusual level of fanaticism", he said.
Azari is charged with conspiracy to prepare for a terrorist attack. The potential penalty was not immediately clear.
In court documents, Azari was accused of conspiring with Baryalei and others between May and September to prepare for a terrorist attack. Mr Allnutt said the charge stemmed from the interception of a phone call a couple of days ago.
Azari did not apply for bail and did not enter a plea. His next court appearance was set for November 13.
Dozens of police spent Thursday searching Azari's home and a car parked across the street from his house. One officer pulled a memo out of the car from the Australian National Imams Council outlining concerns about Australia's new anti-terrorism proposals. The council did not immediately respond to messages seeking comment.
The Australian Security Intelligence Organisation's director-general, David Irvine, said the threat of terrorism in the country had been rising over the past year, mainly due to Australians joining the Islamic State movement to fight in Syria and Iraq.
"Police believe that this group that we have executed this operation on today had the intention and had started to carry out planning to commit violent acts here in Australia," said federal police deputy commissioner Andrew Colvin.
"Those violent acts particularly related to random acts against members of the public."
Police declined to reveal exact details of the attack they believe was being plotted. New South Wales police commissioner Andrew Scipione said only that it was to be carried out against a member of the public on the street and was at "a very high level".
"Right now is a time for calm," Mr Scipione said. "We need to let people know that they are safe, and certainly from our perspective, we know that the work this morning will ensure that all of those plans that may have been on foot have been thwarted."
A separate series of raids was conducted on Thursday in the eastern cities of Brisbane and Logan. Last week, Australian police arrested two men in Brisbane for allegedly preparing to fight in Syria, recruiting jihadists and raising money for the al Qaida offshoot group Jabhat al-Nusra, also known as the Nusra Front.
Mr Colvin said the raids conducted in Brisbane on Thursday were a follow-up to that operation. Queensland police commissioner Ian Stewart said the operations in Sydney and Brisbane were linked, but declined to release details.
Police said at the time there was no terrorist threat to the Group of 20 leaders' summit to be hosted by Brisbane in November that will bring US president Barack Obama and other leaders of the world's 20 biggest economies to the Queensland state capital.
Australia has estimated about 60 of its citizens are fighting for IS and the Nusra Front in Iraq and Syria. Another 15 Australian fighters had been killed, including two young suicide bombers.
The government has said it believes about 100 Australians are actively supporting extremist groups from within Australia, recruiting fighters and grooming suicide bomber candidates as well as providing funds and equipment.
Azari's lawyer, Steve Boland, said during the court hearing that the allegation against his client was based "on one phone call".
A second man was charged in connection with the raids. The 24-year-old, who police did not name, was charged with possessing ammunition without licence and unauthorised possession of a prohibited weapon. He was released on bail and ordered to appear in court next week.
Nine of those detained were later released, New South Wales police said.
A Sydney money transfer business owned by the sister and brother-in-law of convicted terrorist Khaled Sharrouf, an IS fighter, had its licence suspended this week on suspicion it had been sending one million Australian dollars (£549,000) a month to the Middle East to finance terrorism, said John Schimdt, chief executive of the industry regulator and corruption watchdog AUSTRAC.