Australian teenager Jamie Murphy has been released after Bali's police chief confirmed the white powder allegedly discovered on the teen was not an illicit drug.
Mr Murphy, 18, left the police station with his lawyer in almost complete silence, replying only with "yep" when asked if he was happy to be getting out.
"The white substance test results by forensic lab official statement was negative," said Kuta police chief Wayan Sumara. "[It] was a mixed of acetaminophen (pain killer), two type of cough medicine, and caffeine," he said.
Bali police chief Sugeng Priyanto earlier told Fairfax Media the powder, as well as blood and urine tests on the 18-year-old, had come back negative for drugs.
"According to Denpasar drug chief, the test results were negative, all negative," he said. "I received the report via phone that the white substance was not narcotic, urine test also negative."
Mr Murphy was released because no crime had been committed, he said.
"If negative, it means no crime happened," Mr Priyanto said.
Made Suarjana from the Vidhi Law Office said the teenager was "very happy" to hear the news.
"He is very happy [to hear test results are negative], because that's the truth, he was never in possession of such thing [narcotics]," Mr Suarjana said.
Mr Suarjana said Mr Murphy never bought the white substance, and it appeared "like magic" when he was searched by security guards at the Sky Garden nightclub.
"Suddenly the item was just there, when he was searched by the security," Mr Suarjana said. "Because he was in a panic, he can't remember the incident in whole.
"He never said anything about buying it from a local man."
That statement appeared to contradict comments made later by the police chief, who told reporters at a press conference that Mr Murphy had bought the substance on the street. The police chief suggested though that Mr Murphy did not know what he was purchasing when he allegedly bought it.
"He doesn't know if it was drug or not," Mr Sumara said.
Desi Widyantari, another lawyer representing the 18-year-old, said he was not fully alert while he was searched and detained, using an Indonesian term "setengah sadar" which can mean drunk or half-conscious.
"The item ... was just suddenly there, he wasn't fully aware [of the incident]," Ms Widyantari said. "Hopefully the problem can be resolved quickly."
Police had initially believed the package of white powder, allegedly found in the Perth teen's bag, was cocaine or heroin.
The Sky Garden nightclub apologised on Wednesday for the "excessive force" that was used on Mr Murphy when he was allegedly found with a packet of white powder.
The 18-year-old's parents left Perth on Wednesday morning and arrived in Denpasar about noon local time (3pm AEDT).
Foreign Affairs Minister Julie Bishop told media early on Wednesday that Mr Murphy could be held for three days while an investigation took place and another three days while a decision was made about whether or not to arrest him.
Australian consular staff visited Mr Murphy for about 20 minutes on Wednesday morning. They made no comment.
Mr Murphy had been detained since early on Tuesday morning, after security staff at a nightclub allegedly found the powder during a search.
Security cameras at the Sky Garden nightclub in Kuta captured the teen casually walking up to two guards at the front of the club at 12.46am.
The Perth resident raised his arms slightly, so one of the guards could pat him down.
It was a routine body check, the nightclub management said in a statement, but what allegedly followed began an ordeal that would involve police and consular officials.
In the footage, Mr Murphy appears to unzip the bumbag he is wearing so the security guard can search it.
The guard appears to pull an object from the bag and show it to Mr Murphy, before another security guard joins them.
Mr Murphy is shown gesturing with his arms, before he is led away.
In a statement to Fairfax Media, Sky Garden management said the security guards had discovered a plastic bag containing a white powder that they suspected contained narcotics.
"Our security escorted the western male to meet the security chief on the second level; the security chief then instructed our security staff to bring him to the mobile police station located at the Bali Monument."
That mobile police station is less than 50 metres from the nightclub, and staff walked him there.
"Upon arriving at the mobile police station, our security were ordered to re-enact the sequence of events that had transpired; at this time news media were already stationed [at the location]."
Mr Murphy was then taken to a nearby police station for further questioning, according to the statement.
"Our policy is to inspect all guests for weapons and drugs, in order to prevent anyone from passing them on to innocent [or] unsuspecting victims," the club's management said.
"On a final note, we are deeply saddened by last night's events and we want to ensure all the parents at home in Australia that their children's safety is our top concern.
"We have faith that the local police will conduct a fair investigation.
"We hope for a quick and peaceful resolution to this matter."