# paystack-python
[![Coverage Status](https://coveralls.io/repos/github/andela-sjames/paystack-python/badge.svg?branch=develop)](https://coveralls.io/github/andela-sjames/paystack-python?branch=master)
[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/andela-sjames/paystack-python/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/andela-sjames/paystack-python/?branch=master)
[![Circle CI](https://img.shields.io/badge/license-MIT-blue.svg)](https://img.shields.io/badge/license-MIT-blue.svg) [![Build Status](https://travis-ci.org/andela-sjames/paystack-python.svg?branch=master)](https://travis-ci.org/andela-sjames/paystack-python)
[![PyPI version](https://badge.fury.io/py/paystackapi.svg)](https://badge.fury.io/py/paystackapi)
Python plugin for [Paystack](https://paystack.com/)
View on [pypi.python.org](https://pypi.python.org/pypi/paystackapi)
## Installation
```shell
pip install paystackapi
```
## Instantiate Paystack
```python
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>
### API Reference: [API](https://paystack.com/docs/api/)
### 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:
```bash
export PAYSTACK_SECRET_KEY = 'your_secret_key'
```
> Don't forget to get your API key from [Paystack](https://paystack.com/) and assign to the variable `PAYSTACK_SECRET_KEY`
### Available resources
```Python
BulkCharge
Charge
ControlPanel
Customer
Invoice
Misc
Page
Plan
Product
Refund
Settlement
SubAccount
Subscription
Transaction
TransferControl
Transfer
TransferSplit
TransferRecipient
Verification
```
Please reference the **[docs](https://github.com/andela-sjames/paystack-python/tree/master/docs)** folder for usage,
Raw data
{
"_id": null,
"home_page": "https://github.com/andela-sjames/paystack-python",
"name": "paystackapi",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "paystack python library",
"author": "Samuel James and Issa Jubril",
"author_email": "samuelvarejames@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/76/80/7025cfa31227486c4fef75fb6bb1f81db04a16e0c14e57741026d82c5387/paystackapi-2.1.1.tar.gz",
"platform": null,
"description": "# paystack-python\n\n[![Coverage Status](https://coveralls.io/repos/github/andela-sjames/paystack-python/badge.svg?branch=develop)](https://coveralls.io/github/andela-sjames/paystack-python?branch=master)\n[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/andela-sjames/paystack-python/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/andela-sjames/paystack-python/?branch=master)\n[![Circle CI](https://img.shields.io/badge/license-MIT-blue.svg)](https://img.shields.io/badge/license-MIT-blue.svg) [![Build Status](https://travis-ci.org/andela-sjames/paystack-python.svg?branch=master)](https://travis-ci.org/andela-sjames/paystack-python)\n[![PyPI version](https://badge.fury.io/py/paystackapi.svg)](https://badge.fury.io/py/paystackapi)\n\nPython plugin for [Paystack](https://paystack.com/)\nView on [pypi.python.org](https://pypi.python.org/pypi/paystackapi)\n\n## Installation\n\n```shell\npip install paystackapi\n```\n\n## Instantiate Paystack\n\n```python\nfrom paystackapi.paystack import Paystack\npaystack_secret_key = \"5om3secretK3y\"\npaystack = Paystack(secret_key=paystack_secret_key)\n\n# to use transaction class\npaystack.transaction.list()\n\n# to use customer class\npaystack.customer.get(transaction_id)\n\n# to use plan class\npaystack.plan.get(plan_id)\n\n# to use subscription class\npaystack.subscription.list()\n```\n\n## DOC Reference: <https://developers.paystack.co/v2.0/reference>\n\n### API Reference: [API](https://paystack.com/docs/api/)\n\n### Other methods can be found in the docs folder\n\n### Static Use\n\nTo start using the Paystack Python API, you need to start by setting your secret key.\n\nYou can set your secret key in your environment by running:\n\n```bash\nexport PAYSTACK_SECRET_KEY = 'your_secret_key'\n```\n\n> Don't forget to get your API key from [Paystack](https://paystack.com/) and assign to the variable `PAYSTACK_SECRET_KEY`\n\n### Available resources\n\n```Python\n\nBulkCharge\nCharge\nControlPanel\nCustomer\nInvoice\nMisc\nPage\nPlan\nProduct\nRefund\nSettlement\nSubAccount\nSubscription\nTransaction\nTransferControl\nTransfer\nTransferSplit\nTransferRecipient\nVerification\n\n```\n\nPlease reference the **[docs](https://github.com/andela-sjames/paystack-python/tree/master/docs)** folder for usage,",
"bugtrack_url": null,
"license": "MIT",
"summary": "A python library to consume Paystack API",
"version": "2.1.1",
"project_urls": {
"Homepage": "https://github.com/andela-sjames/paystack-python"
},
"split_keywords": [
"paystack",
"python",
"library"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "76807025cfa31227486c4fef75fb6bb1f81db04a16e0c14e57741026d82c5387",
"md5": "ebc322161100a91bab884f104f3f56ba",
"sha256": "00bb7e58089efce7ff1a650be6359259b4cfeff4eed7a2a6e3cc3c5f46b86814"
},
"downloads": -1,
"filename": "paystackapi-2.1.1.tar.gz",
"has_sig": false,
"md5_digest": "ebc322161100a91bab884f104f3f56ba",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 18972,
"upload_time": "2023-12-08T20:07:22",
"upload_time_iso_8601": "2023-12-08T20:07:22.701827Z",
"url": "https://files.pythonhosted.org/packages/76/80/7025cfa31227486c4fef75fb6bb1f81db04a16e0c14e57741026d82c5387/paystackapi-2.1.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-12-08 20:07:22",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "andela-sjames",
"github_project": "paystack-python",
"travis_ci": true,
"coveralls": false,
"github_actions": false,
"requirements": [
{
"name": "args",
"specs": [
[
"==",
"0.1.0"
]
]
},
{
"name": "certifi",
"specs": [
[
"==",
"2019.6.16"
]
]
},
{
"name": "chardet",
"specs": [
[
"==",
"3.0.4"
]
]
},
{
"name": "clint",
"specs": [
[
"==",
"0.5.1"
]
]
},
{
"name": "coverage",
"specs": [
[
"==",
"4.0.3"
]
]
},
{
"name": "coveralls",
"specs": [
[
"==",
"1.1"
]
]
},
{
"name": "curdling",
"specs": [
[
"==",
"0.4.0"
]
]
},
{
"name": "distlib",
"specs": [
[
"==",
"0.1.2"
]
]
},
{
"name": "docopt",
"specs": [
[
"==",
"0.6.2"
]
]
},
{
"name": "docutils",
"specs": [
[
"==",
"0.12"
]
]
},
{
"name": "funcsigs",
"specs": [
[
"==",
"0.4"
]
]
},
{
"name": "httpretty",
"specs": [
[
"==",
"0.8.14"
]
]
},
{
"name": "idna",
"specs": [
[
"==",
"2.7"
]
]
},
{
"name": "m2r",
"specs": [
[
"==",
"0.2.1"
]
]
},
{
"name": "mistune",
"specs": [
[
"==",
"0.8.4"
]
]
},
{
"name": "mock",
"specs": [
[
"==",
"1.3.0"
]
]
},
{
"name": "pbr",
"specs": [
[
"==",
"1.8.1"
]
]
},
{
"name": "pkginfo",
"specs": [
[
"==",
"1.4.2"
]
]
},
{
"name": "requests",
"specs": [
[
"==",
"2.20.0"
]
]
},
{
"name": "requests-toolbelt",
"specs": [
[
"==",
"0.8.0"
]
]
},
{
"name": "simplejson",
"specs": [
[
"==",
"3.8.2"
]
]
},
{
"name": "six",
"specs": [
[
"==",
"1.10.0"
]
]
},
{
"name": "sure",
"specs": [
[
"==",
"1.2.24"
]
]
},
{
"name": "tqdm",
"specs": [
[
"==",
"4.25.0"
]
]
},
{
"name": "twine",
"specs": [
[
"==",
"1.11.0"
]
]
},
{
"name": "urllib3",
"specs": [
[
"==",
"1.26.5"
]
]
}
],
"lcname": "paystackapi"
}