If you paid anyone for a referral/lead only if it closed it would violate RESPA. You can't pay for referrals. You can buy general leads, but you can't just pay for those that close.
http://www.hud.gov/offices/hsg/sfh/res/respamor.cfm#HT " Section 8 of RESPA prohibits a person from giving or accepting any thing of value for referrals of settlement service business related to a federally related mortgage loan. It also prohibits a person from giving or accepting any part of a charge for services that are not performed. "
Section 8: kickbacks, fee-splitting, unearned fees
Section 8 of RESPA prohibits anyone from giving or accepting a fee, kickback or any thing of value in exchange for referrals of settlement service business involving a federally related mortgage loan. In addition, RESPA prohibits fee splitting and receiving unearned fees for services not actually performed.
Violations of Section 8's anti-kickback, referral fees and unearned fees provisions of RESPA are subject to criminal and civil penalties. In a criminal case a person who violates Section 8 may be fined up to $10,000 and imprisoned up to one year. In a private law suit a person who violates Section 8 may be liable to the person charged for the settlement service an amount equal to three times the amount of the charge paid for the service.