Steps and Sample Code for Purchasing RI via API