mirror of
https://github.com/NoFxAiOS/nofx.git
synced 2026-07-13 07:46:54 +08:00
feat: fix Lighter V2 integration and improve error handling
- Fix Lighter API field name mismatches (position/size, avg_entry_price/entry_price, sign/side) - Fix GetBalance return format to match standard fields (totalWalletBalance, totalUnrealizedProfit) - Fix GetPositions return format to match standard fields (positionAmt, markPrice, unRealizedProfit) - Add API Key Index field to frontend with explanation - Update Lighter referral link - Disable Lighter testnet (mainnet only) - Add load error tracking for better error messages - Remove old Lighter V1 implementation files - Remove test credentials from test files
This commit is contained in:
@@ -131,6 +131,7 @@ export interface Exchange {
|
||||
lighterWalletAddr?: string
|
||||
lighterPrivateKey?: string
|
||||
lighterApiKeyPrivateKey?: string
|
||||
lighterApiKeyIndex?: number
|
||||
}
|
||||
|
||||
export interface CreateExchangeRequest {
|
||||
@@ -148,6 +149,7 @@ export interface CreateExchangeRequest {
|
||||
lighter_wallet_addr?: string
|
||||
lighter_private_key?: string
|
||||
lighter_api_key_private_key?: string
|
||||
lighter_api_key_index?: number
|
||||
}
|
||||
|
||||
export interface CreateTraderRequest {
|
||||
@@ -199,6 +201,7 @@ export interface UpdateExchangeConfigRequest {
|
||||
lighter_wallet_addr?: string
|
||||
lighter_private_key?: string
|
||||
lighter_api_key_private_key?: string
|
||||
lighter_api_key_index?: number
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user