how do I know what number the IRS reports to Social Security for earned income, for people receiving social security

If I get social security and work as contractor what is the formula for my earned income for  social security?

They told me it is not as simple as gross minus expenses.  And there is some formula I need to get and that I need to report the number to them  monthly so that it does not exceed 1950.

Please help me.