forked from kodorvan/stcs
Added API key verification for permissions
This commit is contained in:
@@ -109,6 +109,7 @@ async def start_trading_cycle(
|
||||
"The number of contracts exceeds maximum limit allowed",
|
||||
"The number of contracts exceeds minimum limit allowed",
|
||||
"Order placement failed as your position may exceed the max",
|
||||
"Permission denied, please check your API key permissions"
|
||||
}
|
||||
else None
|
||||
)
|
||||
@@ -371,6 +372,7 @@ async def open_positions(
|
||||
"The number of contracts exceeds maximum limit allowed": "The number of contracts exceeds maximum limit allowed",
|
||||
"The number of contracts exceeds minimum limit allowed": "The number of contracts exceeds minimum limit allowed",
|
||||
"Order placement failed as your position may exceed the max": "Order placement failed as your position may exceed the max",
|
||||
"Permission denied, please check your API key permissions": "Permission denied, please check your API key permissions"
|
||||
}
|
||||
for key, msg in known_errors.items():
|
||||
if key in error_text:
|
||||
|
||||
Reference in New Issue
Block a user