ethereum-hooks 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 (102) hide show
  1. package/README.md +81 -117
  2. package/{client/src/crypto_hooks/ens/useFetchAddressENSLookup.ts → crypto_hooks/ens/useAddressENSLookup.ts} +2 -2
  3. package/{client/src/crypto_hooks/ens/useFetchENSAddressLookup.ts → crypto_hooks/ens/useENSAddressLookup.ts} +3 -4
  4. package/{client/src/crypto_hooks/ens/useFetchENSIDLookup.ts → crypto_hooks/ens/useENSIDLookup.ts} +2 -2
  5. package/{client/src/crypto_hooks/ens/useFetchENSNameLookup.ts → crypto_hooks/ens/useENSNameLookup.ts} +2 -2
  6. package/{client/src/crypto_hooks/erc20Tokens/useFetchERC20CollectionOwners.ts → crypto_hooks/erc20Tokens/useERC20CollectionOwners.ts} +3 -3
  7. package/{client/src/crypto_hooks/erc20Tokens/useFetchERC20CollectionTopCoins.ts → crypto_hooks/erc20Tokens/useERC20CollectionTopCoins.ts} +2 -2
  8. package/{client/src/crypto_hooks/erc20Tokens/useFetchERC20CollectionTransfers.ts → crypto_hooks/erc20Tokens/useERC20CollectionTransfers.ts} +3 -3
  9. package/{client/src/crypto_hooks/erc20Tokens/useFetchERC20Holdings.ts → crypto_hooks/erc20Tokens/useERC20Holdings.ts} +2 -2
  10. package/{client/src/crypto_hooks/erc20Tokens/useFetchERC20Transfers.ts → crypto_hooks/erc20Tokens/useERC20Transfers.ts} +2 -2
  11. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721CollectionAttributes.ts → crypto_hooks/erc721Tokens/useERC721CollectionAttributes.ts} +2 -2
  12. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721CollectionData.ts → crypto_hooks/erc721Tokens/useERC721CollectionData.ts} +2 -2
  13. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721CollectionExtraData.ts → crypto_hooks/erc721Tokens/useERC721CollectionExtraData.ts} +2 -2
  14. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721CollectionFloorPrice.ts → crypto_hooks/erc721Tokens/useERC721CollectionFloorPrice.ts} +2 -2
  15. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721CollectionMarketCap.ts → crypto_hooks/erc721Tokens/useERC721CollectionMarketCap.ts} +2 -2
  16. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721CollectionSales.ts → crypto_hooks/erc721Tokens/useERC721CollectionSales.ts} +2 -2
  17. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721CollectionTransfers.ts → crypto_hooks/erc721Tokens/useERC721CollectionTransfers.ts} +2 -2
  18. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721CollectionTrends.ts → crypto_hooks/erc721Tokens/useERC721CollectionTrends.ts} +2 -2
  19. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721CollectionVolume.ts → crypto_hooks/erc721Tokens/useERC721CollectionVolume.ts} +2 -2
  20. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721Holdings.ts → crypto_hooks/erc721Tokens/useERC721Holdings.ts} +2 -2
  21. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721LookupData.ts → crypto_hooks/erc721Tokens/useERC721LookupData.ts} +2 -2
  22. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721OpenseaData.ts → crypto_hooks/erc721Tokens/useERC721OpenseaData.ts} +2 -2
  23. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721RarityData.ts → crypto_hooks/erc721Tokens/useERC721RarityData.ts} +2 -2
  24. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721SalesData.ts → crypto_hooks/erc721Tokens/useERC721SalesData.ts} +2 -2
  25. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721TransferLookupData.ts → crypto_hooks/erc721Tokens/useERC721TransferLookupData.ts} +2 -2
  26. package/{client/src/crypto_hooks/erc721Tokens/useFetchERC721TransfersData.ts → crypto_hooks/erc721Tokens/useERC721TransfersData.ts} +2 -2
  27. package/{client/src/crypto_hooks/gas/useFetchGasLookup.ts → crypto_hooks/gas/useGasLookup.ts} +2 -2
  28. package/crypto_hooks/index.ts +39 -0
  29. package/{client/src/crypto_hooks/prices/useFetchERC20Price.ts → crypto_hooks/prices/useERC20Price.ts} +2 -2
  30. package/{client/src/crypto_hooks/prices/useFetchERC721Price.ts → crypto_hooks/prices/useERC721Price.ts} +2 -2
  31. package/{client/src/crypto_hooks/prices/useFetchETHPrice.ts → crypto_hooks/prices/useETHPrice.ts} +2 -2
  32. package/{client/src/crypto_hooks/prices/useFetchLayerTwoPrice.ts → crypto_hooks/prices/useLayerTwoPrice.ts} +2 -2
  33. package/package.json +19 -21
  34. package/client/package.json +0 -25
  35. package/hook-server-design.png +0 -0
  36. package/hooksinformation.txt +0 -49
  37. package/server/Controller/ENS/AddressToENSController.ts +0 -30
  38. package/server/Controller/ENS/ENSIDController.ts +0 -32
  39. package/server/Controller/ENS/ENSNameController.ts +0 -32
  40. package/server/Controller/ENS/ENSToAddressController.ts +0 -32
  41. package/server/Controller/ERC20Tokens/ERC20CollectionOwnersController.ts +0 -29
  42. package/server/Controller/ERC20Tokens/ERC20CollectionTopCoinsController.ts +0 -27
  43. package/server/Controller/ERC20Tokens/ERC20CollectionTransfersController.ts +0 -29
  44. package/server/Controller/ERC20Tokens/ERC20HoldingsController.ts +0 -29
  45. package/server/Controller/ERC20Tokens/ERC20TransfersController.ts +0 -29
  46. package/server/Controller/ERC721Tokens/ERC721CollectionAttributesController.ts +0 -29
  47. package/server/Controller/ERC721Tokens/ERC721CollectionDataController.ts +0 -29
  48. package/server/Controller/ERC721Tokens/ERC721CollectionExtraDataController.ts +0 -29
  49. package/server/Controller/ERC721Tokens/ERC721CollectionFloorPriceController.ts +0 -18
  50. package/server/Controller/ERC721Tokens/ERC721CollectionMarketCapController.ts +0 -29
  51. package/server/Controller/ERC721Tokens/ERC721CollectionSalesController.ts +0 -29
  52. package/server/Controller/ERC721Tokens/ERC721CollectionTransfersController.ts +0 -29
  53. package/server/Controller/ERC721Tokens/ERC721CollectionTrendsController.ts +0 -28
  54. package/server/Controller/ERC721Tokens/ERC721CollectionVolumeController.ts +0 -28
  55. package/server/Controller/ERC721Tokens/ERC721HoldingsController.ts +0 -29
  56. package/server/Controller/ERC721Tokens/ERC721LookupDataController.ts +0 -28
  57. package/server/Controller/ERC721Tokens/ERC721OpenseaDataController.ts +0 -29
  58. package/server/Controller/ERC721Tokens/ERC721RarityDataController.ts +0 -29
  59. package/server/Controller/ERC721Tokens/ERC721SalesDataController.ts +0 -34
  60. package/server/Controller/ERC721Tokens/ERC721TransferLookupDataController.ts +0 -28
  61. package/server/Controller/ERC721Tokens/ERC721TransfersDataController.ts +0 -29
  62. package/server/Controller/Gas/GasLookupController.ts +0 -26
  63. package/server/Controller/Prices/ERC20PriceController.ts +0 -43
  64. package/server/Controller/Prices/ERC721PriceController.ts +0 -28
  65. package/server/Controller/Prices/ETHPriceController.ts +0 -42
  66. package/server/Controller/Prices/LayerTwoPriceController.ts +0 -41
  67. package/server/Routes/ENSRoutes/AddressToENSRoute.ts +0 -9
  68. package/server/Routes/ENSRoutes/ENSIDRoute.ts +0 -8
  69. package/server/Routes/ENSRoutes/ENSNameRoute.ts +0 -9
  70. package/server/Routes/ENSRoutes/ENSToAddressRoute.ts +0 -9
  71. package/server/Routes/ERC20TokensRoutes/ERC20CollectionOwnersRoute.ts +0 -9
  72. package/server/Routes/ERC20TokensRoutes/ERC20CollectionTopCoinsRoute.ts +0 -9
  73. package/server/Routes/ERC20TokensRoutes/ERC20CollectionTransfersRoute.ts +0 -9
  74. package/server/Routes/ERC20TokensRoutes/ERC20HoldingsRoute.ts +0 -9
  75. package/server/Routes/ERC20TokensRoutes/ERC20TransfersRoute.ts +0 -9
  76. package/server/Routes/ERC721TokensRoutes/ERC721CollectionAttributesRoute.ts +0 -9
  77. package/server/Routes/ERC721TokensRoutes/ERC721CollectionDataRoute.ts +0 -9
  78. package/server/Routes/ERC721TokensRoutes/ERC721CollectionExtraDataRoute.ts +0 -9
  79. package/server/Routes/ERC721TokensRoutes/ERC721CollectionFloorPriceRoute.ts +0 -9
  80. package/server/Routes/ERC721TokensRoutes/ERC721CollectionMarketCapRoute.ts +0 -9
  81. package/server/Routes/ERC721TokensRoutes/ERC721CollectionSalesRoute.ts +0 -9
  82. package/server/Routes/ERC721TokensRoutes/ERC721CollectionTransfersRoute.ts +0 -9
  83. package/server/Routes/ERC721TokensRoutes/ERC721CollectionTrendsRoute.ts +0 -9
  84. package/server/Routes/ERC721TokensRoutes/ERC721CollectionVolumeRoute.ts +0 -9
  85. package/server/Routes/ERC721TokensRoutes/ERC721HoldingsRoute.ts +0 -9
  86. package/server/Routes/ERC721TokensRoutes/ERC721LookupDataRoute.ts +0 -9
  87. package/server/Routes/ERC721TokensRoutes/ERC721OpenseaDataRoute.ts +0 -9
  88. package/server/Routes/ERC721TokensRoutes/ERC721RarityDataRoute.ts +0 -9
  89. package/server/Routes/ERC721TokensRoutes/ERC721SalesDataRoute.ts +0 -9
  90. package/server/Routes/ERC721TokensRoutes/ERC721TransferLookupDataRoute.ts +0 -9
  91. package/server/Routes/ERC721TokensRoutes/ERC721TransfersDataRoute.ts +0 -9
  92. package/server/Routes/GasRoutes/GasLookupRoute.ts +0 -9
  93. package/server/Routes/PriceRoutes/ERC20PriceRoute.ts +0 -9
  94. package/server/Routes/PriceRoutes/ERC721PriceRoute.ts +0 -9
  95. package/server/Routes/PriceRoutes/ETHPriceRoute.ts +0 -9
  96. package/server/Routes/PriceRoutes/LayerTwoPriceRoute.ts +0 -9
  97. package/server/package.json +0 -25
  98. package/server/server.ts +0 -96
  99. package/server/tsconfig.json +0 -109
  100. /package/{client/src/custom_hooks → custom_hooks}/useFetch.ts +0 -0
  101. /package/{client/src/types → types}/FetchStateType.ts +0 -0
  102. /package/{client/src/types → types}/LayerTwoType.ts +0 -0
