• Stars
    star
    119
  • Rank 296,130 (Top 6 %)
  • Language
    JavaScript
  • License
    MIT License
  • Created about 12 years ago
  • Updated about 7 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A simple Django app that collects and displays Stripe data.

A simple Stripe Dashboard

Stripe is awesome. Metrics are awesome. So let's do this!

Try it.

Go check out a live, working version with OAuth at http://board.zapier.com/. Your data is in cache and sticks around for 24 hours, then you'll need to refresh it (we do not refresh it for you automatically).

A sample dashboard for illustration.

some made up numbers for example!

Heads up!

Trying to distill this information from Stripe's API is actually a bit tricky since we don't have a history of logged events (and downloading your entire Stripe DB via their API is not cool). So, we do our best to approximate it with a mixture of current customer snapshots, subscription update and deleted events. If you have a clever way to do this better, we want to see it added!

Run it.

Well, first you need a Stripe application. You can read about that at https://stripe.com/docs/apps/oauth.

Heroku

Heroku makes this easy if you follow the docs found at https://devcenter.heroku.com/articles/django. Below are some of the fancier things you'll need to do first to get it running...

You'll need the Redis To Go addon in Heroku:

# free version
heroku addons:add redistogo:nano

Here are some extra commands:

# your s3 config information
heroku config:add AWS_ACCESS_KEY_ID=xxx
heroku config:add AWS_SECRET_ACCESS_KEY=xxx
heroku config:add AWS_STORAGE_BUCKET_NAME=xxx
# a random secret key for django
heroku config:add SECRET_KEY=xxx
# the application's id "ca_*"
heroku config:add STRIPE_CLIENT_ID=xxx
# the account api key "*"
heroku config:add STRIPE_CLIENT_SECRET=xxx

And don't forget to scale out at least one worker:

# will cost you money...
heroku ps:scale celeryd=1

Local

Be sure to pip install -r requirements.txt and have Redis running locally.

Create a settings_local.py file like so:

DEBUG = True
TEMPLATE_DEBUG = DEBUG

DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.sqlite3',
        'NAME': 'stripeboard.sqlite',
        'USER': '',
        'PASSWORD': '',
        'HOST': '',
        'PORT': '',
    }
}

BROKER_URL = 'redis://localhost:6379/0'

CACHES = {
    'default': {
        'BACKEND': 'redis_cache.RedisCache',
        'LOCATION': 'localhost:6379',
        'OPTIONS': {
            'DB': 0,
            'PARSER_CLASS': 'redis.connection.HiredisParser'
        },
    }
}

SECRET_KEY = 'FILLMEIN!'

MEDIA_URL = '/media/'
STATIC_URL = '/static/'

STRIPE_TEST_API_KEY = 'ONLYFORTESTS...'

STRIPE_CLIENT_ID = 'ASTRING' # the application's id "ca_*"
STRIPE_CLIENT_SECRET = 'ASTRING' # the account api key "*"

And run foreman start after doing all the standard python manage.py syncdb stuff.

More Repositories

1

django-drip

πŸ’§ Use Django admin to manage drip campaign emails using querysets on Django's User model.
Python
636
star
2

django-rest-hooks

πŸ’Œ Add webhook subscriptions to your Django app.
Python
559
star
3

resthooks

A lightweight subscription notification layer on top of your existing REST API
HTML
551
star
4

django-knowledge

Add a help desk or knowledge base to your Django project with only a few lines of boilerplate code.
Python
490
star
5

email-reply-parser

πŸ“§ Email reply parser library for Python
Python
462
star
6

zapier-platform

The SDK for you to build an integration on Zapier
JavaScript
338
star
7

zapier-platform-cli

πŸ’» Build Zapier integrations and test locally using the JavaScript tools you already know.
JavaScript
259
star
8

kubechecks

Check your Kubernetes changes before they hit the cluster
Go
150
star
9

apollo-server-integration-testing

Test helper for writing apollo-server integration tests
TypeScript
134
star
10

Zapier-for-Alfred

An Alfred workflow to trigger Zaps
122
star
11

prom-aggregation-gateway

An aggregating push gateway for Prometheus
Go
112
star
12

google-yolo-inline

A demo of how to include Google One-tap sign up anywhere on your own site
HTML
90
star
13

node-resthooksdemo

A simple node.js RESTHooks demo built upon the Sails Web Framework
JavaScript
68
star
14

intl-dateformat

Format a date using Intl.DateTimeFormat goodness.
TypeScript
62
star
15

redux-router-kit

Routing tools for React+Redux
JavaScript
51
star
16

visual-builder

Learn how to use Zapier Visual Builder to create new Zapier integrations
HTML
49
star
17

django-rest-framework-jsonmask

Exposes Google Partial Response syntax in Django REST Framework
Python
46
star
18

react-element-portal

Blend React into your exising site by rendering elements inline, targeting an element by id.
JavaScript
34
star
19

zapier-platform-example-app-github

An example GitHub app for the Zapier platform.
JavaScript
27
star
20

tfbuddy

Terraform Cloud pull request alternate workflow
Go
26
star
21

preoomkiller-controller

