Economists have studied the question of value basically since the founding of economics. Many ideas have been proposed and rejected. The one you are probably subscribing to is something like Marx's "Labor theory of value".
I could write an argument explaining why the labor theory of value is wrong, but you can just read the Criticisms section on Wikipedia, which will do a better job of it than I could:
https://en.wikipedia.org/wiki/Labor_theory_of_value#Criticis...
If you want to assert that some job is "under paid", you have to have a reference valuation that the current compensation is "under" with respect to. The perspective of modern economists is that value comes from "marginal utility":
https://en.wikipedia.org/wiki/Marginalism
Here is a list of common value theories from the history of economics: