Skip to content

SparkPost/appengine-std-python-sample

Repository files navigation

Sign up for a SparkPost account and visit our Developer Hub for even more content.

This sample app demonstrates how to send email with Python and python-sparkpost on the Google App Engine standard environment.

Prerequisites

Setup

  1. Sign up for a SparkPost account here.

  2. Create an API key with Transmissions: read/write privilege here.

  3. Add your API key to app.yaml.

  4. Install the app's dependencies:

    mkdir lib
    pip install -r requirements -t lib

Running Locally

  1. Run the app using the Google Cloud SDK dev app server:

    $GCLOUD_SDK/bin/dev_appserver.py app.yaml
  2. Visit the app in your browser: http://localhost:8080/

Deploying To Google App Engine

  1. Deploy the app and dependencies to your Google Cloud project:

    gcloud app deploy
  2. Visit the app in your browser:

    gcloud app browse

Running The Tests

pip install pytest responses flaky
pytest main_test.py

About

Sample app using Python, Flask and SparkPost in the Google App Engine standard environment

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •