When a party to any suit pending in any court of record in this state shall make application to such court in term time, or to the judge thereof in vacation, for a commission to take the examination of witnesses, and shall support the application by affidavit, and shall have given to the adverse party reasonable notice of such application, the court or judge may, upon such terms as it may think proper, award such commission.
§ 492.220, RSMo