{ "info": { "author": "openpay", "author_email": "pythondev@openpay.com.au", "bugtrack_url": null, "classifiers": [ "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python :: 2", "Programming Language :: Python :: 3" ], "description": "## Python Openpay SDK\n\nThis module is created to achieve payment via. [_Openpay_](https://www.openpay.com.au/) from any web based platform \ncreated by *Python*. Every merchant can use this SDK for its clients to handle order creation to complete payment. \n\n\n### Installation\n\n```pip install python-openpay```\n\n### Creation of Merchant\nEvery _merchant_ object is created by using compulsory attribute **jam_auth_token**, **country_code** and along with other two non-mandatory attributes \nsuch as - **auth_token** and **openpay_url_mode** as follows:-.\n```python\nfrom openpay import Merchant\nmerchant= Merchant(jam_auth_token='your jam auth token',country_code=\"au or uk\" auth_token=None, openpay_url_mode=\"Live\")\n``` \nHere, **openpay_url_mode** is used to specify the mode of URL, such as \"_Live_\" or \"_Training_\". This is required for testing this SDK \nin **demo** or **production** purpose. \n\nNow a _merchant_ can set up _success_, _cancel_ and _failure_ urls for redirecting a client during or after payment through **openpay** \nas follows:-\n```python[]\nmerchant.set_callback_url(callback_url=val1, cancel_url=val2, failure_url=val3)\n```\n### fraud altert\nif any fraud is taking place corresponding to a plan id then merchant can call this following function\n\n```python\nmerchant.online_order_fraud_alert(plan_id=plan_id)\n``` \n**Note:** **This is not mandatory. It will only be called if fraud occurs**\n\n### Creation of Client\nA particular **merchant** has a set of **clients** for his site. So, when we create a _client_ object then we have to \nassociate a _merchant_ object with it. Possible ways to associate a _client_ with _merchant_ are as follows:-\n\n```python\nfrom openpay import Client\nclient = Client(merchant=merchant) # association with merchant\n ```\nLater, we can update a _client_ object using **demographic information** as follows(res for residential and del for delivery address):-\n ```python\nclient(first_name='openpay', family_name='test', email='testdevloper007@gmail.com', res_address_1='15/520 Collins Street',\nres_suburb='Melbourne', res_state='Victoria', res_postcode=3000, dob='06 Jan 1985')\n```\nAdd just add del_ suffix like ```del_address_1``` instead of ```res_address_1``` for ```address, suburb and state```.\n\nAnother way to create _client_ with two above steps in together as follows :\n```python\nclient = Client(first_name='Test', family_name='User', email='testdevloper007@gmail.com', address_1='15/520 Collins Street',\nsuburb='Melbourne', state='Victoria', postcode=3000, dob='06 Jan 1985', merchant=merchant)\n```\n**Note:** Here _```%b```_ *_Month as locale\u2019s abbreviated name. Jan, Feb, \u2026, Dec_*. So, any valid _date format_ should be \nlike '**06 Jan 1985**'. In addition, _postal code_ should be of length **4**. \n### Check if price is valid for payment(comes in min max range)\nBefore initiating order, need to check if price is valid with\n```python\nclient.is_valid_price(price=)\n```\nIf the status is True or error is blank in response then we can proceed further with the next call ```new_online_order```\n### Online order creation\nHere, _client_ is going to order one or more item(s) from _merchant_ site and param _purchase_price_ is the sum of\nitem(s) prices chosen by client.\n```python\nclient.new_online_order(purchase_price=, plan_creation_type=\"Pending\")\n```\nAfter successful execution, a **plan ID** is created for the _client_.\n### Check Min and Max purchase price \n```python\nclient.min_max_purchase_price()\n```\nThis method is used to check whether the _purchase_price_ is in the **minimum** and **maximum** price range of a\n_merchant_ or not.\n\n### Create online plan\n```python\nplan_link = client.create_online_plan(order_id= )\n```\nOpenpay provides all possible plans to pay _purchase_price_ for this _client_. Once a plan is chosen by _client_ then Openpay \nredirects him for payment.\n\n### Check payment and order status\nTo check payment and order status for a _client_, we should call below functions with **plan_id** as argument respectively.\n```python\nclient.check_payment_capture(plan_id=plan_id)\nclient.check_order_status(plan_id=plan_id)\n\n```\n### Create refund\nIf _merchant_ wants to create any **partial** refund for a plan then he has to set arguments _plan_id_ and \n_new_purchase_price_ as follows:-\n\n```python\nclient.refund_status(plan_id=plan_id, new_purchase_price= )\n```\n**Note:** Argument _new_purchase_price_ is calculated as follows:-\n```markdown\nprevious purchase price - amount of price to refund\n```\n\nIn case of **full** refund, set arguments _plan_id_ and _full_refund_ as follows:-\n```python\nclient.refund_status(plan_id=plan_id, full_return=True)\n```\n\n### Create dispatch\nIf _merchant_ wants to initiate a _dispatch_ of an order then he will following method with corresponding _plan_id_ \nof that order as follows:-\n```python\nclient.order_dispatch_plan(plan_id=plan_id)\n```\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/openpaygithub/PythonSDK", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "python-openpay", "package_url": "https://pypi.org/project/python-openpay/", "platform": "", "project_url": "https://pypi.org/project/python-openpay/", "project_urls": { "Homepage": "https://github.com/openpaygithub/PythonSDK" }, "release_url": "https://pypi.org/project/python-openpay/0.6.3/", "requires_dist": [ "lxml", "requests (==2.20.1)" ], "requires_python": "", "summary": "openpay python sdk", "version": "0.6.3" }, "last_serial": 5150312, "releases": { "0.4": [ { "comment_text": "", "digests": { "md5": "88c12bbc8687fe80f86eddfc83aa383e", "sha256": "5a8e0c06b96ffec10df74af0760c8c9101b9372f290bb0d88462fd18986aeeed" }, "downloads": -1, "filename": "python_openpay-0.4-py3-none-any.whl", "has_sig": false, "md5_digest": "88c12bbc8687fe80f86eddfc83aa383e", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 6796, "upload_time": "2019-01-28T09:36:10", "url": "https://files.pythonhosted.org/packages/94/2e/7da7d8547c6863153ca2fa3a1e6eb22603b6f4ae6377b873dc7cee8adcb9/python_openpay-0.4-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "9f80647b5dfb74d4c0cb7f0fc70ed28e", "sha256": "d8f227aa6909ca2ffa597deceab56bb1b5415e35bf36d19e2d7f9d958c08cc95" }, "downloads": -1, "filename": "python-openpay-0.4.tar.gz", "has_sig": false, "md5_digest": "9f80647b5dfb74d4c0cb7f0fc70ed28e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4909, "upload_time": "2019-01-28T09:36:12", "url": "https://files.pythonhosted.org/packages/79/4b/306779972e813de80ab433af897dcbe1456502806a8baee15e39eb4efaf6/python-openpay-0.4.tar.gz" } ], "0.4.1": [ { "comment_text": "", "digests": { "md5": "86ed50860cb747dd3438404feff3593c", "sha256": "6f4dcaa4110fc7072446255ee78ba17b76953206e06fabc9eb250be3edd07560" }, "downloads": -1, "filename": "python-openpay-0.4.1.tar.gz", "has_sig": false, "md5_digest": "86ed50860cb747dd3438404feff3593c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5715, "upload_time": "2019-02-04T10:22:37", "url": "https://files.pythonhosted.org/packages/8f/33/c50fa40b841b0791f9eb2f6410e553af59de31ee5b90c9e1e0b6d5506f3b/python-openpay-0.4.1.tar.gz" } ], "0.5": [ { "comment_text": "", "digests": { "md5": "6675a10b311c0cd2ea0d993623e05aa8", "sha256": "e745c6685197278daf61d1421fa318483b68c70cccc92066769bcd54d49fbcfc" }, "downloads": -1, "filename": "python_openpay-0.5-py3-none-any.whl", "has_sig": false, "md5_digest": "6675a10b311c0cd2ea0d993623e05aa8", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 8416, "upload_time": "2019-04-04T12:29:23", "url": "https://files.pythonhosted.org/packages/43/c7/fd59e92295b2326498eb03c20fd9414f9a5d85b39ccfde93b7b7bb8df957/python_openpay-0.5-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "ced7d017be751822a05b8efc869d4c89", "sha256": "eeac9bbf6dad02881392754d68fd3bf9b57d9d19261e74e22b41d44c116d073b" }, "downloads": -1, "filename": "python-openpay-0.5.tar.gz", "has_sig": false, "md5_digest": "ced7d017be751822a05b8efc869d4c89", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6559, "upload_time": "2019-04-04T12:29:25", "url": "https://files.pythonhosted.org/packages/db/54/0fcb5d78ca659430a88e56ce1d434b526ed20e87918ef6e3abd0866ba8b8/python-openpay-0.5.tar.gz" } ], "0.5.1": [ { "comment_text": "", "digests": { "md5": "16bc5d994ccf87b98f3b01030a02c657", "sha256": "9d1c0db5c3c7d9b5e351e3688070346647ad4d875c4061d7828349267857d64d" }, "downloads": -1, "filename": "python_openpay-0.5.1-py3-none-any.whl", "has_sig": false, "md5_digest": "16bc5d994ccf87b98f3b01030a02c657", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 8573, "upload_time": "2019-04-05T13:17:49", "url": "https://files.pythonhosted.org/packages/3d/a6/6ce59c937e3b9f75315a752bb8489c8da063a9882ce1d762bef786e75f31/python_openpay-0.5.1-py3-none-any.whl" } ], "0.5.2": [ { "comment_text": "", "digests": { "md5": "dbb67fa6afcdd581a010067baae1d5fa", "sha256": "1ceaa8122de4d387d00e52d6ba89dba2e04a1b2aec1841f5df800d0738d6012e" }, "downloads": -1, "filename": "python_openpay-0.5.2-py3-none-any.whl", "has_sig": false, "md5_digest": "dbb67fa6afcdd581a010067baae1d5fa", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 8573, "upload_time": "2019-04-05T13:19:05", "url": "https://files.pythonhosted.org/packages/05/62/ca45a75cf74bde7f650ea8d05e86b1b2a4dd0434778fae68db853db4873c/python_openpay-0.5.2-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "402ed1fe7ad0c94544760cd13c8e8735", "sha256": "7369798b81be7bdc83cc692e9c5bf22458615c69ec8fc0c0c47dbd26550fad03" }, "downloads": -1, "filename": "python-openpay-0.5.2.tar.gz", "has_sig": false, "md5_digest": "402ed1fe7ad0c94544760cd13c8e8735", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6687, "upload_time": "2019-04-05T13:19:07", "url": "https://files.pythonhosted.org/packages/f7/20/9411a277d9195e755a0bd9c629f45c817fced401af7dc9695cc713708ae5/python-openpay-0.5.2.tar.gz" } ], "0.6": [ { "comment_text": "", "digests": { "md5": "0debdc0c7eeb3be5dfd42ff83859e528", "sha256": "1ca3e391a5c68f51f2a44890e5b9370531b6ac3ac0d7b9563bd73a48963dd4f1" }, "downloads": -1, "filename": "python_openpay-0.6-py3-none-any.whl", "has_sig": false, "md5_digest": "0debdc0c7eeb3be5dfd42ff83859e528", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 8648, "upload_time": "2019-04-08T14:19:17", "url": "https://files.pythonhosted.org/packages/51/68/79401f28682a54763bf4e6cbd6eb70e76c7c538ce4978c1cfe3973f8ad80/python_openpay-0.6-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "42e0b7bc93370c887606ed2355e9f6fc", "sha256": "309c0a14721c5917eb43266c2861dc36ceb1bff759b2fdb751c72a53438a7efd" }, "downloads": -1, "filename": "python-openpay-0.6.tar.gz", "has_sig": false, "md5_digest": "42e0b7bc93370c887606ed2355e9f6fc", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6772, "upload_time": "2019-04-08T14:19:20", "url": "https://files.pythonhosted.org/packages/b1/a0/ee26bfdb7d73addbc4293bb6f6a02f6491ef582a74837549a391c22a0e93/python-openpay-0.6.tar.gz" } ], "0.6.1": [ { "comment_text": "", "digests": { "md5": "bfce1da58301e15f2fdf06459906c2fb", "sha256": "a04cd72469031e937fbcaa041edb23417b3b723624735f402e2aa6c5aeb34d09" }, "downloads": -1, "filename": "python_openpay-0.6.1-py3-none-any.whl", "has_sig": false, "md5_digest": "bfce1da58301e15f2fdf06459906c2fb", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 8647, "upload_time": "2019-04-09T08:23:18", "url": "https://files.pythonhosted.org/packages/0b/4b/da388532655e2828c9f479c7419af6b3632a1b3af736c36aa5600fede8a4/python_openpay-0.6.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "9755036adefc3c7cad57ad6338ab7099", "sha256": "357bc40b54b9aa8b145685dcf1ca3eb6f465ca93ec79c5ec398b8e1725391660" }, "downloads": -1, "filename": "python-openpay-0.6.1.tar.gz", "has_sig": false, "md5_digest": "9755036adefc3c7cad57ad6338ab7099", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6757, "upload_time": "2019-04-09T08:23:22", "url": "https://files.pythonhosted.org/packages/55/63/e0fcf9ce37d2252543e278d74d55b2c29e7f1028e05419e7ec064a894796/python-openpay-0.6.1.tar.gz" } ], "0.6.2": [ { "comment_text": "", "digests": { "md5": "22aba1c98fe0d065b8f9761a8ac3152f", "sha256": "aca921e5a235faaf9dc31be30b6a061b61629c77e0f74207249b2d59737b0e32" }, "downloads": -1, "filename": "python_openpay-0.6.2-py3-none-any.whl", "has_sig": false, "md5_digest": "22aba1c98fe0d065b8f9761a8ac3152f", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 8646, "upload_time": "2019-04-09T09:12:11", "url": "https://files.pythonhosted.org/packages/78/d9/c89bf52219499021b38377bab3a92ac3c3c08159b9486b69dcce65b5492e/python_openpay-0.6.2-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "eb1d27fba04777622505d26cb995c040", "sha256": "8632148b8cfa21bbf8453627c56fdc833d54ee7044363772d5f1bf8d74044abd" }, "downloads": -1, "filename": "python-openpay-0.6.2.tar.gz", "has_sig": false, "md5_digest": "eb1d27fba04777622505d26cb995c040", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6751, "upload_time": "2019-04-09T09:12:16", "url": "https://files.pythonhosted.org/packages/26/de/fb8fbf637a4338d8650feb31ec6227d5dcd08789d9222b231cbbec21f6fc/python-openpay-0.6.2.tar.gz" } ], "0.6.3": [ { "comment_text": "", "digests": { "md5": "b0f956ae5fae5b473aada2a3d957b61f", "sha256": "276411beb94103254b6c58cd9719d7e8a16ab23af89030e5b768ae5c4f2c6adf" }, "downloads": -1, "filename": "python_openpay-0.6.3-py3-none-any.whl", "has_sig": false, "md5_digest": "b0f956ae5fae5b473aada2a3d957b61f", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 8820, "upload_time": "2019-04-16T14:12:38", "url": "https://files.pythonhosted.org/packages/4f/f3/2cb2d907b43c15680ea428ab7edbf4d4bf2b3ecf952b25ccbdab50492a22/python_openpay-0.6.3-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "c502720bef6ed6a9abe419a8c3f4547b", "sha256": "62162671f8687461a3efd5f6be81de67fc47bbfb52c8c9492e216385ec687804" }, "downloads": -1, "filename": "python-openpay-0.6.3.tar.gz", "has_sig": false, "md5_digest": "c502720bef6ed6a9abe419a8c3f4547b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6918, "upload_time": "2019-04-16T14:12:40", "url": "https://files.pythonhosted.org/packages/f6/61/ae05f9e3dbde427730a7e65fa4215ce7d7b2e1d43bd501d96a2e380c03ce/python-openpay-0.6.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "b0f956ae5fae5b473aada2a3d957b61f", "sha256": "276411beb94103254b6c58cd9719d7e8a16ab23af89030e5b768ae5c4f2c6adf" }, "downloads": -1, "filename": "python_openpay-0.6.3-py3-none-any.whl", "has_sig": false, "md5_digest": "b0f956ae5fae5b473aada2a3d957b61f", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 8820, "upload_time": "2019-04-16T14:12:38", "url": "https://files.pythonhosted.org/packages/4f/f3/2cb2d907b43c15680ea428ab7edbf4d4bf2b3ecf952b25ccbdab50492a22/python_openpay-0.6.3-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "c502720bef6ed6a9abe419a8c3f4547b", "sha256": "62162671f8687461a3efd5f6be81de67fc47bbfb52c8c9492e216385ec687804" }, "downloads": -1, "filename": "python-openpay-0.6.3.tar.gz", "has_sig": false, "md5_digest": "c502720bef6ed6a9abe419a8c3f4547b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6918, "upload_time": "2019-04-16T14:12:40", "url": "https://files.pythonhosted.org/packages/f6/61/ae05f9e3dbde427730a7e65fa4215ce7d7b2e1d43bd501d96a2e380c03ce/python-openpay-0.6.3.tar.gz" } ] }