The basis for your question is a typical category confusion. namely, believing that in world where magic exists it bends the laws of nature. Magic will be part of nature.
Since science is the study of nature. Natural philosophers, the name scientists had before the name of scientist was invented, will observe and conduct experiments into nature. They observe certain natural phenomena behave in certain ways when magic isn't involved and different ways when magic is involved.
In the historical past of our world there existed a category of phenomena they called 'natural magic'. Usually this was electrostatics and magnetism. Getting small electrical shocks from rubbed cat's fur and seeing compass needles swinging to the North must have seemed magical.
In your world where magic is part of nature, science will incorporate nature as we know it, and nature where magic is involved. Nature and magic will be one and the same thing. Science is the study of nature. The science will be more magical than the science of our world.
The application of science combined with magic is basically technology. Please note: magic has always been a technology. It is intended to do useful things, either for good or ill.
When magic is part of nature it should definitely follow laws of nature similar to those in our world. So, yes, there could be a thermodynamics of magic. How this would work will involve thinking how a process works in our world. How entropy applies, forces, conservation of matter and energy, etc etc, but with a magical component that follows exactly equivalent laws of nature.