Earthworms play a role in the global cycling of carbon, nitrogen, phosphorus, and organic matter. They accumulate metals, they aerate the ground, and aid water drainage to it. The earthworm can grow up to 30 cm long. It occurs worldwide but there are many different species. Simply described, the earthworm consists of two tubes inserted into one another: the skin muscle tube with its longitudinal and circular muscles and the intestinal canal.
Lumbricidae earthworms (the common European earthworms) pull leaves into their tube system by sucking on a leaf. The worms release a secretion containing amylase from the pharyngeal glands. This moistens the leaf and promotes its decomposition process. The decomposition is done by fungi and bacteria. With sucking and pumping movements of the mouth, the decomposed food is then eaten by the worms. This process brings fungi, bacteria, and small particles of earth into the digestive tract of the worm. The humus of the top layers of earth has gone through the earthworms.
In the muscular, hard-walled stomach, the rotted plant remains are rubbed between mineral particles that have been taken up with the food. In the intestine, various enzymes and microorganisms help to break up and digest the food.
 James D. Robertson, The Function of the Calciferous Glands of Earthworms, J. Experim. Biol. 1936, 13, 279–297. Link
 Manuel Liebeke, Nicole Strittmatter, Sarah Fearn, A. John Morgan, Peter Kille, Jens Fuchser, David Wallis, Vitalii Palchykov, Jeremy Robertson, Elma Lahive, David J. Spurgeon, David McPhail, Zoltán Takáts, Jacob G. Bundy, Unique metabolites protect earthworms against plant polyphenols, Nat. Commun. 2015. https://doi.org/10.1038/ncomms8869