Create a Stripe accountIf you don’t have a Stripe account yet, create one for free by following the instructions on this link: https://dashboard.stripe.com/register.
Register your platform and find your application client_id
Go to the Stripe Connect settings page and fill in the information in the Standalone accounts section.
Then, take a note of the client_id values presented for the Development and Production sections, you will need them later.
Setup the example OAuth client
You can setup an OAuth client in your server with your favorite language and framework. If you don’t have an OAuth library to use, you can use the simple examples provided by Stripe, which is what we will use as an example in these instructions.
Take a look at the OAuth Sample Applications section in the Stripe Documentation and find an example for the language of your choice. Please note the complete examples for each language are available as Gist pages.
Follow all the instructions in the code comments, and replace the constants for the client id with the value you got in the last step, and the api key with the secret key you can find in your API Settings page in your Stripe Dashboard. Please note you should use the Production client id together with the Live secret key.
To setup the test environment, repeat this step, making a copy of the file, using a different the file name and routing location, and replacing the appropriated Development client id and Test secret key.
Let us and Stripe know about your OAuth application url
Once you publish your OAuth clients for production and development, take a note at the address where they are located (which varies depending on the language of your choice). Make sure this urls are working properly. When opening them with your browser, you should see a simple link that says “Connect with Stripe”.
Go back to the Stripe Connect settings page and enter the respective OAuth application urls in the Redirect URIs fields for Development and Production.
Then, send the same urls to us by our email firstname.lastname@example.org.
Verify if our account is connected
After sending us your OAuth url, we will connect our Make My Donation account to your Stripe platform and get back to you once the process is finished. Make sure our account is connected by going to the Connected accounts page in your Stripe Dashboard.
Use the View Test Data switch at the left bar so you can check both the Production and Development data.
Also in this page you can find our Stripe account id which is right next to our account email and you will need it later to create charges.
Create charges on your platform
After the setup is complete, you can use the regular Stripe API to collect a payment. For more information on creating direct charges see the Stripe Documentation for Direct Charges for connected accounts. Follow the examples for the language of your choice and replace the connected account id with the account id you found in the previous step, and the API secret key with your own key that you can find in the API Settings page (you can switch between test and live keys once you have setup both the Development and Production environments).
For a more extensive documentation on Stripe Charges you can refer to the Stripe API Documentation for Charges.
Required Meta Data
When processing transaction on behalf of Make My Donation, please be sure to provide the required Meta data with each transaction. Click here to learn more about Make My Donation's Meta data requirements.