Skip to content
Python plugin for Paystack
Python
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
docs
paystackapi
.gitignore
.python-version
.travis.yml
LICENSE
README.md
requirements.txt
setup.py

README.md

paystack-python

Coverage Status Scrutinizer Code Quality Circle CI Build Status PyPI version

Python plugin for Paystack View on pypi.python.org

Installation

pip install paystackapi

Instantiate Paystack

from paystackapi.paystack import Paystack
paystack_secret_key = "5om3secretK3y"
paystack = Paystack(secret_key=paystack_secret_key)

# to use transaction class
paystack.transaction.list()

# to use customer class
paystack.customer.get(transaction_id)

# to use plan class
paystack.plan.get(plan_id)

# to use subscription class
paystack.subscription.list()

DOC Reference: https://developers.paystack.co/v2.0/reference

Other methods can be found in the docs folder

Static Use

To start using the Paystack Python API, you need to start by setting your secret key.

You can set your secret key in your environment by running:

export PAYSTACK_SECRET_KEY = 'your_secret_key'

Don't forget to get your API key from Paystack and assign to the variable PAYSTACK_SECRET_KEY

Available resources

BulkCharge
Charge
ControlPanel
Customer
Invoice
Misc
Page
Plan
Product
Refund
Settlement
SubAccount
Subscription
Transaction
TransferControl
Transfer
TransferRecipient
Verification

Please reference the docs folder for usage,

You can’t perform that action at this time.