QubiPy


NameQubiPy JSON
Version 0.2.4 PyPI version JSON
download
home_pagehttps://github.com/QubiPy-Labs/QubiPy
SummaryQubiPy, a Python Library for the QUBIC RPC API
upload_time2024-12-21 13:35:10
maintainerNone
docs_urlNone
authorKyoto
requires_python>=3.10
licenseNone
keywords qubic blockchain rpc api cryptocurrency
VCS
bugtrack_url
requirements requests urllib3 certifi charset-normalizer idna pytest pytest-mock pytest-sugar iniconfig pluggy black setuptools watchdog
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # QubiPy, a Python Library for the QUBIC RPC API
Currently, QubiPy is in a very early development phase, so please take this into consideration before using the library.

Please visit the [Change log](https://github.com/QubiPy-Labs/QubiPy/blob/main/docs/changelog.md) to see all changes.

![release](https://img.shields.io/badge/release-v0.2.4--beta-blue)
![python](https://img.shields.io/badge/python-3.10_%7C_3.11_%7C_3.12-blue)
![Python Package](https://github.com/QubiPy-Labs/QubiPy/actions/workflows/python-package.yml/badge.svg)
![Code Quality](https://github.com/QubiPy-Labs/QubiPy/actions/workflows/pylint.yml/badge.svg)
![license](https://img.shields.io/badge/license-AGPL--3.0-orange)
![dependabot](https://img.shields.io/badge/dependabot-enabled-025e8c)


###  Important notice
QubiPy is in beta phase and may change considerably until the stable version. Keep this in mind when using the library.

### Documentation
To learn more about QubiPy and its complete use, please visit our official [documentation](https://qubipy.readthedocs.io/en/latest/).

### Requirements
To install the necessary dependencies, run this command in the console :
```
$ pip install -r requirements.txt
```

### How to use
You have two ways to use QubiPy, one is by [PyPi](https://pypi.org/project/QubiPy/) or by cloning the project from the official repository.

To use the module, it is necessary to import some classes before :
```python
from qubipy.rpc import rpc_client
from qubipy.core import core_client
```

Let's request tick info from the RPC for example :

```python
RPC = rpc_client.QubiPy_RPC()
print(RPC.get_tick_info())
```
Response :
```python
$ {
  "tick": 16660254,
  "duration": 1,
  "epoch": 131,
  "initialTick": 16640000
}
```
Let's request the entity info from the core :
```python
CORE = core_client.QubiPy_Core()
print(CORE.get_entity_info('PEKBRHZQKMGCQBTAHXHZRXQRLBACJIHAGWHMPIJTZBWIJVTIWQOVMGJDTPFO'))
```
Reponse :
```python
$ {
  "entity": {
    "id": "PEKBRHZQKMGCQBTAHXHZRXQRLBACJIHAGWHMPIJTZBWIJVTIWQOVMGJDTPFO",
    "incomingAmount": "113653127220",
    "outgoingAmount": "80838490981",
    "numberOfIncomingTransfers": 824156,
    "numberOfOutgoingTransfers": 422,
    "latestIncomingTransferTick": 16613012,
    "latestOutgoingTransferTick": 16613029
  },
  "validForTick": 16660147,
  "spectrumIndex": 7434551,
  "siblingIds": [
    "GIDNABDPPDFPECDPYUQZEBZONVJAXCTRQXRGHCLPNAOMEAHMULYQBQQEZRBE",
    "WUTXDWZRYSBHOEHBZSVCWIRXSAPAZFMZSJFHOGDTIAYOPAIKGUNGIOLEVFVO",
    "NZUUNSQJEAXQAACZVEGHEHDNQRLDZRHXDJKCJLCXODFQQJTHGCMIRZDFAXBD",
    "HFSHRQUTQONGFDTXKPPAGHEMJSHBLTWVQKZMKVGYYEDSTPBIRBTMHSRCUKUO",
    "PGXXITTPEGARXGSHDTBVFYRVBXFHZBXPIQQNBQKJHEGXZGDTTCYGITFGSKBG",
    "EFEDDOBGUVASHBTCYRCUZOXQTLUDMKMCEYFHDLETIFAUDPLYOZYQUPEBAXGC",
    "DNYAQMGQRFCUMBUCEIFRNYSCYUXDWNWTTLFQQFDCEBVCTOWGLVXLCNBESPJE",
    "MSWZOKQKAWZUECKOEWOPMNUBSQSDAHTHYIFMSYRRKBZSJJLHLECBOUUDNNHO",
    "RGHPZOHWBHKIICUGBENRQPKDJHJDLIFKETGMKMPMTAJGRTPIOKCPETRDPBME",
    "CADVHWJMDNOJJGPDAVPYOUNDPWEABLSDLPGHCWJWGDFTYIVFBAZIBTDBQKVL",
    "AEMCJNNWDXBRSFEZVXAHFDPLNBJHMMMDBLKPVETCQFCZFJWEVEEXANUBUMCM",
    "BTOZFRHDVNYUVAMHNBBZJTNMCVZBORRPFNQIZZPRDEMHIFPWTFSARQVBMATC",
    "SHWFJGOAMBUIJDDSKCWAMOIWBNJHUUDHRDDHRBORSDCCSJLSSCDGXOKCVWMB",
    "XTOYTMZTUTPPVGBWYCVIFDVMLLWFIMXRZKOGUHJLADMIKLZTIPQJPLKCGVUB",
    "ZVBYCOZKUMZRTBIAYVWUTWUGYNQEPASOMENYCCERUDCYFHKMIQDLCVNCZCVA",
    "GHGNSBIOBLCIRGBBEKQZOSTKXJGHXWUYVNLRCTSBUENITLCSDIBNSDBBITQL",
    "PKFLHUYXWAELGGXBXTRRASNCQZSEDURLIUXKEDHTYFAIASIPPTSBVYMCQTWB",
    "OCOVEQIPGTUPIBAYGYDOSAWXWIGBKDBVKIFARQSHWAUUYSYVLKZITMZCMHCI",
    "NAPHRLGCLNNKVERLZDIGIFADQSLAZYUULTBAGCDYEEDSBFZGCCLXZXDGSBKK",
    "IGIZMDVOTFEJTFXHXURCUXNOSCDFJJJHTTTSRGABECNPKMJFZQTTEKOBSDFH",
    "OHEMQVDLSQLQQAVHTYOKFPZUOHIBNBWJITCHETOBUAAPWWFSYACPPSMEHSEE",
    "LPJMDKCKOOYGBFAEXDRZCALQUIIALWMHFSAEJUUBKBQXRPDYCXEXKMYDDJIO",
    "HGDFFPYTXOKSMGYMXPFEPLCQXXLDRULLJEIAYOVZBFABJIYZHVNSLRAENXUG",
    "ZQLSECAGXOUHNEFFBATFQIBYAYYDECSPKVHNGGJIPEGNSIUWNORASTNAUFYL"
  ]
}

```

### Technical notes
This library is using `crypto.dll` which is a C extension of Qubic key utility functions and bind it to Python. To build this `crypto.dll`, this repository was used: [https://github.com/serendipity-seeker/key-utils-binding](https://github.com/serendipity-seeker/key-utils-binding).


            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/QubiPy-Labs/QubiPy",
    "name": "QubiPy",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.10",
    "maintainer_email": null,
    "keywords": "qubic, blockchain, rpc, api, cryptocurrency",
    "author": "Kyoto",
    "author_email": "qubipy.labs@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/81/01/3abff02fbd291e319eea284d334d8d46143d5bc44d4571d3acba765493e3/qubipy-0.2.4.tar.gz",
    "platform": null,
    "description": "# QubiPy, a Python Library for the QUBIC RPC API\r\nCurrently, QubiPy is in a very early development phase, so please take this into consideration before using the library.\r\n\r\nPlease visit the [Change log](https://github.com/QubiPy-Labs/QubiPy/blob/main/docs/changelog.md) to see all changes.\r\n\r\n![release](https://img.shields.io/badge/release-v0.2.4--beta-blue)\r\n![python](https://img.shields.io/badge/python-3.10_%7C_3.11_%7C_3.12-blue)\r\n![Python Package](https://github.com/QubiPy-Labs/QubiPy/actions/workflows/python-package.yml/badge.svg)\r\n![Code Quality](https://github.com/QubiPy-Labs/QubiPy/actions/workflows/pylint.yml/badge.svg)\r\n![license](https://img.shields.io/badge/license-AGPL--3.0-orange)\r\n![dependabot](https://img.shields.io/badge/dependabot-enabled-025e8c)\r\n\r\n\r\n###  Important notice\r\nQubiPy is in beta phase and may change considerably until the stable version. Keep this in mind when using the library.\r\n\r\n### Documentation\r\nTo learn more about QubiPy and its complete use, please visit our official [documentation](https://qubipy.readthedocs.io/en/latest/).\r\n\r\n### Requirements\r\nTo install the necessary dependencies, run this command in the console :\r\n```\r\n$ pip install -r requirements.txt\r\n```\r\n\r\n### How to use\r\nYou have two ways to use QubiPy, one is by [PyPi](https://pypi.org/project/QubiPy/) or by cloning the project from the official repository.\r\n\r\nTo use the module, it is necessary to import some classes before :\r\n```python\r\nfrom qubipy.rpc import rpc_client\r\nfrom qubipy.core import core_client\r\n```\r\n\r\nLet's request tick info from the RPC for example :\r\n\r\n```python\r\nRPC = rpc_client.QubiPy_RPC()\r\nprint(RPC.get_tick_info())\r\n```\r\nResponse :\r\n```python\r\n$ {\r\n  \"tick\": 16660254,\r\n  \"duration\": 1,\r\n  \"epoch\": 131,\r\n  \"initialTick\": 16640000\r\n}\r\n```\r\nLet's request the entity info from the core :\r\n```python\r\nCORE = core_client.QubiPy_Core()\r\nprint(CORE.get_entity_info('PEKBRHZQKMGCQBTAHXHZRXQRLBACJIHAGWHMPIJTZBWIJVTIWQOVMGJDTPFO'))\r\n```\r\nReponse :\r\n```python\r\n$ {\r\n  \"entity\": {\r\n    \"id\": \"PEKBRHZQKMGCQBTAHXHZRXQRLBACJIHAGWHMPIJTZBWIJVTIWQOVMGJDTPFO\",\r\n    \"incomingAmount\": \"113653127220\",\r\n    \"outgoingAmount\": \"80838490981\",\r\n    \"numberOfIncomingTransfers\": 824156,\r\n    \"numberOfOutgoingTransfers\": 422,\r\n    \"latestIncomingTransferTick\": 16613012,\r\n    \"latestOutgoingTransferTick\": 16613029\r\n  },\r\n  \"validForTick\": 16660147,\r\n  \"spectrumIndex\": 7434551,\r\n  \"siblingIds\": [\r\n    \"GIDNABDPPDFPECDPYUQZEBZONVJAXCTRQXRGHCLPNAOMEAHMULYQBQQEZRBE\",\r\n    \"WUTXDWZRYSBHOEHBZSVCWIRXSAPAZFMZSJFHOGDTIAYOPAIKGUNGIOLEVFVO\",\r\n    \"NZUUNSQJEAXQAACZVEGHEHDNQRLDZRHXDJKCJLCXODFQQJTHGCMIRZDFAXBD\",\r\n    \"HFSHRQUTQONGFDTXKPPAGHEMJSHBLTWVQKZMKVGYYEDSTPBIRBTMHSRCUKUO\",\r\n    \"PGXXITTPEGARXGSHDTBVFYRVBXFHZBXPIQQNBQKJHEGXZGDTTCYGITFGSKBG\",\r\n    \"EFEDDOBGUVASHBTCYRCUZOXQTLUDMKMCEYFHDLETIFAUDPLYOZYQUPEBAXGC\",\r\n    \"DNYAQMGQRFCUMBUCEIFRNYSCYUXDWNWTTLFQQFDCEBVCTOWGLVXLCNBESPJE\",\r\n    \"MSWZOKQKAWZUECKOEWOPMNUBSQSDAHTHYIFMSYRRKBZSJJLHLECBOUUDNNHO\",\r\n    \"RGHPZOHWBHKIICUGBENRQPKDJHJDLIFKETGMKMPMTAJGRTPIOKCPETRDPBME\",\r\n    \"CADVHWJMDNOJJGPDAVPYOUNDPWEABLSDLPGHCWJWGDFTYIVFBAZIBTDBQKVL\",\r\n    \"AEMCJNNWDXBRSFEZVXAHFDPLNBJHMMMDBLKPVETCQFCZFJWEVEEXANUBUMCM\",\r\n    \"BTOZFRHDVNYUVAMHNBBZJTNMCVZBORRPFNQIZZPRDEMHIFPWTFSARQVBMATC\",\r\n    \"SHWFJGOAMBUIJDDSKCWAMOIWBNJHUUDHRDDHRBORSDCCSJLSSCDGXOKCVWMB\",\r\n    \"XTOYTMZTUTPPVGBWYCVIFDVMLLWFIMXRZKOGUHJLADMIKLZTIPQJPLKCGVUB\",\r\n    \"ZVBYCOZKUMZRTBIAYVWUTWUGYNQEPASOMENYCCERUDCYFHKMIQDLCVNCZCVA\",\r\n    \"GHGNSBIOBLCIRGBBEKQZOSTKXJGHXWUYVNLRCTSBUENITLCSDIBNSDBBITQL\",\r\n    \"PKFLHUYXWAELGGXBXTRRASNCQZSEDURLIUXKEDHTYFAIASIPPTSBVYMCQTWB\",\r\n    \"OCOVEQIPGTUPIBAYGYDOSAWXWIGBKDBVKIFARQSHWAUUYSYVLKZITMZCMHCI\",\r\n    \"NAPHRLGCLNNKVERLZDIGIFADQSLAZYUULTBAGCDYEEDSBFZGCCLXZXDGSBKK\",\r\n    \"IGIZMDVOTFEJTFXHXURCUXNOSCDFJJJHTTTSRGABECNPKMJFZQTTEKOBSDFH\",\r\n    \"OHEMQVDLSQLQQAVHTYOKFPZUOHIBNBWJITCHETOBUAAPWWFSYACPPSMEHSEE\",\r\n    \"LPJMDKCKOOYGBFAEXDRZCALQUIIALWMHFSAEJUUBKBQXRPDYCXEXKMYDDJIO\",\r\n    \"HGDFFPYTXOKSMGYMXPFEPLCQXXLDRULLJEIAYOVZBFABJIYZHVNSLRAENXUG\",\r\n    \"ZQLSECAGXOUHNEFFBATFQIBYAYYDECSPKVHNGGJIPEGNSIUWNORASTNAUFYL\"\r\n  ]\r\n}\r\n\r\n```\r\n\r\n### Technical notes\r\nThis library is using `crypto.dll` which is a C extension of Qubic key utility functions and bind it to Python. To build this `crypto.dll`, this repository was used: [https://github.com/serendipity-seeker/key-utils-binding](https://github.com/serendipity-seeker/key-utils-binding).\r\n\r\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "QubiPy, a Python Library for the QUBIC RPC API",
    "version": "0.2.4",
    "project_urls": {
        "Bug Tracker": "https://github.com/QubiPy-Labs/QubiPy/issues",
        "Documentation": "https://qubipy.readthedocs.io",
        "Homepage": "https://github.com/QubiPy-Labs/QubiPy",
        "Source Code": "https://github.com/QubiPy-Labs/QubiPy"
    },
    "split_keywords": [
        "qubic",
        " blockchain",
        " rpc",
        " api",
        " cryptocurrency"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "70adecf3b193b0ed06bbff56d44be7c9d466b6b5bd7881a8725d761a5882a6bc",
                "md5": "7e1f2f4a70c235e26ae728ae00ddb4db",
                "sha256": "0403fc2035c5738a7fb19b27cffbac0cfce6cb0231c5e7254700a282ed8d412c"
            },
            "downloads": -1,
            "filename": "QubiPy-0.2.4-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "7e1f2f4a70c235e26ae728ae00ddb4db",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.10",
            "size": 255136,
            "upload_time": "2024-12-21T13:35:08",
            "upload_time_iso_8601": "2024-12-21T13:35:08.022172Z",
            "url": "https://files.pythonhosted.org/packages/70/ad/ecf3b193b0ed06bbff56d44be7c9d466b6b5bd7881a8725d761a5882a6bc/QubiPy-0.2.4-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "81013abff02fbd291e319eea284d334d8d46143d5bc44d4571d3acba765493e3",
                "md5": "6431e6ccbae7639dfac3a0963050d2ef",
                "sha256": "6fd7dda4199806380e720e7c16f8e723cab00cffb0d2c74ae9bcfe7f11988f73"
            },
            "downloads": -1,
            "filename": "qubipy-0.2.4.tar.gz",
            "has_sig": false,
            "md5_digest": "6431e6ccbae7639dfac3a0963050d2ef",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.10",
            "size": 253632,
            "upload_time": "2024-12-21T13:35:10",
            "upload_time_iso_8601": "2024-12-21T13:35:10.633364Z",
            "url": "https://files.pythonhosted.org/packages/81/01/3abff02fbd291e319eea284d334d8d46143d5bc44d4571d3acba765493e3/qubipy-0.2.4.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-12-21 13:35:10",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "QubiPy-Labs",
    "github_project": "QubiPy",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [
        {
            "name": "requests",
            "specs": [
                [
                    "==",
                    "2.32.3"
                ]
            ]
        },
        {
            "name": "urllib3",
            "specs": [
                [
                    "==",
                    "2.2.3"
                ]
            ]
        },
        {
            "name": "certifi",
            "specs": [
                [
                    "==",
                    "2024.8.30"
                ]
            ]
        },
        {
            "name": "charset-normalizer",
            "specs": [
                [
                    "==",
                    "3.4.0"
                ]
            ]
        },
        {
            "name": "idna",
            "specs": [
                [
                    "==",
                    "3.10"
                ]
            ]
        },
        {
            "name": "pytest",
            "specs": [
                [
                    "==",
                    "8.3.3"
                ]
            ]
        },
        {
            "name": "pytest-mock",
            "specs": [
                [
                    "==",
                    "3.14.0"
                ]
            ]
        },
        {
            "name": "pytest-sugar",
            "specs": [
                [
                    "==",
                    "1.0.0"
                ]
            ]
        },
        {
            "name": "iniconfig",
            "specs": [
                [
                    "==",
                    "2.0.0"
                ]
            ]
        },
        {
            "name": "pluggy",
            "specs": [
                [
                    "==",
                    "1.5.0"
                ]
            ]
        },
        {
            "name": "black",
            "specs": [
                [
                    "==",
                    "24.10.0"
                ]
            ]
        },
        {
            "name": "setuptools",
            "specs": [
                [
                    "==",
                    "75.3.0"
                ]
            ]
        },
        {
            "name": "watchdog",
            "specs": [
                [
                    "==",
                    "6.0.0"
                ]
            ]
        }
    ],
    "lcname": "qubipy"
}
        
Elapsed time: 0.47292s