A US court on Thursday sentenced a former Mexican state attorney general to 20 years in prison after he pleaded guilty to participating in an international drug trafficking ring.

Edgar Veytia, a dual citizen of the United States and Mexico, was arrested in March 2017 on suspicion of involvement in the production and trafficking of illegal drugs including heroin and cocaine into the United States starting in January 2013.

At the time of his arrest at the US border in San Diego he was the attorney general in Mexico's western state of Nayarit.

US authorities said Veytia used his prosecutor role to support activities of the H-2 Cartel -- an organized crime network with distribution cells throughout the US -- in exchange for bribes.

US officials also said he helped the cartel cover up the murder of a rival drug trafficker in 2015.

The Drug Enforcement Administration estimates that H-2 -- a violent cartel accused of torture and dozens of homicides -- distributed some 500 kilograms of heroin, 100 kilograms of cocaine, 200 kilograms of methamphetamine and 3,000 kilograms of marijuana into the United States between January 2013 and February 2017.

Nayarit is on Mexico's Pacific north coast and shares a border with the states of Jalisco and Sinaloa, where drug cartels hold a powerful grip.

The sentencing comes months after one of the world's most notorious drug lords, Joaquin "El Chapo" Guzman was sentenced to life in prison in a New York court.

"We warned that there were more days of reckoning to come," said US Attorney Richard Donoghue in a statement. "The sentence imposed on this corrupt Mexican government official makes this just such a day."