A simple wrapper for the Torn API
Project description
Simple Torn Wrapper
A simple basis wrapper for the torn API. Handles sending and converting the response into a Python dictionary.
Example
An example of the usage:
from simple_torn_wrapper import TornWrapper
wrapper = TornWrapper(api_key='API_KEY') # Find your API key in Torn
selections = ['selection1','selection2'] # Examples of selections are listed in the Torn API.
section = 'user' # Other sections can be found in Torn API
data = wrapper.request(section, id, selections)
Request also accepts parameters tsfrom and tsto for a timestamp search range.
These can be chosen from the API as referenced on: https://www.torn.com/api.html#. Section is one of the 6 main categories and selections should be a list of strings.
Issues and Contact
- Discord @ https://discord.gg/myTajWNU6q
- issue @ https://github.com/SolitudalDeveloper/SimpleTorn/issues
- email @ innominatusofficial@gmail.com
Development
To develop onto this repository, feel free to fork/clone. Pipfile has all requirements. Testing is done using Pytest.
Will add guide on development setup later.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file simple-torn-wrapper-0.0.4.tar.gz.
File metadata
- Download URL: simple-torn-wrapper-0.0.4.tar.gz
- Upload date:
- Size: 3.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.10.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fefeb73bb586297d96403ae68071290973ee859f3d0470a31af29cafbefa8fa5
|
|
| MD5 |
9959f00dd6df20d606cb0eda848bf025
|
|
| BLAKE2b-256 |
78fee2957ac09fe73fdcd1749a69d32a3b7d6976cf842b75edf755b185813782
|
File details
Details for the file simple_torn_wrapper-0.0.4-py3-none-any.whl.
File metadata
- Download URL: simple_torn_wrapper-0.0.4-py3-none-any.whl
- Upload date:
- Size: 4.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.10.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
15dcd5c7036fb7b2f1260887cf4faabd65915edda8b95e6dbd7457f7fb90ed3a
|
|
| MD5 |
c7a6ff7eeed762b27d25ee4f69ac8a53
|
|
| BLAKE2b-256 |
5adee143f4fbd938a7000884261e46a5c33852bb9bb40f14691d1ba62a0d3e9b
|