gateio-api 1.2.5 → 1.2.7

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.
package/llms.txt CHANGED
@@ -588,6 +588,8 @@ export async function signMessage(
588
588
  method: SignEncodeMethod,
589
589
  algorithm: SignAlgorithm,
590
590
  ): Promise<string>
591
+ ⋮----
592
+ export function checkWebCryptoAPISupported()
591
593
 
592
594
  ================
593
595
  File: src/types/request/account.ts
@@ -3281,173 +3283,6 @@ export interface StpGroupUser {
3281
3283
  create_time: number;
3282
3284
  }
3283
3285
 
3284
- ================
3285
- File: src/types/response/delivery.ts
3286
- ================
3287
- /**==========================================================================================================================
3288
- * DELIVERY
3289
- * ==========================================================================================================================
3290
- */
3291
- ⋮----
3292
- export interface DeliveryOrderBook {
3293
- id?: number;
3294
- current: number;
3295
- update: number;
3296
- asks: { p: string; s: number }[];
3297
- bids: { p: string; s: number }[];
3298
- }
3299
- ⋮----
3300
- export interface DeliveryTrade {
3301
- id: number;
3302
- create_time: number;
3303
- create_time_ms: number;
3304
- contract: string;
3305
- size: number;
3306
- price: string;
3307
- is_internal?: boolean;
3308
- }
3309
- ⋮----
3310
- export interface DeliveryCandle {
3311
- t: number;
3312
- v?: number;
3313
- c: string;
3314
- h: string;
3315
- l: string;
3316
- o: string;
3317
- }
3318
- ⋮----
3319
- export interface DeliveryTicker {
3320
- contract: string;
3321
- last: string;
3322
- change_percentage: string;
3323
- total_size: string;
3324
- low_24h: string;
3325
- high_24h: string;
3326
- volume_24h: string;
3327
- volume_24h_btc?: string;
3328
- volume_24h_usd?: string;
3329
- volume_24h_base: string;
3330
- volume_24h_quote: string;
3331
- volume_24h_settle: string;
3332
- mark_price: string;
3333
- funding_rate: string;
3334
- funding_rate_indicative: string;
3335
- index_price: string;
3336
- quanto_base_rate?: string;
3337
- basis_rate: string;
3338
- basis_value: string;
3339
- lowest_ask: string;
3340
- highest_bid: string;
3341
- }
3342
- ⋮----
3343
- export interface DeliveryAccount {
3344
- total: string;
3345
- unrealised_pnl: string;
3346
- position_margin: string;
3347
- order_margin: string;
3348
- available: string;
3349
- point: string;
3350
- currency: string;
3351
- in_dual_mode: boolean;
3352
- enable_credit: boolean;
3353
- position_initial_margin: string;
3354
- maintenance_margin: string;
3355
- bonus: string;
3356
- enable_evolved_classic: boolean;
3357
- cross_order_margin: string;
3358
- cross_initial_margin: string;
3359
- cross_maintenance_margin: string;
3360
- cross_unrealised_pnl: string;
3361
- cross_available: string;
3362
- isolated_position_margin: string;
3363
- history: {
3364
- dnw: string;
3365
- pnl: string;
3366
- fee: string;
3367
- refr: string;
3368
- fund: string;
3369
- point_dnw: string;
3370
- point_fee: string;
3371
- point_refr: string;
3372
- bonus_dnw: string;
3373
- bonus_offset: string;
3374
- };
3375
- }
3376
- ⋮----
3377
- export interface DeliveryBook {
3378
- time: number;
3379
- change: string;
3380
- balance: string;
3381
- type:
3382
- | 'dnw'
3383
- | 'pnl'
3384
- | 'fee'
3385
- | 'refr'
3386
- | 'fund'
3387
- | 'point_dnw'
3388
- | 'point_fee'
3389
- | 'point_refr'
3390
- | 'bonus_offset';
3391
- text: string;
3392
- contract?: string;
3393
- trade_id?: string;
3394
- }
3395
- ⋮----
3396
- export interface DeliveryTradingHistoryRecord {
3397
- id: number;
3398
- create_time: number;
3399
- contract: string;
3400
- order_id: string;
3401
- size: number;
3402
- price: string;
3403
- role: 'taker' | 'maker';
3404
- text: string;
3405
- fee: string;
3406
- point_fee: string;
3407
- }
3408
- ⋮----
3409
- export interface DeliveryClosedPosition {
3410
- time: number;
3411
- contract: string;
3412
- side: 'long' | 'short';
3413
- pnl: string;
3414
- pnl_pnl: string;
3415
- pnl_fund: string;
3416
- pnl_fee: string;
3417
- text: string;
3418
- max_size: string;
3419
- first_open_time: number;
3420
- long_price: string;
3421
- short_price: string;
3422
- }
3423
- ⋮----
3424
- export interface DeliveryLiquidationHistoryRecord {
3425
- time: number;
3426
- contract: string;
3427
- leverage?: string;
3428
- size: number;
3429
- margin?: string;
3430
- entry_price?: string;
3431
- liq_price?: string;
3432
- mark_price?: string;
3433
- order_id?: number;
3434
- order_price: string;
3435
- fill_price: string;
3436
- left: number;
3437
- }
3438
- ⋮----
3439
- export interface DeliverySettlementHistoryRecord {
3440
- time: number;
3441
- contract: string;
3442
- leverage: string;
3443
- size: number;
3444
- margin: string;
3445
- entry_price: string;
3446
- settle_price: string;
3447
- profit: string;
3448
- fee: string;
3449
- }
3450
-
3451
3286
  ================
