You'll have to set up a website with PHP/SQL scripts. I doubt you know how to do that if you don't know how to make an auto-purchasing system already.
Your best bet is to pay someone to make it for you. Until you either make it yourself or pay someone else to make it, you'll just have to deal with either learning PHP/SQL, or selling things manually.