Firipy is a Python wrapper for the Firi API. It provides a simple and intuitive way to interact with the Firi cryptocurrency exchange, allowing users to retrieve market data, manage orders, and more. With Firipy, you can easily integrate Firi's features into your Python applications.
Project description
FiriAPI
FiriAPI is a Python client for the Firi API.
📦 Installation
You can install FiriAPI using pip:
pip install firipy
🚀 Usage
First, import the FiriAPI
class from the firipy
module:
from firipy import FiriAPI
Then, initialize the client with your API token from Firi:
client = FiriAPI("your-token")
Now you can use the client to interact with the Firi API. For example, to get the current time:
time = client.time()
print(time)
To get history over all transactions:
history = client.history_transactions()
print(history)
To get balances:
balances = client.balances()
print(balances)
⏳ Rate Limiting
FiriAPI includes a rate limit, which is the number of seconds to wait between requests. By default, this is set to 1 second. You can change this when you initialize the client:
client = FiriAPI("your-token", rate_limit=2) # wait 2 seconds between requests
🚩 Error Handling
FiriAPI handles HTTP errors using the requests.Response.raise_for_status
method.
If a request fails, this method raises a requests.HTTPError
exception.
The client catches this exception and prints an error message.
The client also handles other exceptions that might occur during the execution of a request, and prints an error message in these cases.
🔥 Contributing
Contributions to FiriAPI are welcome! Please submit a pull request or create an issue on the GitHub page.
📝 Disclaimer
This client was developed by Ove Aursland and is not officially associated with Firi.
Project details
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
File details
Details for the file firipy-0.0.9.tar.gz
.
File metadata
- Download URL: firipy-0.0.9.tar.gz
- Upload date:
- Size: 5.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 385ca5bceee6d888dd8380d2320269267b058330e04edf2f127b233da8f3f675 |
|
MD5 | 7e4d07f6b5faee9cfc058a25653dc479 |
|
BLAKE2b-256 | b51e6168566be2a42107f98eadd9bce23dc24a49b8272f6300c3138c53af66e1 |
File details
Details for the file firipy-0.0.9-py3-none-any.whl
.
File metadata
- Download URL: firipy-0.0.9-py3-none-any.whl
- Upload date:
- Size: 4.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9338fcb247207a99e15f66aad78671a16ea01e590c952280db4b789a0ef4107f |
|
MD5 | ff153fe470db9f405370e350350a887d |
|
BLAKE2b-256 | aca4e8ba99e0612c872da34ea1906054e617c90ccd9bb0b4634523e77fc77409 |