3452
3287
  File: src/types/response/earn.ts
3453
3288
  ================
@@ -3738,6 +3573,223 @@ export interface PartnerTransaction {
3738
3573
  source: string;
3739
3574
  }
3740
3575
 
3576
+ ================
3577
+ File: src/types/response/wallet.ts
3578
+ ================
3579
+ export interface CurrencyChain {
3580
+ chain: string;
3581
+ name_cn: string;
3582
+ name_en: string;
3583
+ contract_address: string;
3584
+ is_disabled: number;
3585
+ is_deposit_disabled: number;
3586
+ is_withdraw_disabled: number;
3587
+ decimal: string;
3588
+ }
3589
+ ⋮----
3590
+ export interface CreateDepositAddressResp {
3591
+ currency: string;
3592
+ address: string;
3593
+ multichain_addresses: {
3594
+ chain: string;
3595
+ address: string;
3596
+ payment_id: string;
3597
+ payment_name: string;
3598
+ obtain_failed: number;
3599
+ }[];
3600
+ }
3601
+ ⋮----
3602
+ export interface SubAccountTransferRecord {
3603
+ currency: string;
3604
+ sub_account: string;
3605
+ direction: 'to' | 'from';
3606
+ amount: string;
3607
+ uid: string;
3608
+ client_order_id: string;
3609
+ timest: string;
3610
+ source: string;
3611
+ sub_account_type: 'spot' | 'futures' | 'cross_margin' | 'delivery';
3612
+ }
3613
+ ⋮----
3614
+ export interface WithdrawalStatus {
3615
+ currency: string;
3616
+ name: string;
3617
+ name_cn: string;
3618
+ deposit: string;
3619
+ withdraw_percent: string;
3620
+ withdraw_fix: string;
3621
+ withdraw_day_limit: string;
3622
+ withdraw_amount_mini: string;
3623
+ withdraw_day_limit_remain: string;
3624
+ withdraw_eachtime_limit: string;
3625
+ withdraw_fix_on_chains: { [key: string]: string };
3626
+ withdraw_percent_on_chains: { [key: string]: string };
3627
+ }
3628
+ ⋮----
3629
+ export interface SubAccountMarginBalance {
3630
+ currency_pair: string;
3631
+ locked: boolean;
3632
+ risk: string;
3633
+ base: {
3634
+ currency: string;
3635
+ available: string;
3636
+ locked: string;
3637
+ borrowed: string;
3638
+ interest: string;
3639
+ };
3640
+ quote: {
3641
+ currency: string;
3642
+ available: string;
3643
+ locked: string;
3644
+ borrowed: string;
3645
+ interest: string;
3646
+ };
3647
+ }
3648
+ ⋮----
3649
+ export interface SubAccountFuturesBalancesResp {
3650
+ uid: string;
3651
+ available: {
3652
+ [key: string]: {
3653
+ total: string;
3654
+ unrealised_pnl: string;
3655
+ position_margin: string;
3656
+ order_margin: string;
3657
+ available: string;
3658
+ point: string;
3659
+ currency: string;
3660
+ in_dual_mode: boolean;
3661
+ enable_credit: boolean;
3662
+ position_initial_margin: string;
3663
+ maintenance_margin: string;
3664
+ bonus: string;
3665
+ enable_evolved_classic: boolean;
3666
+ cross_order_margin: string;
3667
+ cross_initial_margin: string;
3668
+ cross_maintenance_margin: string;
3669
+ cross_unrealised_pnl: string;
3670
+ cross_available: string;
3671
+ isolated_position_margin: string;
3672
+ history: {
3673
+ dnw: string;
3674
+ pnl: string;
3675
+ fee: string;
3676
+ refr: string;
3677
+ fund: string;
3678
+ point_dnw: string;
3679
+ point_fee: string;
3680
+ point_refr: string;
3681
+ bonus_dnw: string;
3682
+ bonus_offset: string;
3683
+ };
3684
+ };
3685
+ };
3686
+ }
3687
+ ⋮----
3688
+ export interface SubAccountCrossMarginBalancesResp {
3689
+ uid: string;
3690
+ available: {
3691
+ user_id: number;
3692
+ locked: boolean;
3693
+ balances: {
3694
+ [key: string]: {
3695
+ available: string;
3696
+ freeze: string;
3697
+ borrowed: string;
3698
+ interest: string;
3699
+ };
3700
+ };
3701
+ total: string;
3702
+ borrowed: string;
3703
+ borrowed_net: string;
3704
+ net: string;
3705
+ leverage: string;
3706
+ interest: string;
3707
+ risk: string;
3708
+ total_initial_margin: string;
3709
+ total_margin_balance: string;
3710
+ total_maintenance_margin: string;
3711
+ total_initial_margin_rate: string;
3712
+ total_maintenance_margin_rate: string;
3713
+ total_available_margin: string;
3714
+ };
3715
+ }
3716
+ ⋮----
3717
+ export interface SavedAddress {
3718
+ currency: string;
3719
+ chain: string;
3720
+ address: string;
3721
+ name: string;
3722
+ tag: string;
3723
+ verified: string;
3724
+ }
3725
+ ⋮----
3726
+ export interface TradingFees {
3727
+ user_id: number;
3728
+ taker_fee: string;
3729
+ maker_fee: string;
3730
+ gt_discount: boolean;
3731
+ gt_taker_fee: string;
3732
+ gt_maker_fee: string;
3733
+ loan_fee: string;
3734
+ point_type: string;
3735
+ futures_taker_fee: string;
3736
+ futures_maker_fee: string;
3737
+ delivery_taker_fee: string;
3738
+ delivery_maker_fee: string;
3739
+ debit_fee: number;
3740
+ }
3741
+ ⋮----
3742
+ export interface GetBalancesResp {
3743
+ total: {
3744
+ amount: string;
3745
+ currency: string;
3746
+ unrealised_pnl?: string;
3747
+ borrowed?: string;
3748
+ };
3749
+ details: {
3750
+ [key: string]: {
3751
+ amount: string;
3752
+ currency: string;
3753
+ unrealised_pnl?: string;
3754
+ borrowed?: string;
3755
+ };
3756
+ };
3757
+ }
3758
+ ⋮----
3759
+ export interface SmallBalanceRecord {
3760
+ currency: string;
3761
+ available_balance: string;
3762
+ estimated_as_btc: string;
3763
+ convertible_to_gt: string;
3764
+ }
3765
+ ⋮----
3766
+ export interface SmallBalanceHistoryRecord {
3767
+ id: string;
3768
+ currency: string;
3769
+ amount: string;
3770
+ gt_amount: string;
3771
+ create_time: number;
3772
+ }
3773
+ ⋮----
3774
+ export interface PushOrder {
3775
+ id: number;
3776
+ push_uid: number;
3777
+ receive_uid: number;
3778
+ currency: string;
3779
+ amount: string;
3780
+ create_time: number;
3781
+ status:
3782
+ | 'CREATING'
3783
+ | 'PENDING'
3784
+ | 'CANCELLING'
3785
+ | 'CANCELLED'
3786
+ | 'REFUSING'
3787
+ | 'REFUSED'
3788
+ | 'RECEIVING'
3789
+ | 'RECEIVED';
3790
+ message: string;
3791
+ }
3792
+
3741
3793
  ================
