@d8x/perpetuals-sdk 2.5.1 → 2.5.3
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/dist/cjs/abi/CompositeToken.json +894 -0
- package/dist/cjs/config/defaultConfig.json +1 -1
- package/dist/cjs/config/priceFeedOnChain.json +10 -0
- package/dist/cjs/contracts/CompositeToken.d.ts +426 -0
- package/dist/cjs/contracts/CompositeToken.js +3 -0
- package/dist/cjs/contracts/CompositeToken.js.map +1 -0
- package/dist/cjs/contracts/factories/CompositeToken__factory.d.ts +689 -0
- package/dist/cjs/contracts/factories/CompositeToken__factory.js +912 -0
- package/dist/cjs/contracts/factories/CompositeToken__factory.js.map +1 -0
- package/dist/cjs/contracts/factories/index.d.ts +1 -0
- package/dist/cjs/contracts/factories/index.js +3 -1
- package/dist/cjs/contracts/factories/index.js.map +1 -1
- package/dist/cjs/contracts/index.d.ts +2 -0
- package/dist/cjs/contracts/index.js +3 -1
- package/dist/cjs/contracts/index.js.map +1 -1
- package/dist/cjs/marketData.js +10 -1
- package/dist/cjs/marketData.js.map +1 -1
- package/dist/cjs/onChainPxFactory.js +5 -4
- package/dist/cjs/onChainPxFactory.js.map +1 -1
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/abi/CompositeToken.json +894 -0
- package/dist/esm/config/defaultConfig.json +1 -1
- package/dist/esm/config/priceFeedOnChain.json +10 -0
- package/dist/esm/contracts/CompositeToken.d.ts +426 -0
- package/dist/esm/contracts/CompositeToken.js +2 -0
- package/dist/esm/contracts/CompositeToken.js.map +1 -0
- package/dist/esm/contracts/factories/CompositeToken__factory.d.ts +689 -0
- package/dist/esm/contracts/factories/CompositeToken__factory.js +908 -0
- package/dist/esm/contracts/factories/CompositeToken__factory.js.map +1 -0
- package/dist/esm/contracts/factories/index.d.ts +1 -0
- package/dist/esm/contracts/factories/index.js +1 -0
- package/dist/esm/contracts/factories/index.js.map +1 -1
- package/dist/esm/contracts/index.d.ts +2 -0
- package/dist/esm/contracts/index.js +1 -0
- package/dist/esm/contracts/index.js.map +1 -1
- package/dist/esm/marketData.js +11 -2
- package/dist/esm/marketData.js.map +1 -1
- package/dist/esm/onChainPxFactory.js +5 -4
- package/dist/esm/onChainPxFactory.js.map +1 -1
- package/dist/esm/version.d.ts +1 -1
- package/dist/esm/version.js +1 -1
- package/package.json +1 -1
- package/src/abi/CompositeToken.json +894 -0
- package/src/config/defaultConfig.json +1 -1
- package/src/config/priceFeedOnChain.json +10 -0
- package/src/contracts/CompositeToken.ts +845 -0
- package/src/contracts/factories/CompositeToken__factory.ts +917 -0
- package/src/contracts/factories/index.ts +1 -0
- package/src/contracts/index.ts +2 -0
- package/src/marketData.ts +11 -3
- package/src/onChainPxFactory.ts +4 -3
- package/src/version.ts +1 -1
|
@@ -180,6 +180,6 @@
|
|
|
180
180
|
"proxyABILocation": "./abi/IPerpetualManager.json",
|
|
181
181
|
"limitOrderBookFactoryABILocation": "./abi/LimitOrderBookFactory.json",
|
|
182
182
|
"limitOrderBookABILocation": "./abi/LimitOrderBook.json",
|
|
183
|
-
"configSource": "https://raw.githubusercontent.com/D8-X/sync-hub/
|
|
183
|
+
"configSource": "https://raw.githubusercontent.com/D8-X/sync-hub/refs/heads/bera-usd-busd/d8x-futures-node-sdk/"
|
|
184
184
|
}
|
|
185
185
|
]
|
|
@@ -22,5 +22,15 @@
|
|
|
22
22
|
"https://arbitrum.blockpi.network/v1/rpc/public",
|
|
23
23
|
"https://arbitrum-one.public.blastapi.io"
|
|
24
24
|
]
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
"name": "bUSD-USD",
|
|
28
|
+
"rpcs": [
|
|
29
|
+
"https://rpc.berachain.com",
|
|
30
|
+
"https://berachain.blockpi.network/v1/rpc/public",
|
|
31
|
+
"https://berachain-rpc.publicnode.com"
|
|
32
|
+
],
|
|
33
|
+
"pxFeedAddress": "0xA8655EF2354d679E2553C10b2d59a61C4345aF51",
|
|
34
|
+
"decimals": 6
|
|
25
35
|
}
|
|
26
36
|
]
|
|
@@ -0,0 +1,426 @@
|
|
|
1
|
+
import type { BaseContract, BigNumberish, BytesLike, FunctionFragment, Result, Interface, EventFragment, AddressLike, ContractRunner, ContractMethod, Listener } from "ethers";
|
|
2
|
+
import type { TypedContractEvent, TypedDeferredTopicFilter, TypedEventLog, TypedLogDescription, TypedListener, TypedContractMethod } from "./common";
|
|
3
|
+
export interface CompositeTokenInterface extends Interface {
|
|
4
|
+
getFunction(nameOrSignature: "CMP_DECIMALS" | "UPGRADE_INTERFACE_VERSION" | "addTokens" | "allowance" | "approve" | "balanceOf" | "controller" | "decimals" | "effectiveBalanceOf" | "getSupportedTokens" | "initialize" | "latestRoundData" | "name" | "owner" | "proxiableUUID" | "registerAccount" | "registeredToken" | "removeTokens" | "renounceOwnership" | "setController" | "supportedToken" | "symbol" | "totalInvested" | "totalSupply" | "totalValue" | "transfer" | "transferFrom" | "transferOwnership" | "upgradeToAndCall"): FunctionFragment;
|
|
5
|
+
getEvent(nameOrSignatureOrTopic: "AccountRegistered" | "Approval" | "ControllerSet" | "Initialized" | "OwnershipTransferred" | "TokenSupported" | "Transfer" | "Upgraded"): EventFragment;
|
|
6
|
+
encodeFunctionData(functionFragment: "CMP_DECIMALS", values?: undefined): string;
|
|
7
|
+
encodeFunctionData(functionFragment: "UPGRADE_INTERFACE_VERSION", values?: undefined): string;
|
|
8
|
+
encodeFunctionData(functionFragment: "addTokens", values: [AddressLike[], AddressLike[], BytesLike[]]): string;
|
|
9
|
+
encodeFunctionData(functionFragment: "allowance", values: [AddressLike, AddressLike]): string;
|
|
10
|
+
encodeFunctionData(functionFragment: "approve", values: [AddressLike, BigNumberish]): string;
|
|
11
|
+
encodeFunctionData(functionFragment: "balanceOf", values: [AddressLike]): string;
|
|
12
|
+
encodeFunctionData(functionFragment: "controller", values?: undefined): string;
|
|
13
|
+
encodeFunctionData(functionFragment: "decimals", values?: undefined): string;
|
|
14
|
+
encodeFunctionData(functionFragment: "effectiveBalanceOf", values: [AddressLike]): string;
|
|
15
|
+
encodeFunctionData(functionFragment: "getSupportedTokens", values?: undefined): string;
|
|
16
|
+
encodeFunctionData(functionFragment: "initialize", values: [AddressLike, AddressLike[], AddressLike[], BytesLike[]]): string;
|
|
17
|
+
encodeFunctionData(functionFragment: "latestRoundData", values?: undefined): string;
|
|
18
|
+
encodeFunctionData(functionFragment: "name", values?: undefined): string;
|
|
19
|
+
encodeFunctionData(functionFragment: "owner", values?: undefined): string;
|
|
20
|
+
encodeFunctionData(functionFragment: "proxiableUUID", values?: undefined): string;
|
|
21
|
+
encodeFunctionData(functionFragment: "registerAccount", values: [AddressLike]): string;
|
|
22
|
+
encodeFunctionData(functionFragment: "registeredToken", values: [AddressLike]): string;
|
|
23
|
+
encodeFunctionData(functionFragment: "removeTokens", values: [AddressLike[]]): string;
|
|
24
|
+
encodeFunctionData(functionFragment: "renounceOwnership", values?: undefined): string;
|
|
25
|
+
encodeFunctionData(functionFragment: "setController", values: [AddressLike]): string;
|
|
26
|
+
encodeFunctionData(functionFragment: "supportedToken", values: [AddressLike]): string;
|
|
27
|
+
encodeFunctionData(functionFragment: "symbol", values?: undefined): string;
|
|
28
|
+
encodeFunctionData(functionFragment: "totalInvested", values: [AddressLike]): string;
|
|
29
|
+
encodeFunctionData(functionFragment: "totalSupply", values?: undefined): string;
|
|
30
|
+
encodeFunctionData(functionFragment: "totalValue", values?: undefined): string;
|
|
31
|
+
encodeFunctionData(functionFragment: "transfer", values: [AddressLike, BigNumberish]): string;
|
|
32
|
+
encodeFunctionData(functionFragment: "transferFrom", values: [AddressLike, AddressLike, BigNumberish]): string;
|
|
33
|
+
encodeFunctionData(functionFragment: "transferOwnership", values: [AddressLike]): string;
|
|
34
|
+
encodeFunctionData(functionFragment: "upgradeToAndCall", values: [AddressLike, BytesLike]): string;
|
|
35
|
+
decodeFunctionResult(functionFragment: "CMP_DECIMALS", data: BytesLike): Result;
|
|
36
|
+
decodeFunctionResult(functionFragment: "UPGRADE_INTERFACE_VERSION", data: BytesLike): Result;
|
|
37
|
+
decodeFunctionResult(functionFragment: "addTokens", data: BytesLike): Result;
|
|
38
|
+
decodeFunctionResult(functionFragment: "allowance", data: BytesLike): Result;
|
|
39
|
+
decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result;
|
|
40
|
+
decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result;
|
|
41
|
+
decodeFunctionResult(functionFragment: "controller", data: BytesLike): Result;
|
|
42
|
+
decodeFunctionResult(functionFragment: "decimals", data: BytesLike): Result;
|
|
43
|
+
decodeFunctionResult(functionFragment: "effectiveBalanceOf", data: BytesLike): Result;
|
|
44
|
+
decodeFunctionResult(functionFragment: "getSupportedTokens", data: BytesLike): Result;
|
|
45
|
+
decodeFunctionResult(functionFragment: "initialize", data: BytesLike): Result;
|
|
46
|
+
decodeFunctionResult(functionFragment: "latestRoundData", data: BytesLike): Result;
|
|
47
|
+
decodeFunctionResult(functionFragment: "name", data: BytesLike): Result;
|
|
48
|
+
decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result;
|
|
49
|
+
decodeFunctionResult(functionFragment: "proxiableUUID", data: BytesLike): Result;
|
|
50
|
+
decodeFunctionResult(functionFragment: "registerAccount", data: BytesLike): Result;
|
|
51
|
+
decodeFunctionResult(functionFragment: "registeredToken", data: BytesLike): Result;
|
|
52
|
+
decodeFunctionResult(functionFragment: "removeTokens", data: BytesLike): Result;
|
|
53
|
+
decodeFunctionResult(functionFragment: "renounceOwnership", data: BytesLike): Result;
|
|
54
|
+
decodeFunctionResult(functionFragment: "setController", data: BytesLike): Result;
|
|
55
|
+
decodeFunctionResult(functionFragment: "supportedToken", data: BytesLike): Result;
|
|
56
|
+
decodeFunctionResult(functionFragment: "symbol", data: BytesLike): Result;
|
|
57
|
+
decodeFunctionResult(functionFragment: "totalInvested", data: BytesLike): Result;
|
|
58
|
+
decodeFunctionResult(functionFragment: "totalSupply", data: BytesLike): Result;
|
|
59
|
+
decodeFunctionResult(functionFragment: "totalValue", data: BytesLike): Result;
|
|
60
|
+
decodeFunctionResult(functionFragment: "transfer", data: BytesLike): Result;
|
|
61
|
+
decodeFunctionResult(functionFragment: "transferFrom", data: BytesLike): Result;
|
|
62
|
+
decodeFunctionResult(functionFragment: "transferOwnership", data: BytesLike): Result;
|
|
63
|
+
decodeFunctionResult(functionFragment: "upgradeToAndCall", data: BytesLike): Result;
|
|
64
|
+
}
|
|
65
|
+
export declare namespace AccountRegisteredEvent {
|
|
66
|
+
type InputTuple = [token: AddressLike, account: AddressLike];
|
|
67
|
+
type OutputTuple = [token: string, account: string];
|
|
68
|
+
interface OutputObject {
|
|
69
|
+
token: string;
|
|
70
|
+
account: string;
|
|
71
|
+
}
|
|
72
|
+
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
|
|
73
|
+
type Filter = TypedDeferredTopicFilter<Event>;
|
|
74
|
+
type Log = TypedEventLog<Event>;
|
|
75
|
+
type LogDescription = TypedLogDescription<Event>;
|
|
76
|
+
}
|
|
77
|
+
export declare namespace ApprovalEvent {
|
|
78
|
+
type InputTuple = [
|
|
79
|
+
owner: AddressLike,
|
|
80
|
+
spender: AddressLike,
|
|
81
|
+
value: BigNumberish
|
|
82
|
+
];
|
|
83
|
+
type OutputTuple = [owner: string, spender: string, value: bigint];
|
|
84
|
+
interface OutputObject {
|
|
85
|
+
owner: string;
|
|
86
|
+
spender: string;
|
|
87
|
+
value: bigint;
|
|
88
|
+
}
|
|
89
|
+
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
|
|
90
|
+
type Filter = TypedDeferredTopicFilter<Event>;
|
|
91
|
+
type Log = TypedEventLog<Event>;
|
|
92
|
+
type LogDescription = TypedLogDescription<Event>;
|
|
93
|
+
}
|
|
94
|
+
export declare namespace ControllerSetEvent {
|
|
95
|
+
type InputTuple = [
|
|
96
|
+
oldController: AddressLike,
|
|
97
|
+
newController: AddressLike
|
|
98
|
+
];
|
|
99
|
+
type OutputTuple = [oldController: string, newController: string];
|
|
100
|
+
interface OutputObject {
|
|
101
|
+
oldController: string;
|
|
102
|
+
newController: string;
|
|
103
|
+
}
|
|
104
|
+
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
|
|
105
|
+
type Filter = TypedDeferredTopicFilter<Event>;
|
|
106
|
+
type Log = TypedEventLog<Event>;
|
|
107
|
+
type LogDescription = TypedLogDescription<Event>;
|
|
108
|
+
}
|
|
109
|
+
export declare namespace InitializedEvent {
|
|
110
|
+
type InputTuple = [version: BigNumberish];
|
|
111
|
+
type OutputTuple = [version: bigint];
|
|
112
|
+
interface OutputObject {
|
|
113
|
+
version: bigint;
|
|
114
|
+
}
|
|
115
|
+
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
|
|
116
|
+
type Filter = TypedDeferredTopicFilter<Event>;
|
|
117
|
+
type Log = TypedEventLog<Event>;
|
|
118
|
+
type LogDescription = TypedLogDescription<Event>;
|
|
119
|
+
}
|
|
120
|
+
export declare namespace OwnershipTransferredEvent {
|
|
121
|
+
type InputTuple = [previousOwner: AddressLike, newOwner: AddressLike];
|
|
122
|
+
type OutputTuple = [previousOwner: string, newOwner: string];
|
|
123
|
+
interface OutputObject {
|
|
124
|
+
previousOwner: string;
|
|
125
|
+
newOwner: string;
|
|
126
|
+
}
|
|
127
|
+
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
|
|
128
|
+
type Filter = TypedDeferredTopicFilter<Event>;
|
|
129
|
+
type Log = TypedEventLog<Event>;
|
|
130
|
+
type LogDescription = TypedLogDescription<Event>;
|
|
131
|
+
}
|
|
132
|
+
export declare namespace TokenSupportedEvent {
|
|
133
|
+
type InputTuple = [token: AddressLike, supported: boolean];
|
|
134
|
+
type OutputTuple = [token: string, supported: boolean];
|
|
135
|
+
interface OutputObject {
|
|
136
|
+
token: string;
|
|
137
|
+
supported: boolean;
|
|
138
|
+
}
|
|
139
|
+
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
|
|
140
|
+
type Filter = TypedDeferredTopicFilter<Event>;
|
|
141
|
+
type Log = TypedEventLog<Event>;
|
|
142
|
+
type LogDescription = TypedLogDescription<Event>;
|
|
143
|
+
}
|
|
144
|
+
export declare namespace TransferEvent {
|
|
145
|
+
type InputTuple = [
|
|
146
|
+
from: AddressLike,
|
|
147
|
+
to: AddressLike,
|
|
148
|
+
value: BigNumberish
|
|
149
|
+
];
|
|
150
|
+
type OutputTuple = [from: string, to: string, value: bigint];
|
|
151
|
+
interface OutputObject {
|
|
152
|
+
from: string;
|
|
153
|
+
to: string;
|
|
154
|
+
value: bigint;
|
|
155
|
+
}
|
|
156
|
+
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
|
|
157
|
+
type Filter = TypedDeferredTopicFilter<Event>;
|
|
158
|
+
type Log = TypedEventLog<Event>;
|
|
159
|
+
type LogDescription = TypedLogDescription<Event>;
|
|
160
|
+
}
|
|
161
|
+
export declare namespace UpgradedEvent {
|
|
162
|
+
type InputTuple = [implementation: AddressLike];
|
|
163
|
+
type OutputTuple = [implementation: string];
|
|
164
|
+
interface OutputObject {
|
|
165
|
+
implementation: string;
|
|
166
|
+
}
|
|
167
|
+
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
|
|
168
|
+
type Filter = TypedDeferredTopicFilter<Event>;
|
|
169
|
+
type Log = TypedEventLog<Event>;
|
|
170
|
+
type LogDescription = TypedLogDescription<Event>;
|
|
171
|
+
}
|
|
172
|
+
export interface CompositeToken extends BaseContract {
|
|
173
|
+
connect(runner?: ContractRunner | null): CompositeToken;
|
|
174
|
+
waitForDeployment(): Promise<this>;
|
|
175
|
+
interface: CompositeTokenInterface;
|
|
176
|
+
queryFilter<TCEvent extends TypedContractEvent>(event: TCEvent, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined): Promise<Array<TypedEventLog<TCEvent>>>;
|
|
177
|
+
queryFilter<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined): Promise<Array<TypedEventLog<TCEvent>>>;
|
|
178
|
+
on<TCEvent extends TypedContractEvent>(event: TCEvent, listener: TypedListener<TCEvent>): Promise<this>;
|
|
179
|
+
on<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, listener: TypedListener<TCEvent>): Promise<this>;
|
|
180
|
+
once<TCEvent extends TypedContractEvent>(event: TCEvent, listener: TypedListener<TCEvent>): Promise<this>;
|
|
181
|
+
once<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, listener: TypedListener<TCEvent>): Promise<this>;
|
|
182
|
+
listeners<TCEvent extends TypedContractEvent>(event: TCEvent): Promise<Array<TypedListener<TCEvent>>>;
|
|
183
|
+
listeners(eventName?: string): Promise<Array<Listener>>;
|
|
184
|
+
removeAllListeners<TCEvent extends TypedContractEvent>(event?: TCEvent): Promise<this>;
|
|
185
|
+
CMP_DECIMALS: TypedContractMethod<[], [bigint], "view">;
|
|
186
|
+
UPGRADE_INTERFACE_VERSION: TypedContractMethod<[], [string], "view">;
|
|
187
|
+
addTokens: TypedContractMethod<[
|
|
188
|
+
_tokens: AddressLike[],
|
|
189
|
+
_feeds: AddressLike[],
|
|
190
|
+
_ids: BytesLike[]
|
|
191
|
+
], [
|
|
192
|
+
void
|
|
193
|
+
], "nonpayable">;
|
|
194
|
+
allowance: TypedContractMethod<[
|
|
195
|
+
_owner: AddressLike,
|
|
196
|
+
_spender: AddressLike
|
|
197
|
+
], [
|
|
198
|
+
bigint
|
|
199
|
+
], "view">;
|
|
200
|
+
approve: TypedContractMethod<[
|
|
201
|
+
spender: AddressLike,
|
|
202
|
+
value: BigNumberish
|
|
203
|
+
], [
|
|
204
|
+
boolean
|
|
205
|
+
], "nonpayable">;
|
|
206
|
+
balanceOf: TypedContractMethod<[account: AddressLike], [bigint], "view">;
|
|
207
|
+
controller: TypedContractMethod<[], [string], "view">;
|
|
208
|
+
decimals: TypedContractMethod<[], [bigint], "view">;
|
|
209
|
+
effectiveBalanceOf: TypedContractMethod<[
|
|
210
|
+
_account: AddressLike
|
|
211
|
+
], [
|
|
212
|
+
bigint
|
|
213
|
+
], "view">;
|
|
214
|
+
getSupportedTokens: TypedContractMethod<[], [string[]], "view">;
|
|
215
|
+
initialize: TypedContractMethod<[
|
|
216
|
+
_owner: AddressLike,
|
|
217
|
+
_tokens: AddressLike[],
|
|
218
|
+
_feeds: AddressLike[],
|
|
219
|
+
_ids: BytesLike[]
|
|
220
|
+
], [
|
|
221
|
+
void
|
|
222
|
+
], "nonpayable">;
|
|
223
|
+
latestRoundData: TypedContractMethod<[
|
|
224
|
+
], [
|
|
225
|
+
[
|
|
226
|
+
bigint,
|
|
227
|
+
bigint,
|
|
228
|
+
bigint,
|
|
229
|
+
bigint,
|
|
230
|
+
bigint
|
|
231
|
+
] & {
|
|
232
|
+
roundId: bigint;
|
|
233
|
+
answer: bigint;
|
|
234
|
+
startedAt: bigint;
|
|
235
|
+
updatedAt: bigint;
|
|
236
|
+
answeredInRound: bigint;
|
|
237
|
+
}
|
|
238
|
+
], "view">;
|
|
239
|
+
name: TypedContractMethod<[], [string], "view">;
|
|
240
|
+
owner: TypedContractMethod<[], [string], "view">;
|
|
241
|
+
proxiableUUID: TypedContractMethod<[], [string], "view">;
|
|
242
|
+
registerAccount: TypedContractMethod<[
|
|
243
|
+
_token: AddressLike
|
|
244
|
+
], [
|
|
245
|
+
void
|
|
246
|
+
], "nonpayable">;
|
|
247
|
+
registeredToken: TypedContractMethod<[arg0: AddressLike], [string], "view">;
|
|
248
|
+
removeTokens: TypedContractMethod<[
|
|
249
|
+
_tokens: AddressLike[]
|
|
250
|
+
], [
|
|
251
|
+
void
|
|
252
|
+
], "nonpayable">;
|
|
253
|
+
renounceOwnership: TypedContractMethod<[], [void], "nonpayable">;
|
|
254
|
+
setController: TypedContractMethod<[
|
|
255
|
+
_newController: AddressLike
|
|
256
|
+
], [
|
|
257
|
+
void
|
|
258
|
+
], "nonpayable">;
|
|
259
|
+
supportedToken: TypedContractMethod<[
|
|
260
|
+
arg0: AddressLike
|
|
261
|
+
], [
|
|
262
|
+
[
|
|
263
|
+
string,
|
|
264
|
+
string,
|
|
265
|
+
bigint,
|
|
266
|
+
bigint
|
|
267
|
+
] & {
|
|
268
|
+
id: string;
|
|
269
|
+
feed: string;
|
|
270
|
+
tokenDecimals: bigint;
|
|
271
|
+
feedDecimals: bigint;
|
|
272
|
+
}
|
|
273
|
+
], "view">;
|
|
274
|
+
symbol: TypedContractMethod<[], [string], "view">;
|
|
275
|
+
totalInvested: TypedContractMethod<[arg0: AddressLike], [bigint], "view">;
|
|
276
|
+
totalSupply: TypedContractMethod<[], [bigint], "view">;
|
|
277
|
+
totalValue: TypedContractMethod<[], [bigint], "view">;
|
|
278
|
+
transfer: TypedContractMethod<[
|
|
279
|
+
to: AddressLike,
|
|
280
|
+
value: BigNumberish
|
|
281
|
+
], [
|
|
282
|
+
boolean
|
|
283
|
+
], "nonpayable">;
|
|
284
|
+
transferFrom: TypedContractMethod<[
|
|
285
|
+
from: AddressLike,
|
|
286
|
+
to: AddressLike,
|
|
287
|
+
value: BigNumberish
|
|
288
|
+
], [
|
|
289
|
+
boolean
|
|
290
|
+
], "nonpayable">;
|
|
291
|
+
transferOwnership: TypedContractMethod<[
|
|
292
|
+
newOwner: AddressLike
|
|
293
|
+
], [
|
|
294
|
+
void
|
|
295
|
+
], "nonpayable">;
|
|
296
|
+
upgradeToAndCall: TypedContractMethod<[
|
|
297
|
+
newImplementation: AddressLike,
|
|
298
|
+
data: BytesLike
|
|
299
|
+
], [
|
|
300
|
+
void
|
|
301
|
+
], "payable">;
|
|
302
|
+
getFunction<T extends ContractMethod = ContractMethod>(key: string | FunctionFragment): T;
|
|
303
|
+
getFunction(nameOrSignature: "CMP_DECIMALS"): TypedContractMethod<[], [bigint], "view">;
|
|
304
|
+
getFunction(nameOrSignature: "UPGRADE_INTERFACE_VERSION"): TypedContractMethod<[], [string], "view">;
|
|
305
|
+
getFunction(nameOrSignature: "addTokens"): TypedContractMethod<[
|
|
306
|
+
_tokens: AddressLike[],
|
|
307
|
+
_feeds: AddressLike[],
|
|
308
|
+
_ids: BytesLike[]
|
|
309
|
+
], [
|
|
310
|
+
void
|
|
311
|
+
], "nonpayable">;
|
|
312
|
+
getFunction(nameOrSignature: "allowance"): TypedContractMethod<[
|
|
313
|
+
_owner: AddressLike,
|
|
314
|
+
_spender: AddressLike
|
|
315
|
+
], [
|
|
316
|
+
bigint
|
|
317
|
+
], "view">;
|
|
318
|
+
getFunction(nameOrSignature: "approve"): TypedContractMethod<[
|
|
319
|
+
spender: AddressLike,
|
|
320
|
+
value: BigNumberish
|
|
321
|
+
], [
|
|
322
|
+
boolean
|
|
323
|
+
], "nonpayable">;
|
|
324
|
+
getFunction(nameOrSignature: "balanceOf"): TypedContractMethod<[account: AddressLike], [bigint], "view">;
|
|
325
|
+
getFunction(nameOrSignature: "controller"): TypedContractMethod<[], [string], "view">;
|
|
326
|
+
getFunction(nameOrSignature: "decimals"): TypedContractMethod<[], [bigint], "view">;
|
|
327
|
+
getFunction(nameOrSignature: "effectiveBalanceOf"): TypedContractMethod<[_account: AddressLike], [bigint], "view">;
|
|
328
|
+
getFunction(nameOrSignature: "getSupportedTokens"): TypedContractMethod<[], [string[]], "view">;
|
|
329
|
+
getFunction(nameOrSignature: "initialize"): TypedContractMethod<[
|
|
330
|
+
_owner: AddressLike,
|
|
331
|
+
_tokens: AddressLike[],
|
|
332
|
+
_feeds: AddressLike[],
|
|
333
|
+
_ids: BytesLike[]
|
|
334
|
+
], [
|
|
335
|
+
void
|
|
336
|
+
], "nonpayable">;
|
|
337
|
+
getFunction(nameOrSignature: "latestRoundData"): TypedContractMethod<[
|
|
338
|
+
], [
|
|
339
|
+
[
|
|
340
|
+
bigint,
|
|
341
|
+
bigint,
|
|
342
|
+
bigint,
|
|
343
|
+
bigint,
|
|
344
|
+
bigint
|
|
345
|
+
] & {
|
|
346
|
+
roundId: bigint;
|
|
347
|
+
answer: bigint;
|
|
348
|
+
startedAt: bigint;
|
|
349
|
+
updatedAt: bigint;
|
|
350
|
+
answeredInRound: bigint;
|
|
351
|
+
}
|
|
352
|
+
], "view">;
|
|
353
|
+
getFunction(nameOrSignature: "name"): TypedContractMethod<[], [string], "view">;
|
|
354
|
+
getFunction(nameOrSignature: "owner"): TypedContractMethod<[], [string], "view">;
|
|
355
|
+
getFunction(nameOrSignature: "proxiableUUID"): TypedContractMethod<[], [string], "view">;
|
|
356
|
+
getFunction(nameOrSignature: "registerAccount"): TypedContractMethod<[_token: AddressLike], [void], "nonpayable">;
|
|
357
|
+
getFunction(nameOrSignature: "registeredToken"): TypedContractMethod<[arg0: AddressLike], [string], "view">;
|
|
358
|
+
getFunction(nameOrSignature: "removeTokens"): TypedContractMethod<[_tokens: AddressLike[]], [void], "nonpayable">;
|
|
359
|
+
getFunction(nameOrSignature: "renounceOwnership"): TypedContractMethod<[], [void], "nonpayable">;
|
|
360
|
+
getFunction(nameOrSignature: "setController"): TypedContractMethod<[_newController: AddressLike], [void], "nonpayable">;
|
|
361
|
+
getFunction(nameOrSignature: "supportedToken"): TypedContractMethod<[
|
|
362
|
+
arg0: AddressLike
|
|
363
|
+
], [
|
|
364
|
+
[
|
|
365
|
+
string,
|
|
366
|
+
string,
|
|
367
|
+
bigint,
|
|
368
|
+
bigint
|
|
369
|
+
] & {
|
|
370
|
+
id: string;
|
|
371
|
+
feed: string;
|
|
372
|
+
tokenDecimals: bigint;
|
|
373
|
+
feedDecimals: bigint;
|
|
374
|
+
}
|
|
375
|
+
], "view">;
|
|
376
|
+
getFunction(nameOrSignature: "symbol"): TypedContractMethod<[], [string], "view">;
|
|
377
|
+
getFunction(nameOrSignature: "totalInvested"): TypedContractMethod<[arg0: AddressLike], [bigint], "view">;
|
|
378
|
+
getFunction(nameOrSignature: "totalSupply"): TypedContractMethod<[], [bigint], "view">;
|
|
379
|
+
getFunction(nameOrSignature: "totalValue"): TypedContractMethod<[], [bigint], "view">;
|
|
380
|
+
getFunction(nameOrSignature: "transfer"): TypedContractMethod<[
|
|
381
|
+
to: AddressLike,
|
|
382
|
+
value: BigNumberish
|
|
383
|
+
], [
|
|
384
|
+
boolean
|
|
385
|
+
], "nonpayable">;
|
|
386
|
+
getFunction(nameOrSignature: "transferFrom"): TypedContractMethod<[
|
|
387
|
+
from: AddressLike,
|
|
388
|
+
to: AddressLike,
|
|
389
|
+
value: BigNumberish
|
|
390
|
+
], [
|
|
391
|
+
boolean
|
|
392
|
+
], "nonpayable">;
|
|
393
|
+
getFunction(nameOrSignature: "transferOwnership"): TypedContractMethod<[newOwner: AddressLike], [void], "nonpayable">;
|
|
394
|
+
getFunction(nameOrSignature: "upgradeToAndCall"): TypedContractMethod<[
|
|
395
|
+
newImplementation: AddressLike,
|
|
396
|
+
data: BytesLike
|
|
397
|
+
], [
|
|
398
|
+
void
|
|
399
|
+
], "payable">;
|
|
400
|
+
getEvent(key: "AccountRegistered"): TypedContractEvent<AccountRegisteredEvent.InputTuple, AccountRegisteredEvent.OutputTuple, AccountRegisteredEvent.OutputObject>;
|
|
401
|
+
getEvent(key: "Approval"): TypedContractEvent<ApprovalEvent.InputTuple, ApprovalEvent.OutputTuple, ApprovalEvent.OutputObject>;
|
|
402
|
+
getEvent(key: "ControllerSet"): TypedContractEvent<ControllerSetEvent.InputTuple, ControllerSetEvent.OutputTuple, ControllerSetEvent.OutputObject>;
|
|
403
|
+
getEvent(key: "Initialized"): TypedContractEvent<InitializedEvent.InputTuple, InitializedEvent.OutputTuple, InitializedEvent.OutputObject>;
|
|
404
|
+
getEvent(key: "OwnershipTransferred"): TypedContractEvent<OwnershipTransferredEvent.InputTuple, OwnershipTransferredEvent.OutputTuple, OwnershipTransferredEvent.OutputObject>;
|
|
405
|
+
getEvent(key: "TokenSupported"): TypedContractEvent<TokenSupportedEvent.InputTuple, TokenSupportedEvent.OutputTuple, TokenSupportedEvent.OutputObject>;
|
|
406
|
+
getEvent(key: "Transfer"): TypedContractEvent<TransferEvent.InputTuple, TransferEvent.OutputTuple, TransferEvent.OutputObject>;
|
|
407
|
+
getEvent(key: "Upgraded"): TypedContractEvent<UpgradedEvent.InputTuple, UpgradedEvent.OutputTuple, UpgradedEvent.OutputObject>;
|
|
408
|
+
filters: {
|
|
409
|
+
"AccountRegistered(address,address)": TypedContractEvent<AccountRegisteredEvent.InputTuple, AccountRegisteredEvent.OutputTuple, AccountRegisteredEvent.OutputObject>;
|
|
410
|
+
AccountRegistered: TypedContractEvent<AccountRegisteredEvent.InputTuple, AccountRegisteredEvent.OutputTuple, AccountRegisteredEvent.OutputObject>;
|
|
411
|
+
"Approval(address,address,uint256)": TypedContractEvent<ApprovalEvent.InputTuple, ApprovalEvent.OutputTuple, ApprovalEvent.OutputObject>;
|
|
412
|
+
Approval: TypedContractEvent<ApprovalEvent.InputTuple, ApprovalEvent.OutputTuple, ApprovalEvent.OutputObject>;
|
|
413
|
+
"ControllerSet(address,address)": TypedContractEvent<ControllerSetEvent.InputTuple, ControllerSetEvent.OutputTuple, ControllerSetEvent.OutputObject>;
|
|
414
|
+
ControllerSet: TypedContractEvent<ControllerSetEvent.InputTuple, ControllerSetEvent.OutputTuple, ControllerSetEvent.OutputObject>;
|
|
415
|
+
"Initialized(uint64)": TypedContractEvent<InitializedEvent.InputTuple, InitializedEvent.OutputTuple, InitializedEvent.OutputObject>;
|
|
416
|
+
Initialized: TypedContractEvent<InitializedEvent.InputTuple, InitializedEvent.OutputTuple, InitializedEvent.OutputObject>;
|
|
417
|
+
"OwnershipTransferred(address,address)": TypedContractEvent<OwnershipTransferredEvent.InputTuple, OwnershipTransferredEvent.OutputTuple, OwnershipTransferredEvent.OutputObject>;
|
|
418
|
+
OwnershipTransferred: TypedContractEvent<OwnershipTransferredEvent.InputTuple, OwnershipTransferredEvent.OutputTuple, OwnershipTransferredEvent.OutputObject>;
|
|
419
|
+
"TokenSupported(address,bool)": TypedContractEvent<TokenSupportedEvent.InputTuple, TokenSupportedEvent.OutputTuple, TokenSupportedEvent.OutputObject>;
|
|
420
|
+
TokenSupported: TypedContractEvent<TokenSupportedEvent.InputTuple, TokenSupportedEvent.OutputTuple, TokenSupportedEvent.OutputObject>;
|
|
421
|
+
"Transfer(address,address,uint256)": TypedContractEvent<TransferEvent.InputTuple, TransferEvent.OutputTuple, TransferEvent.OutputObject>;
|
|
422
|
+
Transfer: TypedContractEvent<TransferEvent.InputTuple, TransferEvent.OutputTuple, TransferEvent.OutputObject>;
|
|
423
|
+
"Upgraded(address)": TypedContractEvent<UpgradedEvent.InputTuple, UpgradedEvent.OutputTuple, UpgradedEvent.OutputObject>;
|
|
424
|
+
Upgraded: TypedContractEvent<UpgradedEvent.InputTuple, UpgradedEvent.OutputTuple, UpgradedEvent.OutputObject>;
|
|
425
|
+
};
|
|
426
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CompositeToken.js","sourceRoot":"","sources":["../../../src/contracts/CompositeToken.ts"],"names":[],"mappings":""}
|