@pickhooks/sdk 0.0.0-stage → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +309 -3
  3. package/dist/abis/any3.d.ts +2123 -0
  4. package/dist/abis/any3.js +3 -0
  5. package/dist/abis/anytax.d.ts +1786 -0
  6. package/dist/abis/anytax.js +3 -0
  7. package/dist/abis/calls.d.ts +2515 -0
  8. package/dist/abis/calls.js +4 -0
  9. package/dist/abis/common.d.ts +449 -0
  10. package/dist/abis/common.js +91 -0
  11. package/dist/abis/dips.d.ts +897 -0
  12. package/dist/abis/dips.js +2 -0
  13. package/dist/abis/index.d.ts +12 -0
  14. package/dist/abis/index.js +12 -0
  15. package/dist/abis/infra.d.ts +701 -0
  16. package/dist/abis/infra.js +4 -0
  17. package/dist/abis/lever.d.ts +1710 -0
  18. package/dist/abis/lever.js +5 -0
  19. package/dist/abis/lever2.d.ts +2710 -0
  20. package/dist/abis/lever2.js +5 -0
  21. package/dist/abis/pools.d.ts +1898 -0
  22. package/dist/abis/pools.js +4 -0
  23. package/dist/abis/sticky.d.ts +953 -0
  24. package/dist/abis/sticky.js +4 -0
  25. package/dist/abis/v1.d.ts +1627 -0
  26. package/dist/abis/v1.js +5 -0
  27. package/dist/abis/v2.d.ts +3264 -0
  28. package/dist/abis/v2.js +8 -0
  29. package/dist/addresses.d.ts +87 -0
  30. package/dist/addresses.js +62 -0
  31. package/dist/any.d.ts +447 -0
  32. package/dist/any.js +729 -0
  33. package/dist/api.d.ts +62 -0
  34. package/dist/api.js +30 -0
  35. package/dist/blocks.d.ts +107 -0
  36. package/dist/blocks.js +126 -0
  37. package/dist/coin-rules-config.d.ts +8 -0
  38. package/dist/coin-rules-config.js +13 -0
  39. package/dist/coin-rules.d.ts +383 -0
  40. package/dist/coin-rules.js +878 -0
  41. package/dist/coins.d.ts +217 -0
  42. package/dist/coins.js +520 -0
  43. package/dist/dips.d.ts +133 -0
  44. package/dist/dips.js +148 -0
  45. package/dist/errors.d.ts +35 -0
  46. package/dist/errors.js +347 -0
  47. package/dist/index.d.ts +73 -0
  48. package/dist/index.js +58 -0
  49. package/dist/infinity.d.ts +63 -0
  50. package/dist/infinity.js +96 -0
  51. package/dist/infra.d.ts +112 -0
  52. package/dist/infra.js +114 -0
  53. package/dist/lever.d.ts +391 -0
  54. package/dist/lever.js +419 -0
  55. package/dist/pools.d.ts +274 -0
  56. package/dist/pools.js +405 -0
  57. package/dist/sticky-rules.d.ts +179 -0
  58. package/dist/sticky-rules.js +580 -0
  59. package/dist/sticky.d.ts +216 -0
  60. package/dist/sticky.js +292 -0
  61. package/dist/tx.d.ts +70 -0
  62. package/dist/tx.js +69 -0
  63. package/dist/v3.d.ts +42 -0
  64. package/dist/v3.js +98 -0
  65. package/package.json +58 -4
