@gala-chain/launchpad-sdk 6.0.0 → 7.0.0-beta.2

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 (1686) hide show
  1. package/EXAMPLES.md +159 -156
  2. package/LICENSE +21 -0
  3. package/README.md +56 -3338
  4. package/dist/LaunchpadSDK.d.ts +113 -1811
  5. package/dist/LaunchpadSDK.d.ts.map +1 -1
  6. package/dist/api/LaunchpadAPI.d.ts +21 -69
  7. package/dist/api/LaunchpadAPI.d.ts.map +1 -1
  8. package/dist/api/dto/BondingCurveDTOs.d.ts +8 -8
  9. package/dist/api/dto/BondingCurveDTOs.d.ts.map +1 -1
  10. package/dist/api/dto/BurnTokensDto.d.ts +2 -14
  11. package/dist/api/dto/BurnTokensDto.d.ts.map +1 -1
  12. package/dist/api/dto/LockTokenDto.d.ts +2 -14
  13. package/dist/api/dto/LockTokenDto.d.ts.map +1 -1
  14. package/dist/api/dto/TransferTokenDto.d.ts +2 -14
  15. package/dist/api/dto/TransferTokenDto.d.ts.map +1 -1
  16. package/dist/api/dto/UnlockTokenDto.d.ts +2 -14
  17. package/dist/api/dto/UnlockTokenDto.d.ts.map +1 -1
  18. package/dist/bridge/BridgeService.d.ts.map +1 -1
  19. package/dist/bridge/constants/tokens.d.ts +1 -1
  20. package/dist/bridge/index.d.ts +1 -1
  21. package/dist/bridge/index.d.ts.map +1 -1
  22. package/dist/bridge/public-types.d.ts +2 -0
  23. package/dist/bridge/public-types.d.ts.map +1 -0
  24. package/dist/bridge/strategies/BridgeStrategy.d.ts +44 -0
  25. package/dist/bridge/strategies/BridgeStrategy.d.ts.map +1 -1
  26. package/dist/bridge/strategies/EthereumBridgeStrategy.d.ts +4 -26
  27. package/dist/bridge/strategies/EthereumBridgeStrategy.d.ts.map +1 -1
  28. package/dist/bridge/strategies/SolanaBridgeStrategy.d.ts +4 -26
  29. package/dist/bridge/strategies/SolanaBridgeStrategy.d.ts.map +1 -1
  30. package/dist/bridge/utils/bridgePayload.d.ts.map +1 -1
  31. package/dist/bridge/utils/bridgeStatusParser.d.ts +5 -4
  32. package/dist/bridge/utils/bridgeStatusParser.d.ts.map +1 -1
  33. package/dist/bridge/utils/strategyDelegation.d.ts +57 -0
  34. package/dist/bridge/utils/strategyDelegation.d.ts.map +1 -1
  35. package/dist/config/environments.d.ts +19 -33
  36. package/dist/config/environments.d.ts.map +1 -1
  37. package/dist/constants/bondingCurve.d.ts +10 -10
  38. package/dist/constants/bondingCurve.d.ts.map +1 -1
  39. package/dist/constants/endpoints.d.ts +23 -58
  40. package/dist/constants/endpoints.d.ts.map +1 -1
  41. package/dist/constants/sdk-defaults.d.ts +0 -2
  42. package/dist/constants/sdk-defaults.d.ts.map +1 -1
  43. package/dist/constants/version.generated.d.ts +3 -3
  44. package/dist/constants/version.generated.d.ts.map +1 -1
  45. package/dist/errors/LaunchpadSDKError.d.ts +28 -0
  46. package/dist/errors/LaunchpadSDKError.d.ts.map +1 -0
  47. package/dist/errors/index.d.ts +3 -0
  48. package/dist/errors/index.d.ts.map +1 -0
  49. package/dist/helpers/sdk.d.ts +8 -8
  50. package/dist/helpers/sdk.d.ts.map +1 -1
  51. package/dist/index.browser.d.ts +21 -23
  52. package/dist/index.browser.d.ts.map +1 -1
  53. package/dist/index.browser.esm.js +1 -1
  54. package/dist/index.cjs +1 -1
  55. package/dist/index.d.ts +1 -1
  56. package/dist/index.d.ts.map +1 -1
  57. package/dist/index.esm.js +1 -1
  58. package/dist/index.js +1 -1
  59. package/dist/launchpad/bundle-submission.d.ts +88 -0
  60. package/dist/launchpad/bundle-submission.d.ts.map +1 -0
  61. package/dist/launchpad/strings-instructions.d.ts +15 -0
  62. package/dist/launchpad/strings-instructions.d.ts.map +1 -0
  63. package/dist/launchpad/transport.d.ts +28 -0
  64. package/dist/launchpad/transport.d.ts.map +1 -0
  65. package/dist/launchpad/writes.d.ts +74 -0
  66. package/dist/launchpad/writes.d.ts.map +1 -0
  67. package/dist/native.cjs +1 -1
  68. package/dist/native.d.ts +3 -0
  69. package/dist/native.d.ts.map +1 -1
  70. package/dist/native.esm.js +1 -1
  71. package/dist/polyfills/file-global.d.ts +4 -0
  72. package/dist/polyfills/file-global.d.ts.map +1 -1
  73. package/dist/react.cjs +1 -1
  74. package/dist/react.esm.js +1 -1
  75. package/dist/schemas/files.d.ts +2 -2
  76. package/dist/schemas/files.d.ts.map +1 -1
  77. package/dist/schemas/pagination.d.ts +0 -3
  78. package/dist/schemas/pagination.d.ts.map +1 -1
  79. package/dist/services/BanService.d.ts.map +1 -1
  80. package/dist/services/BaseService.d.ts +1 -1
  81. package/dist/services/BaseService.d.ts.map +1 -1
  82. package/dist/services/BatchedCacheService.d.ts.map +1 -1
  83. package/dist/services/BundleService.d.ts +1 -1
  84. package/dist/services/BundleService.d.ts.map +1 -1
  85. package/dist/services/BundlerClientFactory.d.ts +3 -3
  86. package/dist/services/BundlerClientFactory.d.ts.map +1 -1
  87. package/dist/services/ContentFlagService.d.ts +1 -0
  88. package/dist/services/ContentFlagService.d.ts.map +1 -1
  89. package/dist/services/DexService.d.ts +1 -1
  90. package/dist/services/DexService.d.ts.map +1 -1
  91. package/dist/services/GalaChainLockService.d.ts +4 -1
  92. package/dist/services/GalaChainLockService.d.ts.map +1 -1
  93. package/dist/services/GalaChainTokenService.d.ts +1 -0
  94. package/dist/services/GalaChainTokenService.d.ts.map +1 -1
  95. package/dist/services/GalaChainTransferService.d.ts +10 -5
  96. package/dist/services/GalaChainTransferService.d.ts.map +1 -1
  97. package/dist/services/GdexStreamService.d.ts +3 -1
  98. package/dist/services/GdexStreamService.d.ts.map +1 -1
  99. package/dist/services/HolderService.d.ts.map +1 -1
  100. package/dist/services/LaunchpadService.d.ts +3 -35
  101. package/dist/services/LaunchpadService.d.ts.map +1 -1
  102. package/dist/services/OEmbedService.d.ts +2 -2
  103. package/dist/services/OEmbedService.d.ts.map +1 -1
  104. package/dist/services/PoolService.d.ts +9 -20
  105. package/dist/services/PoolService.d.ts.map +1 -1
  106. package/dist/services/PriceHistoryService.d.ts +6 -4
  107. package/dist/services/PriceHistoryService.d.ts.map +1 -1
  108. package/dist/services/StreamChatService.d.ts +3 -101
  109. package/dist/services/StreamChatService.d.ts.map +1 -1
  110. package/dist/services/StreamTokenServiceBase.d.ts.map +1 -1
  111. package/dist/services/StreamWebSocketService.d.ts +5 -2
  112. package/dist/services/StreamWebSocketService.d.ts.map +1 -1
  113. package/dist/services/StreamingEventService.d.ts +1 -1
  114. package/dist/services/StreamingEventService.d.ts.map +1 -1
  115. package/dist/services/StreamingService.d.ts +4 -20
  116. package/dist/services/StreamingService.d.ts.map +1 -1
  117. package/dist/services/TokenMetadataCache.d.ts.map +1 -1
  118. package/dist/services/TokenMetadataService.d.ts +1 -1
  119. package/dist/services/TokenMetadataService.d.ts.map +1 -1
  120. package/dist/services/TokenResolverService.d.ts +5 -0
  121. package/dist/services/TokenResolverService.d.ts.map +1 -1
  122. package/dist/services/TradeService.d.ts.map +1 -1
  123. package/dist/services/UserService.d.ts +1 -62
  124. package/dist/services/UserService.d.ts.map +1 -1
  125. package/dist/services/WebSocketAdminService.d.ts.map +1 -1
  126. package/dist/services/WebSocketService.d.ts +1 -1
  127. package/dist/services/WebSocketService.d.ts.map +1 -1
  128. package/dist/services/WrapService.d.ts +10 -11
  129. package/dist/services/WrapService.d.ts.map +1 -1
  130. package/dist/services/WrappableTokenCache.d.ts.map +1 -1
  131. package/dist/services/WrappableTokenService.d.ts +1 -1
  132. package/dist/services/WrappableTokenService.d.ts.map +1 -1
  133. package/dist/services/__mocks__/logger.mock.d.ts.map +1 -1
  134. package/dist/services/shared/http-helpers.d.ts +1 -1
  135. package/dist/services/shared/http-helpers.d.ts.map +1 -1
  136. package/dist/services/shared/pagination-helpers.d.ts.map +1 -1
  137. package/dist/services/shared/service-validators.d.ts +1 -1
  138. package/dist/services/shared/service-validators.d.ts.map +1 -1
  139. package/dist/services/shared/websocket-helpers.d.ts.map +1 -1
  140. package/dist/signing/eip712.d.ts +13 -0
  141. package/dist/signing/eip712.d.ts.map +1 -0
  142. package/dist/signing/index.d.ts +5 -0
  143. package/dist/signing/index.d.ts.map +1 -0
  144. package/dist/signing/signers.d.ts +81 -0
  145. package/dist/signing/signers.d.ts.map +1 -0
  146. package/dist/signing/types.d.ts +31 -0
  147. package/dist/signing/types.d.ts.map +1 -0
  148. package/dist/tokens/transfers.d.ts +91 -0
  149. package/dist/tokens/transfers.d.ts.map +1 -0
  150. package/dist/types/api-key.dto.d.ts.map +1 -1
  151. package/dist/types/backend-responses.d.ts +8 -31
  152. package/dist/types/backend-responses.d.ts.map +1 -1
  153. package/dist/types/ban.dto.d.ts +14 -23
  154. package/dist/types/ban.dto.d.ts.map +1 -1
  155. package/dist/types/chat-messages.dto.d.ts.map +1 -1
  156. package/dist/types/comments.dto.d.ts +5 -26
  157. package/dist/types/comments.dto.d.ts.map +1 -1
  158. package/dist/types/common.d.ts +4 -3
  159. package/dist/types/common.d.ts.map +1 -1
  160. package/dist/types/content-flag.dto.d.ts.map +1 -1
  161. package/dist/types/dto.d.ts +6 -0
  162. package/dist/types/dto.d.ts.map +1 -1
  163. package/dist/types/engagement-stats.dto.d.ts +2 -3
  164. package/dist/types/engagement-stats.dto.d.ts.map +1 -1
  165. package/dist/types/galachain-api.types.d.ts.map +1 -1
  166. package/dist/types/launchpad.dto.d.ts +7 -73
  167. package/dist/types/launchpad.dto.d.ts.map +1 -1
  168. package/dist/types/messages.dto.d.ts.map +1 -1
  169. package/dist/types/moderator.dto.d.ts +10 -18
  170. package/dist/types/moderator.dto.d.ts.map +1 -1
  171. package/dist/types/options.dto.d.ts +2 -13
  172. package/dist/types/options.dto.d.ts.map +1 -1
  173. package/dist/types/overseer.dto.d.ts +1 -2
  174. package/dist/types/overseer.dto.d.ts.map +1 -1
  175. package/dist/types/priceHistory.dto.d.ts +15 -46
  176. package/dist/types/priceHistory.dto.d.ts.map +1 -1
  177. package/dist/types/session-auth.dto.d.ts +4 -8
  178. package/dist/types/session-auth.dto.d.ts.map +1 -1
  179. package/dist/types/stream-chat.dto.d.ts +14 -105
  180. package/dist/types/stream-chat.dto.d.ts.map +1 -1
  181. package/dist/types/streaming.dto.d.ts +30 -119
  182. package/dist/types/streaming.dto.d.ts.map +1 -1
  183. package/dist/types/token-ban.dto.d.ts +5 -9
  184. package/dist/types/token-ban.dto.d.ts.map +1 -1
  185. package/dist/types/token-config.dto.d.ts +2 -3
  186. package/dist/types/token-config.dto.d.ts.map +1 -1
  187. package/dist/types/token.types.d.ts +50 -27
  188. package/dist/types/token.types.d.ts.map +1 -1
  189. package/dist/types/trade.dto.d.ts +2 -3
  190. package/dist/types/trade.dto.d.ts.map +1 -1
  191. package/dist/types/transfer.dto.d.ts +2 -16
  192. package/dist/types/transfer.dto.d.ts.map +1 -1
  193. package/dist/types/user.dto.d.ts +4 -6
  194. package/dist/types/user.dto.d.ts.map +1 -1
  195. package/dist/utils/ReconnectionManager.d.ts +0 -1
  196. package/dist/utils/ReconnectionManager.d.ts.map +1 -1
  197. package/dist/utils/adapters.d.ts +1 -1
  198. package/dist/utils/adapters.d.ts.map +1 -1
  199. package/dist/utils/agent-config.d.ts +17 -14
  200. package/dist/utils/agent-config.d.ts.map +1 -1
  201. package/dist/utils/amount-validator.d.ts +1 -1
  202. package/dist/utils/api-patterns.d.ts.map +1 -1
  203. package/dist/utils/async-patterns.d.ts.map +1 -1
  204. package/dist/utils/auto-pagination.d.ts +2 -2
  205. package/dist/utils/auto-pagination.d.ts.map +1 -1
  206. package/dist/utils/bignumber-helpers.d.ts +7 -4
  207. package/dist/utils/bignumber-helpers.d.ts.map +1 -1
  208. package/dist/utils/bondingCurveCalculations.d.ts +6 -19
  209. package/dist/utils/bondingCurveCalculations.d.ts.map +1 -1
  210. package/dist/utils/crypto-compat.d.ts.map +1 -1
  211. package/dist/utils/data-transform-patterns.d.ts +2 -8
  212. package/dist/utils/data-transform-patterns.d.ts.map +1 -1
  213. package/dist/utils/delimiter-parser.d.ts.map +1 -1
  214. package/dist/utils/error-factories.d.ts.map +1 -1
  215. package/dist/utils/error-handling-patterns.d.ts +2 -4
  216. package/dist/utils/error-handling-patterns.d.ts.map +1 -1
  217. package/dist/utils/error-patterns.d.ts +3 -2
  218. package/dist/utils/error-patterns.d.ts.map +1 -1
  219. package/dist/utils/error-utils.d.ts +0 -4
  220. package/dist/utils/error-utils.d.ts.map +1 -1
  221. package/dist/utils/errors.d.ts +8 -7
  222. package/dist/utils/errors.d.ts.map +1 -1
  223. package/dist/utils/http.d.ts +8 -19
  224. package/dist/utils/http.d.ts.map +1 -1
  225. package/dist/utils/message-validators.d.ts +13 -0
  226. package/dist/utils/message-validators.d.ts.map +1 -0
  227. package/dist/utils/object-extractors.d.ts +1 -1
  228. package/dist/utils/object-patterns.d.ts +1 -1
  229. package/dist/utils/object-patterns.d.ts.map +1 -1
  230. package/dist/utils/pagination-helpers.d.ts +1 -1
  231. package/dist/utils/pagination-helpers.d.ts.map +1 -1
  232. package/dist/utils/service-validators.d.ts.map +1 -1
  233. package/dist/utils/string-transforms.d.ts +1 -1
  234. package/dist/utils/token-format-converter.d.ts +3 -3
  235. package/dist/utils/token-format-converter.d.ts.map +1 -1
  236. package/dist/utils/token-holder-transformer.d.ts +30 -0
  237. package/dist/utils/token-holder-transformer.d.ts.map +1 -0
  238. package/dist/utils/token-instance-key.d.ts +57 -0
  239. package/dist/utils/token-instance-key.d.ts.map +1 -0
  240. package/dist/utils/token-instance-resolver.d.ts +29 -0
  241. package/dist/utils/token-instance-resolver.d.ts.map +1 -0
  242. package/dist/utils/token-operation-details.d.ts +23 -0
  243. package/dist/utils/token-operation-details.d.ts.map +1 -0
  244. package/dist/utils/token-stringification.d.ts +0 -1
  245. package/dist/utils/token-stringification.d.ts.map +1 -1
  246. package/dist/utils/transfer-validation.d.ts +4 -4
  247. package/dist/utils/transfer-validation.d.ts.map +1 -1
  248. package/dist/utils/unique-key-generator.d.ts +31 -32
  249. package/dist/utils/unique-key-generator.d.ts.map +1 -1
  250. package/dist/utils/validation-patterns.d.ts +1 -6
  251. package/dist/utils/validation-patterns.d.ts.map +1 -1
  252. package/dist/utils/validation.d.ts.map +1 -1
  253. package/dist/utils/wallet.d.ts +2 -21
  254. package/dist/utils/wallet.d.ts.map +1 -1
  255. package/dist/utils/websocket-patterns.d.ts +3 -4
  256. package/dist/utils/websocket-patterns.d.ts.map +1 -1
  257. package/dist/wallet/ExternalWalletProvider.d.ts +2 -21
  258. package/dist/wallet/ExternalWalletProvider.d.ts.map +1 -1
  259. package/dist/wallet/GalaChainConnectProvider.d.ts +1 -1
  260. package/dist/wallet/GalaChainConnectProvider.d.ts.map +1 -1
  261. package/dist/wallet/GalaWalletProvider.d.ts +2 -21
  262. package/dist/wallet/GalaWalletProvider.d.ts.map +1 -1
  263. package/dist/wallet/detection.d.ts.map +1 -1
  264. package/dist/wallet/event-handlers.d.ts +50 -0
  265. package/dist/wallet/event-handlers.d.ts.map +1 -0
  266. package/dist/wallet/signing-operation.d.ts +19 -0
  267. package/dist/wallet/signing-operation.d.ts.map +1 -0
  268. package/dist/wallet/typed-data-helpers.d.ts +68 -0
  269. package/dist/wallet/typed-data-helpers.d.ts.map +1 -0
  270. package/dist/wallet.cjs +1 -1
  271. package/dist/wallet.esm.js +1 -1
  272. package/package.json +189 -186
  273. package/README.md.bak +0 -3174
  274. package/dist/ai-docs.json +0 -11904
  275. package/dist/examples/admin/api-key-advanced.d.ts +0 -43
  276. package/dist/examples/admin/api-key-advanced.d.ts.map +0 -1
  277. package/dist/examples/admin/moderator-invite-complete.d.ts +0 -41
  278. package/dist/examples/admin/moderator-invite-complete.d.ts.map +0 -1
  279. package/dist/examples/admin/overseer-management-advanced.d.ts +0 -38
  280. package/dist/examples/admin/overseer-management-advanced.d.ts.map +0 -1
  281. package/dist/examples/admin/overseer-page-stats.d.ts +0 -26
  282. package/dist/examples/admin/overseer-page-stats.d.ts.map +0 -1
  283. package/dist/examples/admin/token-ban-complete.d.ts +0 -44
  284. package/dist/examples/admin/token-ban-complete.d.ts.map +0 -1
  285. package/dist/examples/ai-moderation/ai-moderation-demo.d.ts +0 -32
  286. package/dist/examples/ai-moderation/ai-moderation-demo.d.ts.map +0 -1
  287. package/dist/examples/ai-moderation/flag-ai-verdicts-demo.d.ts +0 -30
  288. package/dist/examples/ai-moderation/flag-ai-verdicts-demo.d.ts.map +0 -1
  289. package/dist/examples/analytics/index.d.ts +0 -23
  290. package/dist/examples/analytics/index.d.ts.map +0 -1
  291. package/dist/examples/analytics/market-analysis-tools.d.ts +0 -28
  292. package/dist/examples/analytics/market-analysis-tools.d.ts.map +0 -1
  293. package/dist/examples/analytics/portfolio-performance-tracking.d.ts +0 -25
  294. package/dist/examples/analytics/portfolio-performance-tracking.d.ts.map +0 -1
  295. package/dist/examples/analytics/trading-analytics-advanced.d.ts +0 -27
  296. package/dist/examples/analytics/trading-analytics-advanced.d.ts.map +0 -1
  297. package/dist/examples/api-keys/advanced-configuration.d.ts +0 -19
  298. package/dist/examples/api-keys/advanced-configuration.d.ts.map +0 -1
  299. package/dist/examples/api-keys/complete-lifecycle.d.ts +0 -18
  300. package/dist/examples/api-keys/complete-lifecycle.d.ts.map +0 -1
  301. package/dist/examples/api-keys/crud.d.ts +0 -22
  302. package/dist/examples/api-keys/crud.d.ts.map +0 -1
  303. package/dist/examples/api-keys/token-delegation.d.ts +0 -24
  304. package/dist/examples/api-keys/token-delegation.d.ts.map +0 -1
  305. package/dist/examples/api-keys/user-api-key-auth.d.ts +0 -24
  306. package/dist/examples/api-keys/user-api-key-auth.d.ts.map +0 -1
  307. package/dist/examples/auth/auth-permissions-checking.d.ts +0 -32
  308. package/dist/examples/auth/auth-permissions-checking.d.ts.map +0 -1
  309. package/dist/examples/auth/auth-token-management.d.ts +0 -32
  310. package/dist/examples/auth/auth-token-management.d.ts.map +0 -1
  311. package/dist/examples/auth/auth-validation-workflows.d.ts +0 -32
  312. package/dist/examples/auth/auth-validation-workflows.d.ts.map +0 -1
  313. package/dist/examples/bans/ban-management.d.ts +0 -24
  314. package/dist/examples/bans/ban-management.d.ts.map +0 -1
  315. package/dist/examples/bans/demo-global-user-bans.d.ts +0 -27
  316. package/dist/examples/bans/demo-global-user-bans.d.ts.map +0 -1
  317. package/dist/examples/bonding/token-graduation-workflow.d.ts +0 -21
  318. package/dist/examples/bonding/token-graduation-workflow.d.ts.map +0 -1
  319. package/dist/examples/bonding-curve/basic-trading.d.ts +0 -20
  320. package/dist/examples/bonding-curve/basic-trading.d.ts.map +0 -1
  321. package/dist/examples/bonding-curve/graduation-workflow.d.ts +0 -18
  322. package/dist/examples/bonding-curve/graduation-workflow.d.ts.map +0 -1
  323. package/dist/examples/bonding-curve/pagination-variants.d.ts +0 -17
  324. package/dist/examples/bonding-curve/pagination-variants.d.ts.map +0 -1
  325. package/dist/examples/bonding-curve/pool-analysis.d.ts +0 -18
  326. package/dist/examples/bonding-curve/pool-analysis.d.ts.map +0 -1
  327. package/dist/examples/bonding-curve/pool-creator-filtering.d.ts +0 -17
  328. package/dist/examples/bonding-curve/pool-creator-filtering.d.ts.map +0 -1
  329. package/dist/examples/bonding-curve/pool-discovery.d.ts +0 -19
  330. package/dist/examples/bonding-curve/pool-discovery.d.ts.map +0 -1
  331. package/dist/examples/bonding-curve/price-impact.d.ts +0 -18
  332. package/dist/examples/bonding-curve/price-impact.d.ts.map +0 -1
  333. package/dist/examples/bonding-curve/token-launch.d.ts +0 -18
  334. package/dist/examples/bonding-curve/token-launch.d.ts.map +0 -1
  335. package/dist/examples/bonding-curve/user-holder-context.d.ts +0 -18
  336. package/dist/examples/bonding-curve/user-holder-context.d.ts.map +0 -1
  337. package/dist/examples/bonding-curve/volume-trading.d.ts +0 -18
  338. package/dist/examples/bonding-curve/volume-trading.d.ts.map +0 -1
  339. package/dist/examples/bridge/bridge-ethereum-specific.d.ts +0 -18
  340. package/dist/examples/bridge/bridge-ethereum-specific.d.ts.map +0 -1
  341. package/dist/examples/bridge/bridge-generic-operations.d.ts +0 -18
  342. package/dist/examples/bridge/bridge-generic-operations.d.ts.map +0 -1
  343. package/dist/examples/bridge/bridge-multi-chain-routing.d.ts +0 -31
  344. package/dist/examples/bridge/bridge-multi-chain-routing.d.ts.map +0 -1
  345. package/dist/examples/bridge/bridge-network-methods.d.ts +0 -31
  346. package/dist/examples/bridge/bridge-network-methods.d.ts.map +0 -1
  347. package/dist/examples/bridge/bridge-network-tokens.d.ts +0 -18
  348. package/dist/examples/bridge/bridge-network-tokens.d.ts.map +0 -1
  349. package/dist/examples/bridge/bridge-network-validation.d.ts +0 -33
  350. package/dist/examples/bridge/bridge-network-validation.d.ts.map +0 -1
  351. package/dist/examples/bridge/bridge-operations.d.ts +0 -27
  352. package/dist/examples/bridge/bridge-operations.d.ts.map +0 -1
  353. package/dist/examples/bridge/bridge-solana-specific.d.ts +0 -18
  354. package/dist/examples/bridge/bridge-solana-specific.d.ts.map +0 -1
  355. package/dist/examples/bridge/bridge-status-monitoring.d.ts +0 -30
  356. package/dist/examples/bridge/bridge-status-monitoring.d.ts.map +0 -1
  357. package/dist/examples/bridge/bridge-wrapped-token-operations.d.ts +0 -30
  358. package/dist/examples/bridge/bridge-wrapped-token-operations.d.ts.map +0 -1
  359. package/dist/examples/bridge/bridgeable-tokens.d.ts +0 -27
  360. package/dist/examples/bridge/bridgeable-tokens.d.ts.map +0 -1
  361. package/dist/examples/bridge/check-balances.d.ts +0 -13
  362. package/dist/examples/bridge/check-balances.d.ts.map +0 -1
  363. package/dist/examples/bridge/ethereum-in.d.ts +0 -17
  364. package/dist/examples/bridge/ethereum-in.d.ts.map +0 -1
  365. package/dist/examples/bridge/ethereum-out.d.ts +0 -17
  366. package/dist/examples/bridge/ethereum-out.d.ts.map +0 -1
  367. package/dist/examples/bridge/ethereum-roundtrip.d.ts +0 -20
  368. package/dist/examples/bridge/ethereum-roundtrip.d.ts.map +0 -1
  369. package/dist/examples/bridge/external-balances.d.ts +0 -29
  370. package/dist/examples/bridge/external-balances.d.ts.map +0 -1
  371. package/dist/examples/bridge/fee-estimation.d.ts +0 -14
  372. package/dist/examples/bridge/fee-estimation.d.ts.map +0 -1
  373. package/dist/examples/bridge/solana-in.d.ts +0 -18
  374. package/dist/examples/bridge/solana-in.d.ts.map +0 -1
  375. package/dist/examples/bridge/solana-out.d.ts +0 -18
  376. package/dist/examples/bridge/solana-out.d.ts.map +0 -1
  377. package/dist/examples/bridge/solana-roundtrip.d.ts +0 -21
  378. package/dist/examples/bridge/solana-roundtrip.d.ts.map +0 -1
  379. package/dist/examples/bridge/status-tracking.d.ts +0 -16
  380. package/dist/examples/bridge/status-tracking.d.ts.map +0 -1
  381. package/dist/examples/bridge/supported-tokens.d.ts +0 -14
  382. package/dist/examples/bridge/supported-tokens.d.ts.map +0 -1
  383. package/dist/examples/bridge/test-debug-unwrap.d.ts +0 -13
  384. package/dist/examples/bridge/test-debug-unwrap.d.ts.map +0 -1
  385. package/dist/examples/bridge/test-unwrap-execution.d.ts +0 -13
  386. package/dist/examples/bridge/test-unwrap-execution.d.ts.map +0 -1
  387. package/dist/examples/bridge/test-wrap-debug.d.ts +0 -13
  388. package/dist/examples/bridge/test-wrap-debug.d.ts.map +0 -1
  389. package/dist/examples/bridge/test-wrap-execution.d.ts +0 -13
  390. package/dist/examples/bridge/test-wrap-execution.d.ts.map +0 -1
  391. package/dist/examples/bridge/test-wrap-roundtrip.d.ts +0 -13
  392. package/dist/examples/bridge/test-wrap-roundtrip.d.ts.map +0 -1
  393. package/dist/examples/bridge/transaction-status.d.ts +0 -26
  394. package/dist/examples/bridge/transaction-status.d.ts.map +0 -1
  395. package/dist/examples/bridge/wallet-balances.d.ts +0 -24
  396. package/dist/examples/bridge/wallet-balances.d.ts.map +0 -1
  397. package/dist/examples/bridge/wrap-discovery.d.ts +0 -16
  398. package/dist/examples/bridge/wrap-discovery.d.ts.map +0 -1
  399. package/dist/examples/bridge/wrap-fee-estimation.d.ts +0 -16
  400. package/dist/examples/bridge/wrap-fee-estimation.d.ts.map +0 -1
  401. package/dist/examples/bridge/wrap-unwrap.d.ts +0 -18
  402. package/dist/examples/bridge/wrap-unwrap.d.ts.map +0 -1
  403. package/dist/examples/bridge/wrap-utilities.d.ts +0 -21
  404. package/dist/examples/bridge/wrap-utilities.d.ts.map +0 -1
  405. package/dist/examples/calculations/calculation-methods-comprehensive.d.ts +0 -24
  406. package/dist/examples/calculations/calculation-methods-comprehensive.d.ts.map +0 -1
  407. package/dist/examples/calculations/external-calculations-demo.d.ts +0 -23
  408. package/dist/examples/calculations/external-calculations-demo.d.ts.map +0 -1
  409. package/dist/examples/calculations/local-calculations-demo.d.ts +0 -24
  410. package/dist/examples/calculations/local-calculations-demo.d.ts.map +0 -1
  411. package/dist/examples/calculations/pool-calculation-context.d.ts +0 -19
  412. package/dist/examples/calculations/pool-calculation-context.d.ts.map +0 -1
  413. package/dist/examples/chat/basic-chat.d.ts +0 -17
  414. package/dist/examples/chat/basic-chat.d.ts.map +0 -1
  415. package/dist/examples/chat/chat-admin-controls.d.ts +0 -41
  416. package/dist/examples/chat/chat-admin-controls.d.ts.map +0 -1
  417. package/dist/examples/chat/chat-demo.d.ts +0 -25
  418. package/dist/examples/chat/chat-demo.d.ts.map +0 -1
  419. package/dist/examples/chat/chat-engagement-stats.d.ts +0 -44
  420. package/dist/examples/chat/chat-engagement-stats.d.ts.map +0 -1
  421. package/dist/examples/chat/chat-lifecycle.d.ts +0 -26
  422. package/dist/examples/chat/chat-lifecycle.d.ts.map +0 -1
  423. package/dist/examples/chat/chat-message-management.d.ts +0 -18
  424. package/dist/examples/chat/chat-message-management.d.ts.map +0 -1
  425. package/dist/examples/chat/chat-pinning-workflow.d.ts +0 -37
  426. package/dist/examples/chat/chat-pinning-workflow.d.ts.map +0 -1
  427. package/dist/examples/chat/demo-pin-messages.d.ts +0 -17
  428. package/dist/examples/chat/demo-pin-messages.d.ts.map +0 -1
  429. package/dist/examples/chat/multi-user-chat-test.d.ts +0 -19
  430. package/dist/examples/chat/multi-user-chat-test.d.ts.map +0 -1
  431. package/dist/examples/chat/quick-reaction-test.d.ts +0 -4
  432. package/dist/examples/chat/quick-reaction-test.d.ts.map +0 -1
  433. package/dist/examples/chat/typing-indicators.d.ts +0 -23
  434. package/dist/examples/chat/typing-indicators.d.ts.map +0 -1
  435. package/dist/examples/chat/websocket-chat.d.ts +0 -21
  436. package/dist/examples/chat/websocket-chat.d.ts.map +0 -1
  437. package/dist/examples/comments/basic-comments.d.ts +0 -19
  438. package/dist/examples/comments/basic-comments.d.ts.map +0 -1
  439. package/dist/examples/comments/comments-demo.d.ts +0 -34
  440. package/dist/examples/comments/comments-demo.d.ts.map +0 -1
  441. package/dist/examples/comments/comments-lifecycle.d.ts +0 -24
  442. package/dist/examples/comments/comments-lifecycle.d.ts.map +0 -1
  443. package/dist/examples/comments/comments-update-workflow.d.ts +0 -35
  444. package/dist/examples/comments/comments-update-workflow.d.ts.map +0 -1
  445. package/dist/examples/content/content-categorization.d.ts +0 -51
  446. package/dist/examples/content/content-categorization.d.ts.map +0 -1
  447. package/dist/examples/content/content-publishing-workflow.d.ts +0 -45
  448. package/dist/examples/content/content-publishing-workflow.d.ts.map +0 -1
  449. package/dist/examples/content/content-versioning.d.ts +0 -52
  450. package/dist/examples/content/content-versioning.d.ts.map +0 -1
  451. package/dist/examples/content-flags/comprehensive-flag-workflow.d.ts +0 -40
  452. package/dist/examples/content-flags/comprehensive-flag-workflow.d.ts.map +0 -1
  453. package/dist/examples/content-flags/flag-management.d.ts +0 -28
  454. package/dist/examples/content-flags/flag-management.d.ts.map +0 -1
  455. package/dist/examples/content-reactions/advanced-reactions.d.ts +0 -24
  456. package/dist/examples/content-reactions/advanced-reactions.d.ts.map +0 -1
  457. package/dist/examples/content-reactions/basic-reactions.d.ts +0 -21
  458. package/dist/examples/content-reactions/basic-reactions.d.ts.map +0 -1
  459. package/dist/examples/content-reactions/comprehensive-reactions-workflow.d.ts +0 -41
  460. package/dist/examples/content-reactions/comprehensive-reactions-workflow.d.ts.map +0 -1
  461. package/dist/examples/content-reactions/content-reactions-advanced.d.ts +0 -40
  462. package/dist/examples/content-reactions/content-reactions-advanced.d.ts.map +0 -1
  463. package/dist/examples/core/authenticated-operations.d.ts +0 -14
  464. package/dist/examples/core/authenticated-operations.d.ts.map +0 -1
  465. package/dist/examples/core/complete-sdk-demo.d.ts +0 -22
  466. package/dist/examples/core/complete-sdk-demo.d.ts.map +0 -1
  467. package/dist/examples/core/image-uploads.d.ts +0 -28
  468. package/dist/examples/core/image-uploads.d.ts.map +0 -1
  469. package/dist/examples/core/privatekey-override-pattern.d.ts +0 -16
  470. package/dist/examples/core/privatekey-override-pattern.d.ts.map +0 -1
  471. package/dist/examples/core/read-only-operations.d.ts +0 -16
  472. package/dist/examples/core/read-only-operations.d.ts.map +0 -1
  473. package/dist/examples/core/session-auth-demo.d.ts +0 -15
  474. package/dist/examples/core/session-auth-demo.d.ts.map +0 -1
  475. package/dist/examples/core/session-auth-lifecycle.d.ts +0 -19
  476. package/dist/examples/core/session-auth-lifecycle.d.ts.map +0 -1
  477. package/dist/examples/core/test-pagination-fix.d.ts +0 -14
  478. package/dist/examples/core/test-pagination-fix.d.ts.map +0 -1
  479. package/dist/examples/core/token-refresh-utilities.d.ts +0 -18
  480. package/dist/examples/core/token-refresh-utilities.d.ts.map +0 -1
  481. package/dist/examples/core/token-validation.d.ts +0 -18
  482. package/dist/examples/core/token-validation.d.ts.map +0 -1
  483. package/dist/examples/core/wallet-management.d.ts +0 -23
  484. package/dist/examples/core/wallet-management.d.ts.map +0 -1
  485. package/dist/examples/debug/check-recorded-bridge-tx.d.ts +0 -8
  486. package/dist/examples/debug/check-recorded-bridge-tx.d.ts.map +0 -1
  487. package/dist/examples/debug/debug-comment.d.ts +0 -2
  488. package/dist/examples/debug/debug-comment.d.ts.map +0 -1
  489. package/dist/examples/debug/test-volume-data-bounds-prod.d.ts +0 -15
  490. package/dist/examples/debug/test-volume-data-bounds-prod.d.ts.map +0 -1
  491. package/dist/examples/debug/test-volume-data-bounds.d.ts +0 -14
  492. package/dist/examples/debug/test-volume-data-bounds.d.ts.map +0 -1
  493. package/dist/examples/debug/websocket-event-discovery.d.ts +0 -26
  494. package/dist/examples/debug/websocket-event-discovery.d.ts.map +0 -1
  495. package/dist/examples/debug/websocket-monitor.d.ts +0 -15
  496. package/dist/examples/debug/websocket-monitor.d.ts.map +0 -1
  497. package/dist/examples/debug-single-trade.d.ts +0 -6
  498. package/dist/examples/debug-single-trade.d.ts.map +0 -1
  499. package/dist/examples/demo-librarian.d.ts +0 -18
  500. package/dist/examples/demo-librarian.d.ts.map +0 -1
  501. package/dist/examples/demo-runner.d.ts +0 -22
  502. package/dist/examples/demo-runner.d.ts.map +0 -1
  503. package/dist/examples/dex/demo-roundtrip-liquidity.d.ts +0 -16
  504. package/dist/examples/dex/demo-roundtrip-liquidity.d.ts.map +0 -1
  505. package/dist/examples/dex/dex-impermanent-loss-analysis.d.ts +0 -28
  506. package/dist/examples/dex/dex-impermanent-loss-analysis.d.ts.map +0 -1
  507. package/dist/examples/dex/dex-liquidity-management-advanced.d.ts +0 -27
  508. package/dist/examples/dex/dex-liquidity-management-advanced.d.ts.map +0 -1
  509. package/dist/examples/dex/dex-multi-hop-swaps.d.ts +0 -32
  510. package/dist/examples/dex/dex-multi-hop-swaps.d.ts.map +0 -1
  511. package/dist/examples/dex/dex-pool-pricing.d.ts +0 -20
  512. package/dist/examples/dex/dex-pool-pricing.d.ts.map +0 -1
  513. package/dist/examples/dex/dex-quote-calculations.d.ts +0 -21
  514. package/dist/examples/dex/dex-quote-calculations.d.ts.map +0 -1
  515. package/dist/examples/dex/dex-seasons-leaderboard.d.ts +0 -22
  516. package/dist/examples/dex/dex-seasons-leaderboard.d.ts.map +0 -1
  517. package/dist/examples/dex/dex-slippage-protection.d.ts +0 -28
  518. package/dist/examples/dex/dex-slippage-protection.d.ts.map +0 -1
  519. package/dist/examples/dex/dex-tokens-discovery.d.ts +0 -20
  520. package/dist/examples/dex/dex-tokens-discovery.d.ts.map +0 -1
  521. package/dist/examples/dex/dex-volume-analytics.d.ts +0 -19
  522. package/dist/examples/dex/dex-volume-analytics.d.ts.map +0 -1
  523. package/dist/examples/dex/leaderboard.d.ts +0 -12
  524. package/dist/examples/dex/leaderboard.d.ts.map +0 -1
  525. package/dist/examples/dex/pool-discovery.d.ts +0 -25
  526. package/dist/examples/dex/pool-discovery.d.ts.map +0 -1
  527. package/dist/examples/dex/pools-with-pricing.d.ts +0 -28
  528. package/dist/examples/dex/pools-with-pricing.d.ts.map +0 -1
  529. package/dist/examples/dex/quote-comparison.d.ts +0 -16
  530. package/dist/examples/dex/quote-comparison.d.ts.map +0 -1
  531. package/dist/examples/dex/swap-user-assets-comprehensive.d.ts +0 -20
  532. package/dist/examples/dex/swap-user-assets-comprehensive.d.ts.map +0 -1
  533. package/dist/examples/dex/swap-workflow.d.ts +0 -20
  534. package/dist/examples/dex/swap-workflow.d.ts.map +0 -1
  535. package/dist/examples/dex/token-discovery.d.ts +0 -27
  536. package/dist/examples/dex/token-discovery.d.ts.map +0 -1
  537. package/dist/examples/dex/volume-summary.d.ts +0 -12
  538. package/dist/examples/dex/volume-summary.d.ts.map +0 -1
  539. package/dist/examples/error-handling/error-recovery-patterns.d.ts +0 -42
  540. package/dist/examples/error-handling/error-recovery-patterns.d.ts.map +0 -1
  541. package/dist/examples/error-handling/timeout-management.d.ts +0 -43
  542. package/dist/examples/error-handling/timeout-management.d.ts.map +0 -1
  543. package/dist/examples/events/event-aggregation-analysis.d.ts +0 -40
  544. package/dist/examples/events/event-aggregation-analysis.d.ts.map +0 -1
  545. package/dist/examples/events/event-emission-patterns.d.ts +0 -35
  546. package/dist/examples/events/event-emission-patterns.d.ts.map +0 -1
  547. package/dist/examples/events/subscription-management-advanced.d.ts +0 -38
  548. package/dist/examples/events/subscription-management-advanced.d.ts.map +0 -1
  549. package/dist/examples/fees/complete-fee-test.d.ts +0 -13
  550. package/dist/examples/fees/complete-fee-test.d.ts.map +0 -1
  551. package/dist/examples/fees/demo-fee-generation-and-collection.d.ts +0 -27
  552. package/dist/examples/fees/demo-fee-generation-and-collection.d.ts.map +0 -1
  553. package/dist/examples/fees/demo-fees-high-volume.d.ts +0 -13
  554. package/dist/examples/fees/demo-fees-high-volume.d.ts.map +0 -1
  555. package/dist/examples/fees/demo-multi-wallet-fee-generation.d.ts +0 -13
  556. package/dist/examples/fees/demo-multi-wallet-fee-generation.d.ts.map +0 -1
  557. package/dist/examples/fees/trade-and-collect-fees.d.ts +0 -13
  558. package/dist/examples/fees/trade-and-collect-fees.d.ts.map +0 -1
  559. package/dist/examples/galachain/bundler-transactions.d.ts +0 -28
  560. package/dist/examples/galachain/bundler-transactions.d.ts.map +0 -1
  561. package/dist/examples/galachain/galachain-token-resolution.d.ts +0 -28
  562. package/dist/examples/galachain/galachain-token-resolution.d.ts.map +0 -1
  563. package/dist/examples/galachain/galachain-tokens.d.ts +0 -28
  564. package/dist/examples/galachain/galachain-tokens.d.ts.map +0 -1
  565. package/dist/examples/galachain/galachain-transfers.d.ts +0 -25
  566. package/dist/examples/galachain/galachain-transfers.d.ts.map +0 -1
  567. package/dist/examples/global-feed-demo.d.ts +0 -17
  568. package/dist/examples/global-feed-demo.d.ts.map +0 -1
  569. package/dist/examples/global-feed-filtering-demo.d.ts +0 -20
  570. package/dist/examples/global-feed-filtering-demo.d.ts.map +0 -1
  571. package/dist/examples/launchpad/demo-socials.d.ts +0 -16
  572. package/dist/examples/launchpad/demo-socials.d.ts.map +0 -1
  573. package/dist/examples/launchpad/fetch-token-stats.d.ts +0 -18
  574. package/dist/examples/launchpad/fetch-token-stats.d.ts.map +0 -1
  575. package/dist/examples/launchpad/update-token-config.d.ts +0 -17
  576. package/dist/examples/launchpad/update-token-config.d.ts.map +0 -1
  577. package/dist/examples/liquidity/apr-calculator.d.ts +0 -18
  578. package/dist/examples/liquidity/apr-calculator.d.ts.map +0 -1
  579. package/dist/examples/liquidity/demo-bundler-operations.d.ts +0 -15
  580. package/dist/examples/liquidity/demo-bundler-operations.d.ts.map +0 -1
  581. package/dist/examples/liquidity/demo-fetch-all-positions.d.ts +0 -2
  582. package/dist/examples/liquidity/demo-fetch-all-positions.d.ts.map +0 -1
  583. package/dist/examples/liquidity/demo-position-direct.d.ts +0 -14
  584. package/dist/examples/liquidity/demo-position-direct.d.ts.map +0 -1
  585. package/dist/examples/liquidity/demo-positions-with-chunked-pricing.d.ts +0 -26
  586. package/dist/examples/liquidity/demo-positions-with-chunked-pricing.d.ts.map +0 -1
  587. package/dist/examples/liquidity/demo-roundtrip-remove.d.ts +0 -21
  588. package/dist/examples/liquidity/demo-roundtrip-remove.d.ts.map +0 -1
  589. package/dist/examples/liquidity/detailed.d.ts +0 -21
  590. package/dist/examples/liquidity/detailed.d.ts.map +0 -1
  591. package/dist/examples/liquidity/errors.d.ts +0 -18
  592. package/dist/examples/liquidity/errors.d.ts.map +0 -1
  593. package/dist/examples/liquidity/fee-collection.d.ts +0 -22
  594. package/dist/examples/liquidity/fee-collection.d.ts.map +0 -1
  595. package/dist/examples/liquidity/liquidity-position-details.d.ts +0 -21
  596. package/dist/examples/liquidity/liquidity-position-details.d.ts.map +0 -1
  597. package/dist/examples/liquidity/liquidity-removal-estimation.d.ts +0 -19
  598. package/dist/examples/liquidity/liquidity-removal-estimation.d.ts.map +0 -1
  599. package/dist/examples/liquidity/multi-position.d.ts +0 -22
  600. package/dist/examples/liquidity/multi-position.d.ts.map +0 -1
  601. package/dist/examples/liquidity/positions-cli.d.ts +0 -41
  602. package/dist/examples/liquidity/positions-cli.d.ts.map +0 -1
  603. package/dist/examples/liquidity/ticks.d.ts +0 -18
  604. package/dist/examples/liquidity/ticks.d.ts.map +0 -1
  605. package/dist/examples/locks/burn-tokens.d.ts +0 -25
  606. package/dist/examples/locks/burn-tokens.d.ts.map +0 -1
  607. package/dist/examples/locks/lock-unlock-workflow.d.ts +0 -20
  608. package/dist/examples/locks/lock-unlock-workflow.d.ts.map +0 -1
  609. package/dist/examples/messages/messages-lifecycle.d.ts +0 -37
  610. package/dist/examples/messages/messages-lifecycle.d.ts.map +0 -1
  611. package/dist/examples/messages/messages-pinning.d.ts +0 -37
  612. package/dist/examples/messages/messages-pinning.d.ts.map +0 -1
  613. package/dist/examples/moderators/claim-invite.d.ts +0 -28
  614. package/dist/examples/moderators/claim-invite.d.ts.map +0 -1
  615. package/dist/examples/moderators/invite-management.d.ts +0 -30
  616. package/dist/examples/moderators/invite-management.d.ts.map +0 -1
  617. package/dist/examples/moderators/moderated-tokens-portfolio.d.ts +0 -18
  618. package/dist/examples/moderators/moderated-tokens-portfolio.d.ts.map +0 -1
  619. package/dist/examples/monitoring/demo-stream-events.d.ts +0 -17
  620. package/dist/examples/monitoring/demo-stream-events.d.ts.map +0 -1
  621. package/dist/examples/monitoring/demo-watch-pools.d.ts +0 -18
  622. package/dist/examples/monitoring/demo-watch-pools.d.ts.map +0 -1
  623. package/dist/examples/monitoring/demo-watch-tokens.d.ts +0 -18
  624. package/dist/examples/monitoring/demo-watch-tokens.d.ts.map +0 -1
  625. package/dist/examples/monitoring/fees-collection-e2e.d.ts +0 -36
  626. package/dist/examples/monitoring/fees-collection-e2e.d.ts.map +0 -1
  627. package/dist/examples/monitoring/fees-collection-guaranteed.d.ts +0 -49
  628. package/dist/examples/monitoring/fees-collection-guaranteed.d.ts.map +0 -1
  629. package/dist/examples/monitoring/liquidity-e2e-test.d.ts +0 -15
  630. package/dist/examples/monitoring/liquidity-e2e-test.d.ts.map +0 -1
  631. package/dist/examples/monitoring/liquidity-monitor.d.ts +0 -17
  632. package/dist/examples/monitoring/liquidity-monitor.d.ts.map +0 -1
  633. package/dist/examples/monitoring/pool-creation-integration.d.ts +0 -27
  634. package/dist/examples/monitoring/pool-creation-integration.d.ts.map +0 -1
  635. package/dist/examples/monitoring/pool-liquidity-tracker.d.ts +0 -15
  636. package/dist/examples/monitoring/pool-liquidity-tracker.d.ts.map +0 -1
  637. package/dist/examples/monitoring/subscribe-liquidity-added.d.ts +0 -30
  638. package/dist/examples/monitoring/subscribe-liquidity-added.d.ts.map +0 -1
  639. package/dist/examples/monitoring/subscribe-liquidity-removed.d.ts +0 -30
  640. package/dist/examples/monitoring/subscribe-liquidity-removed.d.ts.map +0 -1
  641. package/dist/examples/monitoring/subscribe-pool-creations.d.ts +0 -29
  642. package/dist/examples/monitoring/subscribe-pool-creations.d.ts.map +0 -1
  643. package/dist/examples/monitoring/subscribe-token-creations.d.ts +0 -21
  644. package/dist/examples/monitoring/subscribe-token-creations.d.ts.map +0 -1
  645. package/dist/examples/monitoring/token-creation-integration.d.ts +0 -32
  646. package/dist/examples/monitoring/token-creation-integration.d.ts.map +0 -1
  647. package/dist/examples/monitoring/websocket-event-handlers.d.ts +0 -22
  648. package/dist/examples/monitoring/websocket-event-handlers.d.ts.map +0 -1
  649. package/dist/examples/nft/demo-collection-management.d.ts +0 -13
  650. package/dist/examples/nft/demo-collection-management.d.ts.map +0 -1
  651. package/dist/examples/nft/demo-fee-calculations.d.ts +0 -14
  652. package/dist/examples/nft/demo-fee-calculations.d.ts.map +0 -1
  653. package/dist/examples/nft/demo-minting.d.ts +0 -13
  654. package/dist/examples/nft/demo-minting.d.ts.map +0 -1
  655. package/dist/examples/nft/demo-portfolio-query.d.ts +0 -14
  656. package/dist/examples/nft/demo-portfolio-query.d.ts.map +0 -1
  657. package/dist/examples/nft/nft-collection-lifecycle.d.ts +0 -22
  658. package/dist/examples/nft/nft-collection-lifecycle.d.ts.map +0 -1
  659. package/dist/examples/nft/nft-data-queries.d.ts +0 -22
  660. package/dist/examples/nft/nft-data-queries.d.ts.map +0 -1
  661. package/dist/examples/nft/nft-fee-estimation.d.ts +0 -23
  662. package/dist/examples/nft/nft-fee-estimation.d.ts.map +0 -1
  663. package/dist/examples/nft/nft-token-creation.d.ts +0 -22
  664. package/dist/examples/nft/nft-token-creation.d.ts.map +0 -1
  665. package/dist/examples/nft/nft-utilities.d.ts +0 -23
  666. package/dist/examples/nft/nft-utilities.d.ts.map +0 -1
  667. package/dist/examples/orchestrator-master.d.ts +0 -22
  668. package/dist/examples/orchestrator-master.d.ts.map +0 -1
  669. package/dist/examples/orchestrator-tasks.d.ts +0 -38
  670. package/dist/examples/orchestrator-tasks.d.ts.map +0 -1
  671. package/dist/examples/overseers/claim-invite.d.ts +0 -31
  672. package/dist/examples/overseers/claim-invite.d.ts.map +0 -1
  673. package/dist/examples/overseers/demo-list-users.d.ts +0 -19
  674. package/dist/examples/overseers/demo-list-users.d.ts.map +0 -1
  675. package/dist/examples/overseers/direct-promotion.d.ts +0 -39
  676. package/dist/examples/overseers/direct-promotion.d.ts.map +0 -1
  677. package/dist/examples/overseers/invite-management.d.ts +0 -38
  678. package/dist/examples/overseers/invite-management.d.ts.map +0 -1
  679. package/dist/examples/overseers/restricted-names-management.d.ts +0 -27
  680. package/dist/examples/overseers/restricted-names-management.d.ts.map +0 -1
  681. package/dist/examples/performance/caching-strategies-advanced.d.ts +0 -28
  682. package/dist/examples/performance/caching-strategies-advanced.d.ts.map +0 -1
  683. package/dist/examples/performance/performance-optimization-patterns.d.ts +0 -28
  684. package/dist/examples/performance/performance-optimization-patterns.d.ts.map +0 -1
  685. package/dist/examples/persistence/data-backup-recovery.d.ts +0 -119
  686. package/dist/examples/persistence/data-backup-recovery.d.ts.map +0 -1
  687. package/dist/examples/persistence/local-storage-patterns.d.ts +0 -86
  688. package/dist/examples/persistence/local-storage-patterns.d.ts.map +0 -1
  689. package/dist/examples/queries/advanced-sorting.d.ts +0 -28
  690. package/dist/examples/queries/advanced-sorting.d.ts.map +0 -1
  691. package/dist/examples/queries/complex-filtering.d.ts +0 -27
  692. package/dist/examples/queries/complex-filtering.d.ts.map +0 -1
  693. package/dist/examples/security/security-audit-trail.d.ts +0 -42
  694. package/dist/examples/security/security-audit-trail.d.ts.map +0 -1
  695. package/dist/examples/security/security-content-moderation-advanced.d.ts +0 -42
  696. package/dist/examples/security/security-content-moderation-advanced.d.ts.map +0 -1
  697. package/dist/examples/security/security-token-safety-checks.d.ts +0 -41
  698. package/dist/examples/security/security-token-safety-checks.d.ts.map +0 -1
  699. package/dist/examples/security/security-user-restrictions-advanced.d.ts +0 -42
  700. package/dist/examples/security/security-user-restrictions-advanced.d.ts.map +0 -1
  701. package/dist/examples/site-config-demo.d.ts +0 -20
  702. package/dist/examples/site-config-demo.d.ts.map +0 -1
  703. package/dist/examples/streaming/admin-controls.d.ts +0 -30
  704. package/dist/examples/streaming/admin-controls.d.ts.map +0 -1
  705. package/dist/examples/streaming/advanced-stream-demo.d.ts +0 -28
  706. package/dist/examples/streaming/advanced-stream-demo.d.ts.map +0 -1
  707. package/dist/examples/streaming/basic-stream.d.ts +0 -17
  708. package/dist/examples/streaming/basic-stream.d.ts.map +0 -1
  709. package/dist/examples/streaming/demo-countdown.d.ts +0 -16
  710. package/dist/examples/streaming/demo-countdown.d.ts.map +0 -1
  711. package/dist/examples/streaming/demo-get-stream-credentials.d.ts +0 -29
  712. package/dist/examples/streaming/demo-get-stream-credentials.d.ts.map +0 -1
  713. package/dist/examples/streaming/demo-platform-config.d.ts +0 -20
  714. package/dist/examples/streaming/demo-platform-config.d.ts.map +0 -1
  715. package/dist/examples/streaming/engagement-stats.d.ts +0 -25
  716. package/dist/examples/streaming/engagement-stats.d.ts.map +0 -1
  717. package/dist/examples/streaming/recordings.d.ts +0 -16
  718. package/dist/examples/streaming/recordings.d.ts.map +0 -1
  719. package/dist/examples/streaming/simulcast.d.ts +0 -19
  720. package/dist/examples/streaming/simulcast.d.ts.map +0 -1
  721. package/dist/examples/streaming/stream-access-control.d.ts +0 -30
  722. package/dist/examples/streaming/stream-access-control.d.ts.map +0 -1
  723. package/dist/examples/streaming/stream-control.d.ts +0 -25
  724. package/dist/examples/streaming/stream-control.d.ts.map +0 -1
  725. package/dist/examples/streaming/stream-countdown.d.ts +0 -31
  726. package/dist/examples/streaming/stream-countdown.d.ts.map +0 -1
  727. package/dist/examples/streaming/stream-enable-disable.d.ts +0 -31
  728. package/dist/examples/streaming/stream-enable-disable.d.ts.map +0 -1
  729. package/dist/examples/streaming/stream-key-management.d.ts +0 -21
  730. package/dist/examples/streaming/stream-key-management.d.ts.map +0 -1
  731. package/dist/examples/streaming/stream-recording-management.d.ts +0 -29
  732. package/dist/examples/streaming/stream-recording-management.d.ts.map +0 -1
  733. package/dist/examples/streaming/stream-simulcast-multi-platform.d.ts +0 -38
  734. package/dist/examples/streaming/stream-simulcast-multi-platform.d.ts.map +0 -1
  735. package/dist/examples/streaming/stream-viewer-analytics.d.ts +0 -43
  736. package/dist/examples/streaming/stream-viewer-analytics.d.ts.map +0 -1
  737. package/dist/examples/streaming/streaming-lifecycle.d.ts +0 -26
  738. package/dist/examples/streaming/streaming-lifecycle.d.ts.map +0 -1
  739. package/dist/examples/streaming-premium/stream-monetization-setup.d.ts +0 -47
  740. package/dist/examples/streaming-premium/stream-monetization-setup.d.ts.map +0 -1
  741. package/dist/examples/streaming-premium/stream-revenue-analytics.d.ts +0 -56
  742. package/dist/examples/streaming-premium/stream-revenue-analytics.d.ts.map +0 -1
  743. package/dist/examples/streaming-premium/stream-vip-management.d.ts +0 -56
  744. package/dist/examples/streaming-premium/stream-vip-management.d.ts.map +0 -1
  745. package/dist/examples/swap-monitoring/arbitrage-monitor.d.ts +0 -20
  746. package/dist/examples/swap-monitoring/arbitrage-monitor.d.ts.map +0 -1
  747. package/dist/examples/swap-monitoring/e2e-trading-demo.d.ts +0 -50
  748. package/dist/examples/swap-monitoring/e2e-trading-demo.d.ts.map +0 -1
  749. package/dist/examples/swap-monitoring/health-monitor.d.ts +0 -10
  750. package/dist/examples/swap-monitoring/health-monitor.d.ts.map +0 -1
  751. package/dist/examples/swap-monitoring/volume-monitor.d.ts +0 -20
  752. package/dist/examples/swap-monitoring/volume-monitor.d.ts.map +0 -1
  753. package/dist/examples/testing/demo-test-runner.d.ts +0 -33
  754. package/dist/examples/testing/demo-test-runner.d.ts.map +0 -1
  755. package/dist/examples/testing/error-classifier.d.ts +0 -23
  756. package/dist/examples/testing/error-classifier.d.ts.map +0 -1
  757. package/dist/examples/testing/index.d.ts +0 -14
  758. package/dist/examples/testing/index.d.ts.map +0 -1
  759. package/dist/examples/testing/memory-manager.d.ts +0 -31
  760. package/dist/examples/testing/memory-manager.d.ts.map +0 -1
  761. package/dist/examples/testing/report-generator.d.ts +0 -31
  762. package/dist/examples/testing/report-generator.d.ts.map +0 -1
  763. package/dist/examples/testing/test-result-types.d.ts +0 -158
  764. package/dist/examples/testing/test-result-types.d.ts.map +0 -1
  765. package/dist/examples/token-bans/token-ban-management.d.ts +0 -32
  766. package/dist/examples/token-bans/token-ban-management.d.ts.map +0 -1
  767. package/dist/examples/token-creation/token-launch-complete.d.ts +0 -20
  768. package/dist/examples/token-creation/token-launch-complete.d.ts.map +0 -1
  769. package/dist/examples/token-creation/token-validation-comprehensive.d.ts +0 -22
  770. package/dist/examples/token-creation/token-validation-comprehensive.d.ts.map +0 -1
  771. package/dist/examples/token-info/token-name-resolution.d.ts +0 -30
  772. package/dist/examples/token-info/token-name-resolution.d.ts.map +0 -1
  773. package/dist/examples/token-info/token-operations-comprehensive.d.ts +0 -22
  774. package/dist/examples/token-info/token-operations-comprehensive.d.ts.map +0 -1
  775. package/dist/examples/token-metadata/token-description-versioning.d.ts +0 -33
  776. package/dist/examples/token-metadata/token-description-versioning.d.ts.map +0 -1
  777. package/dist/examples/token-metadata/token-image-management.d.ts +0 -34
  778. package/dist/examples/token-metadata/token-image-management.d.ts.map +0 -1
  779. package/dist/examples/token-metadata/token-social-links-management.d.ts +0 -34
  780. package/dist/examples/token-metadata/token-social-links-management.d.ts.map +0 -1
  781. package/dist/examples/trading/buy-sell-aliases.d.ts +0 -20
  782. package/dist/examples/trading/buy-sell-aliases.d.ts.map +0 -1
  783. package/dist/examples/trading/volume-data-demo.d.ts +0 -20
  784. package/dist/examples/trading/volume-data-demo.d.ts.map +0 -1
  785. package/dist/examples/trading-advanced/dollar-cost-averaging.d.ts +0 -35
  786. package/dist/examples/trading-advanced/dollar-cost-averaging.d.ts.map +0 -1
  787. package/dist/examples/trading-advanced/limit-orders-advanced.d.ts +0 -34
  788. package/dist/examples/trading-advanced/limit-orders-advanced.d.ts.map +0 -1
  789. package/dist/examples/trading-advanced/stop-loss-orders.d.ts +0 -34
  790. package/dist/examples/trading-advanced/stop-loss-orders.d.ts.map +0 -1
  791. package/dist/examples/trading-advanced/trading-history-analysis.d.ts +0 -35
  792. package/dist/examples/trading-advanced/trading-history-analysis.d.ts.map +0 -1
  793. package/dist/examples/users/balance-queries.d.ts +0 -28
  794. package/dist/examples/users/balance-queries.d.ts.map +0 -1
  795. package/dist/examples/users/fetch-user-balances.d.ts +0 -19
  796. package/dist/examples/users/fetch-user-balances.d.ts.map +0 -1
  797. package/dist/examples/users/fetch-user-report.d.ts +0 -21
  798. package/dist/examples/users/fetch-user-report.d.ts.map +0 -1
  799. package/dist/examples/users/profile-images.d.ts +0 -24
  800. package/dist/examples/users/profile-images.d.ts.map +0 -1
  801. package/dist/examples/users/profile-management.d.ts +0 -22
  802. package/dist/examples/users/profile-management.d.ts.map +0 -1
  803. package/dist/examples/users/referrals-comprehensive.d.ts +0 -26
  804. package/dist/examples/users/referrals-comprehensive.d.ts.map +0 -1
  805. package/dist/examples/users/wallet-balances-external.d.ts +0 -28
  806. package/dist/examples/users/wallet-balances-external.d.ts.map +0 -1
  807. package/dist/examples/utilities/account.d.ts +0 -19
  808. package/dist/examples/utilities/account.d.ts.map +0 -1
  809. package/dist/examples/utilities/balance.d.ts +0 -5
  810. package/dist/examples/utilities/balance.d.ts.map +0 -1
  811. package/dist/examples/utilities/balances.d.ts +0 -7
  812. package/dist/examples/utilities/balances.d.ts.map +0 -1
  813. package/dist/examples/utilities/demo-cache.d.ts +0 -13
  814. package/dist/examples/utilities/demo-cache.d.ts.map +0 -1
  815. package/dist/examples/utilities/demo-token-supply.d.ts +0 -14
  816. package/dist/examples/utilities/demo-token-supply.d.ts.map +0 -1
  817. package/dist/examples/utilities/key-derivation.d.ts +0 -12
  818. package/dist/examples/utilities/key-derivation.d.ts.map +0 -1
  819. package/dist/examples/utilities/multi-token-portfolio.d.ts +0 -18
  820. package/dist/examples/utilities/multi-token-portfolio.d.ts.map +0 -1
  821. package/dist/examples/utilities/pool-discovery-advanced.d.ts +0 -36
  822. package/dist/examples/utilities/pool-discovery-advanced.d.ts.map +0 -1
  823. package/dist/examples/utilities/pool-pair-analysis.d.ts +0 -37
  824. package/dist/examples/utilities/pool-pair-analysis.d.ts.map +0 -1
  825. package/dist/examples/utilities/price-history.d.ts +0 -22
  826. package/dist/examples/utilities/price-history.d.ts.map +0 -1
  827. package/dist/examples/utilities/referrals.d.ts +0 -21
  828. package/dist/examples/utilities/referrals.d.ts.map +0 -1
  829. package/dist/examples/utilities/token-classification.d.ts +0 -38
  830. package/dist/examples/utilities/token-classification.d.ts.map +0 -1
  831. package/dist/examples/utilities/token-discovery.d.ts +0 -26
  832. package/dist/examples/utilities/token-discovery.d.ts.map +0 -1
  833. package/dist/examples/utilities/token-metadata-advanced.d.ts +0 -37
  834. package/dist/examples/utilities/token-metadata-advanced.d.ts.map +0 -1
  835. package/dist/examples/utilities/token-validation-complete.d.ts +0 -41
  836. package/dist/examples/utilities/token-validation-complete.d.ts.map +0 -1
  837. package/dist/examples/utilities/trade-history.d.ts +0 -19
  838. package/dist/examples/utilities/trade-history.d.ts.map +0 -1
  839. package/dist/examples/utilities/transfers.d.ts +0 -29
  840. package/dist/examples/utilities/transfers.d.ts.map +0 -1
  841. package/dist/examples/utilities/validation-and-error-handling.d.ts +0 -27
  842. package/dist/examples/utilities/validation-and-error-handling.d.ts.map +0 -1
  843. package/dist/examples/utilities/wrappable-tokens.d.ts +0 -27
  844. package/dist/examples/utilities/wrappable-tokens.d.ts.map +0 -1
  845. package/dist/examples/utility/auth-utilities.d.ts +0 -30
  846. package/dist/examples/utility/auth-utilities.d.ts.map +0 -1
  847. package/dist/examples/utility/pool-utilities.d.ts +0 -29
  848. package/dist/examples/utility/pool-utilities.d.ts.map +0 -1
  849. package/dist/examples/utility/sdk-configuration.d.ts +0 -29
  850. package/dist/examples/utility/sdk-configuration.d.ts.map +0 -1
  851. package/dist/examples/utility/wallet-management-advanced.d.ts +0 -32
  852. package/dist/examples/utility/wallet-management-advanced.d.ts.map +0 -1
  853. package/dist/examples/utils/auth-bootstrap.d.ts +0 -123
  854. package/dist/examples/utils/auth-bootstrap.d.ts.map +0 -1
  855. package/dist/examples/utils/balance-checking.d.ts +0 -158
  856. package/dist/examples/utils/balance-checking.d.ts.map +0 -1
  857. package/dist/examples/utils/bridge-formatters.d.ts +0 -188
  858. package/dist/examples/utils/bridge-formatters.d.ts.map +0 -1
  859. package/dist/examples/utils/bridge-setup.d.ts +0 -235
  860. package/dist/examples/utils/bridge-setup.d.ts.map +0 -1
  861. package/dist/examples/utils/bridge-transaction-logger.d.ts +0 -42
  862. package/dist/examples/utils/bridge-transaction-logger.d.ts.map +0 -1
  863. package/dist/examples/utils/cli-input.d.ts +0 -41
  864. package/dist/examples/utils/cli-input.d.ts.map +0 -1
  865. package/dist/examples/utils/demo-config.d.ts +0 -155
  866. package/dist/examples/utils/demo-config.d.ts.map +0 -1
  867. package/dist/examples/utils/demo-registry.d.ts +0 -155
  868. package/dist/examples/utils/demo-registry.d.ts.map +0 -1
  869. package/dist/examples/utils/error-handler.d.ts +0 -85
  870. package/dist/examples/utils/error-handler.d.ts.map +0 -1
  871. package/dist/examples/utils/formatting.d.ts +0 -195
  872. package/dist/examples/utils/formatting.d.ts.map +0 -1
  873. package/dist/examples/utils/get-environment.d.ts +0 -17
  874. package/dist/examples/utils/get-environment.d.ts.map +0 -1
  875. package/dist/examples/utils/index.d.ts +0 -44
  876. package/dist/examples/utils/index.d.ts.map +0 -1
  877. package/dist/examples/utils/indexing.d.ts +0 -48
  878. package/dist/examples/utils/indexing.d.ts.map +0 -1
  879. package/dist/examples/utils/load-env.d.ts +0 -90
  880. package/dist/examples/utils/load-env.d.ts.map +0 -1
  881. package/dist/examples/utils/logger.d.ts +0 -52
  882. package/dist/examples/utils/logger.d.ts.map +0 -1
  883. package/dist/examples/utils/pool-helpers.d.ts +0 -226
  884. package/dist/examples/utils/pool-helpers.d.ts.map +0 -1
  885. package/dist/examples/utils/punchlist.d.ts +0 -104
  886. package/dist/examples/utils/punchlist.d.ts.map +0 -1
  887. package/dist/examples/utils/sdk-setup.d.ts +0 -423
  888. package/dist/examples/utils/sdk-setup.d.ts.map +0 -1
  889. package/dist/examples/utils/suppress-logging.d.ts +0 -11
  890. package/dist/examples/utils/suppress-logging.d.ts.map +0 -1
  891. package/dist/examples/utils/token-naming.d.ts +0 -117
  892. package/dist/examples/utils/token-naming.d.ts.map +0 -1
  893. package/dist/examples/utils/trade-helpers.d.ts +0 -195
  894. package/dist/examples/utils/trade-helpers.d.ts.map +0 -1
  895. package/dist/examples/utils/transaction-helpers.d.ts +0 -92
  896. package/dist/examples/utils/transaction-helpers.d.ts.map +0 -1
  897. package/dist/examples/wallet/wallet-initialization-complete.d.ts +0 -31
  898. package/dist/examples/wallet/wallet-initialization-complete.d.ts.map +0 -1
  899. package/dist/examples/wallet/wallet-key-rotation.d.ts +0 -28
  900. package/dist/examples/wallet/wallet-key-rotation.d.ts.map +0 -1
  901. package/dist/examples/wallet/wallet-recovery-patterns.d.ts +0 -29
  902. package/dist/examples/wallet/wallet-recovery-patterns.d.ts.map +0 -1
  903. package/dist/examples/wallet/wallet-signature-operations.d.ts +0 -28
  904. package/dist/examples/wallet/wallet-signature-operations.d.ts.map +0 -1
  905. package/dist/examples/wallet-tracking/wallet-balance-monitoring.d.ts +0 -21
  906. package/dist/examples/wallet-tracking/wallet-balance-monitoring.d.ts.map +0 -1
  907. package/dist/examples/wallet-tracking/wallet-portfolio-alerts.d.ts +0 -21
  908. package/dist/examples/wallet-tracking/wallet-portfolio-alerts.d.ts.map +0 -1
  909. package/dist/examples/wallet-tracking/wallet-transaction-tracking.d.ts +0 -21
  910. package/dist/examples/wallet-tracking/wallet-transaction-tracking.d.ts.map +0 -1
  911. package/dist/examples/websocket/websocket-chat-advanced.d.ts +0 -26
  912. package/dist/examples/websocket/websocket-chat-advanced.d.ts.map +0 -1
  913. package/dist/examples/websocket/websocket-chat-events-detailed.d.ts +0 -28
  914. package/dist/examples/websocket/websocket-chat-events-detailed.d.ts.map +0 -1
  915. package/dist/examples/websocket/websocket-chat-events.d.ts +0 -26
  916. package/dist/examples/websocket/websocket-chat-events.d.ts.map +0 -1
  917. package/dist/examples/websocket/websocket-combined-events.d.ts +0 -28
  918. package/dist/examples/websocket/websocket-combined-events.d.ts.map +0 -1
  919. package/dist/examples/websocket/websocket-comprehensive.d.ts +0 -25
  920. package/dist/examples/websocket/websocket-comprehensive.d.ts.map +0 -1
  921. package/dist/examples/websocket/websocket-connected-clients.d.ts +0 -30
  922. package/dist/examples/websocket/websocket-connected-clients.d.ts.map +0 -1
  923. package/dist/examples/websocket/websocket-connection-management.d.ts +0 -28
  924. package/dist/examples/websocket/websocket-connection-management.d.ts.map +0 -1
  925. package/dist/examples/websocket/websocket-content-events.d.ts +0 -28
  926. package/dist/examples/websocket/websocket-content-events.d.ts.map +0 -1
  927. package/dist/examples/websocket/websocket-core-events.d.ts +0 -27
  928. package/dist/examples/websocket/websocket-core-events.d.ts.map +0 -1
  929. package/dist/examples/websocket/websocket-dex-events.d.ts +0 -40
  930. package/dist/examples/websocket/websocket-dex-events.d.ts.map +0 -1
  931. package/dist/examples/websocket/websocket-dex-pools.d.ts +0 -23
  932. package/dist/examples/websocket/websocket-dex-pools.d.ts.map +0 -1
  933. package/dist/examples/websocket/websocket-download-recording.d.ts +0 -26
  934. package/dist/examples/websocket/websocket-download-recording.d.ts.map +0 -1
  935. package/dist/examples/websocket/websocket-interactions.d.ts +0 -25
  936. package/dist/examples/websocket/websocket-interactions.d.ts.map +0 -1
  937. package/dist/examples/websocket/websocket-moderation-events.d.ts +0 -26
  938. package/dist/examples/websocket/websocket-moderation-events.d.ts.map +0 -1
  939. package/dist/examples/websocket/websocket-recording-events.d.ts +0 -24
  940. package/dist/examples/websocket/websocket-recording-events.d.ts.map +0 -1
  941. package/dist/examples/websocket/websocket-room-events.d.ts +0 -27
  942. package/dist/examples/websocket/websocket-room-events.d.ts.map +0 -1
  943. package/dist/examples/websocket/websocket-room-management.d.ts +0 -27
  944. package/dist/examples/websocket/websocket-room-management.d.ts.map +0 -1
  945. package/dist/examples/websocket/websocket-simulcast-events.d.ts +0 -26
  946. package/dist/examples/websocket/websocket-simulcast-events.d.ts.map +0 -1
  947. package/dist/examples/websocket/websocket-stream-auth.d.ts +0 -23
  948. package/dist/examples/websocket/websocket-stream-auth.d.ts.map +0 -1
  949. package/dist/examples/websocket/websocket-stream-countdown.d.ts +0 -38
  950. package/dist/examples/websocket/websocket-stream-countdown.d.ts.map +0 -1
  951. package/dist/examples/websocket/websocket-stream-events.d.ts +0 -26
  952. package/dist/examples/websocket/websocket-stream-events.d.ts.map +0 -1
  953. package/dist/examples/websocket/websocket-stream-status.d.ts +0 -39
  954. package/dist/examples/websocket/websocket-stream-status.d.ts.map +0 -1
  955. package/dist/examples/websocket/websocket-subscription-management.d.ts +0 -27
  956. package/dist/examples/websocket/websocket-subscription-management.d.ts.map +0 -1
  957. package/dist/examples/websocket/websocket-token-creation-events.d.ts +0 -22
  958. package/dist/examples/websocket/websocket-token-creation-events.d.ts.map +0 -1
  959. package/dist/examples/websocket/websocket-token-events.d.ts +0 -24
  960. package/dist/examples/websocket/websocket-token-events.d.ts.map +0 -1
  961. package/dist/examples/websocket/websocket-token-subscription.d.ts +0 -26
  962. package/dist/examples/websocket/websocket-token-subscription.d.ts.map +0 -1
  963. package/dist/examples/websocket/websocket-token-viewers.d.ts +0 -29
  964. package/dist/examples/websocket/websocket-token-viewers.d.ts.map +0 -1
  965. package/dist/examples/websocket/websocket-unsubscribe.d.ts +0 -25
  966. package/dist/examples/websocket/websocket-unsubscribe.d.ts.map +0 -1
  967. package/dist/examples/websocket/websocket-user-events.d.ts +0 -40
  968. package/dist/examples/websocket/websocket-user-events.d.ts.map +0 -1
  969. package/dist/examples/websocket/websocket-user-presence.d.ts +0 -29
  970. package/dist/examples/websocket/websocket-user-presence.d.ts.map +0 -1
  971. package/dist/examples/websocket/websocket-viewer-analytics.d.ts +0 -38
  972. package/dist/examples/websocket/websocket-viewer-analytics.d.ts.map +0 -1
  973. package/dist/examples/wrap/wrap-status-tracking.d.ts +0 -19
  974. package/dist/examples/wrap/wrap-status-tracking.d.ts.map +0 -1
  975. package/dist/examples/wrap/wrap-token-discovery.d.ts +0 -20
  976. package/dist/examples/wrap/wrap-token-discovery.d.ts.map +0 -1
  977. package/dist/scripts/derive-public-key-from-private-key.d.ts +0 -8
  978. package/dist/scripts/derive-public-key-from-private-key.d.ts.map +0 -1
  979. package/dist/scripts/eslint-fixer.d.ts +0 -7
  980. package/dist/scripts/eslint-fixer.d.ts.map +0 -1
  981. package/dist/scripts/final-fixer.d.ts +0 -7
  982. package/dist/scripts/final-fixer.d.ts.map +0 -1
  983. package/dist/scripts/fix-all-remaining-boolean.d.ts +0 -7
  984. package/dist/scripts/fix-all-remaining-boolean.d.ts.map +0 -1
  985. package/dist/scripts/fix-boolean-expressions-advanced.d.ts +0 -7
  986. package/dist/scripts/fix-boolean-expressions-advanced.d.ts.map +0 -1
  987. package/dist/scripts/fix-boolean-expressions-ast.d.ts +0 -9
  988. package/dist/scripts/fix-boolean-expressions-ast.d.ts.map +0 -1
  989. package/dist/scripts/fix-boolean-expressions-auto.d.ts +0 -7
  990. package/dist/scripts/fix-boolean-expressions-auto.d.ts.map +0 -1
  991. package/dist/scripts/fix-final-aggressive.d.ts +0 -6
  992. package/dist/scripts/fix-final-aggressive.d.ts.map +0 -1
  993. package/dist/scripts/fix-final-boolean.d.ts +0 -7
  994. package/dist/scripts/fix-final-boolean.d.ts.map +0 -1
  995. package/dist/scripts/fix-remaining-boolean.d.ts +0 -7
  996. package/dist/scripts/fix-remaining-boolean.d.ts.map +0 -1
  997. package/dist/scripts/fix-strict-boolean-comprehensive.d.ts +0 -3
  998. package/dist/scripts/fix-strict-boolean-comprehensive.d.ts.map +0 -1
  999. package/dist/scripts/fix-strict-boolean-expressions.d.ts +0 -2
  1000. package/dist/scripts/fix-strict-boolean-expressions.d.ts.map +0 -1
  1001. package/dist/scripts/fix-strict-boolean-final.d.ts +0 -13
  1002. package/dist/scripts/fix-strict-boolean-final.d.ts.map +0 -1
  1003. package/dist/scripts/fixer-aggressive.d.ts +0 -7
  1004. package/dist/scripts/fixer-aggressive.d.ts.map +0 -1
  1005. package/dist/scripts/fixer-conservative.d.ts +0 -7
  1006. package/dist/scripts/fixer-conservative.d.ts.map +0 -1
  1007. package/dist/scripts/fixer-direct.d.ts +0 -7
  1008. package/dist/scripts/fixer-direct.d.ts.map +0 -1
  1009. package/dist/scripts/generate-demo-registry.d.ts +0 -14
  1010. package/dist/scripts/generate-demo-registry.d.ts.map +0 -1
  1011. package/dist/scripts/inject-version.d.ts +0 -8
  1012. package/dist/scripts/inject-version.d.ts.map +0 -1
  1013. package/dist/scripts/strict-boolean-fixer.d.ts +0 -9
  1014. package/dist/scripts/strict-boolean-fixer.d.ts.map +0 -1
  1015. package/dist/scripts/validate-demo-registry.d.ts +0 -17
  1016. package/dist/scripts/validate-demo-registry.d.ts.map +0 -1
  1017. package/dist/services/DexBackendClient.d.ts +0 -225
  1018. package/dist/services/DexBackendClient.d.ts.map +0 -1
  1019. package/dist/services/DexBackendTradeClient.d.ts +0 -34
  1020. package/dist/services/DexBackendTradeClient.d.ts.map +0 -1
  1021. package/dist/services/DexPoolService.d.ts +0 -152
  1022. package/dist/services/DexPoolService.d.ts.map +0 -1
  1023. package/dist/services/DexQuoteService.d.ts +0 -446
  1024. package/dist/services/DexQuoteService.d.ts.map +0 -1
  1025. package/dist/services/GSwapAssetService.d.ts +0 -96
  1026. package/dist/services/GSwapAssetService.d.ts.map +0 -1
  1027. package/dist/services/GSwapLiquidityMutationService.d.ts +0 -138
  1028. package/dist/services/GSwapLiquidityMutationService.d.ts.map +0 -1
  1029. package/dist/services/GSwapLiquidityQueryService.d.ts +0 -75
  1030. package/dist/services/GSwapLiquidityQueryService.d.ts.map +0 -1
  1031. package/dist/services/GSwapPoolCalculationService.d.ts +0 -187
  1032. package/dist/services/GSwapPoolCalculationService.d.ts.map +0 -1
  1033. package/dist/services/GSwapPoolQueryService.d.ts +0 -114
  1034. package/dist/services/GSwapPoolQueryService.d.ts.map +0 -1
  1035. package/dist/services/GSwapService.d.ts +0 -1207
  1036. package/dist/services/GSwapService.d.ts.map +0 -1
  1037. package/dist/services/GSwapSwapService.d.ts +0 -66
  1038. package/dist/services/GSwapSwapService.d.ts.map +0 -1
  1039. package/dist/services/MultiPoolStateManager.d.ts +0 -289
  1040. package/dist/services/MultiPoolStateManager.d.ts.map +0 -1
  1041. package/dist/services/PoolCacheManager.d.ts +0 -258
  1042. package/dist/services/PoolCacheManager.d.ts.map +0 -1
  1043. package/dist/services/PoolStateManager.d.ts +0 -176
  1044. package/dist/services/PoolStateManager.d.ts.map +0 -1
  1045. package/dist/services/SignatureService.d.ts +0 -113
  1046. package/dist/services/SignatureService.d.ts.map +0 -1
  1047. package/dist/services/SwapEventQueue.d.ts +0 -192
  1048. package/dist/services/SwapEventQueue.d.ts.map +0 -1
  1049. package/dist/src/LaunchpadSDK.d.ts +0 -10746
  1050. package/dist/src/LaunchpadSDK.d.ts.map +0 -1
  1051. package/dist/src/api/LaunchpadAPI.d.ts +0 -930
  1052. package/dist/src/api/LaunchpadAPI.d.ts.map +0 -1
  1053. package/dist/src/api/dto/BondingCurveDTOs.d.ts +0 -145
  1054. package/dist/src/api/dto/BondingCurveDTOs.d.ts.map +0 -1
  1055. package/dist/src/api/dto/BurnTokensDto.d.ts +0 -89
  1056. package/dist/src/api/dto/BurnTokensDto.d.ts.map +0 -1
  1057. package/dist/src/api/dto/LockTokenDto.d.ts +0 -97
  1058. package/dist/src/api/dto/LockTokenDto.d.ts.map +0 -1
  1059. package/dist/src/api/dto/TransferTokenDto.d.ts +0 -76
  1060. package/dist/src/api/dto/TransferTokenDto.d.ts.map +0 -1
  1061. package/dist/src/api/dto/UnlockTokenDto.d.ts +0 -86
  1062. package/dist/src/api/dto/UnlockTokenDto.d.ts.map +0 -1
  1063. package/dist/src/auth/JwtAuth.d.ts +0 -183
  1064. package/dist/src/auth/JwtAuth.d.ts.map +0 -1
  1065. package/dist/src/auth/SessionAuthService.d.ts +0 -151
  1066. package/dist/src/auth/SessionAuthService.d.ts.map +0 -1
  1067. package/dist/src/auth/SignatureAuth.d.ts +0 -181
  1068. package/dist/src/auth/SignatureAuth.d.ts.map +0 -1
  1069. package/dist/src/auth/storage.d.ts +0 -66
  1070. package/dist/src/auth/storage.d.ts.map +0 -1
  1071. package/dist/src/auth/types.d.ts +0 -50
  1072. package/dist/src/auth/types.d.ts.map +0 -1
  1073. package/dist/src/bridge/BridgeService.d.ts +0 -484
  1074. package/dist/src/bridge/BridgeService.d.ts.map +0 -1
  1075. package/dist/src/bridge/GalaConnectClient.d.ts +0 -170
  1076. package/dist/src/bridge/GalaConnectClient.d.ts.map +0 -1
  1077. package/dist/src/bridge/constants/index.d.ts +0 -7
  1078. package/dist/src/bridge/constants/index.d.ts.map +0 -1
  1079. package/dist/src/bridge/constants/tokens.d.ts +0 -212
  1080. package/dist/src/bridge/constants/tokens.d.ts.map +0 -1
  1081. package/dist/src/bridge/index.d.ts +0 -24
  1082. package/dist/src/bridge/index.d.ts.map +0 -1
  1083. package/dist/src/bridge/strategies/BridgeStrategy.d.ts +0 -160
  1084. package/dist/src/bridge/strategies/BridgeStrategy.d.ts.map +0 -1
  1085. package/dist/src/bridge/strategies/EthereumBridgeStrategy.d.ts +0 -200
  1086. package/dist/src/bridge/strategies/EthereumBridgeStrategy.d.ts.map +0 -1
  1087. package/dist/src/bridge/strategies/SolanaBridgeStrategy.d.ts +0 -258
  1088. package/dist/src/bridge/strategies/SolanaBridgeStrategy.d.ts.map +0 -1
  1089. package/dist/src/bridge/types/bridge.dto.d.ts +0 -772
  1090. package/dist/src/bridge/types/bridge.dto.d.ts.map +0 -1
  1091. package/dist/src/bridge/types/bridgeable-token.dto.d.ts +0 -205
  1092. package/dist/src/bridge/types/bridgeable-token.dto.d.ts.map +0 -1
  1093. package/dist/src/bridge/types/eip712.d.ts +0 -66
  1094. package/dist/src/bridge/types/eip712.d.ts.map +0 -1
  1095. package/dist/src/bridge/types/index.d.ts +0 -8
  1096. package/dist/src/bridge/types/index.d.ts.map +0 -1
  1097. package/dist/src/bridge/utils/RateLimiter.d.ts +0 -34
  1098. package/dist/src/bridge/utils/RateLimiter.d.ts.map +0 -1
  1099. package/dist/src/bridge/utils/address-formatter.d.ts +0 -25
  1100. package/dist/src/bridge/utils/address-formatter.d.ts.map +0 -1
  1101. package/dist/src/bridge/utils/addressValidation.d.ts +0 -200
  1102. package/dist/src/bridge/utils/addressValidation.d.ts.map +0 -1
  1103. package/dist/src/bridge/utils/balanceHelpers.d.ts +0 -215
  1104. package/dist/src/bridge/utils/balanceHelpers.d.ts.map +0 -1
  1105. package/dist/src/bridge/utils/bridgeErrors.d.ts +0 -98
  1106. package/dist/src/bridge/utils/bridgeErrors.d.ts.map +0 -1
  1107. package/dist/src/bridge/utils/bridgeOutHelpers.d.ts +0 -68
  1108. package/dist/src/bridge/utils/bridgeOutHelpers.d.ts.map +0 -1
  1109. package/dist/src/bridge/utils/bridgePayload.d.ts +0 -98
  1110. package/dist/src/bridge/utils/bridgePayload.d.ts.map +0 -1
  1111. package/dist/src/bridge/utils/bridgeStatusParser.d.ts +0 -75
  1112. package/dist/src/bridge/utils/bridgeStatusParser.d.ts.map +0 -1
  1113. package/dist/src/bridge/utils/eip712Helpers.d.ts +0 -66
  1114. package/dist/src/bridge/utils/eip712Helpers.d.ts.map +0 -1
  1115. package/dist/src/bridge/utils/index.d.ts +0 -19
  1116. package/dist/src/bridge/utils/index.d.ts.map +0 -1
  1117. package/dist/src/bridge/utils/retry.d.ts +0 -112
  1118. package/dist/src/bridge/utils/retry.d.ts.map +0 -1
  1119. package/dist/src/bridge/utils/strategyDelegation.d.ts +0 -69
  1120. package/dist/src/bridge/utils/strategyDelegation.d.ts.map +0 -1
  1121. package/dist/src/bridge/utils/tokenIdUtils.d.ts +0 -86
  1122. package/dist/src/bridge/utils/tokenIdUtils.d.ts.map +0 -1
  1123. package/dist/src/bridge/utils/tokenMath.d.ts +0 -39
  1124. package/dist/src/bridge/utils/tokenMath.d.ts.map +0 -1
  1125. package/dist/src/bridge/utils/tokenMetadataResolver.d.ts +0 -97
  1126. package/dist/src/bridge/utils/tokenMetadataResolver.d.ts.map +0 -1
  1127. package/dist/src/config/environments.d.ts +0 -51
  1128. package/dist/src/config/environments.d.ts.map +0 -1
  1129. package/dist/src/constants/bondingCurve.d.ts +0 -102
  1130. package/dist/src/constants/bondingCurve.d.ts.map +0 -1
  1131. package/dist/src/constants/config.d.ts +0 -30
  1132. package/dist/src/constants/config.d.ts.map +0 -1
  1133. package/dist/src/constants/decimals.d.ts +0 -63
  1134. package/dist/src/constants/decimals.d.ts.map +0 -1
  1135. package/dist/src/constants/endpoints.d.ts +0 -820
  1136. package/dist/src/constants/endpoints.d.ts.map +0 -1
  1137. package/dist/src/constants/enums.d.ts +0 -65
  1138. package/dist/src/constants/enums.d.ts.map +0 -1
  1139. package/dist/src/constants/error-messages.d.ts +0 -61
  1140. package/dist/src/constants/error-messages.d.ts.map +0 -1
  1141. package/dist/src/constants/events.d.ts +0 -53
  1142. package/dist/src/constants/events.d.ts.map +0 -1
  1143. package/dist/src/constants/jwt.d.ts +0 -41
  1144. package/dist/src/constants/jwt.d.ts.map +0 -1
  1145. package/dist/src/constants/nft-fees.d.ts +0 -30
  1146. package/dist/src/constants/nft-fees.d.ts.map +0 -1
  1147. package/dist/src/constants/pagination.d.ts +0 -66
  1148. package/dist/src/constants/pagination.d.ts.map +0 -1
  1149. package/dist/src/constants/query-fields.d.ts +0 -51
  1150. package/dist/src/constants/query-fields.d.ts.map +0 -1
  1151. package/dist/src/constants/sdk-defaults.d.ts +0 -37
  1152. package/dist/src/constants/sdk-defaults.d.ts.map +0 -1
  1153. package/dist/src/constants/version.d.ts +0 -6
  1154. package/dist/src/constants/version.d.ts.map +0 -1
  1155. package/dist/src/constants/version.generated.d.ts +0 -7
  1156. package/dist/src/constants/version.generated.d.ts.map +0 -1
  1157. package/dist/src/helpers/sdk.d.ts +0 -87
  1158. package/dist/src/helpers/sdk.d.ts.map +0 -1
  1159. package/dist/src/helpers/wallet.d.ts +0 -151
  1160. package/dist/src/helpers/wallet.d.ts.map +0 -1
  1161. package/dist/src/index.browser.d.ts +0 -149
  1162. package/dist/src/index.browser.d.ts.map +0 -1
  1163. package/dist/src/index.d.ts +0 -12
  1164. package/dist/src/index.d.ts.map +0 -1
  1165. package/dist/src/index.node.d.ts +0 -13
  1166. package/dist/src/index.node.d.ts.map +0 -1
  1167. package/dist/src/native.d.ts +0 -22
  1168. package/dist/src/native.d.ts.map +0 -1
  1169. package/dist/src/polyfills/file-global.d.ts +0 -12
  1170. package/dist/src/polyfills/file-global.d.ts.map +0 -1
  1171. package/dist/src/react/WalletContext.d.ts +0 -60
  1172. package/dist/src/react/WalletContext.d.ts.map +0 -1
  1173. package/dist/src/react/index.d.ts +0 -65
  1174. package/dist/src/react/index.d.ts.map +0 -1
  1175. package/dist/src/react/types.d.ts +0 -76
  1176. package/dist/src/react/types.d.ts.map +0 -1
  1177. package/dist/src/react/useWallet.d.ts +0 -123
  1178. package/dist/src/react/useWallet.d.ts.map +0 -1
  1179. package/dist/src/react/useWalletConnection.d.ts +0 -89
  1180. package/dist/src/react/useWalletConnection.d.ts.map +0 -1
  1181. package/dist/src/react/useWalletDetection.d.ts +0 -81
  1182. package/dist/src/react/useWalletDetection.d.ts.map +0 -1
  1183. package/dist/src/schemas/files.d.ts +0 -83
  1184. package/dist/src/schemas/files.d.ts.map +0 -1
  1185. package/dist/src/schemas/index.d.ts +0 -83
  1186. package/dist/src/schemas/index.d.ts.map +0 -1
  1187. package/dist/src/schemas/launchpad.d.ts +0 -135
  1188. package/dist/src/schemas/launchpad.d.ts.map +0 -1
  1189. package/dist/src/schemas/pagination.d.ts +0 -107
  1190. package/dist/src/schemas/pagination.d.ts.map +0 -1
  1191. package/dist/src/schemas/primitives.d.ts +0 -142
  1192. package/dist/src/schemas/primitives.d.ts.map +0 -1
  1193. package/dist/src/schemas/trade.d.ts +0 -140
  1194. package/dist/src/schemas/trade.d.ts.map +0 -1
  1195. package/dist/src/schemas/user.d.ts +0 -99
  1196. package/dist/src/schemas/user.d.ts.map +0 -1
  1197. package/dist/src/schemas/validators.d.ts +0 -332
  1198. package/dist/src/schemas/validators.d.ts.map +0 -1
  1199. package/dist/src/services/AIModerationService.d.ts +0 -217
  1200. package/dist/src/services/AIModerationService.d.ts.map +0 -1
  1201. package/dist/src/services/AbstractCacheService.d.ts +0 -227
  1202. package/dist/src/services/AbstractCacheService.d.ts.map +0 -1
  1203. package/dist/src/services/AbstractTokenFetchService.d.ts +0 -150
  1204. package/dist/src/services/AbstractTokenFetchService.d.ts.map +0 -1
  1205. package/dist/src/services/ApiKeyService.d.ts +0 -211
  1206. package/dist/src/services/ApiKeyService.d.ts.map +0 -1
  1207. package/dist/src/services/BanService.d.ts +0 -312
  1208. package/dist/src/services/BanService.d.ts.map +0 -1
  1209. package/dist/src/services/BaseService.d.ts +0 -116
  1210. package/dist/src/services/BaseService.d.ts.map +0 -1
  1211. package/dist/src/services/BatchedCacheService.d.ts +0 -133
  1212. package/dist/src/services/BatchedCacheService.d.ts.map +0 -1
  1213. package/dist/src/services/BridgeableTokenCache.d.ts +0 -120
  1214. package/dist/src/services/BridgeableTokenCache.d.ts.map +0 -1
  1215. package/dist/src/services/BridgeableTokenService.d.ts +0 -218
  1216. package/dist/src/services/BridgeableTokenService.d.ts.map +0 -1
  1217. package/dist/src/services/BundleService.d.ts +0 -245
  1218. package/dist/src/services/BundleService.d.ts.map +0 -1
  1219. package/dist/src/services/BundlerClientFactory.d.ts +0 -32
  1220. package/dist/src/services/BundlerClientFactory.d.ts.map +0 -1
  1221. package/dist/src/services/ChartService.d.ts +0 -106
  1222. package/dist/src/services/ChartService.d.ts.map +0 -1
  1223. package/dist/src/services/ClientConfigService.d.ts +0 -61
  1224. package/dist/src/services/ClientConfigService.d.ts.map +0 -1
  1225. package/dist/src/services/ContentFlagService.d.ts +0 -218
  1226. package/dist/src/services/ContentFlagService.d.ts.map +0 -1
  1227. package/dist/src/services/ContentReactionService.d.ts +0 -175
  1228. package/dist/src/services/ContentReactionService.d.ts.map +0 -1
  1229. package/dist/src/services/DexBackendClient.d.ts +0 -225
  1230. package/dist/src/services/DexBackendClient.d.ts.map +0 -1
  1231. package/dist/src/services/DexBackendTradeClient.d.ts +0 -34
  1232. package/dist/src/services/DexBackendTradeClient.d.ts.map +0 -1
  1233. package/dist/src/services/DexPoolService.d.ts +0 -152
  1234. package/dist/src/services/DexPoolService.d.ts.map +0 -1
  1235. package/dist/src/services/DexQuoteService.d.ts +0 -446
  1236. package/dist/src/services/DexQuoteService.d.ts.map +0 -1
  1237. package/dist/src/services/DexService.d.ts +0 -433
  1238. package/dist/src/services/DexService.d.ts.map +0 -1
  1239. package/dist/src/services/EventsBatcherService.d.ts +0 -111
  1240. package/dist/src/services/EventsBatcherService.d.ts.map +0 -1
  1241. package/dist/src/services/GSwapAssetService.d.ts +0 -96
  1242. package/dist/src/services/GSwapAssetService.d.ts.map +0 -1
  1243. package/dist/src/services/GSwapLiquidityMutationService.d.ts +0 -138
  1244. package/dist/src/services/GSwapLiquidityMutationService.d.ts.map +0 -1
  1245. package/dist/src/services/GSwapLiquidityQueryService.d.ts +0 -75
  1246. package/dist/src/services/GSwapLiquidityQueryService.d.ts.map +0 -1
  1247. package/dist/src/services/GSwapPoolCalculationService.d.ts +0 -187
  1248. package/dist/src/services/GSwapPoolCalculationService.d.ts.map +0 -1
  1249. package/dist/src/services/GSwapPoolQueryService.d.ts +0 -114
  1250. package/dist/src/services/GSwapPoolQueryService.d.ts.map +0 -1
  1251. package/dist/src/services/GSwapService.d.ts +0 -1207
  1252. package/dist/src/services/GSwapService.d.ts.map +0 -1
  1253. package/dist/src/services/GSwapSwapService.d.ts +0 -66
  1254. package/dist/src/services/GSwapSwapService.d.ts.map +0 -1
  1255. package/dist/src/services/GalaChainBalanceService.d.ts +0 -155
  1256. package/dist/src/services/GalaChainBalanceService.d.ts.map +0 -1
  1257. package/dist/src/services/GalaChainLockService.d.ts +0 -144
  1258. package/dist/src/services/GalaChainLockService.d.ts.map +0 -1
  1259. package/dist/src/services/GalaChainService.d.ts +0 -400
  1260. package/dist/src/services/GalaChainService.d.ts.map +0 -1
  1261. package/dist/src/services/GalaChainTokenService.d.ts +0 -108
  1262. package/dist/src/services/GalaChainTokenService.d.ts.map +0 -1
  1263. package/dist/src/services/GalaChainTransferService.d.ts +0 -211
  1264. package/dist/src/services/GalaChainTransferService.d.ts.map +0 -1
  1265. package/dist/src/services/GdexStreamService.d.ts +0 -133
  1266. package/dist/src/services/GdexStreamService.d.ts.map +0 -1
  1267. package/dist/src/services/HolderService.d.ts +0 -181
  1268. package/dist/src/services/HolderService.d.ts.map +0 -1
  1269. package/dist/src/services/ImageService.d.ts +0 -173
  1270. package/dist/src/services/ImageService.d.ts.map +0 -1
  1271. package/dist/src/services/IntervalRegistry.d.ts +0 -79
  1272. package/dist/src/services/IntervalRegistry.d.ts.map +0 -1
  1273. package/dist/src/services/LaunchpadService.d.ts +0 -343
  1274. package/dist/src/services/LaunchpadService.d.ts.map +0 -1
  1275. package/dist/src/services/MessagesService.d.ts +0 -251
  1276. package/dist/src/services/MessagesService.d.ts.map +0 -1
  1277. package/dist/src/services/ModeratorService.d.ts +0 -311
  1278. package/dist/src/services/ModeratorService.d.ts.map +0 -1
  1279. package/dist/src/services/MultiPoolStateManager.d.ts +0 -289
  1280. package/dist/src/services/MultiPoolStateManager.d.ts.map +0 -1
  1281. package/dist/src/services/NetworkKeyedCacheService.d.ts +0 -185
  1282. package/dist/src/services/NetworkKeyedCacheService.d.ts.map +0 -1
  1283. package/dist/src/services/NftCollectionService.d.ts +0 -121
  1284. package/dist/src/services/NftCollectionService.d.ts.map +0 -1
  1285. package/dist/src/services/NotificationService.d.ts +0 -113
  1286. package/dist/src/services/NotificationService.d.ts.map +0 -1
  1287. package/dist/src/services/OEmbedService.d.ts +0 -152
  1288. package/dist/src/services/OEmbedService.d.ts.map +0 -1
  1289. package/dist/src/services/OverseerService.d.ts +0 -524
  1290. package/dist/src/services/OverseerService.d.ts.map +0 -1
  1291. package/dist/src/services/PlatformConfigService.d.ts +0 -149
  1292. package/dist/src/services/PlatformConfigService.d.ts.map +0 -1
  1293. package/dist/src/services/PlatformStatsService.d.ts +0 -72
  1294. package/dist/src/services/PlatformStatsService.d.ts.map +0 -1
  1295. package/dist/src/services/PoolCacheManager.d.ts +0 -258
  1296. package/dist/src/services/PoolCacheManager.d.ts.map +0 -1
  1297. package/dist/src/services/PoolService.d.ts +0 -316
  1298. package/dist/src/services/PoolService.d.ts.map +0 -1
  1299. package/dist/src/services/PoolStateManager.d.ts +0 -176
  1300. package/dist/src/services/PoolStateManager.d.ts.map +0 -1
  1301. package/dist/src/services/PriceHistoryService.d.ts +0 -207
  1302. package/dist/src/services/PriceHistoryService.d.ts.map +0 -1
  1303. package/dist/src/services/RestrictedNamesService.d.ts +0 -80
  1304. package/dist/src/services/RestrictedNamesService.d.ts.map +0 -1
  1305. package/dist/src/services/SignatureService.d.ts +0 -113
  1306. package/dist/src/services/SignatureService.d.ts.map +0 -1
  1307. package/dist/src/services/StreamChatService.d.ts +0 -259
  1308. package/dist/src/services/StreamChatService.d.ts.map +0 -1
  1309. package/dist/src/services/StreamTokenServiceBase.d.ts +0 -404
  1310. package/dist/src/services/StreamTokenServiceBase.d.ts.map +0 -1
  1311. package/dist/src/services/StreamWebSocketService.d.ts +0 -586
  1312. package/dist/src/services/StreamWebSocketService.d.ts.map +0 -1
  1313. package/dist/src/services/StreamingEventService.d.ts +0 -441
  1314. package/dist/src/services/StreamingEventService.d.ts.map +0 -1
  1315. package/dist/src/services/StreamingService.d.ts +0 -573
  1316. package/dist/src/services/StreamingService.d.ts.map +0 -1
  1317. package/dist/src/services/SwapEventQueue.d.ts +0 -192
  1318. package/dist/src/services/SwapEventQueue.d.ts.map +0 -1
  1319. package/dist/src/services/TokenBanService.d.ts +0 -217
  1320. package/dist/src/services/TokenBanService.d.ts.map +0 -1
  1321. package/dist/src/services/TokenClassKeyService.d.ts +0 -162
  1322. package/dist/src/services/TokenClassKeyService.d.ts.map +0 -1
  1323. package/dist/src/services/TokenMetadataCache.d.ts +0 -310
  1324. package/dist/src/services/TokenMetadataCache.d.ts.map +0 -1
  1325. package/dist/src/services/TokenMetadataService.d.ts +0 -509
  1326. package/dist/src/services/TokenMetadataService.d.ts.map +0 -1
  1327. package/dist/src/services/TokenResolverService.d.ts +0 -329
  1328. package/dist/src/services/TokenResolverService.d.ts.map +0 -1
  1329. package/dist/src/services/TradeService.d.ts +0 -286
  1330. package/dist/src/services/TradeService.d.ts.map +0 -1
  1331. package/dist/src/services/TradingQuotesService.d.ts +0 -162
  1332. package/dist/src/services/TradingQuotesService.d.ts.map +0 -1
  1333. package/dist/src/services/UserService.d.ts +0 -352
  1334. package/dist/src/services/UserService.d.ts.map +0 -1
  1335. package/dist/src/services/WebSocketAdminService.d.ts +0 -587
  1336. package/dist/src/services/WebSocketAdminService.d.ts.map +0 -1
  1337. package/dist/src/services/WebSocketService.d.ts +0 -189
  1338. package/dist/src/services/WebSocketService.d.ts.map +0 -1
  1339. package/dist/src/services/WeeklyChallengeService.d.ts +0 -114
  1340. package/dist/src/services/WeeklyChallengeService.d.ts.map +0 -1
  1341. package/dist/src/services/WrapService.d.ts +0 -172
  1342. package/dist/src/services/WrapService.d.ts.map +0 -1
  1343. package/dist/src/services/WrappableTokenCache.d.ts +0 -100
  1344. package/dist/src/services/WrappableTokenCache.d.ts.map +0 -1
  1345. package/dist/src/services/WrappableTokenService.d.ts +0 -130
  1346. package/dist/src/services/WrappableTokenService.d.ts.map +0 -1
  1347. package/dist/src/services/__mocks__/logger.mock.d.ts +0 -24
  1348. package/dist/src/services/__mocks__/logger.mock.d.ts.map +0 -1
  1349. package/dist/src/services/shared/cache-helpers.d.ts +0 -188
  1350. package/dist/src/services/shared/cache-helpers.d.ts.map +0 -1
  1351. package/dist/src/services/shared/http-helpers.d.ts +0 -146
  1352. package/dist/src/services/shared/http-helpers.d.ts.map +0 -1
  1353. package/dist/src/services/shared/pagination-helpers.d.ts +0 -167
  1354. package/dist/src/services/shared/pagination-helpers.d.ts.map +0 -1
  1355. package/dist/src/services/shared/service-validators.d.ts +0 -137
  1356. package/dist/src/services/shared/service-validators.d.ts.map +0 -1
  1357. package/dist/src/services/shared/websocket-helpers.d.ts +0 -158
  1358. package/dist/src/services/shared/websocket-helpers.d.ts.map +0 -1
  1359. package/dist/src/setup.d.ts +0 -8
  1360. package/dist/src/setup.d.ts.map +0 -1
  1361. package/dist/src/test-constants.d.ts +0 -29
  1362. package/dist/src/test-constants.d.ts.map +0 -1
  1363. package/dist/src/types/ai-moderation.dto.d.ts +0 -294
  1364. package/dist/src/types/ai-moderation.dto.d.ts.map +0 -1
  1365. package/dist/src/types/api-key.dto.d.ts +0 -373
  1366. package/dist/src/types/api-key.dto.d.ts.map +0 -1
  1367. package/dist/src/types/backend-responses.d.ts +0 -235
  1368. package/dist/src/types/backend-responses.d.ts.map +0 -1
  1369. package/dist/src/types/ban.dto.d.ts +0 -577
  1370. package/dist/src/types/ban.dto.d.ts.map +0 -1
  1371. package/dist/src/types/burn.dto.d.ts +0 -170
  1372. package/dist/src/types/burn.dto.d.ts.map +0 -1
  1373. package/dist/src/types/cache-management.dto.d.ts +0 -44
  1374. package/dist/src/types/cache-management.dto.d.ts.map +0 -1
  1375. package/dist/src/types/chat-messages.dto.d.ts +0 -193
  1376. package/dist/src/types/chat-messages.dto.d.ts.map +0 -1
  1377. package/dist/src/types/client-config.dto.d.ts +0 -43
  1378. package/dist/src/types/client-config.dto.d.ts.map +0 -1
  1379. package/dist/src/types/comment.dto.d.ts +0 -176
  1380. package/dist/src/types/comment.dto.d.ts.map +0 -1
  1381. package/dist/src/types/comments.dto.d.ts +0 -198
  1382. package/dist/src/types/comments.dto.d.ts.map +0 -1
  1383. package/dist/src/types/common.d.ts +0 -619
  1384. package/dist/src/types/common.d.ts.map +0 -1
  1385. package/dist/src/types/composite-pool.dto.d.ts +0 -101
  1386. package/dist/src/types/composite-pool.dto.d.ts.map +0 -1
  1387. package/dist/src/types/constraints.d.ts +0 -378
  1388. package/dist/src/types/constraints.d.ts.map +0 -1
  1389. package/dist/src/types/content-flag.dto.d.ts +0 -337
  1390. package/dist/src/types/content-flag.dto.d.ts.map +0 -1
  1391. package/dist/src/types/content-reactions.dto.d.ts +0 -132
  1392. package/dist/src/types/content-reactions.dto.d.ts.map +0 -1
  1393. package/dist/src/types/dex-pool.dto.d.ts +0 -230
  1394. package/dist/src/types/dex-pool.dto.d.ts.map +0 -1
  1395. package/dist/src/types/dto.d.ts +0 -183
  1396. package/dist/src/types/dto.d.ts.map +0 -1
  1397. package/dist/src/types/engagement-stats.dto.d.ts +0 -62
  1398. package/dist/src/types/engagement-stats.dto.d.ts.map +0 -1
  1399. package/dist/src/types/events.dto.d.ts +0 -80
  1400. package/dist/src/types/events.dto.d.ts.map +0 -1
  1401. package/dist/src/types/galachain-api.types.d.ts +0 -297
  1402. package/dist/src/types/galachain-api.types.d.ts.map +0 -1
  1403. package/dist/src/types/global-feed.dto.d.ts +0 -203
  1404. package/dist/src/types/global-feed.dto.d.ts.map +0 -1
  1405. package/dist/src/types/gswap-responses.types.d.ts +0 -369
  1406. package/dist/src/types/gswap-responses.types.d.ts.map +0 -1
  1407. package/dist/src/types/gswap.dto.d.ts +0 -448
  1408. package/dist/src/types/gswap.dto.d.ts.map +0 -1
  1409. package/dist/src/types/holder.types.d.ts +0 -106
  1410. package/dist/src/types/holder.types.d.ts.map +0 -1
  1411. package/dist/src/types/launchpad.dto.d.ts +0 -1263
  1412. package/dist/src/types/launchpad.dto.d.ts.map +0 -1
  1413. package/dist/src/types/launchpad.validation.d.ts +0 -43
  1414. package/dist/src/types/launchpad.validation.d.ts.map +0 -1
  1415. package/dist/src/types/liquidity-monitor.dto.d.ts +0 -177
  1416. package/dist/src/types/liquidity-monitor.dto.d.ts.map +0 -1
  1417. package/dist/src/types/lock.dto.d.ts +0 -261
  1418. package/dist/src/types/lock.dto.d.ts.map +0 -1
  1419. package/dist/src/types/messages.dto.d.ts +0 -386
  1420. package/dist/src/types/messages.dto.d.ts.map +0 -1
  1421. package/dist/src/types/moderator.dto.d.ts +0 -607
  1422. package/dist/src/types/moderator.dto.d.ts.map +0 -1
  1423. package/dist/src/types/nft.dto.d.ts +0 -155
  1424. package/dist/src/types/nft.dto.d.ts.map +0 -1
  1425. package/dist/src/types/notification.dto.d.ts +0 -92
  1426. package/dist/src/types/notification.dto.d.ts.map +0 -1
  1427. package/dist/src/types/oembed.dto.d.ts +0 -160
  1428. package/dist/src/types/oembed.dto.d.ts.map +0 -1
  1429. package/dist/src/types/options.dto.d.ts +0 -485
  1430. package/dist/src/types/options.dto.d.ts.map +0 -1
  1431. package/dist/src/types/overseer.dto.d.ts +0 -530
  1432. package/dist/src/types/overseer.dto.d.ts.map +0 -1
  1433. package/dist/src/types/platform-config.dto.d.ts +0 -89
  1434. package/dist/src/types/platform-config.dto.d.ts.map +0 -1
  1435. package/dist/src/types/platform-stats.dto.d.ts +0 -40
  1436. package/dist/src/types/platform-stats.dto.d.ts.map +0 -1
  1437. package/dist/src/types/pool-state-delta.dto.d.ts +0 -246
  1438. package/dist/src/types/pool-state-delta.dto.d.ts.map +0 -1
  1439. package/dist/src/types/pool.dto.d.ts +0 -111
  1440. package/dist/src/types/pool.dto.d.ts.map +0 -1
  1441. package/dist/src/types/priceHistory.dto.d.ts +0 -165
  1442. package/dist/src/types/priceHistory.dto.d.ts.map +0 -1
  1443. package/dist/src/types/restricted-names.dto.d.ts +0 -50
  1444. package/dist/src/types/restricted-names.dto.d.ts.map +0 -1
  1445. package/dist/src/types/result.types.d.ts +0 -104
  1446. package/dist/src/types/result.types.d.ts.map +0 -1
  1447. package/dist/src/types/session-auth.dto.d.ts +0 -99
  1448. package/dist/src/types/session-auth.dto.d.ts.map +0 -1
  1449. package/dist/src/types/stream-chat.dto.d.ts +0 -810
  1450. package/dist/src/types/stream-chat.dto.d.ts.map +0 -1
  1451. package/dist/src/types/streaming-events.dto.d.ts +0 -605
  1452. package/dist/src/types/streaming-events.dto.d.ts.map +0 -1
  1453. package/dist/src/types/streaming.dto.d.ts +0 -1178
  1454. package/dist/src/types/streaming.dto.d.ts.map +0 -1
  1455. package/dist/src/types/swap-monitor.dto.d.ts +0 -256
  1456. package/dist/src/types/swap-monitor.dto.d.ts.map +0 -1
  1457. package/dist/src/types/token-ban.dto.d.ts +0 -194
  1458. package/dist/src/types/token-ban.dto.d.ts.map +0 -1
  1459. package/dist/src/types/token-config.dto.d.ts +0 -117
  1460. package/dist/src/types/token-config.dto.d.ts.map +0 -1
  1461. package/dist/src/types/token.types.d.ts +0 -336
  1462. package/dist/src/types/token.types.d.ts.map +0 -1
  1463. package/dist/src/types/trade.dto.d.ts +0 -457
  1464. package/dist/src/types/trade.dto.d.ts.map +0 -1
  1465. package/dist/src/types/trades-query.dto.d.ts +0 -133
  1466. package/dist/src/types/trades-query.dto.d.ts.map +0 -1
  1467. package/dist/src/types/transfer.dto.d.ts +0 -186
  1468. package/dist/src/types/transfer.dto.d.ts.map +0 -1
  1469. package/dist/src/types/user.dto.d.ts +0 -880
  1470. package/dist/src/types/user.dto.d.ts.map +0 -1
  1471. package/dist/src/types/websocket-admin.dto.d.ts +0 -390
  1472. package/dist/src/types/websocket-admin.dto.d.ts.map +0 -1
  1473. package/dist/src/types/websocket-data.types.d.ts +0 -35
  1474. package/dist/src/types/websocket-data.types.d.ts.map +0 -1
  1475. package/dist/src/types/websocket-events.dto.d.ts +0 -472
  1476. package/dist/src/types/websocket-events.dto.d.ts.map +0 -1
  1477. package/dist/src/types/websocket.types.d.ts +0 -118
  1478. package/dist/src/types/websocket.types.d.ts.map +0 -1
  1479. package/dist/src/types/weekly-challenge.dto.d.ts +0 -130
  1480. package/dist/src/types/weekly-challenge.dto.d.ts.map +0 -1
  1481. package/dist/src/types/wrappable-token.dto.d.ts +0 -305
  1482. package/dist/src/types/wrappable-token.dto.d.ts.map +0 -1
  1483. package/dist/src/utils/LiquidityEventExtractor.d.ts +0 -106
  1484. package/dist/src/utils/LiquidityEventExtractor.d.ts.map +0 -1
  1485. package/dist/src/utils/Logger.d.ts +0 -136
  1486. package/dist/src/utils/Logger.d.ts.map +0 -1
  1487. package/dist/src/utils/MonitoringMetrics.d.ts +0 -151
  1488. package/dist/src/utils/MonitoringMetrics.d.ts.map +0 -1
  1489. package/dist/src/utils/PoolKeyNormalizer.d.ts +0 -135
  1490. package/dist/src/utils/PoolKeyNormalizer.d.ts.map +0 -1
  1491. package/dist/src/utils/ReconnectionManager.d.ts +0 -142
  1492. package/dist/src/utils/ReconnectionManager.d.ts.map +0 -1
  1493. package/dist/src/utils/SignatureHelper.d.ts +0 -140
  1494. package/dist/src/utils/SignatureHelper.d.ts.map +0 -1
  1495. package/dist/src/utils/SwapEventExtractor.d.ts +0 -152
  1496. package/dist/src/utils/SwapEventExtractor.d.ts.map +0 -1
  1497. package/dist/src/utils/adapters.d.ts +0 -111
  1498. package/dist/src/utils/adapters.d.ts.map +0 -1
  1499. package/dist/src/utils/address-formatter.d.ts +0 -318
  1500. package/dist/src/utils/address-formatter.d.ts.map +0 -1
  1501. package/dist/src/utils/agent-config.d.ts +0 -288
  1502. package/dist/src/utils/agent-config.d.ts.map +0 -1
  1503. package/dist/src/utils/amount-validator.d.ts +0 -268
  1504. package/dist/src/utils/amount-validator.d.ts.map +0 -1
  1505. package/dist/src/utils/api-patterns.d.ts +0 -347
  1506. package/dist/src/utils/api-patterns.d.ts.map +0 -1
  1507. package/dist/src/utils/array-helpers.d.ts +0 -115
  1508. package/dist/src/utils/array-helpers.d.ts.map +0 -1
  1509. package/dist/src/utils/assetUrls.d.ts +0 -450
  1510. package/dist/src/utils/assetUrls.d.ts.map +0 -1
  1511. package/dist/src/utils/async-patterns.d.ts +0 -272
  1512. package/dist/src/utils/async-patterns.d.ts.map +0 -1
  1513. package/dist/src/utils/auto-pagination.d.ts +0 -549
  1514. package/dist/src/utils/auto-pagination.d.ts.map +0 -1
  1515. package/dist/src/utils/bignumber-helpers.d.ts +0 -446
  1516. package/dist/src/utils/bignumber-helpers.d.ts.map +0 -1
  1517. package/dist/src/utils/bignumber-pool-cache.d.ts +0 -169
  1518. package/dist/src/utils/bignumber-pool-cache.d.ts.map +0 -1
  1519. package/dist/src/utils/bondingCurveCalculations.d.ts +0 -144
  1520. package/dist/src/utils/bondingCurveCalculations.d.ts.map +0 -1
  1521. package/dist/src/utils/cacheWarmingHelpers.d.ts +0 -110
  1522. package/dist/src/utils/cacheWarmingHelpers.d.ts.map +0 -1
  1523. package/dist/src/utils/composite-pool-converter.d.ts +0 -121
  1524. package/dist/src/utils/composite-pool-converter.d.ts.map +0 -1
  1525. package/dist/src/utils/crypto-compat.d.ts +0 -40
  1526. package/dist/src/utils/crypto-compat.d.ts.map +0 -1
  1527. package/dist/src/utils/data-transform-patterns.d.ts +0 -393
  1528. package/dist/src/utils/data-transform-patterns.d.ts.map +0 -1
  1529. package/dist/src/utils/date-utils.d.ts +0 -205
  1530. package/dist/src/utils/date-utils.d.ts.map +0 -1
  1531. package/dist/src/utils/delimiter-parser.d.ts +0 -139
  1532. package/dist/src/utils/delimiter-parser.d.ts.map +0 -1
  1533. package/dist/src/utils/error-factories.d.ts +0 -701
  1534. package/dist/src/utils/error-factories.d.ts.map +0 -1
  1535. package/dist/src/utils/error-handling-patterns.d.ts +0 -390
  1536. package/dist/src/utils/error-handling-patterns.d.ts.map +0 -1
  1537. package/dist/src/utils/error-patterns.d.ts +0 -360
  1538. package/dist/src/utils/error-patterns.d.ts.map +0 -1
  1539. package/dist/src/utils/error-utils.d.ts +0 -463
  1540. package/dist/src/utils/error-utils.d.ts.map +0 -1
  1541. package/dist/src/utils/error-wrapper.d.ts +0 -208
  1542. package/dist/src/utils/error-wrapper.d.ts.map +0 -1
  1543. package/dist/src/utils/errors.d.ts +0 -552
  1544. package/dist/src/utils/errors.d.ts.map +0 -1
  1545. package/dist/src/utils/http-factory.d.ts +0 -36
  1546. package/dist/src/utils/http-factory.d.ts.map +0 -1
  1547. package/dist/src/utils/http.d.ts +0 -113
  1548. package/dist/src/utils/http.d.ts.map +0 -1
  1549. package/dist/src/utils/load-env.d.ts +0 -31
  1550. package/dist/src/utils/load-env.d.ts.map +0 -1
  1551. package/dist/src/utils/multipart-helpers.d.ts +0 -38
  1552. package/dist/src/utils/multipart-helpers.d.ts.map +0 -1
  1553. package/dist/src/utils/multipart.d.ts +0 -63
  1554. package/dist/src/utils/multipart.d.ts.map +0 -1
  1555. package/dist/src/utils/nft-helpers.d.ts +0 -62
  1556. package/dist/src/utils/nft-helpers.d.ts.map +0 -1
  1557. package/dist/src/utils/numeric-patterns.d.ts +0 -289
  1558. package/dist/src/utils/numeric-patterns.d.ts.map +0 -1
  1559. package/dist/src/utils/numeric-wrappers.d.ts +0 -149
  1560. package/dist/src/utils/numeric-wrappers.d.ts.map +0 -1
  1561. package/dist/src/utils/object-extractors.d.ts +0 -115
  1562. package/dist/src/utils/object-extractors.d.ts.map +0 -1
  1563. package/dist/src/utils/object-patterns.d.ts +0 -81
  1564. package/dist/src/utils/object-patterns.d.ts.map +0 -1
  1565. package/dist/src/utils/pagination-helpers.d.ts +0 -161
  1566. package/dist/src/utils/pagination-helpers.d.ts.map +0 -1
  1567. package/dist/src/utils/pagination-validation.d.ts +0 -88
  1568. package/dist/src/utils/pagination-validation.d.ts.map +0 -1
  1569. package/dist/src/utils/pool-pair-parser.d.ts +0 -57
  1570. package/dist/src/utils/pool-pair-parser.d.ts.map +0 -1
  1571. package/dist/src/utils/pool-state-validator.d.ts +0 -207
  1572. package/dist/src/utils/pool-state-validator.d.ts.map +0 -1
  1573. package/dist/src/utils/position-filters.d.ts +0 -252
  1574. package/dist/src/utils/position-filters.d.ts.map +0 -1
  1575. package/dist/src/utils/primitives.d.ts +0 -76
  1576. package/dist/src/utils/primitives.d.ts.map +0 -1
  1577. package/dist/src/utils/query-params.d.ts +0 -89
  1578. package/dist/src/utils/query-params.d.ts.map +0 -1
  1579. package/dist/src/utils/response-handlers.d.ts +0 -225
  1580. package/dist/src/utils/response-handlers.d.ts.map +0 -1
  1581. package/dist/src/utils/response-helpers.d.ts +0 -28
  1582. package/dist/src/utils/response-helpers.d.ts.map +0 -1
  1583. package/dist/src/utils/response-normalizers.d.ts +0 -115
  1584. package/dist/src/utils/response-normalizers.d.ts.map +0 -1
  1585. package/dist/src/utils/safe-parsers.d.ts +0 -487
  1586. package/dist/src/utils/safe-parsers.d.ts.map +0 -1
  1587. package/dist/src/utils/service-validators.d.ts +0 -268
  1588. package/dist/src/utils/service-validators.d.ts.map +0 -1
  1589. package/dist/src/utils/slippage-utils.d.ts +0 -70
  1590. package/dist/src/utils/slippage-utils.d.ts.map +0 -1
  1591. package/dist/src/utils/string-patterns.d.ts +0 -404
  1592. package/dist/src/utils/string-patterns.d.ts.map +0 -1
  1593. package/dist/src/utils/string-transforms.d.ts +0 -89
  1594. package/dist/src/utils/string-transforms.d.ts.map +0 -1
  1595. package/dist/src/utils/string-utils.d.ts +0 -108
  1596. package/dist/src/utils/string-utils.d.ts.map +0 -1
  1597. package/dist/src/utils/swap-delta-calculator.d.ts +0 -231
  1598. package/dist/src/utils/swap-delta-calculator.d.ts.map +0 -1
  1599. package/dist/src/utils/tick-crossing-handler.d.ts +0 -250
  1600. package/dist/src/utils/tick-crossing-handler.d.ts.map +0 -1
  1601. package/dist/src/utils/token-format-converter.d.ts +0 -175
  1602. package/dist/src/utils/token-format-converter.d.ts.map +0 -1
  1603. package/dist/src/utils/token-parser.d.ts +0 -235
  1604. package/dist/src/utils/token-parser.d.ts.map +0 -1
  1605. package/dist/src/utils/token-stringification.d.ts +0 -168
  1606. package/dist/src/utils/token-stringification.d.ts.map +0 -1
  1607. package/dist/src/utils/tokenNameNormalizer.d.ts +0 -96
  1608. package/dist/src/utils/tokenNameNormalizer.d.ts.map +0 -1
  1609. package/dist/src/utils/tokenNormalizer.d.ts +0 -167
  1610. package/dist/src/utils/tokenNormalizer.d.ts.map +0 -1
  1611. package/dist/src/utils/trade-transformers.d.ts +0 -28
  1612. package/dist/src/utils/trade-transformers.d.ts.map +0 -1
  1613. package/dist/src/utils/transfer-validation.d.ts +0 -58
  1614. package/dist/src/utils/transfer-validation.d.ts.map +0 -1
  1615. package/dist/src/utils/type-guard-factory.d.ts +0 -260
  1616. package/dist/src/utils/type-guard-factory.d.ts.map +0 -1
  1617. package/dist/src/utils/unique-key-generator.d.ts +0 -148
  1618. package/dist/src/utils/unique-key-generator.d.ts.map +0 -1
  1619. package/dist/src/utils/validation-helpers.d.ts +0 -1074
  1620. package/dist/src/utils/validation-helpers.d.ts.map +0 -1
  1621. package/dist/src/utils/validation-patterns.d.ts +0 -768
  1622. package/dist/src/utils/validation-patterns.d.ts.map +0 -1
  1623. package/dist/src/utils/validation.d.ts +0 -140
  1624. package/dist/src/utils/validation.d.ts.map +0 -1
  1625. package/dist/src/utils/wallet.d.ts +0 -185
  1626. package/dist/src/utils/wallet.d.ts.map +0 -1
  1627. package/dist/src/utils/websocket-errors.d.ts +0 -30
  1628. package/dist/src/utils/websocket-errors.d.ts.map +0 -1
  1629. package/dist/src/utils/websocket-patterns.d.ts +0 -680
  1630. package/dist/src/utils/websocket-patterns.d.ts.map +0 -1
  1631. package/dist/src/utils/websocket-validators.d.ts +0 -30
  1632. package/dist/src/utils/websocket-validators.d.ts.map +0 -1
  1633. package/dist/src/wallet/ExternalWalletProvider.d.ts +0 -109
  1634. package/dist/src/wallet/ExternalWalletProvider.d.ts.map +0 -1
  1635. package/dist/src/wallet/GalaChainConnectProvider.d.ts +0 -125
  1636. package/dist/src/wallet/GalaChainConnectProvider.d.ts.map +0 -1
  1637. package/dist/src/wallet/GalaWalletProvider.d.ts +0 -141
  1638. package/dist/src/wallet/GalaWalletProvider.d.ts.map +0 -1
  1639. package/dist/src/wallet/PrivateKeyProvider.d.ts +0 -90
  1640. package/dist/src/wallet/PrivateKeyProvider.d.ts.map +0 -1
  1641. package/dist/src/wallet/detection.d.ts +0 -107
  1642. package/dist/src/wallet/detection.d.ts.map +0 -1
  1643. package/dist/src/wallet/index.d.ts +0 -52
  1644. package/dist/src/wallet/index.d.ts.map +0 -1
  1645. package/dist/src/wallet/types.d.ts +0 -267
  1646. package/dist/src/wallet/types.d.ts.map +0 -1
  1647. package/dist/src/wallet/utils.d.ts +0 -117
  1648. package/dist/src/wallet/utils.d.ts.map +0 -1
  1649. package/dist/types/composite-pool.dto.d.ts +0 -101
  1650. package/dist/types/composite-pool.dto.d.ts.map +0 -1
  1651. package/dist/types/dex-pool.dto.d.ts +0 -230
  1652. package/dist/types/dex-pool.dto.d.ts.map +0 -1
  1653. package/dist/types/gswap-responses.types.d.ts +0 -369
  1654. package/dist/types/gswap-responses.types.d.ts.map +0 -1
  1655. package/dist/types/gswap.dto.d.ts +0 -448
  1656. package/dist/types/gswap.dto.d.ts.map +0 -1
  1657. package/dist/types/liquidity-monitor.dto.d.ts +0 -177
  1658. package/dist/types/liquidity-monitor.dto.d.ts.map +0 -1
  1659. package/dist/types/pool-state-delta.dto.d.ts +0 -246
  1660. package/dist/types/pool-state-delta.dto.d.ts.map +0 -1
  1661. package/dist/types/swap-monitor.dto.d.ts +0 -256
  1662. package/dist/types/swap-monitor.dto.d.ts.map +0 -1
  1663. package/dist/utils/LiquidityEventExtractor.d.ts +0 -106
  1664. package/dist/utils/LiquidityEventExtractor.d.ts.map +0 -1
  1665. package/dist/utils/MonitoringMetrics.d.ts +0 -151
  1666. package/dist/utils/MonitoringMetrics.d.ts.map +0 -1
  1667. package/dist/utils/PoolKeyNormalizer.d.ts +0 -135
  1668. package/dist/utils/PoolKeyNormalizer.d.ts.map +0 -1
  1669. package/dist/utils/SignatureHelper.d.ts +0 -140
  1670. package/dist/utils/SignatureHelper.d.ts.map +0 -1
  1671. package/dist/utils/SwapEventExtractor.d.ts +0 -152
  1672. package/dist/utils/SwapEventExtractor.d.ts.map +0 -1
  1673. package/dist/utils/bignumber-pool-cache.d.ts +0 -169
  1674. package/dist/utils/bignumber-pool-cache.d.ts.map +0 -1
  1675. package/dist/utils/composite-pool-converter.d.ts +0 -121
  1676. package/dist/utils/composite-pool-converter.d.ts.map +0 -1
  1677. package/dist/utils/pool-pair-parser.d.ts +0 -57
  1678. package/dist/utils/pool-pair-parser.d.ts.map +0 -1
  1679. package/dist/utils/pool-state-validator.d.ts +0 -207
  1680. package/dist/utils/pool-state-validator.d.ts.map +0 -1
  1681. package/dist/utils/position-filters.d.ts +0 -252
  1682. package/dist/utils/position-filters.d.ts.map +0 -1
  1683. package/dist/utils/swap-delta-calculator.d.ts +0 -231
  1684. package/dist/utils/swap-delta-calculator.d.ts.map +0 -1
  1685. package/dist/utils/tick-crossing-handler.d.ts +0 -250
  1686. package/dist/utils/tick-crossing-handler.d.ts.map +0 -1
