anymal-protocol 1.0.123 → 1.0.124

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.
package/dist/index.js CHANGED
@@ -24,11 +24,19 @@ __export(index_exports, {
24
24
  ActionSourceType: () => ActionSourceType,
25
25
  ActionStatus: () => ActionStatus,
26
26
  ActionType: () => ActionType,
27
+ ERROR_ABI: () => ERROR_ABI,
27
28
  FIREBASE_WEB_API_KEYS: () => FIREBASE_WEB_API_KEYS,
28
29
  FIREBASE_WEB_AUTH_API_ENDPOINTS: () => FIREBASE_WEB_AUTH_API_ENDPOINTS,
30
+ KIBBLE_TOKEN_ABI: () => KIBBLE_TOKEN_ABI,
31
+ MARKETPLACE_ABI: () => MARKETPLACE_ABI,
29
32
  MarketplacePaymentType: () => MarketplacePaymentType,
30
33
  NETWORK_HOSTS: () => NETWORK_HOSTS,
31
34
  Network: () => Network,
35
+ ORGANIZATION_BEACON_ABI: () => ORGANIZATION_BEACON_ABI,
36
+ ORGANIZATION_IMPL_ABI: () => ORGANIZATION_IMPL_ABI,
37
+ ORG_FUNCTION: () => ORG_FUNCTION,
38
+ PET_NFT_ABI: () => PET_NFT_ABI,
39
+ REWARDABLE_ACTIONS_ABI: () => REWARDABLE_ACTIONS_ABI,
32
40
  convertToActionDefinition: () => convertToActionDefinition,
33
41
  convertToActionRecord: () => convertToActionRecord,
34
42
  convertToMultipleActionDefinitions: () => convertToMultipleActionDefinitions,
@@ -71,6 +79,7 @@ __export(index_exports, {
71
79
  useProcessOrgPartialKibblePayment: () => useProcessOrgPartialKibblePayment,
72
80
  useProcessPartialKibblePayment: () => useProcessPartialKibblePayment,
73
81
  useSaveAnymalMetadata: () => useSaveAnymalMetadata,
82
+ useSendCoinbaseUserOperation: () => useSendCoinbaseUserOperation,
74
83
  useSubmitContractAction: () => useSubmitContractAction,
75
84
  useUpdateAnymalWithNFT: () => useUpdateAnymalWithNFT,
76
85
  useUpdateOrgWalletAddress: () => useUpdateOrgWalletAddress,
@@ -458,15 +467,1140 @@ function useFetchNotifications() {
458
467
  );
459
468
  }
460
469
 
461
- // src/utils/anymals/useMintAnymalNFT.ts
462
- var import_viem3 = require("viem");
470
+ // src/utils/coinbase/useSendCoinbaseUserOperation.ts
471
+ var import_react10 = require("react");
472
+ var import_cdp_hooks = require("@coinbase/cdp-hooks");
473
+ function useSendCoinbaseUserOperation() {
474
+ const { sendUserOperation, data, error, status } = (0, import_cdp_hooks.useSendUserOperation)();
475
+ const sendOperationFn = (0, import_react10.useCallback)(
476
+ async (evmAddress, callData, contractAddress) => {
477
+ if (!evmAddress || !callData || !contractAddress) {
478
+ return { success: false, message: "Missing required information" };
479
+ }
480
+ try {
481
+ await sendUserOperation({
482
+ evmSmartAccount: evmAddress,
483
+ network: "base-sepolia",
484
+ useCdpPaymaster: true,
485
+ calls: [{ data: callData, to: contractAddress }]
486
+ });
487
+ return { success: true, message: "Operation submitted." };
488
+ } catch (e) {
489
+ console.error(e);
490
+ return { success: false, message: e.message };
491
+ }
492
+ },
493
+ [sendUserOperation]
494
+ );
495
+ return { sendOperationFn, data, status, error };
496
+ }
463
497
 
464
498
  // src/helpers/BlockchainAbiHelper.tsx
465
499
  var import_viem = require("viem");
466
- var PET_NFT_ABI = [{ "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, { "inputs": [], "name": "AccessControlBadConfirmation", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, { "internalType": "bytes32", "name": "neededRole", "type": "bytes32" }], "name": "AccessControlUnauthorizedAccount", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "target", "type": "address" }], "name": "AddressEmptyCode", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }], "name": "ERC1967InvalidImplementation", "type": "error" }, { "inputs": [], "name": "ERC1967NonPayable", "type": "error" }, { "inputs": [], "name": "EnforcedPause", "type": "error" }, { "inputs": [], "name": "ExpectedPause", "type": "error" }, { "inputs": [], "name": "FailedCall", "type": "error" }, { "inputs": [], "name": "InvalidInitialization", "type": "error" }, { "inputs": [], "name": "NotInitializing", "type": "error" }, { "inputs": [], "name": "UUPSUnauthorizedCallContext", "type": "error" }, { "inputs": [{ "internalType": "bytes32", "name": "slot", "type": "bytes32" }], "name": "UUPSUnsupportedProxiableUUID", "type": "error" }, { "anonymous": false, "inputs": [{ "indexed": false, "internalType": "uint64", "name": "version", "type": "uint64" }], "name": "Initialized", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }, { "indexed": false, "internalType": "string", "name": "pid", "type": "string" }, { "indexed": false, "internalType": "string", "name": "nftId", "type": "string" }, { "indexed": false, "internalType": "string", "name": "metadataURL", "type": "string" }, { "indexed": false, "internalType": "uint256", "name": "campaignId", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "rewardAmount", "type": "uint256" }, { "indexed": false, "internalType": "string", "name": "_anymalTxId", "type": "string" }], "name": "MetadataApproved", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }, { "indexed": false, "internalType": "string", "name": "anymalTxId", "type": "string" }, { "indexed": false, "internalType": "string", "name": "pid", "type": "string" }, { "indexed": false, "internalType": "string", "name": "nftId", "type": "string" }, { "indexed": false, "internalType": "string", "name": "metadataURL", "type": "string" }, { "indexed": false, "internalType": "uint256", "name": "campaignId", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "rewardAmount", "type": "uint256" }, { "indexed": false, "internalType": "string", "name": "_anymalTxId", "type": "string" }], "name": "MetadataRejected", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }, { "indexed": false, "internalType": "string", "name": "pid", "type": "string" }, { "indexed": false, "internalType": "string", "name": "nftId", "type": "string" }, { "indexed": false, "internalType": "string", "name": "metadataURL", "type": "string" }, { "indexed": false, "internalType": "uint256", "name": "campaignId", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "rewardAmount", "type": "uint256" }, { "indexed": false, "internalType": "string", "name": "_anymalTxId", "type": "string" }], "name": "MetadataSubmitted", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], "name": "Paused", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }, { "indexed": false, "internalType": "string", "name": "pid", "type": "string" }, { "indexed": false, "internalType": "string", "name": "nftId", "type": "string" }, { "indexed": false, "internalType": "uint256", "name": "rewardAmount", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "campaignId", "type": "uint256" }, { "indexed": false, "internalType": "string", "name": "_anymalTxId", "type": "string" }], "name": "RewardDistributed", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" }], "name": "RoleAdminChanged", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], "name": "RoleGranted", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], "name": "RoleRevoked", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], "name": "Unpaused", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], "name": "Upgraded", "type": "event" }, { "inputs": [], "name": "APPROVER_ROLE", "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "DEFAULT_ADMIN_ROLE", "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "UPGRADE_INTERFACE_VERSION", "outputs": [{ "internalType": "string", "name": "", "type": "string" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "_user", "type": "address" }, { "internalType": "string", "name": "_pid", "type": "string" }, { "internalType": "string", "name": "_nftId", "type": "string" }, { "internalType": "string", "name": "_metadataURL", "type": "string" }, { "internalType": "uint256", "name": "_campaignId", "type": "uint256" }, { "internalType": "string", "name": "_anymalTxId", "type": "string" }], "name": "approveMetadata", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "campaignCount", "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], "name": "campaigns", "outputs": [{ "internalType": "string", "name": "name", "type": "string" }, { "internalType": "uint256", "name": "rewardAmount", "type": "uint256" }, { "internalType": "bool", "name": "isActive", "type": "bool" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "string", "name": "_name", "type": "string" }, { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" }], "name": "createCampaign", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "defaultRewardAmount", "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], "name": "getRoleAdmin", "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "internalType": "address", "name": "account", "type": "address" }], "name": "grantRole", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "internalType": "address", "name": "account", "type": "address" }], "name": "hasRole", "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }, { "internalType": "contract IERC20", "name": "_rewardToken", "type": "address" }, { "internalType": "contract IPetToken", "name": "_petToken", "type": "address" }, { "internalType": "uint256", "name": "_defaultRewardAmount", "type": "uint256" }], "name": "initialize", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "paused", "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "petToken", "outputs": [{ "internalType": "contract IPetToken", "name": "", "type": "address" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "proxiableUUID", "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "internalType": "address", "name": "callerConfirmation", "type": "address" }], "name": "renounceRole", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "internalType": "address", "name": "account", "type": "address" }], "name": "revokeRole", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "rewardToken", "outputs": [{ "internalType": "contract IERC20", "name": "", "type": "address" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "string", "name": "_pid", "type": "string" }, { "internalType": "string", "name": "_nftId", "type": "string" }, { "internalType": "string", "name": "_metadataURL", "type": "string" }, { "internalType": "uint256", "name": "_campaignId", "type": "uint256" }, { "internalType": "string", "name": "_anymalTxId", "type": "string" }], "name": "submitMetadata", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "string", "name": "_pid", "type": "string" }, { "internalType": "string", "name": "_nftId", "type": "string" }, { "internalType": "string", "name": "_metadataURL", "type": "string" }, { "internalType": "string", "name": "_campaignName", "type": "string" }, { "internalType": "string", "name": "_anymalTxId", "type": "string" }], "name": "submitMetadataByCampaignName", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], "name": "supportsInterface", "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "uint256", "name": "_campaignId", "type": "uint256" }, { "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" }, { "internalType": "bool", "name": "_isActive", "type": "bool" }], "name": "updateCampaign", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" }], "name": "updateDefaultReward", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }, { "internalType": "bytes", "name": "data", "type": "bytes" }], "name": "upgradeToAndCall", "outputs": [], "stateMutability": "payable", "type": "function" }];
467
- var MARKETPLACE_ABI = [{ "inputs": [{ "internalType": "address", "name": "target", "type": "address" }], "name": "AddressEmptyCode", "type": "error" }, { "inputs": [], "name": "ECDSAInvalidSignature", "type": "error" }, { "inputs": [{ "internalType": "uint256", "name": "length", "type": "uint256" }], "name": "ECDSAInvalidSignatureLength", "type": "error" }, { "inputs": [{ "internalType": "bytes32", "name": "s", "type": "bytes32" }], "name": "ECDSAInvalidSignatureS", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }], "name": "ERC1967InvalidImplementation", "type": "error" }, { "inputs": [], "name": "ERC1967NonPayable", "type": "error" }, { "inputs": [], "name": "FailedCall", "type": "error" }, { "inputs": [], "name": "InvalidInitialization", "type": "error" }, { "inputs": [], "name": "NotInitializing", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], "name": "OwnableInvalidOwner", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], "name": "OwnableUnauthorizedAccount", "type": "error" }, { "inputs": [], "name": "UUPSUnauthorizedCallContext", "type": "error" }, { "inputs": [{ "internalType": "bytes32", "name": "slot", "type": "bytes32" }], "name": "UUPSUnsupportedProxiableUUID", "type": "error" }, { "anonymous": false, "inputs": [{ "indexed": false, "internalType": "uint64", "name": "version", "type": "uint64" }], "name": "Initialized", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" }], "name": "OwnershipTransferred", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "string", "name": "orderId", "type": "string" }, { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, { "indexed": true, "internalType": "string", "name": "pid", "type": "string" }, { "indexed": false, "internalType": "string", "name": "anymalNftId", "type": "string" }, { "indexed": false, "internalType": "uint256", "name": "amountInTokens", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" }], "name": "PartialPaymentMade", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "string", "name": "orderId", "type": "string" }, { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "amountInTokens", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" }], "name": "PaymentMade", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "string", "name": "orderId", "type": "string" }, { "indexed": true, "internalType": "address", "name": "payer", "type": "address" }, { "indexed": true, "internalType": "string", "name": "pid", "type": "string" }, { "indexed": false, "internalType": "uint256", "name": "refundedAmount", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" }], "name": "RefundProcessed", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": false, "internalType": "bool", "name": "enabled", "type": "bool" }], "name": "SignatureCheckToggled", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], "name": "Upgraded", "type": "event" }, { "inputs": [], "name": "UPGRADE_INTERFACE_VERSION", "outputs": [{ "internalType": "string", "name": "", "type": "string" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "authorizer", "outputs": [{ "internalType": "address", "name": "", "type": "address" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "_initialOwner", "type": "address" }, { "internalType": "address", "name": "_authorizer", "type": "address" }, { "internalType": "address", "name": "_kibbleToken", "type": "address" }], "name": "initialize", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "kibbleToken", "outputs": [{ "internalType": "contract IERC20", "name": "", "type": "address" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "owner", "outputs": [{ "internalType": "address", "name": "", "type": "address" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }, { "internalType": "address", "name": "", "type": "address" }], "name": "paidAmounts", "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "string", "name": "orderId", "type": "string" }, { "internalType": "string", "name": "anymalNftId", "type": "string" }, { "internalType": "string", "name": "pid", "type": "string" }, { "internalType": "uint256", "name": "amountInTokens", "type": "uint256" }, { "internalType": "uint256", "name": "maxTokenPayment", "type": "uint256" }, { "internalType": "bytes32", "name": "nonce", "type": "bytes32" }, { "internalType": "uint256", "name": "deadline", "type": "uint256" }, { "internalType": "bytes", "name": "backendSignature", "type": "bytes" }], "name": "partialPay", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "proxiableUUID", "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "string", "name": "orderId", "type": "string" }, { "internalType": "address", "name": "payer", "type": "address" }, { "internalType": "string", "name": "pid", "type": "string" }], "name": "refund", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "_authorizer", "type": "address" }], "name": "setAuthorizer", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "bool", "name": "enabled", "type": "bool" }], "name": "setSignatureCheckEnabled", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "signatureCheckEnabled", "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], "name": "transferOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }, { "internalType": "bytes", "name": "data", "type": "bytes" }], "name": "upgradeToAndCall", "outputs": [], "stateMutability": "payable", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "name": "usedNonces", "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "to", "type": "address" }, { "internalType": "uint256", "name": "amount", "type": "uint256" }], "name": "withdrawKibble", "outputs": [], "stateMutability": "nonpayable", "type": "function" }];
468
- var ORGANIZATION_BEACON_ABI = [{ "inputs": [{ "internalType": "address", "name": "_initialImplementation", "type": "address" }, { "internalType": "address", "name": "_initialOwner", "type": "address" }, { "internalType": "address", "name": "_anymalNFTProxy", "type": "address" }], "stateMutability": "nonpayable", "type": "constructor" }, { "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }], "name": "BeaconInvalidImplementation", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], "name": "OwnableInvalidOwner", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], "name": "OwnableUnauthorizedAccount", "type": "error" }, { "anonymous": false, "inputs": [{ "indexed": false, "internalType": "string", "name": "pid", "type": "string" }, { "indexed": false, "internalType": "string", "name": "name", "type": "string" }, { "indexed": false, "internalType": "address", "name": "proxyAddress", "type": "address" }, { "indexed": false, "internalType": "address", "name": "networkAdmin", "type": "address" }, { "indexed": false, "internalType": "address", "name": "userAdmin", "type": "address" }], "name": "NewOrganizationCreated", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" }], "name": "OwnershipTransferred", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], "name": "Upgraded", "type": "event" }, { "inputs": [], "name": "anymalNFTProxy", "outputs": [{ "internalType": "address", "name": "", "type": "address" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "_userAdmin", "type": "address" }, { "internalType": "string", "name": "_orgName", "type": "string" }, { "internalType": "string", "name": "_orgPid", "type": "string" }], "name": "createOrganizationProxy", "outputs": [{ "internalType": "address", "name": "proxyAddress", "type": "address" }], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "implementation", "outputs": [{ "internalType": "address", "name": "", "type": "address" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "owner", "outputs": [{ "internalType": "address", "name": "", "type": "address" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], "name": "transferOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], "name": "upgradeBeaconTo", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }], "name": "upgradeTo", "outputs": [], "stateMutability": "nonpayable", "type": "function" }];
469
- var REWARDABLE_ACTIONS_ABI = [{ "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, { "inputs": [], "name": "AccessControlBadConfirmation", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, { "internalType": "bytes32", "name": "neededRole", "type": "bytes32" }], "name": "AccessControlUnauthorizedAccount", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "target", "type": "address" }], "name": "AddressEmptyCode", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }], "name": "ERC1967InvalidImplementation", "type": "error" }, { "inputs": [], "name": "ERC1967NonPayable", "type": "error" }, { "inputs": [], "name": "FailedCall", "type": "error" }, { "inputs": [], "name": "InvalidInitialization", "type": "error" }, { "inputs": [], "name": "NotInitializing", "type": "error" }, { "inputs": [], "name": "ReentrancyGuardReentrantCall", "type": "error" }, { "inputs": [], "name": "UUPSUnauthorizedCallContext", "type": "error" }, { "inputs": [{ "internalType": "bytes32", "name": "slot", "type": "bytes32" }], "name": "UUPSUnsupportedProxiableUUID", "type": "error" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, { "indexed": false, "internalType": "uint256", "name": "rewardAmount", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "maxClaims", "type": "uint256" }], "name": "ActionTypeAdded", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, { "indexed": false, "internalType": "uint256", "name": "newRewardAmount", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "newMaxClaims", "type": "uint256" }], "name": "ActionTypeUpdated", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, { "indexed": true, "internalType": "uint256", "name": "index", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "quantity", "type": "uint256" }, { "indexed": false, "internalType": "uint16", "name": "multiplier", "type": "uint16" }], "name": "ActionValidated", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": false, "internalType": "uint64", "name": "version", "type": "uint64" }], "name": "Initialized", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, { "indexed": true, "internalType": "address", "name": "user", "type": "address" }, { "indexed": true, "internalType": "uint256", "name": "index", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" }], "name": "RewardClaimedByIndex", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "indexed": true, "internalType": "bytes32", "name": "previousAdminRole", "type": "bytes32" }, { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" }], "name": "RoleAdminChanged", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], "name": "RoleGranted", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "indexed": true, "internalType": "address", "name": "account", "type": "address" }, { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }], "name": "RoleRevoked", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], "name": "Upgraded", "type": "event" }, { "inputs": [], "name": "ADMIN_ROLE", "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "APPROVER_ROLE", "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "DEFAULT_ADMIN_ROLE", "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "UPGRADE_INTERFACE_VERSION", "outputs": [{ "internalType": "string", "name": "", "type": "string" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "name": "actionConfigs", "outputs": [{ "internalType": "uint256", "name": "rewardAmount", "type": "uint256" }, { "internalType": "uint256", "name": "maxClaims", "type": "uint256" }, { "internalType": "bool", "name": "exists", "type": "bool" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, { "internalType": "uint256", "name": "rewardAmount", "type": "uint256" }, { "internalType": "uint256", "name": "maxClaims", "type": "uint256" }], "name": "addActionType", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, { "internalType": "uint256", "name": "index", "type": "uint256" }], "name": "claimByIndex", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], "name": "depositRewards", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }], "name": "getRoleAdmin", "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "internalType": "address", "name": "account", "type": "address" }], "name": "grantRole", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "internalType": "address", "name": "account", "type": "address" }], "name": "hasRole", "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }, { "internalType": "contract IERC20", "name": "_rewardToken", "type": "address" }], "name": "initialize", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "proxiableUUID", "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "internalType": "address", "name": "callerConfirmation", "type": "address" }], "name": "renounceRole", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, { "internalType": "address", "name": "account", "type": "address" }], "name": "revokeRole", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "rewardToken", "outputs": [{ "internalType": "contract IERC20", "name": "", "type": "address" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }], "name": "supportsInterface", "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "user", "type": "address" }, { "internalType": "bytes32", "name": "actionId", "type": "bytes32" }], "name": "totalValidatedSlots", "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "user", "type": "address" }, { "internalType": "bytes32", "name": "actionId", "type": "bytes32" }], "name": "unclaimedSlots", "outputs": [{ "internalType": "uint256", "name": "count", "type": "uint256" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, { "internalType": "uint256", "name": "newRewardAmount", "type": "uint256" }, { "internalType": "uint256", "name": "newMaxClaims", "type": "uint256" }], "name": "updateActionType", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }, { "internalType": "bytes", "name": "data", "type": "bytes" }], "name": "upgradeToAndCall", "outputs": [], "stateMutability": "payable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "user", "type": "address" }, { "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, { "internalType": "uint256", "name": "quantity", "type": "uint256" }, { "internalType": "uint16", "name": "multiplier", "type": "uint16" }], "name": "validateAction", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }, { "internalType": "address", "name": "", "type": "address" }, { "internalType": "uint256", "name": "", "type": "uint256" }], "name": "validations", "outputs": [{ "internalType": "uint256", "name": "quantity", "type": "uint256" }, { "internalType": "uint16", "name": "multiplier", "type": "uint16" }, { "internalType": "bool", "name": "claimed", "type": "bool" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }], "name": "withdrawRewards", "outputs": [], "stateMutability": "nonpayable", "type": "function" }];
500
+ var PET_NFT_ABI = [{ "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, {
501
+ "inputs": [],
502
+ "name": "AccessControlBadConfirmation",
503
+ "type": "error"
504
+ }, {
505
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, {
506
+ "internalType": "bytes32",
507
+ "name": "neededRole",
508
+ "type": "bytes32"
509
+ }],
510
+ "name": "AccessControlUnauthorizedAccount",
511
+ "type": "error"
512
+ }, {
513
+ "inputs": [{ "internalType": "address", "name": "target", "type": "address" }],
514
+ "name": "AddressEmptyCode",
515
+ "type": "error"
516
+ }, {
517
+ "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }],
518
+ "name": "ERC1967InvalidImplementation",
519
+ "type": "error"
520
+ }, { "inputs": [], "name": "ERC1967NonPayable", "type": "error" }, {
521
+ "inputs": [],
522
+ "name": "EnforcedPause",
523
+ "type": "error"
524
+ }, { "inputs": [], "name": "ExpectedPause", "type": "error" }, {
525
+ "inputs": [],
526
+ "name": "FailedCall",
527
+ "type": "error"
528
+ }, { "inputs": [], "name": "InvalidInitialization", "type": "error" }, {
529
+ "inputs": [],
530
+ "name": "NotInitializing",
531
+ "type": "error"
532
+ }, { "inputs": [], "name": "UUPSUnauthorizedCallContext", "type": "error" }, {
533
+ "inputs": [{
534
+ "internalType": "bytes32",
535
+ "name": "slot",
536
+ "type": "bytes32"
537
+ }],
538
+ "name": "UUPSUnsupportedProxiableUUID",
539
+ "type": "error"
540
+ }, {
541
+ "anonymous": false,
542
+ "inputs": [{ "indexed": false, "internalType": "uint64", "name": "version", "type": "uint64" }],
543
+ "name": "Initialized",
544
+ "type": "event"
545
+ }, {
546
+ "anonymous": false,
547
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }, {
548
+ "indexed": false,
549
+ "internalType": "string",
550
+ "name": "pid",
551
+ "type": "string"
552
+ }, { "indexed": false, "internalType": "string", "name": "nftId", "type": "string" }, {
553
+ "indexed": false,
554
+ "internalType": "string",
555
+ "name": "metadataURL",
556
+ "type": "string"
557
+ }, { "indexed": false, "internalType": "uint256", "name": "campaignId", "type": "uint256" }, {
558
+ "indexed": false,
559
+ "internalType": "uint256",
560
+ "name": "rewardAmount",
561
+ "type": "uint256"
562
+ }, { "indexed": false, "internalType": "string", "name": "_anymalTxId", "type": "string" }],
563
+ "name": "MetadataApproved",
564
+ "type": "event"
565
+ }, {
566
+ "anonymous": false,
567
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }, {
568
+ "indexed": false,
569
+ "internalType": "string",
570
+ "name": "anymalTxId",
571
+ "type": "string"
572
+ }, { "indexed": false, "internalType": "string", "name": "pid", "type": "string" }, {
573
+ "indexed": false,
574
+ "internalType": "string",
575
+ "name": "nftId",
576
+ "type": "string"
577
+ }, { "indexed": false, "internalType": "string", "name": "metadataURL", "type": "string" }, {
578
+ "indexed": false,
579
+ "internalType": "uint256",
580
+ "name": "campaignId",
581
+ "type": "uint256"
582
+ }, { "indexed": false, "internalType": "uint256", "name": "rewardAmount", "type": "uint256" }, {
583
+ "indexed": false,
584
+ "internalType": "string",
585
+ "name": "_anymalTxId",
586
+ "type": "string"
587
+ }],
588
+ "name": "MetadataRejected",
589
+ "type": "event"
590
+ }, {
591
+ "anonymous": false,
592
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }, {
593
+ "indexed": false,
594
+ "internalType": "string",
595
+ "name": "pid",
596
+ "type": "string"
597
+ }, { "indexed": false, "internalType": "string", "name": "nftId", "type": "string" }, {
598
+ "indexed": false,
599
+ "internalType": "string",
600
+ "name": "metadataURL",
601
+ "type": "string"
602
+ }, { "indexed": false, "internalType": "uint256", "name": "campaignId", "type": "uint256" }, {
603
+ "indexed": false,
604
+ "internalType": "uint256",
605
+ "name": "rewardAmount",
606
+ "type": "uint256"
607
+ }, { "indexed": false, "internalType": "string", "name": "_anymalTxId", "type": "string" }],
608
+ "name": "MetadataSubmitted",
609
+ "type": "event"
610
+ }, {
611
+ "anonymous": false,
612
+ "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }],
613
+ "name": "Paused",
614
+ "type": "event"
615
+ }, {
616
+ "anonymous": false,
617
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }, {
618
+ "indexed": false,
619
+ "internalType": "string",
620
+ "name": "pid",
621
+ "type": "string"
622
+ }, { "indexed": false, "internalType": "string", "name": "nftId", "type": "string" }, {
623
+ "indexed": false,
624
+ "internalType": "uint256",
625
+ "name": "rewardAmount",
626
+ "type": "uint256"
627
+ }, { "indexed": false, "internalType": "uint256", "name": "campaignId", "type": "uint256" }, {
628
+ "indexed": false,
629
+ "internalType": "string",
630
+ "name": "_anymalTxId",
631
+ "type": "string"
632
+ }],
633
+ "name": "RewardDistributed",
634
+ "type": "event"
635
+ }, {
636
+ "anonymous": false,
637
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
638
+ "indexed": true,
639
+ "internalType": "bytes32",
640
+ "name": "previousAdminRole",
641
+ "type": "bytes32"
642
+ }, { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" }],
643
+ "name": "RoleAdminChanged",
644
+ "type": "event"
645
+ }, {
646
+ "anonymous": false,
647
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
648
+ "indexed": true,
649
+ "internalType": "address",
650
+ "name": "account",
651
+ "type": "address"
652
+ }, { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }],
653
+ "name": "RoleGranted",
654
+ "type": "event"
655
+ }, {
656
+ "anonymous": false,
657
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
658
+ "indexed": true,
659
+ "internalType": "address",
660
+ "name": "account",
661
+ "type": "address"
662
+ }, { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }],
663
+ "name": "RoleRevoked",
664
+ "type": "event"
665
+ }, {
666
+ "anonymous": false,
667
+ "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }],
668
+ "name": "Unpaused",
669
+ "type": "event"
670
+ }, {
671
+ "anonymous": false,
672
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }],
673
+ "name": "Upgraded",
674
+ "type": "event"
675
+ }, {
676
+ "inputs": [],
677
+ "name": "APPROVER_ROLE",
678
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
679
+ "stateMutability": "view",
680
+ "type": "function"
681
+ }, {
682
+ "inputs": [],
683
+ "name": "DEFAULT_ADMIN_ROLE",
684
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
685
+ "stateMutability": "view",
686
+ "type": "function"
687
+ }, {
688
+ "inputs": [],
689
+ "name": "UPGRADE_INTERFACE_VERSION",
690
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
691
+ "stateMutability": "view",
692
+ "type": "function"
693
+ }, {
694
+ "inputs": [{ "internalType": "address", "name": "_user", "type": "address" }, {
695
+ "internalType": "string",
696
+ "name": "_pid",
697
+ "type": "string"
698
+ }, { "internalType": "string", "name": "_nftId", "type": "string" }, {
699
+ "internalType": "string",
700
+ "name": "_metadataURL",
701
+ "type": "string"
702
+ }, { "internalType": "uint256", "name": "_campaignId", "type": "uint256" }, {
703
+ "internalType": "string",
704
+ "name": "_anymalTxId",
705
+ "type": "string"
706
+ }],
707
+ "name": "approveMetadata",
708
+ "outputs": [],
709
+ "stateMutability": "nonpayable",
710
+ "type": "function"
711
+ }, {
712
+ "inputs": [],
713
+ "name": "campaignCount",
714
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
715
+ "stateMutability": "view",
716
+ "type": "function"
717
+ }, {
718
+ "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
719
+ "name": "campaigns",
720
+ "outputs": [{ "internalType": "string", "name": "name", "type": "string" }, {
721
+ "internalType": "uint256",
722
+ "name": "rewardAmount",
723
+ "type": "uint256"
724
+ }, { "internalType": "bool", "name": "isActive", "type": "bool" }],
725
+ "stateMutability": "view",
726
+ "type": "function"
727
+ }, {
728
+ "inputs": [{ "internalType": "string", "name": "_name", "type": "string" }, {
729
+ "internalType": "uint256",
730
+ "name": "_rewardAmount",
731
+ "type": "uint256"
732
+ }],
733
+ "name": "createCampaign",
734
+ "outputs": [],
735
+ "stateMutability": "nonpayable",
736
+ "type": "function"
737
+ }, {
738
+ "inputs": [],
739
+ "name": "defaultRewardAmount",
740
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
741
+ "stateMutability": "view",
742
+ "type": "function"
743
+ }, {
744
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }],
745
+ "name": "getRoleAdmin",
746
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
747
+ "stateMutability": "view",
748
+ "type": "function"
749
+ }, {
750
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
751
+ "internalType": "address",
752
+ "name": "account",
753
+ "type": "address"
754
+ }],
755
+ "name": "grantRole",
756
+ "outputs": [],
757
+ "stateMutability": "nonpayable",
758
+ "type": "function"
759
+ }, {
760
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
761
+ "internalType": "address",
762
+ "name": "account",
763
+ "type": "address"
764
+ }],
765
+ "name": "hasRole",
766
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
767
+ "stateMutability": "view",
768
+ "type": "function"
769
+ }, {
770
+ "inputs": [{
771
+ "internalType": "address",
772
+ "name": "initialOwner",
773
+ "type": "address"
774
+ }, {
775
+ "internalType": "contract IERC20",
776
+ "name": "_rewardToken",
777
+ "type": "address"
778
+ }, { "internalType": "contract IPetToken", "name": "_petToken", "type": "address" }, {
779
+ "internalType": "uint256",
780
+ "name": "_defaultRewardAmount",
781
+ "type": "uint256"
782
+ }],
783
+ "name": "initialize",
784
+ "outputs": [],
785
+ "stateMutability": "nonpayable",
786
+ "type": "function"
787
+ }, {
788
+ "inputs": [],
789
+ "name": "pause",
790
+ "outputs": [],
791
+ "stateMutability": "nonpayable",
792
+ "type": "function"
793
+ }, {
794
+ "inputs": [],
795
+ "name": "paused",
796
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
797
+ "stateMutability": "view",
798
+ "type": "function"
799
+ }, {
800
+ "inputs": [],
801
+ "name": "petToken",
802
+ "outputs": [{ "internalType": "contract IPetToken", "name": "", "type": "address" }],
803
+ "stateMutability": "view",
804
+ "type": "function"
805
+ }, {
806
+ "inputs": [],
807
+ "name": "proxiableUUID",
808
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
809
+ "stateMutability": "view",
810
+ "type": "function"
811
+ }, {
812
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
813
+ "internalType": "address",
814
+ "name": "callerConfirmation",
815
+ "type": "address"
816
+ }],
817
+ "name": "renounceRole",
818
+ "outputs": [],
819
+ "stateMutability": "nonpayable",
820
+ "type": "function"
821
+ }, {
822
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
823
+ "internalType": "address",
824
+ "name": "account",
825
+ "type": "address"
826
+ }],
827
+ "name": "revokeRole",
828
+ "outputs": [],
829
+ "stateMutability": "nonpayable",
830
+ "type": "function"
831
+ }, {
832
+ "inputs": [],
833
+ "name": "rewardToken",
834
+ "outputs": [{ "internalType": "contract IERC20", "name": "", "type": "address" }],
835
+ "stateMutability": "view",
836
+ "type": "function"
837
+ }, {
838
+ "inputs": [{ "internalType": "string", "name": "_pid", "type": "string" }, {
839
+ "internalType": "string",
840
+ "name": "_nftId",
841
+ "type": "string"
842
+ }, { "internalType": "string", "name": "_metadataURL", "type": "string" }, {
843
+ "internalType": "uint256",
844
+ "name": "_campaignId",
845
+ "type": "uint256"
846
+ }, { "internalType": "string", "name": "_anymalTxId", "type": "string" }],
847
+ "name": "submitMetadata",
848
+ "outputs": [],
849
+ "stateMutability": "nonpayable",
850
+ "type": "function"
851
+ }, {
852
+ "inputs": [{ "internalType": "string", "name": "_pid", "type": "string" }, {
853
+ "internalType": "string",
854
+ "name": "_nftId",
855
+ "type": "string"
856
+ }, { "internalType": "string", "name": "_metadataURL", "type": "string" }, {
857
+ "internalType": "string",
858
+ "name": "_campaignName",
859
+ "type": "string"
860
+ }, { "internalType": "string", "name": "_anymalTxId", "type": "string" }],
861
+ "name": "submitMetadataByCampaignName",
862
+ "outputs": [],
863
+ "stateMutability": "nonpayable",
864
+ "type": "function"
865
+ }, {
866
+ "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }],
867
+ "name": "supportsInterface",
868
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
869
+ "stateMutability": "view",
870
+ "type": "function"
871
+ }, {
872
+ "inputs": [],
873
+ "name": "unpause",
874
+ "outputs": [],
875
+ "stateMutability": "nonpayable",
876
+ "type": "function"
877
+ }, {
878
+ "inputs": [{ "internalType": "uint256", "name": "_campaignId", "type": "uint256" }, {
879
+ "internalType": "uint256",
880
+ "name": "_rewardAmount",
881
+ "type": "uint256"
882
+ }, { "internalType": "bool", "name": "_isActive", "type": "bool" }],
883
+ "name": "updateCampaign",
884
+ "outputs": [],
885
+ "stateMutability": "nonpayable",
886
+ "type": "function"
887
+ }, {
888
+ "inputs": [{ "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" }],
889
+ "name": "updateDefaultReward",
890
+ "outputs": [],
891
+ "stateMutability": "nonpayable",
892
+ "type": "function"
893
+ }, {
894
+ "inputs": [{
895
+ "internalType": "address",
896
+ "name": "newImplementation",
897
+ "type": "address"
898
+ }, { "internalType": "bytes", "name": "data", "type": "bytes" }],
899
+ "name": "upgradeToAndCall",
900
+ "outputs": [],
901
+ "stateMutability": "payable",
902
+ "type": "function"
903
+ }];
904
+ var MARKETPLACE_ABI = [{
905
+ "inputs": [{ "internalType": "address", "name": "target", "type": "address" }],
906
+ "name": "AddressEmptyCode",
907
+ "type": "error"
908
+ }, { "inputs": [], "name": "ECDSAInvalidSignature", "type": "error" }, {
909
+ "inputs": [{
910
+ "internalType": "uint256",
911
+ "name": "length",
912
+ "type": "uint256"
913
+ }],
914
+ "name": "ECDSAInvalidSignatureLength",
915
+ "type": "error"
916
+ }, {
917
+ "inputs": [{ "internalType": "bytes32", "name": "s", "type": "bytes32" }],
918
+ "name": "ECDSAInvalidSignatureS",
919
+ "type": "error"
920
+ }, {
921
+ "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }],
922
+ "name": "ERC1967InvalidImplementation",
923
+ "type": "error"
924
+ }, { "inputs": [], "name": "ERC1967NonPayable", "type": "error" }, {
925
+ "inputs": [],
926
+ "name": "FailedCall",
927
+ "type": "error"
928
+ }, { "inputs": [], "name": "InvalidInitialization", "type": "error" }, {
929
+ "inputs": [],
930
+ "name": "NotInitializing",
931
+ "type": "error"
932
+ }, {
933
+ "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }],
934
+ "name": "OwnableInvalidOwner",
935
+ "type": "error"
936
+ }, {
937
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
938
+ "name": "OwnableUnauthorizedAccount",
939
+ "type": "error"
940
+ }, { "inputs": [], "name": "UUPSUnauthorizedCallContext", "type": "error" }, {
941
+ "inputs": [{
942
+ "internalType": "bytes32",
943
+ "name": "slot",
944
+ "type": "bytes32"
945
+ }],
946
+ "name": "UUPSUnsupportedProxiableUUID",
947
+ "type": "error"
948
+ }, {
949
+ "anonymous": false,
950
+ "inputs": [{ "indexed": false, "internalType": "uint64", "name": "version", "type": "uint64" }],
951
+ "name": "Initialized",
952
+ "type": "event"
953
+ }, {
954
+ "anonymous": false,
955
+ "inputs": [{
956
+ "indexed": true,
957
+ "internalType": "address",
958
+ "name": "previousOwner",
959
+ "type": "address"
960
+ }, { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" }],
961
+ "name": "OwnershipTransferred",
962
+ "type": "event"
963
+ }, {
964
+ "anonymous": false,
965
+ "inputs": [{ "indexed": true, "internalType": "string", "name": "orderId", "type": "string" }, {
966
+ "indexed": true,
967
+ "internalType": "address",
968
+ "name": "payer",
969
+ "type": "address"
970
+ }, { "indexed": true, "internalType": "string", "name": "pid", "type": "string" }, {
971
+ "indexed": false,
972
+ "internalType": "string",
973
+ "name": "anymalNftId",
974
+ "type": "string"
975
+ }, { "indexed": false, "internalType": "uint256", "name": "amountInTokens", "type": "uint256" }, {
976
+ "indexed": false,
977
+ "internalType": "uint256",
978
+ "name": "timestamp",
979
+ "type": "uint256"
980
+ }],
981
+ "name": "PartialPaymentMade",
982
+ "type": "event"
983
+ }, {
984
+ "anonymous": false,
985
+ "inputs": [{ "indexed": true, "internalType": "string", "name": "orderId", "type": "string" }, {
986
+ "indexed": true,
987
+ "internalType": "address",
988
+ "name": "payer",
989
+ "type": "address"
990
+ }, { "indexed": false, "internalType": "uint256", "name": "amountInTokens", "type": "uint256" }, {
991
+ "indexed": false,
992
+ "internalType": "uint256",
993
+ "name": "timestamp",
994
+ "type": "uint256"
995
+ }],
996
+ "name": "PaymentMade",
997
+ "type": "event"
998
+ }, {
999
+ "anonymous": false,
1000
+ "inputs": [{ "indexed": true, "internalType": "string", "name": "orderId", "type": "string" }, {
1001
+ "indexed": true,
1002
+ "internalType": "address",
1003
+ "name": "payer",
1004
+ "type": "address"
1005
+ }, { "indexed": true, "internalType": "string", "name": "pid", "type": "string" }, {
1006
+ "indexed": false,
1007
+ "internalType": "uint256",
1008
+ "name": "refundedAmount",
1009
+ "type": "uint256"
1010
+ }, { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" }],
1011
+ "name": "RefundProcessed",
1012
+ "type": "event"
1013
+ }, {
1014
+ "anonymous": false,
1015
+ "inputs": [{ "indexed": false, "internalType": "bool", "name": "enabled", "type": "bool" }],
1016
+ "name": "SignatureCheckToggled",
1017
+ "type": "event"
1018
+ }, {
1019
+ "anonymous": false,
1020
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }],
1021
+ "name": "Upgraded",
1022
+ "type": "event"
1023
+ }, {
1024
+ "inputs": [],
1025
+ "name": "UPGRADE_INTERFACE_VERSION",
1026
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
1027
+ "stateMutability": "view",
1028
+ "type": "function"
1029
+ }, {
1030
+ "inputs": [],
1031
+ "name": "authorizer",
1032
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
1033
+ "stateMutability": "view",
1034
+ "type": "function"
1035
+ }, {
1036
+ "inputs": [{ "internalType": "address", "name": "_initialOwner", "type": "address" }, {
1037
+ "internalType": "address",
1038
+ "name": "_authorizer",
1039
+ "type": "address"
1040
+ }, { "internalType": "address", "name": "_kibbleToken", "type": "address" }],
1041
+ "name": "initialize",
1042
+ "outputs": [],
1043
+ "stateMutability": "nonpayable",
1044
+ "type": "function"
1045
+ }, {
1046
+ "inputs": [],
1047
+ "name": "kibbleToken",
1048
+ "outputs": [{ "internalType": "contract IERC20", "name": "", "type": "address" }],
1049
+ "stateMutability": "view",
1050
+ "type": "function"
1051
+ }, {
1052
+ "inputs": [],
1053
+ "name": "owner",
1054
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
1055
+ "stateMutability": "view",
1056
+ "type": "function"
1057
+ }, {
1058
+ "inputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }, {
1059
+ "internalType": "address",
1060
+ "name": "",
1061
+ "type": "address"
1062
+ }],
1063
+ "name": "paidAmounts",
1064
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
1065
+ "stateMutability": "view",
1066
+ "type": "function"
1067
+ }, {
1068
+ "inputs": [{ "internalType": "string", "name": "orderId", "type": "string" }, {
1069
+ "internalType": "string",
1070
+ "name": "anymalNftId",
1071
+ "type": "string"
1072
+ }, { "internalType": "string", "name": "pid", "type": "string" }, {
1073
+ "internalType": "uint256",
1074
+ "name": "amountInTokens",
1075
+ "type": "uint256"
1076
+ }, { "internalType": "uint256", "name": "maxTokenPayment", "type": "uint256" }, {
1077
+ "internalType": "bytes32",
1078
+ "name": "nonce",
1079
+ "type": "bytes32"
1080
+ }, { "internalType": "uint256", "name": "deadline", "type": "uint256" }, {
1081
+ "internalType": "bytes",
1082
+ "name": "backendSignature",
1083
+ "type": "bytes"
1084
+ }],
1085
+ "name": "partialPay",
1086
+ "outputs": [],
1087
+ "stateMutability": "nonpayable",
1088
+ "type": "function"
1089
+ }, {
1090
+ "inputs": [],
1091
+ "name": "proxiableUUID",
1092
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1093
+ "stateMutability": "view",
1094
+ "type": "function"
1095
+ }, {
1096
+ "inputs": [{ "internalType": "string", "name": "orderId", "type": "string" }, {
1097
+ "internalType": "address",
1098
+ "name": "payer",
1099
+ "type": "address"
1100
+ }, { "internalType": "string", "name": "pid", "type": "string" }],
1101
+ "name": "refund",
1102
+ "outputs": [],
1103
+ "stateMutability": "nonpayable",
1104
+ "type": "function"
1105
+ }, {
1106
+ "inputs": [],
1107
+ "name": "renounceOwnership",
1108
+ "outputs": [],
1109
+ "stateMutability": "nonpayable",
1110
+ "type": "function"
1111
+ }, {
1112
+ "inputs": [{ "internalType": "address", "name": "_authorizer", "type": "address" }],
1113
+ "name": "setAuthorizer",
1114
+ "outputs": [],
1115
+ "stateMutability": "nonpayable",
1116
+ "type": "function"
1117
+ }, {
1118
+ "inputs": [{ "internalType": "bool", "name": "enabled", "type": "bool" }],
1119
+ "name": "setSignatureCheckEnabled",
1120
+ "outputs": [],
1121
+ "stateMutability": "nonpayable",
1122
+ "type": "function"
1123
+ }, {
1124
+ "inputs": [],
1125
+ "name": "signatureCheckEnabled",
1126
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
1127
+ "stateMutability": "view",
1128
+ "type": "function"
1129
+ }, {
1130
+ "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }],
1131
+ "name": "transferOwnership",
1132
+ "outputs": [],
1133
+ "stateMutability": "nonpayable",
1134
+ "type": "function"
1135
+ }, {
1136
+ "inputs": [{
1137
+ "internalType": "address",
1138
+ "name": "newImplementation",
1139
+ "type": "address"
1140
+ }, { "internalType": "bytes", "name": "data", "type": "bytes" }],
1141
+ "name": "upgradeToAndCall",
1142
+ "outputs": [],
1143
+ "stateMutability": "payable",
1144
+ "type": "function"
1145
+ }, {
1146
+ "inputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1147
+ "name": "usedNonces",
1148
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
1149
+ "stateMutability": "view",
1150
+ "type": "function"
1151
+ }, {
1152
+ "inputs": [{ "internalType": "address", "name": "to", "type": "address" }, {
1153
+ "internalType": "uint256",
1154
+ "name": "amount",
1155
+ "type": "uint256"
1156
+ }],
1157
+ "name": "withdrawKibble",
1158
+ "outputs": [],
1159
+ "stateMutability": "nonpayable",
1160
+ "type": "function"
1161
+ }];
1162
+ var ORGANIZATION_BEACON_ABI = [{
1163
+ "inputs": [{
1164
+ "internalType": "address",
1165
+ "name": "_initialImplementation",
1166
+ "type": "address"
1167
+ }, { "internalType": "address", "name": "_initialOwner", "type": "address" }, {
1168
+ "internalType": "address",
1169
+ "name": "_anymalNFTProxy",
1170
+ "type": "address"
1171
+ }],
1172
+ "stateMutability": "nonpayable",
1173
+ "type": "constructor"
1174
+ }, {
1175
+ "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }],
1176
+ "name": "BeaconInvalidImplementation",
1177
+ "type": "error"
1178
+ }, {
1179
+ "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }],
1180
+ "name": "OwnableInvalidOwner",
1181
+ "type": "error"
1182
+ }, {
1183
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
1184
+ "name": "OwnableUnauthorizedAccount",
1185
+ "type": "error"
1186
+ }, {
1187
+ "anonymous": false,
1188
+ "inputs": [{ "indexed": false, "internalType": "string", "name": "pid", "type": "string" }, {
1189
+ "indexed": false,
1190
+ "internalType": "string",
1191
+ "name": "name",
1192
+ "type": "string"
1193
+ }, { "indexed": false, "internalType": "address", "name": "proxyAddress", "type": "address" }, {
1194
+ "indexed": false,
1195
+ "internalType": "address",
1196
+ "name": "networkAdmin",
1197
+ "type": "address"
1198
+ }, { "indexed": false, "internalType": "address", "name": "userAdmin", "type": "address" }],
1199
+ "name": "NewOrganizationCreated",
1200
+ "type": "event"
1201
+ }, {
1202
+ "anonymous": false,
1203
+ "inputs": [{
1204
+ "indexed": true,
1205
+ "internalType": "address",
1206
+ "name": "previousOwner",
1207
+ "type": "address"
1208
+ }, { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" }],
1209
+ "name": "OwnershipTransferred",
1210
+ "type": "event"
1211
+ }, {
1212
+ "anonymous": false,
1213
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }],
1214
+ "name": "Upgraded",
1215
+ "type": "event"
1216
+ }, {
1217
+ "inputs": [],
1218
+ "name": "anymalNFTProxy",
1219
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
1220
+ "stateMutability": "view",
1221
+ "type": "function"
1222
+ }, {
1223
+ "inputs": [{ "internalType": "address", "name": "_userAdmin", "type": "address" }, {
1224
+ "internalType": "string",
1225
+ "name": "_orgName",
1226
+ "type": "string"
1227
+ }, { "internalType": "string", "name": "_orgPid", "type": "string" }],
1228
+ "name": "createOrganizationProxy",
1229
+ "outputs": [{ "internalType": "address", "name": "proxyAddress", "type": "address" }],
1230
+ "stateMutability": "nonpayable",
1231
+ "type": "function"
1232
+ }, {
1233
+ "inputs": [],
1234
+ "name": "implementation",
1235
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
1236
+ "stateMutability": "view",
1237
+ "type": "function"
1238
+ }, {
1239
+ "inputs": [],
1240
+ "name": "owner",
1241
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
1242
+ "stateMutability": "view",
1243
+ "type": "function"
1244
+ }, {
1245
+ "inputs": [],
1246
+ "name": "renounceOwnership",
1247
+ "outputs": [],
1248
+ "stateMutability": "nonpayable",
1249
+ "type": "function"
1250
+ }, {
1251
+ "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }],
1252
+ "name": "transferOwnership",
1253
+ "outputs": [],
1254
+ "stateMutability": "nonpayable",
1255
+ "type": "function"
1256
+ }, {
1257
+ "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }],
1258
+ "name": "upgradeBeaconTo",
1259
+ "outputs": [],
1260
+ "stateMutability": "nonpayable",
1261
+ "type": "function"
1262
+ }, {
1263
+ "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }],
1264
+ "name": "upgradeTo",
1265
+ "outputs": [],
1266
+ "stateMutability": "nonpayable",
1267
+ "type": "function"
1268
+ }];
1269
+ var REWARDABLE_ACTIONS_ABI = [{
1270
+ "inputs": [],
1271
+ "stateMutability": "nonpayable",
1272
+ "type": "constructor"
1273
+ }, { "inputs": [], "name": "AccessControlBadConfirmation", "type": "error" }, {
1274
+ "inputs": [{
1275
+ "internalType": "address",
1276
+ "name": "account",
1277
+ "type": "address"
1278
+ }, { "internalType": "bytes32", "name": "neededRole", "type": "bytes32" }],
1279
+ "name": "AccessControlUnauthorizedAccount",
1280
+ "type": "error"
1281
+ }, {
1282
+ "inputs": [{ "internalType": "address", "name": "target", "type": "address" }],
1283
+ "name": "AddressEmptyCode",
1284
+ "type": "error"
1285
+ }, {
1286
+ "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }],
1287
+ "name": "ERC1967InvalidImplementation",
1288
+ "type": "error"
1289
+ }, { "inputs": [], "name": "ERC1967NonPayable", "type": "error" }, {
1290
+ "inputs": [],
1291
+ "name": "FailedCall",
1292
+ "type": "error"
1293
+ }, { "inputs": [], "name": "InvalidInitialization", "type": "error" }, {
1294
+ "inputs": [],
1295
+ "name": "NotInitializing",
1296
+ "type": "error"
1297
+ }, { "inputs": [], "name": "ReentrancyGuardReentrantCall", "type": "error" }, {
1298
+ "inputs": [],
1299
+ "name": "UUPSUnauthorizedCallContext",
1300
+ "type": "error"
1301
+ }, {
1302
+ "inputs": [{ "internalType": "bytes32", "name": "slot", "type": "bytes32" }],
1303
+ "name": "UUPSUnsupportedProxiableUUID",
1304
+ "type": "error"
1305
+ }, {
1306
+ "anonymous": false,
1307
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1308
+ "indexed": false,
1309
+ "internalType": "uint256",
1310
+ "name": "rewardAmount",
1311
+ "type": "uint256"
1312
+ }, { "indexed": false, "internalType": "uint256", "name": "maxClaims", "type": "uint256" }],
1313
+ "name": "ActionTypeAdded",
1314
+ "type": "event"
1315
+ }, {
1316
+ "anonymous": false,
1317
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1318
+ "indexed": false,
1319
+ "internalType": "uint256",
1320
+ "name": "newRewardAmount",
1321
+ "type": "uint256"
1322
+ }, { "indexed": false, "internalType": "uint256", "name": "newMaxClaims", "type": "uint256" }],
1323
+ "name": "ActionTypeUpdated",
1324
+ "type": "event"
1325
+ }, {
1326
+ "anonymous": false,
1327
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1328
+ "indexed": true,
1329
+ "internalType": "address",
1330
+ "name": "user",
1331
+ "type": "address"
1332
+ }, { "indexed": true, "internalType": "uint256", "name": "index", "type": "uint256" }, {
1333
+ "indexed": false,
1334
+ "internalType": "uint256",
1335
+ "name": "quantity",
1336
+ "type": "uint256"
1337
+ }, { "indexed": false, "internalType": "uint16", "name": "multiplier", "type": "uint16" }],
1338
+ "name": "ActionValidated",
1339
+ "type": "event"
1340
+ }, {
1341
+ "anonymous": false,
1342
+ "inputs": [{ "indexed": false, "internalType": "uint64", "name": "version", "type": "uint64" }],
1343
+ "name": "Initialized",
1344
+ "type": "event"
1345
+ }, {
1346
+ "anonymous": false,
1347
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1348
+ "indexed": true,
1349
+ "internalType": "address",
1350
+ "name": "user",
1351
+ "type": "address"
1352
+ }, { "indexed": true, "internalType": "uint256", "name": "index", "type": "uint256" }, {
1353
+ "indexed": false,
1354
+ "internalType": "uint256",
1355
+ "name": "amount",
1356
+ "type": "uint256"
1357
+ }],
1358
+ "name": "RewardClaimedByIndex",
1359
+ "type": "event"
1360
+ }, {
1361
+ "anonymous": false,
1362
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1363
+ "indexed": true,
1364
+ "internalType": "bytes32",
1365
+ "name": "previousAdminRole",
1366
+ "type": "bytes32"
1367
+ }, { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" }],
1368
+ "name": "RoleAdminChanged",
1369
+ "type": "event"
1370
+ }, {
1371
+ "anonymous": false,
1372
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1373
+ "indexed": true,
1374
+ "internalType": "address",
1375
+ "name": "account",
1376
+ "type": "address"
1377
+ }, { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }],
1378
+ "name": "RoleGranted",
1379
+ "type": "event"
1380
+ }, {
1381
+ "anonymous": false,
1382
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1383
+ "indexed": true,
1384
+ "internalType": "address",
1385
+ "name": "account",
1386
+ "type": "address"
1387
+ }, { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }],
1388
+ "name": "RoleRevoked",
1389
+ "type": "event"
1390
+ }, {
1391
+ "anonymous": false,
1392
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }],
1393
+ "name": "Upgraded",
1394
+ "type": "event"
1395
+ }, {
1396
+ "inputs": [],
1397
+ "name": "ADMIN_ROLE",
1398
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1399
+ "stateMutability": "view",
1400
+ "type": "function"
1401
+ }, {
1402
+ "inputs": [],
1403
+ "name": "APPROVER_ROLE",
1404
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1405
+ "stateMutability": "view",
1406
+ "type": "function"
1407
+ }, {
1408
+ "inputs": [],
1409
+ "name": "DEFAULT_ADMIN_ROLE",
1410
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1411
+ "stateMutability": "view",
1412
+ "type": "function"
1413
+ }, {
1414
+ "inputs": [],
1415
+ "name": "UPGRADE_INTERFACE_VERSION",
1416
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
1417
+ "stateMutability": "view",
1418
+ "type": "function"
1419
+ }, {
1420
+ "inputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1421
+ "name": "actionConfigs",
1422
+ "outputs": [{ "internalType": "uint256", "name": "rewardAmount", "type": "uint256" }, {
1423
+ "internalType": "uint256",
1424
+ "name": "maxClaims",
1425
+ "type": "uint256"
1426
+ }, { "internalType": "bool", "name": "exists", "type": "bool" }],
1427
+ "stateMutability": "view",
1428
+ "type": "function"
1429
+ }, {
1430
+ "inputs": [{ "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1431
+ "internalType": "uint256",
1432
+ "name": "rewardAmount",
1433
+ "type": "uint256"
1434
+ }, { "internalType": "uint256", "name": "maxClaims", "type": "uint256" }],
1435
+ "name": "addActionType",
1436
+ "outputs": [],
1437
+ "stateMutability": "nonpayable",
1438
+ "type": "function"
1439
+ }, {
1440
+ "inputs": [{ "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1441
+ "internalType": "uint256",
1442
+ "name": "index",
1443
+ "type": "uint256"
1444
+ }],
1445
+ "name": "claimByIndex",
1446
+ "outputs": [],
1447
+ "stateMutability": "nonpayable",
1448
+ "type": "function"
1449
+ }, {
1450
+ "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }],
1451
+ "name": "depositRewards",
1452
+ "outputs": [],
1453
+ "stateMutability": "nonpayable",
1454
+ "type": "function"
1455
+ }, {
1456
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }],
1457
+ "name": "getRoleAdmin",
1458
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1459
+ "stateMutability": "view",
1460
+ "type": "function"
1461
+ }, {
1462
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1463
+ "internalType": "address",
1464
+ "name": "account",
1465
+ "type": "address"
1466
+ }],
1467
+ "name": "grantRole",
1468
+ "outputs": [],
1469
+ "stateMutability": "nonpayable",
1470
+ "type": "function"
1471
+ }, {
1472
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1473
+ "internalType": "address",
1474
+ "name": "account",
1475
+ "type": "address"
1476
+ }],
1477
+ "name": "hasRole",
1478
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
1479
+ "stateMutability": "view",
1480
+ "type": "function"
1481
+ }, {
1482
+ "inputs": [{
1483
+ "internalType": "address",
1484
+ "name": "initialOwner",
1485
+ "type": "address"
1486
+ }, { "internalType": "contract IERC20", "name": "_rewardToken", "type": "address" }],
1487
+ "name": "initialize",
1488
+ "outputs": [],
1489
+ "stateMutability": "nonpayable",
1490
+ "type": "function"
1491
+ }, {
1492
+ "inputs": [],
1493
+ "name": "proxiableUUID",
1494
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1495
+ "stateMutability": "view",
1496
+ "type": "function"
1497
+ }, {
1498
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1499
+ "internalType": "address",
1500
+ "name": "callerConfirmation",
1501
+ "type": "address"
1502
+ }],
1503
+ "name": "renounceRole",
1504
+ "outputs": [],
1505
+ "stateMutability": "nonpayable",
1506
+ "type": "function"
1507
+ }, {
1508
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1509
+ "internalType": "address",
1510
+ "name": "account",
1511
+ "type": "address"
1512
+ }],
1513
+ "name": "revokeRole",
1514
+ "outputs": [],
1515
+ "stateMutability": "nonpayable",
1516
+ "type": "function"
1517
+ }, {
1518
+ "inputs": [],
1519
+ "name": "rewardToken",
1520
+ "outputs": [{ "internalType": "contract IERC20", "name": "", "type": "address" }],
1521
+ "stateMutability": "view",
1522
+ "type": "function"
1523
+ }, {
1524
+ "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }],
1525
+ "name": "supportsInterface",
1526
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
1527
+ "stateMutability": "view",
1528
+ "type": "function"
1529
+ }, {
1530
+ "inputs": [{ "internalType": "address", "name": "user", "type": "address" }, {
1531
+ "internalType": "bytes32",
1532
+ "name": "actionId",
1533
+ "type": "bytes32"
1534
+ }],
1535
+ "name": "totalValidatedSlots",
1536
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
1537
+ "stateMutability": "view",
1538
+ "type": "function"
1539
+ }, {
1540
+ "inputs": [{ "internalType": "address", "name": "user", "type": "address" }, {
1541
+ "internalType": "bytes32",
1542
+ "name": "actionId",
1543
+ "type": "bytes32"
1544
+ }],
1545
+ "name": "unclaimedSlots",
1546
+ "outputs": [{ "internalType": "uint256", "name": "count", "type": "uint256" }],
1547
+ "stateMutability": "view",
1548
+ "type": "function"
1549
+ }, {
1550
+ "inputs": [{ "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1551
+ "internalType": "uint256",
1552
+ "name": "newRewardAmount",
1553
+ "type": "uint256"
1554
+ }, { "internalType": "uint256", "name": "newMaxClaims", "type": "uint256" }],
1555
+ "name": "updateActionType",
1556
+ "outputs": [],
1557
+ "stateMutability": "nonpayable",
1558
+ "type": "function"
1559
+ }, {
1560
+ "inputs": [{
1561
+ "internalType": "address",
1562
+ "name": "newImplementation",
1563
+ "type": "address"
1564
+ }, { "internalType": "bytes", "name": "data", "type": "bytes" }],
1565
+ "name": "upgradeToAndCall",
1566
+ "outputs": [],
1567
+ "stateMutability": "payable",
1568
+ "type": "function"
1569
+ }, {
1570
+ "inputs": [{ "internalType": "address", "name": "user", "type": "address" }, {
1571
+ "internalType": "bytes32",
1572
+ "name": "actionId",
1573
+ "type": "bytes32"
1574
+ }, { "internalType": "uint256", "name": "quantity", "type": "uint256" }, {
1575
+ "internalType": "uint16",
1576
+ "name": "multiplier",
1577
+ "type": "uint16"
1578
+ }],
1579
+ "name": "validateAction",
1580
+ "outputs": [],
1581
+ "stateMutability": "nonpayable",
1582
+ "type": "function"
1583
+ }, {
1584
+ "inputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }, {
1585
+ "internalType": "address",
1586
+ "name": "",
1587
+ "type": "address"
1588
+ }, { "internalType": "uint256", "name": "", "type": "uint256" }],
1589
+ "name": "validations",
1590
+ "outputs": [{ "internalType": "uint256", "name": "quantity", "type": "uint256" }, {
1591
+ "internalType": "uint16",
1592
+ "name": "multiplier",
1593
+ "type": "uint16"
1594
+ }, { "internalType": "bool", "name": "claimed", "type": "bool" }],
1595
+ "stateMutability": "view",
1596
+ "type": "function"
1597
+ }, {
1598
+ "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }],
1599
+ "name": "withdrawRewards",
1600
+ "outputs": [],
1601
+ "stateMutability": "nonpayable",
1602
+ "type": "function"
1603
+ }];
470
1604
  var ORGANIZATION_IMPL_ABI = [
471
1605
  {
472
1606
  "inputs": [],
@@ -1277,7 +2411,506 @@ var ORGANIZATION_IMPL_ABI = [
1277
2411
  "type": "function"
1278
2412
  }
1279
2413
  ];
1280
- var KIBBLE_TOKEN_ABI = [{ "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, { "inputs": [{ "internalType": "address", "name": "target", "type": "address" }], "name": "AddressEmptyCode", "type": "error" }, { "inputs": [], "name": "CheckpointUnorderedInsertion", "type": "error" }, { "inputs": [], "name": "ECDSAInvalidSignature", "type": "error" }, { "inputs": [{ "internalType": "uint256", "name": "length", "type": "uint256" }], "name": "ECDSAInvalidSignatureLength", "type": "error" }, { "inputs": [{ "internalType": "bytes32", "name": "s", "type": "bytes32" }], "name": "ECDSAInvalidSignatureS", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }], "name": "ERC1967InvalidImplementation", "type": "error" }, { "inputs": [], "name": "ERC1967NonPayable", "type": "error" }, { "inputs": [{ "internalType": "uint256", "name": "increasedSupply", "type": "uint256" }, { "internalType": "uint256", "name": "cap", "type": "uint256" }], "name": "ERC20ExceededSafeSupply", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "spender", "type": "address" }, { "internalType": "uint256", "name": "allowance", "type": "uint256" }, { "internalType": "uint256", "name": "needed", "type": "uint256" }], "name": "ERC20InsufficientAllowance", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "sender", "type": "address" }, { "internalType": "uint256", "name": "balance", "type": "uint256" }, { "internalType": "uint256", "name": "needed", "type": "uint256" }], "name": "ERC20InsufficientBalance", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "approver", "type": "address" }], "name": "ERC20InvalidApprover", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "receiver", "type": "address" }], "name": "ERC20InvalidReceiver", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "sender", "type": "address" }], "name": "ERC20InvalidSender", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "spender", "type": "address" }], "name": "ERC20InvalidSpender", "type": "error" }, { "inputs": [{ "internalType": "uint256", "name": "deadline", "type": "uint256" }], "name": "ERC2612ExpiredSignature", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "signer", "type": "address" }, { "internalType": "address", "name": "owner", "type": "address" }], "name": "ERC2612InvalidSigner", "type": "error" }, { "inputs": [{ "internalType": "uint256", "name": "timepoint", "type": "uint256" }, { "internalType": "uint48", "name": "clock", "type": "uint48" }], "name": "ERC5805FutureLookup", "type": "error" }, { "inputs": [], "name": "ERC6372InconsistentClock", "type": "error" }, { "inputs": [], "name": "EnforcedPause", "type": "error" }, { "inputs": [], "name": "ExpectedPause", "type": "error" }, { "inputs": [], "name": "FailedCall", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, { "internalType": "uint256", "name": "currentNonce", "type": "uint256" }], "name": "InvalidAccountNonce", "type": "error" }, { "inputs": [], "name": "InvalidInitialization", "type": "error" }, { "inputs": [], "name": "NotInitializing", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], "name": "OwnableInvalidOwner", "type": "error" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], "name": "OwnableUnauthorizedAccount", "type": "error" }, { "inputs": [{ "internalType": "uint8", "name": "bits", "type": "uint8" }, { "internalType": "uint256", "name": "value", "type": "uint256" }], "name": "SafeCastOverflowedUintDowncast", "type": "error" }, { "inputs": [], "name": "UUPSUnauthorizedCallContext", "type": "error" }, { "inputs": [{ "internalType": "bytes32", "name": "slot", "type": "bytes32" }], "name": "UUPSUnsupportedProxiableUUID", "type": "error" }, { "inputs": [{ "internalType": "uint256", "name": "expiry", "type": "uint256" }], "name": "VotesExpiredSignature", "type": "error" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, { "indexed": true, "internalType": "address", "name": "spender", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }], "name": "Approval", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, { "indexed": true, "internalType": "address", "name": "fromDelegate", "type": "address" }, { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" }], "name": "DelegateChanged", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "previousVotes", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "newVotes", "type": "uint256" }], "name": "DelegateVotesChanged", "type": "event" }, { "anonymous": false, "inputs": [], "name": "EIP712DomainChanged", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": false, "internalType": "uint64", "name": "version", "type": "uint64" }], "name": "Initialized", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" }], "name": "OwnershipTransferred", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], "name": "Paused", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "from", "type": "address" }, { "indexed": true, "internalType": "address", "name": "to", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }], "name": "Transfer", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }], "name": "Unpaused", "type": "event" }, { "anonymous": false, "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }], "name": "Upgraded", "type": "event" }, { "inputs": [], "name": "CLOCK_MODE", "outputs": [{ "internalType": "string", "name": "", "type": "string" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "DOMAIN_SEPARATOR", "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "UPGRADE_INTERFACE_VERSION", "outputs": [{ "internalType": "string", "name": "", "type": "string" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }, { "internalType": "address", "name": "spender", "type": "address" }], "name": "allowance", "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "spender", "type": "address" }, { "internalType": "uint256", "name": "value", "type": "uint256" }], "name": "approve", "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], "name": "balanceOf", "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "uint256", "name": "value", "type": "uint256" }], "name": "burn", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, { "internalType": "uint256", "name": "value", "type": "uint256" }], "name": "burnFrom", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, { "internalType": "uint32", "name": "pos", "type": "uint32" }], "name": "checkpoints", "outputs": [{ "components": [{ "internalType": "uint48", "name": "_key", "type": "uint48" }, { "internalType": "uint208", "name": "_value", "type": "uint208" }], "internalType": "struct Checkpoints.Checkpoint208", "name": "", "type": "tuple" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "clock", "outputs": [{ "internalType": "uint48", "name": "", "type": "uint48" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "decimals", "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }], "name": "delegate", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }, { "internalType": "uint256", "name": "nonce", "type": "uint256" }, { "internalType": "uint256", "name": "expiry", "type": "uint256" }, { "internalType": "uint8", "name": "v", "type": "uint8" }, { "internalType": "bytes32", "name": "r", "type": "bytes32" }, { "internalType": "bytes32", "name": "s", "type": "bytes32" }], "name": "delegateBySig", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], "name": "delegates", "outputs": [{ "internalType": "address", "name": "", "type": "address" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "eip712Domain", "outputs": [{ "internalType": "bytes1", "name": "fields", "type": "bytes1" }, { "internalType": "string", "name": "name", "type": "string" }, { "internalType": "string", "name": "version", "type": "string" }, { "internalType": "uint256", "name": "chainId", "type": "uint256" }, { "internalType": "address", "name": "verifyingContract", "type": "address" }, { "internalType": "bytes32", "name": "salt", "type": "bytes32" }, { "internalType": "uint256[]", "name": "extensions", "type": "uint256[]" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "uint256", "name": "timepoint", "type": "uint256" }], "name": "getPastTotalSupply", "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, { "internalType": "uint256", "name": "timepoint", "type": "uint256" }], "name": "getPastVotes", "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], "name": "getVotes", "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }], "name": "initialize", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "to", "type": "address" }, { "internalType": "uint256", "name": "amount", "type": "uint256" }], "name": "mint", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "name", "outputs": [{ "internalType": "string", "name": "", "type": "string" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }], "name": "nonces", "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "account", "type": "address" }], "name": "numCheckpoints", "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "owner", "outputs": [{ "internalType": "address", "name": "", "type": "address" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "paused", "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }, { "internalType": "address", "name": "spender", "type": "address" }, { "internalType": "uint256", "name": "value", "type": "uint256" }, { "internalType": "uint256", "name": "deadline", "type": "uint256" }, { "internalType": "uint8", "name": "v", "type": "uint8" }, { "internalType": "bytes32", "name": "r", "type": "bytes32" }, { "internalType": "bytes32", "name": "s", "type": "bytes32" }], "name": "permit", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "proxiableUUID", "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "symbol", "outputs": [{ "internalType": "string", "name": "", "type": "string" }], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "totalSupply", "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], "stateMutability": "view", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "to", "type": "address" }, { "internalType": "uint256", "name": "value", "type": "uint256" }], "name": "transfer", "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "from", "type": "address" }, { "internalType": "address", "name": "to", "type": "address" }, { "internalType": "uint256", "name": "value", "type": "uint256" }], "name": "transferFrom", "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }], "name": "transferOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }, { "internalType": "bytes", "name": "data", "type": "bytes" }], "name": "upgradeToAndCall", "outputs": [], "stateMutability": "payable", "type": "function" }];
2414
+ var KIBBLE_TOKEN_ABI = [{
2415
+ "inputs": [],
2416
+ "stateMutability": "nonpayable",
2417
+ "type": "constructor"
2418
+ }, {
2419
+ "inputs": [{ "internalType": "address", "name": "target", "type": "address" }],
2420
+ "name": "AddressEmptyCode",
2421
+ "type": "error"
2422
+ }, { "inputs": [], "name": "CheckpointUnorderedInsertion", "type": "error" }, {
2423
+ "inputs": [],
2424
+ "name": "ECDSAInvalidSignature",
2425
+ "type": "error"
2426
+ }, {
2427
+ "inputs": [{ "internalType": "uint256", "name": "length", "type": "uint256" }],
2428
+ "name": "ECDSAInvalidSignatureLength",
2429
+ "type": "error"
2430
+ }, {
2431
+ "inputs": [{ "internalType": "bytes32", "name": "s", "type": "bytes32" }],
2432
+ "name": "ECDSAInvalidSignatureS",
2433
+ "type": "error"
2434
+ }, {
2435
+ "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }],
2436
+ "name": "ERC1967InvalidImplementation",
2437
+ "type": "error"
2438
+ }, { "inputs": [], "name": "ERC1967NonPayable", "type": "error" }, {
2439
+ "inputs": [{
2440
+ "internalType": "uint256",
2441
+ "name": "increasedSupply",
2442
+ "type": "uint256"
2443
+ }, { "internalType": "uint256", "name": "cap", "type": "uint256" }],
2444
+ "name": "ERC20ExceededSafeSupply",
2445
+ "type": "error"
2446
+ }, {
2447
+ "inputs": [{ "internalType": "address", "name": "spender", "type": "address" }, {
2448
+ "internalType": "uint256",
2449
+ "name": "allowance",
2450
+ "type": "uint256"
2451
+ }, { "internalType": "uint256", "name": "needed", "type": "uint256" }],
2452
+ "name": "ERC20InsufficientAllowance",
2453
+ "type": "error"
2454
+ }, {
2455
+ "inputs": [{ "internalType": "address", "name": "sender", "type": "address" }, {
2456
+ "internalType": "uint256",
2457
+ "name": "balance",
2458
+ "type": "uint256"
2459
+ }, { "internalType": "uint256", "name": "needed", "type": "uint256" }],
2460
+ "name": "ERC20InsufficientBalance",
2461
+ "type": "error"
2462
+ }, {
2463
+ "inputs": [{ "internalType": "address", "name": "approver", "type": "address" }],
2464
+ "name": "ERC20InvalidApprover",
2465
+ "type": "error"
2466
+ }, {
2467
+ "inputs": [{ "internalType": "address", "name": "receiver", "type": "address" }],
2468
+ "name": "ERC20InvalidReceiver",
2469
+ "type": "error"
2470
+ }, {
2471
+ "inputs": [{ "internalType": "address", "name": "sender", "type": "address" }],
2472
+ "name": "ERC20InvalidSender",
2473
+ "type": "error"
2474
+ }, {
2475
+ "inputs": [{ "internalType": "address", "name": "spender", "type": "address" }],
2476
+ "name": "ERC20InvalidSpender",
2477
+ "type": "error"
2478
+ }, {
2479
+ "inputs": [{ "internalType": "uint256", "name": "deadline", "type": "uint256" }],
2480
+ "name": "ERC2612ExpiredSignature",
2481
+ "type": "error"
2482
+ }, {
2483
+ "inputs": [{ "internalType": "address", "name": "signer", "type": "address" }, {
2484
+ "internalType": "address",
2485
+ "name": "owner",
2486
+ "type": "address"
2487
+ }],
2488
+ "name": "ERC2612InvalidSigner",
2489
+ "type": "error"
2490
+ }, {
2491
+ "inputs": [{ "internalType": "uint256", "name": "timepoint", "type": "uint256" }, {
2492
+ "internalType": "uint48",
2493
+ "name": "clock",
2494
+ "type": "uint48"
2495
+ }],
2496
+ "name": "ERC5805FutureLookup",
2497
+ "type": "error"
2498
+ }, { "inputs": [], "name": "ERC6372InconsistentClock", "type": "error" }, {
2499
+ "inputs": [],
2500
+ "name": "EnforcedPause",
2501
+ "type": "error"
2502
+ }, { "inputs": [], "name": "ExpectedPause", "type": "error" }, {
2503
+ "inputs": [],
2504
+ "name": "FailedCall",
2505
+ "type": "error"
2506
+ }, {
2507
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, {
2508
+ "internalType": "uint256",
2509
+ "name": "currentNonce",
2510
+ "type": "uint256"
2511
+ }],
2512
+ "name": "InvalidAccountNonce",
2513
+ "type": "error"
2514
+ }, { "inputs": [], "name": "InvalidInitialization", "type": "error" }, {
2515
+ "inputs": [],
2516
+ "name": "NotInitializing",
2517
+ "type": "error"
2518
+ }, {
2519
+ "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }],
2520
+ "name": "OwnableInvalidOwner",
2521
+ "type": "error"
2522
+ }, {
2523
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
2524
+ "name": "OwnableUnauthorizedAccount",
2525
+ "type": "error"
2526
+ }, {
2527
+ "inputs": [{ "internalType": "uint8", "name": "bits", "type": "uint8" }, {
2528
+ "internalType": "uint256",
2529
+ "name": "value",
2530
+ "type": "uint256"
2531
+ }],
2532
+ "name": "SafeCastOverflowedUintDowncast",
2533
+ "type": "error"
2534
+ }, { "inputs": [], "name": "UUPSUnauthorizedCallContext", "type": "error" }, {
2535
+ "inputs": [{
2536
+ "internalType": "bytes32",
2537
+ "name": "slot",
2538
+ "type": "bytes32"
2539
+ }],
2540
+ "name": "UUPSUnsupportedProxiableUUID",
2541
+ "type": "error"
2542
+ }, {
2543
+ "inputs": [{ "internalType": "uint256", "name": "expiry", "type": "uint256" }],
2544
+ "name": "VotesExpiredSignature",
2545
+ "type": "error"
2546
+ }, {
2547
+ "anonymous": false,
2548
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, {
2549
+ "indexed": true,
2550
+ "internalType": "address",
2551
+ "name": "spender",
2552
+ "type": "address"
2553
+ }, { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }],
2554
+ "name": "Approval",
2555
+ "type": "event"
2556
+ }, {
2557
+ "anonymous": false,
2558
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, {
2559
+ "indexed": true,
2560
+ "internalType": "address",
2561
+ "name": "fromDelegate",
2562
+ "type": "address"
2563
+ }, { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" }],
2564
+ "name": "DelegateChanged",
2565
+ "type": "event"
2566
+ }, {
2567
+ "anonymous": false,
2568
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, {
2569
+ "indexed": false,
2570
+ "internalType": "uint256",
2571
+ "name": "previousVotes",
2572
+ "type": "uint256"
2573
+ }, { "indexed": false, "internalType": "uint256", "name": "newVotes", "type": "uint256" }],
2574
+ "name": "DelegateVotesChanged",
2575
+ "type": "event"
2576
+ }, { "anonymous": false, "inputs": [], "name": "EIP712DomainChanged", "type": "event" }, {
2577
+ "anonymous": false,
2578
+ "inputs": [{ "indexed": false, "internalType": "uint64", "name": "version", "type": "uint64" }],
2579
+ "name": "Initialized",
2580
+ "type": "event"
2581
+ }, {
2582
+ "anonymous": false,
2583
+ "inputs": [{
2584
+ "indexed": true,
2585
+ "internalType": "address",
2586
+ "name": "previousOwner",
2587
+ "type": "address"
2588
+ }, { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" }],
2589
+ "name": "OwnershipTransferred",
2590
+ "type": "event"
2591
+ }, {
2592
+ "anonymous": false,
2593
+ "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }],
2594
+ "name": "Paused",
2595
+ "type": "event"
2596
+ }, {
2597
+ "anonymous": false,
2598
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "from", "type": "address" }, {
2599
+ "indexed": true,
2600
+ "internalType": "address",
2601
+ "name": "to",
2602
+ "type": "address"
2603
+ }, { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }],
2604
+ "name": "Transfer",
2605
+ "type": "event"
2606
+ }, {
2607
+ "anonymous": false,
2608
+ "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }],
2609
+ "name": "Unpaused",
2610
+ "type": "event"
2611
+ }, {
2612
+ "anonymous": false,
2613
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }],
2614
+ "name": "Upgraded",
2615
+ "type": "event"
2616
+ }, {
2617
+ "inputs": [],
2618
+ "name": "CLOCK_MODE",
2619
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
2620
+ "stateMutability": "view",
2621
+ "type": "function"
2622
+ }, {
2623
+ "inputs": [],
2624
+ "name": "DOMAIN_SEPARATOR",
2625
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
2626
+ "stateMutability": "view",
2627
+ "type": "function"
2628
+ }, {
2629
+ "inputs": [],
2630
+ "name": "UPGRADE_INTERFACE_VERSION",
2631
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
2632
+ "stateMutability": "view",
2633
+ "type": "function"
2634
+ }, {
2635
+ "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }, {
2636
+ "internalType": "address",
2637
+ "name": "spender",
2638
+ "type": "address"
2639
+ }],
2640
+ "name": "allowance",
2641
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2642
+ "stateMutability": "view",
2643
+ "type": "function"
2644
+ }, {
2645
+ "inputs": [{ "internalType": "address", "name": "spender", "type": "address" }, {
2646
+ "internalType": "uint256",
2647
+ "name": "value",
2648
+ "type": "uint256"
2649
+ }],
2650
+ "name": "approve",
2651
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
2652
+ "stateMutability": "nonpayable",
2653
+ "type": "function"
2654
+ }, {
2655
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
2656
+ "name": "balanceOf",
2657
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2658
+ "stateMutability": "view",
2659
+ "type": "function"
2660
+ }, {
2661
+ "inputs": [{ "internalType": "uint256", "name": "value", "type": "uint256" }],
2662
+ "name": "burn",
2663
+ "outputs": [],
2664
+ "stateMutability": "nonpayable",
2665
+ "type": "function"
2666
+ }, {
2667
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, {
2668
+ "internalType": "uint256",
2669
+ "name": "value",
2670
+ "type": "uint256"
2671
+ }],
2672
+ "name": "burnFrom",
2673
+ "outputs": [],
2674
+ "stateMutability": "nonpayable",
2675
+ "type": "function"
2676
+ }, {
2677
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, {
2678
+ "internalType": "uint32",
2679
+ "name": "pos",
2680
+ "type": "uint32"
2681
+ }],
2682
+ "name": "checkpoints",
2683
+ "outputs": [{
2684
+ "components": [{
2685
+ "internalType": "uint48",
2686
+ "name": "_key",
2687
+ "type": "uint48"
2688
+ }, { "internalType": "uint208", "name": "_value", "type": "uint208" }],
2689
+ "internalType": "struct Checkpoints.Checkpoint208",
2690
+ "name": "",
2691
+ "type": "tuple"
2692
+ }],
2693
+ "stateMutability": "view",
2694
+ "type": "function"
2695
+ }, {
2696
+ "inputs": [],
2697
+ "name": "clock",
2698
+ "outputs": [{ "internalType": "uint48", "name": "", "type": "uint48" }],
2699
+ "stateMutability": "view",
2700
+ "type": "function"
2701
+ }, {
2702
+ "inputs": [],
2703
+ "name": "decimals",
2704
+ "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }],
2705
+ "stateMutability": "view",
2706
+ "type": "function"
2707
+ }, {
2708
+ "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }],
2709
+ "name": "delegate",
2710
+ "outputs": [],
2711
+ "stateMutability": "nonpayable",
2712
+ "type": "function"
2713
+ }, {
2714
+ "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }, {
2715
+ "internalType": "uint256",
2716
+ "name": "nonce",
2717
+ "type": "uint256"
2718
+ }, { "internalType": "uint256", "name": "expiry", "type": "uint256" }, {
2719
+ "internalType": "uint8",
2720
+ "name": "v",
2721
+ "type": "uint8"
2722
+ }, { "internalType": "bytes32", "name": "r", "type": "bytes32" }, {
2723
+ "internalType": "bytes32",
2724
+ "name": "s",
2725
+ "type": "bytes32"
2726
+ }],
2727
+ "name": "delegateBySig",
2728
+ "outputs": [],
2729
+ "stateMutability": "nonpayable",
2730
+ "type": "function"
2731
+ }, {
2732
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
2733
+ "name": "delegates",
2734
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
2735
+ "stateMutability": "view",
2736
+ "type": "function"
2737
+ }, {
2738
+ "inputs": [],
2739
+ "name": "eip712Domain",
2740
+ "outputs": [{ "internalType": "bytes1", "name": "fields", "type": "bytes1" }, {
2741
+ "internalType": "string",
2742
+ "name": "name",
2743
+ "type": "string"
2744
+ }, { "internalType": "string", "name": "version", "type": "string" }, {
2745
+ "internalType": "uint256",
2746
+ "name": "chainId",
2747
+ "type": "uint256"
2748
+ }, { "internalType": "address", "name": "verifyingContract", "type": "address" }, {
2749
+ "internalType": "bytes32",
2750
+ "name": "salt",
2751
+ "type": "bytes32"
2752
+ }, { "internalType": "uint256[]", "name": "extensions", "type": "uint256[]" }],
2753
+ "stateMutability": "view",
2754
+ "type": "function"
2755
+ }, {
2756
+ "inputs": [{ "internalType": "uint256", "name": "timepoint", "type": "uint256" }],
2757
+ "name": "getPastTotalSupply",
2758
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2759
+ "stateMutability": "view",
2760
+ "type": "function"
2761
+ }, {
2762
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, {
2763
+ "internalType": "uint256",
2764
+ "name": "timepoint",
2765
+ "type": "uint256"
2766
+ }],
2767
+ "name": "getPastVotes",
2768
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2769
+ "stateMutability": "view",
2770
+ "type": "function"
2771
+ }, {
2772
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
2773
+ "name": "getVotes",
2774
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2775
+ "stateMutability": "view",
2776
+ "type": "function"
2777
+ }, {
2778
+ "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }],
2779
+ "name": "initialize",
2780
+ "outputs": [],
2781
+ "stateMutability": "nonpayable",
2782
+ "type": "function"
2783
+ }, {
2784
+ "inputs": [{ "internalType": "address", "name": "to", "type": "address" }, {
2785
+ "internalType": "uint256",
2786
+ "name": "amount",
2787
+ "type": "uint256"
2788
+ }],
2789
+ "name": "mint",
2790
+ "outputs": [],
2791
+ "stateMutability": "nonpayable",
2792
+ "type": "function"
2793
+ }, {
2794
+ "inputs": [],
2795
+ "name": "name",
2796
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
2797
+ "stateMutability": "view",
2798
+ "type": "function"
2799
+ }, {
2800
+ "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }],
2801
+ "name": "nonces",
2802
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2803
+ "stateMutability": "view",
2804
+ "type": "function"
2805
+ }, {
2806
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
2807
+ "name": "numCheckpoints",
2808
+ "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }],
2809
+ "stateMutability": "view",
2810
+ "type": "function"
2811
+ }, {
2812
+ "inputs": [],
2813
+ "name": "owner",
2814
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
2815
+ "stateMutability": "view",
2816
+ "type": "function"
2817
+ }, {
2818
+ "inputs": [],
2819
+ "name": "pause",
2820
+ "outputs": [],
2821
+ "stateMutability": "nonpayable",
2822
+ "type": "function"
2823
+ }, {
2824
+ "inputs": [],
2825
+ "name": "paused",
2826
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
2827
+ "stateMutability": "view",
2828
+ "type": "function"
2829
+ }, {
2830
+ "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }, {
2831
+ "internalType": "address",
2832
+ "name": "spender",
2833
+ "type": "address"
2834
+ }, { "internalType": "uint256", "name": "value", "type": "uint256" }, {
2835
+ "internalType": "uint256",
2836
+ "name": "deadline",
2837
+ "type": "uint256"
2838
+ }, { "internalType": "uint8", "name": "v", "type": "uint8" }, {
2839
+ "internalType": "bytes32",
2840
+ "name": "r",
2841
+ "type": "bytes32"
2842
+ }, { "internalType": "bytes32", "name": "s", "type": "bytes32" }],
2843
+ "name": "permit",
2844
+ "outputs": [],
2845
+ "stateMutability": "nonpayable",
2846
+ "type": "function"
2847
+ }, {
2848
+ "inputs": [],
2849
+ "name": "proxiableUUID",
2850
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
2851
+ "stateMutability": "view",
2852
+ "type": "function"
2853
+ }, {
2854
+ "inputs": [],
2855
+ "name": "renounceOwnership",
2856
+ "outputs": [],
2857
+ "stateMutability": "nonpayable",
2858
+ "type": "function"
2859
+ }, {
2860
+ "inputs": [],
2861
+ "name": "symbol",
2862
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
2863
+ "stateMutability": "view",
2864
+ "type": "function"
2865
+ }, {
2866
+ "inputs": [],
2867
+ "name": "totalSupply",
2868
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2869
+ "stateMutability": "view",
2870
+ "type": "function"
2871
+ }, {
2872
+ "inputs": [{ "internalType": "address", "name": "to", "type": "address" }, {
2873
+ "internalType": "uint256",
2874
+ "name": "value",
2875
+ "type": "uint256"
2876
+ }],
2877
+ "name": "transfer",
2878
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
2879
+ "stateMutability": "nonpayable",
2880
+ "type": "function"
2881
+ }, {
2882
+ "inputs": [{ "internalType": "address", "name": "from", "type": "address" }, {
2883
+ "internalType": "address",
2884
+ "name": "to",
2885
+ "type": "address"
2886
+ }, { "internalType": "uint256", "name": "value", "type": "uint256" }],
2887
+ "name": "transferFrom",
2888
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
2889
+ "stateMutability": "nonpayable",
2890
+ "type": "function"
2891
+ }, {
2892
+ "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }],
2893
+ "name": "transferOwnership",
2894
+ "outputs": [],
2895
+ "stateMutability": "nonpayable",
2896
+ "type": "function"
2897
+ }, {
2898
+ "inputs": [],
2899
+ "name": "unpause",
2900
+ "outputs": [],
2901
+ "stateMutability": "nonpayable",
2902
+ "type": "function"
2903
+ }, {
2904
+ "inputs": [{
2905
+ "internalType": "address",
2906
+ "name": "newImplementation",
2907
+ "type": "address"
2908
+ }, { "internalType": "bytes", "name": "data", "type": "bytes" }],
2909
+ "name": "upgradeToAndCall",
2910
+ "outputs": [],
2911
+ "stateMutability": "payable",
2912
+ "type": "function"
2913
+ }];
1281
2914
  var LOCAL_ERRORS = [
1282
2915
  ...KIBBLE_TOKEN_ABI.filter((item) => item.type === "error"),
1283
2916
  ...ORGANIZATION_IMPL_ABI.filter((item) => item.type === "error"),
@@ -1294,7 +2927,8 @@ var ERROR_ABI = [...LOCAL_ERRORS, (0, import_viem.parseAbi)([...OZ_ERROR_FRAGMEN
1294
2927
  var ORG_FUNCTION = "executeCall";
1295
2928
 
1296
2929
  // src/utils/anymals/useMintAnymalNFT.ts
1297
- var import_react10 = require("react");
2930
+ var import_viem3 = require("viem");
2931
+ var import_react11 = require("react");
1298
2932
 
1299
2933
  // src/helpers/GasEstimateHelper.tsx
1300
2934
  async function applyBundlerGasEstimator(account, bundlerClient, options) {
@@ -1375,7 +3009,7 @@ async function simulateCall(publicClient, target, abi, functionName, args, calle
1375
3009
 
1376
3010
  // src/utils/anymals/useMintAnymalNFT.ts
1377
3011
  function useMintAnymalNFT() {
1378
- return (0, import_react10.useCallback)(
3012
+ return (0, import_react11.useCallback)(
1379
3013
  async (pid, nftId, anymalTxId, dbAuthToken, validationContractAddress, smartAccount, bundlerClient) => {
1380
3014
  if (!dbAuthToken || !nftId || !bundlerClient || !smartAccount || !pid || !validationContractAddress) {
1381
3015
  return {
@@ -1427,9 +3061,9 @@ function useMintAnymalNFT() {
1427
3061
  }
1428
3062
 
1429
3063
  // src/utils/anymals/useAddAnymalToDatabase.ts
1430
- var import_react11 = require("react");
3064
+ var import_react12 = require("react");
1431
3065
  function useAddAnymalToDatabase() {
1432
- return (0, import_react11.useCallback)(
3066
+ return (0, import_react12.useCallback)(
1433
3067
  async (dbAuthToken, endpoint, anymalData) => {
1434
3068
  if (!dbAuthToken) {
1435
3069
  return {
@@ -1502,9 +3136,9 @@ function useAddAnymalToDatabase() {
1502
3136
  }
1503
3137
 
1504
3138
  // src/utils/anymals/useDeleteAnymalFromDatabase.ts
1505
- var import_react12 = require("react");
3139
+ var import_react13 = require("react");
1506
3140
  function useDeleteAnymalFromDatabase() {
1507
- return (0, import_react12.useCallback)(
3141
+ return (0, import_react13.useCallback)(
1508
3142
  async (dbAuthToken, endpoint, anymalDocID) => {
1509
3143
  if (!dbAuthToken || !endpoint || !anymalDocID) return;
1510
3144
  try {
@@ -1542,9 +3176,9 @@ function useDeleteAnymalFromDatabase() {
1542
3176
  }
1543
3177
 
1544
3178
  // src/utils/anymals/useSaveAnymalMetadata.ts
1545
- var import_react13 = require("react");
3179
+ var import_react14 = require("react");
1546
3180
  function useSaveAnymalMetadata() {
1547
- return (0, import_react13.useCallback)(
3181
+ return (0, import_react14.useCallback)(
1548
3182
  async (userPid, anymalTxId, idToken, publicKey, nftMetadataInput, authServiceBaseUrl) => {
1549
3183
  const response = await fetch(`${authServiceBaseUrl}/process-nft`, {
1550
3184
  method: "POST",
@@ -1573,9 +3207,9 @@ function useSaveAnymalMetadata() {
1573
3207
  }
1574
3208
 
1575
3209
  // src/utils/anymals/useUpdateAnymalWithNFT.ts
1576
- var import_react14 = require("react");
3210
+ var import_react15 = require("react");
1577
3211
  function useUpdateAnymalWithNFT() {
1578
- return (0, import_react14.useCallback)(
3212
+ return (0, import_react15.useCallback)(
1579
3213
  async (anymalPassportId, anymalDocId, dbAuthToken, endpoint) => {
1580
3214
  if (!dbAuthToken || !anymalPassportId || !anymalDocId || !endpoint) {
1581
3215
  return {
@@ -1622,7 +3256,7 @@ function useUpdateAnymalWithNFT() {
1622
3256
  }
1623
3257
 
1624
3258
  // src/utils/anymals/useUploadAnymalImage.ts
1625
- var import_react15 = require("react");
3259
+ var import_react16 = require("react");
1626
3260
 
1627
3261
  // src/helpers/UploadImageHelper.tsx
1628
3262
  function resizeImage(file, maxWidth = 800, maxHeight = 800, quality = 0.7) {
@@ -1679,7 +3313,7 @@ function toBase64(file) {
1679
3313
 
1680
3314
  // src/utils/anymals/useUploadAnymalImage.ts
1681
3315
  function useUploadAnymalImage() {
1682
- return (0, import_react15.useCallback)(
3316
+ return (0, import_react16.useCallback)(
1683
3317
  async (imageFile, type, idToken, publicKey, authServiceBaseUrl, petType, breed, lifestage, anymalPid) => {
1684
3318
  if (!imageFile || !idToken) {
1685
3319
  return {
@@ -1741,7 +3375,7 @@ function useUploadAnymalImage() {
1741
3375
  }
1742
3376
 
1743
3377
  // src/utils/anymals/useFetchAnymals.ts
1744
- var import_react16 = require("react");
3378
+ var import_react17 = require("react");
1745
3379
 
1746
3380
  // src/utils/anymals/fetchAnymals.ts
1747
3381
  async function fetchAnymals({
@@ -1794,11 +3428,11 @@ async function fetchAnymals({
1794
3428
 
1795
3429
  // src/utils/anymals/useFetchAnymals.ts
1796
3430
  function useFetchAnymals() {
1797
- return (0, import_react16.useCallback)(fetchAnymals, []);
3431
+ return (0, import_react17.useCallback)(fetchAnymals, []);
1798
3432
  }
1799
3433
 
1800
3434
  // src/utils/marketplace/useProcessPartialKibblePayment.ts
1801
- var import_react17 = require("react");
3435
+ var import_react18 = require("react");
1802
3436
 
1803
3437
  // src/helpers/ProcessDirectPartialPayment.tsx
1804
3438
  var import_viem4 = require("viem");
@@ -1898,7 +3532,7 @@ async function processDirectPartialPayment(marketplaceContract, smartAccount, bu
1898
3532
 
1899
3533
  // src/utils/marketplace/useProcessPartialKibblePayment.ts
1900
3534
  function useProcessPartialKibblePayment() {
1901
- return (0, import_react17.useCallback)(
3535
+ return (0, import_react18.useCallback)(
1902
3536
  async (pid, nftId, orderId, dbAuthToken, marketplaceContract, smartAccount, bundlerClient, amountInTokens, maxTokenPayment, nonce, deadline, backendSignature) => {
1903
3537
  if (!orderId || !dbAuthToken || !nftId || !bundlerClient || !smartAccount || !pid || !marketplaceContract || !amountInTokens || !maxTokenPayment || !nonce || !deadline) {
1904
3538
  return {
@@ -1954,7 +3588,7 @@ function useProcessPartialKibblePayment() {
1954
3588
  }
1955
3589
 
1956
3590
  // src/utils/marketplace/useApproveKibbleToken.ts
1957
- var import_react18 = require("react");
3591
+ var import_react19 = require("react");
1958
3592
 
1959
3593
  // src/helpers/ProcessDirectKibbleApproval.tsx
1960
3594
  var import_viem5 = require("viem");
@@ -1999,7 +3633,7 @@ async function processDirectKibbleApproval(kibbleTokenAddress, spenderAddress, s
1999
3633
 
2000
3634
  // src/utils/marketplace/useApproveKibbleToken.ts
2001
3635
  function useApproveKibbleToken() {
2002
- return (0, import_react18.useCallback)(
3636
+ return (0, import_react19.useCallback)(
2003
3637
  async (kibbleTokenAddress, marketplaceContract, amount, smartAccount, bundlerClient) => {
2004
3638
  try {
2005
3639
  const result = await processDirectKibbleApproval(
@@ -2026,10 +3660,10 @@ function useApproveKibbleToken() {
2026
3660
  }
2027
3661
 
2028
3662
  // src/utils/organization/useCreateOrganizationBase.ts
2029
- var import_react19 = require("react");
3663
+ var import_react20 = require("react");
2030
3664
  var import_viem6 = require("viem");
2031
3665
  function useCreateOrganizationBase() {
2032
- return (0, import_react19.useCallback)(
3666
+ return (0, import_react20.useCallback)(
2033
3667
  /**
2034
3668
  * Creates a new organization on-chain.
2035
3669
  *
@@ -2125,7 +3759,7 @@ function useCreateOrganizationBase() {
2125
3759
  }
2126
3760
 
2127
3761
  // src/utils/organization/useApproveOrgKibbleToken.ts
2128
- var import_react20 = require("react");
3762
+ var import_react21 = require("react");
2129
3763
 
2130
3764
  // src/helpers/ProcessOrgKibbleApproval.tsx
2131
3765
  var import_viem8 = require("viem");
@@ -2223,7 +3857,7 @@ async function processOrgKibbleApproval(orgContractAddress, kibbleTokenAddress,
2223
3857
 
2224
3858
  // src/utils/organization/useApproveOrgKibbleToken.ts
2225
3859
  function useApproveOrgPartialPayment() {
2226
- return (0, import_react20.useCallback)(
3860
+ return (0, import_react21.useCallback)(
2227
3861
  async (orgContractAddress, kibbleTokenAddress, partialPaymentModuleAddress, managerSmartAccount, bundlerClient, approveAmount) => {
2228
3862
  if (!orgContractAddress || !kibbleTokenAddress || !partialPaymentModuleAddress || !managerSmartAccount || !bundlerClient || !approveAmount) {
2229
3863
  return {
@@ -2255,7 +3889,7 @@ function useApproveOrgPartialPayment() {
2255
3889
  }
2256
3890
 
2257
3891
  // src/utils/organization/useProcessOrgPartialKibblePayment.ts
2258
- var import_react21 = require("react");
3892
+ var import_react22 = require("react");
2259
3893
 
2260
3894
  // src/helpers/ProcessOrgPartialPayment.tsx
2261
3895
  var import_viem9 = require("viem");
@@ -2313,7 +3947,7 @@ async function processOrgPartialPayment(orgContractAddress, partialPaymentModule
2313
3947
 
2314
3948
  // src/utils/organization/useProcessOrgPartialKibblePayment.ts
2315
3949
  function useProcessOrgPartialKibblePayment() {
2316
- return (0, import_react21.useCallback)(
3950
+ return (0, import_react22.useCallback)(
2317
3951
  async (orgContractAddress, partialPaymentModuleAddress, managerSmartAccount, bundlerClient, orderId, anymalNftId, pid, amountInTokens, maxTokenPayment, nonce, deadline, backendSignature) => {
2318
3952
  if (!orgContractAddress || !partialPaymentModuleAddress || !managerSmartAccount || !bundlerClient || !orderId || !pid || !nonce || !backendSignature) {
2319
3953
  return {
@@ -2351,9 +3985,9 @@ function useProcessOrgPartialKibblePayment() {
2351
3985
  }
2352
3986
 
2353
3987
  // src/utils/organization/useUpdateOrgWalletAddress.ts
2354
- var import_react22 = require("react");
3988
+ var import_react23 = require("react");
2355
3989
  function useUpdateOrgWalletAddress() {
2356
- return (0, import_react22.useCallback)(
3990
+ return (0, import_react23.useCallback)(
2357
3991
  async (dbAuthToken, docID, baseWalletAddress, endpoint) => {
2358
3992
  try {
2359
3993
  const mutation = `
@@ -2393,9 +4027,9 @@ function useUpdateOrgWalletAddress() {
2393
4027
 
2394
4028
  // src/utils/organization/useMintOrgAnymalNFT.ts
2395
4029
  var import_viem10 = require("viem");
2396
- var import_react23 = require("react");
4030
+ var import_react24 = require("react");
2397
4031
  function useMintOrgAnymalNFT() {
2398
- return (0, import_react23.useCallback)(
4032
+ return (0, import_react24.useCallback)(
2399
4033
  async (orgContractAddress, pid, nftId, anymalTxId, dbAuthToken, validationContractAddress, managerSmartAccount, bundlerClient) => {
2400
4034
  if (!dbAuthToken || !nftId || !bundlerClient || !managerSmartAccount || !pid || !validationContractAddress || !orgContractAddress) {
2401
4035
  return {
@@ -2658,9 +4292,9 @@ async function submitAction(idToken, pid, sourceType, payload, endpointBaseUrl)
2658
4292
  }
2659
4293
 
2660
4294
  // src/utils/actions/useFetchActions.ts
2661
- var import_react24 = require("react");
4295
+ var import_react25 = require("react");
2662
4296
  function useFetchActions() {
2663
- return (0, import_react24.useCallback)(
4297
+ return (0, import_react25.useCallback)(
2664
4298
  async (idToken, actionsServiceBaseUrl, pid, status, limit, offset) => {
2665
4299
  const params = new URLSearchParams({ pid });
2666
4300
  if (status) params.set("status", status);
@@ -2689,9 +4323,9 @@ function useFetchActions() {
2689
4323
  }
2690
4324
 
2691
4325
  // src/utils/actions/useFetchActionDefinitions.ts
2692
- var import_react25 = require("react");
4326
+ var import_react26 = require("react");
2693
4327
  function useFetchActionDefinitions() {
2694
- return (0, import_react25.useCallback)(
4328
+ return (0, import_react26.useCallback)(
2695
4329
  async (idToken, actionsServiceBaseUrl) => {
2696
4330
  try {
2697
4331
  const response = await fetch(
@@ -2788,10 +4422,10 @@ var convertToMultipleActionRecords = (frs) => frs.map(convertToActionRecord);
2788
4422
  var convertToMultipleActionDefinitions = (frs) => frs.map(convertToActionDefinition);
2789
4423
 
2790
4424
  // src/utils/application/useCreateUserAppData.ts
2791
- var import_react26 = require("react");
4425
+ var import_react27 = require("react");
2792
4426
  var import_uuid2 = require("uuid");
2793
4427
  function useCreateUserAppData() {
2794
- return (0, import_react26.useCallback)(
4428
+ return (0, import_react27.useCallback)(
2795
4429
  async (appId, pid, dbAuthToken, endpoint) => {
2796
4430
  if (!dbAuthToken || !pid || !dbAuthToken || !endpoint) return;
2797
4431
  const appValues = {
@@ -2846,10 +4480,10 @@ function useCreateUserAppData() {
2846
4480
  }
2847
4481
 
2848
4482
  // src/utils/application/useCreateOrganizationAppData.ts
2849
- var import_react27 = require("react");
4483
+ var import_react28 = require("react");
2850
4484
  var import_uuid3 = require("uuid");
2851
4485
  function useCreateOrganizationAppData() {
2852
- return (0, import_react27.useCallback)(
4486
+ return (0, import_react28.useCallback)(
2853
4487
  async (appId, pid, dbAuthToken, endpoint) => {
2854
4488
  if (!dbAuthToken || !pid || !dbAuthToken || !endpoint) return;
2855
4489
  const appValues = {
@@ -2903,10 +4537,10 @@ function useCreateOrganizationAppData() {
2903
4537
  }
2904
4538
 
2905
4539
  // src/utils/balance/useFetchBalance.ts
2906
- var import_react28 = require("react");
4540
+ var import_react29 = require("react");
2907
4541
  var import_viem12 = require("viem");
2908
4542
  function useFetchBalance() {
2909
- return (0, import_react28.useCallback)(
4543
+ return (0, import_react29.useCallback)(
2910
4544
  async (publicClient, walletAddress, kibbleTokenAddress) => {
2911
4545
  try {
2912
4546
  const balance = await publicClient.readContract({
@@ -2926,9 +4560,9 @@ function useFetchBalance() {
2926
4560
 
2927
4561
  // src/utils/actions/useClaimActionReward.ts
2928
4562
  var import_viem13 = require("viem");
2929
- var import_react29 = require("react");
4563
+ var import_react30 = require("react");
2930
4564
  function useClaimActionReward() {
2931
- return (0, import_react29.useCallback)(
4565
+ return (0, import_react30.useCallback)(
2932
4566
  async (actionId, claimIndex, rewardableActionContractAddress, smartAccount, bundlerClient) => {
2933
4567
  if (!actionId || claimIndex === void 0 || !bundlerClient || !smartAccount || !rewardableActionContractAddress) {
2934
4568
  return {
@@ -2975,9 +4609,9 @@ function useClaimActionReward() {
2975
4609
 
2976
4610
  // src/utils/actions/useClaimOrgActionReward.ts
2977
4611
  var import_viem14 = require("viem");
2978
- var import_react30 = require("react");
4612
+ var import_react31 = require("react");
2979
4613
  function useClaimOrgActionReward() {
2980
- return (0, import_react30.useCallback)(
4614
+ return (0, import_react31.useCallback)(
2981
4615
  async (orgContractAddress, rewardableActionContractAddress, actionId, claimIndex, smartAccount, bundlerClient) => {
2982
4616
  if (!orgContractAddress || !actionId || claimIndex === void 0 || !bundlerClient || !smartAccount) {
2983
4617
  return {
@@ -3027,9 +4661,9 @@ function useClaimOrgActionReward() {
3027
4661
  }
3028
4662
 
3029
4663
  // src/utils/actions/useSubmitContractAction.ts
3030
- var import_react31 = require("react");
4664
+ var import_react32 = require("react");
3031
4665
  function useSubmitContractAction() {
3032
- return (0, import_react31.useCallback)(
4666
+ return (0, import_react32.useCallback)(
3033
4667
  (idToken, pid, source, endpoint, payload) => {
3034
4668
  if (!idToken || !pid || !source || !endpoint || !payload) return;
3035
4669
  let sourceTypePayload = {};
@@ -3150,11 +4784,19 @@ function isMarketplacePurchaseAction(payload) {
3150
4784
  ActionSourceType,
3151
4785
  ActionStatus,
3152
4786
  ActionType,
4787
+ ERROR_ABI,
3153
4788
  FIREBASE_WEB_API_KEYS,
3154
4789
  FIREBASE_WEB_AUTH_API_ENDPOINTS,
4790
+ KIBBLE_TOKEN_ABI,
4791
+ MARKETPLACE_ABI,
3155
4792
  MarketplacePaymentType,
3156
4793
  NETWORK_HOSTS,
3157
4794
  Network,
4795
+ ORGANIZATION_BEACON_ABI,
4796
+ ORGANIZATION_IMPL_ABI,
4797
+ ORG_FUNCTION,
4798
+ PET_NFT_ABI,
4799
+ REWARDABLE_ACTIONS_ABI,
3158
4800
  convertToActionDefinition,
3159
4801
  convertToActionRecord,
3160
4802
  convertToMultipleActionDefinitions,
@@ -3197,6 +4839,7 @@ function isMarketplacePurchaseAction(payload) {
3197
4839
  useProcessOrgPartialKibblePayment,
3198
4840
  useProcessPartialKibblePayment,
3199
4841
  useSaveAnymalMetadata,
4842
+ useSendCoinbaseUserOperation,
3200
4843
  useSubmitContractAction,
3201
4844
  useUpdateAnymalWithNFT,
3202
4845
  useUpdateOrgWalletAddress,