No project description provided
Project description
sunny-order-splitter-python-sdk
安装
pip install sunny-order-splitter --upgrade
使用
from sunny_order_splitter.core import SunnyOrderSplitter
def main():
platform = "BINANCE"
base_url = "https://api.binance.com"
#base_url = "https://testnet.binance.vision"
api_key = "Q9TdT7Tl9KaoFBWaxJ6Rlt8N4fEurKYeBsYfUhXgTRSFMZWzbWa14kybz5vLebCk"
secret_key = "9UJ7Vx3SZRF6mvmmLGksR08UMChTiWZG3fyA4JdsyK4pWKsnuqXQwk7N3q8mBw43"
symbol = 'NOTUSDT'
#base_url 可不传,默认正式环境
sos = SunnyOrderSplitter(platform, symbol, api_key, secret_key, base_url)
params = {
"side": "BUY",
"orderAmount": 20, # USDT 金额
"totalAmount": 85, # USDT 金额
"interval": 5 #秒
}
"""
params = {
"side": "SELL",
"orderAmount": 1000, #NOT 数量
"totalAmount": 4100, #NOT 数量
"interval": 5
}
"""
if not sos.split_order(params):
print("One or more orders failed.")
else:
print("All orders placed successfully.")
if __name__ == "__main__":
main()
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 sunny_order_splitter-0.1.3.tar.gz
.
File metadata
- Download URL: sunny_order_splitter-0.1.3.tar.gz
- Upload date:
- Size: 3.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7e713dab4682d83ee387190d8e2bf7ff6561224ce69016d8a4d651d4e2b2cbcb |
|
MD5 | d07e444ac31508aee252b6cf564d592d |
|
BLAKE2b-256 | 355395e382e8489c073e3da9464d67d1200241bd81ce3cf67cffd91dfffaa2cc |
File details
Details for the file sunny_order_splitter-0.1.3-py3-none-any.whl
.
File metadata
- Download URL: sunny_order_splitter-0.1.3-py3-none-any.whl
- Upload date:
- Size: 3.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a8006feb8d57afb6d789771dd96aef93c14a7dbefbe65e8800f6d88e8bd634a2 |
|
MD5 | 5817654940463074ef86835ab5c4847f |
|
BLAKE2b-256 | 029156a6716e23fabdc9b2d30b2c2fce19d98b400716b3c56587adc4bb64100e |