NEW DELHI — India has lodged a protest with the United States government after several Indian students were detained there in connection with their enrollment in a fake university, after an undercover operation.

The American authorities said this past week that they had indicted eight people accused of exploiting the country’s student visa system. They were said to have helped foreign nationals illegally remain in the United States by enrolling them into the University of Farmington in Farmington Hills, Mich., which billed itself as a “nationally accredited business and STEM institution” with an innovative curriculum, flexible class schedules and a diverse student body.

But the private university was being secretly operated by agents of the Department of Homeland Security to expose immigration fraud, according to federal prosecutors who announced charges in the case.

The Indian government said on Saturday that it had issued a rare “démarche” to the United States Embassy in New Delhi, telling it that Indian officials needed immediate consular access to the detainees.