ostium-python-sdk 0.1.22__tar.gz → 0.1.23__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/PKG-INFO +4 -5
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/README.md +3 -4
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk.egg-info/PKG-INFO +4 -5
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/setup.py +1 -1
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk/__init__.py +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk/abi.py +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk/balance.py +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk/config.py +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk/constants.py +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk/formulae.py +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk/formulae_wrapper.py +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk/ostium.py +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk/price.py +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk/sdk.py +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk/subgraph.py +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk/utils.py +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk.egg-info/SOURCES.txt +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk.egg-info/dependency_links.txt +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk.egg-info/requires.txt +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk.egg-info/top_level.txt +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/pyproject.toml +0 -0
- {ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: ostium-python-sdk
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.23
|
|
4
4
|
Summary: A python based SDK developed for interacting with Ostium, a leveraged trading application for trading currencies, commodities, indices, crypto and more.
|
|
5
5
|
Home-page: https://github.com/0xOstium/ostium-python-sdk
|
|
6
6
|
Author: ami@ostium.io
|
|
@@ -224,7 +224,7 @@ except Exception as e:
|
|
|
224
224
|
|
|
225
225
|
### Create a Short ETH Limit Order
|
|
226
226
|
|
|
227
|
-
This example shows how to create a short ETH limit order, 10%
|
|
227
|
+
This example shows how to create a short ETH limit order, 10% above the current ETHUSD price. So if price goes up 10% we order a Short ETH trade.
|
|
228
228
|
|
|
229
229
|
```python
|
|
230
230
|
# Get private key from environment variable
|
|
@@ -253,7 +253,7 @@ try:
|
|
|
253
253
|
# Get latest price for ETH
|
|
254
254
|
latest_price, _ = await sdk.price.get_price("ETH", "USD")
|
|
255
255
|
print(f"Latest price: {latest_price}")
|
|
256
|
-
# Execute trade at current
|
|
256
|
+
# Execute LIMIT trade order at 10% above the current price
|
|
257
257
|
receipt = sdk.ostium.perform_trade(order_params, at_price=latest_price * 1.1)
|
|
258
258
|
print(
|
|
259
259
|
f"Order successful! Transaction hash: {receipt['transactionHash'].hex()}")
|
|
@@ -281,8 +281,7 @@ except Exception as e:
|
|
|
281
281
|
print(f"Order failed: {str(e)}")
|
|
282
282
|
```
|
|
283
283
|
|
|
284
|
-
<b>NOTE:</b> Similiarly you can create a Stop order, just use 'STOP' as the order_type and make sure at_price is set to
|
|
285
|
-
|
|
284
|
+
<b>NOTE:</b> Similiarly you can create a Stop order, just use 'STOP' as the order_type and make sure at_price is set to an acceptable stop loss price.
|
|
286
285
|
|
|
287
286
|
|
|
288
287
|
## Example Usage Scripts
|
|
@@ -209,7 +209,7 @@ except Exception as e:
|
|
|
209
209
|
|
|
210
210
|
### Create a Short ETH Limit Order
|
|
211
211
|
|
|
212
|
-
This example shows how to create a short ETH limit order, 10%
|
|
212
|
+
This example shows how to create a short ETH limit order, 10% above the current ETHUSD price. So if price goes up 10% we order a Short ETH trade.
|
|
213
213
|
|
|
214
214
|
```python
|
|
215
215
|
# Get private key from environment variable
|
|
@@ -238,7 +238,7 @@ try:
|
|
|
238
238
|
# Get latest price for ETH
|
|
239
239
|
latest_price, _ = await sdk.price.get_price("ETH", "USD")
|
|
240
240
|
print(f"Latest price: {latest_price}")
|
|
241
|
-
# Execute trade at current
|
|
241
|
+
# Execute LIMIT trade order at 10% above the current price
|
|
242
242
|
receipt = sdk.ostium.perform_trade(order_params, at_price=latest_price * 1.1)
|
|
243
243
|
print(
|
|
244
244
|
f"Order successful! Transaction hash: {receipt['transactionHash'].hex()}")
|
|
@@ -266,8 +266,7 @@ except Exception as e:
|
|
|
266
266
|
print(f"Order failed: {str(e)}")
|
|
267
267
|
```
|
|
268
268
|
|
|
269
|
-
<b>NOTE:</b> Similiarly you can create a Stop order, just use 'STOP' as the order_type and make sure at_price is set to
|
|
270
|
-
|
|
269
|
+
<b>NOTE:</b> Similiarly you can create a Stop order, just use 'STOP' as the order_type and make sure at_price is set to an acceptable stop loss price.
|
|
271
270
|
|
|
272
271
|
|
|
273
272
|
## Example Usage Scripts
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: ostium-python-sdk
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.23
|
|
4
4
|
Summary: A python based SDK developed for interacting with Ostium, a leveraged trading application for trading currencies, commodities, indices, crypto and more.
|
|
5
5
|
Home-page: https://github.com/0xOstium/ostium-python-sdk
|
|
6
6
|
Author: ami@ostium.io
|
|
@@ -224,7 +224,7 @@ except Exception as e:
|
|
|
224
224
|
|
|
225
225
|
### Create a Short ETH Limit Order
|
|
226
226
|
|
|
227
|
-
This example shows how to create a short ETH limit order, 10%
|
|
227
|
+
This example shows how to create a short ETH limit order, 10% above the current ETHUSD price. So if price goes up 10% we order a Short ETH trade.
|
|
228
228
|
|
|
229
229
|
```python
|
|
230
230
|
# Get private key from environment variable
|
|
@@ -253,7 +253,7 @@ try:
|
|
|
253
253
|
# Get latest price for ETH
|
|
254
254
|
latest_price, _ = await sdk.price.get_price("ETH", "USD")
|
|
255
255
|
print(f"Latest price: {latest_price}")
|
|
256
|
-
# Execute trade at current
|
|
256
|
+
# Execute LIMIT trade order at 10% above the current price
|
|
257
257
|
receipt = sdk.ostium.perform_trade(order_params, at_price=latest_price * 1.1)
|
|
258
258
|
print(
|
|
259
259
|
f"Order successful! Transaction hash: {receipt['transactionHash'].hex()}")
|
|
@@ -281,8 +281,7 @@ except Exception as e:
|
|
|
281
281
|
print(f"Order failed: {str(e)}")
|
|
282
282
|
```
|
|
283
283
|
|
|
284
|
-
<b>NOTE:</b> Similiarly you can create a Stop order, just use 'STOP' as the order_type and make sure at_price is set to
|
|
285
|
-
|
|
284
|
+
<b>NOTE:</b> Similiarly you can create a Stop order, just use 'STOP' as the order_type and make sure at_price is set to an acceptable stop loss price.
|
|
286
285
|
|
|
287
286
|
|
|
288
287
|
## Example Usage Scripts
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
{ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk.egg-info/requires.txt
RENAMED
|
File without changes
|
{ostium_python_sdk-0.1.22 → ostium_python_sdk-0.1.23}/ostium_python_sdk.egg-info/top_level.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|