Name | tappd-client JSON |
Version |
0.1.2
JSON |
| download |
home_page | None |
Summary | Python client for Tappd in DStack CVM |
upload_time | 2024-11-12 03:09:49 |
maintainer | None |
docs_url | None |
author | None |
requires_python | >=3.7 |
license | None |
keywords |
dstack
tappd
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# Tappd Client
A Python client for interacting with the Tappd daemon via Unix socket communication.
## Installation
```bash
pip install tappd-client
```
## Usage
```python
from tappd_client import TappdClient
# Initialize the client
client = TappdClient() # Default socket path: /var/run/tappd.sock
# Or specify custom socket path
client = TappdClient(socket_path='/custom/path/tappd.sock')
# Get TDX quote
# Using binary data
binary_data = b'Hello World'
response = client.tdx_quote(binary_data)
# Using string data
string_data = "Hello World"
response = client.tdx_quote(string_data)
# Get the quote
quote = response.quote
# Get event log
event_log = response.event_log
# Replay RTMRS from the event log
rtmrs = response.replay_rtmrs()
RTMR0 = rtmrs[0]
RTMR1 = rtmrs[1]
RTMR2 = rtmrs[2]
RTMR3 = rtmrs[3]
```
## License
This project is licensed under the MIT License. See the LICENSE file for more details.
Raw data
{
"_id": null,
"home_page": null,
"name": "tappd-client",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.7",
"maintainer_email": null,
"keywords": "dstack, tappd",
"author": null,
"author_email": "Kevin Wang <wy721@qq.com>",
"download_url": "https://files.pythonhosted.org/packages/ec/30/873f08f31360c8a8264ca24fe27503d2c5cc84bf955bd12f2b5ece45f105/tappd_client-0.1.2.tar.gz",
"platform": null,
"description": "# Tappd Client\n\nA Python client for interacting with the Tappd daemon via Unix socket communication.\n\n## Installation\n\n```bash\npip install tappd-client\n```\n\n## Usage\n\n```python\nfrom tappd_client import TappdClient\n\n# Initialize the client\nclient = TappdClient() # Default socket path: /var/run/tappd.sock\n# Or specify custom socket path\nclient = TappdClient(socket_path='/custom/path/tappd.sock')\n\n# Get TDX quote\n# Using binary data\nbinary_data = b'Hello World'\nresponse = client.tdx_quote(binary_data)\n\n# Using string data\nstring_data = \"Hello World\"\nresponse = client.tdx_quote(string_data)\n\n# Get the quote\nquote = response.quote\n\n# Get event log\nevent_log = response.event_log\n\n# Replay RTMRS from the event log\nrtmrs = response.replay_rtmrs()\nRTMR0 = rtmrs[0]\nRTMR1 = rtmrs[1]\nRTMR2 = rtmrs[2]\nRTMR3 = rtmrs[3]\n```\n\n## License\n\nThis project is licensed under the MIT License. See the LICENSE file for more details.\n",
"bugtrack_url": null,
"license": null,
"summary": "Python client for Tappd in DStack CVM",
"version": "0.1.2",
"project_urls": null,
"split_keywords": [
"dstack",
" tappd"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "cd2b1ddc7e3fed5c6fbf56f54c00423a0db2fe9f36c236a0d3491da05c7cc78d",
"md5": "941319a69c648b9dfac6e12ea856d867",
"sha256": "34a9d9edc5e6b08b4e71eca790ca5a7638a7e95ad2969bf01084938b2e63ec94"
},
"downloads": -1,
"filename": "tappd_client-0.1.2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "941319a69c648b9dfac6e12ea856d867",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.7",
"size": 3080,
"upload_time": "2024-11-12T03:09:47",
"upload_time_iso_8601": "2024-11-12T03:09:47.733480Z",
"url": "https://files.pythonhosted.org/packages/cd/2b/1ddc7e3fed5c6fbf56f54c00423a0db2fe9f36c236a0d3491da05c7cc78d/tappd_client-0.1.2-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "ec30873f08f31360c8a8264ca24fe27503d2c5cc84bf955bd12f2b5ece45f105",
"md5": "2661faf38d11a7473b99495ffc2b7c4d",
"sha256": "4d49d5df7f708aaeaa449a82e40552acdd8b6c36eb84e9488424481013ecf238"
},
"downloads": -1,
"filename": "tappd_client-0.1.2.tar.gz",
"has_sig": false,
"md5_digest": "2661faf38d11a7473b99495ffc2b7c4d",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.7",
"size": 2631,
"upload_time": "2024-11-12T03:09:49",
"upload_time_iso_8601": "2024-11-12T03:09:49.911628Z",
"url": "https://files.pythonhosted.org/packages/ec/30/873f08f31360c8a8264ca24fe27503d2c5cc84bf955bd12f2b5ece45f105/tappd_client-0.1.2.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-11-12 03:09:49",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "tappd-client"
}