@covalenthq/client-sdk 1.0.2 → 2.0.1

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.
Files changed (192) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +223 -282
  3. package/dist/cjs/index.d.ts +17 -20
  4. package/dist/cjs/index.js +2331 -7659
  5. package/dist/cjs/index.js.map +1 -1
  6. package/dist/cjs/src/GoldRushClient.d.ts +20 -0
  7. package/dist/cjs/src/services/BalanceService.d.ts +125 -0
  8. package/dist/cjs/src/services/BaseService.d.ts +161 -0
  9. package/dist/cjs/src/services/NftService.d.ts +157 -0
  10. package/dist/cjs/src/services/PricingService.d.ts +25 -0
  11. package/dist/cjs/src/services/SecurityService.d.ts +28 -0
  12. package/dist/cjs/src/services/TransactionService.d.ts +128 -0
  13. package/dist/cjs/src/utils/functions/bigIntParser.d.ts +1 -0
  14. package/dist/cjs/{util/CalculatePrettyBalance.d.ts → src/utils/functions/calculatePrettyBalance.d.ts} +0 -0
  15. package/dist/cjs/src/utils/functions/debugOutput.d.ts +2 -0
  16. package/dist/cjs/src/utils/functions/endpointGenerator.d.ts +4 -0
  17. package/dist/cjs/src/utils/functions/execution.d.ts +11 -0
  18. package/dist/cjs/src/utils/functions/isValidApiKey.d.ts +1 -0
  19. package/dist/cjs/src/utils/functions/paginateEndpoint.d.ts +7 -0
  20. package/dist/cjs/src/utils/functions/prettifyCurrency.d.ts +2 -0
  21. package/dist/{esm/util/types/BalanceServiceTypes.d.ts → cjs/src/utils/types/BalanceService.types.d.ts} +91 -27
  22. package/dist/{es/util/types/BaseServiceTypes.d.ts → cjs/src/utils/types/BaseService.types.d.ts} +68 -18
  23. package/dist/cjs/src/utils/types/Generic.types.d.ts +477 -0
  24. package/dist/{esm/util/types/NftServiceTypes.d.ts → cjs/src/utils/types/NftService.types.d.ts} +53 -83
  25. package/dist/cjs/{util/types/PricingServiceTypes.d.ts → src/utils/types/PricingService.types.d.ts} +9 -3
  26. package/dist/{esm/util/types/SecurityServiceTypes.d.ts → cjs/src/utils/types/SecurityService.types.d.ts} +8 -7
  27. package/dist/{esm/util/types/TransactionServiceTypes.d.ts → cjs/src/utils/types/TransactionService.types.d.ts} +110 -24
  28. package/dist/es/index.d.ts +17 -20
  29. package/dist/es/index.js +2327 -7649
  30. package/dist/es/index.js.map +1 -1
  31. package/dist/es/src/GoldRushClient.d.ts +20 -0
  32. package/dist/es/src/services/BalanceService.d.ts +125 -0
  33. package/dist/es/src/services/BaseService.d.ts +161 -0
  34. package/dist/es/src/services/NftService.d.ts +157 -0
  35. package/dist/es/src/services/PricingService.d.ts +25 -0
  36. package/dist/es/src/services/SecurityService.d.ts +28 -0
  37. package/dist/es/src/services/TransactionService.d.ts +128 -0
  38. package/dist/es/src/utils/functions/bigIntParser.d.ts +1 -0
  39. package/dist/es/{util/CalculatePrettyBalance.d.ts → src/utils/functions/calculatePrettyBalance.d.ts} +0 -0
  40. package/dist/es/src/utils/functions/debugOutput.d.ts +2 -0
  41. package/dist/es/src/utils/functions/endpointGenerator.d.ts +4 -0
  42. package/dist/es/src/utils/functions/execution.d.ts +11 -0
  43. package/dist/es/src/utils/functions/isValidApiKey.d.ts +1 -0
  44. package/dist/es/src/utils/functions/paginateEndpoint.d.ts +7 -0
  45. package/dist/es/src/utils/functions/prettifyCurrency.d.ts +2 -0
  46. package/dist/{cjs/util/types/BalanceServiceTypes.d.ts → es/src/utils/types/BalanceService.types.d.ts} +91 -27
  47. package/dist/{esm/util/types/BaseServiceTypes.d.ts → es/src/utils/types/BaseService.types.d.ts} +68 -18
  48. package/dist/es/src/utils/types/Generic.types.d.ts +477 -0
  49. package/dist/{cjs/util/types/NftServiceTypes.d.ts → es/src/utils/types/NftService.types.d.ts} +53 -83
  50. package/dist/es/{util/types/PricingServiceTypes.d.ts → src/utils/types/PricingService.types.d.ts} +9 -3
  51. package/dist/{util/types/SecurityServiceTypes.d.ts → es/src/utils/types/SecurityService.types.d.ts} +8 -7
  52. package/dist/{cjs/util/types/TransactionServiceTypes.d.ts → es/src/utils/types/TransactionService.types.d.ts} +110 -24
  53. package/dist/esm/index.d.ts +17 -20
  54. package/dist/esm/index.js +2327 -7649
  55. package/dist/esm/index.js.map +1 -1
  56. package/dist/esm/src/GoldRushClient.d.ts +20 -0
  57. package/dist/esm/src/services/BalanceService.d.ts +125 -0
  58. package/dist/esm/src/services/BaseService.d.ts +161 -0
  59. package/dist/esm/src/services/NftService.d.ts +157 -0
  60. package/dist/esm/src/services/PricingService.d.ts +25 -0
  61. package/dist/esm/src/services/SecurityService.d.ts +28 -0
  62. package/dist/esm/src/services/TransactionService.d.ts +128 -0
  63. package/dist/esm/src/utils/functions/bigIntParser.d.ts +1 -0
  64. package/dist/esm/{util/CalculatePrettyBalance.d.ts → src/utils/functions/calculatePrettyBalance.d.ts} +0 -0
  65. package/dist/esm/src/utils/functions/debugOutput.d.ts +2 -0
  66. package/dist/esm/src/utils/functions/endpointGenerator.d.ts +4 -0
  67. package/dist/esm/src/utils/functions/execution.d.ts +11 -0
  68. package/dist/esm/src/utils/functions/isValidApiKey.d.ts +1 -0
  69. package/dist/esm/src/utils/functions/paginateEndpoint.d.ts +7 -0
  70. package/dist/esm/src/utils/functions/prettifyCurrency.d.ts +2 -0
  71. package/dist/{util/types/BalanceServiceTypes.d.ts → esm/src/utils/types/BalanceService.types.d.ts} +91 -27
  72. package/dist/{cjs/util/types/BaseServiceTypes.d.ts → esm/src/utils/types/BaseService.types.d.ts} +68 -18
  73. package/dist/esm/src/utils/types/Generic.types.d.ts +477 -0
  74. package/dist/{util/types/NftServiceTypes.d.ts → esm/src/utils/types/NftService.types.d.ts} +53 -83
  75. package/dist/esm/{util/types/PricingServiceTypes.d.ts → src/utils/types/PricingService.types.d.ts} +9 -3
  76. package/dist/{es/util/types/SecurityServiceTypes.d.ts → esm/src/utils/types/SecurityService.types.d.ts} +8 -7
  77. package/dist/{util/types/TransactionServiceTypes.d.ts → esm/src/utils/types/TransactionService.types.d.ts} +110 -24
  78. package/package.json +25 -12
  79. package/dist/cjs/services/BalanceService.d.ts +0 -638
  80. package/dist/cjs/services/BaseService.d.ts +0 -571
  81. package/dist/cjs/services/CovalentClient.d.ts +0 -57
  82. package/dist/cjs/services/NftService.d.ts +0 -686
  83. package/dist/cjs/services/PricingService.d.ts +0 -103
  84. package/dist/cjs/services/SecurityService.d.ts +0 -162
  85. package/dist/cjs/services/TransactionService.d.ts +0 -711
  86. package/dist/cjs/services/XykService.d.ts +0 -1018
  87. package/dist/cjs/util/ApiHelpers.d.ts +0 -6
  88. package/dist/cjs/util/ApiKeyValidator.d.ts +0 -8
  89. package/dist/cjs/util/Chains.d.ts +0 -223
  90. package/dist/cjs/util/backoff.d.ts +0 -12
  91. package/dist/cjs/util/prettifyCurrency.d.ts +0 -2
  92. package/dist/cjs/util/types/GenericTypes.d.ts +0 -116
  93. package/dist/cjs/util/types/SecurityServiceTypes.d.ts +0 -121
  94. package/dist/cjs/util/types/XykServiceTypes.d.ts +0 -687
  95. package/dist/es/services/BalanceService.d.ts +0 -638
  96. package/dist/es/services/BaseService.d.ts +0 -571
  97. package/dist/es/services/CovalentClient.d.ts +0 -57
  98. package/dist/es/services/NftService.d.ts +0 -686
  99. package/dist/es/services/PricingService.d.ts +0 -103
  100. package/dist/es/services/SecurityService.d.ts +0 -162
  101. package/dist/es/services/TransactionService.d.ts +0 -711
  102. package/dist/es/services/XykService.d.ts +0 -1018
  103. package/dist/es/util/ApiHelpers.d.ts +0 -6
  104. package/dist/es/util/ApiKeyValidator.d.ts +0 -8
  105. package/dist/es/util/Chains.d.ts +0 -223
  106. package/dist/es/util/backoff.d.ts +0 -12
  107. package/dist/es/util/prettifyCurrency.d.ts +0 -2
  108. package/dist/es/util/types/BalanceServiceTypes.d.ts +0 -378
  109. package/dist/es/util/types/GenericTypes.d.ts +0 -116
  110. package/dist/es/util/types/NftServiceTypes.d.ts +0 -303
  111. package/dist/es/util/types/TransactionServiceTypes.d.ts +0 -388
  112. package/dist/es/util/types/XykServiceTypes.d.ts +0 -687
  113. package/dist/esm/services/BalanceService.d.ts +0 -638
  114. package/dist/esm/services/BaseService.d.ts +0 -571
  115. package/dist/esm/services/CovalentClient.d.ts +0 -57
  116. package/dist/esm/services/NftService.d.ts +0 -686
  117. package/dist/esm/services/PricingService.d.ts +0 -103
  118. package/dist/esm/services/SecurityService.d.ts +0 -162
  119. package/dist/esm/services/TransactionService.d.ts +0 -711
  120. package/dist/esm/services/XykService.d.ts +0 -1018
  121. package/dist/esm/util/ApiHelpers.d.ts +0 -6
  122. package/dist/esm/util/ApiKeyValidator.d.ts +0 -8
  123. package/dist/esm/util/Chains.d.ts +0 -223
  124. package/dist/esm/util/backoff.d.ts +0 -12
  125. package/dist/esm/util/prettifyCurrency.d.ts +0 -2
  126. package/dist/esm/util/types/GenericTypes.d.ts +0 -116
  127. package/dist/esm/util/types/XykServiceTypes.d.ts +0 -687
  128. package/dist/index.d.ts +0 -20
  129. package/dist/index.js +0 -21
  130. package/dist/index.js.map +0 -1
  131. package/dist/services/BalanceService.d.ts +0 -638
  132. package/dist/services/BalanceService.js +0 -959
  133. package/dist/services/BalanceService.js.map +0 -1
  134. package/dist/services/BaseService.d.ts +0 -571
  135. package/dist/services/BaseService.js +0 -1202
  136. package/dist/services/BaseService.js.map +0 -1
  137. package/dist/services/CovalentClient.d.ts +0 -57
  138. package/dist/services/CovalentClient.js +0 -49
  139. package/dist/services/CovalentClient.js.map +0 -1
  140. package/dist/services/NftService.d.ts +0 -686
  141. package/dist/services/NftService.js +0 -1490
  142. package/dist/services/NftService.js.map +0 -1
  143. package/dist/services/PricingService.d.ts +0 -103
  144. package/dist/services/PricingService.js +0 -155
  145. package/dist/services/PricingService.js.map +0 -1
  146. package/dist/services/SecurityService.d.ts +0 -162
  147. package/dist/services/SecurityService.js +0 -249
  148. package/dist/services/SecurityService.js.map +0 -1
  149. package/dist/services/TransactionService.d.ts +0 -711
  150. package/dist/services/TransactionService.js +0 -1687
  151. package/dist/services/TransactionService.js.map +0 -1
  152. package/dist/services/XykService.d.ts +0 -1018
  153. package/dist/services/XykService.js +0 -1827
  154. package/dist/services/XykService.js.map +0 -1
  155. package/dist/util/ApiHelpers.d.ts +0 -6
  156. package/dist/util/ApiHelpers.js +0 -87
  157. package/dist/util/ApiHelpers.js.map +0 -1
  158. package/dist/util/ApiKeyValidator.d.ts +0 -8
  159. package/dist/util/ApiKeyValidator.js +0 -13
  160. package/dist/util/ApiKeyValidator.js.map +0 -1
  161. package/dist/util/CalculatePrettyBalance.d.ts +0 -1
  162. package/dist/util/CalculatePrettyBalance.js +0 -32
  163. package/dist/util/CalculatePrettyBalance.js.map +0 -1
  164. package/dist/util/Chains.d.ts +0 -223
  165. package/dist/util/Chains.js +0 -225
  166. package/dist/util/Chains.js.map +0 -1
  167. package/dist/util/backoff.d.ts +0 -12
  168. package/dist/util/backoff.js +0 -47
  169. package/dist/util/backoff.js.map +0 -1
  170. package/dist/util/prettifyCurrency.d.ts +0 -2
  171. package/dist/util/prettifyCurrency.js +0 -69
  172. package/dist/util/prettifyCurrency.js.map +0 -1
  173. package/dist/util/types/BalanceServiceTypes.js +0 -2
  174. package/dist/util/types/BalanceServiceTypes.js.map +0 -1
  175. package/dist/util/types/BaseServiceTypes.d.ts +0 -276
  176. package/dist/util/types/BaseServiceTypes.js +0 -2
  177. package/dist/util/types/BaseServiceTypes.js.map +0 -1
  178. package/dist/util/types/GenericTypes.d.ts +0 -116
  179. package/dist/util/types/GenericTypes.js +0 -2
  180. package/dist/util/types/GenericTypes.js.map +0 -1
  181. package/dist/util/types/NftServiceTypes.js +0 -2
  182. package/dist/util/types/NftServiceTypes.js.map +0 -1
  183. package/dist/util/types/PricingServiceTypes.d.ts +0 -33
  184. package/dist/util/types/PricingServiceTypes.js +0 -2
  185. package/dist/util/types/PricingServiceTypes.js.map +0 -1
  186. package/dist/util/types/SecurityServiceTypes.js +0 -2
  187. package/dist/util/types/SecurityServiceTypes.js.map +0 -1
  188. package/dist/util/types/TransactionServiceTypes.js +0 -2
  189. package/dist/util/types/TransactionServiceTypes.js.map +0 -1
  190. package/dist/util/types/XykServiceTypes.d.ts +0 -687
  191. package/dist/util/types/XykServiceTypes.js +0 -2
  192. package/dist/util/types/XykServiceTypes.js.map +0 -1