package/README.md CHANGED
@@ -14,75 +14,37 @@ The following resources were utilized when building these client hooks:
14
14
 
15
15
  <br />
16
16
 
17
- ## React Hooks Client-Server Setup
18
- When working with this package, you will need to implement the typical MERN design pattern, set up <code>.env</code> variables, and set up the server to allow the client hooks to establish communication to the back-end.
17
+ ## React Hooks
18
+ This package uses AWS Lambda functions to construct authenticated API calls. The architecture follows a simple flow: **Client Hook useFetch AWS Lambda Response**.
19
19
 
20
- <b>You will need to set the following environment variables in your <code>.env</code> file: </b>
20
+ The AWS Lambda functions handle authentication automatically using pre-configured API keys for various blockchain services:
21
+ - **OPENSEA_API_KEY** - For NFT marketplace data
22
+ - **MORALIS_API_KEY** - For Web3 data aggregation
23
+ - **BLK_API_KEY** - For Blocknative gas and mempool data
24
+ - **TRANSPOSE_API_KEY** - For indexed blockchain data
25
+ - **ALCHEMY_API_KEY** - For Ethereum node access and enhanced APIs
21
26
 
22
- - <code>ALCHEMY_API_KEY</code>
23
- - <code>BLK_API_KEY</code>
24
- - <code>CLIENT_URL</code>
25
- - <code>COINGECKO_API_KEY</code>
26
- - <code>MORALIS_API_KEY</code>
27
- - <code>OPENSEA_API_KEY</code>
28
- - <code>PORT</code>
29
- - <code>TRANSPOSE_API_KEY</code>
30
-
31
- The following diagram will help you understand the workflow:
32
-
33
- <img src="https://genericbucket95.s3.us-east-2.amazonaws.com/hook-server-design.png" alt="Hook Server" width="600" height="400" />
34
-
35
-
36
- <br />
37
-
38
- ## Server Setup
39
-
40
- For this part, you will need to incorporate the server object exported from the <code>server.ts</code> file inside the server directory.
41
-
42
- <b>You will need to build on top of this built-in server, any additional routes and configurations as this server contains all the routes needed to effectively use the client hooks. </b>
43
-
44
- This is how you can incorporate the built-in server for additional add-ons and configuration in a custom server file of your own:
45
-
46
- <code>customServer.ts</code>
47
-
48
- ```javascript
49
- import { server } from 'server'; // Import the built-in server
50
-
51
- // Environment variables, PORT, and CLIENT_URL will be used by this built-in server
52
- // PORT specifies the port to activate the Node server
53
- // CLIENT_URL specifies the URL that is CORS enabled
54
-
55
- // Add any additional routes you may have on top of this server, etc.
56
- server.use("", "/xxx-xxxx");
57
- ...
58
- ...
59
- ...
60
-
61
-
62
- ```
63
-
64
- <br />
27
+ No backend setup or environment variables are required on your end.
65
28
 
