Specifically, female cochineals. Europeans also used it as a dye, and as a coloring agent for food and beverages.
I just started reading the landmark 1820 British tome "A Treatise on Adulterations of Food, and Culinary Poisons Exhibiting the Fraudulent Sophistications of Bread, Beer, Wine, Spiritous Liquors, Tea, Coffee, Cream, Confectionery, Vinegar, Mustard, Pepper, Cheese, Olive Oil, Pickles, and Other Articles Employed in Domestic Economy", by Fredrick Accum (from Gutenberg.org)
Slow going, because of both the prose and antiquated terms. About a quarter of the unfamiliar words aren't recognized by my ereader's wimpy dictionary.
From other readings, it wasn't until 1860 that British Parliament finally got around to passing a decent food act.
Red lead was a popular additive. And brick dust. And alum was used to salvage spoiled flour...
Even the equivalent of ipecac syrup wasn't below being adulterated.
To be fair, vegetable starches (corn, tapioca, potato) were added to to make products better, in addition to cheating the consumer.
It was this book that led to the creation of the Co-Operative movement in Britain, who started milling and selling their own flour, to the members of their co-Operative.