@@ -0,0 +1,4 @@
1
+ // Generated from web/src/lib/infra-abi.ts (the site's ABIs of the live contracts). Do not edit by hand: node scripts/gen-abis.mjs
2
+ export const hooksExecutorAbi = [{ "type": "function", "name": "MAX_FEE_BPS", "inputs": [], "outputs": [{ "name": "", "type": "uint16" }], "stateMutability": "view" }, { "type": "function", "name": "buyProtected", "inputs": [{ "name": "b", "type": "tuple", "components": [{ "name": "token", "type": "address" }, { "name": "target", "type": "address" }, { "name": "swap", "type": "bytes" }, { "name": "swapValue", "type": "uint256" }, { "name": "minCoins", "type": "uint256" }, { "name": "bidId", "type": "uint256" }, { "name": "protectCoins", "type": "uint128" }, { "name": "partialOk", "type": "bool" }, { "name": "maxPremium", "type": "uint256" }, { "name": "to", "type": "address" }, { "name": "deadline", "type": "uint256" }] }], "outputs": [{ "name": "coins", "type": "uint256" }, { "name": "floorId", "type": "uint256" }, { "name": "premium", "type": "uint256" }], "stateMutability": "payable" }, { "type": "function", "name": "collectPlatform", "inputs": [], "outputs": [{ "name": "a", "type": "uint256" }], "stateMutability": "nonpayable" }, { "type": "function", "name": "desk", "inputs": [], "outputs": [{ "name": "", "type": "address" }], "stateMutability": "view" }, { "type": "function", "name": "feeBps", "inputs": [], "outputs": [{ "name": "", "type": "uint16" }], "stateMutability": "view" }, { "type": "function", "name": "isTarget", "inputs": [{ "name": "", "type": "address" }], "outputs": [{ "name": "", "type": "bool" }], "stateMutability": "view" }, { "type": "function", "name": "owner", "inputs": [], "outputs": [{ "name": "", "type": "address" }], "stateMutability": "view" }, { "type": "function", "name": "platformOwed", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "platformWallet", "inputs": [], "outputs": [{ "name": "", "type": "address" }], "stateMutability": "view" }, { "type": "function", "name": "quoteProtect", "inputs": [{ "name": "bidId", "type": "uint256" }, { "name": "coins", "type": "uint256" }, { "name": "protectCoins", "type": "uint128" }, { "name": "partialOk", "type": "bool" }], "outputs": [{ "name": "protect", "type": "uint128" }, { "name": "cover", "type": "uint256" }, { "name": "premium", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "setFee", "inputs": [{ "name": "feeBps_", "type": "uint16" }], "outputs": [], "stateMutability": "nonpayable" }, { "type": "function", "name": "setOwner", "inputs": [{ "name": "owner_", "type": "address" }], "outputs": [], "stateMutability": "nonpayable" }, { "type": "function", "name": "setPlatform", "inputs": [{ "name": "wallet", "type": "address" }], "outputs": [], "stateMutability": "nonpayable" }, { "type": "event", "name": "FeeSet", "inputs": [{ "name": "feeBps", "type": "uint16", "indexed": false }], "anonymous": false }, { "type": "event", "name": "OwnerSet", "inputs": [{ "name": "owner", "type": "address", "indexed": false }], "anonymous": false }, { "type": "event", "name": "PlatformCollected", "inputs": [{ "name": "to", "type": "address", "indexed": true }, { "name": "amount", "type": "uint256", "indexed": false }], "anonymous": false }, { "type": "event", "name": "PlatformSet", "inputs": [{ "name": "wallet", "type": "address", "indexed": false }], "anonymous": false }, { "type": "event", "name": "ProtectedBuy", "inputs": [{ "name": "buyer", "type": "address", "indexed": true }, { "name": "to", "type": "address", "indexed": true }, { "name": "token", "type": "address", "indexed": true }, { "name": "bnbIn", "type": "uint256", "indexed": false }, { "name": "coins", "type": "uint256", "indexed": false }, { "name": "bidId", "type": "uint256", "indexed": false }, { "name": "floorId", "type": "uint256", "indexed": false }, { "name": "protectedCoins", "type": "uint128", "indexed": false }, { "name": "premium", "type": "uint256", "indexed": false }, { "name": "fee", "type": "uint256", "indexed": false }], "anonymous": false }, { "type": "error", "name": "Expired", "inputs": [] }, { "type": "error", "name": "FeeTooHigh", "inputs": [] }, { "type": "error", "name": "NotOwner", "inputs": [] }, { "type": "error", "name": "NothingOwed", "inputs": [] }, { "type": "error", "name": "NothingToProtect", "inputs": [] }, { "type": "error", "name": "PremiumTooHigh", "inputs": [] }, { "type": "error", "name": "Reentrant", "inputs": [] }, { "type": "error", "name": "SendFailed", "inputs": [] }, { "type": "error", "name": "Swap", "inputs": [{ "name": "reason", "type": "bytes" }] }, { "type": "error", "name": "Target", "inputs": [] }, { "type": "error", "name": "TooFewCoins", "inputs": [] }, { "type": "error", "name": "Value", "inputs": [] }, { "type": "error", "name": "WrongCoin", "inputs": [] }, { "type": "error", "name": "ZeroAddress", "inputs": [] }];
3
+ export const hooksFloorAbi = [{ "type": "function", "name": "DEAD", "inputs": [], "outputs": [{ "name": "", "type": "address" }], "stateMutability": "view" }, { "type": "function", "name": "KEEP_BPS", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "PRICE_UNIT", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "PROTOCOL_BPS", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "burnHeld", "inputs": [], "outputs": [], "stateMutability": "nonpayable" }, { "type": "function", "name": "circulating", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "collectProtocol", "inputs": [], "outputs": [{ "name": "a", "type": "uint256" }], "stateMutability": "nonpayable" }, { "type": "function", "name": "feed", "inputs": [], "outputs": [], "stateMutability": "payable" }, { "type": "function", "name": "floor", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "protocol", "inputs": [], "outputs": [{ "name": "", "type": "address" }], "stateMutability": "view" }, { "type": "function", "name": "protocolOwed", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "quote", "inputs": [{ "name": "coins", "type": "uint256" }], "outputs": [{ "name": "payout", "type": "uint256" }, { "name": "kept", "type": "uint256" }, { "name": "protocolFee", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "redeem", "inputs": [{ "name": "coins", "type": "uint256" }, { "name": "minBnb", "type": "uint256" }, { "name": "to", "type": "address" }], "outputs": [{ "name": "payout", "type": "uint256" }], "stateMutability": "nonpayable" }, { "type": "function", "name": "reserve", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "supplyAtStart", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "token", "inputs": [], "outputs": [{ "name": "", "type": "address" }], "stateMutability": "view" }, { "type": "function", "name": "totalFed", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "totalPaid", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "totalRedeemed", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "event", "name": "Burned", "inputs": [{ "name": "coins", "type": "uint256", "indexed": false }], "anonymous": false }, { "type": "event", "name": "Fed", "inputs": [{ "name": "from", "type": "address", "indexed": true }, { "name": "amount", "type": "uint256", "indexed": false }], "anonymous": false }, { "type": "event", "name": "ProtocolCollected", "inputs": [{ "name": "to", "type": "address", "indexed": true }, { "name": "amount", "type": "uint256", "indexed": false }], "anonymous": false }, { "type": "event", "name": "Redeemed", "inputs": [{ "name": "by", "type": "address", "indexed": true }, { "name": "to", "type": "address", "indexed": true }, { "name": "coins", "type": "uint256", "indexed": false }, { "name": "payout", "type": "uint256", "indexed": false }, { "name": "kept", "type": "uint256", "indexed": false }, { "name": "protocolFee", "type": "uint256", "indexed": false }], "anonymous": false }, { "type": "error", "name": "Amount", "inputs": [] }, { "type": "error", "name": "Delivery", "inputs": [] }, { "type": "error", "name": "NothingOwed", "inputs": [] }, { "type": "error", "name": "PayoutTooLow", "inputs": [] }, { "type": "error", "name": "Reentrant", "inputs": [] }, { "type": "error", "name": "SendFailed", "inputs": [] }, { "type": "error", "name": "SupplyGrew", "inputs": [] }, { "type": "error", "name": "ZeroAddress", "inputs": [] }];
4
+ export const hooksFloorFactoryAbi = [{ "type": "function", "name": "count", "inputs": [], "outputs": [{ "name": "", "type": "uint256" }], "stateMutability": "view" }, { "type": "function", "name": "floorOf", "inputs": [{ "name": "", "type": "address" }], "outputs": [{ "name": "", "type": "address" }], "stateMutability": "view" }, { "type": "function", "name": "floors", "inputs": [{ "name": "start", "type": "uint256" }, { "name": "n", "type": "uint256" }], "outputs": [{ "name": "out", "type": "address[]" }], "stateMutability": "view" }, { "type": "function", "name": "open", "inputs": [{ "name": "token", "type": "address" }], "outputs": [{ "name": "floor", "type": "address" }], "stateMutability": "payable" }, { "type": "function", "name": "predict", "inputs": [{ "name": "token", "type": "address" }], "outputs": [{ "name": "", "type": "address" }], "stateMutability": "view" }, { "type": "function", "name": "protocol", "inputs": [], "outputs": [{ "name": "", "type": "address" }], "stateMutability": "view" }, { "type": "event", "name": "FloorOpened", "inputs": [{ "name": "token", "type": "address", "indexed": true }, { "name": "floor", "type": "address", "indexed": true }, { "name": "by", "type": "address", "indexed": true }], "anonymous": false }, { "type": "error", "name": "Exists", "inputs": [] }, { "type": "error", "name": "ZeroAddress", "inputs": [] }];