@one-source/api-mcp 1.0.0

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 (167) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +147 -0
  3. package/dist/analytics.d.ts +53 -0
  4. package/dist/analytics.d.ts.map +1 -0
  5. package/dist/analytics.fix-verification.test.d.ts +11 -0
  6. package/dist/analytics.fix-verification.test.d.ts.map +1 -0
  7. package/dist/analytics.fix-verification.test.js +146 -0
  8. package/dist/analytics.fix-verification.test.js.map +1 -0
  9. package/dist/analytics.js +126 -0
  10. package/dist/analytics.js.map +1 -0
  11. package/dist/cli.d.ts +3 -0
  12. package/dist/cli.d.ts.map +1 -0
  13. package/dist/cli.js +144 -0
  14. package/dist/cli.js.map +1 -0
  15. package/dist/client.d.ts +52 -0
  16. package/dist/client.d.ts.map +1 -0
  17. package/dist/client.js +126 -0
  18. package/dist/client.js.map +1 -0
  19. package/dist/create-server.d.ts +28 -0
  20. package/dist/create-server.d.ts.map +1 -0
  21. package/dist/create-server.js +133 -0
  22. package/dist/create-server.js.map +1 -0
  23. package/dist/tools/chain/contract-code.d.ts +6 -0
  24. package/dist/tools/chain/contract-code.d.ts.map +1 -0
  25. package/dist/tools/chain/contract-code.js +19 -0
  26. package/dist/tools/chain/contract-code.js.map +1 -0
  27. package/dist/tools/chain/ens-resolve.d.ts +3 -0
  28. package/dist/tools/chain/ens-resolve.d.ts.map +1 -0
  29. package/dist/tools/chain/ens-resolve.js +25 -0
  30. package/dist/tools/chain/ens-resolve.js.map +1 -0
  31. package/dist/tools/chain/estimate-gas.d.ts +6 -0
  32. package/dist/tools/chain/estimate-gas.d.ts.map +1 -0
  33. package/dist/tools/chain/estimate-gas.js +31 -0
  34. package/dist/tools/chain/estimate-gas.js.map +1 -0
  35. package/dist/tools/chain/network-info.d.ts +6 -0
  36. package/dist/tools/chain/network-info.d.ts.map +1 -0
  37. package/dist/tools/chain/network-info.js +18 -0
  38. package/dist/tools/chain/network-info.js.map +1 -0
  39. package/dist/tools/chain/nonce.d.ts +6 -0
  40. package/dist/tools/chain/nonce.d.ts.map +1 -0
  41. package/dist/tools/chain/nonce.js +19 -0
  42. package/dist/tools/chain/nonce.js.map +1 -0
  43. package/dist/tools/chain/pending-block.d.ts +6 -0
  44. package/dist/tools/chain/pending-block.d.ts.map +1 -0
  45. package/dist/tools/chain/pending-block.js +18 -0
  46. package/dist/tools/chain/pending-block.js.map +1 -0
  47. package/dist/tools/chain/proxy-detect.d.ts +6 -0
  48. package/dist/tools/chain/proxy-detect.d.ts.map +1 -0
  49. package/dist/tools/chain/proxy-detect.js +19 -0
  50. package/dist/tools/chain/proxy-detect.js.map +1 -0
  51. package/dist/tools/chain/simulate-call.d.ts +6 -0
  52. package/dist/tools/chain/simulate-call.d.ts.map +1 -0
  53. package/dist/tools/chain/simulate-call.js +33 -0
  54. package/dist/tools/chain/simulate-call.js.map +1 -0
  55. package/dist/tools/chain/storage-read.d.ts +3 -0
  56. package/dist/tools/chain/storage-read.d.ts.map +1 -0
  57. package/dist/tools/chain/storage-read.js +22 -0
  58. package/dist/tools/chain/storage-read.js.map +1 -0
  59. package/dist/tools/chain/tx-receipt.d.ts +6 -0
  60. package/dist/tools/chain/tx-receipt.d.ts.map +1 -0
  61. package/dist/tools/chain/tx-receipt.js +18 -0
  62. package/dist/tools/chain/tx-receipt.js.map +1 -0
  63. package/dist/tools/index.d.ts +7 -0
  64. package/dist/tools/index.d.ts.map +1 -0
  65. package/dist/tools/index.js +77 -0
  66. package/dist/tools/index.js.map +1 -0
  67. package/dist/tools/indexed/address-txs.d.ts +6 -0
  68. package/dist/tools/indexed/address-txs.d.ts.map +1 -0
  69. package/dist/tools/indexed/address-txs.js +25 -0
  70. package/dist/tools/indexed/address-txs.js.map +1 -0
  71. package/dist/tools/indexed/block.d.ts +3 -0
  72. package/dist/tools/indexed/block.d.ts.map +1 -0
  73. package/dist/tools/indexed/block.js +23 -0
  74. package/dist/tools/indexed/block.js.map +1 -0
  75. package/dist/tools/indexed/contract-info.d.ts +6 -0
  76. package/dist/tools/indexed/contract-info.d.ts.map +1 -0
  77. package/dist/tools/indexed/contract-info.js +18 -0
  78. package/dist/tools/indexed/contract-info.js.map +1 -0
  79. package/dist/tools/indexed/erc1155-balance.d.ts +6 -0
  80. package/dist/tools/indexed/erc1155-balance.d.ts.map +1 -0
  81. package/dist/tools/indexed/erc1155-balance.js +24 -0
  82. package/dist/tools/indexed/erc1155-balance.js.map +1 -0
  83. package/dist/tools/indexed/erc20-balance.d.ts +6 -0
  84. package/dist/tools/indexed/erc20-balance.d.ts.map +1 -0
  85. package/dist/tools/indexed/erc20-balance.js +22 -0
  86. package/dist/tools/indexed/erc20-balance.js.map +1 -0
  87. package/dist/tools/indexed/erc20-transfers.d.ts +6 -0
  88. package/dist/tools/indexed/erc20-transfers.d.ts.map +1 -0
  89. package/dist/tools/indexed/erc20-transfers.js +24 -0
  90. package/dist/tools/indexed/erc20-transfers.js.map +1 -0
  91. package/dist/tools/indexed/events.d.ts +3 -0
  92. package/dist/tools/indexed/events.d.ts.map +1 -0
  93. package/dist/tools/indexed/events.js +32 -0
  94. package/dist/tools/indexed/events.js.map +1 -0
  95. package/dist/tools/indexed/nft-media.d.ts +6 -0
  96. package/dist/tools/indexed/nft-media.d.ts.map +1 -0
  97. package/dist/tools/indexed/nft-media.js +22 -0
  98. package/dist/tools/indexed/nft-media.js.map +1 -0
  99. package/dist/tools/indexed/nft-metadata.d.ts +6 -0
  100. package/dist/tools/indexed/nft-metadata.d.ts.map +1 -0
  101. package/dist/tools/indexed/nft-metadata.js +22 -0
  102. package/dist/tools/indexed/nft-metadata.js.map +1 -0
  103. package/dist/tools/indexed/nft-owner.d.ts +6 -0
  104. package/dist/tools/indexed/nft-owner.d.ts.map +1 -0
  105. package/dist/tools/indexed/nft-owner.js +22 -0
  106. package/dist/tools/indexed/nft-owner.js.map +1 -0
  107. package/dist/tools/indexed/tx-details.d.ts +6 -0
  108. package/dist/tools/indexed/tx-details.d.ts.map +1 -0
  109. package/dist/tools/indexed/tx-details.js +19 -0
  110. package/dist/tools/indexed/tx-details.js.map +1 -0
  111. package/dist/tools/indexed/wallet-nfts.d.ts +6 -0
  112. package/dist/tools/indexed/wallet-nfts.d.ts.map +1 -0
  113. package/dist/tools/indexed/wallet-nfts.js +22 -0
  114. package/dist/tools/indexed/wallet-nfts.js.map +1 -0
  115. package/dist/tools/live/allowance.d.ts +6 -0
  116. package/dist/tools/live/allowance.d.ts.map +1 -0
  117. package/dist/tools/live/allowance.js +24 -0
  118. package/dist/tools/live/allowance.js.map +1 -0
  119. package/dist/tools/live/contract-info.d.ts +6 -0
  120. package/dist/tools/live/contract-info.d.ts.map +1 -0
  121. package/dist/tools/live/contract-info.js +19 -0
  122. package/dist/tools/live/contract-info.js.map +1 -0
  123. package/dist/tools/live/erc1155-balance.d.ts +6 -0
  124. package/dist/tools/live/erc1155-balance.d.ts.map +1 -0
  125. package/dist/tools/live/erc1155-balance.js +24 -0
  126. package/dist/tools/live/erc1155-balance.js.map +1 -0
  127. package/dist/tools/live/erc20-balance.d.ts +6 -0
  128. package/dist/tools/live/erc20-balance.d.ts.map +1 -0
  129. package/dist/tools/live/erc20-balance.js +22 -0
  130. package/dist/tools/live/erc20-balance.js.map +1 -0
  131. package/dist/tools/live/erc20-transfers.d.ts +3 -0
  132. package/dist/tools/live/erc20-transfers.d.ts.map +1 -0
  133. package/dist/tools/live/erc20-transfers.js +26 -0
  134. package/dist/tools/live/erc20-transfers.js.map +1 -0
  135. package/dist/tools/live/erc721-tokens.d.ts +6 -0
  136. package/dist/tools/live/erc721-tokens.d.ts.map +1 -0
  137. package/dist/tools/live/erc721-tokens.js +22 -0
  138. package/dist/tools/live/erc721-tokens.js.map +1 -0
  139. package/dist/tools/live/events.d.ts +3 -0
  140. package/dist/tools/live/events.d.ts.map +1 -0
  141. package/dist/tools/live/events.js +26 -0
  142. package/dist/tools/live/events.js.map +1 -0
  143. package/dist/tools/live/multi-balance.d.ts +3 -0
  144. package/dist/tools/live/multi-balance.d.ts.map +1 -0
  145. package/dist/tools/live/multi-balance.js +26 -0
  146. package/dist/tools/live/multi-balance.js.map +1 -0
  147. package/dist/tools/live/nft-metadata.d.ts +6 -0
  148. package/dist/tools/live/nft-metadata.d.ts.map +1 -0
  149. package/dist/tools/live/nft-metadata.js +22 -0
  150. package/dist/tools/live/nft-metadata.js.map +1 -0
  151. package/dist/tools/live/nft-owner.d.ts +6 -0
  152. package/dist/tools/live/nft-owner.d.ts.map +1 -0
  153. package/dist/tools/live/nft-owner.js +22 -0
  154. package/dist/tools/live/nft-owner.js.map +1 -0
  155. package/dist/tools/live/total-supply.d.ts +6 -0
  156. package/dist/tools/live/total-supply.d.ts.map +1 -0
  157. package/dist/tools/live/total-supply.js +20 -0
  158. package/dist/tools/live/total-supply.js.map +1 -0
  159. package/dist/tools/live/tx-details.d.ts +6 -0
  160. package/dist/tools/live/tx-details.d.ts.map +1 -0
  161. package/dist/tools/live/tx-details.js +19 -0
  162. package/dist/tools/live/tx-details.js.map +1 -0
  163. package/dist/types.d.ts +74 -0
  164. package/dist/types.d.ts.map +1 -0
  165. package/dist/types.js +86 -0
  166. package/dist/types.js.map +1 -0
  167. package/package.json +64 -0
