{ "info": { "author": "DxChain", "author_email": "developer@dxchain.com", "bugtrack_url": null, "classifiers": [], "description": "# DxChainPy\n\nDxChainPy is a simple Python implementation for DxChain API, which allows users to build their own application based on DxChain Network.\n\nTable of Contents:\n\n* [Requirements](#requirements)\n* [Installation](#installation)\n* [Documentation](#documentation)\n* [Examples](#examples)\n* [License](#license)\n\n## Requirements\n\n* Python: 3.7\n\n## Installation\n\nThere are two ways to install the library:\n\n* Installation using pip (Python Package Manager):\n\n```bash\n$ pip install dxchainpy\n```\n\n* Installation from source (requires git):\n\n```bash\n$ git clone https://github.com/DxChainNetwork/dxchainpy\n$ cd dxchainpy \n$ python setup.py install\n```\n\n## Documentation\nDocumentation is available online: [https://dxchainapidoc.readthedocs.io/en/latest/index.html](https://dxchainapidoc.readthedocs.io/en/latest/index.html)\n\nFor support, please email **developer@dxchain.com**\n\n## Examples\n**Getting information of consensus and specific blocks**\n\n```python\n# import dxchainpy package\nimport dxchainpy\n\n# declare a class object with self defined host\ndxchain = dxchainpy.Dxchain()\n\n# call Consensus methods\n# Get consensus information\nconsensus_info = dxchain.consensus.info()\nprint(consensus_info)\n\n# Get block information based on height\nblock_info = dxchain.consensus.block_by_height(3)\nprint(block_info)\n\n# Get block information based on id\nblock_id = '00000001ef0bfc292345e67cdd3f918206993036e7f500c7995d224e9b9da99a'\nblock_info = dxchain.consensus.block_by_id(block_id)\nprint(block_info)\n```\n\nThe example will print (python dictionary format):\n\n```python\n{'synced': True, 'height': 835, 'currentblock': '00000005a198330a265aab9538fa882e41a423181570923fd9b1d7c78dcb0780', 'target': [0, 0, 0, 6, 166, 127, 91, 80, 240, 184, 121, 105, 236, 89, 120, 91, 125, 245, 238, 213, 218, 145, 156, 7, 207, 210, 3, 236, 200, 20, 186, 116], 'difficulty': '645822761'}\n\n{'id': '0000000f28ee9ea58b711b1870a0e243ab415b5eea7eabf6db2f3c0670fb3026', 'height': 3, 'parentid': '00000002a23b13c30d4d5400ae3a94f74bba4cc63c65e39eedfa5922987ee78e', 'difficulty': '238609294', 'nonce': [19, 30, 0, 0, 0, 0, 0, 0], 'timestamp': 1546563148, 'minerpayouts': [{'id': 'a25cb81b9d1e3ea33f9177c4fc7d9c1d1b15337c5f676d22b1d785c61d468c8d', 'value': '29700000000000000000000000000', 'unlockhash': 'TeRWdaMsigXka35nPtT4mBXVRTSeXGRqMDRVknswNjG1WKSDiKdk'}], 'transactions': [{'id': '7cc21c8aea62561e78b42a32cf928b5e94a098e2c49f1f7e776bc07e1507eeed', 'dxcoininputs': [], 'dxcoinoutputs': [], 'storagecontracts': [], 'storagecontractrevisions': [], 'storageproofs': [], 'minerfees': [], 'arbitrarydata': ['Tm9uR2R4AAAAAAAAAAAAABq7mAmGSRQKzVN2umDuyaQ='], 'transactionsignatures': []}]}\n\n{'id': '00000001ef0bfc292345e67cdd3f918206993036e7f500c7995d224e9b9da99a', 'height': 243, 'parentid': '00000004cd371436d403e7c53d55ee6e65ffd7a5c666bd4c2c1e21d7088f781a', 'difficulty': '120769904', 'nonce': [45, 24, 0, 0, 0, 0, 0, 0], 'timestamp': 1546564063, 'minerpayouts': [{'id': '1d2578fa90e8f62da0d38bc9c13bdcd606137c42ff628de18d77b875f28c6d8c', 'value': '29695000000000000000000000000', 'unlockhash': 'BWNc8v3innYXCF6shQPyCXsEA14YdogYKYGXYwGeu26cnJ6iG4mQ'}], 'transactions': [{'id': '3e3e530e93a26d61bbd4b0ad40d20f9f96c71b18b0a0d1ce1a859d9d8b6efa81', 'dxcoininputs': [], 'dxcoinoutputs': [], 'storagecontracts': [], 'storagecontractrevisions': [], 'storageproofs': [], 'minerfees': [], 'arbitrarydata': ['Tm9uR2R4AAAAAAAAAAAAAAM4ko5KxCHocnNSFXC6jXE='], 'transactionsignatures': []}]}\n```\n\n## License\nDxChainPy is released under the MIT License. See LICENSE for more information.", "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/DxChainNetwork/dxchainpy", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "dxchainpy", "package_url": "https://pypi.org/project/dxchainpy/", "platform": "", "project_url": "https://pypi.org/project/dxchainpy/", "project_urls": { "Homepage": "https://github.com/DxChainNetwork/dxchainpy" }, "release_url": "https://pypi.org/project/dxchainpy/0.3.6.1/", "requires_dist": null, "requires_python": "", "summary": "Toolkit that allows users to interact with dxchain", "version": "0.3.6.1" }, "last_serial": 4674659, "releases": { "0.3.6": [ { "comment_text": "", "digests": { "md5": "0bafec1997fc9ba07cc0f4ee4c156362", "sha256": "04fadd33310791ce876a6c8b1b40b18260a29f5af7be2ed095a3add84128fd78" }, "downloads": -1, "filename": "dxchainpy-0.3.6.tar.gz", "has_sig": false, "md5_digest": "0bafec1997fc9ba07cc0f4ee4c156362", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6301, "upload_time": "2019-01-07T19:55:07", "url": "https://files.pythonhosted.org/packages/b6/a1/86fb484e40a2684782c74c4dbff257ef28b8e87d99d3dc8475f621e09607/dxchainpy-0.3.6.tar.gz" } ], "0.3.6.1": [ { "comment_text": "", "digests": { "md5": "80aa943b640210228b79cf1592898f41", "sha256": "a3db49f34a509688ebc1bee866b0c2b60cc22854fa96c1140ca4969bf9cb3b09" }, "downloads": -1, "filename": "dxchainpy-0.3.6.1.tar.gz", "has_sig": false, "md5_digest": "80aa943b640210228b79cf1592898f41", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6306, "upload_time": "2019-01-08T23:26:00", "url": "https://files.pythonhosted.org/packages/ab/cf/98f0754ba4e053e7c86f53d3610b353f59e536e2157643e1025fafc9d50f/dxchainpy-0.3.6.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "80aa943b640210228b79cf1592898f41", "sha256": "a3db49f34a509688ebc1bee866b0c2b60cc22854fa96c1140ca4969bf9cb3b09" }, "downloads": -1, "filename": "dxchainpy-0.3.6.1.tar.gz", "has_sig": false, "md5_digest": "80aa943b640210228b79cf1592898f41", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6306, "upload_time": "2019-01-08T23:26:00", "url": "https://files.pythonhosted.org/packages/ab/cf/98f0754ba4e053e7c86f53d3610b353f59e536e2157643e1025fafc9d50f/dxchainpy-0.3.6.1.tar.gz" } ] }