@gainsnetwork/sdk 0.2.12-rc4 → 0.2.12-rc5

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.
@@ -132,6 +132,11 @@ const _abi = [
132
132
  name: "WrongOrder",
133
133
  type: "error",
134
134
  },
135
+ {
136
+ inputs: [],
137
+ name: "WrongOrderType",
138
+ type: "error",
139
+ },
135
140
  {
136
141
  inputs: [],
137
142
  name: "WrongParams",
@@ -607,14 +612,14 @@ const _abi = [
607
612
  type: "uint40",
608
613
  },
609
614
  {
610
- internalType: "uint64",
615
+ internalType: "uint40",
611
616
  name: "startLiqThresholdP",
612
- type: "uint64",
617
+ type: "uint40",
613
618
  },
614
619
  {
615
- internalType: "uint64",
620
+ internalType: "uint40",
616
621
  name: "endLiqThresholdP",
617
- type: "uint64",
622
+ type: "uint40",
618
623
  },
619
624
  {
620
625
  internalType: "uint24",
@@ -635,7 +640,7 @@ const _abi = [
635
640
  ],
636
641
  name: "GroupLiquidationParamsUpdated",
637
642
  type: "event",
638
- signature: "0x52bf41e4c95a813ed559a6c8bd01fa75e1ef80e29720fae8a1c1691bce4519aa",
643
+ signature: "0x7e8e79d406657a52635b68c3f3ad15d2526e71077df1b40afad9d323eacbabfc",
639
644
  },
640
645
  {
641
646
  anonymous: false,
@@ -959,14 +964,14 @@ const _abi = [
959
964
  type: "uint40",
960
965
  },
961
966
  {
962
- internalType: "uint64",
967
+ internalType: "uint40",
963
968
  name: "startLiqThresholdP",
964
- type: "uint64",
969
+ type: "uint40",
965
970
  },
966
971
  {
967
- internalType: "uint64",
972
+ internalType: "uint40",
968
973
  name: "endLiqThresholdP",
969
- type: "uint64",
974
+ type: "uint40",
970
975
  },
971
976
  {
972
977
  internalType: "uint24",
@@ -1006,14 +1011,14 @@ const _abi = [
1006
1011
  type: "uint40",
1007
1012
  },
1008
1013
  {
1009
- internalType: "uint64",
1014
+ internalType: "uint40",
1010
1015
  name: "startLiqThresholdP",
1011
- type: "uint64",
1016
+ type: "uint40",
1012
1017
  },
1013
1018
  {
1014
- internalType: "uint64",
1019
+ internalType: "uint40",
1015
1020
  name: "endLiqThresholdP",
1016
- type: "uint64",
1021
+ type: "uint40",
1017
1022
  },
1018
1023
  {
1019
1024
  internalType: "uint24",
@@ -1101,14 +1106,14 @@ const _abi = [
1101
1106
  type: "uint40",
1102
1107
  },
1103
1108
  {
1104
- internalType: "uint64",
1109
+ internalType: "uint40",
1105
1110
  name: "startLiqThresholdP",
1106
- type: "uint64",
1111
+ type: "uint40",
1107
1112
  },
1108
1113
  {
1109
- internalType: "uint64",
1114
+ internalType: "uint40",
1110
1115
  name: "endLiqThresholdP",
1111
- type: "uint64",
1116
+ type: "uint40",
1112
1117
  },
1113
1118
  {
1114
1119
  internalType: "uint24",
@@ -1130,7 +1135,7 @@ const _abi = [
1130
1135
  outputs: [],
1131
1136
  stateMutability: "nonpayable",
1132
1137
  type: "function",
1133
- signature: "0xda13028a",
1138
+ signature: "0x85d4390e",
1134
1139
  },
1135
1140
  {
1136
1141
  inputs: [
@@ -1643,14 +1648,14 @@ const _abi = [
1643
1648
  type: "uint40",
1644
1649
  },
1645
1650
  {
1646
- internalType: "uint64",
1651
+ internalType: "uint40",
1647
1652
  name: "startLiqThresholdP",
1648
- type: "uint64",
1653
+ type: "uint40",
1649
1654
  },
1650
1655
  {
1651
- internalType: "uint64",
1656
+ internalType: "uint40",
1652
1657
  name: "endLiqThresholdP",
1653
- type: "uint64",
1658
+ type: "uint40",
1654
1659
  },
1655
1660
  {
1656
1661
  internalType: "uint24",
@@ -1672,7 +1677,7 @@ const _abi = [
1672
1677
  outputs: [],
1673
1678
  stateMutability: "nonpayable",
1674
1679
  type: "function",
1675
- signature: "0x8eb657f6",
1680
+ signature: "0xd0cb753e",
1676
1681
  },
1677
1682
  {
1678
1683
  inputs: [
@@ -3096,6 +3101,26 @@ const _abi = [
3096
3101
  name: "WrongWindowsDuration",
3097
3102
  type: "error",
3098
3103
  },
3104
+ {
3105
+ anonymous: false,
3106
+ inputs: [
3107
+ {
3108
+ indexed: true,
3109
+ internalType: "uint256",
3110
+ name: "pairIndex",
3111
+ type: "uint256",
3112
+ },
3113
+ {
3114
+ indexed: false,
3115
+ internalType: "uint40",
3116
+ name: "cumulativeFactor",
3117
+ type: "uint40",
3118
+ },
3119
+ ],
3120
+ name: "CumulativeFactorUpdated",
3121
+ type: "event",
3122
+ signature: "0x2742ec28d0252b4477106a77a10b04e1c1ecd2b568c7168d56c3a3154d3a3122",
3123
+ },
3099
3124
  {
3100
3125
  anonymous: false,
3101
3126
  inputs: [
@@ -3241,61 +3266,9 @@ const _abi = [
3241
3266
  name: "long",
3242
3267
  type: "bool",
3243
3268
  },
3244
- {
3245
- internalType: "uint128",
3246
- name: "openInterestUsd",
3247
- type: "uint128",
3248
- },
3249
- ],
3250
- indexed: false,
3251
- internalType: "struct IPriceImpact.OiWindowUpdate",
3252
- name: "oiWindowUpdate",
3253
- type: "tuple",
3254
- },
3255
- {
3256
- indexed: false,
3257
- internalType: "bool",
3258
- name: "isPartial",
3259
- type: "bool",
3260
- },
3261
- ],
3262
- name: "PriceImpactOpenInterestAdded",
3263
- type: "event",
3264
- signature: "0x4ad96f03f62012d64f1a3676413b5a73b13a99eebe005158b124403e3c3ab70d",
3265
- },
3266
- {
3267
- anonymous: false,
3268
- inputs: [
3269
- {
3270
- components: [
3271
- {
3272
- internalType: "address",
3273
- name: "trader",
3274
- type: "address",
3275
- },
3276
- {
3277
- internalType: "uint32",
3278
- name: "index",
3279
- type: "uint32",
3280
- },
3281
- {
3282
- internalType: "uint48",
3283
- name: "windowsDuration",
3284
- type: "uint48",
3285
- },
3286
- {
3287
- internalType: "uint256",
3288
- name: "pairIndex",
3289
- type: "uint256",
3290
- },
3291
- {
3292
- internalType: "uint256",
3293
- name: "windowId",
3294
- type: "uint256",
3295
- },
3296
3269
  {
3297
3270
  internalType: "bool",
3298
- name: "long",
3271
+ name: "open",
3299
3272
  type: "bool",
3300
3273
  },
3301
3274
  {
@@ -3309,16 +3282,10 @@ const _abi = [
3309
3282
  name: "oiWindowUpdate",
3310
3283
  type: "tuple",
3311
3284
  },
3312
- {
3313
- indexed: false,
3314
- internalType: "bool",
3315
- name: "notOutdated",
3316
- type: "bool",
3317
- },
3318
3285
  ],
3319
- name: "PriceImpactOpenInterestRemoved",
3286
+ name: "PriceImpactOpenInterestAdded",
3320
3287
  type: "event",
3321
- signature: "0x02c87303d6313dfe4cd344c2850cf9b343c7b2baa78546cec5892065611b0181",
3288
+ signature: "0xcca5358ade10271036cf22898f07ad681f9dd7fc3e861da5fc31319c4b890ad4",
3322
3289
  },
3323
3290
  {
3324
3291
  anonymous: false,
@@ -3351,16 +3318,22 @@ const _abi = [
3351
3318
  {
3352
3319
  anonymous: false,
3353
3320
  inputs: [
3321
+ {
3322
+ indexed: true,
3323
+ internalType: "uint256",
3324
+ name: "pairIndex",
3325
+ type: "uint256",
3326
+ },
3354
3327
  {
3355
3328
  indexed: false,
3356
- internalType: "uint24",
3329
+ internalType: "uint32",
3357
3330
  name: "protectionCloseFactorBlocks",
3358
- type: "uint24",
3331
+ type: "uint32",
3359
3332
  },
3360
3333
  ],
3361
3334
  name: "ProtectionCloseFactorBlocksUpdated",
3362
3335
  type: "event",
3363
- signature: "0xbb1ab3cb7b05f44cea93ff3a0ea17c517fa0a0c1a6aab8d78b996128d2b0199f",
3336
+ signature: "0xd537ef0f85bea3a23f6af53d4c1b29fdc74cdbd3a07a37bfdb76f5368aebd660",
3364
3337
  },
3365
3338
  {
3366
3339
  anonymous: false,
@@ -3373,14 +3346,14 @@ const _abi = [
3373
3346
  },
3374
3347
  {
3375
3348
  indexed: false,
3376
- internalType: "uint256",
3349
+ internalType: "uint40",
3377
3350
  name: "protectionCloseFactor",
3378
- type: "uint256",
3351
+ type: "uint40",
3379
3352
  },
3380
3353
  ],
3381
3354
  name: "ProtectionCloseFactorUpdated",
3382
3355
  type: "event",
3383
- signature: "0x91702eff4d91af5aaa0a65e6c7cd5893e9e354b77f408789116e6f18054bb611",
3356
+ signature: "0x471eb2788149a10519cea684f0149db7c6af0e5fa1182f06b50c5420fe95d12a",
3384
3357
  },
3385
3358
  {
3386
3359
  inputs: [
@@ -3399,12 +3372,17 @@ const _abi = [
3399
3372
  name: "_oiDeltaCollateral",
3400
3373
  type: "uint256",
3401
3374
  },
3375
+ {
3376
+ internalType: "bool",
3377
+ name: "_open",
3378
+ type: "bool",
3379
+ },
3402
3380
  ],
3403
3381
  name: "addPriceImpactOpenInterest",
3404
3382
  outputs: [],
3405
3383
  stateMutability: "nonpayable",
3406
3384
  type: "function",
3407
- signature: "0x4c8a7602",
3385
+ signature: "0x23ce624b",
3408
3386
  },
3409
3387
  {
3410
3388
  inputs: [
@@ -3585,45 +3563,6 @@ const _abi = [
3585
3563
  type: "function",
3586
3564
  signature: "0x0d569f27",
3587
3565
  },
3588
- {
3589
- inputs: [
3590
- {
3591
- internalType: "uint256",
3592
- name: "_pairIndex",
3593
- type: "uint256",
3594
- },
3595
- {
3596
- internalType: "bool",
3597
- name: "_long",
3598
- type: "bool",
3599
- },
3600
- ],
3601
- name: "getPriceImpactOi",
3602
- outputs: [
3603
- {
3604
- internalType: "uint256",
3605
- name: "activeOi",
3606
- type: "uint256",
3607
- },
3608
- ],
3609
- stateMutability: "view",
3610
- type: "function",
3611
- signature: "0xb6d92b02",
3612
- },
3613
- {
3614
- inputs: [],
3615
- name: "getProtectionCloseFactorBlocks",
3616
- outputs: [
3617
- {
3618
- internalType: "uint24",
3619
- name: "",
3620
- type: "uint24",
3621
- },
3622
- ],
3623
- stateMutability: "view",
3624
- type: "function",
3625
- signature: "0xa7059886",
3626
- },
3627
3566
  {
3628
3567
  inputs: [
3629
3568
  {
@@ -3632,42 +3571,64 @@ const _abi = [
3632
3571
  type: "uint256[]",
3633
3572
  },
3634
3573
  ],
3635
- name: "getProtectionCloseFactors",
3574
+ name: "getPairFactors",
3636
3575
  outputs: [
3637
3576
  {
3638
- internalType: "uint256[]",
3577
+ components: [
3578
+ {
3579
+ internalType: "uint40",
3580
+ name: "protectionCloseFactor",
3581
+ type: "uint40",
3582
+ },
3583
+ {
3584
+ internalType: "uint32",
3585
+ name: "protectionCloseFactorBlocks",
3586
+ type: "uint32",
3587
+ },
3588
+ {
3589
+ internalType: "uint40",
3590
+ name: "cumulativeFactor",
3591
+ type: "uint40",
3592
+ },
3593
+ {
3594
+ internalType: "uint144",
3595
+ name: "__placeholder",
3596
+ type: "uint144",
3597
+ },
3598
+ ],
3599
+ internalType: "struct IPriceImpact.PairFactors[]",
3639
3600
  name: "",
3640
- type: "uint256[]",
3601
+ type: "tuple[]",
3641
3602
  },
3642
3603
  ],
3643
3604
  stateMutability: "view",
3644
3605
  type: "function",
3645
- signature: "0xf33fc605",
3606
+ signature: "0x8db9e2da",
3646
3607
  },
3647
3608
  {
3648
3609
  inputs: [
3649
3610
  {
3650
- internalType: "address",
3651
- name: "_trader",
3652
- type: "address",
3611
+ internalType: "uint256",
3612
+ name: "_pairIndex",
3613
+ type: "uint256",
3653
3614
  },
3654
3615
  {
3655
- internalType: "uint32",
3656
- name: "_index",
3657
- type: "uint32",
3616
+ internalType: "bool",
3617
+ name: "_long",
3618
+ type: "bool",
3658
3619
  },
3659
3620
  ],
3660
- name: "getTradeLastWindowOiUsd",
3621
+ name: "getPriceImpactOi",
3661
3622
  outputs: [
3662
3623
  {
3663
- internalType: "uint128",
3664
- name: "",
3665
- type: "uint128",
3624
+ internalType: "uint256",
3625
+ name: "activeOi",
3626
+ type: "uint256",
3666
3627
  },
3667
3628
  ],
3668
3629
  stateMutability: "view",
3669
3630
  type: "function",
3670
- signature: "0x273064f2",
3631
+ signature: "0xb6d92b02",
3671
3632
  },
3672
3633
  {
3673
3634
  inputs: [
@@ -3706,6 +3667,11 @@ const _abi = [
3706
3667
  name: "_createdBlock",
3707
3668
  type: "uint256",
3708
3669
  },
3670
+ {
3671
+ internalType: "enum ITradingStorage.ContractsVersion",
3672
+ name: "_contractsVersion",
3673
+ type: "uint8",
3674
+ },
3709
3675
  ],
3710
3676
  name: "getTradePriceImpact",
3711
3677
  outputs: [
@@ -3722,44 +3688,36 @@ const _abi = [
3722
3688
  ],
3723
3689
  stateMutability: "view",
3724
3690
  type: "function",
3725
- signature: "0x31d20230",
3691
+ signature: "0xdd5ef6f1",
3726
3692
  },
3727
3693
  {
3728
3694
  inputs: [
3729
3695
  {
3730
- internalType: "address",
3731
- name: "_trader",
3732
- type: "address",
3696
+ internalType: "uint16[]",
3697
+ name: "_pairIndices",
3698
+ type: "uint16[]",
3733
3699
  },
3734
3700
  {
3735
- internalType: "uint32",
3736
- name: "_index",
3737
- type: "uint32",
3701
+ internalType: "uint40[]",
3702
+ name: "_protectionCloseFactors",
3703
+ type: "uint40[]",
3738
3704
  },
3739
- ],
3740
- name: "getTradePriceImpactInfo",
3741
- outputs: [
3742
3705
  {
3743
- components: [
3744
- {
3745
- internalType: "uint128",
3746
- name: "lastWindowOiUsd",
3747
- type: "uint128",
3748
- },
3749
- {
3750
- internalType: "uint128",
3751
- name: "__placeholder",
3752
- type: "uint128",
3753
- },
3754
- ],
3755
- internalType: "struct IPriceImpact.TradePriceImpactInfo",
3756
- name: "",
3757
- type: "tuple",
3706
+ internalType: "uint32[]",
3707
+ name: "_protectionCloseFactorBlocks",
3708
+ type: "uint32[]",
3709
+ },
3710
+ {
3711
+ internalType: "uint40[]",
3712
+ name: "_cumulativeFactors",
3713
+ type: "uint40[]",
3758
3714
  },
3759
3715
  ],
3760
- stateMutability: "view",
3716
+ name: "initializePairFactors",
3717
+ outputs: [],
3718
+ stateMutability: "nonpayable",
3761
3719
  type: "function",
3762
- signature: "0xc3248367",
3720
+ signature: "0x3d7e587a",
3763
3721
  },
3764
3722
  {
3765
3723
  inputs: [
@@ -3783,40 +3741,21 @@ const _abi = [
3783
3741
  {
3784
3742
  inputs: [
3785
3743
  {
3786
- internalType: "uint24",
3787
- name: "_protectionCloseFactorBlocks",
3788
- type: "uint24",
3744
+ internalType: "uint16[]",
3745
+ name: "_pairIndices",
3746
+ type: "uint16[]",
3747
+ },
3748
+ {
3749
+ internalType: "uint40[]",
3750
+ name: "_cumulativeFactors",
3751
+ type: "uint40[]",
3789
3752
  },
3790
3753
  ],
3791
- name: "initializeProtectionCloseFactorBlocks",
3754
+ name: "setCumulativeFactors",
3792
3755
  outputs: [],
3793
3756
  stateMutability: "nonpayable",
3794
3757
  type: "function",
3795
- signature: "0x0420f323",
3796
- },
3797
- {
3798
- inputs: [
3799
- {
3800
- internalType: "address",
3801
- name: "_trader",
3802
- type: "address",
3803
- },
3804
- {
3805
- internalType: "uint32",
3806
- name: "_index",
3807
- type: "uint32",
3808
- },
3809
- {
3810
- internalType: "uint256",
3811
- name: "_oiDeltaCollateral",
3812
- type: "uint256",
3813
- },
3814
- ],
3815
- name: "removePriceImpactOpenInterest",
3816
- outputs: [],
3817
- stateMutability: "nonpayable",
3818
- type: "function",
3819
- signature: "0x2f29a9e8",
3758
+ signature: "0xa7d518fc",
3820
3759
  },
3821
3760
  {
3822
3761
  inputs: [
@@ -3873,16 +3812,21 @@ const _abi = [
3873
3812
  {
3874
3813
  inputs: [
3875
3814
  {
3876
- internalType: "uint24",
3815
+ internalType: "uint16[]",
3816
+ name: "_pairIndices",
3817
+ type: "uint16[]",
3818
+ },
3819
+ {
3820
+ internalType: "uint32[]",
3877
3821
  name: "_protectionCloseFactorBlocks",
3878
- type: "uint24",
3822
+ type: "uint32[]",
3879
3823
  },
3880
3824
  ],
3881
3825
  name: "setProtectionCloseFactorBlocks",
3882
3826
  outputs: [],
3883
3827
  stateMutability: "nonpayable",
3884
3828
  type: "function",
3885
- signature: "0xb63280b2",
3829
+ signature: "0x2a4cde4a",
3886
3830
  },
3887
3831
  {
3888
3832
  inputs: [
@@ -3892,16 +3836,16 @@ const _abi = [
3892
3836
  type: "uint16[]",
3893
3837
  },
3894
3838
  {
3895
- internalType: "uint256[]",
3839
+ internalType: "uint40[]",
3896
3840
  name: "_protectionCloseFactors",
3897
- type: "uint256[]",
3841
+ type: "uint40[]",
3898
3842
  },
3899
3843
  ],
3900
3844
  name: "setProtectionCloseFactors",
3901
3845
  outputs: [],
3902
3846
  stateMutability: "nonpayable",
3903
3847
  type: "function",
3904
- signature: "0x928ca2f0",
3848
+ signature: "0xef0243dc",
3905
3849
  },
3906
3850
  {
3907
3851
  inputs: [],
@@ -4291,6 +4235,38 @@ const _abi = [
4291
4235
  type: "event",
4292
4236
  signature: "0xce228a7b1b8e239798e94cb2ba581d57501692fc1d29719a891125f1f393826d",
4293
4237
  },
4238
+ {
4239
+ anonymous: false,
4240
+ inputs: [
4241
+ {
4242
+ components: [
4243
+ {
4244
+ internalType: "address",
4245
+ name: "user",
4246
+ type: "address",
4247
+ },
4248
+ {
4249
+ internalType: "uint32",
4250
+ name: "index",
4251
+ type: "uint32",
4252
+ },
4253
+ ],
4254
+ indexed: false,
4255
+ internalType: "struct ITradingStorage.Id",
4256
+ name: "tradeId",
4257
+ type: "tuple",
4258
+ },
4259
+ {
4260
+ indexed: false,
4261
+ internalType: "uint16",
4262
+ name: "maxClosingSlippageP",
4263
+ type: "uint16",
4264
+ },
4265
+ ],
4266
+ name: "TradeMaxClosingSlippagePUpdated",
4267
+ type: "event",
4268
+ signature: "0xb34e0065c48018b4a48b78c4729fd9ffd1968c59d6532e600c4afb42ce093da1",
4269
+ },
4294
4270
  {
4295
4271
  anonymous: false,
4296
4272
  inputs: [
@@ -4342,10 +4318,16 @@ const _abi = [
4342
4318
  name: "newSl",
4343
4319
  type: "uint64",
4344
4320
  },
4321
+ {
4322
+ indexed: false,
4323
+ internalType: "bool",
4324
+ name: "refreshLiquidationParams",
4325
+ type: "bool",
4326
+ },
4345
4327
  ],
4346
4328
  name: "TradePositionUpdated",
4347
4329
  type: "event",
4348
- signature: "0x39ede689b34cc36c8cf85698a4e83530eb6a29a07a57f0bfc3d02bfaca44edb5",
4330
+ signature: "0x3890801c6f1ea37e9eb6aaae6cb1e57eeb8fe67e3af47b2533ff1fc4d1031ede",
4349
4331
  },
4350
4332
  {
4351
4333
  anonymous: false,
@@ -4488,9 +4470,14 @@ const _abi = [
4488
4470
  type: "uint48",
4489
4471
  },
4490
4472
  {
4491
- internalType: "uint48",
4473
+ internalType: "enum ITradingStorage.ContractsVersion",
4474
+ name: "contractsVersion",
4475
+ type: "uint8",
4476
+ },
4477
+ {
4478
+ internalType: "uint40",
4492
4479
  name: "__placeholder",
4493
- type: "uint48",
4480
+ type: "uint40",
4494
4481
  },
4495
4482
  ],
4496
4483
  indexed: false,
@@ -4506,14 +4493,14 @@ const _abi = [
4506
4493
  type: "uint40",
4507
4494
  },
4508
4495
  {
4509
- internalType: "uint64",
4496
+ internalType: "uint40",
4510
4497
  name: "startLiqThresholdP",
4511
- type: "uint64",
4498
+ type: "uint40",
4512
4499
  },
4513
4500
  {
4514
- internalType: "uint64",
4501
+ internalType: "uint40",
4515
4502
  name: "endLiqThresholdP",
4516
- type: "uint64",
4503
+ type: "uint40",
4517
4504
  },
4518
4505
  {
4519
4506
  internalType: "uint24",
@@ -4534,7 +4521,7 @@ const _abi = [
4534
4521
  ],
4535
4522
  name: "TradeStored",
4536
4523
  type: "event",
4537
- signature: "0x68a5f29b49e875ed9fb6226960bdeb3ba45320ae3d7521d3689d6f97638fbe0c",
4524
+ signature: "0xb40b87d57025355f7877bcb0b13819afb13b4ce2a1bf3a1795af7109d99ab3a9",
4538
4525
  },
4539
4526
  {
4540
4527
  anonymous: false,
@@ -4830,9 +4817,14 @@ const _abi = [
4830
4817
  type: "uint48",
4831
4818
  },
4832
4819
  {
4833
- internalType: "uint48",
4820
+ internalType: "enum ITradingStorage.ContractsVersion",
4821
+ name: "contractsVersion",
4822
+ type: "uint8",
4823
+ },
4824
+ {
4825
+ internalType: "uint40",
4834
4826
  name: "__placeholder",
4835
- type: "uint48",
4827
+ type: "uint40",
4836
4828
  },
4837
4829
  ],
4838
4830
  internalType: "struct ITradingStorage.TradeInfo[]",
@@ -4959,14 +4951,14 @@ const _abi = [
4959
4951
  type: "uint40",
4960
4952
  },
4961
4953
  {
4962
- internalType: "uint64",
4954
+ internalType: "uint40",
4963
4955
  name: "startLiqThresholdP",
4964
- type: "uint64",
4956
+ type: "uint40",
4965
4957
  },
4966
4958
  {
4967
- internalType: "uint64",
4959
+ internalType: "uint40",
4968
4960
  name: "endLiqThresholdP",
4969
- type: "uint64",
4961
+ type: "uint40",
4970
4962
  },
4971
4963
  {
4972
4964
  internalType: "uint24",
@@ -5152,6 +5144,20 @@ const _abi = [
5152
5144
  type: "function",
5153
5145
  signature: "0x0212f0d6",
5154
5146
  },
5147
+ {
5148
+ inputs: [],
5149
+ name: "getCurrentContractsVersion",
5150
+ outputs: [
5151
+ {
5152
+ internalType: "enum ITradingStorage.ContractsVersion",
5153
+ name: "",
5154
+ type: "uint8",
5155
+ },
5156
+ ],
5157
+ stateMutability: "pure",
5158
+ type: "function",
5159
+ signature: "0x9095b119",
5160
+ },
5155
5161
  {
5156
5162
  inputs: [
5157
5163
  {
@@ -5572,9 +5578,14 @@ const _abi = [
5572
5578
  type: "uint48",
5573
5579
  },
5574
5580
  {
5575
- internalType: "uint48",
5581
+ internalType: "enum ITradingStorage.ContractsVersion",
5582
+ name: "contractsVersion",
5583
+ type: "uint8",
5584
+ },
5585
+ {
5586
+ internalType: "uint40",
5576
5587
  name: "__placeholder",
5577
- type: "uint48",
5588
+ type: "uint40",
5578
5589
  },
5579
5590
  ],
5580
5591
  internalType: "struct ITradingStorage.TradeInfo",
@@ -5629,9 +5640,14 @@ const _abi = [
5629
5640
  type: "uint48",
5630
5641
  },
5631
5642
  {
5632
- internalType: "uint48",
5643
+ internalType: "enum ITradingStorage.ContractsVersion",
5644
+ name: "contractsVersion",
5645
+ type: "uint8",
5646
+ },
5647
+ {
5648
+ internalType: "uint40",
5633
5649
  name: "__placeholder",
5634
- type: "uint48",
5650
+ type: "uint40",
5635
5651
  },
5636
5652
  ],
5637
5653
  internalType: "struct ITradingStorage.TradeInfo[]",
@@ -5666,14 +5682,14 @@ const _abi = [
5666
5682
  type: "uint40",
5667
5683
  },
5668
5684
  {
5669
- internalType: "uint64",
5685
+ internalType: "uint40",
5670
5686
  name: "startLiqThresholdP",
5671
- type: "uint64",
5687
+ type: "uint40",
5672
5688
  },
5673
5689
  {
5674
- internalType: "uint64",
5690
+ internalType: "uint40",
5675
5691
  name: "endLiqThresholdP",
5676
- type: "uint64",
5692
+ type: "uint40",
5677
5693
  },
5678
5694
  {
5679
5695
  internalType: "uint24",
@@ -5882,14 +5898,14 @@ const _abi = [
5882
5898
  type: "uint40",
5883
5899
  },
5884
5900
  {
5885
- internalType: "uint64",
5901
+ internalType: "uint40",
5886
5902
  name: "startLiqThresholdP",
5887
- type: "uint64",
5903
+ type: "uint40",
5888
5904
  },
5889
5905
  {
5890
- internalType: "uint64",
5906
+ internalType: "uint40",
5891
5907
  name: "endLiqThresholdP",
5892
- type: "uint64",
5908
+ type: "uint40",
5893
5909
  },
5894
5910
  {
5895
5911
  internalType: "uint24",
@@ -6329,9 +6345,14 @@ const _abi = [
6329
6345
  type: "uint48",
6330
6346
  },
6331
6347
  {
6332
- internalType: "uint48",
6348
+ internalType: "enum ITradingStorage.ContractsVersion",
6349
+ name: "contractsVersion",
6350
+ type: "uint8",
6351
+ },
6352
+ {
6353
+ internalType: "uint40",
6333
6354
  name: "__placeholder",
6334
- type: "uint48",
6355
+ type: "uint40",
6335
6356
  },
6336
6357
  ],
6337
6358
  internalType: "struct ITradingStorage.TradeInfo",
@@ -6416,7 +6437,7 @@ const _abi = [
6416
6437
  ],
6417
6438
  stateMutability: "nonpayable",
6418
6439
  type: "function",
6419
- signature: "0x9f30b640",
6440
+ signature: "0xb857d386",
6420
6441
  },
6421
6442
  {
6422
6443
  inputs: [
@@ -6528,6 +6549,37 @@ const _abi = [
6528
6549
  type: "function",
6529
6550
  signature: "0x5a68200d",
6530
6551
  },
6552
+ {
6553
+ inputs: [
6554
+ {
6555
+ components: [
6556
+ {
6557
+ internalType: "address",
6558
+ name: "user",
6559
+ type: "address",
6560
+ },
6561
+ {
6562
+ internalType: "uint32",
6563
+ name: "index",
6564
+ type: "uint32",
6565
+ },
6566
+ ],
6567
+ internalType: "struct ITradingStorage.Id",
6568
+ name: "_tradeId",
6569
+ type: "tuple",
6570
+ },
6571
+ {
6572
+ internalType: "uint16",
6573
+ name: "_maxSlippageP",
6574
+ type: "uint16",
6575
+ },
6576
+ ],
6577
+ name: "updateTradeMaxClosingSlippageP",
6578
+ outputs: [],
6579
+ stateMutability: "nonpayable",
6580
+ type: "function",
6581
+ signature: "0x07d426fd",
6582
+ },
6531
6583
  {
6532
6584
  inputs: [
6533
6585
  {
@@ -6562,12 +6614,17 @@ const _abi = [
6562
6614
  name: "_openPrice",
6563
6615
  type: "uint64",
6564
6616
  },
6617
+ {
6618
+ internalType: "bool",
6619
+ name: "_refreshLiquidationParams",
6620
+ type: "bool",
6621
+ },
6565
6622
  ],
6566
6623
  name: "updateTradePosition",
6567
6624
  outputs: [],
6568
6625
  stateMutability: "nonpayable",
6569
6626
  type: "function",
6570
- signature: "0x7281d8f8",
6627
+ signature: "0x72570e24",
6571
6628
  },
6572
6629
  {
6573
6630
  inputs: [
@@ -6930,11 +6987,6 @@ const _abi = [
6930
6987
  name: "WrongLeverage",
6931
6988
  type: "error",
6932
6989
  },
6933
- {
6934
- inputs: [],
6935
- name: "WrongOrderType",
6936
- type: "error",
6937
- },
6938
6990
  {
6939
6991
  inputs: [],
6940
6992
  name: "WrongSl",
@@ -7810,12 +7862,17 @@ const _abi = [
7810
7862
  name: "_index",
7811
7863
  type: "uint32",
7812
7864
  },
7865
+ {
7866
+ internalType: "uint64",
7867
+ name: "_expectedPrice",
7868
+ type: "uint64",
7869
+ },
7813
7870
  ],
7814
7871
  name: "closeTradeMarket",
7815
7872
  outputs: [],
7816
7873
  stateMutability: "nonpayable",
7817
7874
  type: "function",
7818
- signature: "0xbdb340cd",
7875
+ signature: "0x36ce736b",
7819
7876
  },
7820
7877
  {
7821
7878
  inputs: [
@@ -7834,12 +7891,17 @@ const _abi = [
7834
7891
  name: "_leverageDelta",
7835
7892
  type: "uint24",
7836
7893
  },
7894
+ {
7895
+ internalType: "uint64",
7896
+ name: "_expectedPrice",
7897
+ type: "uint64",
7898
+ },
7837
7899
  ],
7838
7900
  name: "decreasePositionSize",
7839
7901
  outputs: [],
7840
7902
  stateMutability: "nonpayable",
7841
7903
  type: "function",
7842
- signature: "0x69f6bde1",
7904
+ signature: "0xa7cac572",
7843
7905
  },
7844
7906
  {
7845
7907
  inputs: [
@@ -8277,6 +8339,25 @@ const _abi = [
8277
8339
  type: "function",
8278
8340
  signature: "0x52d029d2",
8279
8341
  },
8342
+ {
8343
+ inputs: [
8344
+ {
8345
+ internalType: "uint32",
8346
+ name: "_index",
8347
+ type: "uint32",
8348
+ },
8349
+ {
8350
+ internalType: "uint16",
8351
+ name: "_maxSlippageP",
8352
+ type: "uint16",
8353
+ },
8354
+ ],
8355
+ name: "updateMaxClosingSlippageP",
8356
+ outputs: [],
8357
+ stateMutability: "nonpayable",
8358
+ type: "function",
8359
+ signature: "0x9e8433d0",
8360
+ },
8280
8361
  {
8281
8362
  inputs: [
8282
8363
  {
@@ -9436,52 +9517,402 @@ const _abi = [
9436
9517
  signature: "0xcbc8e6f2",
9437
9518
  },
9438
9519
  {
9439
- inputs: [],
9440
- name: "BorrowingWrongExponent",
9441
- type: "error",
9442
- },
9443
- {
9444
- inputs: [],
9445
- name: "BorrowingZeroGroup",
9446
- type: "error",
9447
- },
9448
- {
9449
- anonymous: false,
9450
9520
  inputs: [
9451
9521
  {
9452
- indexed: true,
9453
- internalType: "uint8",
9454
- name: "collateralIndex",
9455
- type: "uint8",
9522
+ components: [
9523
+ {
9524
+ internalType: "address",
9525
+ name: "user",
9526
+ type: "address",
9527
+ },
9528
+ {
9529
+ internalType: "uint32",
9530
+ name: "index",
9531
+ type: "uint32",
9532
+ },
9533
+ ],
9534
+ internalType: "struct ITradingStorage.Id",
9535
+ name: "_tradeId",
9536
+ type: "tuple",
9456
9537
  },
9457
9538
  {
9458
- indexed: true,
9459
- internalType: "uint16",
9460
- name: "groupIndex",
9461
- type: "uint16",
9539
+ internalType: "enum ITradingStorage.PendingOrderType",
9540
+ name: "_orderType",
9541
+ type: "uint8",
9462
9542
  },
9463
9543
  {
9464
- indexed: false,
9465
- internalType: "uint256",
9466
- name: "currentBlock",
9467
- type: "uint256",
9544
+ internalType: "uint64",
9545
+ name: "_open",
9546
+ type: "uint64",
9468
9547
  },
9469
9548
  {
9470
- indexed: false,
9471
9549
  internalType: "uint64",
9472
- name: "accFeeLong",
9550
+ name: "_high",
9473
9551
  type: "uint64",
9474
9552
  },
9475
9553
  {
9476
- indexed: false,
9477
9554
  internalType: "uint64",
9478
- name: "accFeeShort",
9555
+ name: "_low",
9479
9556
  type: "uint64",
9480
9557
  },
9481
9558
  ],
9482
- name: "BorrowingGroupAccFeesUpdated",
9483
- type: "event",
9484
- signature: "0xb4297e7afacc3feba1f03e1a444e70031a62f3ae4d6372c2b0cb3e0e62e8568e",
9559
+ name: "validateTriggerCloseOrderCallback",
9560
+ outputs: [
9561
+ {
9562
+ components: [
9563
+ {
9564
+ internalType: "address",
9565
+ name: "user",
9566
+ type: "address",
9567
+ },
9568
+ {
9569
+ internalType: "uint32",
9570
+ name: "index",
9571
+ type: "uint32",
9572
+ },
9573
+ {
9574
+ internalType: "uint16",
9575
+ name: "pairIndex",
9576
+ type: "uint16",
9577
+ },
9578
+ {
9579
+ internalType: "uint24",
9580
+ name: "leverage",
9581
+ type: "uint24",
9582
+ },
9583
+ {
9584
+ internalType: "bool",
9585
+ name: "long",
9586
+ type: "bool",
9587
+ },
9588
+ {
9589
+ internalType: "bool",
9590
+ name: "isOpen",
9591
+ type: "bool",
9592
+ },
9593
+ {
9594
+ internalType: "uint8",
9595
+ name: "collateralIndex",
9596
+ type: "uint8",
9597
+ },
9598
+ {
9599
+ internalType: "enum ITradingStorage.TradeType",
9600
+ name: "tradeType",
9601
+ type: "uint8",
9602
+ },
9603
+ {
9604
+ internalType: "uint120",
9605
+ name: "collateralAmount",
9606
+ type: "uint120",
9607
+ },
9608
+ {
9609
+ internalType: "uint64",
9610
+ name: "openPrice",
9611
+ type: "uint64",
9612
+ },
9613
+ {
9614
+ internalType: "uint64",
9615
+ name: "tp",
9616
+ type: "uint64",
9617
+ },
9618
+ {
9619
+ internalType: "uint64",
9620
+ name: "sl",
9621
+ type: "uint64",
9622
+ },
9623
+ {
9624
+ internalType: "uint192",
9625
+ name: "__placeholder",
9626
+ type: "uint192",
9627
+ },
9628
+ ],
9629
+ internalType: "struct ITradingStorage.Trade",
9630
+ name: "t",
9631
+ type: "tuple",
9632
+ },
9633
+ {
9634
+ internalType: "enum ITradingCallbacks.CancelReason",
9635
+ name: "cancelReason",
9636
+ type: "uint8",
9637
+ },
9638
+ {
9639
+ components: [
9640
+ {
9641
+ internalType: "uint256",
9642
+ name: "positionSizeCollateral",
9643
+ type: "uint256",
9644
+ },
9645
+ {
9646
+ internalType: "uint256",
9647
+ name: "gnsPriceCollateral",
9648
+ type: "uint256",
9649
+ },
9650
+ {
9651
+ internalType: "int256",
9652
+ name: "profitP",
9653
+ type: "int256",
9654
+ },
9655
+ {
9656
+ internalType: "uint256",
9657
+ name: "executionPrice",
9658
+ type: "uint256",
9659
+ },
9660
+ {
9661
+ internalType: "uint256",
9662
+ name: "liqPrice",
9663
+ type: "uint256",
9664
+ },
9665
+ {
9666
+ internalType: "uint256",
9667
+ name: "amountSentToTrader",
9668
+ type: "uint256",
9669
+ },
9670
+ {
9671
+ internalType: "uint256",
9672
+ name: "reward1",
9673
+ type: "uint256",
9674
+ },
9675
+ {
9676
+ internalType: "uint256",
9677
+ name: "reward2",
9678
+ type: "uint256",
9679
+ },
9680
+ {
9681
+ internalType: "uint256",
9682
+ name: "reward3",
9683
+ type: "uint256",
9684
+ },
9685
+ {
9686
+ internalType: "uint128",
9687
+ name: "collateralPrecisionDelta",
9688
+ type: "uint128",
9689
+ },
9690
+ {
9691
+ internalType: "uint256",
9692
+ name: "collateralPriceUsd",
9693
+ type: "uint256",
9694
+ },
9695
+ {
9696
+ internalType: "bool",
9697
+ name: "exactExecution",
9698
+ type: "bool",
9699
+ },
9700
+ {
9701
+ internalType: "uint256",
9702
+ name: "closingFeeCollateral",
9703
+ type: "uint256",
9704
+ },
9705
+ {
9706
+ internalType: "uint256",
9707
+ name: "triggerFeeCollateral",
9708
+ type: "uint256",
9709
+ },
9710
+ {
9711
+ internalType: "uint256",
9712
+ name: "collateralLeftInStorage",
9713
+ type: "uint256",
9714
+ },
9715
+ ],
9716
+ internalType: "struct ITradingCallbacks.Values",
9717
+ name: "v",
9718
+ type: "tuple",
9719
+ },
9720
+ {
9721
+ internalType: "uint256",
9722
+ name: "priceImpactP",
9723
+ type: "uint256",
9724
+ },
9725
+ ],
9726
+ stateMutability: "view",
9727
+ type: "function",
9728
+ signature: "0x85ea3c78",
9729
+ },
9730
+ {
9731
+ inputs: [
9732
+ {
9733
+ components: [
9734
+ {
9735
+ internalType: "address",
9736
+ name: "user",
9737
+ type: "address",
9738
+ },
9739
+ {
9740
+ internalType: "uint32",
9741
+ name: "index",
9742
+ type: "uint32",
9743
+ },
9744
+ ],
9745
+ internalType: "struct ITradingStorage.Id",
9746
+ name: "_tradeId",
9747
+ type: "tuple",
9748
+ },
9749
+ {
9750
+ internalType: "enum ITradingStorage.PendingOrderType",
9751
+ name: "_orderType",
9752
+ type: "uint8",
9753
+ },
9754
+ {
9755
+ internalType: "uint64",
9756
+ name: "_open",
9757
+ type: "uint64",
9758
+ },
9759
+ {
9760
+ internalType: "uint64",
9761
+ name: "_high",
9762
+ type: "uint64",
9763
+ },
9764
+ {
9765
+ internalType: "uint64",
9766
+ name: "_low",
9767
+ type: "uint64",
9768
+ },
9769
+ ],
9770
+ name: "validateTriggerOpenOrderCallback",
9771
+ outputs: [
9772
+ {
9773
+ components: [
9774
+ {
9775
+ internalType: "address",
9776
+ name: "user",
9777
+ type: "address",
9778
+ },
9779
+ {
9780
+ internalType: "uint32",
9781
+ name: "index",
9782
+ type: "uint32",
9783
+ },
9784
+ {
9785
+ internalType: "uint16",
9786
+ name: "pairIndex",
9787
+ type: "uint16",
9788
+ },
9789
+ {
9790
+ internalType: "uint24",
9791
+ name: "leverage",
9792
+ type: "uint24",
9793
+ },
9794
+ {
9795
+ internalType: "bool",
9796
+ name: "long",
9797
+ type: "bool",
9798
+ },
9799
+ {
9800
+ internalType: "bool",
9801
+ name: "isOpen",
9802
+ type: "bool",
9803
+ },
9804
+ {
9805
+ internalType: "uint8",
9806
+ name: "collateralIndex",
9807
+ type: "uint8",
9808
+ },
9809
+ {
9810
+ internalType: "enum ITradingStorage.TradeType",
9811
+ name: "tradeType",
9812
+ type: "uint8",
9813
+ },
9814
+ {
9815
+ internalType: "uint120",
9816
+ name: "collateralAmount",
9817
+ type: "uint120",
9818
+ },
9819
+ {
9820
+ internalType: "uint64",
9821
+ name: "openPrice",
9822
+ type: "uint64",
9823
+ },
9824
+ {
9825
+ internalType: "uint64",
9826
+ name: "tp",
9827
+ type: "uint64",
9828
+ },
9829
+ {
9830
+ internalType: "uint64",
9831
+ name: "sl",
9832
+ type: "uint64",
9833
+ },
9834
+ {
9835
+ internalType: "uint192",
9836
+ name: "__placeholder",
9837
+ type: "uint192",
9838
+ },
9839
+ ],
9840
+ internalType: "struct ITradingStorage.Trade",
9841
+ name: "t",
9842
+ type: "tuple",
9843
+ },
9844
+ {
9845
+ internalType: "enum ITradingCallbacks.CancelReason",
9846
+ name: "cancelReason",
9847
+ type: "uint8",
9848
+ },
9849
+ {
9850
+ internalType: "uint256",
9851
+ name: "priceImpactP",
9852
+ type: "uint256",
9853
+ },
9854
+ {
9855
+ internalType: "uint256",
9856
+ name: "priceAfterImpact",
9857
+ type: "uint256",
9858
+ },
9859
+ {
9860
+ internalType: "bool",
9861
+ name: "exactExecution",
9862
+ type: "bool",
9863
+ },
9864
+ ],
9865
+ stateMutability: "view",
9866
+ type: "function",
9867
+ signature: "0xa96ae63b",
9868
+ },
9869
+ {
9870
+ inputs: [],
9871
+ name: "BorrowingWrongExponent",
9872
+ type: "error",
9873
+ },
9874
+ {
9875
+ inputs: [],
9876
+ name: "BorrowingZeroGroup",
9877
+ type: "error",
9878
+ },
9879
+ {
9880
+ anonymous: false,
9881
+ inputs: [
9882
+ {
9883
+ indexed: true,
9884
+ internalType: "uint8",
9885
+ name: "collateralIndex",
9886
+ type: "uint8",
9887
+ },
9888
+ {
9889
+ indexed: true,
9890
+ internalType: "uint16",
9891
+ name: "groupIndex",
9892
+ type: "uint16",
9893
+ },
9894
+ {
9895
+ indexed: false,
9896
+ internalType: "uint256",
9897
+ name: "currentBlock",
9898
+ type: "uint256",
9899
+ },
9900
+ {
9901
+ indexed: false,
9902
+ internalType: "uint64",
9903
+ name: "accFeeLong",
9904
+ type: "uint64",
9905
+ },
9906
+ {
9907
+ indexed: false,
9908
+ internalType: "uint64",
9909
+ name: "accFeeShort",
9910
+ type: "uint64",
9911
+ },
9912
+ ],
9913
+ name: "BorrowingGroupAccFeesUpdated",
9914
+ type: "event",
9915
+ signature: "0xb4297e7afacc3feba1f03e1a444e70031a62f3ae4d6372c2b0cb3e0e62e8568e",
9485
9916
  },
9486
9917
  {
9487
9918
  anonymous: false,
@@ -10683,6 +11114,38 @@ const _abi = [
10683
11114
  name: "useBorrowingFees",
10684
11115
  type: "bool",
10685
11116
  },
11117
+ {
11118
+ components: [
11119
+ {
11120
+ internalType: "uint40",
11121
+ name: "maxLiqSpreadP",
11122
+ type: "uint40",
11123
+ },
11124
+ {
11125
+ internalType: "uint40",
11126
+ name: "startLiqThresholdP",
11127
+ type: "uint40",
11128
+ },
11129
+ {
11130
+ internalType: "uint40",
11131
+ name: "endLiqThresholdP",
11132
+ type: "uint40",
11133
+ },
11134
+ {
11135
+ internalType: "uint24",
11136
+ name: "startLeverage",
11137
+ type: "uint24",
11138
+ },
11139
+ {
11140
+ internalType: "uint24",
11141
+ name: "endLeverage",
11142
+ type: "uint24",
11143
+ },
11144
+ ],
11145
+ internalType: "struct IPairsStorage.GroupLiquidationParams",
11146
+ name: "liquidationParams",
11147
+ type: "tuple",
11148
+ },
10686
11149
  ],
10687
11150
  internalType: "struct IBorrowingFees.LiqPriceInput",
10688
11151
  name: "_input",
@@ -10699,7 +11162,7 @@ const _abi = [
10699
11162
  ],
10700
11163
  stateMutability: "view",
10701
11164
  type: "function",
10702
- signature: "0xea122fd8",
11165
+ signature: "0x61ddacb0",
10703
11166
  },
10704
11167
  {
10705
11168
  inputs: [
@@ -11013,11 +11476,6 @@ const _abi = [
11013
11476
  name: "SourceNotOracleOfRequest",
11014
11477
  type: "error",
11015
11478
  },
11016
- {
11017
- inputs: [],
11018
- name: "T",
11019
- type: "error",
11020
- },
11021
11479
  {
11022
11480
  inputs: [],
11023
11481
  name: "TransferAndCallToOracleFailed",
@@ -11028,34 +11486,6 @@ const _abi = [
11028
11486
  name: "WrongCollateralUsdDecimals",
11029
11487
  type: "error",
11030
11488
  },
11031
- {
11032
- anonymous: false,
11033
- inputs: [
11034
- {
11035
- indexed: true,
11036
- internalType: "bytes32",
11037
- name: "id",
11038
- type: "bytes32",
11039
- },
11040
- ],
11041
- name: "ChainlinkFulfilled",
11042
- type: "event",
11043
- signature: "0x7cc135e0cebb02c3480ae5d74d377283180a2601f8f644edf7987b009316c63a",
11044
- },
11045
- {
11046
- anonymous: false,
11047
- inputs: [
11048
- {
11049
- indexed: true,
11050
- internalType: "bytes32",
11051
- name: "id",
11052
- type: "bytes32",
11053
- },
11054
- ],
11055
- name: "ChainlinkRequested",
11056
- type: "event",
11057
- signature: "0xb5e6e01e79f91267dc17b4e6314d5d4d03593d2ceee0fbb452b750bd70ea5af9",
11058
- },
11059
11489
  {
11060
11490
  anonymous: false,
11061
11491
  inputs: [
@@ -11364,18 +11794,30 @@ const _abi = [
11364
11794
  name: "collateralIndex",
11365
11795
  type: "uint8",
11366
11796
  },
11367
- {
11368
- indexed: true,
11369
- internalType: "address",
11370
- name: "trader",
11371
- type: "address",
11372
- },
11373
11797
  {
11374
11798
  indexed: true,
11375
11799
  internalType: "uint256",
11376
11800
  name: "pairIndex",
11377
11801
  type: "uint256",
11378
11802
  },
11803
+ {
11804
+ components: [
11805
+ {
11806
+ internalType: "address",
11807
+ name: "user",
11808
+ type: "address",
11809
+ },
11810
+ {
11811
+ internalType: "uint32",
11812
+ name: "index",
11813
+ type: "uint32",
11814
+ },
11815
+ ],
11816
+ indexed: false,
11817
+ internalType: "struct ITradingStorage.Id",
11818
+ name: "tradeId",
11819
+ type: "tuple",
11820
+ },
11379
11821
  {
11380
11822
  components: [
11381
11823
  {
@@ -11433,7 +11875,7 @@ const _abi = [
11433
11875
  ],
11434
11876
  name: "PriceRequested",
11435
11877
  type: "event",
11436
- signature: "0x64ef5f525ba1978b433275b3e10998a2fac9ccad2c78aa723bb841fe527beb3b",
11878
+ signature: "0x59fd16e7bbed6457d473d57a799cffde3ff43e27a3a87479a5a431b4801f754f",
11437
11879
  },
11438
11880
  {
11439
11881
  anonymous: false,
@@ -11887,16 +12329,28 @@ const _abi = [
11887
12329
  name: "_collateralIndex",
11888
12330
  type: "uint8",
11889
12331
  },
11890
- {
11891
- internalType: "address",
11892
- name: "_trader",
11893
- type: "address",
11894
- },
11895
12332
  {
11896
12333
  internalType: "uint16",
11897
12334
  name: "_pairIndex",
11898
12335
  type: "uint16",
11899
12336
  },
12337
+ {
12338
+ components: [
12339
+ {
12340
+ internalType: "address",
12341
+ name: "user",
12342
+ type: "address",
12343
+ },
12344
+ {
12345
+ internalType: "uint32",
12346
+ name: "index",
12347
+ type: "uint32",
12348
+ },
12349
+ ],
12350
+ internalType: "struct ITradingStorage.Id",
12351
+ name: "_tradeId",
12352
+ type: "tuple",
12353
+ },
11900
12354
  {
11901
12355
  components: [
11902
12356
  {
@@ -11934,7 +12388,7 @@ const _abi = [
11934
12388
  outputs: [],
11935
12389
  stateMutability: "nonpayable",
11936
12390
  type: "function",
11937
- signature: "0x10d86d65",
12391
+ signature: "0x7e156b8c",
11938
12392
  },
11939
12393
  {
11940
12394
  inputs: [