A Phoenix Maryvale Precinct patrol officer faces multiple felony charges after an investigation revealed he was stealing from drug dealers, the police department announced Friday.

James Wren, 23, who joined Phoenix police two years ago, was arrested late Thursday as part of an undercover sting. He was booked on suspicion of conspiracy, attempted theft, attempted money laundering and aiding a criminal syndicate.

Prior to Thursday's sting, Wren is believed to have taken nearly $40,000 in drug cash in two cases since 2008. He resigned Thursday after admitting to involvement in three incidents, according to police. Wren is accused of working with friends from outside the police department to divvy up the money after making unreported traffic stops on couriers, who he would rob of drug money and release without making an arrest, police said.

No other officers are believed to be involved, though Wren is accused of stealing from drug dealers on duty while in uniform and in a fully-marked city patrol vehicle.

Investigators learned about the heists through a drug dealer arrested last week by Avondale police in an unrelated case, police said. Internal affairs detectives worked with others from drug-enforcement and SWAT to arrest Wren during a sting.

Phoenix Police Chief Jack Harris said Wren's actions "shamed the police department, the badge and the profession." He credited his department for arresting Wren within one week of learning about his involvement in "drug money rip offs from others involved in the narcotics business."

Harris, a Maryvale native who began his career patrolling west Phoenix, said he recalled a drug-enforcement officer who faced charges nearly 10 years ago in a similar investigation, though such cases of misconduct are rare.

"I think this is all positive from the perspective that it shows that our policies and procedures are very appropriate, and that we take immediate action when something like this happens," Harris said. "To put together a complex investigation like this and bring this person to justice in just seven days, I think is indicative of how our department upholds our standards."

Harris added that investigators found little in Wren's background check and hiring process that showed any indication of being prone to misconduct.

The people Wren is accused of conspiring with included people he knew before becoming a police officer. However, police said no further arrests were planned.

On Thursday, investigators baited Wren into a traffic stop where he was tempted with $40,000 of what he believed to be drug money for an upcoming transaction, according to investigators.

Wren made the traffic stop in the 6300 block of West McDowell Road before he became suspicious, disengaged, and drove to a Laveen police precinct where he was arrested, police said.

The officer is not accused of stealing drugs. Phoenix police Sgt. Tommy Thompson, a department spokesman, said Wren's aim was "not to arrest, not to impound the money, but to take the money for personal gain."

Wren comes from a law enforcement family. His father is a retired Phoenix police sergeant and has three other family members, both civilian and sworn, employed by the department.