@@ -0,0 +1,32 @@
1
+ /**
2
+ * 1s_events — Search indexed event logs by contract and/or event name.
3
+ */
4
+ import { z } from 'zod';
5
+ import { networkParam, formatResponse, limitParam, blockNumberParam, optionalAddressParam } from '../../types.js';
6
+ export const tool = {
7
+ name: '1s_events',
8
+ description: 'Search indexed event logs by contract address and/or event name. ' +
9
+ 'Use this for decoded, searchable events; use 1s_events_live for raw eth_getLogs against the node. ' +
10
+ 'Sorted by block number descending.',
11
+ category: 'indexed',
12
+ schema: {
13
+ contract: optionalAddressParam.describe('Contract address to filter events by'),
14
+ event_name: z.string().regex(/^[a-zA-Z_][a-zA-Z0-9_]*$/).max(100).optional().describe("Event name e.g. 'Transfer', 'Approval'"),
15
+ limit: limitParam,
16
+ from_block: blockNumberParam.describe('Start block number (inclusive)'),
17
+ to_block: blockNumberParam.describe('End block number (inclusive)'),
18
+ network: networkParam,
19
+ },
20
+ handler: async (input, client) => {
21
+ const res = await client.get('/api/events', {
22
+ contract: input.contract,
23
+ event_name: input.event_name,
24
+ limit: input.limit,
25
+ from_block: input.from_block,
26
+ to_block: input.to_block,
27
+ network: input.network,
28
+ });
29
+ return formatResponse(res);
30
+ },
31
+ };
32
+ //# sourceMappingURL=events.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"events.js","sourceRoot":"","sources":["../../../src/tools/indexed/events.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,UAAU,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAElH,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,WAAW;IACjB,WAAW,EACT,mEAAmE;QACnE,oGAAoG;QACpG,oCAAoC;IACtC,QAAQ,EAAE,SAAS;IACnB,MAAM,EAAE;QACN,QAAQ,EAAE,oBAAoB,CAAC,QAAQ,CAAC,sCAAsC,CAAC;QAC/E,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,0BAA0B,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,wCAAwC,CAAC;QAC/H,KAAK,EAAE,UAAU;QACjB,UAAU,EAAE,gBAAgB,CAAC,QAAQ,CAAC,gCAAgC,CAAC;QACvE,QAAQ,EAAE,gBAAgB,CAAC,QAAQ,CAAC,8BAA8B,CAAC;QACnE,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,aAAa,EAAE;YAC1C,QAAQ,EAAE,KAAK,CAAC,QAA8B;YAC9C,UAAU,EAAE,KAAK,CAAC,UAAgC;YAClD,KAAK,EAAE,KAAK,CAAC,KAA2B;YACxC,UAAU,EAAE,KAAK,CAAC,UAAgC;YAClD,QAAQ,EAAE,KAAK,CAAC,QAA8B;YAC9C,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 1s_nft_media — Get processed media files for an NFT.
3
+ */
4
+ import type { ToolDef } from '../../types.js';
5
+ export declare const tool: ToolDef;
6
+ //# sourceMappingURL=nft-media.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nft-media.d.ts","sourceRoot":"","sources":["../../../src/tools/indexed/nft-media.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAoBlB,CAAC"}
@@ -0,0 +1,22 @@
1
+ import { networkParam, formatResponse, addressParam, tokenIdParam } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_nft_media',
4
+ description: 'Get processed media files (images, videos, thumbnails) for an NFT. ' +
5
+ 'Use this to get optimized media URLs with dimensions and content types. ' +
6
+ 'Only returns successfully processed media (status=OK).',
7
+ category: 'indexed',
8
+ schema: {
9
+ contract: addressParam.describe('NFT contract address'),
10
+ token_id: tokenIdParam,
11
+ network: networkParam,
12
+ },
13
+ handler: async (input, client) => {
14
+ const res = await client.get('/api/nft/media', {
15
+ contract: input.contract,
16
+ token_id: input.token_id,
17
+ network: input.network,
18
+ });
19
+ return formatResponse(res);
20
+ },
21
+ };
22
+ //# sourceMappingURL=nft-media.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nft-media.js","sourceRoot":"","sources":["../../../src/tools/indexed/nft-media.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE1F,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,cAAc;IACpB,WAAW,EACT,qEAAqE;QACrE,0EAA0E;QAC1E,wDAAwD;IAC1D,QAAQ,EAAE,SAAS;IACnB,MAAM,EAAE;QACN,QAAQ,EAAE,YAAY,CAAC,QAAQ,CAAC,sBAAsB,CAAC;QACvD,QAAQ,EAAE,YAAY;QACtB,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,gBAAgB,EAAE;YAC7C,QAAQ,EAAE,KAAK,CAAC,QAAkB;YAClC,QAAQ,EAAE,KAAK,CAAC,QAAkB;YAClC,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 1s_nft_metadata — Get NFT metadata from the index.
3
+ */
4
+ import type { ToolDef } from '../../types.js';
5
+ export declare const tool: ToolDef;
6
+ //# sourceMappingURL=nft-metadata.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nft-metadata.d.ts","sourceRoot":"","sources":["../../../src/tools/indexed/nft-metadata.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAoBlB,CAAC"}
@@ -0,0 +1,22 @@
1
+ import { networkParam, formatResponse, addressParam, tokenIdParam } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_nft_metadata',
4
+ description: 'Get NFT metadata including name, description, image URL, and traits from the index. ' +
5
+ 'Use this for enriched metadata; use 1s_nft_metadata_live to fetch directly from the token\'s URI. ' +
6
+ 'Excludes records with fetch errors.',
7
+ category: 'indexed',
8
+ schema: {
9
+ contract: addressParam.describe('NFT contract address'),
10
+ token_id: tokenIdParam,
11
+ network: networkParam,
12
+ },
13
+ handler: async (input, client) => {
14
+ const res = await client.get('/api/nft/metadata', {
15
+ contract: input.contract,
16
+ token_id: input.token_id,
17
+ network: input.network,
18
+ });
19
+ return formatResponse(res);
20
+ },
21
+ };
22
+ //# sourceMappingURL=nft-metadata.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nft-metadata.js","sourceRoot":"","sources":["../../../src/tools/indexed/nft-metadata.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE1F,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,iBAAiB;IACvB,WAAW,EACT,sFAAsF;QACtF,oGAAoG;QACpG,qCAAqC;IACvC,QAAQ,EAAE,SAAS;IACnB,MAAM,EAAE;QACN,QAAQ,EAAE,YAAY,CAAC,QAAQ,CAAC,sBAAsB,CAAC;QACvD,QAAQ,EAAE,YAAY;QACtB,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,mBAAmB,EAAE;YAChD,QAAQ,EAAE,KAAK,CAAC,QAAkB;YAClC,QAAQ,EAAE,KAAK,CAAC,QAAkB;YAClC,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 1s_nft_owner — Get the current owner of an NFT from the index.
3
+ */
4
+ import type { ToolDef } from '../../types.js';
5
+ export declare const tool: ToolDef;
6
+ //# sourceMappingURL=nft-owner.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nft-owner.d.ts","sourceRoot":"","sources":["../../../src/tools/indexed/nft-owner.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAoBlB,CAAC"}
@@ -0,0 +1,22 @@
1
+ import { networkParam, formatResponse, addressParam, tokenIdParam } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_nft_owner',
4
+ description: 'Get the current owner of an NFT from the index. ' +
5
+ 'Use this for quick ownership checks; use 1s_nft_owner_live for guaranteed real-time data. ' +
6
+ 'Filters out zero-balance holders automatically.',
7
+ category: 'indexed',
8
+ schema: {
9
+ contract: addressParam.describe('NFT contract address'),
10
+ token_id: tokenIdParam,
11
+ network: networkParam,
12
+ },
13
+ handler: async (input, client) => {
14
+ const res = await client.get('/api/nft/owner', {
15
+ contract: input.contract,
16
+ token_id: input.token_id,
17
+ network: input.network,
18
+ });
19
+ return formatResponse(res);
20
+ },
21
+ };
22
+ //# sourceMappingURL=nft-owner.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nft-owner.js","sourceRoot":"","sources":["../../../src/tools/indexed/nft-owner.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE1F,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,cAAc;IACpB,WAAW,EACT,kDAAkD;QAClD,4FAA4F;QAC5F,iDAAiD;IACnD,QAAQ,EAAE,SAAS;IACnB,MAAM,EAAE;QACN,QAAQ,EAAE,YAAY,CAAC,QAAQ,CAAC,sBAAsB,CAAC;QACvD,QAAQ,EAAE,YAAY;QACtB,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,gBAAgB,EAAE;YAC7C,QAAQ,EAAE,KAAK,CAAC,QAAkB;YAClC,QAAQ,EAAE,KAAK,CAAC,QAAkB;YAClC,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 1s_tx_details — Get indexed transaction details with decoded event logs.
3
+ */
4
+ import type { ToolDef } from '../../types.js';
5
+ export declare const tool: ToolDef;
6
+ //# sourceMappingURL=tx-details.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tx-details.d.ts","sourceRoot":"","sources":["../../../src/tools/indexed/tx-details.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAiBlB,CAAC"}
@@ -0,0 +1,19 @@
1
+ import { networkParam, formatResponse, txHashParam, safePath } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_tx_details',
4
+ description: 'Get indexed transaction details with decoded event logs. ' +
5
+ 'Use this for rich transaction data; use 1s_tx_details_live for unindexed or very recent transactions. ' +
6
+ 'Returns both the transaction and up to 100 associated events.',
7
+ category: 'indexed',
8
+ schema: {
9
+ hash: txHashParam,
10
+ network: networkParam,
11
+ },
12
+ handler: async (input, client) => {
13
+ const res = await client.get(`/api/tx/${safePath(input.hash)}`, {
14
+ network: input.network,
15
+ });
16
+ return formatResponse(res);
17
+ },
18
+ };
19
+ //# sourceMappingURL=tx-details.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tx-details.js","sourceRoot":"","sources":["../../../src/tools/indexed/tx-details.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAErF,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,eAAe;IACrB,WAAW,EACT,2DAA2D;QAC3D,wGAAwG;QACxG,+DAA+D;IACjE,QAAQ,EAAE,SAAS;IACnB,MAAM,EAAE;QACN,IAAI,EAAE,WAAW;QACjB,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,WAAW,QAAQ,CAAC,KAAK,CAAC,IAAc,CAAC,EAAE,EAAE;YACxE,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 1s_wallet_nfts — Get a wallet's complete NFT portfolio.
3
+ */
4
+ import type { ToolDef } from '../../types.js';
5
+ export declare const tool: ToolDef;
6
+ //# sourceMappingURL=wallet-nfts.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"wallet-nfts.d.ts","sourceRoot":"","sources":["../../../src/tools/indexed/wallet-nfts.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAoBlB,CAAC"}
@@ -0,0 +1,22 @@
1
+ import { networkParam, formatResponse, addressParam, limitParam } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_wallet_nfts',
4
+ description: 'Get a wallet\'s complete NFT portfolio with metadata enrichment. ' +
5
+ 'Returns ERC721 and ERC1155 tokens with names, images, and collection info. ' +
6
+ 'Results sorted by most recently updated.',
7
+ category: 'indexed',
8
+ schema: {
9
+ account: addressParam.describe('Wallet address to list NFTs for'),
10
+ limit: limitParam,
11
+ network: networkParam,
12
+ },
13
+ handler: async (input, client) => {
14
+ const res = await client.get('/api/wallet/nfts', {
15
+ account: input.account,
16
+ limit: input.limit,
17
+ network: input.network,
18
+ });
19
+ return formatResponse(res);
20
+ },
21
+ };
22
+ //# sourceMappingURL=wallet-nfts.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"wallet-nfts.js","sourceRoot":"","sources":["../../../src/tools/indexed/wallet-nfts.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAExF,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,gBAAgB;IACtB,WAAW,EACT,mEAAmE;QACnE,6EAA6E;QAC7E,0CAA0C;IAC5C,QAAQ,EAAE,SAAS;IACnB,MAAM,EAAE;QACN,OAAO,EAAE,YAAY,CAAC,QAAQ,CAAC,iCAAiC,CAAC;QACjE,KAAK,EAAE,UAAU;QACjB,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,kBAAkB,EAAE;YAC/C,OAAO,EAAE,KAAK,CAAC,OAAiB;YAChC,KAAK,EAAE,KAAK,CAAC,KAA2B;YACxC,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 1s_allowance_live — Check ERC20 token allowance via RPC.
3
+ */
4
+ import type { ToolDef } from '../../types.js';
5
+ export declare const tool: ToolDef;
6
+ //# sourceMappingURL=allowance.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"allowance.d.ts","sourceRoot":"","sources":["../../../src/tools/live/allowance.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAsBlB,CAAC"}
@@ -0,0 +1,24 @@
1
+ import { networkParam, formatResponse, addressParam } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_allowance_live',
4
+ description: 'Check ERC20 token allowance (approved spending amount) via the allowance(owner,spender) RPC call. ' +
5
+ 'Use this before executing transferFrom or to verify approvals. ' +
6
+ 'Returns the allowance amount in raw token units.',
7
+ category: 'live',
8
+ schema: {
9
+ owner: addressParam.describe('Token owner address'),
10
+ spender: addressParam.describe('Approved spender address'),
11
+ token: addressParam.describe('ERC20 token contract address'),
12
+ network: networkParam,
13
+ },
14
+ handler: async (input, client) => {
15
+ const res = await client.get('/api/chain/allowance', {
16
+ owner: input.owner,
17
+ spender: input.spender,
18
+ token: input.token,
19
+ network: input.network,
20
+ });
21
+ return formatResponse(res);
22
+ },
23
+ };
24
+ //# sourceMappingURL=allowance.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"allowance.js","sourceRoot":"","sources":["../../../src/tools/live/allowance.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE5E,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,mBAAmB;IACzB,WAAW,EACT,oGAAoG;QACpG,iEAAiE;QACjE,kDAAkD;IACpD,QAAQ,EAAE,MAAM;IAChB,MAAM,EAAE;QACN,KAAK,EAAE,YAAY,CAAC,QAAQ,CAAC,qBAAqB,CAAC;QACnD,OAAO,EAAE,YAAY,CAAC,QAAQ,CAAC,0BAA0B,CAAC;QAC1D,KAAK,EAAE,YAAY,CAAC,QAAQ,CAAC,8BAA8B,CAAC;QAC5D,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,sBAAsB,EAAE;YACnD,KAAK,EAAE,KAAK,CAAC,KAAe;YAC5B,OAAO,EAAE,KAAK,CAAC,OAAiB;YAChC,KAAK,EAAE,KAAK,CAAC,KAAe;YAC5B,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 1s_contract_info_live — Detect contract type and supported interfaces.
3
+ */
4
+ import type { ToolDef } from '../../types.js';
5
+ export declare const tool: ToolDef;
6
+ //# sourceMappingURL=contract-info.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contract-info.d.ts","sourceRoot":"","sources":["../../../src/tools/live/contract-info.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAiBlB,CAAC"}
@@ -0,0 +1,19 @@
1
+ import { networkParam, formatResponse, addressParam, safePath } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_contract_info_live',
4
+ description: 'Detect contract type and supported interfaces via eth_getCode and ERC165 supportsInterface. ' +
5
+ 'Use this for real-time standard detection; use 1s_contract_info for indexed metadata. ' +
6
+ 'Returns detected standards (ERC20, ERC721, ERC1155, ERC165).',
7
+ category: 'live',
8
+ schema: {
9
+ address: addressParam,
10
+ network: networkParam,
11
+ },
12
+ handler: async (input, client) => {
13
+ const res = await client.get(`/api/chain/contract/${safePath(input.address)}`, {
14
+ network: input.network,
15
+ });
16
+ return formatResponse(res);
17
+ },
18
+ };
19
+ //# sourceMappingURL=contract-info.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contract-info.js","sourceRoot":"","sources":["../../../src/tools/live/contract-info.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAEtF,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,uBAAuB;IAC7B,WAAW,EACT,8FAA8F;QAC9F,wFAAwF;QACxF,8DAA8D;IAChE,QAAQ,EAAE,MAAM;IAChB,MAAM,EAAE;QACN,OAAO,EAAE,YAAY;QACrB,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,uBAAuB,QAAQ,CAAC,KAAK,CAAC,OAAiB,CAAC,EAAE,EAAE;YACvF,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 1s_erc1155_balance_live — Get real-time ERC1155 token balance from the blockchain.
3
+ */
4
+ import type { ToolDef } from '../../types.js';
5
+ export declare const tool: ToolDef;
6
+ //# sourceMappingURL=erc1155-balance.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"erc1155-balance.d.ts","sourceRoot":"","sources":["../../../src/tools/live/erc1155-balance.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAsBlB,CAAC"}
@@ -0,0 +1,24 @@
1
+ import { networkParam, formatResponse, addressParam, tokenIdParam } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_erc1155_balance_live',
4
+ description: 'Get real-time ERC1155 token balance via balanceOf(address,uint256) RPC call. ' +
5
+ 'Use this when you need guaranteed current balance; use 1s_erc1155_balance for cached lookups. ' +
6
+ 'Returns the raw balance as a numeric string.',
7
+ category: 'live',
8
+ schema: {
9
+ account: addressParam.describe('Wallet address to check balance for'),
10
+ contract: addressParam.describe('ERC1155 contract address'),
11
+ token_id: tokenIdParam,
12
+ network: networkParam,
13
+ },
14
+ handler: async (input, client) => {
15
+ const res = await client.get('/api/chain/erc1155-balance', {
16
+ account: input.account,
17
+ contract: input.contract,
18
+ token_id: input.token_id,
19
+ network: input.network,
20
+ });
21
+ return formatResponse(res);
22
+ },
23
+ };
24
+ //# sourceMappingURL=erc1155-balance.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"erc1155-balance.js","sourceRoot":"","sources":["../../../src/tools/live/erc1155-balance.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE1F,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,yBAAyB;IAC/B,WAAW,EACT,+EAA+E;QAC/E,gGAAgG;QAChG,8CAA8C;IAChD,QAAQ,EAAE,MAAM;IAChB,MAAM,EAAE;QACN,OAAO,EAAE,YAAY,CAAC,QAAQ,CAAC,qCAAqC,CAAC;QACrE,QAAQ,EAAE,YAAY,CAAC,QAAQ,CAAC,0BAA0B,CAAC;QAC3D,QAAQ,EAAE,YAAY;QACtB,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,4BAA4B,EAAE;YACzD,OAAO,EAAE,KAAK,CAAC,OAAiB;YAChC,QAAQ,EAAE,KAAK,CAAC,QAAkB;YAClC,QAAQ,EAAE,KAAK,CAAC,QAAkB;YAClC,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 1s_erc20_balance_live — Get real-time ERC20 token balance from the blockchain.
3
+ */
4
+ import type { ToolDef } from '../../types.js';
5
+ export declare const tool: ToolDef;
6
+ //# sourceMappingURL=erc20-balance.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"erc20-balance.d.ts","sourceRoot":"","sources":["../../../src/tools/live/erc20-balance.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAoBlB,CAAC"}
@@ -0,0 +1,22 @@
1
+ import { networkParam, formatResponse, addressParam } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_erc20_balance_live',
4
+ description: 'Get real-time ERC20 token balance directly from the blockchain via balanceOf. ' +
5
+ 'Use this for pre-transaction checks or when zero indexing delay is needed; use 1s_erc20_balance for cheaper cached lookups. ' +
6
+ 'Returns raw token units (divide by 10^decimals); non-standard tokens may return empty name/symbol.',
7
+ category: 'live',
8
+ schema: {
9
+ account: addressParam.describe('Wallet address to check balance for'),
10
+ token: addressParam.describe('ERC20 token contract address'),
11
+ network: networkParam,
12
+ },
13
+ handler: async (input, client) => {
14
+ const res = await client.get('/api/chain/erc20-balance', {
15
+ account: input.account,
16
+ token: input.token,
17
+ network: input.network,
18
+ });
19
+ return formatResponse(res);
20
+ },
21
+ };
22
+ //# sourceMappingURL=erc20-balance.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"erc20-balance.js","sourceRoot":"","sources":["../../../src/tools/live/erc20-balance.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE5E,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,uBAAuB;IAC7B,WAAW,EACT,gFAAgF;QAChF,8HAA8H;QAC9H,oGAAoG;IACtG,QAAQ,EAAE,MAAM;IAChB,MAAM,EAAE;QACN,OAAO,EAAE,YAAY,CAAC,QAAQ,CAAC,qCAAqC,CAAC;QACrE,KAAK,EAAE,YAAY,CAAC,QAAQ,CAAC,8BAA8B,CAAC;QAC5D,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,0BAA0B,EAAE;YACvD,OAAO,EAAE,KAAK,CAAC,OAAiB;YAChC,KAAK,EAAE,KAAK,CAAC,KAAe;YAC5B,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,3 @@
1
+ import type { ToolDef } from '../../types.js';
2
+ export declare const tool: ToolDef;
3
+ //# sourceMappingURL=erc20-transfers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"erc20-transfers.d.ts","sourceRoot":"","sources":["../../../src/tools/live/erc20-transfers.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAwBlB,CAAC"}
@@ -0,0 +1,26 @@
1
+ import { networkParam, formatResponse, optionalAddressParam, hexDataParam } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_erc20_transfers_live',
4
+ description: 'Query ERC20 Transfer event logs via eth_getLogs. ' +
5
+ 'Use this for real-time transfer monitoring; use 1s_erc20_transfers for indexed transfer history. ' +
6
+ 'Block params are hex-encoded.',
7
+ category: 'live',
8
+ schema: {
9
+ token: optionalAddressParam.describe('ERC20 token contract address'),
10
+ wallet: optionalAddressParam.describe('Wallet address to filter transfers'),
11
+ from_block: hexDataParam.optional().describe('Start block in hex (e.g. 0x1234)'),
12
+ to_block: hexDataParam.optional().describe('End block in hex'),
13
+ network: networkParam,
14
+ },
15
+ handler: async (input, client) => {
16
+ const res = await client.get('/api/chain/erc20-transfers', {
17
+ token: input.token,
18
+ wallet: input.wallet,
19
+ from_block: input.from_block,
20
+ to_block: input.to_block,
21
+ network: input.network,
22
+ });
23
+ return formatResponse(res);
24
+ },
25
+ };
26
+ //# sourceMappingURL=erc20-transfers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"erc20-transfers.js","sourceRoot":"","sources":["../../../src/tools/live/erc20-transfers.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,oBAAoB,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAElG,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,yBAAyB;IAC/B,WAAW,EACT,mDAAmD;QACnD,mGAAmG;QACnG,+BAA+B;IACjC,QAAQ,EAAE,MAAM;IAChB,MAAM,EAAE;QACN,KAAK,EAAE,oBAAoB,CAAC,QAAQ,CAAC,8BAA8B,CAAC;QACpE,MAAM,EAAE,oBAAoB,CAAC,QAAQ,CAAC,oCAAoC,CAAC;QAC3E,UAAU,EAAE,YAAY,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,kCAAkC,CAAC;QAChF,QAAQ,EAAE,YAAY,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,kBAAkB,CAAC;QAC9D,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,4BAA4B,EAAE;YACzD,KAAK,EAAE,KAAK,CAAC,KAA2B;YACxC,MAAM,EAAE,KAAK,CAAC,MAA4B;YAC1C,UAAU,EAAE,KAAK,CAAC,UAAgC;YAClD,QAAQ,EAAE,KAAK,CAAC,QAA8B;YAC9C,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 1s_erc721_tokens_live — Enumerate ERC721 tokens owned by an address.
3
+ */
4
+ import type { ToolDef } from '../../types.js';
5
+ export declare const tool: ToolDef;
6
+ //# sourceMappingURL=erc721-tokens.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"erc721-tokens.d.ts","sourceRoot":"","sources":["../../../src/tools/live/erc721-tokens.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAoBlB,CAAC"}
@@ -0,0 +1,22 @@
1
+ import { networkParam, formatResponse, addressParam } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_erc721_tokens_live',
4
+ description: 'Enumerate ERC721 tokens owned by an address via ERC721Enumerable. ' +
5
+ 'Only works for contracts that implement the Enumerable extension. ' +
6
+ 'Returns token IDs owned by the address.',
7
+ category: 'live',
8
+ schema: {
9
+ owner: addressParam.describe('Wallet address to enumerate tokens for'),
10
+ contract: addressParam.describe('ERC721 contract address'),
11
+ network: networkParam,
12
+ },
13
+ handler: async (input, client) => {
14
+ const res = await client.get('/api/chain/erc721-tokens', {
15
+ owner: input.owner,
16
+ contract: input.contract,
17
+ network: input.network,
18
+ });
19
+ return formatResponse(res);
20
+ },
21
+ };
22
+ //# sourceMappingURL=erc721-tokens.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"erc721-tokens.js","sourceRoot":"","sources":["../../../src/tools/live/erc721-tokens.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE5E,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,uBAAuB;IAC7B,WAAW,EACT,oEAAoE;QACpE,oEAAoE;QACpE,yCAAyC;IAC3C,QAAQ,EAAE,MAAM;IAChB,MAAM,EAAE;QACN,KAAK,EAAE,YAAY,CAAC,QAAQ,CAAC,wCAAwC,CAAC;QACtE,QAAQ,EAAE,YAAY,CAAC,QAAQ,CAAC,yBAAyB,CAAC;QAC1D,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,0BAA0B,EAAE;YACvD,KAAK,EAAE,KAAK,CAAC,KAAe;YAC5B,QAAQ,EAAE,KAAK,CAAC,QAAkB;YAClC,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,3 @@
1
+ import type { ToolDef } from '../../types.js';
2
+ export declare const tool: ToolDef;
3
+ //# sourceMappingURL=events.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../../../src/tools/live/events.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAwBlB,CAAC"}
@@ -0,0 +1,26 @@
1
+ import { networkParam, formatResponse, optionalAddressParam, hexDataParam } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_events_live',
4
+ description: 'Query raw event logs via eth_getLogs directly from the node. ' +
5
+ 'Use this for real-time or unindexed events; use 1s_events for decoded, searchable indexed events. ' +
6
+ 'Block params are hex-encoded (e.g. 0x1234).',
7
+ category: 'live',
8
+ schema: {
9
+ contract: optionalAddressParam.describe('Contract address to filter'),
10
+ topic: hexDataParam.optional().describe('Event topic0 hash (0x...)'),
11
+ from_block: hexDataParam.optional().describe('Start block in hex (e.g. 0x1234)'),
12
+ to_block: hexDataParam.optional().describe('End block in hex'),
13
+ network: networkParam,
14
+ },
15
+ handler: async (input, client) => {
16
+ const res = await client.get('/api/chain/events', {
17
+ contract: input.contract,
18
+ topic: input.topic,
19
+ from_block: input.from_block,
20
+ to_block: input.to_block,
21
+ network: input.network,
22
+ });
23
+ return formatResponse(res);
24
+ },
25
+ };
26
+ //# sourceMappingURL=events.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"events.js","sourceRoot":"","sources":["../../../src/tools/live/events.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,oBAAoB,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAElG,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,gBAAgB;IACtB,WAAW,EACT,+DAA+D;QAC/D,oGAAoG;QACpG,6CAA6C;IAC/C,QAAQ,EAAE,MAAM;IAChB,MAAM,EAAE;QACN,QAAQ,EAAE,oBAAoB,CAAC,QAAQ,CAAC,4BAA4B,CAAC;QACrE,KAAK,EAAE,YAAY,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,2BAA2B,CAAC;QACpE,UAAU,EAAE,YAAY,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,kCAAkC,CAAC;QAChF,QAAQ,EAAE,YAAY,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,kBAAkB,CAAC;QAC9D,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,mBAAmB,EAAE;YAChD,QAAQ,EAAE,KAAK,CAAC,QAA8B;YAC9C,KAAK,EAAE,KAAK,CAAC,KAA2B;YACxC,UAAU,EAAE,KAAK,CAAC,UAAgC;YAClD,QAAQ,EAAE,KAAK,CAAC,QAA8B;YAC9C,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,3 @@
1
+ import type { ToolDef } from '../../types.js';
2
+ export declare const tool: ToolDef;
3
+ //# sourceMappingURL=multi-balance.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"multi-balance.d.ts","sourceRoot":"","sources":["../../../src/tools/live/multi-balance.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAoBlB,CAAC"}
@@ -0,0 +1,26 @@
1
+ /**
2
+ * 1s_multi_balance_live — Get ETH and multiple ERC20 balances in a single call.
3
+ */
4
+ import { z } from 'zod';
5
+ import { networkParam, formatResponse, addressParam } from '../../types.js';
6
+ export const tool = {
7
+ name: '1s_multi_balance_live',
8
+ description: 'Get ETH and multiple ERC20 balances in a single batched RPC call. ' +
9
+ 'Use this to check a wallet\'s holdings across multiple tokens efficiently. ' +
10
+ 'Individual token errors are returned per-token without failing the entire request.',
11
+ category: 'live',
12
+ schema: {
13
+ address: addressParam,
14
+ tokens: z.string().regex(/^(0x[a-fA-F0-9]{40})(,0x[a-fA-F0-9]{40})*$/, 'Comma-separated 0x addresses').optional().describe('Comma-separated ERC20 contract addresses'),
15
+ network: networkParam,
16
+ },
17
+ handler: async (input, client) => {
18
+ const res = await client.get('/api/chain/live-balance', {
19
+ address: input.address,
20
+ tokens: input.tokens,
21
+ network: input.network,
22
+ });
23
+ return formatResponse(res);
24
+ },
25
+ };
26
+ //# sourceMappingURL=multi-balance.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"multi-balance.js","sourceRoot":"","sources":["../../../src/tools/live/multi-balance.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE5E,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,uBAAuB;IAC7B,WAAW,EACT,oEAAoE;QACpE,6EAA6E;QAC7E,oFAAoF;IACtF,QAAQ,EAAE,MAAM;IAChB,MAAM,EAAE;QACN,OAAO,EAAE,YAAY;QACrB,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,4CAA4C,EAAE,8BAA8B,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,0CAA0C,CAAC;QACtK,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,yBAAyB,EAAE;YACtD,OAAO,EAAE,KAAK,CAAC,OAAiB;YAChC,MAAM,EAAE,KAAK,CAAC,MAA4B;YAC1C,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 1s_nft_metadata_live — Fetch NFT metadata directly from the blockchain.
3
+ */
4
+ import type { ToolDef } from '../../types.js';
5
+ export declare const tool: ToolDef;
6
+ //# sourceMappingURL=nft-metadata.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nft-metadata.d.ts","sourceRoot":"","sources":["../../../src/tools/live/nft-metadata.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAoBlB,CAAC"}
@@ -0,0 +1,22 @@
1
+ import { networkParam, formatResponse, addressParam, tokenIdParam } from '../../types.js';
2
+ export const tool = {
3
+ name: '1s_nft_metadata_live',
4
+ description: 'Fetch NFT metadata directly from the blockchain via tokenURI/uri RPC call. ' +
5
+ 'Resolves all URI formats: ipfs://, ar://, data: URIs, bare CIDs, and ERC1155 {id} templates. ' +
6
+ 'Use this for freshest metadata; use 1s_nft_metadata for cached lookups.',
7
+ category: 'live',
8
+ schema: {
9
+ contract: addressParam.describe('NFT contract address'),
10
+ token_id: tokenIdParam,
11
+ network: networkParam,
12
+ },
13
+ handler: async (input, client) => {
14
+ const res = await client.get('/api/chain/nft-metadata', {
15
+ contract: input.contract,
16
+ token_id: input.token_id,
17
+ network: input.network,
18
+ });
19
+ return formatResponse(res);
20
+ },
21
+ };
22
+ //# sourceMappingURL=nft-metadata.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nft-metadata.js","sourceRoot":"","sources":["../../../src/tools/live/nft-metadata.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE1F,MAAM,CAAC,MAAM,IAAI,GAAY;IAC3B,IAAI,EAAE,sBAAsB;IAC5B,WAAW,EACT,6EAA6E;QAC7E,+FAA+F;QAC/F,yEAAyE;IAC3E,QAAQ,EAAE,MAAM;IAChB,MAAM,EAAE;QACN,QAAQ,EAAE,YAAY,CAAC,QAAQ,CAAC,sBAAsB,CAAC;QACvD,QAAQ,EAAE,YAAY;QACtB,OAAO,EAAE,YAAY;KACtB;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAC/B,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,yBAAyB,EAAE;YACtD,QAAQ,EAAE,KAAK,CAAC,QAAkB;YAClC,QAAQ,EAAE,KAAK,CAAC,QAAkB;YAClC,OAAO,EAAE,KAAK,CAAC,OAA6B;SAC7C,CAAC,CAAC;QACH,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;CACF,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 1s_nft_owner_live — Get the current NFT owner from the blockchain.
3
+ */
4
+ import type { ToolDef } from '../../types.js';
5
+ export declare const tool: ToolDef;
6
+ //# sourceMappingURL=nft-owner.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nft-owner.d.ts","sourceRoot":"","sources":["../../../src/tools/live/nft-owner.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,eAAO,MAAM,IAAI,EAAE,OAoBlB,CAAC"}