package/README.md CHANGED
@@ -1,3376 +1,94 @@
1
- # Gala Launchpad SDK
1
+ # @gala-chain/launchpad-sdk
2
2
 
3
- **Version: 5.0.4-beta.46 (Latest)**
3
+ The v6 TypeScript SDK for Gala Launchpad. It provides read APIs for launchpad data, typed launchpad submissions, gateway-backed token transactions, and the official GSwap DEX client through `sdk.dex`.
4
4
 
5
- A comprehensive TypeScript SDK for the Gala Launchpad Backend API, providing type-safe authentication, trading, and real-time features for DeFi applications.
6
-
7
- > **⚠️ BREAKING CHANGE (v3.33.0+)**: Token format parsing now **ONLY accepts delimited formats** (`GALA|Unit|none|none` or `GALA$Unit$none$none`). Plain token strings (`'GALA'`, `'GUSDC'`) are **permanently rejected** for security. See [Migration Guide](#token-format-migration-v330) below.
8
-
9
- [![npm version](https://badge.fury.io/js/@gala-chain%2Flaunchpad-sdk.svg)](https://badge.fury.io/js/@gala-chain%2Flaunchpad-sdk)
10
- [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
11
- [![TypeScript](https://img.shields.io/badge/%3C%2F%3E-TypeScript-%230074c1.svg)](http://www.typescriptlang.org/)
12
- [![Documentation Coverage](https://img.shields.io/badge/Documentation%20Coverage-100%25-success)](./docs/API-REFERENCE.md)
13
-
14
- ## Features
15
-
16
- **Clean Result Types with No Wrapper Overhead:**
17
-
18
- - **Direct Result Access**: Get clean, typed results without wrapper objects
19
- - **Semantic Type Conversion**: Dates as Date objects, numbers as numbers, strings for precision
20
- - **Comprehensive Type Safety**: Full TypeScript support with precise result interfaces
21
- - **Zero Wrapper Overhead**: No more `result.data.success` - direct property access
22
- - **Options Object Pattern**: All methods with 2+ parameters use clean options objects
23
- - **Auto-Pagination**: Automatic multi-page fetching with configurable concurrency
24
-
25
- ### Developer Experience
26
-
27
- ```typescript
28
- import { createLaunchpadSDK, createWallet } from '@gala-chain/launchpad-sdk';
29
-
30
- // Auto-detect wallet format and create SDK
31
- const sdk = createLaunchpadSDK({
32
- wallet: 'your-private-key-or-mnemonic' // Auto-detects format!
33
- });
34
-
35
- // Direct result access - no wrapper objects!
36
- const pools = await sdk.fetchPools({ type: 'recent' });
37
- console.log(`Found ${pools.total} pools`); // Direct property access
38
- console.log(`Page ${pools.page} of ${pools.totalPages}`); // Clean pagination
39
- console.log(`Has next: ${pools.hasNext}`); // Boolean convenience properties
40
-
41
- // Clean typed results everywhere
42
- const balance = await sdk.fetchGalaBalance();
43
- console.log(`Balance: ${balance.balance} GALA`); // Direct balance access
44
- console.log(`Last updated: ${balance.lastUpdated.toISOString()}`); // Date object
45
- ```
46
-
47
- ## Clean API Architecture
48
-
49
- **Direct result access with no wrapper overhead:**
50
-
51
- ```typescript
52
- // Get pools with direct property access
53
- const pools = await sdk.fetchPools({ type: 'recent' });
54
- console.log(pools.items); // Direct access to pool array
55
- console.log(pools.meta.total); // Immediate pagination info
56
- console.log(pools.meta.page < pools.meta.totalPages); // Has more pages
57
- ```
58
-
59
- ## Key Features
60
-
61
- - **Type-Safe API Client**: Full TypeScript support with comprehensive type definitions
62
- - **Clean Result Types**: Direct property access without wrapper objects
63
- - **Options Object Pattern**: All multi-parameter methods use clean options objects
64
- - **Auto-Pagination**: Automatic multi-page fetching for large result sets
65
- - **Signature Authentication**: Ethereum wallet-based authentication with automatic signature generation
66
- - **Helper Functions**: Auto-detecting wallet creation and SDK factory functions
67
- - **Pool Management**: Create, fetch, and check token pools on the launchpad
68
- - **Token Trading**: Buy and sell tokens with slippage protection via GalaChain
69
- - **DEX Pool Discovery**: Discover and explore GalaSwap liquidity pools with filtering, sorting, and pagination
70
- - **DEX Trading**: Real-time token swaps on GalaSwap DEX with quote generation and slippage protection
71
- - **Liquidity Management**: Manage liquidity positions on GalaSwap (add, remove, collect fees) with filtering and organization utilities
72
- - **Token Transfers**: Transfer GALA and launchpad tokens between wallets with EIP-712 signatures
73
- - **User Operations**: Portfolio management, token balances, and account management
74
- - **Comment System**: Post and retrieve comments on token pools
75
- - **Price History**: Fetch historical price data for DEX tokens with pagination (Node.js only)
76
- - **Cross-Chain Bridging**: Transfer tokens between GalaChain, Ethereum, and Solana with fee estimation
77
- - **External Wallet Balances**: Query Ethereum and Solana wallet balances (single-token or full portfolio)
78
- - **Live Streaming**: Start/stop streams, manage recordings and simulcast targets for token pools (v5.1.0+)
79
- - **Stream Chat**: Real-time chat messaging via REST and WebSocket with admin controls (v5.1.0+)
80
- - **Events Tracking**: SDK-side event batching with automatic persistence and overseer monitoring (v8.2.0+)
81
- - **Global Feed**: Unified real-time event stream for token updates and site configuration changes (v7.0.0+)
82
- - **Overseer System**: Global platform oversight with CCTV dashboard, invite management, platform summary, and cache management (v5.9.0+)
83
- - **Moderator System**: Token-scoped moderation with magic link invites (v5.7.0+)
84
- - **Content Flags**: Report and manage flagged content with two-tier review system (v5.8.0+)
85
- - **User Bans**: Per-token and global user banning with active user tracking (v5.5.0+)
86
- - **Comprehensive Validation**: Input validation and error handling for all operations
87
- - **Multi-Environment Support**: Production, staging, and custom backend URLs
88
-
89
- ## Installation
90
-
91
- ### NPM
92
-
93
- ```bash
94
- npm install @gala-chain/launchpad-sdk
95
- ```
96
-
97
- ### Yarn
98
-
99
- ```bash
100
- yarn add @gala-chain/launchpad-sdk
101
- ```
102
-
103
- ### Peer Dependencies
104
-
105
- This SDK requires the following peer dependencies to be installed:
106
-
107
- ```bash
108
- npm install ethers@^6.15.0 @gala-chain/api@^2.4.3 @gala-chain/connect@^2.4.3 socket.io-client@^4.8.1 axios@^1.12.2 bignumber.js@^9.1.2 zod@^3.25.76
109
- ```
110
-
111
- **Or with yarn:**
112
-
113
- ```bash
114
- yarn add ethers@^6.15.0 @gala-chain/api@^2.4.3 @gala-chain/connect@^2.4.3 socket.io-client@^4.8.1 axios@^1.12.2 bignumber.js@^9.1.2 zod@^3.25.76
115
- ```
116
-
117
- **All peer dependencies are required** - this includes `socket.io-client` which is needed for transaction verification via WebSocket.
118
-
119
- ## Module Formats
120
-
121
- The SDK is distributed in **three module formats** to support both modern and legacy projects:
122
-
123
- ### ESM (ES Modules) - Primary Format
124
-
125
- **For modern bundlers and Node.js 16+:**
126
-
127
- ```typescript
128
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
129
-
130
- const sdk = createLaunchpadSDK({
131
- wallet: 'your-private-key-or-mnemonic'
132
- });
133
- ```
134
-
135
- **When to use:**
136
- - ✅ React, Vue, Svelte, Angular applications
137
- - ✅ Next.js, Nuxt, SvelteKit
138
- - ✅ Vite, Webpack, esbuild bundlers
139
- - ✅ Modern Node.js projects with `"type": "module"`
140
-
141
- ### CommonJS - Legacy Support
142
-
143
- **For CommonJS projects and older Node.js environments:**
144
-
145
- ```javascript
146
- const { createLaunchpadSDK } = require('@gala-chain/launchpad-sdk');
147
-
148
- const sdk = createLaunchpadSDK({
149
- wallet: 'your-private-key-or-mnemonic'
150
- });
151
- ```
152
-
153
- **When to use:**
154
- - ✅ Legacy Node.js projects with CommonJS modules
155
- - ✅ Older tooling that doesn't support ESM
156
- - ✅ Express.js, Nest.js (CommonJS mode)
157
- - ✅ Projects without build tools
158
-
159
- ### UMD (Universal Module Definition) - Browser Legacy
160
-
161
- **For browser globals and legacy environments:**
162
-
163
- ```html
164
- <script src="node_modules/@gala-chain/launchpad-sdk/dist/index.js"></script>
165
- <script>
166
- const sdk = window.GalaLaunchpadSDK.createLaunchpadSDK({
167
- wallet: 'your-private-key-or-mnemonic'
168
- });
169
- </script>
170
- ```
171
-
172
- **When to use:**
173
- - ✅ Direct browser `<script>` tags
174
- - ✅ Older browser environments
175
- - ✅ CDN delivery
176
-
177
- ### Module Resolution
178
-
179
- Node.js automatically selects the correct module format based on your project:
180
-
181
- | Project Type | Method | Format Used | File |
182
- |---|---|---|---|
183
- | ESM Module | `import` | ESM | `dist/index.esm.js` |
184
- | CommonJS | `require()` | CommonJS | `dist/index.cjs.js` |
185
- | Legacy Tools | Direct Include | UMD | `dist/index.js` |
186
-
187
- **No configuration needed** - Node.js and bundlers automatically select the optimal format via the package exports field!
188
-
189
- ## Wallet Configuration Modes
190
-
191
- The SDK supports **two operational modes** with optional wallet configuration:
192
-
193
- ### Full-Access Mode (with Wallet)
194
-
195
- **For executing trades, creating tokens, and managing funds:**
196
-
197
- ```typescript
198
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
199
-
200
- // Initialize with wallet - enables signing operations
201
- const sdk = createLaunchpadSDK({
202
- wallet: 'your-private-key-or-mnemonic'
203
- });
204
-
205
- // Now you can execute trades
206
- const result = await sdk.buy({
207
- tokenName: 'anime',
208
- amount: '100',
209
- type: 'native',
210
- slippageToleranceFactor: 0.01
211
- });
212
- ```
213
-
214
- **Capabilities:**
215
- - ✅ Execute token trades (buy/sell)
216
- - ✅ Create new tokens
217
- - ✅ Transfer GALA and tokens
218
- - ✅ Update user profile
219
- - ✅ Post comments
220
- - ✅ All read operations (fetch pools, prices, etc.)
221
-
222
- ### Read-Only Mode (without Wallet)
223
-
224
- **For querying data without wallet authentication:**
225
-
226
- ```typescript
227
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
228
-
229
- // Initialize without wallet - read-only operations only
230
- const sdk = createLaunchpadSDK({});
231
-
232
- // Query operations work fine
233
- const pools = await sdk.fetchPools({ type: 'recent' });
234
- const prices = await sdk.fetchTokenSpotPrice('anime');
235
- const balance = await sdk.fetchGalaBalance();
236
- ```
237
-
238
- **Capabilities:**
239
- - ✅ Fetch token pools and details
240
- - ✅ Get real-time prices and price history
241
- - ✅ Check balances and portfolio
242
- - ✅ Browse comments and token information
243
- - ✅ Explore token metadata and distributions
244
- - ❌ Cannot: Execute trades, create tokens, transfer funds (require signatures)
245
-
246
- ### Dynamic Wallet Configuration
247
-
248
- **Upgrade from read-only to full-access mode at runtime:**
249
-
250
- ```typescript
251
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
252
-
253
- // Start in read-only mode
254
- const sdk = createLaunchpadSDK({});
255
- console.log(sdk.hasWallet()); // false
256
-
257
- // Later, upgrade to full-access
258
- sdk.setWallet('your-private-key-or-mnemonic');
259
- console.log(sdk.hasWallet()); // true
260
-
261
- // Now signing operations work
262
- const result = await sdk.buy({
263
- tokenName: 'anime',
264
- amount: '100',
265
- type: 'native',
266
- slippageToleranceFactor: 0.01
267
- });
268
- ```
269
-
270
- **Wallet Management Methods:**
271
- - `hasWallet()` - Check if wallet is configured
272
- - `getWallet()` - Retrieve current wallet instance
273
- - `setWallet(wallet)` - Configure wallet for signing operations
274
- - `validateWallet()` - Type guard that throws if wallet not present
275
-
276
- ## How to Connect Your Wallet
277
-
278
- The SDK ships a complete wallet provider system with EIP-6963 browser detection, 4 provider types, and React hooks. Here's how to go from zero to connected.
279
-
280
- ### Node.js / CLI (PrivateKeyProvider)
281
-
282
- ```typescript
283
- import { PrivateKeyProvider } from '@gala-chain/launchpad-sdk/wallet';
284
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
285
-
286
- const provider = new PrivateKeyProvider('0xYOUR_PRIVATE_KEY');
287
- const sdk = createLaunchpadSDK({ walletProvider: provider });
288
-
289
- // Ready — sign messages, execute trades, transfer tokens
290
- const address = await provider.getAddress(); // 0x checksummed
291
- const galaAddr = await provider.getGalaAddress(); // eth|{40-hex}
292
- const sig = await provider.signMessage('Hello');
293
- ```
294
-
295
- ### Browser (React — 3 steps)
296
-
297
- **Step 1: Wrap your app**
298
-
299
- ```tsx
300
- import { WalletProvider } from '@gala-chain/launchpad-sdk/react';
301
-
302
- function App() {
303
- return (
304
- <WalletProvider autoDetect>
305
- <YourApp />
306
- </WalletProvider>
307
- );
308
- }
309
- ```
310
-
311
- **Step 2: Show detected wallets and connect**
312
-
313
- ```tsx
314
- import { useWalletDetection, useWalletConnection } from '@gala-chain/launchpad-sdk/react';
315
-
316
- function WalletPicker() {
317
- const { wallets, isDetecting } = useWalletDetection();
318
- const { connectDetected, isConnecting } = useWalletConnection();
319
-
320
- if (isDetecting) return <p>Scanning for wallets...</p>;
321
-
322
- return (
323
- <div>
324
- {wallets.map(wallet => (
325
- <button key={wallet.id} onClick={() => connectDetected(wallet)} disabled={isConnecting}>
326
- <img src={wallet.icon} alt="" width={24} /> {wallet.name}
327
- </button>
328
- ))}
329
- </div>
330
- );
331
- }
332
- ```
333
-
334
- **Step 3: Use wallet state**
335
-
336
- ```tsx
337
- import { useWallet, useGalaAddress, useWalletProvider } from '@gala-chain/launchpad-sdk/react';
338
-
339
- function Dashboard() {
340
- const { isConnected, address } = useWallet();
341
- const galaAddress = useGalaAddress();
342
- const provider = useWalletProvider();
343
-
344
- if (!isConnected) return <WalletPicker />;
345
-
346
- return (
347
- <div>
348
- <p>ETH: {address}</p>
349
- <p>GalaChain: {galaAddress}</p>
350
- <button onClick={async () => {
351
- const sig = await provider.signMessage('Prove ownership');
352
- console.log('Signature:', sig);
353
- }}>
354
- Sign Message
355
- </button>
356
- </div>
357
- );
358
- }
359
- ```
360
-
361
- ### Browser (Vanilla — no React)
362
-
363
- ```typescript
364
- import { detectWallets, ExternalWalletProvider, KNOWN_WALLET_RDNS } from '@gala-chain/launchpad-sdk/wallet';
365
-
366
- // Detect installed wallets (EIP-6963, 500ms scan)
367
- const { wallets, primary, hasWallets } = await detectWallets();
368
-
369
- if (hasWallets) {
370
- // Connect to the first detected wallet
371
- const provider = new ExternalWalletProvider(primary.provider);
372
- const address = await provider.connect(); // triggers wallet popup
373
- console.log('Connected:', address);
374
-
375
- // Sign a message
376
- const sig = await provider.signMessage('Hello from Launchpad');
377
-
378
- // Sign EIP-712 typed data (required for GalaChain transactions)
379
- const typedSig = await provider.signTypedData(
380
- { name: 'GalaChain', version: '1' },
381
- { Transfer: [{ name: 'to', type: 'string' }, { name: 'amount', type: 'string' }] },
382
- { to: 'eth|0000000000000000000000000000000000000001', amount: '100' }
383
- );
384
-
385
- // Disconnect
386
- await provider.disconnect();
387
- }
388
-
389
- // Or check for a specific wallet
390
- import { getWalletByRdns } from '@gala-chain/launchpad-sdk/wallet';
391
-
392
- const metamask = await getWalletByRdns(KNOWN_WALLET_RDNS.METAMASK);
393
- if (metamask) {
394
- const provider = new ExternalWalletProvider(metamask.provider);
395
- await provider.connect();
396
- }
397
- ```
398
-
399
- ### Supported Wallets
400
-
401
- EIP-6963 auto-detects any compatible wallet. Known identifiers:
402
-
403
- | Wallet | RDNS | Constant |
404
- |--------|------|----------|
405
- | MetaMask | `io.metamask` | `KNOWN_WALLET_RDNS.METAMASK` |
406
- | Coinbase Wallet | `com.coinbase.wallet` | `KNOWN_WALLET_RDNS.COINBASE` |
407
- | Trust Wallet | `com.trustwallet.app` | `KNOWN_WALLET_RDNS.TRUST_WALLET` |
408
- | Phantom | `app.phantom` | `KNOWN_WALLET_RDNS.PHANTOM` |
409
- | Rainbow | `me.rainbow` | `KNOWN_WALLET_RDNS.RAINBOW` |
410
- | OKX Wallet | `com.okex.wallet` | `KNOWN_WALLET_RDNS.OKX` |
411
- | Rabby | `io.rabby` | `KNOWN_WALLET_RDNS.RABBY` |
412
- | Brave Wallet | `com.brave.wallet` | `KNOWN_WALLET_RDNS.BRAVE` |
413
- | Frame | `sh.frame` | `KNOWN_WALLET_RDNS.FRAME` |
414
- | Ledger | `com.ledger` | `KNOWN_WALLET_RDNS.LEDGER` |
415
- | Zerion | `io.zerion.wallet` | `KNOWN_WALLET_RDNS.ZERION` |
416
- | Gala Wallet | `com.gala.wallet` | `KNOWN_WALLET_RDNS.GALA` |
417
-
418
- Falls back to `window.ethereum` if no EIP-6963 announcements received.
419
-
420
- ### React Hooks Reference
421
-
422
- | Hook | Returns |
423
- |------|---------|
424
- | `useWallet()` | `{ isConnected, address, galaAddress, provider, error }` |
425
- | `useWalletAddress()` | `string \| null` (0x format) |
426
- | `useGalaAddress()` | `string \| null` (eth\| format) |
427
- | `useWalletProvider()` | `WalletProvider \| null` |
428
- | `useIsWalletConnected()` | `boolean` |
429
- | `useWalletConnection()` | `{ connectDetected, disconnect, isConnecting }` |
430
- | `useWalletDetection()` | `{ wallets, isDetecting, refreshWallets }` |
431
-
432
- ### Provider Types
433
-
434
- | Provider | Use Case | Private Key Access | Browser Required |
435
- |----------|----------|--------------------|-----------------|
436
- | `PrivateKeyProvider` | CLI, bots, scripts | Yes | No |
437
- | `ExternalWalletProvider` | MetaMask, Coinbase, etc. | No | Yes |
438
- | `GalaWalletProvider` | Gala Wallet extension | No | Yes |
439
- | `GalaChainConnectProvider` | @gala-chain/connect | No | Yes |
440
-
441
- ### Error Handling
442
-
443
- ```typescript
444
- import { WalletProviderError, WalletProviderErrorCode } from '@gala-chain/launchpad-sdk/wallet';
445
-
446
- try {
447
- await provider.connect();
448
- } catch (e) {
449
- if (e instanceof WalletProviderError) {
450
- switch (e.code) {
451
- case WalletProviderErrorCode.USER_REJECTED:
452
- console.log('User cancelled');
453
- break;
454
- case WalletProviderErrorCode.PROVIDER_NOT_AVAILABLE:
455
- console.log('Wallet not installed');
456
- break;
457
- case WalletProviderErrorCode.CONNECTION_FAILED:
458
- console.log('Connection failed:', e.message);
459
- break;
460
- }
461
- }
462
- }
463
- ```
464
-
465
- **Full reference**: [docs/WALLET-PROVIDERS.md](./docs/WALLET-PROVIDERS.md) | **Live demo**: `npm run demo:wallet`
466
-
467
- ### Method Categorization: Wallet Requirements
468
-
469
- **Methods that DON'T require a wallet (Read-Only Operations):**
470
-
471
- | Category | Methods | Notes |
472
- |----------|---------|-------|
473
- | **Pool Queries** | `fetchPools`, `fetchAllPools`, `fetchPoolDetails`, `fetchPoolDetailsForCalculation`, `isTokenGraduated`, `isTokenNameAvailable`, `isTokenSymbolAvailable` | Query pool data and token availability |
474
- | **Token Data** | `fetchTokenDetails`, `fetchTokenDistribution`, `fetchTokenBadges` | Get token metadata and holder information |
475
- | **Pricing** | `fetchTokenSpotPrice`, `fetchGalaSpotPrice`, `fetchLaunchpadTokenSpotPrice`, `fetchVolumeData` | Get current prices and OHLCV data |
476
- | **Price History** | `fetchPriceHistory`, `fetchAllPriceHistory` | Get historical price snapshots (Node.js only) |
477
- | **Balance Info** | `fetchGalaBalance`, `fetchTokenBalance` | Check GALA and token balances (your own only) |
478
- | **Portfolio** | `fetchTokensHeld`, `fetchTokensCreated` | View your token portfolio and created tokens |
479
- | **Profile** | `fetchProfile` | Retrieve user profile information |
480
- | **Comments** | `fetchComments` | View comments on token pools |
481
- | **Trade History** | `fetchTrades` | View your past trades |
482
- | **Utilities** | `getAddress`, `getEthereumAddress`, `getConfig`, `getVersion`, `getUrlByTokenName`, `getCacheInfo`, `clearCache`, `cleanup`, `cleanupAll` | Utility and configuration methods |
483
- | **Reference** | `resolveTokenClassKey`, `resolveVaultAddress`, `calculateInitialBuyAmount` | Resolve IDs and get reference data |
484
-
485
- **Methods that REQUIRE a wallet (Signing Operations):**
486
-
487
- | Category | Methods | Error When Missing |
488
- |----------|---------|-------------------|
489
- | **Trading** | `buy`, `sell`, `calculateBuyAmount`, `calculateSellAmount`, `calculateBuyAmountLocal`, `calculateBuyAmountExternal`, `calculateSellAmountLocal`, `calculateSellAmountExternal` | `ValidationError: Wallet is required` |
490
- | **Token Creation** | `launchToken`, `uploadTokenImage`, `uploadProfileImage`, `calculateBuyAmountForGraduation`, `graduateToken` | `ValidationError: Wallet is required` |
491
- | **Account Management** | `updateProfile`, `postComment` | `ValidationError: Wallet is required` |
492
- | **Transfers** | `transferGala`, `transferToken` | `ValidationError: Wallet is required` |
493
- | **Admin** | `getBundlerTransactionResult` | May require wallet for certain operations |
494
-
495
- **Key Points:**
496
- - ✅ All read operations work in **read-only mode** without a wallet
497
- - ✅ Wallet can be added later via `setWallet()` to enable signing operations
498
- - ✅ Missing wallet throws `ValidationError` with code `WALLET_REQUIRED`
499
- - ⚠️ Only methods that sign transactions require a wallet
500
-
501
- ## Environment Configuration
502
-
503
- The SDK supports multiple environments (STAGE and PROD). All demo scripts and examples use a **centralized environment configuration pattern** via `.env` file.
504
-
505
- ### Quick Setup
506
-
507
- Create/edit `.env` in the repository root:
508
-
509
- ```bash
510
- # .env
511
- ENVIRONMENT=STAGE # Switch between STAGE and PROD
512
- WALLET_PRIVATE_KEY=0x... # Your wallet private key (optional)
513
- ```
514
-
515
- All demo scripts automatically read from this `.env` file:
516
-
517
- ```bash
518
- npm run demo:read-only # Uses ENVIRONMENT from .env
519
- npm run demo:dex # Uses ENVIRONMENT from .env
520
- npm run demo:liquidity # Uses ENVIRONMENT from .env
521
- ```
522
-
523
- ### Environment Values
524
-
525
- | Value | Accepts | Use Case |
526
- |-------|---------|----------|
527
- | `STAGE` | `STAGE`, `STAGING` | Development/staging |
528
- | `PROD` | `PROD`, `PRODUCTION` | Production |
529
- | Default | (if not set) | Defaults to `STAGE` with warning |
530
-
531
- ### SDK Initialization
532
-
533
- When using demo scripts or examples, the environment is automatically loaded:
534
-
535
- ```typescript
536
- import { getEnvironment } from './examples/utils/get-environment';
537
-
538
- const environment = getEnvironment(); // Reads from .env
539
- const sdk = new LaunchpadSDK({
540
- env: environment,
541
- wallet: undefined // Optional
542
- });
543
- ```
544
-
545
- ### Validation
546
-
547
- Prevent hardcoded environment values:
5
+ ## Install
548
6
 
549
7
  ```bash
550
- npm run validate:env # Validates no hardcoded 'STAGE' or 'PROD'
551
- ```
552
-
553
- ### Full Documentation
554
-
555
- See [docs/ENVIRONMENT_CONFIGURATION.md](./docs/ENVIRONMENT_CONFIGURATION.md) for:
556
- - Architecture and implementation details
557
- - Pattern for adding new scripts
558
- - Troubleshooting guide
559
- - Migration guide for existing scripts
560
-
561
- ## Token Format Migration (v3.33.0)
562
-
563
- ### Breaking Change: Strict Token Format Enforcement
564
-
565
- **v3.33.0 removes support for plain token strings** and requires all tokens to use **delimited format**.
566
-
567
- #### Old Behavior (v3.32.x and below) - DEPRECATED
568
-
569
- Plain token strings were accepted:
570
- ```typescript
571
- // ❌ NO LONGER WORKS (v3.33.0+)
572
- await sdk.addSwapLiquidityByPrice({
573
- token0: 'GALA', // Plain string
574
- token1: 'GUSDC', // Plain string
575
- fee: 3000,
576
- minPrice: '0.95',
577
- maxPrice: '1.05',
578
- amount0Desired: '100',
579
- amount1Desired: '100'
580
- });
581
- ```
582
-
583
- #### New Behavior (v3.33.0+) - REQUIRED
584
-
585
- All tokens must use **pipe-delimited** (`|`) or **dollar-delimited** (`$`) format:
586
-
587
- ```typescript
588
- // ✅ REQUIRED FORMAT (v3.33.0+)
589
- await sdk.addSwapLiquidityByPrice({
590
- token0: 'GALA|Unit|none|none', // Delimited format
591
- token1: 'GUSDC|Unit|none|none', // Delimited format
592
- fee: 3000,
593
- minPrice: '0.95',
594
- maxPrice: '1.05',
595
- amount0Desired: '100',
596
- amount1Desired: '100'
597
- });
598
- ```
599
-
600
- #### Format Options
601
-
602
- **Pipe-Delimited (Recommended):**
603
- ```typescript
604
- 'GALA|Unit|none|none'
605
- 'GUSDC|Unit|none|none'
606
- 'MYTOKEN|Unit|none|none'
607
- ```
608
-
609
- **Dollar-Delimited (Alternative):**
610
- ```typescript
611
- 'GALA$Unit$none$none'
612
- 'GUSDC$Unit$none$none'
613
- 'MYTOKEN$Unit$none$none'
614
- ```
615
-
616
- #### Migration Checklist
617
-
618
- - [ ] Search codebase for plain token strings: `'GALA'`, `'GUSDC'`, etc.
619
- - [ ] Replace with delimited format: `'GALA|Unit|none|none'`, `'GUSDC|Unit|none|none'`
620
- - [ ] Update all SDK method calls that pass token parameters
621
- - [ ] Test thoroughly - TypeScript strict mode will catch most issues
622
- - [ ] Update internal token handling code
623
-
624
- #### Affected Methods
625
-
626
- The following methods now require delimited token format:
627
- - `getSwapQuoteExactInput(token0, token1, amount)`
628
- - `getSwapQuoteExactOutput(token0, token1, amount)`
629
- - `executeSwap(token0, token1, ...)`
630
- - `addSwapLiquidityByPrice({token0, token1, ...})`
631
- - `addSwapLiquidityByTicks({token0, token1, ...})`
632
- - `removeSwapLiquidity({token0, token1, ...})`
633
- - `getSwapPoolInfo(token0, token1)`
634
-
635
- #### Security Rationale
636
-
637
- This breaking change enforces **strict token format validation** to:
638
- - ✅ **Prevent injection attacks** via token string manipulation
639
- - ✅ **Ensure deterministic parsing** with no ambiguous fallbacks
640
- - ✅ **Eliminate security gaps** from loose string handling
641
- - ✅ **Force explicit token specification** with full TokenClassKey structure
642
-
643
- Plain string support created a dangerous "escape hatch" where ambiguous token identifiers could be accepted. v3.33.0 eliminates this by requiring all tokens be properly delimited.
644
-
645
- ## Upgrading to v4.0.0
646
-
647
- ### Breaking Changes: Removed Deprecated Methods
648
-
649
- **v4.0.0 removes one deprecated method** that was superseded in v3.22.7. This is a clean removal with **minimal migration effort** - most users will not be affected.
650
-
651
- #### Removed Method: `fetchLaunchpadTokenSpotPrice()`
652
-
653
- This method was deprecated in v3.22.7 in favor of the more flexible `fetchTokenPrice()` method.
654
-
655
- **Old Code (v3.35.x and below) - NO LONGER WORKS:**
656
- ```typescript
657
- // ❌ REMOVED in v4.0.0
658
- const price = await sdk.fetchLaunchpadTokenSpotPrice('anime');
659
- console.log(`Price: ${price} USD`);
660
- ```
661
-
662
- **New Code (v4.0.0+) - REQUIRED:**
663
- ```typescript
664
- // ✅ REQUIRED - Works for both launchpad and DEX tokens
665
- const price = await sdk.fetchTokenPrice('anime');
666
- console.log(`Price: ${price} USD`);
8
+ pnpm add @gala-chain/launchpad-sdk
667
9
  ```
668
10
 
669
- #### Why This Change?
670
-
671
- The new `fetchTokenPrice()` method:
672
- - ✅ **Unified pricing** - Works for both launchpad tokens and DEX-graduated tokens
673
- - ✅ **Automatic routing** - Detects token type and fetches from correct backend
674
- - ✅ **Better performance** - Single method instead of specialized variants
675
- - ✅ **Cleaner API** - Less method duplication in SDK
11
+ The v6 DEX surface delegates to `@gala-chain/gswap-sdk`. Until its rc is published to the public registry, install the unpublished rc from the sibling package or configure the workspace link used by this repository.
676
12
 
677
- #### Migration Checklist
13
+ ## Configure
678
14
 
679
- - [ ] Search codebase for `fetchLaunchpadTokenSpotPrice(`
680
- - [ ] Replace all occurrences with `fetchTokenPrice(`
681
- - [ ] Test with both launchpad tokens (e.g., `'anime'`) and DEX tokens
682
- - [ ] Verify price results haven't changed (same calculation logic)
683
-
684
- #### Impact Assessment
685
-
686
- **Affected Users:**
687
- - ⚠️ **Only if you explicitly called** `fetchLaunchpadTokenSpotPrice()`
688
- - ✅ **Not affected if you** used `fetchTokenPrice()` or `fetchTokenSpotPrice()` methods
689
- - ✅ **Not affected if you** never queried token prices
690
-
691
- **Migration Effort:**
692
- - ⏱️ **5 minutes** - Simple find/replace across codebase
693
- - ⚙️ **Zero logic changes** - Functionality remains identical
694
- - 🎯 **Low risk** - Price calculation algorithm unchanged
695
-
696
- ### New Features: Service Clients Documentation
697
-
698
- v4.0.0 adds internal service client documentation for advanced users who need direct access to underlying blockchain services.
699
-
700
- ```typescript
15
+ ```ts
701
16
  import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
702
17
 
703
18
  const sdk = createLaunchpadSDK({
704
- wallet: 'your-private-key'
705
- });
706
-
707
- // Advanced: Direct access to DEX Backend API
708
- // Use case: Custom swap parameters or debugging
709
- const quote = await sdk.dexBackendClient.querySwapQuote({
710
- orderedTokens: [...],
711
- zeroForOne: false,
712
- inputAmount: '10',
713
- // ... additional parameters
714
- });
715
-
716
- // Advanced: Direct access to GalaChain Gateway
717
- // Use case: Custom transaction building
718
- const result = await sdk.galaChainGatewayClient.callContract({
719
- address: 'contract-address',
720
- method: 'transfer',
721
- // ... parameters
722
- });
723
- ```
724
-
725
- **⚠️ Important:** Service clients are internal implementation details. For standard operations, always use public SDK methods:
726
- - ✅ Use `sdk.buy()` instead of `sdk.galaChainGatewayClient`
727
- - ✅ Use `sdk.executeSwap()` instead of `sdk.dexBackendClient`
728
- - ✅ These public methods provide better error handling and validation
729
-
730
- For detailed service client documentation, see [docs/API-REFERENCE.md#service-clients](./docs/API-REFERENCE.md#service-clients).
731
-
732
- ### Migration Summary
733
-
734
- **For Most Users:** Nothing to do! v4.0.0 is backward compatible except for the removal of `fetchLaunchpadTokenSpotPrice()`.
735
-
736
- **If You Used `fetchLaunchpadTokenSpotPrice()`:** Replace with `fetchTokenPrice()` - identical functionality, better flexibility.
737
-
738
- **If You Need Service Client Access:** They're now documented and available for advanced use cases, but use public SDK methods when possible.
739
-
740
- ## DEX Pool Discovery & Analysis
741
-
742
- ### Overview
743
-
744
- The SDK provides complete DEX liquidity pool discovery for GalaSwap with filtering, sorting, and pagination. Perfect for finding trading pairs, analyzing pool metrics, and discovering investment opportunities.
745
-
746
- ```typescript
747
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
748
-
749
- const sdk = createLaunchpadSDK({});
750
-
751
- // Discover DEX pools with filtering
752
- const pools = await sdk.fetchDexPools({
753
- search: 'GALA', // Filter by token symbol
754
- sortBy: 'tvl', // Sort options: tvl, volume30d, volume1d
755
- sortOrder: 'desc', // asc or desc
756
- pageSize: 20 // Results per page (default: 20, max: 50)
757
- });
758
-
759
- console.log(`Found ${pools.meta?.total || 'many'} pools`);
760
- console.log(`Showing ${pools.items.length} pools with cursor-based pagination`);
761
-
762
- // Fetch ALL pools with automatic pagination
763
- const allPools = await sdk.fetchAllDexPools({
764
- search: 'GUSDC',
765
- sortBy: 'volume30d',
766
- sortOrder: 'asc'
19
+ env: 'stage',
20
+ baseUrl: 'https://lpad-backend.stage.defi.ovh.gala.com',
767
21
  });
768
22
 
769
- console.log(`Retrieved ${allPools.items.length} total pools`);
23
+ const pools = await sdk.fetchPools({ pageSize: 10 });
24
+ console.log(pools);
770
25
  ```
771
26
 
772
- ### Pool Data Structure
27
+ `Environment` is `'prod' | 'stage'`. The SDK defaults to `prod`; it does not infer an environment from a custom `baseUrl`. Use `gatewayBaseUrl` for the chain gateway override.
773
28
 
774
- Each DEX pool includes comprehensive trading metrics:
29
+ ## Launchpad writes
775
30
 
776
- ```typescript
777
- interface DexPoolData {
778
- poolPair: string; // e.g., "GALA/GUSDC"
779
- poolHash: string; // Unique pool identifier
780
- token0: string; // Token A symbol
781
- token1: string; // Token B symbol
782
- token0Price: string; // Token A USD price
783
- token1Price: string; // Token B USD price
784
- fee: string; // Fee tier (0.05%, 0.30%, 1.00%)
785
- fee24h: number; // 24h accumulated fees
786
- tvl: number; // Total Value Locked (USD)
787
- token0Tvl: number; // TVL in Token A
788
- token1Tvl: number; // TVL in Token B
789
- token0TvlUsd: number; // Token A TVL in USD
790
- token1TvlUsd: number; // Token B TVL in USD
791
- volume1d: number; // 24h trading volume
792
- volume30d: number; // 30d trading volume
793
- apr1d: number; // 24h APR for liquidity providers
794
- dayPerTvl: number; // Fee ratio (volume/TVL)
795
- }
796
- ```
797
-
798
- ### Common Use Cases
31
+ Launchpad buys, sells, and sale creation are submitted to the bundler. The result exposes `bundleId`, `uniqueKey`, and `wait()`:
799
32
 
800
- **Find high-volume pools:**
801
- ```typescript
802
- const highVolumePoolsAsc = await sdk.fetchAllDexPools({
803
- sortBy: 'volume1d',
804
- sortOrder: 'desc'
33
+ ```ts
34
+ const submission = await sdk.launchpad.buyWithNative({
35
+ vaultAddress: 'client|example-token',
36
+ quantity: '1',
37
+ expectedAmount: '1',
805
38
  });
806
39
 
807
- const topPool = highVolumePoolsAsc.items[0];
808
- console.log(`Highest volume pair: ${topPool.poolPair}`);
809
- console.log(`24h Volume: $${topPool.volume1d}`);
810
- console.log(`APR: ${topPool.apr1d.toFixed(2)}%`);
40
+ const result = await submission.wait();
41
+ console.log(submission.bundleId, result);
811
42
  ```
812
43
 
813
- **Discover GALA trading pairs:**
814
- ```typescript
815
- const galaPools = await sdk.fetchDexPools({
816
- search: 'GALA',
817
- sortBy: 'tvl',
818
- pageSize: 20
819
- });
820
-
821
- galaPools.items.forEach(pool => {
822
- console.log(`${pool.poolPair}: $${pool.tvl.toLocaleString()} TVL`);
823
- });
824
- ```
44
+ ## Token writes
825
45
 
826
- **Analyze liquidity provider opportunities:**
827
- ```typescript
828
- const liquidityOpportunities = await sdk.fetchAllDexPools({
829
- sortBy: 'apr1d',
830
- sortOrder: 'desc'
831
- });
46
+ Token transfers and other direct chain token operations go straight to the GalaChain gateway and return a `ChainResult` carrying `status`, `data`, and — read from the `x-transaction-id` and `x-block-number` response headers — `transactionId` and `blockNumber`:
832
47
 
833
- // Find pools with highest APR
834
- const bestAprPools = liquidityOpportunities.items.slice(0, 10);
835
- bestAprPools.forEach(pool => {
836
- console.log(`${pool.poolPair}: ${pool.apr1d.toFixed(2)}% APR`);
48
+ ```ts
49
+ const submission = await sdk.tokens.transfer({
50
+ tokenClassKey: 'GALA|Unit|none|none',
51
+ quantity: '1',
52
+ from: 'eth|0x0123456789012345678901234567890123456789',
53
+ to: 'eth|0x9876543210987654321098765432109876543210',
837
54
  });
838
- ```
839
-
840
- ### Sorting Options
841
-
842
- | Sort Value | Description | Best For |
843
- |-----------|-------------|----------|
844
- | `tvl` (default) | Total Value Locked | Finding main liquidity pools |
845
- | `volume1d` | 24-hour trading volume | High-activity pairs |
846
- | `volume30d` | 30-day trading volume | Trend analysis |
847
-
848
- ### Pagination
849
-
850
- The SDK uses cursor-based pagination with configurable page sizes. Use `fetchAllDexPools()` for complete enumeration:
851
55
 
852
- ```typescript
853
- // Cursor-based discovery (20 max per page)
854
- let cursor: string | undefined;
855
- const result = await sdk.fetchDexPools({ pageSize: 20, cursor });
856
- console.log(`Showing: ${result.items.length} pools`);
857
- console.log(`Has next: ${result.pageInfo?.hasNextPage}`);
858
- if (result.pageInfo?.hasNextPage) cursor = result.pageInfo?.nextCursor;
859
-
860
- // Automatic pagination - get all at once
861
- const allAtOnce = await sdk.fetchAllDexPools();
862
- console.log(`All pools: ${allAtOnce.items.length}`);
863
- ```
864
-
865
- **Cursor-Based Pagination Loop:**
866
- ```typescript
867
- // Manually iterate through paginated results using cursors
868
- let cursor: string | undefined;
869
- const allPools = [];
870
- while (true) {
871
- const result = await sdk.fetchDexPools({ pageSize: 20, cursor });
872
- allPools.push(...result.items);
873
- if (!result.pageInfo?.hasNextPage) break;
874
- cursor = result.pageInfo?.nextCursor;
875
- }
876
- console.log(`Retrieved ${allPools.length} total pools`);
56
+ console.log(submission.transactionId, submission.blockNumber, submission.data);
877
57
  ```
878
58
 
879
- ### Development vs Production Environments
59
+ Never place a private key in source control. For a write-capable SDK, provide a signer through the supported wallet configuration.
880
60
 
881
- The SDK automatically uses the correct DEX backend based on your environment configuration:
61
+ ## GSwap DEX
882
62
 
883
- ```typescript
884
- // Production (default)
885
- const prodSdk = createLaunchpadSDK({
886
- environment: 'production' // Uses prod DEX backend
887
- });
63
+ DEX calls live under `sdk.dex` and use the `@gala-chain/gswap-sdk` contracts:
888
64
 
889
- // Development
890
- const devSdk = createLaunchpadSDK({
891
- environment: 'development' // Uses dev DEX backend
892
- });
65
+ ```ts
66
+ const quote = await sdk.dex.quoting.quoteExactInput(
67
+ 'GALA|Unit|none|none',
68
+ 'GUSDC|Unit|none|none',
69
+ '100',
70
+ );
893
71
 
894
- // Custom URL
895
- const customSdk = createLaunchpadSDK({
896
- dexBackendBaseUrl: 'https://custom-dex.example.com'
897
- });
72
+ const swap = await sdk.dex.swaps.swap(
73
+ 'GALA|Unit|none|none',
74
+ 'GUSDC|Unit|none|none',
75
+ quote.fee,
76
+ { exactIn: '100', amountOutMinimum: quote.amountOut },
77
+ );
78
+ // The swap is queued (swap.mode === 'queued'); confirm() resolves the applied trade
79
+ // or throws the chain's rejection.
80
+ const applied = await swap.confirm();
81
+ console.log(applied.transactionId, applied.result);
898
82
  ```
899
83
 
900
- ## WebSocket Event Watchers (v3.29.0+)
901
-
902
- Real-time event monitoring for DEX pools and launchpad tokens using polling-based watchers with automatic deduplication.
903
-
904
- ### Public WebSocket Methods
905
-
906
- Connect and manage WebSocket connections for real-time event subscriptions:
907
-
908
- ```typescript
909
- // Connect to WebSocket
910
- sdk.connectWebSocket();
911
-
912
- // Check connection status
913
- if (sdk.isWebSocketConnected()) {
914
- console.log('✅ WebSocket connected');
915
- }
916
-
917
- // Subscribe to custom WebSocket events
918
- const unsubscribe = sdk.subscribeToEvent<MyEventType>('custom-channel', (data) => {
919
- console.log('Event received:', data);
920
- });
921
-
922
- // Cleanup when done
923
- unsubscribe();
924
-
925
- // Disconnect from WebSocket
926
- sdk.disconnectWebSocket();
927
- ```
928
-
929
- ### Event Watchers: Real-Time Pool & Token Discovery
930
-
931
- Watch for new DEX pools and launchpad tokens with optional filtering and automatic deduplication.
932
-
933
- #### Watch DEX Pool Creation
934
-
935
- Monitor new liquidity pool creation with TVL and token pair filtering:
936
-
937
- ```typescript
938
- const unsubscribe = sdk.onDexPoolCreation(
939
- (pool) => {
940
- console.log(`✨ New pool: ${pool.poolName}`);
941
- console.log(` Pair: ${pool.token0} / ${pool.token1}`);
942
- console.log(` TVL: $${pool.tvl.toFixed(2)}`);
943
- console.log(` 24h Volume: $${pool.volume1d.toFixed(2)}`);
944
- },
945
- {
946
- minTVL: 10000, // Only notify for pools with TVL >= $10,000
947
- tokens: ['GALA', 'GUSDC'], // Only GALA or GUSDC pairs
948
- intervalMs: 30000 // Poll every 30 seconds (default)
949
- }
950
- );
951
-
952
- // Stop watching after some time
953
- setTimeout(() => {
954
- unsubscribe();
955
- console.log('Stopped watching for new pools');
956
- }, 300000); // 5 minutes
957
- ```
958
-
959
- #### Watch Launchpad Token Creation
960
-
961
- Monitor new token launches with optional creator filtering:
962
-
963
- ```typescript
964
- const unsubscribe = sdk.onLaunchpadTokenCreation(
965
- (token) => {
966
- console.log(`🚀 New token: ${token.tokenName}`);
967
- console.log(` Symbol: ${token.symbol}`);
968
- console.log(` Creator: ${token.creatorAddress}`);
969
- console.log(` Created: ${new Date(token.createdAt).toISOString()}`);
970
- },
971
- {
972
- creatorAddress: 'eth|0x1234...', // Only watch specific creator (optional)
973
- intervalMs: 30000 // Poll every 30 seconds (default)
974
- }
975
- );
976
-
977
- // Example: Watch all tokens for 2 minutes
978
- setTimeout(() => {
979
- unsubscribe();
980
- console.log('Stopped watching for new tokens');
981
- }, 120000);
982
- ```
983
-
984
- ### Key Characteristics
985
-
986
- - **Polling-Based**: Intelligent polling with configurable intervals (recommended minimum: 5 seconds)
987
- - **Automatic Deduplication**: Prevents duplicate callbacks for the same pool/token
988
- - **Client-Side Filtering**: Minimizes API calls with local filtering (minTVL, token pairs, creator address)
989
- - **Cleanup Functions**: All watchers return cleanup functions for proper resource management
990
- - **Error Resilience**: Watchers continue polling after errors without blocking
991
- - **Long-Running Support**: Suitable for background monitoring in production applications
992
-
993
- ### Demo Scripts
994
-
995
- Try the event watcher examples:
996
-
997
- ```bash
998
- # Watch for new DEX pools
999
- npm run demo:watch-pools
1000
-
1001
- # Watch for new launchpad tokens
1002
- npm run demo:watch-tokens
1003
- ```
1004
-
1005
- ## AI Agent Integration
1006
-
1007
- ### For Claude Desktop Users
1008
-
1009
- Install the MCP server to enable Claude to interact with Gala Launchpad directly:
1010
-
1011
- **Full-Access Mode** (with wallet for executing trades):
1012
- ```bash
1013
- claude mcp add "galachain-launchpad" -- env PRIVATE_KEY=<YOUR_PRIVATE_KEY> ENVIRONMENT=development npx -y @gala-chain/launchpad-mcp-server@latest
1014
- ```
1015
-
1016
- **Read-Only Mode** (query data without wallet):
1017
- ```bash
1018
- claude mcp add "galachain-launchpad-readonly" -- env ENVIRONMENT=development npx -y @gala-chain/launchpad-mcp-server@latest
1019
- ```
1020
-
1021
- **Environment Variables:**
1022
- - `PRIVATE_KEY` (optional) - Your wallet private key (omit for read-only mode)
1023
- - `ENVIRONMENT` - Backend environment: `development` | `production` (default: production)
1024
- - `DEBUG` - Enable debug logging: `true` | `false` (default: false)
1025
- - `TIMEOUT` - Request timeout in milliseconds (default: 30000)
1026
-
1027
- **Features**: 224 tools for complete Gala Launchpad operations including:
1028
- - Pool management, pricing, and token discovery
1029
- - Token trading with slippage protection
1030
- - Token creation and management
1031
- - Balance and portfolio queries
1032
- - Wallet status checking and configuration
1033
- - Price history and analysis (Node.js only)
1034
- - Comments and social features
1035
- - Transfers and transactions
1036
-
1037
- See: [MCP Server Documentation](../../mcp-server/README.md)
1038
-
1039
- **Try slash commands** (MCP v1.4.0+):
1040
- ```
1041
- /galachain-launchpad:analyze-token tokenName=anime
1042
- /galachain-launchpad:portfolio
1043
- /galachain-launchpad:buy-tokens tokenName=anime galaAmount=100
1044
- ```
1045
-
1046
- ### For AI Developers
1047
-
1048
- Need help with SDK integration, trading bots, or MCP server development?
1049
-
1050
- Ask **[@agent-galachain-launchpad-developer](../../@agent-galachain-launchpad-developer.md)** - a specialized AI agent with expertise in:
1051
- - Complete SDK API (230+ methods)
1052
- - Optional wallet configuration and dual operational modes
1053
- - Trading patterns and DeFi best practices
1054
- - MCP server architecture
1055
- - Error handling strategies
1056
- - Performance optimization
1057
-
1058
- **Full Integration Guide**: [AI Agent Guide](./docs/AI-AGENT-GUIDE.md)
1059
-
1060
- ## Quick Start
1061
-
1062
- ### Using Helper Functions (Recommended)
1063
-
1064
- ```typescript
1065
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
1066
-
1067
- // Auto-detecting SDK creation (easiest method)
1068
- const sdk = createLaunchpadSDK({
1069
- wallet: 'your-private-key-or-mnemonic' // Auto-detects format!
1070
- });
1071
-
1072
- // Clean, direct result access - All methods use options objects
1073
-
1074
- // Pool Management - Direct result properties
1075
- const pools = await sdk.fetchPools({ type: 'recent', pageSize: 20 });
1076
- console.log(`Found ${pools.meta?.total} pools`);
1077
- console.log(`Has next page: ${pools.pageInfo?.hasNextPage}`);
1078
-
1079
- const badges = await sdk.fetchTokenBadges('dragnrkti');
1080
- console.log(`Volume badges: ${badges.volumeBadges.length}`);
1081
- console.log(`Engagement badges: ${badges.engagementBadges.length}`);
1082
-
1083
- const details = await sdk.fetchPoolDetails('dragnrkti');
1084
- console.log(`Sale status: ${details.saleStatus}`);
1085
- console.log(`Native token quantity: ${details.nativeTokenQuantity}`);
1086
-
1087
- // Price Calculations - Direct amount access
1088
- const buyAmount = await sdk.calculateBuyAmount({
1089
- tokenName: 'dragnrkti',
1090
- amount: '1', // 1 GALA
1091
- type: 'native'
1092
- });
1093
- console.log(`Buy amount: ${buyAmount.amount}`);
1094
- console.log(`Transaction fee: ${buyAmount.transactionFee}`);
1095
-
1096
- // Trading Operations - Required expectedAmount and slippageToleranceFactor
1097
- const buyResult = await sdk.buy({
1098
- tokenName: 'dragnrkti',
1099
- amount: '1',
1100
- type: 'native',
1101
- expectedAmount: buyAmount.amount, // Required: from calculation
1102
- slippageToleranceFactor: 0.05 // Required: decimal format (5% slippage)
1103
- });
1104
- console.log(`Transaction ID: ${buyResult.transactionId}`);
1105
-
1106
- // Data & Analytics - Clean pagination
1107
- const trades = await sdk.fetchTrades({ tokenName: 'dragnrkti' });
1108
- console.log(`Found ${trades.meta.total} trades`);
1109
- console.log(`Page ${trades.meta.page} of ${trades.meta.totalPages}`);
1110
- trades.items.forEach(trade => {
1111
- console.log(`Trade: ${trade.tradeType} ${trade.tokenAmount} at ${trade.createdAt.toISOString()}`);
1112
- });
1113
-
1114
- const comments = await sdk.fetchComments({ tokenName: 'dragnrkti' });
1115
- console.log(`${comments.meta.total} comments found`);
1116
-
1117
- // User Operations - Direct balance access
1118
- const galaBalance = await sdk.fetchGalaBalance();
1119
- console.log(`GALA Balance: ${galaBalance.balance}`);
1120
- console.log(`Last updated: ${galaBalance.lastUpdated.toISOString()}`);
1121
-
1122
- const tokenBalance = await sdk.fetchTokenBalance({
1123
- tokenName: 'dragnrkti',
1124
- address: sdk.getAddress()
1125
- });
1126
- console.log(`Token balance: ${tokenBalance.quantity}`);
1127
- console.log(`USD value: $${tokenBalance.holdingPriceUsd}`);
1128
-
1129
- // Profile - Direct user data
1130
- const profile = await sdk.fetchProfile();
1131
- console.log(`Profile name: ${profile.fullName || 'Not set'}`);
1132
-
1133
- // URL Utilities - Generate frontend URLs
1134
- const tokenUrl = sdk.getUrlByTokenName('dragnrkti');
1135
- console.log(`View token: ${tokenUrl}`);
1136
- // Output: https://lpad-frontend-test1.defi.gala.com/buy-sell/dragnrkti
1137
- ```
1138
-
1139
- ## Auto-Pagination Feature
1140
-
1141
- The SDK now supports automatic pagination for pool fetching with three powerful modes:
1142
-
1143
- ### Three Pagination Modes
1144
-
1145
- ```typescript
1146
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
1147
-
1148
- const sdk = createLaunchpadSDK({
1149
- wallet: 'your-private-key-or-mnemonic'
1150
- });
1151
-
1152
- // MODE 1: Single Page (backward compatible)
1153
- // Limit <= 20: Single API call
1154
- const recent = await sdk.fetchPools({ type: 'recent', pageSize: 20 });
1155
- console.log(`Fetched ${recent.items.length} pools in one request`);
1156
-
1157
- // MODE 2: Multi-Page Auto-Fetch
1158
- // Limit > 20: Automatic concurrent multi-page fetching
1159
- const large = await sdk.fetchPools({ type: 'popular', pageSize: 100 });
1160
- console.log(`Fetched ${large.items.length} pools across multiple pages`);
1161
- // Internally uses cursor-based pagination to efficiently fetch all items
1162
-
1163
- // MODE 3: Infinite Fetch
1164
- // Limit = 0: Fetches ALL available pools
1165
- const all = await sdk.fetchAllPools();
1166
- console.log(`Fetched all ${all.items.length} pools from the platform`);
1167
-
1168
- // Convenience method for "fetch all" pattern
1169
- const allRecent = await sdk.fetchAllPools({ type: 'recent' });
1170
- console.log(`Total pools: ${allRecent.meta.total}`);
1171
- ```
1172
-
1173
- ### Concurrency Configuration
1174
-
1175
- The SDK uses `MAX_CONCURRENT_POOL_FETCHES` to control parallel API requests:
1176
-
1177
- ```typescript
1178
- import { MAX_CONCURRENT_POOL_FETCHES } from '@gala-chain/launchpad-sdk';
1179
-
1180
- console.log(`SDK fetches up to ${MAX_CONCURRENT_POOL_FETCHES} pages concurrently`);
1181
- // Output: "SDK fetches up to 5 pages concurrently"
1182
- ```
1183
-
1184
- **Default**: 5 concurrent requests
1185
- **Benefit**: Balances speed with API rate limits
1186
-
1187
- ### Performance Benefits
1188
-
1189
- | Scenario | Pages Fetched | Network Calls | Time (Sequential) | Time (Concurrent) | Improvement |
1190
- |----------|---------------|---------------|-------------------|-------------------|-------------|
1191
- | 20 pools | 1 page | 1 call | ~200ms | ~200ms | No change |
1192
- | 100 pools | 5 pages | 5 calls | ~1000ms | ~200ms | 5x faster |
1193
- | 500 pools | 25 pages | 25 calls | ~5000ms | ~1000ms | 5x faster |
1194
- | All pools (1000+) | 50+ pages | 50+ calls | ~10,000ms | ~2000ms | 5x faster |
1195
-
1196
- ### When to Use Each Mode
1197
-
1198
- **Single Page (limit <= 20)**
1199
- - Quick queries
1200
- - UI pagination with next/previous buttons
1201
- - When you only need recent results
1202
-
1203
- **Multi-Page (limit > 20)**
1204
- - Analytics dashboards
1205
- - Bulk operations on specific token counts
1206
- - When you know how many results you need
1207
-
1208
- **Infinite (limit = 0 or fetchAllPools())**
1209
- - Complete market scans
1210
- - Full portfolio analysis
1211
- - Trading bot initialization
1212
- - Data exports and backups
1213
-
1214
- ### Example: Market Scanner
1215
-
1216
- ```typescript
1217
- async function scanEntireMarket() {
1218
- // Fetch all pools at once (auto-pagination handles everything)
1219
- const allPools = await sdk.fetchAllPools({ type: 'popular' });
1220
-
1221
- console.log(`Scanning ${allPools.meta.total} pools...`);
1222
-
1223
- // Filter for interesting opportunities
1224
- const highVolume = allPools.items.filter(pool =>
1225
- parseFloat(pool.volumeGala) > 10000
1226
- );
1227
-
1228
- console.log(`Found ${highVolume.length} high-volume pools`);
1229
-
1230
- return highVolume;
1231
- }
1232
- ```
1233
-
1234
- ### New Methods
1235
-
1236
- **fetchAllPools(options?)**
1237
-
1238
- Convenience method that automatically fetches all available pools:
1239
-
1240
- ```typescript
1241
- // Fetch all recent pools
1242
- const allRecent = await sdk.fetchAllPools({ type: 'recent' });
1243
-
1244
- // Fetch all pools matching search
1245
- const dragons = await sdk.fetchAllPools({ search: 'dragon' });
1246
-
1247
- // Fetch specific token across all results
1248
- const specific = await sdk.fetchAllPools({ tokenName: 'anime' });
1249
-
1250
- // Automatic pagination handles all pages internally
1251
- const all = await sdk.fetchAllPools();
1252
- ```
1253
-
1254
- ### Stream Filtering (v5.7.0+)
1255
-
1256
- Filter pools by streaming activity and language:
1257
-
1258
- ```typescript
1259
- // Find pools with upcoming scheduled shows
1260
- const upcomingShows = await sdk.fetchPools({ hasUpcomingShows: true });
1261
-
1262
- // Find pools that recently went live (last 24 hours)
1263
- const recentlyLive = await sdk.fetchPools({ recentlyStreamed: 24 });
1264
-
1265
- // Find active streaming communities (last week)
1266
- const activeCommunities = await sdk.fetchAllPools({ recentlyStreamed: 168 });
1267
-
1268
- // Filter by stream language (ISO 639-1 codes)
1269
- const englishPools = await sdk.fetchPools({ language: 'en' });
1270
- const spanishPools = await sdk.fetchPools({ language: 'es' });
1271
-
1272
- // Pool data includes stream stats
1273
- const pools = await sdk.fetchPools({ type: 'popular' });
1274
- pools.items.forEach(pool => {
1275
- console.log(`${pool.tokenName}:`);
1276
- console.log(` Viewers: ${pool.currentViewerCount || 0}`);
1277
- console.log(` Peak viewers: ${pool.peakViewerCount || 0}`);
1278
- console.log(` Last streamed: ${pool.lastStreamedAt || 'Never'}`);
1279
- });
1280
- ```
1281
-
1282
- ### Manual SDK Creation (Alternative)
1283
-
1284
- ```typescript
1285
- import { Wallet } from 'ethers';
1286
- import { LaunchpadSDK } from '@gala-chain/launchpad-sdk';
1287
-
1288
- // Create wallet manually
1289
- const wallet = new Wallet(process.env.PRIVATE_KEY);
1290
-
1291
- // Initialize SDK
1292
- const sdk = new LaunchpadSDK({
1293
- wallet: wallet,
1294
- baseUrl: 'https://lpad-backend-dev1.defi.gala.com',
1295
- timeout: 30000,
1296
- debug: false
1297
- });
1298
-
1299
- // Same clean API available
1300
- const pools = await sdk.fetchPools({ type: 'recent' });
1301
- console.log(`${pools.total} pools found`);
1302
- ```
1303
-
1304
- ## Complete Example: Trading Flow with Clean Results
1305
-
1306
- ```typescript
1307
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
1308
-
1309
- // 1. Create SDK with auto-detection
1310
- const sdk = createLaunchpadSDK({
1311
- wallet: 'your-private-key-or-mnemonic'
1312
- });
1313
-
1314
- // 2. Check available pools - direct access to results
1315
- const pools = await sdk.fetchPools({
1316
- type: 'recent',
1317
- pageSize: 20
1318
- });
1319
-
1320
- console.log(`Found ${pools.meta.total} pools`);
1321
- pools.items.forEach(pool => {
1322
- console.log(`Pool: ${pool.tokenName} created at ${pool.createdAt}`);
1323
- });
1324
-
1325
- // 3. Get price quote - direct amount access
1326
- const quote = await sdk.calculateBuyAmount({
1327
- tokenName: 'tinyevil',
1328
- amount: '100',
1329
- type: 'native'
1330
- });
1331
-
1332
- console.log(`Buying 100 GALA worth will get you: ${quote.amount} TINYEVIL`);
1333
- console.log(`Transaction fee: ${quote.transactionFee} GALA`);
1334
- console.log(`Reverse bonding curve fee: ${quote.reverseBondingCurveFee} GALA`);
1335
-
1336
- // 4. Execute trade with slippage protection - requires expectedAmount
1337
- const buyResult = await sdk.buy({
1338
- tokenName: 'tinyevil',
1339
- amount: '100',
1340
- type: 'native',
1341
- expectedAmount: quote.amount, // Required: from calculation above
1342
- slippageToleranceFactor: 0.05 // Required: decimal format for 5% slippage
1343
- });
1344
-
1345
- console.log(`Transaction submitted: ${buyResult.transactionId}`);
1346
-
1347
- // 5. Check trade history - clean pagination
1348
- const trades = await sdk.fetchTrades({ tokenName: 'tinyevil' });
1349
- console.log(`Found ${trades.meta.total} trades on page ${trades.meta.page}`);
1350
- console.log(`Has more pages: ${trades.meta.page < trades.meta.totalPages}`);
1351
-
1352
- trades.items.forEach(trade => {
1353
- console.log(`${trade.tradeType}: ${trade.tokenAmount} at ${trade.createdAt.toISOString()}`);
1354
- });
1355
-
1356
- // 6. Post a comment about your trade
1357
- const comment = await sdk.postComment({
1358
- tokenName: 'tinyevil',
1359
- content: 'Just bought some tokens! Great project!'
1360
- });
1361
-
1362
- console.log(`Comment posted with ID: ${comment.id}`);
1363
-
1364
- // 7. Check your balance - direct balance access
1365
- const galaBalance = await sdk.fetchGalaBalance();
1366
- console.log(`GALA Balance: ${galaBalance.balance}`);
1367
- console.log(`Decimals: ${galaBalance.decimals}`);
1368
- console.log(`Last updated: ${galaBalance.lastUpdated.toISOString()}`);
1369
-
1370
- const tokenBalance = await sdk.fetchTokenBalance({
1371
- tokenName: 'tinyevil',
1372
- address: sdk.getAddress()
1373
- });
1374
-
1375
- console.log(`TINYEVIL Balance: ${tokenBalance.quantity}`);
1376
- console.log(`USD Value: $${tokenBalance.holdingPriceUsd}`);
1377
- console.log(`GALA Value: ${tokenBalance.holdingPriceGala} GALA`);
1378
- console.log(`Finalized: ${tokenBalance.isFinalized}`);
1379
- ```
1380
-
1381
- ## Transfer Operations
1382
-
1383
- Transfer GALA and launchpad tokens between wallets with EIP-712 signatures:
1384
-
1385
- ```typescript
1386
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
1387
-
1388
- const sdk = createLaunchpadSDK({
1389
- wallet: 'your-private-key-or-mnemonic'
1390
- });
1391
-
1392
- // Transfer GALA tokens - direct result access
1393
- const galaTransfer = await sdk.transferGala({
1394
- recipientAddress: 'eth|1234567890abcdef1234567890abcdef12345678', // or 0x format
1395
- amount: '1', // 1 GALA
1396
- uniqueKey: 'galaconnect-operation-my-transfer-123' // Optional for idempotency
1397
- });
1398
-
1399
- console.log(`GALA Transfer ID: ${galaTransfer.transactionId}`);
1400
- console.log(`Status: ${galaTransfer.status}`);
1401
-
1402
- // Transfer launchpad tokens - direct result access
1403
- const tokenTransfer = await sdk.transferToken({
1404
- to: '0x9876543210fedcba9876543210fedcba98765432', // or eth| format
1405
- tokenName: 'tinyevil',
1406
- amount: '1000000', // Token amount in smallest unit
1407
- uniqueKey: 'galaconnect-operation-token-transfer-456' // Optional for idempotency
1408
- });
1409
-
1410
- console.log(`Token Transfer ID: ${tokenTransfer.transactionId}`);
1411
- console.log(`Status: ${tokenTransfer.status}`);
1412
- ```
1413
-
1414
- ### Transfer Features
1415
- - **EIP-712 Signatures**: Secure blockchain transactions
1416
- - **Address Format Handling**: Supports both `0x` and `eth|` formats
1417
- - **Idempotency**: Optional unique keys prevent duplicate transfers (must use `galaswap-operation-` or `galaconnect-operation-` prefix)
1418
- - **Comprehensive Validation**: Amount limits, address formats, token names, unique key formats
1419
- - **GalaChain Integration**: Direct transfers via GalaChain gateway
1420
- - **Error Handling**: Detailed error types for different failure scenarios
1421
-
1422
- ## Lock/Unlock Operations
1423
-
1424
- Lock and unlock tokens on GalaChain for staking, escrow, and vesting mechanisms:
1425
-
1426
- ```typescript
1427
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
1428
-
1429
- const sdk = createLaunchpadSDK({
1430
- wallet: 'your-private-key-or-mnemonic'
1431
- });
1432
-
1433
- // Lock tokens - caller becomes lock authority by default
1434
- const lockResult = await sdk.lockToken({
1435
- tokenName: 'tinyevil',
1436
- amount: '1000' // Token amount in smallest unit
1437
- });
1438
-
1439
- console.log(`Locked tokens, tx: ${lockResult.transactionId}`);
1440
-
1441
- // Lock with custom authority and expiration
1442
- const escrowLock = await sdk.lockToken({
1443
- tokenName: 'tinyevil',
1444
- amount: '5000',
1445
- lockAuthority: 'eth|0xEscrowContract...', // Third party can unlock
1446
- expires: Date.now() + 7 * 24 * 60 * 60 * 1000, // Auto-release in 1 week
1447
- name: 'escrow-deal-123' // Named lock for matching
1448
- });
1449
-
1450
- // Unlock tokens - must be called by lock authority
1451
- const unlockResult = await sdk.unlockToken({
1452
- tokenName: 'tinyevil',
1453
- amount: '1000'
1454
- });
1455
-
1456
- console.log(`Unlocked tokens, tx: ${unlockResult.transactionId}`);
1457
-
1458
- // Unlock specific named lock
1459
- await sdk.unlockToken({
1460
- tokenName: 'tinyevil',
1461
- amount: '5000',
1462
- name: 'escrow-deal-123' // Must match lock name
1463
- });
1464
- ```
1465
-
1466
- ### Lock Features
1467
- - **Lock Authority**: Specify who can unlock (defaults to caller)
1468
- - **Expiration**: Optional auto-release timestamp
1469
- - **Named Locks**: Identify locks by name for targeted unlocks
1470
- - **EIP-712 Signatures**: Secure blockchain transactions
1471
- - **Idempotency**: Optional unique keys prevent duplicate operations
1472
-
1473
- ### Use Cases
1474
- - **Staking**: Lock tokens for reward programs
1475
- - **Escrow**: Third-party holds tokens until conditions met
1476
- - **Vesting**: Time-locked token releases with expiration
1477
-
1478
- ## Cross-Chain Bridge Operations
1479
-
1480
- The SDK provides comprehensive cross-chain bridging for GalaChain ↔ Ethereum and GalaChain ↔ Solana transfers.
1481
-
1482
- ### Configuration
1483
-
1484
- ```typescript
1485
- import { LaunchpadSDK } from '@gala-chain/launchpad-sdk';
1486
-
1487
- const sdk = new LaunchpadSDK({
1488
- wallet: process.env.PRIVATE_KEY,
1489
- // Bridge configuration (optional - enables bridge operations)
1490
- ethereumPrivateKey: process.env.ETHEREUM_PRIVATE_KEY, // Required for Ethereum bridging
1491
- solanaPrivateKey: process.env.SOLANA_PRIVATE_KEY, // Required for Solana bridging
1492
- });
1493
- ```
1494
-
1495
- ### Wallet Balance Queries
1496
-
1497
- Query Ethereum and Solana wallet balances with two approaches:
1498
-
1499
- **Single Token Queries (Fast - 1 RPC call)**
1500
- ```typescript
1501
- // Single ERC-20 token balance
1502
- const gala = await sdk.fetchEthereumWalletTokenBalance('GALA');
1503
- // Returns: { symbol: 'GALA', quantity: '1234.56', decimals: 8, contractAddress: '0x...', isNative: false }
1504
-
1505
- // Native ETH balance
1506
- const eth = await sdk.fetchEthereumWalletNativeBalance();
1507
- // Returns: { symbol: 'ETH', quantity: '0.5', decimals: 18, contractAddress: null, isNative: true }
1508
-
1509
- // Single SPL token balance (Solana)
1510
- const solGala = await sdk.fetchSolanaWalletTokenBalance('GALA');
1511
- // Returns: { symbol: 'GALA', quantity: '789.01', decimals: 8, contractAddress: '...', isNative: false }
1512
-
1513
- // Native SOL balance
1514
- const sol = await sdk.fetchSolanaWalletNativeBalance();
1515
- // Returns: { symbol: 'SOL', quantity: '2.5', decimals: 9, contractAddress: null, isNative: true }
1516
- ```
1517
-
1518
- **All Tokens Queries (Complete portfolio view)**
1519
- ```typescript
1520
- // Ethereum: ETH + all supported ERC-20s (GALA, GWETH, GUSDC, GUSDT, GWTRX, GWBTC)
1521
- const allEth = await sdk.fetchEthereumWalletAllBalances();
1522
- console.log(allEth.native.quantity); // ETH balance
1523
- console.log(allEth.tokens); // 6 ERC-20 balances
1524
- console.log(allEth.address); // Wallet address
1525
- console.log(allEth.timestamp); // Query timestamp
1526
-
1527
- // Solana: SOL + all supported SPL tokens (GALA, GSOL)
1528
- const allSol = await sdk.fetchSolanaWalletAllBalances();
1529
- console.log(allSol.native.quantity); // SOL balance
1530
- console.log(allSol.tokens); // 2 SPL balances
1531
- ```
1532
-
1533
- **When to use which:**
1534
- - **Single-token queries**: Quick checks, performance-critical scenarios, frequent polling
1535
- - **All-tokens queries**: Portfolio dashboards, wallet UIs, multi-token operations
1536
-
1537
- ### Bridge Operations
1538
-
1539
- ```typescript
1540
- // Estimate fees before bridging
1541
- const fee = await sdk.estimateBridgeFee({
1542
- tokenSymbol: 'GALA',
1543
- destinationChain: 'Ethereum',
1544
- amount: '1000',
1545
- });
1546
-
1547
- // Bridge OUT: GalaChain → Ethereum/Solana
1548
- const result = await sdk.bridgeOut({
1549
- tokenSymbol: 'GALA',
1550
- amount: '1000',
1551
- destinationChain: 'Ethereum',
1552
- recipientAddress: '0x...',
1553
- });
1554
-
1555
- // Bridge IN: Ethereum/Solana → GalaChain
1556
- const result = await sdk.bridgeIn({
1557
- tokenSymbol: 'GALA',
1558
- amount: '1000',
1559
- sourceChain: 'Ethereum',
1560
- });
1561
-
1562
- // Check bridge status
1563
- const status = await sdk.getBridgeStatus(result.transactionHash);
1564
- ```
1565
-
1566
- ### Supported Tokens
1567
-
1568
- | Token | Symbol | Ethereum | Solana | Decimals |
1569
- |-------|--------|----------|--------|----------|
1570
- | GALA | GALA | ✅ | ✅ | 8 |
1571
- | Wrapped ETH | GWETH | ✅ | - | 18 |
1572
- | USD Coin | GUSDC | ✅ | - | 6 |
1573
- | Tether USD | GUSDT | ✅ | - | 6 |
1574
- | Wrapped TRON | GWTRX | ✅ | - | 6 |
1575
- | Wrapped BTC | GWBTC | ✅ | - | 8 |
1576
- | Wrapped SOL | GSOL | - | ✅ | 9 |
1577
-
1578
- ## Multi-Wallet Support
1579
-
1580
- The SDK supports **per-operation wallet overrides** for testing multi-wallet workflows without creating new SDK instances. This is ideal for:
1581
- - Testing trading scenarios with multiple wallets
1582
- - Building multi-user applications
1583
- - Simulating different user behaviors
1584
- - Creating automated trading bots
1585
-
1586
- ### Private Key Override Pattern
1587
-
1588
- All signing operations accept an optional `privateKey` parameter to use a different wallet for that specific operation:
1589
-
1590
- ```typescript
1591
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
1592
-
1593
- // Create SDK with your main wallet
1594
- const sdk = createLaunchpadSDK({
1595
- wallet: 'your-main-private-key'
1596
- });
1597
-
1598
- // Different wallet's private key (must be in '0x' + 64 hex format)
1599
- const busterPrivateKey = '0x1234567890abcdef...'; // Buster's wallet
1600
-
1601
- // 1. Send GALA from main wallet to Buster
1602
- await sdk.transferGala({
1603
- recipientAddress: '0xBusterAddress...',
1604
- amount: '1000'
1605
- // Uses main SDK wallet (no privateKey override)
1606
- });
1607
-
1608
- // 2. Have Buster buy tokens using his own wallet
1609
- const buyResult = await sdk.buy({
1610
- tokenName: 'tinyevil',
1611
- amount: '100',
1612
- type: 'native',
1613
- expectedAmount: '500000',
1614
- slippageToleranceFactor: 0.05,
1615
- privateKey: busterPrivateKey // Override to use Buster's wallet
1616
- });
1617
-
1618
- // 3. Have Buster post a comment
1619
- await sdk.postComment({
1620
- tokenName: 'tinyevil',
1621
- content: 'Great buy!',
1622
- privateKey: busterPrivateKey // Buster posts the comment
1623
- });
1624
-
1625
- // 4. Main wallet continues operations normally
1626
- const mainWalletBalance = await sdk.fetchGalaBalance();
1627
- // Uses main SDK wallet address
1628
- ```
1629
-
1630
- ### Supported Operations with Private Key Override
1631
-
1632
- All signing operations support the `privateKey` parameter:
1633
-
1634
- **Trading Operations:**
1635
- - `buy(options)` - Buy tokens with different wallet
1636
- - `sell(options)` - Sell tokens with different wallet
1637
-
1638
- **Token Creation:**
1639
- - `launchToken(data)` - Create token from different wallet
1640
- - `uploadTokenImage(options)` - Upload image for token
1641
-
1642
- **Transfer Operations:**
1643
- - `transferGala(options)` - Transfer GALA from different wallet
1644
- - `transferToken(options)` - Transfer tokens from different wallet
1645
-
1646
- **Social & Profile:**
1647
- - `postComment(options)` - Post comment from different wallet
1648
- - `updateProfile(data)` - Update profile for different wallet
1649
- - `uploadProfileImage(options)` - Upload profile image for different wallet
1650
-
1651
- ### Complete Multi-Wallet Example
1652
-
1653
- ```typescript
1654
- import { createLaunchpadSDK, createWallet } from '@gala-chain/launchpad-sdk';
1655
-
1656
- // Main SDK instance
1657
- const sdk = createLaunchpadSDK({
1658
- wallet: 'your-main-private-key'
1659
- });
1660
-
1661
- // Create a test wallet for "Buster"
1662
- const busterWallet = createWallet(); // Random wallet
1663
- const busterPrivateKey = busterWallet.privateKey;
1664
- const busterAddress = busterWallet.address;
1665
-
1666
- console.log(`Buster's address: ${busterAddress}`);
1667
-
1668
- // 1. Fund Buster with GALA from main wallet
1669
- await sdk.transferGala({
1670
- recipientAddress: busterAddress,
1671
- amount: '1000'
1672
- });
1673
-
1674
- // 2. Send Buster some tokens from main wallet
1675
- await sdk.transferToken({
1676
- to: busterAddress,
1677
- tokenName: 'tinyevil',
1678
- amount: '10000'
1679
- });
1680
-
1681
- // 3. Have Buster send some tokens back to main wallet
1682
- await sdk.transferToken({
1683
- to: sdk.getEthereumAddress(), // Main wallet address
1684
- tokenName: 'tinyevil',
1685
- amount: '5000',
1686
- privateKey: busterPrivateKey // Buster's wallet signs
1687
- });
1688
-
1689
- // 4. Have Buster buy more tokens
1690
- const buyQuote = await sdk.calculateBuyAmount({
1691
- tokenName: 'tinyevil',
1692
- amount: '100',
1693
- type: 'native'
1694
- });
1695
-
1696
- await sdk.buy({
1697
- tokenName: 'tinyevil',
1698
- amount: '100',
1699
- type: 'native',
1700
- expectedAmount: buyQuote.amount,
1701
- slippageToleranceFactor: 0.05,
1702
- privateKey: busterPrivateKey // Buster buys
1703
- });
1704
-
1705
- // 5. Have Buster sell some tokens
1706
- const sellQuote = await sdk.calculateSellAmount({
1707
- tokenName: 'tinyevil',
1708
- amount: '50',
1709
- type: 'native'
1710
- });
1711
-
1712
- await sdk.sell({
1713
- tokenName: 'tinyevil',
1714
- amount: '50',
1715
- type: 'native',
1716
- expectedAmount: sellQuote.amount,
1717
- slippageToleranceFactor: 0.05,
1718
- privateKey: busterPrivateKey // Buster sells
1719
- });
1720
-
1721
- // 6. Check final balances for both wallets
1722
- const mainBalance = await sdk.fetchGalaBalance(); // Main wallet
1723
- const busterBalance = await sdk.fetchGalaBalance(busterAddress); // Buster's wallet
1724
-
1725
- console.log(`Main wallet: ${mainBalance.balance} GALA`);
1726
- console.log(`Buster wallet: ${busterBalance.balance} GALA`);
1727
- ```
1728
-
1729
- ### Private Key Format Requirements
1730
-
1731
- The `privateKey` parameter must be a string in the format:
1732
- - **Format**: `'0x' + 64 hexadecimal characters`
1733
- - **Example**: `'0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef'`
1734
- - **Invalid**: Raw hex without '0x' prefix, mnemonic phrases, addresses
1735
-
1736
- ```typescript
1737
- // ✅ Valid private key formats
1738
- const validKey1 = '0x' + 'a'.repeat(64); // Correct format
1739
- const validKey2 = wallet.privateKey; // From ethers.js Wallet
1740
-
1741
- // ❌ Invalid formats (will throw validation error)
1742
- const invalidKey1 = 'a'.repeat(64); // Missing '0x' prefix
1743
- const invalidKey2 = 'word1 word2 ... word24'; // Mnemonic not accepted
1744
- const invalidKey3 = '0x123'; // Too short
1745
- ```
1746
-
1747
- ## Available Methods & Result Types
1748
-
1749
- ### **Fetch Operations**
1750
-
1751
- ```typescript
1752
- // Pool Management
1753
- fetchPools(options?): Promise<PoolsResult>
1754
- // Returns: { items, meta: { total }, pageInfo: { hasNextPage, nextCursor } }
1755
- // Supports cursor-based pagination with configurable pageSize
1756
-
1757
- fetchAllPools(options?): Promise<PoolsResult>
1758
- // Returns: { items, meta: { total }, pageInfo: { hasNextPage } }
1759
- // Convenience method that fetches ALL pools using cursor-based pagination
1760
-
1761
- fetchTokenDistribution(tokenName): Promise<TokenDistributionResult>
1762
- // Returns: { holders, totalSupply, totalHolders, lastUpdated }
1763
-
1764
- fetchTokenBadges(tokenName): Promise<TokenBadgesResult>
1765
- // Returns: { volumeBadges, engagementBadges }
1766
-
1767
- fetchPoolDetails(tokenName): Promise<PoolDetailsData>
1768
- // Returns: { basePrice, maxSupply, saleStatus, nativeTokenQuantity, ... }
1769
-
1770
- fetchTokenDetails(tokenId): Promise<TokenDetails>
1771
- // Returns: { symbol, decimals, name, image, verified, network, chainId, contractAddress, tradingEnabled, ... }
1772
- // Supports flexible tokenId: string ('GUSDC|Unit|none|eth:0x...') or object format
1773
-
1774
- fetchVolumeData(options): Promise<GraphDataResult>
1775
- // Returns: { dataPoints }
1776
-
1777
- // Trade & User Data
1778
- fetchTrades(options): Promise<TradesResult>
1779
- // Returns: { items, meta: { total }, pageInfo: { hasNextPage, nextCursor } }
1780
-
1781
- fetchGalaBalance(address?): Promise<GalaBalanceInfo>
1782
- // Returns: { userAddress, balance, decimals, lastUpdated }
1783
-
1784
- fetchTokenBalance(options): Promise<TokenBalanceInfo>
1785
- // Returns: { quantity, holdingPriceUsd, holdingPriceGala, isFinalized, ... }
1786
-
1787
- fetchComments(options): Promise<CommentsResult>
1788
- // Returns: { items, meta: { total }, pageInfo: { hasNextPage, nextCursor } }
1789
-
1790
- fetchProfile(address?): Promise<UserProfile>
1791
- // Returns: { fullName, profileImage, address, ... }
1792
-
1793
- fetchLaunchTokenFee(): Promise<number>
1794
- // Returns: Current GALA fee required to launch a new token (e.g., 0.001)
1795
- ```
1796
-
1797
- ### **Calculate Operations**
1798
-
1799
- ```typescript
1800
- // Price Calculations
1801
- calculateBuyAmount(options): Promise<AmountCalculationResult>
1802
- // Returns: { amount, reverseBondingCurveFee, transactionFee }
1803
-
1804
- calculateSellAmount(options): Promise<AmountCalculationResult>
1805
- // Returns: { amount, reverseBondingCurveFee, transactionFee }
1806
-
1807
- calculateInitialBuyAmount(options): Promise<AmountCalculationResult>
1808
- // Returns: { amount, reverseBondingCurveFee, transactionFee }
1809
-
1810
- calculateBuyAmountForGraduation(tokenName): Promise<AmountCalculationResult>
1811
- // Returns: { amount, reverseBondingCurveFee, transactionFee }
1812
- // Calculates exact GALA cost to buy all remaining tokens and graduate pool
1813
-
1814
- // Local Calculations (Client-Side, No Network)
1815
- calculateBuyAmountLocal(options): Promise<AmountCalculationResult>
1816
- // Options: { tokenName, amount, type: 'native' | 'exact' }
1817
- // Returns: { amount, reverseBondingCurveFee: '0', transactionFee, gasFee }
1818
- // Instant buy calculation using local bonding curve formulas
1819
-
1820
- calculateSellAmountLocal(options): Promise<AmountCalculationResult>
1821
- // Options: { tokenName, amount, type: 'native' | 'exact', maxSupply, minFeePortion, maxFeePortion }
1822
- // Returns: { amount, reverseBondingCurveFee, transactionFee, gasFee }
1823
- // Instant sell calculation with reverse bonding curve fees
1824
-
1825
- // External Calculations (GalaChain Network)
1826
- calculateBuyAmountExternal(options): Promise<AmountCalculationResult>
1827
- // Explicit external calculation wrapper (same as calculateBuyAmount)
1828
-
1829
- calculateSellAmountExternal(options): Promise<AmountCalculationResult>
1830
- // Explicit external calculation wrapper (same as calculateSellAmount)
1831
-
1832
- // Note: Pass `calculateAmountMode: 'local' | 'external'` to override SDK default mode
1833
-
1834
- // Price History Operations (DEX Backend API, Node.js only)
1835
- fetchPriceHistory(options): Promise<PriceHistoryResult>
1836
- // Options: { tokenName?, tokenId?, from?, to?, sortOrder?, page?, limit? }
1837
- // Token identification (provide EXACTLY ONE):
1838
- // - tokenName: Simple token name (e.g., "demonkpop") - auto-resolves to tokenId
1839
- // - tokenId: Full token class key (e.g., "Token|Unit|DKP|eth:...")
1840
- // Returns: { items, meta: { total }, pageInfo: { hasNextPage, nextCursor } }
1841
- // Fetches paginated historical price snapshots from DEX Backend API
1842
-
1843
- fetchAllPriceHistory(options): Promise<PriceHistoryResult>
1844
- // Options: { tokenName?, tokenId?, from?, to?, sortOrder? } (no pagination params)
1845
- // Token identification (provide EXACTLY ONE):
1846
- // - tokenName: Simple token name (e.g., "demonkpop") - auto-resolves to tokenId
1847
- // - tokenId: Full token class key (e.g., "Token|Unit|DKP|eth:...")
1848
- // Returns: All matching snapshots with total count
1849
- // Convenience method with automatic pagination (returns ALL snapshots)
1850
- ```
1851
-
1852
- ## Performance Optimization
1853
-
1854
- ### Reusing Pool Data to Avoid Redundant Network Calls
1855
-
1856
- Methods that internally use `calculateBuyAmount`/`calculateSellAmount` now support optional `calculateAmountMode` and `currentSupply` parameters for performance optimization. This allows you to:
1857
-
1858
- 1. **Fetch pool details once** using `fetchPoolDetailsForCalculation`
1859
- 2. **Reuse `currentSupply`** across multiple calculations
1860
- 3. **Eliminate redundant network calls** with local mode calculations
1861
- 4. **Get instant results** when real-time precision isn't required
1862
-
1863
- ### Supported Methods
1864
-
1865
- The following methods accept optional performance parameters:
1866
-
1867
- - `fetchLaunchpadTokenSpotPrice(options)` - Pass `calculateAmountMode` and/or `currentSupply`
1868
- - `calculateBuyAmountForGraduation(options)` - Pass `calculateAmountMode` and/or `currentSupply`
1869
- - `graduateToken(options)` - Pass `calculateAmountMode` and/or `currentSupply`
1870
-
1871
- ### Using CALCULATION_MODES Constant
1872
-
1873
- ```typescript
1874
- import { createLaunchpadSDK, CALCULATION_MODES } from '@gala-chain/launchpad-sdk';
1875
-
1876
- const sdk = createLaunchpadSDK({
1877
- wallet: 'your-private-key-or-mnemonic'
1878
- });
1879
-
1880
- // Use type-safe calculation mode constants
1881
- console.log(CALCULATION_MODES.LOCAL); // 'local'
1882
- console.log(CALCULATION_MODES.EXTERNAL); // 'external'
1883
- ```
1884
-
1885
- ### Basic Optimization Pattern
1886
-
1887
- ```typescript
1888
- import { createLaunchpadSDK, CALCULATION_MODES } from '@gala-chain/launchpad-sdk';
1889
-
1890
- const sdk = createLaunchpadSDK({
1891
- wallet: 'your-private-key-or-mnemonic'
1892
- });
1893
-
1894
- const tokenName = 'tinyevil';
1895
-
1896
- // ❌ WITHOUT OPTIMIZATION (3 network calls)
1897
- const spotPrice1 = await sdk.fetchLaunchpadTokenSpotPrice(tokenName);
1898
- // → Fetches pool details internally (call #1)
1899
-
1900
- const graduation1 = await sdk.calculateBuyAmountForGraduation(tokenName);
1901
- // → Fetches pool details internally (call #2)
1902
-
1903
- const graduationResult1 = await sdk.graduateToken({ tokenName });
1904
- // → Fetches pool details internally (call #3)
1905
-
1906
- // ✅ WITH OPTIMIZATION (1 network call + instant local calculations)
1907
- // Step 1: Fetch pool details once
1908
- const poolDetails = await sdk.fetchPoolDetailsForCalculation(tokenName);
1909
- const currentSupply = poolDetails.currentSupply; // Pre-computed with full precision
1910
-
1911
- // Step 2: Reuse currentSupply for instant local calculations
1912
- const spotPrice2 = await sdk.fetchLaunchpadTokenSpotPrice({
1913
- tokenName,
1914
- calculateAmountMode: CALCULATION_MODES.LOCAL,
1915
- currentSupply
1916
- });
1917
- // → Uses local bonding curve formulas (instant, no network call)
1918
-
1919
- const graduation2 = await sdk.calculateBuyAmountForGraduation({
1920
- tokenName,
1921
- calculateAmountMode: CALCULATION_MODES.LOCAL,
1922
- currentSupply
1923
- });
1924
- // → Uses local calculation (instant, no network call)
1925
-
1926
- // Step 3: Graduate with optimized calculation
1927
- const graduationResult2 = await sdk.graduateToken({
1928
- tokenName,
1929
- calculateAmountMode: CALCULATION_MODES.LOCAL,
1930
- currentSupply,
1931
- slippageToleranceFactor: 0.01
1932
- });
1933
- // → Skips redundant pool fetch, uses local calculation
1934
- ```
1935
-
1936
- ### Performance Comparison
1937
-
1938
- | Pattern | Network Calls | Speed | Use Case |
1939
- |---------|--------------|-------|----------|
1940
- | **Without Optimization** | 3 calls | ~600-900ms | One-off operations |
1941
- | **With Optimization** | 1 call | ~200ms | Batch operations, price discovery |
1942
- | **Reduction** | **66% fewer calls** | **~70% faster** | |
1943
-
1944
- ### Complete Optimization Example
1945
-
1946
- ```typescript
1947
- import { createLaunchpadSDK, CALCULATION_MODES } from '@gala-chain/launchpad-sdk';
1948
-
1949
- const sdk = createLaunchpadSDK({
1950
- wallet: 'your-private-key-or-mnemonic'
1951
- });
1952
-
1953
- async function optimizedPoolAnalysis(tokenName: string) {
1954
- console.time('Optimized Analysis');
1955
-
1956
- // 1. Fetch pool details once (only network call needed)
1957
- const poolDetails = await sdk.fetchPoolDetailsForCalculation(tokenName);
1958
- const {
1959
- currentSupply,
1960
- maxSupply,
1961
- reverseBondingCurveMinFeeFactor,
1962
- reverseBondingCurveMaxFeeFactor
1963
- } = poolDetails;
1964
-
1965
- // 2. Get spot price with local calculation (instant)
1966
- const spotPrice = await sdk.fetchLaunchpadTokenSpotPrice({
1967
- tokenName,
1968
- calculateAmountMode: CALCULATION_MODES.LOCAL,
1969
- currentSupply
1970
- });
1971
- console.log(`Spot price: $${spotPrice.usdPrice.toFixed(6)}`);
1972
-
1973
- // 3. Calculate graduation cost with local calculation (instant)
1974
- const graduationCost = await sdk.calculateBuyAmountForGraduation({
1975
- tokenName,
1976
- calculateAmountMode: CALCULATION_MODES.LOCAL,
1977
- currentSupply
1978
- });
1979
- console.log(`Graduation cost: ${graduationCost.amount} GALA`);
1980
-
1981
- // 4. Simulate multiple buy scenarios (all instant)
1982
- const buyAmounts = ['10', '100', '1000'];
1983
- for (const amount of buyAmounts) {
1984
- const buyCalc = await sdk.calculateBuyAmount({
1985
- tokenName,
1986
- amount,
1987
- type: 'native',
1988
- mode: CALCULATION_MODES.LOCAL, // Can also use 'mode' alias
1989
- currentSupply
1990
- });
1991
- console.log(`Buying ${amount} GALA gets you: ${buyCalc.amount} tokens`);
1992
- }
1993
-
1994
- // 5. Simulate multiple sell scenarios (all instant)
1995
- const sellAmounts = ['10', '100', '1000'];
1996
- for (const amount of sellAmounts) {
1997
- const sellCalc = await sdk.calculateSellAmountLocal({
1998
- tokenName,
1999
- amount,
2000
- type: 'native',
2001
- maxSupply,
2002
- reverseBondingCurveMinFeeFactor,
2003
- reverseBondingCurveMaxFeeFactor
2004
- });
2005
- console.log(`Selling ${amount} GALA worth gets you: ${sellCalc.amount} GALA`);
2006
- }
2007
-
2008
- console.timeEnd('Optimized Analysis');
2009
- // Output: Optimized Analysis: ~200-300ms (vs ~2-3 seconds without optimization)
2010
- }
2011
-
2012
- optimizedPoolAnalysis('tinyevil');
2013
- ```
2014
-
2015
- ### When to Use Optimization
2016
-
2017
- **✅ Use optimization when:**
2018
- - Performing multiple calculations on the same token
2019
- - Building price discovery tools or analytics dashboards
2020
- - Running simulations or backtests
2021
- - Creating trading bots with frequent calculations
2022
- - Displaying real-time price feeds (use local mode for smooth updates)
2023
-
2024
- **❌ Skip optimization when:**
2025
- - Performing a single calculation
2026
- - Requiring absolute precision from GalaChain network
2027
- - Token supply changes frequently between calls
2028
-
2029
- ### Local vs External Calculations
2030
-
2031
- ```typescript
2032
- // Local mode (client-side, instant, <0.01% difference from external)
2033
- const localCalc = await sdk.calculateBuyAmount({
2034
- tokenName: 'tinyevil',
2035
- amount: '100',
2036
- type: 'native',
2037
- mode: CALCULATION_MODES.LOCAL,
2038
- currentSupply: poolDetails.currentSupply
2039
- });
2040
-
2041
- // External mode (GalaChain network, real-time, slower)
2042
- const externalCalc = await sdk.calculateBuyAmount({
2043
- tokenName: 'tinyevil',
2044
- amount: '100',
2045
- type: 'native',
2046
- mode: CALCULATION_MODES.EXTERNAL // or omit to use SDK default
2047
- });
2048
-
2049
- // Accuracy comparison
2050
- const difference = Math.abs(
2051
- parseFloat(localCalc.amount) - parseFloat(externalCalc.amount)
2052
- );
2053
- const percentDiff = (difference / parseFloat(externalCalc.amount)) * 100;
2054
- console.log(`Difference: ${percentDiff.toFixed(4)}%`); // Typically < 0.01%
2055
- ```
2056
-
2057
- ### SDK Configuration for Default Calculation Mode
2058
-
2059
- ```typescript
2060
- import { createLaunchpadSDK, CALCULATION_MODES } from '@gala-chain/launchpad-sdk';
2061
-
2062
- // Configure SDK to use local calculations by default
2063
- const sdk = createLaunchpadSDK({
2064
- wallet: 'your-private-key-or-mnemonic',
2065
- config: {
2066
- calculateAmountMode: CALCULATION_MODES.LOCAL // Default to local mode
2067
- }
2068
- });
2069
-
2070
- // All calculations will use local mode by default
2071
- const calc1 = await sdk.calculateBuyAmount({
2072
- tokenName: 'tinyevil',
2073
- amount: '100',
2074
- type: 'native'
2075
- // Uses LOCAL mode from SDK config
2076
- });
2077
-
2078
- // Override per-call if needed
2079
- const calc2 = await sdk.calculateBuyAmount({
2080
- tokenName: 'tinyevil',
2081
- amount: '100',
2082
- type: 'native',
2083
- mode: CALCULATION_MODES.EXTERNAL // Override to external for this call
2084
- });
2085
- ```
2086
-
2087
- ## Token Metadata Cache
2088
-
2089
- The SDK includes an **intelligent metadata cache** that eliminates redundant API calls and enables instant local calculations. The cache stores immutable token metadata (reverse bonding curve fees, vault addresses, max supply) that never changes.
2090
-
2091
- ### How Cache Warming Works
2092
-
2093
- **Opportunistic & Zero-Cost**: Cache warming happens automatically during normal SDK operations without any additional network requests. When you call `fetchPools()`, the SDK extracts and caches metadata from the pool data that was already fetched.
2094
-
2095
- ```typescript
2096
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
2097
-
2098
- const sdk = createLaunchpadSDK({
2099
- wallet: 'your-private-key-or-mnemonic'
2100
- });
2101
-
2102
- // Before fetching - cache is empty
2103
- let cacheInfo = sdk.getCacheInfo();
2104
- console.log('Cached tokens:', cacheInfo.totalTokens); // 0
2105
-
2106
- // Fetch pools - automatically warms cache with RBC fees and vault addresses
2107
- await sdk.fetchPools({ type: 'recent', pageSize: 20 });
2108
-
2109
- // After fetching - cache is warmed with 20 tokens
2110
- cacheInfo = sdk.getCacheInfo();
2111
- console.log('Cached tokens:', cacheInfo.totalTokens); // 20
2112
- console.log('Cache size:', (cacheInfo.cacheSize / 1024).toFixed(2), 'KB');
2113
-
2114
- // Now local calculations are instant (no network calls required)
2115
- const calc = await sdk.calculateBuyAmountLocal({
2116
- tokenName: 'anime',
2117
- amount: '100',
2118
- type: 'native',
2119
- currentSupply: '500000'
2120
- });
2121
- console.log('Instant result:', calc.amount); // <1ms, used cached RBC fees
2122
- ```
2123
-
2124
- ### Performance Benefits
2125
-
2126
- **Dramatic Performance Improvements:**
2127
-
2128
- | Operation | Without Cache | With Cache | Improvement |
2129
- |-----------|---------------|------------|-------------|
2130
- | Single calculation | ~200ms | <1ms | **200x faster** |
2131
- | 10 calculations | ~2000ms | <5ms | **400x faster** |
2132
- | Price discovery (50 tokens) | ~10,000ms | ~50ms | **200x faster** |
2133
-
2134
- **Zero Network Overhead**: Cache warming extracts metadata from pool responses you're already receiving - no extra API calls required.
2135
-
2136
- **Memory Efficient**:
2137
- - ~220 bytes per cached token (includes RBC fees + vault address)
2138
- - Max 10,000 tokens = ~2.5 MB total memory
2139
- - LRU eviction keeps memory bounded
2140
-
2141
- ### Cache Lifecycle
2142
-
2143
- **Session Lifetime**:
2144
- - Cache persists for entire MCP server session (survives across conversations)
2145
- - For direct SDK usage, cache lifetime matches SDK instance lifetime
2146
- - Call `sdk.cleanup()` to clear cache and release resources
2147
-
2148
- **LRU Eviction**:
2149
- - Maximum 10,000 tokens cached
2150
- - Least Recently Updated (LRU) tokens evicted when limit reached
2151
- - O(1) get/set/eviction using JavaScript Map insertion order
2152
-
2153
- ```typescript
2154
- // Cache automatically manages size
2155
- await sdk.fetchPools({ pageSize: 100 }); // Fetches 100 tokens
2156
- await sdk.fetchPools({ pageSize: 100 }); // Fetches 100 more tokens
2157
- await sdk.fetchPools({ pageSize: 100 }); // ... continues
2158
-
2159
- // When 10,000 limit reached, oldest tokens are evicted automatically
2160
- const stats = sdk.getCacheInfo();
2161
- console.log('Total tokens:', stats.totalTokens); // Never exceeds 10,000
2162
- console.log('Oldest entry:', new Date(stats.oldestEntry).toISOString());
2163
- ```
2164
-
2165
- ### Cache Management API
2166
-
2167
- **Get Cache Statistics:**
2168
-
2169
- ```typescript
2170
- const stats = sdk.getCacheInfo();
2171
- console.log('Total tokens cached:', stats.totalTokens);
2172
- console.log('Memory usage:', stats.cacheSize, 'bytes');
2173
- console.log('Average per entry:', (stats.cacheSize / stats.totalTokens).toFixed(0), 'bytes');
2174
- console.log('Oldest entry:', new Date(stats.oldestEntry).toISOString());
2175
- ```
2176
-
2177
- **Clear Cache (Selective or Complete):**
2178
-
2179
- ```typescript
2180
- // Clear specific token
2181
- sdk.clearCache('anime');
2182
- console.log('Cleared anime from cache');
2183
-
2184
- // Clear all tokens
2185
- sdk.clearCache();
2186
- console.log('Cleared entire cache');
2187
-
2188
- // Verify cache is empty
2189
- const stats = sdk.getCacheInfo();
2190
- console.log('Tokens remaining:', stats.totalTokens); // 0
2191
- ```
2192
-
2193
- **Manual Cache Warming (Advanced):**
2194
-
2195
- ```typescript
2196
- // Manually warm cache from pool data (useful for custom caching scenarios)
2197
- sdk.warmCacheFromPoolData('mytoken', {
2198
- vaultAddress: 'service|Token$Unit$MYTOKEN$...',
2199
- reverseBondingCurveMinFeeFactor: 0.0,
2200
- reverseBondingCurveMaxFeeFactor: 0.5
2201
- });
2202
-
2203
- // Cache is now warmed for local calculations
2204
- const calc = await sdk.calculateBuyAmountLocal({
2205
- tokenName: 'mytoken',
2206
- amount: '100',
2207
- type: 'native',
2208
- currentSupply: '1000000'
2209
- });
2210
- ```
2211
-
2212
- ### Complete Cache Example
2213
-
2214
- ```typescript
2215
- import { createLaunchpadSDK, CALCULATION_MODES } from '@gala-chain/launchpad-sdk';
2216
-
2217
- const sdk = createLaunchpadSDK({
2218
- wallet: 'your-private-key-or-mnemonic'
2219
- });
2220
-
2221
- // 1. Warm cache by fetching pools
2222
- console.log('Warming cache...');
2223
- await sdk.fetchPools({ type: 'popular', pageSize: 50 });
2224
-
2225
- // 2. Check cache statistics
2226
- const stats = sdk.getCacheInfo();
2227
- console.log(`Cache warmed with ${stats.totalTokens} tokens`);
2228
- console.log(`Memory: ${(stats.cacheSize / 1024).toFixed(2)} KB`);
2229
-
2230
- // 3. Perform instant calculations using cached metadata
2231
- const tokens = ['anime', 'dragnrkti', 'rocketri'];
2232
-
2233
- console.log('\nCalculating spot prices (instant, no network calls):');
2234
- console.time('Batch Calculations');
2235
-
2236
- for (const token of tokens) {
2237
- // Get pool details once for this token
2238
- const poolDetails = await sdk.fetchPoolDetailsForCalculation(token);
2239
-
2240
- // Multiple instant calculations using cached data
2241
- const [buy10, buy100, buy1000] = await Promise.all([
2242
- sdk.calculateBuyAmountLocal({
2243
- tokenName: token,
2244
- amount: '10',
2245
- type: 'native',
2246
- currentSupply: poolDetails.currentSupply
2247
- }),
2248
- sdk.calculateBuyAmountLocal({
2249
- tokenName: token,
2250
- amount: '100',
2251
- type: 'native',
2252
- currentSupply: poolDetails.currentSupply
2253
- }),
2254
- sdk.calculateBuyAmountLocal({
2255
- tokenName: token,
2256
- amount: '1000',
2257
- type: 'native',
2258
- currentSupply: poolDetails.currentSupply
2259
- })
2260
- ]);
2261
-
2262
- console.log(`${token}:`);
2263
- console.log(` 10 GALA → ${buy10.amount} tokens`);
2264
- console.log(` 100 GALA → ${buy100.amount} tokens`);
2265
- console.log(` 1000 GALA → ${buy1000.amount} tokens`);
2266
- }
2267
-
2268
- console.timeEnd('Batch Calculations');
2269
- // Output: Batch Calculations: ~50-100ms (vs ~3-5 seconds without cache)
2270
-
2271
- // 4. Clear cache when done (optional)
2272
- sdk.clearCache();
2273
- console.log('\nCache cleared');
2274
- ```
2275
-
2276
- ## Price History with Token Names (v3.20.0+)
2277
-
2278
- The SDK now supports convenient token name resolution for price history queries. Instead of providing full token class keys, you can now use simple token names like `"demonkpop"` and the SDK automatically resolves them to the full token identifier.
2279
-
2280
- ### Basic Usage
2281
-
2282
- ```typescript
2283
- import { createLaunchpadSDK } from '@gala-chain/launchpad-sdk';
2284
-
2285
- const sdk = createLaunchpadSDK({
2286
- wallet: 'your-private-key-or-mnemonic'
2287
- });
2288
-
2289
- // ✅ NEW: Use simple token name (auto-resolves to full token ID)
2290
- const recentHistory = await sdk.fetchPriceHistory({
2291
- tokenName: 'demonkpop', // Simple, intuitive token name
2292
- pageSize: 20
2293
- });
2294
-
2295
- console.log(`Latest price: $${recentHistory.snapshots[0].price}`);
2296
- console.log(`Total snapshots: ${recentHistory.total}`);
2297
-
2298
- // ✅ STILL WORKS: Direct token ID (for advanced use cases)
2299
- const historyWithId = await sdk.fetchPriceHistory({
2300
- tokenId: 'Token|Unit|DKP|eth:4A65D29213de2939373ff9eB63AC38730F192C84',
2301
- pageSize: 20
2302
- });
2303
- ```
2304
-
2305
- ### Advanced Examples
2306
-
2307
- ```typescript
2308
- // 1. VOLATILITY ANALYSIS - Using token name for convenience
2309
- const monthlyHistory = await sdk.fetchPriceHistory({
2310
- tokenName: 'demonkpop',
2311
- from: new Date('2025-01-01'),
2312
- to: new Date('2025-02-01'),
2313
- sortOrder: 'ASC', // Chronological order for analysis
2314
- pageSize: 50
2315
- });
2316
-
2317
- const prices = monthlyHistory.snapshots.map(s => parseFloat(s.price));
2318
- const avgPrice = prices.reduce((a, b) => a + b, 0) / prices.length;
2319
- console.log(`Average price: $${avgPrice.toFixed(6)}`);
2320
-
2321
- // 2. AUTO-PAGINATION - Fetch complete dataset with token name
2322
- const completeHistory = await sdk.fetchAllPriceHistory({
2323
- tokenName: 'demonkpop',
2324
- from: new Date('2024-01-01'),
2325
- to: new Date('2024-12-31'),
2326
- sortOrder: 'DESC' // Newest first
2327
- });
2328
-
2329
- console.log(`Total snapshots: ${completeHistory.snapshots.length}`);
2330
- console.log(`Date range: ${completeHistory.snapshots[0].timestamp} to ${completeHistory.snapshots[completeHistory.snapshots.length - 1].timestamp}`);
2331
-
2332
- // 3. PRICE TRENDS - Detect moving averages with pagination
2333
- const recentData = await sdk.fetchPriceHistory({
2334
- tokenName: 'demonkpop',
2335
- from: new Date(Date.now() - 7 * 24 * 60 * 60 * 1000), // Last 7 days
2336
- sortOrder: 'DESC',
2337
- pageSize: 20
2338
- });
2339
-
2340
- const ma7 = recentData.snapshots
2341
- .map(s => parseFloat(s.price))
2342
- .slice(0, 7)
2343
- .reduce((a, b) => a + b, 0) / 7;
2344
-
2345
- console.log(`7-day moving average: $${ma7.toFixed(6)}`);
2346
- ```
2347
-
2348
- ### Token Name Resolution Details
2349
-
2350
- **Supported Token Name Formats:**
2351
- - Any token created on the launchpad (e.g., `demonkpop`, `anime`, `shoewars`)
2352
- - Case-sensitive, 3-20 characters
2353
- - Alphanumeric characters only
2354
- - The SDK automatically resolves to full token class key: `Token|Unit|SYMBOL|eth:...`
2355
-
2356
- **Error Handling:**
2357
- ```typescript
2358
- try {
2359
- const history = await sdk.fetchPriceHistory({
2360
- tokenName: 'unknowntoken'
2361
- });
2362
- } catch (error) {
2363
- if (error.message.includes('Token not found')) {
2364
- console.log('Token does not exist on the launchpad');
2365
- } else if (error.message.includes('must be a string between 3 and 20 characters')) {
2366
- console.log('Invalid token name format');
2367
- } else {
2368
- console.log('Network or other error');
2369
- }
2370
- }
2371
- ```
2372
-
2373
- ### Comparison: Before and After
2374
-
2375
- ```typescript
2376
- // ❌ BEFORE (v3.19 and earlier) - Had to provide full token class key
2377
- const history = await sdk.fetchPriceHistory({
2378
- tokenId: 'Token|Unit|DKP|eth:4A65D29213de2939373ff9eB63AC38730F192C84',
2379
- pageSize: 10
2380
- });
2381
-
2382
- // ✅ AFTER (v3.20+) - Simple token name, auto-resolves internally
2383
- const history = await sdk.fetchPriceHistory({
2384
- tokenName: 'demonkpop',
2385
- pageSize: 10
2386
- });
2387
- ```
2388
-
2389
- ### Performance Notes
2390
-
2391
- - **First Call**: Token name resolution involves a vault lookup (~100-200ms)
2392
- - **Subsequent Calls**: Vault addresses are cached, making repeated calls instant
2393
- - **Network**: Requires DEX Backend API access (Node.js only)
2394
- - **Backwards Compatible**: Existing code using `tokenId` continues to work unchanged
2395
-
2396
- ### Cache Design Philosophy
2397
-
2398
- **Immutable Data Only**: Only caches data that never changes:
2399
- - ✅ Reverse bonding curve fee factors (set at token creation)
2400
- - ✅ Vault addresses (permanent token identifiers)
2401
- - ✅ Max supply (bonding curve constant, typically 10M)
2402
- - ❌ Current supply (changes with every trade - fetched dynamically)
2403
- - ❌ Token balances (user-specific and dynamic)
2404
-
2405
- **Zero-Cost Architecture**: No extra API calls required for cache warming. Metadata is extracted from responses you're already receiving during normal operations.
2406
-
2407
- **Bounded Memory**: LRU eviction ensures cache never exceeds 10,000 tokens (~2.5 MB), making it safe for long-running applications.
2408
-
2409
- **Smart Defaults**: Uses 10,000,000 as default max supply for tokens without explicit data (matches 99%+ of launchpad tokens).
2410
-
2411
- ### When to Use the Cache
2412
-
2413
- **✅ Perfect for:**
2414
- - Price discovery and analytics dashboards
2415
- - Trading bots with frequent calculations
2416
- - Batch operations on multiple tokens
2417
- - Real-time price feeds and charts
2418
- - Simulation and backtesting tools
2419
-
2420
- **❌ Not needed for:**
2421
- - Single one-off calculations
2422
- - Operations requiring absolute real-time precision
2423
- - Scenarios where current supply changes between calls
2424
-
2425
- ### Cache Warming Demo
2426
-
2427
- Run the complete cache demo to see all features in action:
2428
-
2429
- ```bash
2430
- npm run demo-cache
2431
- ```
2432
-
2433
- The demo showcases:
2434
- - Opportunistic warming from `fetchPools()`
2435
- - Detailed warming from `fetchPoolDetailsForCalculation()`
2436
- - Token name normalization (case-insensitive)
2437
- - Cache hit performance (200x+ faster than network calls)
2438
- - Memory estimation accuracy
2439
- - LRU eviction behavior
2440
- - Clear cache operations
2441
-
2442
- ### **Trading Operations**
2443
-
2444
- ```typescript
2445
- // Buy/Sell Tokens
2446
- buy(options): Promise<TransactionResult>
2447
- // Options: { tokenName, amount, type, expectedAmount, slippageToleranceFactor }
2448
- // Returns: { transactionId, status, ... }
2449
-
2450
- sell(options): Promise<TransactionResult>
2451
- // Options: { tokenName, amount, type, expectedAmount, slippageToleranceFactor }
2452
- // Returns: { transactionId, status, ... }
2453
-
2454
- graduateToken(options): Promise<TransactionResult>
2455
- // Options: { tokenName, slippageToleranceFactor?, maxAcceptableReverseBondingCurveFeeSlippageFactor?, privateKey? }
2456
- // Returns: { transactionId, status, ... }
2457
- // One-step pool graduation: calculates cost and buys all remaining tokens
2458
- ```
2459
-
2460
- ### **GSwap DEX Trading Methods**
2461
-
2462
- ```typescript
2463
- // GSwap Quote Operations (read-only, fast)
2464
- getSwapQuoteExactInput(fromToken, toToken, amount): Promise<SwapQuoteResult>
2465
- // Returns: { fromToken, toToken, inputAmount, estimatedOutput, feeTier, priceImpact, executionPrice }
2466
- // Get quote for known input amount (spend known GALA, get estimated token output)
2467
-
2468
- getSwapQuoteExactOutput(fromToken, toToken, amount): Promise<SwapQuoteResult>
2469
- // Returns: { fromToken, toToken, inputAmount, estimatedOutput, feeTier, priceImpact, executionPrice }
2470
- // Get quote for known output amount (get known token output, estimate GALA cost)
2471
-
2472
- // GSwap Swap Execution (requires wallet signer)
2473
- executeSwap(fromToken, toToken, amount, estimatedOutput, feeTier, slippageTolerance): Promise<ExecuteSwapResult>
2474
- // Options: { fromToken, toToken, inputAmount, estimatedOutput, feeTier, slippageTolerance }
2475
- // Returns: { transactionId, status, fromToken, toToken, inputAmount, outputAmount, timestamp }
2476
- // Execute token swap with automatic slippage protection and unified WebSocket monitoring
2477
-
2478
- // GSwap User Operations
2479
- getSwapUserAssets(walletAddress): Promise<UserAsset[]>
2480
- // Returns: [{ tokenId, symbol, name, description, image, balance, decimals, verified, compositeKey }, ...]
2481
- // Get user token balances with rich metadata (v4.1.0+)
2482
-
2483
- getAllSwapUserAssets(walletAddress): Promise<UserAsset[]>
2484
- // Returns: All user tokens with rich metadata (auto-paginated)
2485
- // Optimized: Stops fetching when zero-balance tokens encountered
2486
-
2487
- // Token Discovery (no wallet required)
2488
- fetchAvailableDexTokens({ search?, limit?, page? }): Promise<AvailableDexTokensResult>
2489
- // Returns: { tokens: DexToken[], count, page, limit, hasMore }
2490
- // Paginated token discovery with rich metadata
2491
-
2492
- fetchAllAvailableDexTokens({ search? }): Promise<DexToken[]>
2493
- // Returns: All available DEX tokens (auto-paginated)
2494
- // Use for comprehensive token catalogs and listings
2495
-
2496
- getSwapPoolInfo(tokenA, tokenB): Promise<PoolInfo>
2497
- // Returns: { tokenA, tokenB, liquidity, feeTiers, swapCount }
2498
- // Get liquidity and fee tier information for token pair
2499
- ```
2500
-
2501
- **Key Features:**
2502
- - ✅ **Strict token format enforcement** (v3.33.0+): All tokens require delimited format (`'GALA|Unit|none|none'` or `'GALA$Unit$none$none'`)
2503
- - ✅ **Quote pattern**: Always get quote before executing swap for accurate slippage calculations
2504
- - ✅ **Unified WebSocket**: Real-time transaction monitoring via shared LaunchpadSDK WebSocket connection
2505
- - ✅ **Environment alignment**: Automatic STAGE/PROD configuration matching
2506
- - ✅ **Fee tiers**: Standard DEX fees (500 bps = 0.05%, 3000 bps = 0.30%, 10000 bps = 1.00%)
2507
- - ✅ **Error handling**: Dedicated error types (GSwapQuoteError, GSwapSwapError, GSwapAssetError, GSwapPoolError)
2508
-
2509
- ### **GSwap DEX Trading** (Graduated Tokens)
2510
-
2511
- For tokens that have graduated from the bonding curve phase, use GSwap SDK integration for full DEX trading:
2512
-
2513
- ```typescript
2514
- // Access GSwap trading functionality
2515
- const gswapService = sdk.gswap;
2516
-
2517
- // Get swap quotes for graduated tokens
2518
- const quoteParams = {
2519
- fromToken: 'GALA',
2520
- toToken: 'GUSDC',
2521
- amount: '100'
2522
- };
2523
-
2524
- // Quote for exact input (spend known amount)
2525
- const quoteExactInput = await gswapService.getSwapQuoteExactInput(quoteParams);
2526
- console.log(`Spend 100 GALA, get ~${quoteExactInput.estimatedOutput} GUSDC`);
2527
- console.log(`Price impact: ${quoteExactInput.priceImpact}%`);
2528
- console.log(`Execution price: ${quoteExactInput.executionPrice}`);
2529
-
2530
- // Quote for exact output (receive known amount)
2531
- const quoteExactOutput = await gswapService.getSwapQuoteExactOutput({
2532
- fromToken: 'GALA',
2533
- toToken: 'GUSDC',
2534
- amount: '100' // Desired output amount
2535
- });
2536
- console.log(`To get 100 GUSDC, spend ~${quoteExactOutput.inputAmount} GALA`);
2537
-
2538
- // Execute swap with slippage protection
2539
- const swapResult = await gswapService.executeSwap({
2540
- fromToken: 'GALA',
2541
- toToken: 'GUSDC',
2542
- inputAmount: '100',
2543
- estimatedOutput: quoteExactInput.estimatedOutput,
2544
- feeTier: quoteExactInput.feeTier,
2545
- slippageTolerance: 0.01 // 1% slippage tolerance
2546
- });
2547
-
2548
- console.log(`Swap completed! TX: ${swapResult.transactionId}`);
2549
- console.log(`Received: ${swapResult.outputAmount} GUSDC`);
2550
-
2551
- // Query user assets on DEX (returns rich metadata)
2552
- const assets = await gswapService.getUserAssets('eth|0x...');
2553
- assets.forEach(asset => {
2554
- console.log(`${asset.symbol} (${asset.name}): ${asset.balance}`);
2555
- console.log(` Image: ${asset.image}`);
2556
- console.log(` Verified: ${asset.verified}`);
2557
- });
2558
-
2559
- // Discover all available DEX tokens (no wallet required)
2560
- const availableTokens = await sdk.fetchAvailableDexTokens({ limit: 20, page: 1 });
2561
- console.log(`Found ${availableTokens.count} tokens on DEX`);
2562
- availableTokens.tokens.forEach(token => {
2563
- console.log(`${token.symbol}: ${token.name} - ${token.description}`);
2564
- });
2565
-
2566
- // Get ALL available tokens (auto-paginated)
2567
- const allTokens = await sdk.fetchAllAvailableDexTokens();
2568
- console.log(`Total: ${allTokens.length} tokens available on DEX`);
2569
-
2570
- // Get pool information for token pair
2571
- const poolInfo = await gswapService.getPoolInfo('GALA', 'GUSDC');
2572
- console.log(`Liquidity: ${poolInfo.liquidity}`);
2573
- console.log(`Available fee tiers: ${poolInfo.feeTiers}`);
2574
- ```
2575
-
2576
- **GSwap Error Handling:**
2577
-
2578
- The GSwap service provides specific error types for different failure scenarios:
2579
-
2580
- ```typescript
2581
- import {
2582
- GSwapQuoteError,
2583
- GSwapSwapError,
2584
- GSwapPoolError,
2585
- GSwapAssetError
2586
- } from '@gala-chain/launchpad-sdk';
2587
-
2588
- try {
2589
- const quote = await gswapService.getSwapQuoteExactInput({
2590
- fromToken: 'INVALID',
2591
- toToken: 'GUSDC',
2592
- amount: '100'
2593
- });
2594
- } catch (error) {
2595
- if (error instanceof GSwapQuoteError) {
2596
- console.error(`Quote failed: ${error.message}`);
2597
- console.error(`Error code: ${error.code}`);
2598
- console.error(`Original error:`, error.originalError);
2599
- }
2600
- }
2601
-
2602
- try {
2603
- await gswapService.executeSwap({...});
2604
- } catch (error) {
2605
- if (error instanceof GSwapSwapError) {
2606
- console.error(`Swap failed: ${error.message}`);
2607
- console.error(`Transaction hash: ${error.transactionHash}`);
2608
- console.error(`Error code: ${error.code}`);
2609
- }
2610
- }
2611
-
2612
- try {
2613
- await gswapService.getUserAssets(walletAddress);
2614
- } catch (error) {
2615
- if (error instanceof GSwapAssetError) {
2616
- console.error(`Asset query failed for ${error.walletAddress}: ${error.message}`);
2617
- }
2618
- }
2619
- ```
2620
-
2621
- **GSwap vs Bonding Curve Trading:**
2622
-
2623
- | Feature | Bonding Curve (buy/sell) | GSwap DEX (swaps) |
2624
- |---------|-------------------------|-------------------|
2625
- | **Token Status** | Pre-graduation | Post-graduation |
2626
- | **Liquidity** | Algorithmic curve | Concentrated liquidity pools |
2627
- | **Fee Tiers** | Single: reverseBondingCurveFee | Multiple: 500 (0.05%), 3000 (0.30%), 10000 (1.00%) |
2628
- | **Price Impact** | Linear/exponential | Depends on pool depth |
2629
- | **Method** | Direct buy/sell | Quote + execute pattern |
2630
- | **Quote Types** | Exact input/output | Exact input/output |
2631
-
2632
- **Performance Considerations:**
2633
-
2634
- - Quotes are fast (typically <100ms)
2635
- - Socket connection is auto-established on first swap
2636
- - Socket failures don't block swaps (graceful degradation)
2637
- - Use BigNumber for precision in calculations
2638
- - Slippage tolerance typically 0.5% - 2%
2639
-
2640
- ### **Content Operations**
2641
-
2642
- ```typescript
2643
- // Comments & Content
2644
- postComment(options): Promise<CommentResult>
2645
- // Returns: { id, content, createdAt, ... }
2646
-
2647
- // Token Creation & Management
2648
- launchToken(data): Promise<LaunchTokenResult>
2649
- // Returns: { transactionId, status, ... }
2650
-
2651
- uploadTokenImage(options): Promise<ImageUploadResult>
2652
- // Returns: { imageUrl, success, ... }
2653
-
2654
- // Profile Management
2655
- updateProfile(data): Promise<ProfileUpdateResult>
2656
- // Returns: { success, data, ... }
2657
-
2658
- uploadProfileImage(options): Promise<ImageUploadResult>
2659
- // Returns: { imageUrl, success, ... }
2660
- ```
2661
-
2662
- ### **Token Data & Validation (v6.0.0+)**
2663
-
2664
- ```typescript
2665
- // Fetch complete token data with streaming information consolidated
2666
- fetchToken(tokenName: string): Promise<PoolData>
2667
- // Returns: Complete pool data including streaming fields (playbackId, muxStreamStatus, currentViewerCount, etc.)
2668
- // Example: const pool = await sdk.fetchToken('mytoken');
2669
-
2670
- // Validate token name/symbol for creation or form validation
2671
- validateToken(options: { tokenName?: string, symbol?: string }): Promise<ValidateTokenResponse>
2672
- // Returns: { nameAvailable, symbolAvailable, nameBlocklisted, symbolBlocklisted, errors }
2673
- // Example: const result = await sdk.validateToken({ tokenName: 'mytoken', symbol: 'MYT' });
2674
- ```
2675
-
2676
- **Migration Note (v6.0.0)**: `getStreamInfo()` was removed. Use `fetchToken()` instead - streaming fields now consolidated in PoolData response.
2677
-
2678
- ### **Validation & Utilities**
2679
- - `isTokenNameAvailable(tokenName: string): Promise<boolean>`
2680
- - `isTokenSymbolAvailable(symbol: string): Promise<boolean>`
2681
- - `isTokenGraduated(tokenName: string): Promise<boolean>` - Check if token completed bonding curve phase
2682
- - `getAddress(): string` - Get backend format address (eth|...)
2683
- - `getEthereumAddress(): string` - Get Ethereum format address (0x...)
2684
- - `getUrlByTokenName(tokenName: string): string` - Get frontend URL for token
2685
- - `resolveVaultAddress(tokenName: string): Promise<string>`
2686
- - `cleanup(): void` - Cleanup resources
2687
-
2688
- ### **Cross-Chain Bridge Operations**
2689
-
2690
- ```typescript
2691
- // Bridge Configuration (requires ethereumPrivateKey and/or solanaPrivateKey)
2692
-
2693
- // Wallet Balance Queries - Single Token (Fast - 1 RPC call)
2694
- fetchEthereumWalletTokenBalance(symbol, address?): Promise<ExternalChainBalance>
2695
- // Fetch single ERC-20 balance (GALA, GWETH, GUSDC, GUSDT, GWTRX, GWBTC)
2696
-
2697
- fetchEthereumWalletNativeBalance(address?): Promise<ExternalChainBalance>
2698
- // Fetch native ETH balance only
2699
-
2700
- fetchSolanaWalletTokenBalance(symbol, address?): Promise<ExternalChainBalance>
2701
- // Fetch single SPL token balance (GALA, GSOL)
2702
-
2703
- fetchSolanaWalletNativeBalance(address?): Promise<ExternalChainBalance>
2704
- // Fetch native SOL balance only
2705
-
2706
- // Wallet Balance Queries - All Tokens (Complete Portfolio)
2707
- fetchEthereumWalletAllBalances(address?): Promise<EthereumWalletBalanceResult>
2708
- // Returns: { address, native, tokens[], timestamp } - ETH + 6 ERC-20s
2709
-
2710
- fetchSolanaWalletAllBalances(address?): Promise<SolanaWalletBalanceResult>
2711
- // Returns: { address, native, tokens[], timestamp } - SOL + 2 SPL tokens
2712
-
2713
- // Bridge Operations
2714
- estimateBridgeFee(options): Promise<BridgeFeeEstimate>
2715
- // Estimate fees for bridging tokens
2716
-
2717
- bridgeOut(options): Promise<BridgeResult>
2718
- // Bridge tokens FROM GalaChain TO Ethereum/Solana
2719
-
2720
- bridgeIn(options): Promise<BridgeResult>
2721
- // Bridge tokens FROM Ethereum/Solana TO GalaChain
2722
-
2723
- getBridgeStatus(transactionHash, chainHint?): Promise<BridgeStatus>
2724
- // Check status of bridge transaction
2725
-
2726
- getSupportedBridgeTokens(chain?): BridgeTokenInfo[]
2727
- // List supported bridge tokens
2728
- ```
2729
-
2730
- ## Configuration
2731
-
2732
- ### Constants
2733
-
2734
- ```typescript
2735
- import { MAX_CONCURRENT_POOL_FETCHES } from '@gala-chain/launchpad-sdk';
2736
-
2737
- console.log(`SDK fetches up to ${MAX_CONCURRENT_POOL_FETCHES} pages concurrently`);
2738
- // Output: "SDK fetches up to 5 pages concurrently"
2739
- ```
2740
-
2741
- **MAX_CONCURRENT_POOL_FETCHES**
2742
- - **Type**: `number`
2743
- - **Value**: `5`
2744
- - **Purpose**: Controls concurrency for parallel page fetching in auto-pagination
2745
- - **Balances**: Speed vs API rate limits
2746
- - **Usage**: Exported constant for reference (not configurable at runtime)
2747
-
2748
- ### SDK Configuration
2749
-
2750
- ```typescript
2751
- interface LaunchpadSDKConfig {
2752
- wallet: Wallet; // ethers.js Wallet instance
2753
- baseUrl?: string; // Backend URL (default: dev environment)
2754
- galaChainBaseUrl?: string; // GalaChain gateway URL
2755
- bundleBaseUrl?: string; // Bundle service URL
2756
- webSocketUrl?: string; // WebSocket URL for monitoring
2757
- timeout?: number; // Request timeout (default: 30000ms)
2758
- debug?: boolean; // Enable debug logging
2759
- maxRetries?: number; // Retry attempts (default: 3)
2760
- retryDelay?: number; // Retry delay (default: 1000ms)
2761
- }
2762
- ```
2763
-
2764
- ## Helper Functions
2765
-
2766
- ### **Wallet Creation**
2767
- ```typescript
2768
- import { createWallet, validateWalletInput } from '@gala-chain/launchpad-sdk';
2769
-
2770
- // Auto-detect format and create wallet
2771
- const wallet = createWallet('private-key-or-24-word-mnemonic');
2772
- const randomWallet = createWallet(); // Generate random wallet
2773
-
2774
- // Validate input format without creating wallet
2775
- const isValid = validateWalletInput('0x1234...'); // boolean
2776
- ```
2777
-
2778
- ### **Key Derivation**
2779
-
2780
- Derive public keys and addresses from private keys without creating a wallet:
2781
-
2782
- ```typescript
2783
- import {
2784
- getPublicKeyFromPrivateKey,
2785
- getEthereumAddressFromPrivateKey
2786
- } from '@gala-chain/launchpad-sdk';
2787
-
2788
- // Get public key (both compressed and uncompressed formats)
2789
- const { publicKey, compressedPublicKey } = getPublicKeyFromPrivateKey('0x...');
2790
- // publicKey: "0x04..." (132 chars, uncompressed)
2791
- // compressedPublicKey: "0x02..." or "0x03..." (68 chars)
2792
-
2793
- // Get Ethereum address from private key
2794
- const address = getEthereumAddressFromPrivateKey('0x...');
2795
- // "0x8Ba1f109551bD432803012645Ac136ddd64DBA72" (checksum format)
2796
-
2797
- // Convert to GalaChain format manually
2798
- const galaChainAddress = `eth|${address.slice(2).toLowerCase()}`;
2799
- // "eth|8ba1f109551bd432803012645ac136ddd64dba72"
2800
- ```
2801
-
2802
- ### **GalaChain Address Override**
2803
-
2804
- For non-standard GalaChain addresses (like `client|ops-admin`), use the `galaChainAddress` config option:
2805
-
2806
- ```typescript
2807
- import { LaunchpadSDK } from '@gala-chain/launchpad-sdk';
2808
-
2809
- // Standard: address derived from wallet
2810
- const sdk = new LaunchpadSDK({ wallet });
2811
- sdk.getAddress(); // "eth|a1b2c3d4..."
2812
-
2813
- // Override: use custom GalaChain address
2814
- const adminSdk = new LaunchpadSDK({
2815
- wallet,
2816
- galaChainAddress: 'client|ops-admin'
2817
- });
2818
- adminSdk.getAddress(); // "client|ops-admin"
2819
- ```
2820
-
2821
- Or via environment variable for MCP/Agent setups:
2822
- ```bash
2823
- export WALLET_PRIVATE_KEY=0x...
2824
- export WALLET_ADDRESS=client|ops-admin # Override
2825
- ```
2826
-
2827
- ### **SDK Factory Functions**
2828
- ```typescript
2829
- import { createLaunchpadSDK, createTestLaunchpadSDK } from '@gala-chain/launchpad-sdk';
2830
-
2831
- // Main factory with auto-detection
2832
- const sdk = createLaunchpadSDK({
2833
- wallet: 'your-private-key-or-mnemonic',
2834
- config: {
2835
- baseUrl: 'https://lpad-backend-dev1.defi.gala.com',
2836
- debug: true
2837
- }
2838
- });
2839
-
2840
- // Test-optimized SDK
2841
- const testSDK = createTestLaunchpadSDK({
2842
- wallet: 'test-private-key'
2843
- });
2844
- ```
2845
-
2846
- ### **Position Filter Utilities**
2847
-
2848
- Helpers for organizing and filtering liquidity positions by various criteria:
2849
-
2850
- ```typescript
2851
- import {
2852
- filterByLiquidity, // Remove positions with zero liquidity
2853
- filterByMinLiquidity, // Keep positions >= threshold
2854
- filterByTokenPair, // Match specific token pair
2855
- filterByToken, // Find positions containing a token
2856
- filterByFeeTier, // Filter by fee tier (500, 3000, 10000)
2857
- filterByPoolKey, // Match specific pool (token pair + fee)
2858
- sortByLiquidity, // Sort positions by liquidity amount
2859
- groupByTokenPair, // Group by "TOKEN0/TOKEN1"
2860
- groupByFeeTier, // Group by fee tier
2861
- groupByPoolKey, // Group by "TOKEN0|TOKEN1|FEETIER"
2862
- } from '@gala-chain/launchpad-sdk';
2863
-
2864
- // Example: Find active GALA/GUSDC positions and sort by size
2865
- const allPositions = await sdk.getAllSwapUserLiquidityPositions(address);
2866
- const active = filterByLiquidity(allPositions); // Remove zero-liquidity
2867
- const galaPositions = filterByTokenPair(active, 'GALA', 'GUSDC'); // GALA/GUSDC only
2868
- const sorted = sortByLiquidity(galaPositions, 'desc'); // Largest first
2869
-
2870
- // Group positions by token pair for portfolio analysis
2871
- const grouped = groupByTokenPair(active);
2872
- grouped.forEach((positions, pair) => {
2873
- console.log(`${pair}: ${positions.length} positions`);
2874
- });
2875
-
2876
- // Find positions with significant liquidity
2877
- const large = filterByMinLiquidity(active, '1000');
2878
-
2879
- // Organize by pool (pair + fee tier) for advanced analysis
2880
- const byPool = groupByPoolKey(active);
2881
- byPool.forEach((positions, poolKey) => {
2882
- console.log(`Pool ${poolKey}: ${positions.length} LPs`);
2883
- });
2884
- ```
2885
-
2886
- **Use Cases:**
2887
- - Organize positions by token pair or pool
2888
- - Filter for active positions (non-zero liquidity)
2889
- - Find positions above minimum liquidity threshold
2890
- - Analyze portfolio distribution by token or fee tier
2891
- - Identify opportunities for fee collection
2892
- - Locate positions in specific pools
2893
-
2894
- ## Testing
2895
-
2896
- ```bash
2897
- # Run all tests
2898
- npm test
2899
-
2900
- # Run integration tests (requires environment setup)
2901
- npm run test:integration
2902
-
2903
- # Run type checking
2904
- npm run typecheck
2905
-
2906
- # Run linting
2907
- npm run lint
2908
- ```
2909
-
2910
- ## Documentation
2911
-
2912
- - [API Reference](./docs/API-REFERENCE.md) - Complete reference for all SDK methods with examples
2913
- - [Examples](./examples/) - Code examples and demos
2914
- - [AI Agent Guide](./docs/AI-AGENT-GUIDE.md) - Building AI agents with the Launchpad SDK
2915
-
2916
- ### GSwap Liquidity Operations
2917
-
2918
- - [Liquidity Operations Guide](./docs/LIQUIDITY_OPERATIONS.md) - Complete guide for managing liquidity positions (viewing, adding, collecting fees, removing)
2919
- - [Liquidity Response Structures](./docs/LIQUIDITY_RESPONSES.md) - Detailed reference for all liquidity operation response formats and error handling
2920
- - [GSwap SDK Integration](./docs/GSWAP_INTEGRATION.md) - Deep dive into GSwap patterns, token formats, and advanced trading workflows
2921
-
2922
- ### NFT Collection Management
2923
-
2924
- - [NFT Quick Reference](./docs/NFT_QUICK_REFERENCE.md) - Quick lookup for NFT collection, token class, and minting operations with fee schedules
2925
- - [NFT Operations Guide](./docs/NFT_OPERATIONS.md) - Complete guide for claiming collections, creating token classes, minting NFTs, and querying NFT data
2926
-
2927
- ### WebSocket & Real-Time Events
2928
-
2929
- - [WebSocket Documentation Hub](./docs/websocket/) - Complete guide to WebSocket connections and real-time events
2930
- - [Global Feed Quick Start](./docs/websocket/QUICKSTART.md) - Get real-time updates in 5 minutes
2931
- - [Global Feed Guide](./docs/websocket/GLOBAL-FEED.md) - Comprehensive guide to unified event streaming
2932
- - [WebSocket Authentication](./docs/websocket/AUTHENTICATION.md) - JWT authentication and security best practices
2933
-
2934
- ### Demo Scripts
2935
-
2936
- The SDK includes 36 comprehensive demo scripts organized into logical categories for easy discovery and learning.
2937
-
2938
- #### Organized Directory Structure
2939
-
2940
- ```
2941
- examples/
2942
- ├── core/ # SDK fundamentals and authentication patterns
2943
- ├── liquidity/ # GalaSwap liquidity position management (9 demos)
2944
- ├── bonding-curve/ # Token bonding curve trading operations
2945
- ├── dex/ # DEX trading and pool discovery (6 demos)
2946
- ├── fees/ # Fee generation and collection workflows (5 demos)
2947
- ├── monitoring/ # Real-time event watching (2 demos)
2948
- ├── utilities/ # Balance checks, cache, token supply (5 demos)
2949
- └── debug/ # Development and troubleshooting tools
2950
- ```
2951
-
2952
- #### Quick Start Examples
2953
-
2954
- **Core SDK Operations:**
2955
- ```bash
2956
- # Complete SDK feature demonstration
2957
- npm run demo
2958
-
2959
- # Read-only operations (no wallet required)
2960
- npm run demo:read-only
2961
-
2962
- # Authenticated operations (wallet required)
2963
- npm run demo:authenticated
2964
-
2965
- # Multi-wallet private key override pattern
2966
- npm run demo:privatekey-override
2967
- ```
2968
-
2969
- #### Liquidity Position Management (9 Demos)
2970
-
2971
- Comprehensive liquidity provision workflows for GalaSwap DEX:
2972
-
2973
- ```bash
2974
- # Interactive CLI for position management
2975
- npm run demo:liquidity
2976
-
2977
- # Run all 9 liquidity demos sequentially
2978
- npm run demo:liquidity:all
2979
-
2980
- # Individual demos
2981
- npm run demo:liquidity:detailed # Detailed position lifecycle
2982
- npm run demo:liquidity:ticks # Advanced tick-based positions
2983
- npm run demo:liquidity:portfolio # Multi-position portfolio management
2984
- npm run demo:liquidity:apr # APR calculation for LP positions
2985
- npm run demo:liquidity:errors # Error handling patterns
2986
- npm run demo:liquidity:fetch-all # Fetch all positions with pagination
2987
- npm run demo:liquidity:positions-with-prices # Position pricing enrichment
2988
-
2989
- # Complete roundtrip workflow (legacy, use orchestrator instead)
2990
- npm run demo:dex:roundtrip
2991
- ```
2992
-
2993
- **Orchestrator Pattern:**
2994
- The liquidity orchestrator (`npm run demo:liquidity:all`) runs all demos with intelligent error handling:
2995
- - Skip individual demos: `--skip=detailed,ticks`
2996
- - Run specific demos only: `--only=portfolio,apr`
2997
- - See all available demos: `npm run demo:liquidity:all --help`
2998
-
2999
- #### Bonding Curve Trading (Launchpad Tokens)
3000
-
3001
- Pre-graduation token trading on bonding curve pools:
3002
-
3003
- ```bash
3004
- # Basic buy/sell operations with slippage protection
3005
- npm run demo:trades
3006
- ```
3007
-
3008
- **Bonding Curve Focus:**
3009
- 8 additional bonding curve demos are available through the orchestrator (in development):
3010
- - Pool discovery and filtering
3011
- - Price calculation methods
3012
- - Graduation simulation
3013
- - Multi-token analysis
3014
- - Fee structure exploration
3015
- - Slippage testing scenarios
3016
-
3017
- #### DEX Trading Operations (6 Demos)
3018
-
3019
- Graduated token trading on GalaSwap DEX with full liquidity pool support:
3020
-
3021
- ```bash
3022
- # DEX swap workflow (quote → execute → confirm)
3023
- npm run demo:dex
3024
-
3025
- # Pool discovery and metrics
3026
- npm run demo:dex:pools
3027
-
3028
- # Pool pricing and TVL analysis
3029
- npm run demo:dex:pricing
3030
-
3031
- # Quote comparison (exact input vs exact output)
3032
- npm run demo:dex:quotes
3033
-
3034
- # Complete swap roundtrip (buy → sell → verify)
3035
- npm run demo:roundtrip:swap
3036
- ```
3037
-
3038
- #### Fee Generation and Collection (5 Demos)
3039
-
3040
- Liquidity provider fee workflows with multi-wallet testing:
3041
-
3042
- ```bash
3043
- # Basic fee generation and collection
3044
- npm run demo:fees
3045
-
3046
- # High-volume trading fee accumulation
3047
- npm run demo:fees:high-volume
3048
-
3049
- # Complete fee lifecycle test suite
3050
- npm run demo:fees:test
3051
-
3052
- # Trade and collect fees in single workflow
3053
- npm run demo:fees:trade-collect
3054
- ```
3055
-
3056
- **Note:** `demo-multi-wallet-fee-generation.ts` is available but not exposed in npm scripts (advanced usage).
3057
-
3058
- #### Real-Time Monitoring (2 Demos)
3059
-
3060
- WebSocket-based event watchers for pool and token creation:
3061
-
3062
- ```bash
3063
- # Watch for new DEX pool creation
3064
- npm run demo:watch
3065
-
3066
- # Watch for new launchpad token launches
3067
- npm run demo:watch:tokens
3068
- ```
3069
-
3070
- #### Utility Operations (5 Demos)
3071
-
3072
- Balance queries, caching, and token supply information:
3073
-
3074
- ```bash
3075
- # Metadata cache warming and performance testing
3076
- npm run demo:cache
3077
-
3078
- # Token supply metrics from GalaChain
3079
- npm run demo:token-supply
3080
- ```
3081
-
3082
- **Additional utilities:**
3083
- - `balances.ts` - Multi-token balance queries
3084
- - `balance.ts` - Single token balance check
3085
- - `price-history.ts` - Historical price data (Node.js only)
3086
-
3087
- #### Debug and Development Tools
3088
-
3089
- Advanced troubleshooting and environment testing:
3090
-
3091
- ```bash
3092
- # Environment alignment verification
3093
- tsx examples/debug/test-env-alignment.ts
3094
-
3095
- # Slot0 data debugging
3096
- tsx examples/debug/debug-getslot0-test.ts
3097
-
3098
- # DEX simulation with monkey patching
3099
- tsx examples/debug/demo-dex-monkey-patch-simulation.ts
3100
- ```
3101
-
3102
- #### Demo Statistics
3103
-
3104
- - **Total Demos:** 36 working examples
3105
- - **npm Scripts:** 25 convenient shortcuts
3106
- - **Categories:** 8 organized directories
3107
- - **Coverage:** All major SDK features demonstrated
3108
-
3109
- #### Recommended Learning Path
3110
-
3111
- 1. **Start Here:** `npm run demo` - Complete SDK overview
3112
- 2. **Liquidity Basics:** `npm run demo:liquidity` - Interactive CLI
3113
- 3. **DEX Trading:** `npm run demo:dex` - Swap workflow
3114
- 4. **Fee Management:** `npm run demo:fees` - LP fee collection
3115
- 5. **Advanced:** Explore individual demos by category
3116
-
3117
- #### Migration Notes
3118
-
3119
- **Removed Scripts (v3.32.0+):**
3120
- - `demo:liquidity:simple` - Merged into `demo:liquidity`
3121
- - `demo:liquidity:workflow` - Replaced by orchestrator pattern
3122
- - `demo:dex:swap` - Renamed to `demo:dex` for consistency
3123
-
3124
- **New in v3.32.0+:**
3125
- - Organized directory structure with 8 categories
3126
- - Bonding curve orchestrator (in development)
3127
- - Fee demo npm scripts now exposed
3128
- - Symmetry: Both bonding-curve and dex have pool discovery demos
3129
-
3130
- For detailed migration guide, see [docs/DEMO_MIGRATION_GUIDE.md](./docs/DEMO_MIGRATION_GUIDE.md).
3131
-
3132
- ## Architecture
3133
-
3134
- The SDK uses a **service-based architecture** with backend-aligned services:
3135
-
3136
- ### Backend-Aligned Services
3137
-
3138
- ```typescript
3139
- // Each service maps 1:1 to a specific backend
3140
- import {
3141
- LaunchpadService, // → launchpad-backend (pools, trades, comments, profiles)
3142
- GalaChainService, // → galachain-gateway (balances, transfers, pool details)
3143
- DexService, // → dex-api (spot prices)
3144
- BundleService, // → bundle-backend (transaction bundling, trading)
3145
- WebSocketService // → WebSocket endpoint (real-time monitoring)
3146
- } from '@gala-chain/launchpad-sdk';
3147
- ```
3148
-
3149
- ### Service Responsibilities
3150
-
3151
- **LaunchpadService** - Launchpad Backend Operations (Facade)
3152
-
3153
- LaunchpadService uses a **facade pattern** internally, delegating to specialized sub-services:
3154
-
3155
- ```typescript
3156
- // Internal architecture (v3.6.0+)
3157
- LaunchpadService (facade)
3158
- ├── PoolService - Pool queries, distribution, badges, volume data
3159
- │ ├── fetchPools() - Supports auto-pagination (v3.11.0+)
3160
- │ ├── fetchAllPools() - Convenience method for fetching all pools
3161
- │ └── ...other pool operations
3162
- ├── TradeService - Trade history and queries
3163
- ├── CommentService - Comments with vault resolution
3164
- ├── UserService - Profile management and token lists
3165
- ├── ImageService - Image upload operations
3166
- └── FaucetService - Faucet transfer operations
3167
- ```
3168
-
3169
- **Facade Benefits:**
3170
- - ✅ Single responsibility: Each sub-service has one clear purpose
3171
- - ✅ Maintainability: 76.8% reduction in main service file (1,657 → 384 lines)
3172
- - ✅ Code reuse: Shared utilities for query building and response normalization
3173
- - ✅ Backward compatibility: All public methods unchanged
3174
- - ✅ Testability: Sub-services can be tested independently
3175
-
3176
- **Public API (unchanged):**
3177
- - Pool management (fetch, create, check) with auto-pagination
3178
- - Trade history
3179
- - Comments (post, fetch)
3180
- - User profiles
3181
- - Token images
3182
- - Faucet operations
3183
-
3184
- **GalaChainService** - Blockchain Operations
3185
- - GALA balance queries
3186
- - Token balance queries
3187
- - Token transfers (GALA & launchpad tokens)
3188
- - Pool details from bonding curve contracts
3189
- - Token resolution
3190
-
3191
- **DexService** - Price Queries
3192
- - Spot price fetching
3193
- - Multi-token price queries
3194
-
3195
- **BundleService** - Transaction Bundling
3196
- - Buy token operations
3197
- - Sell token operations
3198
- - Slippage protection
3199
- - Transaction bundling
3200
-
3201
- **WebSocketService** - Real-time Features
3202
- - Transaction monitoring
3203
- - Status updates
3204
- - Connection management
3205
-
3206
- ### Benefits of Service Architecture
3207
-
3208
- ✅ **Clear Separation**: Each service has a single backend responsibility
3209
- ✅ **Type Safety**: Full TypeScript support across all services
3210
- ✅ **Testability**: Services can be tested independently
3211
- ✅ **Maintainability**: Easy to locate and update backend-specific logic
3212
-
3213
- ### AI Agent Integration
3214
-
3215
- The SDK includes comprehensive utilities for AI agent development:
3216
-
3217
- ```typescript
3218
- import { AgentConfig } from '@gala-chain/launchpad-sdk';
3219
-
3220
- // Quick setup with intelligent defaults
3221
- const { sdk, validation } = await AgentConfig.quickSetup({
3222
- environment: 'development',
3223
- autoValidate: true
3224
- });
3225
-
3226
- console.log(`Ready: ${validation.ready}`);
3227
- console.log(`Can trade: ${validation.capabilities.canTrade}`);
3228
- ```
3229
-
3230
- For comprehensive AI agent integration, see:
3231
- - [AI Agent Integration Guide](./docs/AI-AGENT-GUIDE.md) - Complete guide for agent development
3232
- - [MCP Tool Specification](./docs/MCP-TOOL-SPECIFICATION.md) - Blueprint for MCP server creation
3233
- - [Agent Examples](./docs/agent-examples/) - Working code examples
3234
-
3235
- ## Clean Result Types Architecture
3236
-
3237
- ### Key Benefits
3238
-
3239
- ✅ **Direct Property Access**: No more `result.data.success` chains
3240
- ✅ **Type Safety**: Full TypeScript IntelliSense for all result properties
3241
- ✅ **Semantic Types**: Dates as Date objects, numbers as numbers
3242
- ✅ **Cursor Pagination**: `pageInfo.hasNextPage`, `pageInfo.nextCursor` for cursor-based navigation
3243
- ✅ **Zero Wrapper Overhead**: Clean, direct access to all result data
3244
- ✅ **Options Object Pattern**: All multi-parameter methods use options objects
3245
-
3246
- ### Result Type Examples
3247
-
3248
- ```typescript
3249
- // Pool results with pagination
3250
- interface PoolsResult {
3251
- pools: PoolData[]; // Direct pool array
3252
- cursor?: string; // Cursor for pagination
3253
- total: number; // Total items
3254
- pageSize: number; // Items returned per page
3255
- // ... more properties
3256
- }
3257
-
3258
- // Token balance with typed values
3259
- interface TokenBalanceInfo {
3260
- quantity: string; // Token amount (string for precision)
3261
- holdingPriceUsd: number; // USD value (number for math)
3262
- lastUpdated: Date; // Date object (not string)
3263
- isFinalized: boolean; // Boolean flag
3264
- // ... more properties
3265
- }
3266
-
3267
- // Trading results
3268
- interface AmountCalculationResult {
3269
- amount: string; // Calculated amount
3270
- transactionFee: string; // Fee breakdown
3271
- reverseBondingCurveFee: string; // RBC fee
3272
- // Direct access to all calculation data
3273
- }
3274
- ```
3275
-
3276
-
3277
- ## What's New in v7.0.0+
3278
-
3279
- ### Unified Messages API
3280
-
3281
- All message types (CHAT and COMMENT) are now accessible through a single unified endpoint:
3282
-
3283
- ```typescript
3284
- // List all message types for a token
3285
- const result = await sdk.listMessages({ tokenName: 'anime' });
3286
-
3287
- // Filter by type
3288
- const chatOnly = await sdk.listMessages({
3289
- tokenName: 'anime',
3290
- contentType: 'CHAT'
3291
- });
3292
-
3293
- // Create, update, delete messages
3294
- await sdk.createMessage({
3295
- tokenName: 'anime',
3296
- contentType: 'CHAT',
3297
- content: 'Great project!'
3298
- });
3299
-
3300
- // Pin important messages
3301
- await sdk.pinMessage(messageId);
3302
- ```
3303
-
3304
- ### User Data Access
3305
-
3306
- New methods for accessing user information:
3307
-
3308
- ```typescript
3309
- // Fetch user token balances
3310
- const balances = await sdk.fetchUserBalances({
3311
- address: '0x...',
3312
- pageSize: 50
3313
- });
3314
-
3315
- // Get comprehensive user report (Overseer only)
3316
- const report = await sdk.fetchUserReport({
3317
- address: '0x...'
3318
- });
3319
- ```
3320
-
3321
- ### Token Statistics
3322
-
3323
- Get engagement metrics for tokens:
3324
-
3325
- ```typescript
3326
- const stats = await sdk.fetchTokenStats('anime');
3327
- console.log(`Messages: ${stats.messageCount}`);
3328
- console.log(`Peak viewers: ${stats.peakViewerCount}`);
3329
- ```
3330
-
3331
- ### Simplified Restricted Names Management
3332
-
3333
- Manage platform restricted words with a simplified API:
3334
-
3335
- ```typescript
3336
- // Get current list
3337
- const result = await sdk.getRestrictedNames();
3338
- const names = result.data.content.split('\n');
3339
-
3340
- // Update list
3341
- await sdk.updateRestrictedNames('badword1\nbadword2\nbadword3');
3342
- ```
3343
-
3344
- ## Documentation
3345
-
3346
- Comprehensive documentation for all SDK features:
3347
-
3348
- - **[SDK API Updates](../docs/SDK_API_UPDATES.md)** - Complete guide to new v7.0.0+ methods
3349
- - **[Usage Guide](../docs/USAGE_GUIDE.md)** - Step-by-step examples for all features
3350
- - **[API Reference](../docs/API-REFERENCE.md)** - Complete method reference with signatures
3351
- - **[DTO Reference](../docs/DTO_REFERENCE.md)** - All data type definitions
3352
- - **[Migration Guide](../docs/MIGRATION_GUIDE_SDK.md)** - Upgrading from v6.x to v7.0+
3353
- - **[Examples](./EXAMPLES.md)** - Practical code examples by category
3354
-
3355
- ## Environment URLs
3356
-
3357
- - **Development**: `https://lpad-backend-dev1.defi.gala.com`
3358
- - **Production**: `https://lpad-backend-prod1.defi.gala.com`
3359
-
3360
- ## License
3361
-
3362
- MIT License - see [LICENSE](../../LICENSE) file for details.
3363
-
3364
- ## Contributing
3365
-
3366
- Please read [CONTRIBUTING.md](../../CONTRIBUTING.md) for guidelines on contributing to this project.
84
+ Use `sdk.dex.pools`, `sdk.dex.positions`, `sdk.dex.symbols`, and `sdk.dex.assets` for pool discovery, liquidity, token identifiers, and user assets. DEX reads are unsigned; state-changing DEX calls require the configured signer.
3367
85
 
3368
- ## Support
86
+ ## Hosts
3369
87
 
3370
- - GitHub Issues: [Report bugs and request features](https://github.com/gala-chain/launchpad-sdk/issues)
3371
- - Documentation: [Full documentation and examples](./docs/)
3372
- - API Status: All methods working and tested
88
+ The stage defaults are `lpad-backend.stage.defi.ovh.gala.com` for launchpad reads, `swap-backend.stage.defi.ovh.gala.com` for DEX reads, and `gateway-testnet.galachain.com` for gateway operations. Production host values are selected by `env: 'prod'`.
3373
89
 
3374
- ---
90
+ ## Further reading
3375
91
 
3376
- **Built with love for the Gala ecosystem**
92
+ - [Migration 5.x → 6.0](../../MIGRATION.md)
93
+ - [GSwap integration](../../docs/gswap-integration.md)
94
+ - [Examples](../../examples/)