66
29
  ## React Client Hooks
67
30
 
68
31
  The hooks cover several areas of the Ethereum blockchain and can be used for Layer Two chains as well.
69
32
 
70
- You will need to specify the <b>BACKEND URL + ENDPOINT</b> as the <b>Server URL</b> in one of the parameter values to be passed in each of the client hooks you will be using.
71
-
72
- For local development, you will need to specify the <b>full localhost address (http://localhost:PORT/ENDPOINT)</b>.
33
+ Each hook automatically connects to its dedicated AWS Lambda endpoint - no manual URL configuration is needed.
73
34
 
74
35
  Here is a quick example of how you can work with client hooks. The following is a code snippet for working with React.js:
75
36
 
76
37
  <code>ENSToAddressPage.tsx</code>
77
38
  ```javascript
78
39
  import React, { FC } from 'react';
79
- import { useFetchENSAddressLookup } from '../crypto_hooks/ens/useFetchENSAddressLookup'; // Import hook
40
+ import { useENSAddressLookup } from 'ethereum-hooks';
41
+
42
+ // Incorporating the ENS to Address Client Hook.. using Vitalik Buterin's address
43
+ // No server setup required - connects directly to AWS Lambda
80
44
 
81
- // Incorporating the ENS to Address Client Hook.. using Vitalik Buterin's address ;)
82
- // Server URL + Endpoint
83
- // Example uses local development
84
45
  const ENSToAddressPage: FC = () => {
85
- const addressInformation = useFetchENSAddressLookup('vitalik.eth', 'http://localhost:5000/additional-address-to-ens-information');
46
+ // Hook automatically connects to AWS Lambda - no server setup required
47
+ const addressInformation = useENSAddressLookup('vitalik.eth');
86
48
 
87
49
  // Each client hook uses the useFetch custom hook
88
50
  // It returns three states: data, error, loading
@@ -119,193 +81,195 @@ export default ENSToAddressPage;
119
81
 
120
82
  A list of chains supported is provided below in the <code>Types</code> section.
121
83
 
122
- The following table highlights the <b>30 different client hooks</b> and their <b>endpoints</b>:
84
+ ## AWS Lambda Endpoints
85
+
86
+ The following table shows the **30 different client hooks** and their corresponding **AWS Lambda endpoints**:
123
87
 
124
88
  <table>
125
89
  <tr>
126
90
  <th>Category</th>
127
91
  <th>Client Hook Name</th>
128
- <th>Endpoint</th>
92
+ <th>AWS Lambda Endpoint</th>
129
93
  <th>Description</th>
130
- <tr>
94
+ </tr>
131
95
  <tr>
132
96
  <td>ENS</td>
133
- <td><code>useFetchAddressENSLookup(address: string, serverURL: string)</code></td>
134
- <td><code>/address-to-ens-information</code></td>
97
+ <td><code>useAddressENSLookup(address: string)</code></td>
98
+ <td><code>https://37zq2u4ntbygkw7inki3djjm440xctyd.lambda-url.us-east-1.on.aws/</code></td>
135
99
  <td>Fetch the equivalent ENS name from a given address</td>
136
100
  </tr>
137
101
  <tr>
138
102
  <td>ENS</td>
139
- <td><code>useFetchENSAddressLookup(ensName: string, serverURL: string)</code></td>
140
- <td><code>/additional-address-to-ens-information</code></td>
103
+ <td><code>useENSAddressLookup(ensName: string)</code></td>
104
+ <td><code>https://jy3upsy3rgbengcktqlqfcwyhy0wcamb.lambda-url.us-east-1.on.aws/</code></td>
141
105
  <td>Fetch the equivalent ETH address from a given ENS name</td>
142
106
  </tr>
143
107
  <tr>
144
108
  <td>ENS</td>
145
- <td><code>useFetchENSIDLookup(id: string, serverURL: string)</code></td>
146
- <td><code>/ens-transfers-by-id</code></td>
109
+ <td><code>useENSIDLookup(id: string)</code></td>
110
+ <td><code>https://ev6i3gsesgdvj7ouxiwpg4qafu0nfvdw.lambda-url.us-east-1.on.aws/</code></td>
147
111
  <td>Fetch information of a given ENS ID</td>
148
112
  </tr>
149
113
  <tr>
150
114
  <td>ENS</td>
151
- <td><code>useFetchENSNameLookup(ensName: string, serverURL: string)</code></td>
152
- <td><code>/ens-transfers-by-name</code></td>
115
+ <td><code>useENSNameLookup(ensName: string)</code></td>
116
+ <td><code>https://f53actwgpl2a3rk6uynoryuoxq0eifuo.lambda-url.us-east-1.on.aws/</code></td>
153
117
  <td>Fetch information of a given ENS name</td>
154
118
  </tr>
155
119
  <tr>
156
120
  <td>ERC20</td>
157
- <td><code>useFetchERC20CollectionOwners(contractAddress: string, serverURL: string)</code></td>
158
- <td><code>/erc20-collection-owners</code></td>
121
+ <td><code>useERC20CollectionOwners(contractAddress: string)</code></td>
122
+ <td><code>https://hyrbuxy6aivjqjrgtogd3nx5we0gcxjr.lambda-url.us-east-1.on.aws/</code></td>
159
123
  <td>Fetch list of owners of a particular ERC20 collection</td>
160
124
  </tr>
161
125
  <tr>
162
126
  <td>ERC20</td>
163
- <td><code>useFetchERC20CollectionTopCoins(serverURL: string)</code></td>
164
- <td><code>/erc20-top-coins</code></td>
127
+ <td><code>useERC20CollectionTopCoins()</code></td>
128
+ <td><code>https://2ebpropr2dgzqicposkbrvr5nq0ofyyx.lambda-url.us-east-1.on.aws/</code></td>
165
129
  <td>Fetch list of the top ERC20 collections</td>
166
130
  </tr>
167
131
  <tr>
168
132
  <td>ERC20</td>
169
- <td><code>useFetchERC20CollectionTransfers(contractAddress: string, serverURL: string)</code></td>
170
- <td><code>/erc20-collection-transfers</code></td>
133
+ <td><code>useERC20CollectionTransfers(contractAddress: string)</code></td>
134
+ <td><code>https://bwqre7ze2vm3sum5avrvwzwbrm0gyxcy.lambda-url.us-east-1.on.aws/</code></td>
171
135
  <td>Fetch transfer activity of a particular ERC20 collection</td>
172
136
  </tr>
173
137
  <tr>
174
138
  <td>ERC20</td>
175
- <td><code>useFetchERC20Holdings(contractAddress: string, serverURL: string)</code></td>
176
- <td><code>/erc20-collection-holdings</code></td>
139
+ <td><code>useERC20Holdings(contractAddress: string)</code></td>
140
+ <td><code>https://2i2neqclwlgygwimhbzlhdtjwa0dupee.lambda-url.us-east-1.on.aws/</code></td>
177
141
  <td>Track wallet holdings of a particular ERC20 token activity</td>
178
142
  </tr>
179
143
  <tr>
180
144
  <td>ERC20</td>
181
- <td><code>useFetchERC20Transfers(contractAddress: string, serverURL: string)</code></td>
182
- <td><code>/erc20-collection-transfers</code></td>
145
+ <td><code>useERC20Transfers(contractAddress: string)</code></td>
146
+ <td><code>https://msee4ccresifmjhm3mdedry3ki0xvdgx.lambda-url.us-east-1.on.aws/</code></td>
183
147
  <td>Track the transfer activity of a particular ERC20 token in a wallet</td>
184
148
  </tr>
185
149
  <tr>
186
150
  <td>ERC721</td>
187
- <td><code>useFetchERC721CollectionAttributes(contractAddress: string, serverURL: string)</code></td>
188
- <td><code>/erc721-collection-attributes</code></td>
151
+ <td><code>useERC721CollectionAttributes(contractAddress: string)</code></td>
152
+ <td><code>https://7rs4acgso6ld44zjpl25jras3q0szvag.lambda-url.us-east-1.on.aws/</code></td>
189
153
  <td>Fetch attributes of a particular ERC721 collection</td>
190
154
  </tr>
191
155
  <tr>
192
156
  <td>ERC721</td>
193
- <td><code>useFetchERC721CollectionData(contractAddress: string, serverURL: string)</code></td>
194
- <td><code>/erc721-collection-data</code></td>
157
+ <td><code>useERC721CollectionData(contractAddress: string)</code></td>
158
+ <td><code>https://u2pdhfz4qbfkkyp6z4yg4n57hq0hzica.lambda-url.us-east-1.on.aws/</code></td>
195
159
  <td>Fetch data of a particular ERC721 collection</td>
196
160
  </tr>
197
161
  <tr>
198
162
  <td>ERC721</td>
199
- <td><code>useFetchERC721CollectionExtraData(contractAddress: string, serverURL: string)</code></td>
200
- <td><code>/erc721-collection-extra-data</code></td>
163
+ <td><code>useERC721CollectionExtraData(contractAddress: string)</code></td>
164
+ <td><code>https://b5mkshxv54bbj4d54rxze5cj6q0xhptc.lambda-url.us-east-1.on.aws/</code></td>
201
165
  <td>Fetch extra data of a particular ERC721 collection</td>
202
166
  </tr>
203
167
  <tr>
204
168
  <td>ERC721</td>
205
- <td><code>useFetchERC721CollectionFloorPrice(contractAddress: string, serverURL: string)</code></td>
206
- <td><code>/erc721-collection-floor-price</code></td>
169
+ <td><code>useERC721CollectionFloorPrice(contractAddress: string)</code></td>
170
+ <td><code>https://343rc276twphsdjwtzrzjytepu0xdxxn.lambda-url.us-east-1.on.aws/</code></td>
207
171
  <td>Fetch floor price data of a particular ERC721 collection</td>
208
172
  </tr>
209
173
  <tr>
210
174
  <td>ERC721</td>
211
- <td><code>useFetchERC721CollectionMarketCap(contractAddress: string, duration: 2 | 14 | 30, serverURL: string)</code></td>
212
- <td><code>/erc721-collection-market-cap</code></td>
175
+ <td><code>useERC721CollectionMarketCap(contractAddress: string, duration: 2 | 14 | 30)</code></td>
176
+ <td><code>https://o5ntejtug7ixeetoqf5uxjpwgq0mbtvt.lambda-url.us-east-1.on.aws/</code></td>
213
177
  <td>Fetch market cap data of a particular ERC721 collection</td>
214
178
  </tr>
215
179
  <tr>
216
180
  <td>ERC721</td>
217
- <td><code>useFetchERC721CollectionSales(contractAddress: string, serverURL: string)</code></td>
218
- <td><code>/erc721-collection-sales</code></td>
181
+ <td><code>useERC721CollectionSales(contractAddress: string)</code></td>
182
+ <td><code>https://b5xcn2afinyiq32izaoxe4mzua0ggxvm.lambda-url.us-east-1.on.aws/</code></td>
219
183
  <td>Fetch sales data of a particular ERC721 collection</td>
220
184
  </tr>
221
185
  <tr>
222
186
  <td>ERC721</td>
223
- <td><code>useFetchERC721CollectionTransfers(contractAddress: string, serverURL: string)</code></td>
224
- <td><code>/erc721-collection-transfers</code></td>
187
+ <td><code>useERC721CollectionTransfers(contractAddress: string)</code></td>
188
+ <td><code>https://lrtnsabh6hkimp4hqonw3foi2e0zzuxq.lambda-url.us-east-1.on.aws/</code></td>
225
189
  <td>Fetch transfer activity of a particular ERC721 collection</td>
226
190
  </tr>
227
191
  <tr>
228
192
  <td>ERC721</td>
229
- <td><code>useFetchERC721CollectionTrends(serverURL: string)</code></td>
230
- <td><code>/erc721-collection-trends</code></td>
193
+ <td><code>useERC721CollectionTrends()</code></td>
194
+ <td><code>https://hmzkjpwut4bwaeovhryd6hie540fwvzi.lambda-url.us-east-1.on.aws/</code></td>
231
195
  <td>Fetch trending ERC721 collection data</td>
232
196
  </tr>
233
197
  <tr>
234
198
  <td>ERC721</td>
235
- <td><code>useFetchERC721CollectionVolume(serverURL: string)</code></td>
236
- <td><code>/erc721-collection-volume</code></td>
199
+ <td><code>useERC721CollectionVolume()</code></td>
200
+ <td><code>https://zlksxwjaikudsub4rmcc5c4eme0uqntg.lambda-url.us-east-1.on.aws/</code></td>
237
201
  <td>Fetch ERC721 collections by volume data</td>
238
202
  </tr>
239
203
  <tr>
240
204
  <td>ERC721</td>
241
- <td><code>useFetchERC721Holdings(walletAddress: string, serverURL: string)</code></td>
242
- <td><code>/erc721-holdings</code></td>
205
+ <td><code>useERC721Holdings(walletAddress: string)</code></td>
206
+ <td><code>https://rmepnjzubrgdsvmb66kdwz5upm0khfor.lambda-url.us-east-1.on.aws/</code></td>
243
207
  <td>Fetch ERC721 holdings of a particular wallet</td>
244
208
  </tr>
245
209
  <tr>
246
210
  <td>ERC721</td>
247
- <td><code>useFetchERC721LookupData(contractAddress: string, tokenID: string, serverURL: string)</code></td>
248
- <td><code>/erc721-lookup-data</code></td>
211
+ <td><code>useERC721LookupData(contractAddress: string, tokenID: string)</code></td>
212
+ <td><code>https://rd7cae6wlnx3lsiuncgjgeap5e0lkbew.lambda-url.us-east-1.on.aws/</code></td>
249
213
  <td>Fetch data of a particular ERC721 token</td>
250
214
  </tr>
251
215
  <tr>
252
216
  <td>ERC721</td>
253
- <td><code>useFetchERC721OpenseaData(contractAddress: string, tokenID: string, serverURL: string)</code></td>
254
- <td><code>/erc721-opensea-data</code></td>
217
+ <td><code>useERC721OpenseaData(contractAddress: string, tokenID: string)</code></td>
218
+ <td><code>https://qoeq2n767jbu5gbiiy7463d56m0cwdec.lambda-url.us-east-1.on.aws/</code></td>
255
219
  <td>Fetch Opensea data of a particular ERC721 token</td>
256
220
  </tr>
257
221
  <tr>
258
222
  <td>ERC721</td>
259
- <td><code>useFetchERC721RarityData(contractAddress: string, tokenID: string, serverURL: string)</code></td>
260
- <td><code>/erc721-rarity-data</code></td>
223
+ <td><code>useERC721RarityData(contractAddress: string, tokenID: string)</code></td>
224
+ <td><code>https://eilobcax7r4wayov2rfscraqb40rodzv.lambda-url.us-east-1.on.aws/</code></td>
261
225
  <td>Fetch rarity data of a particular ERC721 token</td>
262
226
  </tr>
263
227
  <tr>
264
228
  <td>ERC721</td>
265
- <td><code>useFetchERC721SalesData(contractAddress: string, tokenID: string, serverURL: string)</code></td>
266
- <td><code>/erc721-sales-data</code></td>
229
+ <td><code>useERC721SalesData(contractAddress: string, tokenID: string)</code></td>
230
+ <td><code>https://nhjz6tqihl6bdt7zukf5ru7wnu0ydoqq.lambda-url.us-east-1.on.aws/</code></td>
267
231
  <td>Fetch sales data of a particular ERC721 token</td>
268
232
  </tr>
269
233
  <tr>
270
234
  <td>ERC721</td>
271
- <td><code>useFetchERC721TransferLookupData(contractAddress: string, tokenID: string, serverURL: string)</code></td>
272
- <td><code>/erc721-lookup-data</code></td>
235
+ <td><code>useERC721TransferLookupData(contractAddress: string, tokenID: string)</code></td>
236
+ <td><code>https://o66cbw3kaufg5t3k2fl5ydazbq0tvfaz.lambda-url.us-east-1.on.aws/</code></td>
273
237
  <td>Fetch transfer data of a particular ERC721 token</td>
274
238
  </tr>
275
239
  <tr>
276
240
  <td>ERC721</td>
277
- <td><code>useFetchERC721TransfersData(walletAddress: string, serverURL: string)</code></td>
278
- <td><code>/erc721-token-transfer-lookup-data</code></td>
241
+ <td><code>useERC721TransfersData(walletAddress: string)</code></td>
242
+ <td><code>https://gnfeczsyzj4v6rsyf4zmlpv23q0uixkv.lambda-url.us-east-1.on.aws/</code></td>
279
243
  <td>Fetch ERC721 transfer activity of a particular wallet</td>
280
244
  </tr>
281
245
  <tr>
282
246
  <td>Gas</td>
283
- <td><code>useFetchGasLookup(serverURL: string)</code></td>
284
- <td><code>/gas-information</code></td>
247
+ <td><code>useGasLookup()</code></td>
248
+ <td><code>https://wsebjfjyi4k2kfb4mbcrcjyrqa0nwifh.lambda-url.us-east-1.on.aws/</code></td>
285
249
  <td>Fetch gas information related to Ethereum or a supported layer two</td>
286
250
  </tr>
287
251
  <tr>
288
252
  <td>Prices</td>
289
- <td><code>useFetchERC20Price(contractAddress: string, currentPrice: boolean, duration: 2 | 14 | 30, serverURL: string)</code></td>
290
- <td><code>/erc20-token-price</code></td>
253
+ <td><code>useERC20Price(contractAddress: string, currentPrice: boolean, duration: 2 | 14 | 30)</code></td>
254
+ <td><code>https://vw5caqjd3yg2oyslxcyxkln2dy0nqgxz.lambda-url.us-east-1.on.aws/</code></td>
291
255
  <td>Fetch pricing data of a particular ERC20 collection</td>
292
256
  </tr>
293
257
  <tr>
294
258
  <td>Prices</td>
295
- <td><code>useFetchERC721Price(contractAddress: string, tokenID: string, serverURL: string)</code></td>
296
- <td><code>/erc721-token-price</code></td>
259
+ <td><code>useERC721Price(contractAddress: string, tokenID: string)</code></td>
260
+ <td><code>https://brjvjnlp35ln3solbquo6fiize0bnwje.lambda-url.us-east-1.on.aws/</code></td>
297
261
  <td>Fetch pricing data of a particular ERC721 collection</td>
298
262
  </tr>
299
263
  <tr>
300
264
  <td>Prices</td>
301
- <td><code>useFetchETHPrice(currentPrice: boolean, duration: 2 | 14 | 30, serverURL: string)</code></td>
302
- <td><code>/eth-price</code></td>
265
+ <td><code>useETHPrice(currentPrice: boolean, duration: 2 | 14 | 30)</code></td>
266
+ <td><code>https://fl5mxvcm42g3n7wtodnxq52s2a0jeokj.lambda-url.us-east-1.on.aws/</code></td>
303
267
  <td>Fetch Ethereum price data</td>
304
268
  </tr>
305
269
  <tr>
306
270
  <td>Prices</td>
307
- <td><code>useFetchLayerTwoPrice(layerTwo: LayerTwoNetworks, currentPrice: boolean, duration: 2 | 14 | 30, serverURL: string)</code></td>
308
- <td><code>/layer-two-prices</code></td>
271
+ <td><code>useLayerTwoPrice(layerTwo: LayerTwoNetworks, currentPrice: boolean, duration: 2 | 14 | 30)</code></td>
272
+ <td><code>https://jt7ds5ua6iix7cpa5ueg2ud2gi0joklo.lambda-url.us-east-1.on.aws/</code></td>
309
273
  <td>Fetch Layer Two price data</td>
310
274
  </tr>
311
275
  </table>
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
3
  // Fetching Address to ENS Custom hook
4
- export const useFetchAddressENSLookup = (address: string, serverURL: string) => {
4
+ export const useAddressENSLookup = (address: string) => {
5
5
  const options = {
6
6
  method: 'POST',
7
7
  body: JSON.stringify({ address }),
@@ -11,7 +11,7 @@ export const useFetchAddressENSLookup = (address: string, serverURL: string) =>
11
11
  };
12
12
 
13
13
  // ENDPOINT - /address-to-ens-information
14
- const state = useFetch(serverURL, options); // Use the custom hook to fetch data
14
+ const state = useFetch("https://37zq2u4ntbygkw7inki3djjm440xctyd.lambda-url.us-east-1.on.aws/", options); // Use the custom hook to fetch data
15
15
 
16
16
  return state; // Return the state from the custom hook
17
17
  }
@@ -1,8 +1,7 @@
1
- import axios from "axios";
2
1
  import { useFetch } from "../../custom_hooks/useFetch";
3
2
 
4
3
  // Fetching ENS to Address Custom hook
5
- export const useFetchENSAddressLookup = (ensName: string, serverURL: string) => {
4
+ export const useENSAddressLookup = (ensName: string) => {
6
5
  const options = {
7
6
  method: 'POST',
8
7
  body: JSON.stringify({ ensName }),
@@ -11,8 +10,8 @@ export const useFetchENSAddressLookup = (ensName: string, serverURL: string) =>
11
10
  }
12
11
  };
13
12
 
14
- // ENDPOINT - /additional-address-to-ens-information
15
- const state = useFetch(serverURL, options); // Use the custom hook to fetch data
13
+ // ENDPOINT - /ens-to-address-information
14
+ const state = useFetch("https://jy3upsy3rgbengcktqlqfcwyhy0wcamb.lambda-url.us-east-1.on.aws/", options); // Use the custom hook to fetch data
16
15
 
17
16
  return state; // Return the state from the custom hook
18
17
  }
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
3
  // Fetch ENS ID lookups
4
- export const useFetchENSIDLookup = (id: string, serverURL: string) => {
4
+ export const useENSIDLookup = (id: string) => {
5
5
  const options = {
6
6
  method: 'POST',
7
7
  body: JSON.stringify({ id }),
@@ -11,7 +11,7 @@ export const useFetchENSIDLookup = (id: string, serverURL: string) => {
11
11
  };
12
12
 
13
13
  // ENDPOINT - /ens-transfers-by-id
14
- const state = useFetch(serverURL, options); // Use the custom hook to fetch data
14
+ const state = useFetch("https://ev6i3gsesgdvj7ouxiwpg4qafu0nfvdw.lambda-url.us-east-1.on.aws/", options); // Use the custom hook to fetch data
15
15
 
16
16
  return state; // Return the state from the custom hook
17
17
  }
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
3
  // Fetch ENS Name lookups
4
- export const useFetchENSNameLookup = (ensName: string, serverURL: string) => {
4
+ export const useENSNameLookup = (ensName: string) => {
5
5
 
6
6
  const options = {
7
7
  method: 'POST',
@@ -12,7 +12,7 @@ export const useFetchENSNameLookup = (ensName: string, serverURL: string) => {
12
12
  };
13
13
 
14
14
  // ENDPOINT - /ens-transfers-by-name
15
- const state = useFetch(serverURL, options); // Use the custom hook to fetch data
15
+ const state = useFetch("https://f53actwgpl2a3rk6uynoryuoxq0eifuo.lambda-url.us-east-1.on.aws/", options); // Use the custom hook to fetch data
16
16
 
17
17
  return state; // Return the state from the custom hook
18
18
  }
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
- // Fetching ERC20 Prices Hook
4
- export const useFetchERC20CollectionOwners = async (contractAddress: string, serverURL: string) => {
3
+ // Fetching ERC20 Collection Owners Hook
4
+ export const useERC20CollectionOwners = async (contractAddress: string) => {
5
5
 
6
6
  // Set options for request
7
7
  let options = {
@@ -14,7 +14,7 @@ export const useFetchERC20CollectionOwners = async (contractAddress: string, ser
14
14
 
15
15
  // Use the custom hook to fetch data
16
16
  // ENDPOINT - /erc20-collection-owners
17
- const state = useFetch(serverURL, options);
17
+ const state = useFetch("https://hyrbuxy6aivjqjrgtogd3nx5we0gcxjr.lambda-url.us-east-1.on.aws/", options);
18
18
 
19
19
  // Return the state from the custom hook
20
20
  return state;
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
3
  // Fetching ERC20 Collection Top Coins
4
- export const useFetchERC20CollectionTopCoins = async (serverURL: string) => {
4
+ export const useERC20CollectionTopCoins = async () => {
5
5
 
6
6
  // Set options for request
7
7
  let options = {
@@ -13,7 +13,7 @@ export const useFetchERC20CollectionTopCoins = async (serverURL: string) => {
13
13
 
14
14
  // Use the custom hook to fetch data
15
15
  // ENDPOINT - /erc20-top-coins
16
- const state = useFetch(serverURL, options);
16
+ const state = useFetch("https://2ebpropr2dgzqicposkbrvr5nq0ofyyx.lambda-url.us-east-1.on.aws/", options);
17
17
 
18
18
  // Return the state from the custom hook
19
19
  return state;
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
3
  // Fetching ERC20 Collection Transfers
4
- export const useFetchERC20CollectionTransfers = async (contractAddress: string, serverURL: string) => {
4
+ export const useERC20CollectionTransfers = async (contractAddress: string) => {
5
5
 
6
6
  // Set options for request
7
7
  let options = {
@@ -13,8 +13,8 @@ export const useFetchERC20CollectionTransfers = async (contractAddress: string,
13
13
  }
14
14
 
15
15
  // Use the custom hook to fetch data
16
- // ENDPOINT - /erc20-collecion-transfers
17
- const state = useFetch(serverURL, options);
16
+ // ENDPOINT - /erc20-collection-transfers
17
+ const state = useFetch("https://bwqre7ze2vm3sum5avrvwzwbrm0gyxcy.lambda-url.us-east-1.on.aws/", options);
18
18
 
19
19
  // Return the state from the custom hook
20
20
  return state;
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
3
  // Fetching ERC20 Collection Holdings
4
- export const useFetchERC20Holdings = async (contractAddress: string, serverURL: string) => {
4
+ export const useERC20Holdings = async (contractAddress: string) => {
5
5
 
6
6
  // Set options for request
7
7
  let options = {
@@ -14,7 +14,7 @@ export const useFetchERC20Holdings = async (contractAddress: string, serverURL:
14
14
 
15
15
  // Use the custom hook to fetch data
16
16
  // ENDPOINT - /erc20-collection-holdings
17
- const state = useFetch(serverURL, options);
17
+ const state = useFetch("https://2i2neqclwlgygwimhbzlhdtjwa0dupee.lambda-url.us-east-1.on.aws/", options);
18
18
 
19
19
  // Return the state from the custom hook
20
20
  return state;
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
3
  // Fetching ERC20 Collection Transfers
4
- export const useFetchERC20Transfers = async (contractAddress: string, serverURL: string) => {
4
+ export const useERC20Transfers = async (contractAddress: string) => {
5
5
 
6
6
  // Set options for request
7
7
  let options = {
@@ -14,7 +14,7 @@ export const useFetchERC20Transfers = async (contractAddress: string, serverURL:
14
14
 
15
15
  // Use the custom hook to fetch data
16
16
  // ENDPOINT - /erc20-collection-transfers
17
- const state = useFetch(serverURL, options);
17
+ const state = useFetch("https://msee4ccresifmjhm3mdedry3ki0xvdgx.lambda-url.us-east-1.on.aws/", options);
18
18
 
19
19
  // Return the state from the custom hook
20
20
  return state;
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
3
  // Fetching ERC721 Collection Attributes Hook
4
- export const useFetchERC721CollectionAttributes = async (contractAddress: string, serverURL: string) => {
4
+ export const useERC721CollectionAttributes = async (contractAddress: string) => {
5
5
 
6
6
  // Set options for request
7
7
  let options = {
@@ -14,7 +14,7 @@ export const useFetchERC721CollectionAttributes = async (contractAddress: string
14
14
 
15
15
  // Use the custom hook to fetch data
16
16
  // ENDPOINT - /erc721-collection-attributes
17
- const state = useFetch(serverURL, options);
17
+ const state = useFetch("https://7rs4acgso6ld44zjpl25jras3q0szvag.lambda-url.us-east-1.on.aws/", options);
18
18
 
19
19
  // Return the state from the custom hook
20
20
  return state;
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
3
  // Fetching ERC721 Collection Data Hook
4
- export const useFetchERC721CollectionData = async (contractAddress: string, serverURL: string) => {
4
+ export const useERC721CollectionData = async (contractAddress: string) => {
5
5
 
6
6
  // Set options for request
7
7
  let options = {
@@ -14,7 +14,7 @@ export const useFetchERC721CollectionData = async (contractAddress: string, serv
14
14
 
15
15
  // Use the custom hook to fetch data
16
16
  // ENDPOINT - /erc721-collection-data
17
- const state = useFetch(serverURL, options);
17
+ const state = useFetch("https://u2pdhfz4qbfkkyp6z4yg4n57hq0hzica.lambda-url.us-east-1.on.aws/", options);
18
18
 
19
19
  // Return the state from the custom hook
20
20
  return state;
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
3
  // Fetching ERC721 Collection Data Hook
4
- export const useFetchERC721CollectionExtraData = async (contractAddress: string, serverURL: string) => {
4
+ export const useERC721CollectionExtraData = async (contractAddress: string) => {
5
5
 
6
6
  // Set options for request
7
7
  let options = {
@@ -14,7 +14,7 @@ export const useFetchERC721CollectionExtraData = async (contractAddress: string,
14
14
 
15
15
  // Use the custom hook to fetch data
16
16
  // ENDPOINT - erc721-collection-extra-data
17
- const state = useFetch(serverURL, options);
17
+ const state = useFetch("https://b5mkshxv54bbj4d54rxze5cj6q0xhptc.lambda-url.us-east-1.on.aws/", options);
18
18
 
19
19
  // Return the state from the custom hook
20
20
  return state;
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
3
  // Fetching ERC721 Collection Floor Price Hook
4
- export const useFetchERC721CollectionFloorPrice = async (contractAddress: string, serverURL: string) => {
4
+ export const useERC721CollectionFloorPrice = async (contractAddress: string) => {
5
5
 
6
6
  // Set options for request
7
7
  let options = {
@@ -14,7 +14,7 @@ export const useFetchERC721CollectionFloorPrice = async (contractAddress: string
14
14
 
15
15
  // Use the custom hook to fetch data
16
16
  // ENDPOINT - /erc721-collection-floor-price
17
- const state = useFetch(serverURL, options);
17
+ const state = useFetch("https://343rc276twphsdjwtzrzjytepu0xdxxn.lambda-url.us-east-1.on.aws/", options);
18
18
 
19
19
  // Return the state from the custom hook
20
20
  return state;
@@ -1,7 +1,7 @@
1
1
  import { useFetch } from "../../custom_hooks/useFetch";
2
2
 
3
3
  // Fetching ERC721 Collection Market Cap Hook
4
- export const useFetchERC721CollectionMarketCap = async (contractAddress: string, duration: 2 | 14 | 30, serverURL: string) => {
4
+ export const useERC721CollectionMarketCap = async (contractAddress: string, duration: 2 | 14 | 30) => {
5
5
 
6
6
  // Set options for request
7
7
  let options = {
@@ -14,7 +14,7 @@ export const useFetchERC721CollectionMarketCap = async (contractAddress: string,
14
14
 
15
15
  // Use the custom hook to fetch data
16
16
  // ENDPOINT - /erc721-collection-market-cap
17
- const state = useFetch(serverURL, options);
17
+ const state = useFetch("https://o5ntejtug7ixeetoqf5uxjpwgq0mbtvt.lambda-url.us-east-1.on.aws/", options);
18
18
 
19
19
  // Return the state from the custom hook
20
20
  return state;