A Python API library for Soteria, world's safest Twitter.
Project description
Pyteria
Example
import asyncio
import soteria
async def main():
cache = soteria.MemoryCache()
client = soteria.Client(auth="<TOKEN HERE>", cache=cache)
# fetch a user from the api
user = await soteria.User.fetch(client, 12345)
print(user)
# fetch the list of followers
followers = await user.fetch_followers()
print(followers)
# you can always access the cached list of followers if async is not allowed
print(user.followers)
# remember to close the client after execution
await client.close()
asyncio.run(main())
Features
- Mostly complete coverage of the Soteria API.
- Caching support with customiziable cache implementations.
- Complete type safety with your favorite type checker. 🚀
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
pyteria-0.1.0.tar.gz
(7.4 kB
view hashes)
Built Distribution
pyteria-0.1.0-py3-none-any.whl
(10.8 kB
view hashes)