3742
3794
  File: src/index.ts
3743
3795
  ================
@@ -4030,220 +4082,171 @@ export function safeTerminateWs(
4030
4082
  ): boolean
4031
4083
 
4032
4084
  ================
4033
- File: src/types/response/wallet.ts
4085
+ File: src/types/response/delivery.ts
4034
4086
  ================
4035
- export interface CurrencyChain {
4036
- chain: string;
4037
- name_cn: string;
4038
- name_en: string;
4039
- contract_address: string;
4040
- is_disabled: number;
4041
- is_deposit_disabled: number;
4042
- is_withdraw_disabled: number;
4043
- decimal: string;
4044
- }
4045
- ⋮----
4046
- export interface CreateDepositAddressResp {
4047
- currency: string;
4048
- address: string;
4049
- multichain_addresses: {
4050
- chain: string;
4051
- address: string;
4052
- payment_id: string;
4053
- payment_name: string;
4054
- obtain_failed: number;
4055
- }[];
4056
- }
4057
- ⋮----
4058
- export interface SubAccountTransferRecord {
4059
- currency: string;
4060
- sub_account: string;
4061
- direction: 'to' | 'from';
4062
- amount: string;
4063
- uid: string;
4064
- client_order_id: string;
4065
- timest: string;
4066
- source: string;
4067
- sub_account_type: 'spot' | 'futures' | 'cross_margin' | 'delivery';
4068
- }
4069
- ⋮----
4070
- export interface WithdrawalStatus {
4071
- currency: string;
4072
- name: string;
4073
- name_cn: string;
4074
- deposit: string;
4075
- withdraw_percent: string;
4076
- withdraw_fix: string;
4077
- withdraw_day_limit: string;
4078
- withdraw_amount_mini: string;
4079
- withdraw_day_limit_remain: string;
4080
- withdraw_eachtime_limit: string;
4081
- withdraw_fix_on_chains: { [key: string]: string };
4082
- withdraw_percent_on_chains: { [key: string]: string };
4083
- }
4084
- ⋮----
4085
- export interface SubAccountMarginBalance {
4086
- currency_pair: string;
4087
- locked: boolean;
4088
- risk: string;
4089
- base: {
4090
- currency: string;
4091
- available: string;
4092
- locked: string;
4093
- borrowed: string;
4094
- interest: string;
4095
- };
4096
- quote: {
4097
- currency: string;
4098
- available: string;
4099
- locked: string;
4100
- borrowed: string;
4101
- interest: string;
4102
- };
4103
- }
4087
+ /**==========================================================================================================================
4088
+ * DELIVERY
4089
+ * ==========================================================================================================================
4090
+ */
4104
4091
  ⋮----
