/tchack2016

Primary LanguageCSSMIT LicenseMIT

Braintree Flask Example

Build Status

An example Braintree integration for python in the Flask framework.

Setup Instructions

  1. Install requirements:
pip install -r requirements.txt
  1. Copy the example.env file to .env and fill in your Braintree API credentials. Credentials can be found by navigating to Account > My User > View Authorizations in the Braintree Control Panel. Full instructions can be found on our support site.

  2. Start server:

python app.py

Deploying to Heroku

You can deploy this app directly to Heroku to see the app live. Skip the setup instructions above and click the button below. This will walk you through getting this app up and running on Heroku in minutes.

Deploy

Running tests

Unit tests do not make API calls to Braintree and do not require Braintree credentials. You can run this project's unit tests by calling python test_app.py on the command line.

Pro Tips

Help

Disclaimer

This code is provided as is and is only intended to be used for illustration purposes. This code is not production-ready and is not meant to be used in a production environment. This repository is to be used as a tool to help merchants learn how to integrate with Braintree. Any use of this repository or any of its code in a production environment is highly discouraged.