Muffled giggles broke out in an otherwise hushed courtroom when prosecutors played a rap video made by two drug company sales representatives in 2015.

“Insys Therapeutics, that's our name. We’re raising the bar and we’re changing the game,” the two sales reps rap to a strong beat, singing about getting patients on the highest possible dose of their company’s opioid painkiller.

For almost two months, five former executives and managers at Insys Therapeutics have been on trial in Boston’s federal courthouse. According to other executives who have pleaded guilty, the pharmaceutical company bribed doctors to prescribe their opioid painkiller and lied to insurance companies to get it approved. The executives on trial have pleaded not guilty and say they weren’t aware of the illegal schemes.

Regardless of where blame lies in this particular instance, the trial is raising broader questions about exactly what drug company and their sales reps are — and are not — allowed to do.

What’s Allowed And What’s Not

Aaron Kesselheim, a physician and professor at Harvard Medical School, studies the pharmaceutical industry — and the regulations governing it. In terms of drug sales and promotions, he said, it all goes back to the Federal Food, Drug, and Cosmetic Act and rules set out by the Food and Drug Administration.

However, Kesselheim said, “there aren’t a lot of hard and fast rules.”

Drug reps, for example, can pay physicians to give lectures about their drug. In fact, Kesselheim deemed that “a very common strategy.”

How about paying for travel, perhaps to a conference in Hawaii or a meeting in Las Vegas? Kesselheim said that's also common, although he added, “In past years, there were much more extravagant travel arrangements made. Those really fancy excursions may have fallen by the wayside.”

Drug company sales reps can also minimize discussion of the drug’s risks. “We’ve seen numerous examples of that come up,” Kesselheim said.

Reps can also get higher bonuses if doctors prescribe the medication in higher doses. Kesselheim said this is "technically legal,” adding that sales reps’ bonuses can be tied either to the number of prescriptions or to the dosage of the prescriptions.

Another common and legal tactic? Free drug samples.

“Free drug samples are often used to try to get a patient accustomed to using a brand name drug, so that they will then fill a prescription for a brand name drug in the future – as opposed to using a lower-cost generic drug that may work just as well,” Kesselheim said.

Can drug reps promote off-label uses of their product?

“Technically, that is not allowed,” said Kesselheim. “Now, there are various loopholes.” Sales reps can respond to questions about off-label use and they can hand someone a journal article about off-label use.

There are things Insys Therapeutics allegedly did that are strictly not allowed. A lap dance for a physician who writes lots of prescriptions is one example. Lying to insurance companies and creating a phony speaker’s series — where almost nobody shows up to the lectures but doctors get paid big sums — are also illegal.

But, Kesselheim said, drug companies have learned to break what few rules there are, since the fines are often a lot smaller than the profits they reap in sales.

From a public policy perspective, Kesselheim said the trend is toward reducing the regulations that are in place. However, some large academic medical centers have created their own policies around how their physicians interact with drug companies. In many instances those rules and polices are stricter than the code of conduct put out by the industry trade group Pharmaceutical Research and Manufacturers of America (PhRMA).

In Massachusetts, there used to be a limit on how much could be spent on meals between pharma reps and doctors. But Kesselheim said that changed “a few years ago when the Massachusetts law was overturned as a result of combined lobby from the pharmaceutical industry and the restaurant industry, which was concerned about losing patrons to restaurants in New Hampshire and Connecticut.”

Does It Matter If Drug Reps Market To Doctors?

At the end of the day, does this really matter? Is it a problem that drug sales reps meet with physicians to wine, dine, educate and sell their product?

Thomas Stossel — the author of "Pharmaphobia: How the Conflict of Interest Myth Undermines American Medical Innovation" — says no.

“There's really no smoking gun there. In my opinion, it is way overblown," he said. Stossel, who recently retired as a physician at Brigham and Women's Hospital, thinks drug companies deserve more credit than they get.

“Healthcare is so much better today than it was when I started out, and it’s almost entirely due to the efforts of the medical products industry – diagnostics, devices, drugs,” he said.

Developing drugs takes a lot of work and money, he said, and he worries that too many rules and too much scrutiny around marketing could hinder future drug development.

Stossel — who has consulted for drug companies — said drug reps play an important role in educating doctors about new medications. He dismissed the idea that doctors cannot distinguish between valuable information and a sales pitch as “insulting [to] your intelligence, your integrity, your training.”

There is plenty of data, though, that show that after a drug rep visits a doctor’s office — a practice known as detailing — there are higher rates of prescribing their product.

Stossel said that makes sense, because a doctor has learned about something new that’s available and effective.

Matthew McCoy, a medical ethicist at the University of Pennsylvania, disagrees. He wants to see doctors making decisions based on unbiased evidence, not a sales pitch.

"It doesn’t take a very sizable gift — something as small as a free lunch — to see an association with higher rates of prescribing,” said McCoy. A recent study found just about half of the doctors in the country have accepted something from the industry.

“Even when people are aware that they might be influenced by these types of marketing activities, they are still influenced by them. So really the only way to eliminate the threat of bias from interactions with pharmaceutical marketers is to limit those interactions.”

McCoy said he would like to see physicians getting their information from journal articles and professional associations — sources that do not have a financial interest in what doctors prescribe.

What Can Patients Do?

If a patient wants to know whether their doctor has a relationship with any pharmaceutical companies, they can look at a database that was created under Obamacare.

The free, online database, calledOpen Payments Data, provides information about which doctors have received money or gifts from drug companies in the past few years. It details how much, in what form and from whom.

The data only goes back to midway through 2013 but, in that time, it documents over $33 billion changing hands between Big Pharma and physicians and hospitals.