A Python API wrapper for Suvvy AI API
Project description
An async API wrapper for Suvvy AI
built on top of httpx and pydantic :)
Installation
pip install -U suvvyapi
Synchronous Usage
from suvvyapi import SuvvyAPIWrapper, Message
suvvy = SuvvyAPIWrapper("YOUR_TOKEN")
# You can get your token at https://home.suvvy.ai/
response = suvvy.predict(Message(text="Say hello to Python!"), "random_id")
# 'Hello!'
Asynchronous Usage
import asyncio
from suvvyapi import AsyncSuvvyAPIWrapper, Message
suvvy = AsyncSuvvyAPIWrapper("YOUR_TOKEN")
# You can get your token at https://home.suvvy.ai/
async def main():
response = await suvvy.predict(Message(text="Say hello to Python!"), "random_id")
# 'Hello!'
asyncio.run(main())
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
suvvyapi-0.1a3.tar.gz
(6.6 kB
view details)
Built Distribution
File details
Details for the file suvvyapi-0.1a3.tar.gz
.
File metadata
- Download URL: suvvyapi-0.1a3.tar.gz
- Upload date:
- Size: 6.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6914ef71cd9842646b0406fc8604240a41a99525e77eba3ff94d4516a5793ab8 |
|
MD5 | 7a2457c1b7bc71c80b215ee16a23c9e2 |
|
BLAKE2b-256 | 08b309088c1362c3989edf5cdd6bdebe648c7b7ea8d32569c9c14f82c87c15c2 |
Provenance
File details
Details for the file suvvyapi-0.1a3-py3-none-any.whl
.
File metadata
- Download URL: suvvyapi-0.1a3-py3-none-any.whl
- Upload date:
- Size: 8.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 06f2b069f7b56a2159da0f958ddc7467a92f885eb71d2f79f647fbcdd1408a9e |
|
MD5 | f92e48b0f02b3117f5046321d4e072df |
|
BLAKE2b-256 | 46b0743a946b7c01b22d0bc2ae77ed05f22c0fb6fec22f168463d235db845258 |