The actions depend upon intentions.
Intention are based on their purity (ikhlaas) of purpose.
Only that purity is acceptable that is in the purview of the matter (mas-ala ).
(Note : A person says that , "O Lord make me successful in this business with interest, I shall offer you half of the earnings", then this has purity of purpose but is, nevertheless, unacceptable because it is not in the perview of matter.)
(Part of a pamphlet prepared by a disciple)