See an entry from Charles Scholl, Geroge Mcaulaly et al's "A Phraseological Dictionary of Commercial Correspondence in the English, German, French & Spanish Languages, with an Appendix Containing Lists of Commercial Abbreviations, Geographical Names, the Principal Articles of Commerce", published in 1891:
"Needful: he will do what is needful under the circumstances. We rely on your doing the needful for the protection of our interests. With which will you please do the needful. With which we shall do the needful, and credit you for the amount in due course. I shall do the needful at maturity. I enclose draft for 100 pounds at two months, to which I will thank you to do the needful"
Another entry from a law journal published in 1833 in UK: "The letter was immediately given by the bankrupt to the defendant, with directions that as the voyage was altered, he, the defendant, would do the needful."