How do you have in app purchases in c++?

i want to make a app store but don’t know how to put in purchasing things with actual money and how can i have it download files?