Preoomkiller Controller evicts pods gracefully before they get OOMKilled by Kubernetes
Go
24
star
22

zapier-platform-core

πŸ”Œ The core Zapier platform library / SDK.
JavaScript
24
star
23

conspiracysanta.com

No longer maintained: A better secret santa for teams.
JavaScript
19
star
24

django-stalefields

No longer updated: Automatic .update() instead of .save() for models.
Python
19
star
25

litdoc

πŸ“ A simple Markdown-based 3-column documentation builder.
HTML
18
star
26

django-birdcage

Utilities for maintaining forwards compatibility with Django releases.
Python
15
star
27

zapier-platform-schema

πŸ“– The core Zapier Platform schema.
JavaScript
15
star
28

jsonmask

Implements Google Partial Response dictionary pruning in Python
Python
14
star
29

resthookdemo

A quick and easy demo application for rest hooks.
CSS
13
star
30

profiling-python-like-a-boss

Sample code for a Zapier engineering blog post
Python
13
star
31

zapier-platform-example-app-onedrive

An example Zapier Platform App that demonstrates a complete App using the OneDrive API
JavaScript
12
star
32

zapier-platform-example-app-rest-hooks

An example Zapier Platform App that demonstrates REST Hook Triggers
JavaScript
10
star
33

saasr

A SaaS subscription simulator - a tool to learn about the statistical mechanics of subscriptions
R
10
star
34

langchain-nla-util

Python
7
star
35

awsjavasdk

Boilerplate rJava Access to the AWS Java SDK
R
6
star
36

zapier-sugarcrm-box

No longer updated: A vagrant box to boot up an instance of sugarcrm for local testing
PHP
6
star
37

docker-brubeck

A simple Dockerfile for GitHub's Brubeck (StatsD-compatible metrics aggregator).
Shell
5
star
38

type-system-benchmarks

Benchmark several type systems and ways to build them (right now Typescript and Flow)
TypeScript
4
star
39

zapier-platform-example-app-files

An example Zapier Platform App that demonstrates file handling (stashFile and dehydrate).
JavaScript
4
star
40

redis-statsd

A simple script which pipes Redis statistics into StatsD
Python
4
star
41

eslint-plugin-zapier

🚿 A shareable version of the .eslintrc file used internally at Zapier.
JavaScript
4
star
42

zapier-platform-example-app-minimal

Zapier CLI Platform Minimal App
JavaScript
4
star
43

zapier-platform-example-app-session-auth

An example Zapier Platform App that demonstrates session authentication (username/password exchange for session key)
JavaScript
4
star
44

zapier-platform-example-app-custom-auth

An example Zapier Platform App that demonstrates custom authentication (API keys)
JavaScript
4
star
45

zapier-platform-example-app-oauth2

An example Zapier Platform App that demonstrates OAuth2
JavaScript
4
star
46

zapier-platform-example-app-trigger

An example Zapier Platform App that demonstrates Triggers
JavaScript
3
star
47

kairos

Python
3
star
48

zapier-platform-example-app-dynamic-dropdown

An example Zapier Platform App that demonstrates Dynamic Dropdowns
JavaScript
3
star
49

zapier-zapier-zapier-zapier-coffee-script

No longer updated: Zapier's very own CoffeeScript version which tweaks for our internal tools.
CoffeeScript
3
star
50

docker-proxysql

ProxySQL Docker images
Shell
2
star
51

zapier-platform-example-app-resource

An example Zapier Platform App that demonstrates Resources
JavaScript
2
star
52

nano-flux

No longer maintained: Tiny, simple flux lib.
JavaScript
2
star
53

zapier-platform-example-app-create

An example Zapier Platform App that demonstrates Creates
JavaScript
2
star
54

is-it-online

Wait for a URL to return 2XX, then show an OS notification and exit.
JavaScript
2
star
55

zapier-platform-example-app-microsoft-exchange

An example Zapier CLI app for MS Exchange
JavaScript
2
star
56

django-linttest

Lint Test is a simple Django app to perform flake8 linting on your project
Python
2
star
57

release-notes

an npm module for pulling merged PRs and generating release notes from them
TypeScript
2
star
58

babel-preset-zapier

🏯 A babel preset for Zapier
JavaScript
1
star
59

parquetr

Read/Write Parquet from R
R
1
star
60

docker-statsd

Run StatsD in a Docker container.
JavaScript
1
star
61

proxysql-benchmark

Benchmark proxysql
Python
1
star
62

docker-graphite

A simple Dockerfile that runs Graphite/Carbon (and nothing else!)
Shell
1
star
63

sentinel-graylog

A simple script which pipes Redis Sentinel messages into Graylog
Python
1
star
64

ecr-catalog-refresh

Simple sidecar to refresh a catalogfile from ECR
Python
1
star
65

zapier-platform-example-app-basic-auth

An example Zapier Platform App that demonstrates Basic Auth
JavaScript
1
star
66

diff-match-patch-cython

A quick hack that speeds up dmp by about ~3x.
Python
1
star
67

terraform-provider-opslevel

Terraform provider for OpsLevel.com
Go
1
star
68

zapier-platform-example-app-search

An example Zapier Platform App that demonstrates Searches
JavaScript
1
star