@@ -1,276 +0,0 @@
1
- import { DecodedItem, LogEvent, Pagination } from "./GenericTypes";
2
- export interface BlockResponse {
3
- /** * The timestamp when the response was generated. Useful to show data staleness to users. */
4
- updated_at: Date;
5
- /** * The requested chain ID eg: `1`. */
6
- chain_id: number;
7
- /** * The requested chain name eg: `eth-mainnet`. */
8
- chain_name: string;
9
- /** * List of response items. */
10
- items: Block[];
11
- }
12
- export interface Block {
13
- /** * The hash of the block. */
14
- block_hash: string;
15
- /** * The block signed timestamp in UTC. */
16
- signed_at: Date;
17
- /** * The block height. */
18
- height: number;
19
- /** * The parent block hash. */
20
- block_parent_hash: string;
21
- /** * Extra data written to the block. */
22
- extra_data: string;
23
- /** * The address of the miner. */
24
- miner_address: string;
25
- /** * The associated mining cost. */
26
- mining_cost: number;
27
- /** * The associated gas used. */
28
- gas_used: number;
29
- /** * The associated gas limit. */
30
- gas_limit: number;
31
- /** * The link to the related tx by block endpoint. */
32
- transactions_link: string;
33
- }
34
- export interface ResolvedAddress {
35
- /** * The timestamp when the response was generated. Useful to show data staleness to users. */
36
- updated_at: Date;
37
- /** * The requested chain ID eg: `1`. */
38
- chain_id: number;
39
- /** * The requested chain name eg: `eth-mainnet`. */
40
- chain_name: string;
41
- /** * List of response items. */
42
- items: ResolvedAddressItem[];
43
- }
44
- export interface ResolvedAddressItem {
45
- /** * The requested address. */
46
- address: string;
47
- name: string;
48
- }
49
- export interface BlockHeightsResponse {
50
- /** * The timestamp when the response was generated. Useful to show data staleness to users. */
51
- updated_at: Date;
52
- /** * The requested chain ID eg: `1`. */
53
- chain_id: number;
54
- /** * The requested chain name eg: `eth-mainnet`. */
55
- chain_name: string;
56
- /** * List of response items. */
57
- items: BlockHeights[];
58
- /** * Pagination metadata. */
59
- pagination: Pagination;
60
- }
61
- export interface BlockHeights {
62
- /** * The hash of the block. */
63
- block_hash: string;
64
- /** * The block signed timestamp in UTC. */
65
- signed_at: Date;
66
- /** * The block height. */
67
- height: number;
68
- /** * The parent block hash. */
69
- block_parent_hash: string;
70
- /** * Extra data written to the block. */
71
- extra_data: string;
72
- /** * The address of the miner. */
73
- miner_address: string;
74
- /** * The associated mining cost. */
75
- mining_cost: number;
76
- /** * The associated gas used. */
77
- gas_used: number;
78
- /** * The associated gas limit. */
79
- gas_limit: number;
80
- /** * The link to the related tx by block endpoint. */
81
- transactions_link: string;
82
- }
83
- export interface GetLogsResponse {
84
- /** * The timestamp when the response was generated. Useful to show data staleness to users. */
85
- updated_at: Date;
86
- /** * The requested chain ID eg: `1`. */
87
- chain_id: number;
88
- /** * The requested chain name eg: `eth-mainnet`. */
89
- chain_name: string;
90
- /** * List of response items. */
91
- items: GetLogsEvent[];
92
- }
93
- export interface GetLogsEvent {
94
- /** * The block signed timestamp in UTC. */
95
- block_signed_at: Date;
96
- /** * The height of the block. */
97
- block_height: number;
98
- /** * The hash of the block. */
99
- block_hash: string;
100
- /** * The offset is the position of the tx in the block. */
101
- tx_offset: number;
102
- /** * The offset is the position of the log entry within an event log. */
103
- log_offset: number;
104
- /** * The requested transaction hash. */
105
- tx_hash: string;
106
- /** * The log topics in raw data. */
107
- raw_log_topics: string[];
108
- /** * Use contract decimals to format the token balance for display purposes - divide the balance by `10^{contract_decimals}`. */
109
- sender_contract_decimals: number;
110
- /** * The name of the sender. */
111
- sender_name: string;
112
- /** * The ticker symbol for the sender. This field is set by a developer and non-unique across a network. */
113
- sender_contract_ticker_symbol: string;
114
- /** * The address of the sender. */
115
- sender_address: string;
116
- /** * The label of the sender address. */
117
- sender_address_label: string;
118
- /** * A list of supported standard ERC interfaces, eg: `ERC20` and `ERC721`. */
119
- supports_erc: string[];
120
- /** * The contract logo URL. */
121
- sender_logo_url: string;
122
- /** * The address of the deployed UniswapV2 like factory contract for this DEX. */
123
- sender_factory_address: string;
124
- /** * The log events in raw. */
125
- raw_log_data: string;
126
- /** * The decoded item. */
127
- decoded: DecodedItem;
128
- }
129
- export interface LogEventsByAddressResponse {
130
- /** * The timestamp when the response was generated. Useful to show data staleness to users. */
131
- updated_at: Date;
132
- /** * The requested chain ID eg: `1`. */
133
- chain_id: number;
134
- /** * The requested chain name eg: `eth-mainnet`. */
135
- chain_name: string;
136
- /** * List of response items. */
137
- items: LogEvent[];
138
- /** * Pagination metadata. */
139
- pagination: Pagination;
140
- }
141
- export interface LogEventsByTopicHashResponse {
142
- /** * The timestamp when the response was generated. Useful to show data staleness to users. */
143
- updated_at: Date;
144
- /** * The requested chain ID eg: `1`. */
145
- chain_id: number;
146
- /** * The requested chain name eg: `eth-mainnet`. */
147
- chain_name: string;
148
- /** * List of response items. */
149
- items: LogEvent[];
150
- /** * Pagination metadata. */
151
- pagination: Pagination;
152
- }
153
- export interface AllChainsResponse {
154
- /** * The timestamp when the response was generated. Useful to show data staleness to users. */
155
- updated_at: Date;
156
- /** * List of response items. */
157
- items: ChainItem[];
158
- }
159
- export interface ChainItem {
160
- /** * The chain name eg: `eth-mainnet`. */
161
- name: string;
162
- /** * The requested chain ID eg: `1`. */
163
- chain_id: string;
164
- /** * True if the chain is a testnet. */
165
- is_testnet: boolean;
166
- /** * Schema name to use for direct SQL. */
167
- db_schema_name: string;
168
- /** * The chains label eg: `Ethereum Mainnet`. */
169
- label: string;
170
- /** * The category label eg: `Ethereum`. */
171
- category_label: string;
172
- /** * A svg logo url for the chain. */
173
- logo_url: string;
174
- /** * A black png logo url for the chain. */
175
- black_logo_url: string;
176
- /** * A white png logo url for the chain. */
177
- white_logo_url: string;
178
- /** * The color theme for the chain. */
179
- color_theme: ColorTheme;
180
- /** * True if the chain is an AppChain. */
181
- is_appchain: boolean;
182
- /** * The ChainItem the appchain is a part of. */
183
- appchain_of: ChainItem;
184
- }
185
- export interface ColorTheme {
186
- /** * The red color code. */
187
- red: number;
188
- /** * The green color code. */
189
- green: number;
190
- /** * The blue color code. */
191
- blue: number;
192
- /** * The alpha color code. */
193
- alpha: number;
194
- /** * The hexadecimal color code. */
195
- hex: string;
196
- /** * The color represented in css rgb() functional notation. */
197
- css_rgb: string;
198
- }
199
- export interface AllChainsStatusResponse {
200
- /** * The timestamp when the response was generated. Useful to show data staleness to users. */
201
- updated_at: Date;
202
- /** * List of response items. */
203
- items: ChainStatusItem[];
204
- }
205
- export interface ChainStatusItem {
206
- /** * The chain name eg: `eth-mainnet`. */
207
- name: string;
208
- /** * The requested chain ID eg: `1`. */
209
- chain_id: string;
210
- /** * True if the chain is a testnet. */
211
- is_testnet: boolean;
212
- /** * A svg logo url for the chain. */
213
- logo_url: string;
214
- /** * A black png logo url for the chain. */
215
- black_logo_url: string;
216
- /** * A white png logo url for the chain. */
217
- white_logo_url: string;
218
- /** * True if the chain is an AppChain. */
219
- is_appchain: boolean;
220
- /** * The height of the lastest block available. */
221
- synced_block_height: number;
222
- /** * The signed timestamp of lastest block available. */
223
- synced_blocked_signed_at: Date;
224
- /** * True if the chain has data and ready for querying. */
225
- has_data: boolean;
226
- }
227
- export interface ChainActivityResponse {
228
- /** * The timestamp when the response was generated. Useful to show data staleness to users. */
229
- updated_at: Date;
230
- /** * The requested address. */
231
- address: string;
232
- /** * List of response items. */
233
- items: ChainActivityEvent[];
234
- }
235
- export interface ChainActivityEvent extends ChainItem {
236
- /** * The timestamp when the address was last seen on the chain. */
237
- last_seen_at: Date;
238
- }
239
- export interface GasPricesResponse {
240
- /** * The requested chain ID eg: `1`. */
241
- chain_id: number;
242
- /** * The requested chain name eg: `eth-mainnet`. */
243
- chain_name: string;
244
- /** * The requested quote currency eg: `USD`. */
245
- quote_currency: string;
246
- /** * The timestamp when the response was generated. Useful to show data staleness to users. */
247
- updated_at: Date;
248
- /** * The requested event type. */
249
- event_type: string;
250
- /** * The exchange rate for the requested quote currency. */
251
- gas_quote_rate: number;
252
- /** * The lowest gas fee for the latest block height. */
253
- base_fee: bigint | null;
254
- /** * List of response items. */
255
- items: PriceItem[];
256
- }
257
- export interface PriceItem {
258
- /** * The average gas price, in WEI, for the time interval. */
259
- gas_price: string;
260
- /** * The average gas spent for the time interval. */
261
- gas_spent: string;
262
- /** * The average gas spent in `quote-currency` denomination for the time interval. */
263
- gas_quote: number;
264
- /** * Other fees, when applicable. For example: OP chain L1 fees. */
265
- other_fees: OtherFees;
266
- /** * The sum of the L1 and L2 gas spent, in quote-currency, for the specified time interval. */
267
- total_gas_quote: number;
268
- /** * A prettier version of the total average gas spent, in quote-currency, for the specified time interval, for rendering purposes. */
269
- pretty_total_gas_quote: string;
270
- /** * The specified time interval. */
271
- interval: string;
272
- }
273
- export interface OtherFees {
274
- /** * The calculated L1 gas spent, when applicable, in quote-currency, for the specified time interval. */
275
- l1_gas_quote: number;
276
- }
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=BaseServiceTypes.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"BaseServiceTypes.js","sourceRoot":"","sources":["../../../src/util/types/BaseServiceTypes.ts"],"names":[],"mappings":""}
@@ -1,116 +0,0 @@
1
- export interface Pagination {
2
- /** * True is there is another page. */
3
- has_more: boolean;
4
- /** * The requested page number. */
5
- page_number: number;
6
- /** * The requested number of items on the current page. */
7
- page_size: number;
8
- /** * The total number of items across all pages for this request. */
9
- total_count: number;
10
- }
11
- export interface NftCollectionAttribute {
12
- trait_type: string;
13
- value: string;
14
- }
15
- export interface NftData {
16
- /** * The token's id. */
17
- token_id: bigint | null;
18
- token_url: string;
19
- /** * The original minter. */
20
- original_owner: string;
21
- /** * The current holder of this NFT. */
22
- current_owner: string;
23
- external_data: NftExternalData;
24
- /** * If `true`, the asset data is available from the Covalent CDN. */
25
- asset_cached: boolean;
26
- /** * If `true`, the image data is available from the Covalent CDN. */
27
- image_cached: boolean;
28
- }
29
- export interface NftExternalData {
30
- name: string;
31
- description: string;
32
- asset_url: string;
33
- asset_file_extension: string;
34
- asset_mime_type: string;
35
- asset_size_bytes: string;
36
- image: string;
37
- image_256: string;
38
- image_512: string;
39
- image_1024: string;
40
- animation_url: string;
41
- external_url: string;
42
- attributes: NftCollectionAttribute[];
43
- }
44
- export interface DecodedItem {
45
- name: string;
46
- signature: string;
47
- params: Param[];
48
- }
49
- export interface Param {
50
- name: string;
51
- type: string;
52
- indexed: boolean;
53
- decoded: boolean;
54
- value: string;
55
- }
56
- export interface LogEvent {
57
- /** * The block signed timestamp in UTC. */
58
- block_signed_at: Date;
59
- /** * The height of the block. */
60
- block_height: number;
61
- /** * The offset is the position of the tx in the block. */
62
- tx_offset: number;
63
- /** * The offset is the position of the log entry within an event log. */
64
- log_offset: number;
65
- /** * The requested transaction hash. */
66
- tx_hash: string;
67
- /** * The log topics in raw data. */
68
- raw_log_topics: string[];
69
- /** * Use contract decimals to format the token balance for display purposes - divide the balance by `10^{contract_decimals}`. */
70
- sender_contract_decimals: number;
71
- /** * The name of the sender. */
72
- sender_name: string;
73
- sender_contract_ticker_symbol: string;
74
- /** * The address of the sender. */
75
- sender_address: string;
76
- /** * The label of the sender address. */
77
- sender_address_label: string;
78
- /** * The contract logo URL. */
79
- sender_logo_url: string;
80
- /** * A list of supported standard ERC interfaces, eg: `ERC20` and `ERC721`. */
81
- supports_erc: string[];
82
- /** * The address of the deployed UniswapV2 like factory contract for this DEX. */
83
- sender_factory_address: string;
84
- /** * The log events in raw. */
85
- raw_log_data: string;
86
- /** * The decoded item. */
87
- decoded: DecodedItem;
88
- }
89
- export interface ContractMetadata {
90
- /** * Use contract decimals to format the token balance for display purposes - divide the balance by `10^{contract_decimals}`. */
91
- contract_decimals: number;
92
- /** * The string returned by the `name()` method. */
93
- contract_name: string;
94
- /** * The ticker symbol for this contract. This field is set by a developer and non-unique across a network. */
95
- contract_ticker_symbol: string;
96
- /** * Use the relevant `contract_address` to lookup prices, logos, token transfers, etc. */
97
- contract_address: string;
98
- /** * A list of supported standard ERC interfaces, eg: `ERC20` and `ERC721`. */
99
- supports_erc: string[];
100
- /** * The contract logo URL. */
101
- logo_url: string;
102
- }
103
- export interface Explorer {
104
- /** * The name of the explorer. */
105
- label: string;
106
- /** * The URL of the explorer. */
107
- url: string;
108
- }
109
- export interface LogoUrls {
110
- /** * The token logo URL. */
111
- token_logo_url: string;
112
- /** * The protocol logo URL. */
113
- protocol_logo_url: string;
114
- /** * The chain logo URL. */
115
- chain_logo_url: string;
116
- }
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=GenericTypes.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"GenericTypes.js","sourceRoot":"","sources":["../../../src/util/types/GenericTypes.ts"],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=NftServiceTypes.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"NftServiceTypes.js","sourceRoot":"","sources":["../../../src/util/types/NftServiceTypes.ts"],"names":[],"mappings":""}
@@ -1,33 +0,0 @@
1
- import { ContractMetadata, LogoUrls } from "./GenericTypes";
2
- export interface TokenPricesResponse {
3
- /** * Use contract decimals to format the token balance for display purposes - divide the balance by `10^{contract_decimals}`. */
4
- contract_decimals: number;
5
- /** * The string returned by the `name()` method. */
6
- contract_name: string;
7
- /** * The ticker symbol for this contract. This field is set by a developer and non-unique across a network. */
8
- contract_ticker_symbol: string;
9
- /** * Use the relevant `contract_address` to lookup prices, logos, token transfers, etc. */
10
- contract_address: string;
11
- /** * A list of supported standard ERC interfaces, eg: `ERC20` and `ERC721`. */
12
- supports_erc: string[];
13
- /** * The contract logo URL. */
14
- logo_url: string;
15
- update_at: Date;
16
- /** * The requested quote currency eg: `USD`. */
17
- quote_currency: string;
18
- /** * The contract logo URLs. */
19
- logo_urls: LogoUrls;
20
- /** * List of response items. */
21
- prices: Price[];
22
- /** * List of response items. */
23
- items: Price[];
24
- }
25
- export interface Price {
26
- contract_metadata: ContractMetadata;
27
- /** * The date of the price capture. */
28
- date: Date;
29
- /** * The price in the requested `quote-currency`. */
30
- price: number;
31
- /** * A prettier version of the price for rendering purposes. */
32
- pretty_price: string;
33
- }
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=PricingServiceTypes.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PricingServiceTypes.js","sourceRoot":"","sources":["../../../src/util/types/PricingServiceTypes.ts"],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=SecurityServiceTypes.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"SecurityServiceTypes.js","sourceRoot":"","sources":["../../../src/util/types/SecurityServiceTypes.ts"],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=TransactionServiceTypes.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"TransactionServiceTypes.js","sourceRoot":"","sources":["../../../src/util/types/TransactionServiceTypes.ts"],"names":[],"mappings":""}