{ "info": { "author": "Connor Collins", "author_email": "connor.collins@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Topic :: Software Development" ], "description": "Python QuadrigaCX\n=================\n\nquadrigacx is a Python wrapper for the `QuadrigaCX API (v2)`_.\n\nInstall\n~~~~~~~\n\n``pip install quadrigacx``\n\nor ``pip install setup.py`` in the repo\u2019s main directory after you\ndownload this repo.\n\nConfiguration\n~~~~~~~~~~~~~\n\nYou will need to create a config file in order to use the authenticated\nAPI actions. Use sample.cfg in the config folder\n\nUsage\n~~~~~\n\nBasically, create a QCX object, passing in the path to the config file\n[like in ``quadrigacx/config/sample.cfg``], or the config options in a\ndict [i.e.\n``{client_id:0000, key:yOurKeY, secret:Y0Ur53crr3T142351236}``]\n\n::\n\n import quadrigacx\n qcx = quadrigacx.QCX('config/auth.cfg')\n\nThat QCX object then has a methods called ``methods`` which will tell\nyou all of the actions available in this format:\n\n::\n\n qcx.methods()\n\n {\n 'private':\n [\n {\n 'name':'name_of_action',\n 'requires': {\n 'key': [value for key,value in {'maybe':'some', 'example':'data'}]\n },\n 'optional': {\n 'key': [value for key,value in {'maybe':'some', 'optional':'data'}]\n },\n 'returns': {\n 'something': {\n u'details': u'850.99',\n u'more_details': u'837.51'\n }\n },\n },\n ],\n 'public':\n [\n {\n 'name':'name_of_action',\n 'requires': {\n 'key': [value for key,value in {'maybe':'some', 'example':'data'}]\n },\n 'optional': {\n 'key': [value for key,value in {'maybe':'some', 'optional':'data'}]\n },\n 'returns': {\n 'something': {\n u'details': u'850.99',\n u'more_details': u'837.51'\n }\n },\n }\n ]\n }\n\nYou can take that ``name`` and pass it into QCX.api(), along with the\n``required`` (and ``optional``, if needed) data *as keyword arguments*,\nand you\u2019ll get something like the expected ``returns``.\n\n\n+------------+------+--------------+------------------+------------------------+-------+\n| **Function | **Au | **Required | **Default** | **Optional Arguments** | **Def |\n| Name** | th** | Arguments** | | | ault* |\n| | | | | | * |\n+============+======+==============+==================+========================+=======+\n| ticker | No | a or a list | [btc\\_cad, | | |\n| | | of valid | btc\\_usd, | | |\n| | | books | eth\\_cad, | | |\n| | | | eth\\_btc] | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| order\\_boo | No | a or a list | [btc\\_cad, | A boolean to group | False |\n| k | | of valid | btc\\_usd, | orders with the same | |\n| | | books | eth\\_cad, | price or not | |\n| | | | eth\\_btc] | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| transactio | No | a or a list | [btc\\_cad, | A time frame; last | hour |\n| ns | | of valid | btc\\_usd, | \u2018minute\u2019, or \u2018hour\u2019 | |\n| | | books | eth\\_cad, | | |\n| | | | eth\\_btc] | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| balance | Yes | | | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| user\\_tran | Yes | a or a list | [btc\\_cad, | | |\n| sactions | | of valid | btc\\_usd, | | |\n| | | books | eth\\_cad, | | |\n| | | | eth\\_btc] | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| open\\_orde | Yes | open\\_orders | [btc\\_cad, | | |\n| rs | | | btc\\_usd, | | |\n| | | | eth\\_cad, | | |\n| | | | eth\\_btc] | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| lookup\\_or | Yes | order\\_id | | | |\n| der | | | | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| cancel\\_or | Yes | order\\_id | | | |\n| der | | | | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| buy | Yes | a valid book | | a price | |\n+------------+------+--------------+------------------+------------------------+-------+\n| | | an amount | | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| sell | Yes | a valid book | | a price | |\n+------------+------+--------------+------------------+------------------------+-------+\n| | | an amount | | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| bitcoin\\_d | Yes | | | | |\n| eposit\\_ad | | | | | |\n| dress | | | | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| ether\\_dep | Yes | | | | |\n| osit\\_addr | | | | | |\n| ess | | | | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| bitcoin\\_w | Yes | an amount | | | |\n| ithdrawal | | | | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| | | an address | | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| ethereum\\_ | Yes | an amount | | | |\n| withdrawal | | | | | |\n+------------+------+--------------+------------------+------------------------+-------+\n| | | an address | | | |\n+------------+------+--------------+------------------+------------------------+-------+\n\n**Notes:**\n\n- Not all items in methods() show what the return value is. I will\n eventually update that, but for now just play around.\n- I only show what the positive response should look like, negative\n responses could be (and often are) entirely different.\n- Honestly, you are better off just looking at QuadrigaCX\u2019s API page to\n see what resuts they will provide:\n https://www.quadrigacx.com/api\\_info\n\nExamples:\n~~~~~~~~~\n\nBasic\n^^^^^\n\n::\n\n print qcx.api('ticker')\n\n >> {'eth_cad': {u'volume': u'730.00552932', u'last': u'15.00', u'timestamp': u'1467639054', u'bid': u'14.90', u'vwap': u'15.47', u'high': u'16.34', u'low': u'15.00', u'ask': u'16.08'}, 'btc_cad': {u'volume': u'161.49814654', u'last': u'886.00', u'timestamp': u'1467639053', u'bid': u'878.20', u'vwap': u'867.00', u'high': u'886.00', u'low': u'856.79', u'ask': u'887.97'}, 'eth_btc': {u'volume': u'2256.84091030', u'last': u'0.01722000', u'timestamp': u'1467639054', u'bid': u'0.01722000', u'vwap': u'0.01794464', u'high': u'0.01855999', u'low': u'0.01722000', u'ask': u'0.01819999'}, 'btc_usd': {u'volume': u'10.06581000', u'last': u'670.00', u'timestamp': u'1467639053', u'bid': u'663.10', u'vwap': u'666.91', u'high': u'700.26', u'low': u'670.00', u'ask': u'688.00'}}\n\nOptional Parameter as String\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n::\n\n book = 'btc_cad' # Undocumented ability to send individual values not in a list\n print qcx.api('ticker', book_list=book)\n\n >> {'btc_cad': {u'volume': u'161.49814654', u'last': u'886.00', u'timestamp': u'1467639054', u'bid': u'878.20', u'vwap': u'867.00', u'high': u'886.00', u'low': u'856.79', u'ask': u'887.97'}}\n\nOptional parameter as List\n^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n::\n\n book_list = ['btc_cad', 'eth_btc']\n print qcx.api('ticker', book_list=book_list)\n\n >> {'btc_cad': {u'volume': u'161.49814654', u'last': u'886.00', u'timestamp': u'1467639055', u'bid': u'878.20', u'vwap': u'867.00', u'high': u'886.00', u'low': u'856.79', u'ask': u'887.97'}, 'eth_btc': {u'volume': u'2256.84091030', u'last': u'0.01722000', u'timestamp': u'1467639055', u'bid': u'0.01722000', u'vwap': u'0.01794464', u'high': u'0.01855999', u'low': u'0.01722000', u'ask': u'0.01819999'}}\n\nLimit Purchase with unnamed parameters\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n::\n\n book = 'btc_cad'\n amount = 0.005\n print qcx.api('buy', book, amount)\n\n >> {u'error': {u'message': u'Incorrect : $7.50CAD exceeds available CAD balance', u'code': 21}}", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/c4collins/quadrigacx", "keywords": "bitcoin quadrigacx web python development", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "quadrigacx", "package_url": "https://pypi.org/project/quadrigacx/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/quadrigacx/", "project_urls": { "Homepage": "https://github.com/c4collins/quadrigacx" }, "release_url": "https://pypi.org/project/quadrigacx/0.6.1/", "requires_dist": [ "requests" ], "requires_python": "", "summary": "quadrigacx is a Python wrapper for the QuadrigaCX API", "version": "0.6.1" }, "last_serial": 2203113, "releases": { "0.4.3": [ { "comment_text": "", "digests": { "md5": "9f9276bf079eae2b5c5ce311193565ec", "sha256": "b684e5cec8cc8113d8bc05e960e5690ccdcf78a185e93dbc991ddd8016d2f796" }, "downloads": -1, "filename": "quadrigacx-0.4.3-py2-none-any.whl", "has_sig": false, "md5_digest": "9f9276bf079eae2b5c5ce311193565ec", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 7305, "upload_time": "2016-06-29T12:26:25", "url": "https://files.pythonhosted.org/packages/99/7d/c1547dc369d22a135af2d71f463669f8c76919555f0ee94f00aa4f99305f/quadrigacx-0.4.3-py2-none-any.whl" } ], "0.5.0": [ { "comment_text": "", "digests": { "md5": "91ea65a37a3c5539048a416f3dccff1d", "sha256": "28d0d4b46ed103bff7d05e239e3da50771d4102dd044ddcb801c47aa226ed825" }, "downloads": -1, "filename": "quadrigacx-0.5.0-py2-none-any.whl", "has_sig": false, "md5_digest": "91ea65a37a3c5539048a416f3dccff1d", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 10005, "upload_time": "2016-06-30T11:49:54", "url": "https://files.pythonhosted.org/packages/23/54/a1323359a4fc3456d17ed7eff62b9803392c10ffc021863eda152d4eea1f/quadrigacx-0.5.0-py2-none-any.whl" } ], "0.6.0": [ { "comment_text": "", "digests": { "md5": "675634d7ab29961ff2ce7c658a0e08b8", "sha256": "61457cee5297cf2ba79d9ade1cc1af06d9a60389198e870a095e30b317e04b51" }, "downloads": -1, "filename": "quadrigacx-0.6.0-py2-none-any.whl", "has_sig": false, "md5_digest": "675634d7ab29961ff2ce7c658a0e08b8", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 13779, "upload_time": "2016-07-05T01:14:38", "url": "https://files.pythonhosted.org/packages/ae/b5/201c3fbf8176b10f166eafcf7e933314c46d6d0745e2e2762985d86c364a/quadrigacx-0.6.0-py2-none-any.whl" } ], "0.6.1": [ { "comment_text": "", "digests": { "md5": "9d32ebaa89c3c0ddbd9a24b06b1fe048", "sha256": "e81b56e8b7d011f03043eb7781deeb49f2e581a6dd955e4fb4715841bba5f56a" }, "downloads": -1, "filename": "quadrigacx-0.6.1-py2-none-any.whl", "has_sig": false, "md5_digest": "9d32ebaa89c3c0ddbd9a24b06b1fe048", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 13764, "upload_time": "2016-07-05T10:39:57", "url": "https://files.pythonhosted.org/packages/10/90/2efc967ca12aa70f3926bf529aa216f019d504d809f096641d28d141eaf4/quadrigacx-0.6.1-py2-none-any.whl" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "9d32ebaa89c3c0ddbd9a24b06b1fe048", "sha256": "e81b56e8b7d011f03043eb7781deeb49f2e581a6dd955e4fb4715841bba5f56a" }, "downloads": -1, "filename": "quadrigacx-0.6.1-py2-none-any.whl", "has_sig": false, "md5_digest": "9d32ebaa89c3c0ddbd9a24b06b1fe048", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 13764, "upload_time": "2016-07-05T10:39:57", "url": "https://files.pythonhosted.org/packages/10/90/2efc967ca12aa70f3926bf529aa216f019d504d809f096641d28d141eaf4/quadrigacx-0.6.1-py2-none-any.whl" } ] }