Have you considered something like existing dirt-eating worms? The tailings move out as it goes, the animal essentially filtering the dirt in-place. Worm castings are valuable to gardeners, whether locally produced or introduced as a fertilizer.
Bird and bat guano is quarried and sold, as fertilizer.
I'm thinking thag (1) the excrement could be a valuable resource, and (2) it could be rather different from what we normally think of.
It would be a more interesting story if it wasn't a mundane solid blob of waste remaining from what was eaten. What if it was all magicly transformed, but not all kept for use? The excrement could be gems made by the digestive system from base rock, or it could be expanding foam that makes a good building material, or something like volcanic pumice only with residual magical properies as well.
Let me run with that: after consuming several tons of rock that is magicly stored in the digestive system without taking up much space or adding weight to the animal, he moves to the edge of his territory and excretes a blob that is initially the size you expect from an animal that size, but is the color of magic and potently magical: touching it causes awful death from uncontrolled magic applied to the body in random ways, and the fumes can cause magical effects too.
The material quickly developes a stable coporial form that's like tar or melted glass, but is only mildly hot, and no longer deadly with uncontrolled magic. Then, gas produced inside the mass makes it expand into a huge quantity of mukti-colored foam, and after a day or so the material hardens and is like foamed rock or glass, exactly what depending on what was eaten (both base minerals and magical gems). It is like pumice or slag, but also has some residual magic, and a skilled practitioner can guide it to various useful magical properties as it cures. This can be enchanted building material, with other uses developed over time.
The dragons use it to make lairs and nests like termites, and can control the magic cureing process to that end.
The dragon guano craftsmanship is very dangerous, as working with it early in its wild state gives more potential, and accidents happen. Occasionally random magic has some strange effect nearby. So, the craftsmen also arrange various items around the work arena: staues of dieities, amulets, totems, and blank paper. Once or twice a year an anomolous discharge enchants one of thes objects which acts as a lightning rod: the wild formless magic is guided by the nature of the magical item it is to produce, rather than doing something completely random. And, the charmed item, if identified, can be a valuable by-product.
Just as ancient dye makers (strong bases), felt makers (mercury), and even washer-women (lye vapors) had characteristic occupational hazards, so do the scatmorphers.