4105
- export interface SubAccountFuturesBalancesResp {
4106
- uid: string;
4107
- available: {
4108
- [key: string]: {
4109
- total: string;
4110
- unrealised_pnl: string;
4111
- position_margin: string;
4112
- order_margin: string;
4113
- available: string;
4114
- point: string;
4115
- currency: string;
4116
- in_dual_mode: boolean;
4117
- enable_credit: boolean;
4118
- position_initial_margin: string;
4119
- maintenance_margin: string;
4120
- bonus: string;
4121
- enable_evolved_classic: boolean;
4122
- cross_order_margin: string;
4123
- cross_initial_margin: string;
4124
- cross_maintenance_margin: string;
4125
- cross_unrealised_pnl: string;
4126
- cross_available: string;
4127
- isolated_position_margin: string;
4128
- history: {
4129
- dnw: string;
4130
- pnl: string;
4131
- fee: string;
4132
- refr: string;
4133
- fund: string;
4134
- point_dnw: string;
4135
- point_fee: string;
4136
- point_refr: string;
4137
- bonus_dnw: string;
4138
- bonus_offset: string;
4139
- };
4140
- };
4141
- };
4092
+ export interface DeliveryOrderBook {
4093
+ id?: number;
4094
+ current: number;
4095
+ update: number;
4096
+ asks: { p: string; s: number }[];
4097
+ bids: { p: string; s: number }[];
4142
4098
  }
4143
4099
  ⋮----
4144
- export interface SubAccountCrossMarginBalancesResp {
4145
- uid: string;
4146
- available: {
4147
- user_id: number;
4148
- locked: boolean;
4149
- balances: {
4150
- [key: string]: {
4151
- available: string;
4152
- freeze: string;
4153
- borrowed: string;
4154
- interest: string;
4155
- };
4156
- };
4157
- total: string;
4158
- borrowed: string;
4159
- borrowed_net: string;
4160
- net: string;
4161
- leverage: string;
4162
- interest: string;
4163
- risk: string;
4164
- total_initial_margin: string;
4165
- total_margin_balance: string;
4166
- total_maintenance_margin: string;
4167
- total_initial_margin_rate: string;
4168
- total_maintenance_margin_rate: string;
4169
- total_available_margin: string;
4170
- };
4100
+ export interface DeliveryTrade {
4101
+ id: number;
4102
+ create_time: number;
4103
+ create_time_ms: number;
4104
+ contract: string;
4105
+ size: number;
4106
+ price: string;
4107
+ is_internal?: boolean;
4171
4108
  }
4172
4109
  ⋮----
4173
- export interface SavedAddress {
4174
- currency: string;
4175
- chain: string;
4176
- address: string;
4177
- name: string;
4178
- tag: string;
4179
- verified: string;
4110
+ export interface DeliveryCandle {
4111
+ t: number;
4112
+ v?: number;
4113
+ c: string;
4114
+ h: string;
4115
+ l: string;
4116
+ o: string;
4180
4117
  }
4181
4118
  ⋮----
4182
- export interface TradingFees {
4183
- user_id: number;
4184
- taker_fee: string;
4185
- maker_fee: string;
4186
- gt_discount: boolean;
4187
- gt_taker_fee: string;
4188
- gt_maker_fee: string;
4189
- loan_fee: string;
4190
- point_type: string;
4191
- futures_taker_fee: string;
4192
- futures_maker_fee: string;
4193
- delivery_taker_fee: string;
4194
- delivery_maker_fee: string;
4195
- debit_fee: number;
4119
+ export interface DeliveryTicker {
4120
+ contract: string;
4121
+ last: string;
4122
+ change_percentage: string;
4123
+ total_size: string;
4124
+ low_24h: string;
4125
+ high_24h: string;
4126
+ volume_24h: string;
4127
+ volume_24h_btc?: string;
4128
+ volume_24h_usd?: string;
4129
+ volume_24h_base: string;
4130
+ volume_24h_quote: string;
4131
+ volume_24h_settle: string;
4132
+ mark_price: string;
4133
+ funding_rate: string;
4134
+ funding_rate_indicative: string;
4135
+ index_price: string;
4136
+ quanto_base_rate?: string;
4137
+ basis_rate: string;
4138
+ basis_value: string;
4139
+ lowest_ask: string;
4140
+ highest_bid: string;
4196
4141
  }
4197
4142
  ⋮----
4198
- export interface GetBalancesResp {
4199
- total: {
4200
- amount: string;
4201
- currency: string;
4202
- unrealised_pnl?: string;
4203
- borrowed?: string;
4204
- };
4205
- details: {
4206
- [key: string]: {
4207
- amount: string;
4208
- currency: string;
4209
- unrealised_pnl?: string;
4210
- borrowed?: string;
4211
- };
4143
+ export interface DeliveryAccount {
4144
+ total: string;
4145
+ unrealised_pnl: string;
4146
+ position_margin: string;
4147
+ order_margin: string;
4148
+ available: string;
4149
+ point: string;
4150
+ currency: string;
4151
+ in_dual_mode: boolean;
4152
+ enable_credit: boolean;
4153
+ position_initial_margin: string;
4154
+ maintenance_margin: string;
4155
+ bonus: string;
4156
+ enable_evolved_classic: boolean;
4157
+ cross_order_margin: string;
4158
+ cross_initial_margin: string;
4159
+ cross_maintenance_margin: string;
4160
+ cross_unrealised_pnl: string;
4161
+ cross_available: string;
4162
+ isolated_position_margin: string;
4163
+ history: {
4164
+ dnw: string;
4165
+ pnl: string;
4166
+ fee: string;
4167
+ refr: string;
4168
+ fund: string;
4169
+ point_dnw: string;
4170
+ point_fee: string;
4171
+ point_refr: string;
4172
+ bonus_dnw: string;
4173
+ bonus_offset: string;
4212
4174
  };
4175
+ enable_tiered_mm: boolean;
4213
4176
  }
4214
4177
  ⋮----
4215
- export interface SmallBalanceRecord {
4216
- currency: string;
4217
- available_balance: string;
4218
- estimated_as_btc: string;
4219
- convertible_to_gt: string;
4178
+ export interface DeliveryBook {
4179
+ time: number;
4180
+ change: string;
4181
+ balance: string;
4182
+ type:
4183
+ | 'dnw'
4184
+ | 'pnl'
4185
+ | 'fee'
4186
+ | 'refr'
4187
+ | 'fund'
4188
+ | 'point_dnw'
4189
+ | 'point_fee'
4190
+ | 'point_refr'
4191
+ | 'bonus_offset';
4192
+ text: string;
4193
+ contract?: string;
4194
+ trade_id?: string;
4220
4195
  }
4221
4196
  ⋮----
4222
- export interface SmallBalanceHistoryRecord {
4223
- id: string;
4224
- currency: string;
4225
- amount: string;
4226
- gt_amount: string;
4197
+ export interface DeliveryTradingHistoryRecord {
4198
+ id: number;
4227
4199
  create_time: number;
4200
+ contract: string;
4201
+ order_id: string;
4202
+ size: number;
4203
+ price: string;
4204
+ role: 'taker' | 'maker';
4205
+ text: string;
4206
+ fee: string;
4207
+ point_fee: string;
4228
4208
  }
4229
4209
  ⋮----
4230
- export interface PushOrder {
4231
- id: number;
4232
- push_uid: number;
4233
- receive_uid: number;
4234
- currency: string;
4235
- amount: string;
4236
- create_time: number;
4237
- status:
4238
- | 'CREATING'
4239
- | 'PENDING'
4240
- | 'CANCELLING'
4241
- | 'CANCELLED'
4242
- | 'REFUSING'
4243
- | 'REFUSED'
4244
- | 'RECEIVING'
4245
- | 'RECEIVED';
4246
- message: string;
4210
+ export interface DeliveryClosedPosition {
4211
+ time: number;
4212
+ contract: string;
4213
+ side: 'long' | 'short';
4214
+ pnl: string;
4215
+ pnl_pnl: string;
4216
+ pnl_fund: string;
4217
+ pnl_fee: string;
4218
+ text: string;
4219
+ max_size: string;
4220
+ first_open_time: number;
4221
+ long_price: string;
4222
+ short_price: string;
4223
+ }
4224
+ ⋮----
4225
+ export interface DeliveryLiquidationHistoryRecord {
4226
+ time: number;
4227
+ contract: string;
4228
+ leverage?: string;
4229
+ size: number;
4230
+ margin?: string;
4231
+ entry_price?: string;
4232
+ liq_price?: string;
4233
+ mark_price?: string;
4234
+ order_id?: number;
4235
+ order_price: string;
4236
+ fill_price: string;
4237
+ left: number;
4238
+ }
4239
+ ⋮----
4240
+ export interface DeliverySettlementHistoryRecord {
4241
+ time: number;
4242
+ contract: string;
4243
+ leverage: string;
4244
+ size: number;
4245
+ margin: string;
4246
+ entry_price: string;
4247
+ settle_price: string;
4248
+ profit: string;
4249
+ fee: string;
4247
4250
  }
4248
4251
 
4249
4252
  ================
@@ -4357,6 +4360,11 @@ export interface GetRiskLimitTiersReq {
4357
4360
  offset?: number;
4358
4361
  }
4359
4362
  ⋮----
4363
+ export interface GetRiskLimitTableReq {
4364
+ settle: 'btc' | 'usdt' | 'usd';
4365
+ table_id: string;
4366
+ }
4367
+ ⋮----
4360
4368
  export interface GetFuturesAccountBookReq {
4361
4369
  settle: 'btc' | 'usdt' | 'usd';
4362
4370
  contract?: string;
@@ -4761,6 +4769,7 @@ import {
4761
4769
  serializeParams,
4762
4770
  } from './requestUtils.js';
4763
4771
  import {
4772
+ checkWebCryptoAPISupported,
4764
4773
  hashMessage,
4765
4774
  SignAlgorithm,
4766
4775
  SignEncodeMethod,
@@ -4849,6 +4858,8 @@ constructor(
4849
4858
  // For more advanced configuration, raise an issue on GitHub or use the "networkOptions"
4850
4859
  // parameter to define a custom httpsAgent with the desired properties
4851
4860
  ⋮----
4861
+ // Check Web Crypto API support when credentials are provided and no custom sign function is used
4862
+ ⋮----
4852
4863
  // Throw if one of the 3 values is missing, but at least one of them is set
4853
4864
  ⋮----
4854
4865
  /**
@@ -5885,6 +5896,7 @@ import { WsOperation } from '../types/websockets/requests.js';
5885
5896
  import { WS_LOGGER_CATEGORY } from '../WebsocketClient.js';
5886
5897
  import { DefaultLogger } from './logger.js';
5887
5898
  import { isMessageEvent, MessageEventLike } from './requestUtils.js';
5899
+ import { checkWebCryptoAPISupported } from './webCryptoAPI.js';
5888
5900
  import {
5889
5901
  safeTerminateWs,
5890
5902
  WsTopicRequest,
@@ -6009,6 +6021,8 @@ constructor(
6009
6021
  ⋮----
6010
6022
  // Automatically re-auth WS API, if we were auth'd before and get reconnected
6011
6023
  ⋮----
6024
+ // Check Web Crypto API support when credentials are provided and no custom sign function is used
6025
+ ⋮----
6012
6026
  protected abstract isAuthOnConnectWsKey(wsKey: TWSKey): boolean;
6013
6027
  ⋮----
6014
6028
  protected abstract sendPingEvent(wsKey: TWSKey, ws: WebSocket): void;
@@ -6453,6 +6467,7 @@ export interface FuturesAccount {
6453
6467
  bonus_dnw: string;
6454
6468
  bonus_offset: string;
6455
6469
  };
6470
+ enable_tiered_mm: boolean;
6456
6471
  }
6457
6472
  ⋮----
6458
6473
  export interface FuturesAccountBookRecord {
@@ -6791,6 +6806,15 @@ export interface UpdateFuturesDualModeResp {
6791
6806
  bonus_offset: string;
6792
6807
  };
6793
6808
  }
6809
+ ⋮----
6810
+ export interface RiskLimitTableTier {
6811
+ tier: number;
6812
+ risk_limit: string;
6813
+ initial_rate: string;
6814
+ maintenance_rate: string;
6815
+ leverage_max: string;
6816
+ deduction: string;
6817
+ }
6794
6818
 
6795
6819
  ================
6796
6820
  File: src/WebsocketAPIClient.ts
@@ -7117,6 +7141,7 @@ Updated & performant JavaScript & Node.js SDK for the Gate.com (gate.io) REST AP
7117
7141
  - [REST-like API](#rest-like-api)
7118
7142
  - [Customise Logging](#customise-logging)
7119
7143
  - [LLMs & AI](#use-with-llms--ai)
7144
+ - [Used By](#used-by)
7120
7145
  - [Contributions & Thanks](#contributions--thanks)
7121
7146
 
7122
7147
  ## Installation
@@ -7492,6 +7517,12 @@ This file contains AI optimised structure of all the functions in this package,
7492
7517
 
7493
7518
  ---
7494
7519
 
7520
+ ## Used By
7521
+
7522
+ [![Repository Users Preview Image](https://dependents.info/tiagosiebler/gateio-api/image)](https://github.com/tiagosiebler/gateio-api/network/dependents)
7523
+
7524
+ ---
7525
+
7495
7526
  <!-- template_contributions -->
7496
7527
 
7497
7528
  ### Contributions & Thanks
@@ -7887,6 +7918,7 @@ import {
7887
7918
  GetFuturesTradingHistoryByTimeRangeReq,
7888
7919
  GetFuturesTradingHistoryReq,
7889
7920
  GetLiquidationHistoryReq,
7921
+ GetRiskLimitTableReq,
7890
7922
  GetRiskLimitTiersReq,
7891
7923
  SubmitFuturesOrderReq,
7892
7924
  SubmitFuturesTriggeredOrderReq,
@@ -8042,6 +8074,7 @@ import {
8042
8074
  IndexConstituents,
8043
8075
  LiquidationHistoryRecord,
8044
8076
  PremiumIndexKLine,
8077
+ RiskLimitTableTier,
8045
8078
  RiskLimitTier,
8046
8079
  } from './types/response/futures.js';
8047
8080
  import {
@@ -9196,6 +9229,20 @@ cancelSpotTriggeredOrder(params: {
9196
9229
  order_id: string;
9197
9230
  }): Promise<SpotPriceTriggeredOrder>
9198
9231
  ⋮----
9232
+ /**
9233
+ * Set collateral currency
9234
+ *
9235
+ * @param params Parameters for setting collateral currency
9236
+ * @returns Promise<{
9237
+ * is_success: boolean;
9238
+ * }>
9239
+ */
9240
+ setCollateralCurrency(params: {
9241
+ collateral_type: 0 | 1;
9242
+ enable_list?: string[];
9243
+ disable_list?: string[];
9244
+ }): Promise<
9245
+ ⋮----
9199
9246
  /**==========================================================================================================================
9200
9247
  * MARGIN
9201
9248
  * ==========================================================================================================================
@@ -10164,6 +10211,16 @@ batchUpdateFuturesOrders(params: {
10164
10211
  orders: BatchAmendOrderReq[];
10165
10212
  }): Promise<BatchAmendOrderResp[]>
10166
10213
  ⋮----
10214
+ /**
10215
+ * Query risk limit table by table_id
10216
+ *
10217
+ * @param params Parameters for querying risk limit table
10218
+ * @returns Promise<RiskLimitTableTier[]>
10219
+ */
10220
+ getRiskLimitTable(
10221
+ params: GetRiskLimitTableReq,
10222
+ ): Promise<RiskLimitTableTier[]>
10223
+ ⋮----
10167
10224
  /**
10168
10225
  * Create a price-triggered order
10169
10226
  *
@@ -11474,7 +11531,7 @@ File: package.json
11474
11531
  ================
11475
11532
  {
11476
11533
  "name": "gateio-api",
11477
- "version": "1.2.4",
11534
+ "version": "1.2.7",
11478
11535
  "description": "Complete & Robust Node.js SDK for Gate.com's REST APIs, WebSockets & WebSocket APIs, with TypeScript declarations.",
11479
11536
  "scripts": {
11480
11537
  "clean": "rm -rf dist/*",