anymal-protocol 1.0.123 → 1.0.125

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,18 +24,25 @@ __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,
35
43
  convertToMultipleActionRecords: () => convertToMultipleActionRecords,
36
44
  createApp: () => createApp,
37
45
  createAuthEnvelope: () => createAuthEnvelope,
38
- fetchAnymals: () => fetchAnymals,
39
46
  flattenFirestoreData: () => flattenFirestoreData,
40
47
  generateAppSignature: () => generateAppSignature,
41
48
  generateBytes32Nonce: () => generateBytes32Nonce,
@@ -50,19 +57,17 @@ __export(index_exports, {
50
57
  sendUserOpWithRetries: () => sendUserOpWithRetries,
51
58
  serializePublicKeyCompressed: () => serializePublicKeyCompressed,
52
59
  submitAction: () => submitAction,
53
- useAddAnymalToDatabase: () => useAddAnymalToDatabase,
54
60
  useApproveKibbleToken: () => useApproveKibbleToken,
55
61
  useApproveOrgPartialPayment: () => useApproveOrgPartialPayment,
56
62
  useClaimActionReward: () => useClaimActionReward,
57
63
  useClaimOrgActionReward: () => useClaimOrgActionReward,
64
+ useCoinbaseMintAnymalNFT: () => useCoinbaseMintAnymalNFT,
58
65
  useCreateOrganizationAppData: () => useCreateOrganizationAppData,
59
66
  useCreateOrganizationBase: () => useCreateOrganizationBase,
60
67
  useCreateUserAppData: () => useCreateUserAppData,
61
68
  useCreateWeb3Account: () => useCreateWeb3Account,
62
- useDeleteAnymalFromDatabase: () => useDeleteAnymalFromDatabase,
63
69
  useFetchActionDefinitions: () => useFetchActionDefinitions,
64
70
  useFetchActions: () => useFetchActions,
65
- useFetchAnymals: () => useFetchAnymals,
66
71
  useFetchBalance: () => useFetchBalance,
67
72
  useFetchNotifications: () => useFetchNotifications,
68
73
  useFetchUserData: () => useFetchUserData,
@@ -71,8 +76,8 @@ __export(index_exports, {
71
76
  useProcessOrgPartialKibblePayment: () => useProcessOrgPartialKibblePayment,
72
77
  useProcessPartialKibblePayment: () => useProcessPartialKibblePayment,
73
78
  useSaveAnymalMetadata: () => useSaveAnymalMetadata,
79
+ useSendCoinbaseUserOperation: () => useSendCoinbaseUserOperation,
74
80
  useSubmitContractAction: () => useSubmitContractAction,
75
- useUpdateAnymalWithNFT: () => useUpdateAnymalWithNFT,
76
81
  useUpdateOrgWalletAddress: () => useUpdateOrgWalletAddress,
77
82
  useUpdateUserAsVerified: () => useUpdateUserAsVerified,
78
83
  useUpdateUserEmail: () => useUpdateUserEmail,
@@ -458,15 +463,1143 @@ function useFetchNotifications() {
458
463
  );
459
464
  }
460
465
 
461
- // src/utils/anymals/useMintAnymalNFT.ts
462
- var import_viem3 = require("viem");
466
+ // src/utils/coinbase/useSendCoinbaseUserOperation.ts
467
+ var import_react10 = require("react");
468
+ var import_cdp_hooks = require("@coinbase/cdp-hooks");
469
+ function useSendCoinbaseUserOperation() {
470
+ const { sendUserOperation, data, error, status } = (0, import_cdp_hooks.useSendUserOperation)();
471
+ const sendOperationFn = (0, import_react10.useCallback)(
472
+ async (evmAddress, callData, contractAddress) => {
473
+ if (!evmAddress || !callData || !contractAddress) {
474
+ return { success: false, message: "Missing required information" };
475
+ }
476
+ try {
477
+ await sendUserOperation({
478
+ evmSmartAccount: evmAddress,
479
+ network: "base-sepolia",
480
+ useCdpPaymaster: true,
481
+ calls: [{ data: callData, to: contractAddress }]
482
+ });
483
+ return { success: true, message: "Operation submitted." };
484
+ } catch (e) {
485
+ console.error(e);
486
+ return { success: false, message: e.message };
487
+ }
488
+ },
489
+ [sendUserOperation]
490
+ );
491
+ return { sendOperationFn, data, status, error };
492
+ }
493
+
494
+ // src/utils/coinbase/useCoinbaseMintAnymalNFT.ts
495
+ var import_viem2 = require("viem");
463
496
 
464
497
  // src/helpers/BlockchainAbiHelper.tsx
465
498
  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" }];
499
+ var PET_NFT_ABI = [{ "inputs": [], "stateMutability": "nonpayable", "type": "constructor" }, {
500
+ "inputs": [],
501
+ "name": "AccessControlBadConfirmation",
502
+ "type": "error"
503
+ }, {
504
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, {
505
+ "internalType": "bytes32",
506
+ "name": "neededRole",
507
+ "type": "bytes32"
508
+ }],
509
+ "name": "AccessControlUnauthorizedAccount",
510
+ "type": "error"
511
+ }, {
512
+ "inputs": [{ "internalType": "address", "name": "target", "type": "address" }],
513
+ "name": "AddressEmptyCode",
514
+ "type": "error"
515
+ }, {
516
+ "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }],
517
+ "name": "ERC1967InvalidImplementation",
518
+ "type": "error"
519
+ }, { "inputs": [], "name": "ERC1967NonPayable", "type": "error" }, {
520
+ "inputs": [],
521
+ "name": "EnforcedPause",
522
+ "type": "error"
523
+ }, { "inputs": [], "name": "ExpectedPause", "type": "error" }, {
524
+ "inputs": [],
525
+ "name": "FailedCall",
526
+ "type": "error"
527
+ }, { "inputs": [], "name": "InvalidInitialization", "type": "error" }, {
528
+ "inputs": [],
529
+ "name": "NotInitializing",
530
+ "type": "error"
531
+ }, { "inputs": [], "name": "UUPSUnauthorizedCallContext", "type": "error" }, {
532
+ "inputs": [{
533
+ "internalType": "bytes32",
534
+ "name": "slot",
535
+ "type": "bytes32"
536
+ }],
537
+ "name": "UUPSUnsupportedProxiableUUID",
538
+ "type": "error"
539
+ }, {
540
+ "anonymous": false,
541
+ "inputs": [{ "indexed": false, "internalType": "uint64", "name": "version", "type": "uint64" }],
542
+ "name": "Initialized",
543
+ "type": "event"
544
+ }, {
545
+ "anonymous": false,
546
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }, {
547
+ "indexed": false,
548
+ "internalType": "string",
549
+ "name": "pid",
550
+ "type": "string"
551
+ }, { "indexed": false, "internalType": "string", "name": "nftId", "type": "string" }, {
552
+ "indexed": false,
553
+ "internalType": "string",
554
+ "name": "metadataURL",
555
+ "type": "string"
556
+ }, { "indexed": false, "internalType": "uint256", "name": "campaignId", "type": "uint256" }, {
557
+ "indexed": false,
558
+ "internalType": "uint256",
559
+ "name": "rewardAmount",
560
+ "type": "uint256"
561
+ }, { "indexed": false, "internalType": "string", "name": "_anymalTxId", "type": "string" }],
562
+ "name": "MetadataApproved",
563
+ "type": "event"
564
+ }, {
565
+ "anonymous": false,
566
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }, {
567
+ "indexed": false,
568
+ "internalType": "string",
569
+ "name": "anymalTxId",
570
+ "type": "string"
571
+ }, { "indexed": false, "internalType": "string", "name": "pid", "type": "string" }, {
572
+ "indexed": false,
573
+ "internalType": "string",
574
+ "name": "nftId",
575
+ "type": "string"
576
+ }, { "indexed": false, "internalType": "string", "name": "metadataURL", "type": "string" }, {
577
+ "indexed": false,
578
+ "internalType": "uint256",
579
+ "name": "campaignId",
580
+ "type": "uint256"
581
+ }, { "indexed": false, "internalType": "uint256", "name": "rewardAmount", "type": "uint256" }, {
582
+ "indexed": false,
583
+ "internalType": "string",
584
+ "name": "_anymalTxId",
585
+ "type": "string"
586
+ }],
587
+ "name": "MetadataRejected",
588
+ "type": "event"
589
+ }, {
590
+ "anonymous": false,
591
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }, {
592
+ "indexed": false,
593
+ "internalType": "string",
594
+ "name": "pid",
595
+ "type": "string"
596
+ }, { "indexed": false, "internalType": "string", "name": "nftId", "type": "string" }, {
597
+ "indexed": false,
598
+ "internalType": "string",
599
+ "name": "metadataURL",
600
+ "type": "string"
601
+ }, { "indexed": false, "internalType": "uint256", "name": "campaignId", "type": "uint256" }, {
602
+ "indexed": false,
603
+ "internalType": "uint256",
604
+ "name": "rewardAmount",
605
+ "type": "uint256"
606
+ }, { "indexed": false, "internalType": "string", "name": "_anymalTxId", "type": "string" }],
607
+ "name": "MetadataSubmitted",
608
+ "type": "event"
609
+ }, {
610
+ "anonymous": false,
611
+ "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }],
612
+ "name": "Paused",
613
+ "type": "event"
614
+ }, {
615
+ "anonymous": false,
616
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "user", "type": "address" }, {
617
+ "indexed": false,
618
+ "internalType": "string",
619
+ "name": "pid",
620
+ "type": "string"
621
+ }, { "indexed": false, "internalType": "string", "name": "nftId", "type": "string" }, {
622
+ "indexed": false,
623
+ "internalType": "uint256",
624
+ "name": "rewardAmount",
625
+ "type": "uint256"
626
+ }, { "indexed": false, "internalType": "uint256", "name": "campaignId", "type": "uint256" }, {
627
+ "indexed": false,
628
+ "internalType": "string",
629
+ "name": "_anymalTxId",
630
+ "type": "string"
631
+ }],
632
+ "name": "RewardDistributed",
633
+ "type": "event"
634
+ }, {
635
+ "anonymous": false,
636
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
637
+ "indexed": true,
638
+ "internalType": "bytes32",
639
+ "name": "previousAdminRole",
640
+ "type": "bytes32"
641
+ }, { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" }],
642
+ "name": "RoleAdminChanged",
643
+ "type": "event"
644
+ }, {
645
+ "anonymous": false,
646
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
647
+ "indexed": true,
648
+ "internalType": "address",
649
+ "name": "account",
650
+ "type": "address"
651
+ }, { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }],
652
+ "name": "RoleGranted",
653
+ "type": "event"
654
+ }, {
655
+ "anonymous": false,
656
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
657
+ "indexed": true,
658
+ "internalType": "address",
659
+ "name": "account",
660
+ "type": "address"
661
+ }, { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }],
662
+ "name": "RoleRevoked",
663
+ "type": "event"
664
+ }, {
665
+ "anonymous": false,
666
+ "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }],
667
+ "name": "Unpaused",
668
+ "type": "event"
669
+ }, {
670
+ "anonymous": false,
671
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }],
672
+ "name": "Upgraded",
673
+ "type": "event"
674
+ }, {
675
+ "inputs": [],
676
+ "name": "APPROVER_ROLE",
677
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
678
+ "stateMutability": "view",
679
+ "type": "function"
680
+ }, {
681
+ "inputs": [],
682
+ "name": "DEFAULT_ADMIN_ROLE",
683
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
684
+ "stateMutability": "view",
685
+ "type": "function"
686
+ }, {
687
+ "inputs": [],
688
+ "name": "UPGRADE_INTERFACE_VERSION",
689
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
690
+ "stateMutability": "view",
691
+ "type": "function"
692
+ }, {
693
+ "inputs": [{ "internalType": "address", "name": "_user", "type": "address" }, {
694
+ "internalType": "string",
695
+ "name": "_pid",
696
+ "type": "string"
697
+ }, { "internalType": "string", "name": "_nftId", "type": "string" }, {
698
+ "internalType": "string",
699
+ "name": "_metadataURL",
700
+ "type": "string"
701
+ }, { "internalType": "uint256", "name": "_campaignId", "type": "uint256" }, {
702
+ "internalType": "string",
703
+ "name": "_anymalTxId",
704
+ "type": "string"
705
+ }],
706
+ "name": "approveMetadata",
707
+ "outputs": [],
708
+ "stateMutability": "nonpayable",
709
+ "type": "function"
710
+ }, {
711
+ "inputs": [],
712
+ "name": "campaignCount",
713
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
714
+ "stateMutability": "view",
715
+ "type": "function"
716
+ }, {
717
+ "inputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
718
+ "name": "campaigns",
719
+ "outputs": [{ "internalType": "string", "name": "name", "type": "string" }, {
720
+ "internalType": "uint256",
721
+ "name": "rewardAmount",
722
+ "type": "uint256"
723
+ }, { "internalType": "bool", "name": "isActive", "type": "bool" }],
724
+ "stateMutability": "view",
725
+ "type": "function"
726
+ }, {
727
+ "inputs": [{ "internalType": "string", "name": "_name", "type": "string" }, {
728
+ "internalType": "uint256",
729
+ "name": "_rewardAmount",
730
+ "type": "uint256"
731
+ }],
732
+ "name": "createCampaign",
733
+ "outputs": [],
734
+ "stateMutability": "nonpayable",
735
+ "type": "function"
736
+ }, {
737
+ "inputs": [],
738
+ "name": "defaultRewardAmount",
739
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
740
+ "stateMutability": "view",
741
+ "type": "function"
742
+ }, {
743
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }],
744
+ "name": "getRoleAdmin",
745
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
746
+ "stateMutability": "view",
747
+ "type": "function"
748
+ }, {
749
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
750
+ "internalType": "address",
751
+ "name": "account",
752
+ "type": "address"
753
+ }],
754
+ "name": "grantRole",
755
+ "outputs": [],
756
+ "stateMutability": "nonpayable",
757
+ "type": "function"
758
+ }, {
759
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
760
+ "internalType": "address",
761
+ "name": "account",
762
+ "type": "address"
763
+ }],
764
+ "name": "hasRole",
765
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
766
+ "stateMutability": "view",
767
+ "type": "function"
768
+ }, {
769
+ "inputs": [{
770
+ "internalType": "address",
771
+ "name": "initialOwner",
772
+ "type": "address"
773
+ }, {
774
+ "internalType": "contract IERC20",
775
+ "name": "_rewardToken",
776
+ "type": "address"
777
+ }, { "internalType": "contract IPetToken", "name": "_petToken", "type": "address" }, {
778
+ "internalType": "uint256",
779
+ "name": "_defaultRewardAmount",
780
+ "type": "uint256"
781
+ }],
782
+ "name": "initialize",
783
+ "outputs": [],
784
+ "stateMutability": "nonpayable",
785
+ "type": "function"
786
+ }, {
787
+ "inputs": [],
788
+ "name": "pause",
789
+ "outputs": [],
790
+ "stateMutability": "nonpayable",
791
+ "type": "function"
792
+ }, {
793
+ "inputs": [],
794
+ "name": "paused",
795
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
796
+ "stateMutability": "view",
797
+ "type": "function"
798
+ }, {
799
+ "inputs": [],
800
+ "name": "petToken",
801
+ "outputs": [{ "internalType": "contract IPetToken", "name": "", "type": "address" }],
802
+ "stateMutability": "view",
803
+ "type": "function"
804
+ }, {
805
+ "inputs": [],
806
+ "name": "proxiableUUID",
807
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
808
+ "stateMutability": "view",
809
+ "type": "function"
810
+ }, {
811
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
812
+ "internalType": "address",
813
+ "name": "callerConfirmation",
814
+ "type": "address"
815
+ }],
816
+ "name": "renounceRole",
817
+ "outputs": [],
818
+ "stateMutability": "nonpayable",
819
+ "type": "function"
820
+ }, {
821
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
822
+ "internalType": "address",
823
+ "name": "account",
824
+ "type": "address"
825
+ }],
826
+ "name": "revokeRole",
827
+ "outputs": [],
828
+ "stateMutability": "nonpayable",
829
+ "type": "function"
830
+ }, {
831
+ "inputs": [],
832
+ "name": "rewardToken",
833
+ "outputs": [{ "internalType": "contract IERC20", "name": "", "type": "address" }],
834
+ "stateMutability": "view",
835
+ "type": "function"
836
+ }, {
837
+ "inputs": [{ "internalType": "string", "name": "_pid", "type": "string" }, {
838
+ "internalType": "string",
839
+ "name": "_nftId",
840
+ "type": "string"
841
+ }, { "internalType": "string", "name": "_metadataURL", "type": "string" }, {
842
+ "internalType": "uint256",
843
+ "name": "_campaignId",
844
+ "type": "uint256"
845
+ }, { "internalType": "string", "name": "_anymalTxId", "type": "string" }],
846
+ "name": "submitMetadata",
847
+ "outputs": [],
848
+ "stateMutability": "nonpayable",
849
+ "type": "function"
850
+ }, {
851
+ "inputs": [{ "internalType": "string", "name": "_pid", "type": "string" }, {
852
+ "internalType": "string",
853
+ "name": "_nftId",
854
+ "type": "string"
855
+ }, { "internalType": "string", "name": "_metadataURL", "type": "string" }, {
856
+ "internalType": "string",
857
+ "name": "_campaignName",
858
+ "type": "string"
859
+ }, { "internalType": "string", "name": "_anymalTxId", "type": "string" }],
860
+ "name": "submitMetadataByCampaignName",
861
+ "outputs": [],
862
+ "stateMutability": "nonpayable",
863
+ "type": "function"
864
+ }, {
865
+ "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }],
866
+ "name": "supportsInterface",
867
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
868
+ "stateMutability": "view",
869
+ "type": "function"
870
+ }, {
871
+ "inputs": [],
872
+ "name": "unpause",
873
+ "outputs": [],
874
+ "stateMutability": "nonpayable",
875
+ "type": "function"
876
+ }, {
877
+ "inputs": [{ "internalType": "uint256", "name": "_campaignId", "type": "uint256" }, {
878
+ "internalType": "uint256",
879
+ "name": "_rewardAmount",
880
+ "type": "uint256"
881
+ }, { "internalType": "bool", "name": "_isActive", "type": "bool" }],
882
+ "name": "updateCampaign",
883
+ "outputs": [],
884
+ "stateMutability": "nonpayable",
885
+ "type": "function"
886
+ }, {
887
+ "inputs": [{ "internalType": "uint256", "name": "_rewardAmount", "type": "uint256" }],
888
+ "name": "updateDefaultReward",
889
+ "outputs": [],
890
+ "stateMutability": "nonpayable",
891
+ "type": "function"
892
+ }, {
893
+ "inputs": [{
894
+ "internalType": "address",
895
+ "name": "newImplementation",
896
+ "type": "address"
897
+ }, { "internalType": "bytes", "name": "data", "type": "bytes" }],
898
+ "name": "upgradeToAndCall",
899
+ "outputs": [],
900
+ "stateMutability": "payable",
901
+ "type": "function"
902
+ }];
903
+ var MARKETPLACE_ABI = [{
904
+ "inputs": [{ "internalType": "address", "name": "target", "type": "address" }],
905
+ "name": "AddressEmptyCode",
906
+ "type": "error"
907
+ }, { "inputs": [], "name": "ECDSAInvalidSignature", "type": "error" }, {
908
+ "inputs": [{
909
+ "internalType": "uint256",
910
+ "name": "length",
911
+ "type": "uint256"
912
+ }],
913
+ "name": "ECDSAInvalidSignatureLength",
914
+ "type": "error"
915
+ }, {
916
+ "inputs": [{ "internalType": "bytes32", "name": "s", "type": "bytes32" }],
917
+ "name": "ECDSAInvalidSignatureS",
918
+ "type": "error"
919
+ }, {
920
+ "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }],
921
+ "name": "ERC1967InvalidImplementation",
922
+ "type": "error"
923
+ }, { "inputs": [], "name": "ERC1967NonPayable", "type": "error" }, {
924
+ "inputs": [],
925
+ "name": "FailedCall",
926
+ "type": "error"
927
+ }, { "inputs": [], "name": "InvalidInitialization", "type": "error" }, {
928
+ "inputs": [],
929
+ "name": "NotInitializing",
930
+ "type": "error"
931
+ }, {
932
+ "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }],
933
+ "name": "OwnableInvalidOwner",
934
+ "type": "error"
935
+ }, {
936
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
937
+ "name": "OwnableUnauthorizedAccount",
938
+ "type": "error"
939
+ }, { "inputs": [], "name": "UUPSUnauthorizedCallContext", "type": "error" }, {
940
+ "inputs": [{
941
+ "internalType": "bytes32",
942
+ "name": "slot",
943
+ "type": "bytes32"
944
+ }],
945
+ "name": "UUPSUnsupportedProxiableUUID",
946
+ "type": "error"
947
+ }, {
948
+ "anonymous": false,
949
+ "inputs": [{ "indexed": false, "internalType": "uint64", "name": "version", "type": "uint64" }],
950
+ "name": "Initialized",
951
+ "type": "event"
952
+ }, {
953
+ "anonymous": false,
954
+ "inputs": [{
955
+ "indexed": true,
956
+ "internalType": "address",
957
+ "name": "previousOwner",
958
+ "type": "address"
959
+ }, { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" }],
960
+ "name": "OwnershipTransferred",
961
+ "type": "event"
962
+ }, {
963
+ "anonymous": false,
964
+ "inputs": [{ "indexed": true, "internalType": "string", "name": "orderId", "type": "string" }, {
965
+ "indexed": true,
966
+ "internalType": "address",
967
+ "name": "payer",
968
+ "type": "address"
969
+ }, { "indexed": true, "internalType": "string", "name": "pid", "type": "string" }, {
970
+ "indexed": false,
971
+ "internalType": "string",
972
+ "name": "anymalNftId",
973
+ "type": "string"
974
+ }, { "indexed": false, "internalType": "uint256", "name": "amountInTokens", "type": "uint256" }, {
975
+ "indexed": false,
976
+ "internalType": "uint256",
977
+ "name": "timestamp",
978
+ "type": "uint256"
979
+ }],
980
+ "name": "PartialPaymentMade",
981
+ "type": "event"
982
+ }, {
983
+ "anonymous": false,
984
+ "inputs": [{ "indexed": true, "internalType": "string", "name": "orderId", "type": "string" }, {
985
+ "indexed": true,
986
+ "internalType": "address",
987
+ "name": "payer",
988
+ "type": "address"
989
+ }, { "indexed": false, "internalType": "uint256", "name": "amountInTokens", "type": "uint256" }, {
990
+ "indexed": false,
991
+ "internalType": "uint256",
992
+ "name": "timestamp",
993
+ "type": "uint256"
994
+ }],
995
+ "name": "PaymentMade",
996
+ "type": "event"
997
+ }, {
998
+ "anonymous": false,
999
+ "inputs": [{ "indexed": true, "internalType": "string", "name": "orderId", "type": "string" }, {
1000
+ "indexed": true,
1001
+ "internalType": "address",
1002
+ "name": "payer",
1003
+ "type": "address"
1004
+ }, { "indexed": true, "internalType": "string", "name": "pid", "type": "string" }, {
1005
+ "indexed": false,
1006
+ "internalType": "uint256",
1007
+ "name": "refundedAmount",
1008
+ "type": "uint256"
1009
+ }, { "indexed": false, "internalType": "uint256", "name": "timestamp", "type": "uint256" }],
1010
+ "name": "RefundProcessed",
1011
+ "type": "event"
1012
+ }, {
1013
+ "anonymous": false,
1014
+ "inputs": [{ "indexed": false, "internalType": "bool", "name": "enabled", "type": "bool" }],
1015
+ "name": "SignatureCheckToggled",
1016
+ "type": "event"
1017
+ }, {
1018
+ "anonymous": false,
1019
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }],
1020
+ "name": "Upgraded",
1021
+ "type": "event"
1022
+ }, {
1023
+ "inputs": [],
1024
+ "name": "UPGRADE_INTERFACE_VERSION",
1025
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
1026
+ "stateMutability": "view",
1027
+ "type": "function"
1028
+ }, {
1029
+ "inputs": [],
1030
+ "name": "authorizer",
1031
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
1032
+ "stateMutability": "view",
1033
+ "type": "function"
1034
+ }, {
1035
+ "inputs": [{ "internalType": "address", "name": "_initialOwner", "type": "address" }, {
1036
+ "internalType": "address",
1037
+ "name": "_authorizer",
1038
+ "type": "address"
1039
+ }, { "internalType": "address", "name": "_kibbleToken", "type": "address" }],
1040
+ "name": "initialize",
1041
+ "outputs": [],
1042
+ "stateMutability": "nonpayable",
1043
+ "type": "function"
1044
+ }, {
1045
+ "inputs": [],
1046
+ "name": "kibbleToken",
1047
+ "outputs": [{ "internalType": "contract IERC20", "name": "", "type": "address" }],
1048
+ "stateMutability": "view",
1049
+ "type": "function"
1050
+ }, {
1051
+ "inputs": [],
1052
+ "name": "owner",
1053
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
1054
+ "stateMutability": "view",
1055
+ "type": "function"
1056
+ }, {
1057
+ "inputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }, {
1058
+ "internalType": "address",
1059
+ "name": "",
1060
+ "type": "address"
1061
+ }],
1062
+ "name": "paidAmounts",
1063
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
1064
+ "stateMutability": "view",
1065
+ "type": "function"
1066
+ }, {
1067
+ "inputs": [{ "internalType": "string", "name": "orderId", "type": "string" }, {
1068
+ "internalType": "string",
1069
+ "name": "anymalNftId",
1070
+ "type": "string"
1071
+ }, { "internalType": "string", "name": "pid", "type": "string" }, {
1072
+ "internalType": "uint256",
1073
+ "name": "amountInTokens",
1074
+ "type": "uint256"
1075
+ }, { "internalType": "uint256", "name": "maxTokenPayment", "type": "uint256" }, {
1076
+ "internalType": "bytes32",
1077
+ "name": "nonce",
1078
+ "type": "bytes32"
1079
+ }, { "internalType": "uint256", "name": "deadline", "type": "uint256" }, {
1080
+ "internalType": "bytes",
1081
+ "name": "backendSignature",
1082
+ "type": "bytes"
1083
+ }],
1084
+ "name": "partialPay",
1085
+ "outputs": [],
1086
+ "stateMutability": "nonpayable",
1087
+ "type": "function"
1088
+ }, {
1089
+ "inputs": [],
1090
+ "name": "proxiableUUID",
1091
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1092
+ "stateMutability": "view",
1093
+ "type": "function"
1094
+ }, {
1095
+ "inputs": [{ "internalType": "string", "name": "orderId", "type": "string" }, {
1096
+ "internalType": "address",
1097
+ "name": "payer",
1098
+ "type": "address"
1099
+ }, { "internalType": "string", "name": "pid", "type": "string" }],
1100
+ "name": "refund",
1101
+ "outputs": [],
1102
+ "stateMutability": "nonpayable",
1103
+ "type": "function"
1104
+ }, {
1105
+ "inputs": [],
1106
+ "name": "renounceOwnership",
1107
+ "outputs": [],
1108
+ "stateMutability": "nonpayable",
1109
+ "type": "function"
1110
+ }, {
1111
+ "inputs": [{ "internalType": "address", "name": "_authorizer", "type": "address" }],
1112
+ "name": "setAuthorizer",
1113
+ "outputs": [],
1114
+ "stateMutability": "nonpayable",
1115
+ "type": "function"
1116
+ }, {
1117
+ "inputs": [{ "internalType": "bool", "name": "enabled", "type": "bool" }],
1118
+ "name": "setSignatureCheckEnabled",
1119
+ "outputs": [],
1120
+ "stateMutability": "nonpayable",
1121
+ "type": "function"
1122
+ }, {
1123
+ "inputs": [],
1124
+ "name": "signatureCheckEnabled",
1125
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
1126
+ "stateMutability": "view",
1127
+ "type": "function"
1128
+ }, {
1129
+ "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }],
1130
+ "name": "transferOwnership",
1131
+ "outputs": [],
1132
+ "stateMutability": "nonpayable",
1133
+ "type": "function"
1134
+ }, {
1135
+ "inputs": [{
1136
+ "internalType": "address",
1137
+ "name": "newImplementation",
1138
+ "type": "address"
1139
+ }, { "internalType": "bytes", "name": "data", "type": "bytes" }],
1140
+ "name": "upgradeToAndCall",
1141
+ "outputs": [],
1142
+ "stateMutability": "payable",
1143
+ "type": "function"
1144
+ }, {
1145
+ "inputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1146
+ "name": "usedNonces",
1147
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
1148
+ "stateMutability": "view",
1149
+ "type": "function"
1150
+ }, {
1151
+ "inputs": [{ "internalType": "address", "name": "to", "type": "address" }, {
1152
+ "internalType": "uint256",
1153
+ "name": "amount",
1154
+ "type": "uint256"
1155
+ }],
1156
+ "name": "withdrawKibble",
1157
+ "outputs": [],
1158
+ "stateMutability": "nonpayable",
1159
+ "type": "function"
1160
+ }];
1161
+ var ORGANIZATION_BEACON_ABI = [{
1162
+ "inputs": [{
1163
+ "internalType": "address",
1164
+ "name": "_initialImplementation",
1165
+ "type": "address"
1166
+ }, { "internalType": "address", "name": "_initialOwner", "type": "address" }, {
1167
+ "internalType": "address",
1168
+ "name": "_anymalNFTProxy",
1169
+ "type": "address"
1170
+ }],
1171
+ "stateMutability": "nonpayable",
1172
+ "type": "constructor"
1173
+ }, {
1174
+ "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }],
1175
+ "name": "BeaconInvalidImplementation",
1176
+ "type": "error"
1177
+ }, {
1178
+ "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }],
1179
+ "name": "OwnableInvalidOwner",
1180
+ "type": "error"
1181
+ }, {
1182
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
1183
+ "name": "OwnableUnauthorizedAccount",
1184
+ "type": "error"
1185
+ }, {
1186
+ "anonymous": false,
1187
+ "inputs": [{ "indexed": false, "internalType": "string", "name": "pid", "type": "string" }, {
1188
+ "indexed": false,
1189
+ "internalType": "string",
1190
+ "name": "name",
1191
+ "type": "string"
1192
+ }, { "indexed": false, "internalType": "address", "name": "proxyAddress", "type": "address" }, {
1193
+ "indexed": false,
1194
+ "internalType": "address",
1195
+ "name": "networkAdmin",
1196
+ "type": "address"
1197
+ }, { "indexed": false, "internalType": "address", "name": "userAdmin", "type": "address" }],
1198
+ "name": "NewOrganizationCreated",
1199
+ "type": "event"
1200
+ }, {
1201
+ "anonymous": false,
1202
+ "inputs": [{
1203
+ "indexed": true,
1204
+ "internalType": "address",
1205
+ "name": "previousOwner",
1206
+ "type": "address"
1207
+ }, { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" }],
1208
+ "name": "OwnershipTransferred",
1209
+ "type": "event"
1210
+ }, {
1211
+ "anonymous": false,
1212
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }],
1213
+ "name": "Upgraded",
1214
+ "type": "event"
1215
+ }, {
1216
+ "inputs": [],
1217
+ "name": "anymalNFTProxy",
1218
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
1219
+ "stateMutability": "view",
1220
+ "type": "function"
1221
+ }, {
1222
+ "inputs": [{ "internalType": "address", "name": "_userAdmin", "type": "address" }, {
1223
+ "internalType": "string",
1224
+ "name": "_orgName",
1225
+ "type": "string"
1226
+ }, { "internalType": "string", "name": "_orgPid", "type": "string" }],
1227
+ "name": "createOrganizationProxy",
1228
+ "outputs": [{ "internalType": "address", "name": "proxyAddress", "type": "address" }],
1229
+ "stateMutability": "nonpayable",
1230
+ "type": "function"
1231
+ }, {
1232
+ "inputs": [],
1233
+ "name": "implementation",
1234
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
1235
+ "stateMutability": "view",
1236
+ "type": "function"
1237
+ }, {
1238
+ "inputs": [],
1239
+ "name": "owner",
1240
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
1241
+ "stateMutability": "view",
1242
+ "type": "function"
1243
+ }, {
1244
+ "inputs": [],
1245
+ "name": "renounceOwnership",
1246
+ "outputs": [],
1247
+ "stateMutability": "nonpayable",
1248
+ "type": "function"
1249
+ }, {
1250
+ "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }],
1251
+ "name": "transferOwnership",
1252
+ "outputs": [],
1253
+ "stateMutability": "nonpayable",
1254
+ "type": "function"
1255
+ }, {
1256
+ "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }],
1257
+ "name": "upgradeBeaconTo",
1258
+ "outputs": [],
1259
+ "stateMutability": "nonpayable",
1260
+ "type": "function"
1261
+ }, {
1262
+ "inputs": [{ "internalType": "address", "name": "newImplementation", "type": "address" }],
1263
+ "name": "upgradeTo",
1264
+ "outputs": [],
1265
+ "stateMutability": "nonpayable",
1266
+ "type": "function"
1267
+ }];
1268
+ var REWARDABLE_ACTIONS_ABI = [{
1269
+ "inputs": [],
1270
+ "stateMutability": "nonpayable",
1271
+ "type": "constructor"
1272
+ }, { "inputs": [], "name": "AccessControlBadConfirmation", "type": "error" }, {
1273
+ "inputs": [{
1274
+ "internalType": "address",
1275
+ "name": "account",
1276
+ "type": "address"
1277
+ }, { "internalType": "bytes32", "name": "neededRole", "type": "bytes32" }],
1278
+ "name": "AccessControlUnauthorizedAccount",
1279
+ "type": "error"
1280
+ }, {
1281
+ "inputs": [{ "internalType": "address", "name": "target", "type": "address" }],
1282
+ "name": "AddressEmptyCode",
1283
+ "type": "error"
1284
+ }, {
1285
+ "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }],
1286
+ "name": "ERC1967InvalidImplementation",
1287
+ "type": "error"
1288
+ }, { "inputs": [], "name": "ERC1967NonPayable", "type": "error" }, {
1289
+ "inputs": [],
1290
+ "name": "FailedCall",
1291
+ "type": "error"
1292
+ }, { "inputs": [], "name": "InvalidInitialization", "type": "error" }, {
1293
+ "inputs": [],
1294
+ "name": "NotInitializing",
1295
+ "type": "error"
1296
+ }, { "inputs": [], "name": "ReentrancyGuardReentrantCall", "type": "error" }, {
1297
+ "inputs": [],
1298
+ "name": "UUPSUnauthorizedCallContext",
1299
+ "type": "error"
1300
+ }, {
1301
+ "inputs": [{ "internalType": "bytes32", "name": "slot", "type": "bytes32" }],
1302
+ "name": "UUPSUnsupportedProxiableUUID",
1303
+ "type": "error"
1304
+ }, {
1305
+ "anonymous": false,
1306
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1307
+ "indexed": false,
1308
+ "internalType": "uint256",
1309
+ "name": "rewardAmount",
1310
+ "type": "uint256"
1311
+ }, { "indexed": false, "internalType": "uint256", "name": "maxClaims", "type": "uint256" }],
1312
+ "name": "ActionTypeAdded",
1313
+ "type": "event"
1314
+ }, {
1315
+ "anonymous": false,
1316
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1317
+ "indexed": false,
1318
+ "internalType": "uint256",
1319
+ "name": "newRewardAmount",
1320
+ "type": "uint256"
1321
+ }, { "indexed": false, "internalType": "uint256", "name": "newMaxClaims", "type": "uint256" }],
1322
+ "name": "ActionTypeUpdated",
1323
+ "type": "event"
1324
+ }, {
1325
+ "anonymous": false,
1326
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1327
+ "indexed": true,
1328
+ "internalType": "address",
1329
+ "name": "user",
1330
+ "type": "address"
1331
+ }, { "indexed": true, "internalType": "uint256", "name": "index", "type": "uint256" }, {
1332
+ "indexed": false,
1333
+ "internalType": "uint256",
1334
+ "name": "quantity",
1335
+ "type": "uint256"
1336
+ }, { "indexed": false, "internalType": "uint16", "name": "multiplier", "type": "uint16" }],
1337
+ "name": "ActionValidated",
1338
+ "type": "event"
1339
+ }, {
1340
+ "anonymous": false,
1341
+ "inputs": [{ "indexed": false, "internalType": "uint64", "name": "version", "type": "uint64" }],
1342
+ "name": "Initialized",
1343
+ "type": "event"
1344
+ }, {
1345
+ "anonymous": false,
1346
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1347
+ "indexed": true,
1348
+ "internalType": "address",
1349
+ "name": "user",
1350
+ "type": "address"
1351
+ }, { "indexed": true, "internalType": "uint256", "name": "index", "type": "uint256" }, {
1352
+ "indexed": false,
1353
+ "internalType": "uint256",
1354
+ "name": "amount",
1355
+ "type": "uint256"
1356
+ }],
1357
+ "name": "RewardClaimedByIndex",
1358
+ "type": "event"
1359
+ }, {
1360
+ "anonymous": false,
1361
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1362
+ "indexed": true,
1363
+ "internalType": "bytes32",
1364
+ "name": "previousAdminRole",
1365
+ "type": "bytes32"
1366
+ }, { "indexed": true, "internalType": "bytes32", "name": "newAdminRole", "type": "bytes32" }],
1367
+ "name": "RoleAdminChanged",
1368
+ "type": "event"
1369
+ }, {
1370
+ "anonymous": false,
1371
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1372
+ "indexed": true,
1373
+ "internalType": "address",
1374
+ "name": "account",
1375
+ "type": "address"
1376
+ }, { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }],
1377
+ "name": "RoleGranted",
1378
+ "type": "event"
1379
+ }, {
1380
+ "anonymous": false,
1381
+ "inputs": [{ "indexed": true, "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1382
+ "indexed": true,
1383
+ "internalType": "address",
1384
+ "name": "account",
1385
+ "type": "address"
1386
+ }, { "indexed": true, "internalType": "address", "name": "sender", "type": "address" }],
1387
+ "name": "RoleRevoked",
1388
+ "type": "event"
1389
+ }, {
1390
+ "anonymous": false,
1391
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }],
1392
+ "name": "Upgraded",
1393
+ "type": "event"
1394
+ }, {
1395
+ "inputs": [],
1396
+ "name": "ADMIN_ROLE",
1397
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1398
+ "stateMutability": "view",
1399
+ "type": "function"
1400
+ }, {
1401
+ "inputs": [],
1402
+ "name": "APPROVER_ROLE",
1403
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1404
+ "stateMutability": "view",
1405
+ "type": "function"
1406
+ }, {
1407
+ "inputs": [],
1408
+ "name": "DEFAULT_ADMIN_ROLE",
1409
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1410
+ "stateMutability": "view",
1411
+ "type": "function"
1412
+ }, {
1413
+ "inputs": [],
1414
+ "name": "UPGRADE_INTERFACE_VERSION",
1415
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
1416
+ "stateMutability": "view",
1417
+ "type": "function"
1418
+ }, {
1419
+ "inputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1420
+ "name": "actionConfigs",
1421
+ "outputs": [{ "internalType": "uint256", "name": "rewardAmount", "type": "uint256" }, {
1422
+ "internalType": "uint256",
1423
+ "name": "maxClaims",
1424
+ "type": "uint256"
1425
+ }, { "internalType": "bool", "name": "exists", "type": "bool" }],
1426
+ "stateMutability": "view",
1427
+ "type": "function"
1428
+ }, {
1429
+ "inputs": [{ "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1430
+ "internalType": "uint256",
1431
+ "name": "rewardAmount",
1432
+ "type": "uint256"
1433
+ }, { "internalType": "uint256", "name": "maxClaims", "type": "uint256" }],
1434
+ "name": "addActionType",
1435
+ "outputs": [],
1436
+ "stateMutability": "nonpayable",
1437
+ "type": "function"
1438
+ }, {
1439
+ "inputs": [{ "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1440
+ "internalType": "uint256",
1441
+ "name": "index",
1442
+ "type": "uint256"
1443
+ }],
1444
+ "name": "claimByIndex",
1445
+ "outputs": [],
1446
+ "stateMutability": "nonpayable",
1447
+ "type": "function"
1448
+ }, {
1449
+ "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }],
1450
+ "name": "depositRewards",
1451
+ "outputs": [],
1452
+ "stateMutability": "nonpayable",
1453
+ "type": "function"
1454
+ }, {
1455
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }],
1456
+ "name": "getRoleAdmin",
1457
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1458
+ "stateMutability": "view",
1459
+ "type": "function"
1460
+ }, {
1461
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1462
+ "internalType": "address",
1463
+ "name": "account",
1464
+ "type": "address"
1465
+ }],
1466
+ "name": "grantRole",
1467
+ "outputs": [],
1468
+ "stateMutability": "nonpayable",
1469
+ "type": "function"
1470
+ }, {
1471
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1472
+ "internalType": "address",
1473
+ "name": "account",
1474
+ "type": "address"
1475
+ }],
1476
+ "name": "hasRole",
1477
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
1478
+ "stateMutability": "view",
1479
+ "type": "function"
1480
+ }, {
1481
+ "inputs": [{
1482
+ "internalType": "address",
1483
+ "name": "initialOwner",
1484
+ "type": "address"
1485
+ }, { "internalType": "contract IERC20", "name": "_rewardToken", "type": "address" }],
1486
+ "name": "initialize",
1487
+ "outputs": [],
1488
+ "stateMutability": "nonpayable",
1489
+ "type": "function"
1490
+ }, {
1491
+ "inputs": [],
1492
+ "name": "proxiableUUID",
1493
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
1494
+ "stateMutability": "view",
1495
+ "type": "function"
1496
+ }, {
1497
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1498
+ "internalType": "address",
1499
+ "name": "callerConfirmation",
1500
+ "type": "address"
1501
+ }],
1502
+ "name": "renounceRole",
1503
+ "outputs": [],
1504
+ "stateMutability": "nonpayable",
1505
+ "type": "function"
1506
+ }, {
1507
+ "inputs": [{ "internalType": "bytes32", "name": "role", "type": "bytes32" }, {
1508
+ "internalType": "address",
1509
+ "name": "account",
1510
+ "type": "address"
1511
+ }],
1512
+ "name": "revokeRole",
1513
+ "outputs": [],
1514
+ "stateMutability": "nonpayable",
1515
+ "type": "function"
1516
+ }, {
1517
+ "inputs": [],
1518
+ "name": "rewardToken",
1519
+ "outputs": [{ "internalType": "contract IERC20", "name": "", "type": "address" }],
1520
+ "stateMutability": "view",
1521
+ "type": "function"
1522
+ }, {
1523
+ "inputs": [{ "internalType": "bytes4", "name": "interfaceId", "type": "bytes4" }],
1524
+ "name": "supportsInterface",
1525
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
1526
+ "stateMutability": "view",
1527
+ "type": "function"
1528
+ }, {
1529
+ "inputs": [{ "internalType": "address", "name": "user", "type": "address" }, {
1530
+ "internalType": "bytes32",
1531
+ "name": "actionId",
1532
+ "type": "bytes32"
1533
+ }],
1534
+ "name": "totalValidatedSlots",
1535
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
1536
+ "stateMutability": "view",
1537
+ "type": "function"
1538
+ }, {
1539
+ "inputs": [{ "internalType": "address", "name": "user", "type": "address" }, {
1540
+ "internalType": "bytes32",
1541
+ "name": "actionId",
1542
+ "type": "bytes32"
1543
+ }],
1544
+ "name": "unclaimedSlots",
1545
+ "outputs": [{ "internalType": "uint256", "name": "count", "type": "uint256" }],
1546
+ "stateMutability": "view",
1547
+ "type": "function"
1548
+ }, {
1549
+ "inputs": [{ "internalType": "bytes32", "name": "actionId", "type": "bytes32" }, {
1550
+ "internalType": "uint256",
1551
+ "name": "newRewardAmount",
1552
+ "type": "uint256"
1553
+ }, { "internalType": "uint256", "name": "newMaxClaims", "type": "uint256" }],
1554
+ "name": "updateActionType",
1555
+ "outputs": [],
1556
+ "stateMutability": "nonpayable",
1557
+ "type": "function"
1558
+ }, {
1559
+ "inputs": [{
1560
+ "internalType": "address",
1561
+ "name": "newImplementation",
1562
+ "type": "address"
1563
+ }, { "internalType": "bytes", "name": "data", "type": "bytes" }],
1564
+ "name": "upgradeToAndCall",
1565
+ "outputs": [],
1566
+ "stateMutability": "payable",
1567
+ "type": "function"
1568
+ }, {
1569
+ "inputs": [{ "internalType": "address", "name": "user", "type": "address" }, {
1570
+ "internalType": "bytes32",
1571
+ "name": "actionId",
1572
+ "type": "bytes32"
1573
+ }, { "internalType": "uint256", "name": "quantity", "type": "uint256" }, {
1574
+ "internalType": "uint16",
1575
+ "name": "multiplier",
1576
+ "type": "uint16"
1577
+ }],
1578
+ "name": "validateAction",
1579
+ "outputs": [],
1580
+ "stateMutability": "nonpayable",
1581
+ "type": "function"
1582
+ }, {
1583
+ "inputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }, {
1584
+ "internalType": "address",
1585
+ "name": "",
1586
+ "type": "address"
1587
+ }, { "internalType": "uint256", "name": "", "type": "uint256" }],
1588
+ "name": "validations",
1589
+ "outputs": [{ "internalType": "uint256", "name": "quantity", "type": "uint256" }, {
1590
+ "internalType": "uint16",
1591
+ "name": "multiplier",
1592
+ "type": "uint16"
1593
+ }, { "internalType": "bool", "name": "claimed", "type": "bool" }],
1594
+ "stateMutability": "view",
1595
+ "type": "function"
1596
+ }, {
1597
+ "inputs": [{ "internalType": "uint256", "name": "amount", "type": "uint256" }],
1598
+ "name": "withdrawRewards",
1599
+ "outputs": [],
1600
+ "stateMutability": "nonpayable",
1601
+ "type": "function"
1602
+ }];
470
1603
  var ORGANIZATION_IMPL_ABI = [
471
1604
  {
472
1605
  "inputs": [],
@@ -1277,7 +2410,506 @@ var ORGANIZATION_IMPL_ABI = [
1277
2410
  "type": "function"
1278
2411
  }
1279
2412
  ];
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" }];
2413
+ var KIBBLE_TOKEN_ABI = [{
2414
+ "inputs": [],
2415
+ "stateMutability": "nonpayable",
2416
+ "type": "constructor"
2417
+ }, {
2418
+ "inputs": [{ "internalType": "address", "name": "target", "type": "address" }],
2419
+ "name": "AddressEmptyCode",
2420
+ "type": "error"
2421
+ }, { "inputs": [], "name": "CheckpointUnorderedInsertion", "type": "error" }, {
2422
+ "inputs": [],
2423
+ "name": "ECDSAInvalidSignature",
2424
+ "type": "error"
2425
+ }, {
2426
+ "inputs": [{ "internalType": "uint256", "name": "length", "type": "uint256" }],
2427
+ "name": "ECDSAInvalidSignatureLength",
2428
+ "type": "error"
2429
+ }, {
2430
+ "inputs": [{ "internalType": "bytes32", "name": "s", "type": "bytes32" }],
2431
+ "name": "ECDSAInvalidSignatureS",
2432
+ "type": "error"
2433
+ }, {
2434
+ "inputs": [{ "internalType": "address", "name": "implementation", "type": "address" }],
2435
+ "name": "ERC1967InvalidImplementation",
2436
+ "type": "error"
2437
+ }, { "inputs": [], "name": "ERC1967NonPayable", "type": "error" }, {
2438
+ "inputs": [{
2439
+ "internalType": "uint256",
2440
+ "name": "increasedSupply",
2441
+ "type": "uint256"
2442
+ }, { "internalType": "uint256", "name": "cap", "type": "uint256" }],
2443
+ "name": "ERC20ExceededSafeSupply",
2444
+ "type": "error"
2445
+ }, {
2446
+ "inputs": [{ "internalType": "address", "name": "spender", "type": "address" }, {
2447
+ "internalType": "uint256",
2448
+ "name": "allowance",
2449
+ "type": "uint256"
2450
+ }, { "internalType": "uint256", "name": "needed", "type": "uint256" }],
2451
+ "name": "ERC20InsufficientAllowance",
2452
+ "type": "error"
2453
+ }, {
2454
+ "inputs": [{ "internalType": "address", "name": "sender", "type": "address" }, {
2455
+ "internalType": "uint256",
2456
+ "name": "balance",
2457
+ "type": "uint256"
2458
+ }, { "internalType": "uint256", "name": "needed", "type": "uint256" }],
2459
+ "name": "ERC20InsufficientBalance",
2460
+ "type": "error"
2461
+ }, {
2462
+ "inputs": [{ "internalType": "address", "name": "approver", "type": "address" }],
2463
+ "name": "ERC20InvalidApprover",
2464
+ "type": "error"
2465
+ }, {
2466
+ "inputs": [{ "internalType": "address", "name": "receiver", "type": "address" }],
2467
+ "name": "ERC20InvalidReceiver",
2468
+ "type": "error"
2469
+ }, {
2470
+ "inputs": [{ "internalType": "address", "name": "sender", "type": "address" }],
2471
+ "name": "ERC20InvalidSender",
2472
+ "type": "error"
2473
+ }, {
2474
+ "inputs": [{ "internalType": "address", "name": "spender", "type": "address" }],
2475
+ "name": "ERC20InvalidSpender",
2476
+ "type": "error"
2477
+ }, {
2478
+ "inputs": [{ "internalType": "uint256", "name": "deadline", "type": "uint256" }],
2479
+ "name": "ERC2612ExpiredSignature",
2480
+ "type": "error"
2481
+ }, {
2482
+ "inputs": [{ "internalType": "address", "name": "signer", "type": "address" }, {
2483
+ "internalType": "address",
2484
+ "name": "owner",
2485
+ "type": "address"
2486
+ }],
2487
+ "name": "ERC2612InvalidSigner",
2488
+ "type": "error"
2489
+ }, {
2490
+ "inputs": [{ "internalType": "uint256", "name": "timepoint", "type": "uint256" }, {
2491
+ "internalType": "uint48",
2492
+ "name": "clock",
2493
+ "type": "uint48"
2494
+ }],
2495
+ "name": "ERC5805FutureLookup",
2496
+ "type": "error"
2497
+ }, { "inputs": [], "name": "ERC6372InconsistentClock", "type": "error" }, {
2498
+ "inputs": [],
2499
+ "name": "EnforcedPause",
2500
+ "type": "error"
2501
+ }, { "inputs": [], "name": "ExpectedPause", "type": "error" }, {
2502
+ "inputs": [],
2503
+ "name": "FailedCall",
2504
+ "type": "error"
2505
+ }, {
2506
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, {
2507
+ "internalType": "uint256",
2508
+ "name": "currentNonce",
2509
+ "type": "uint256"
2510
+ }],
2511
+ "name": "InvalidAccountNonce",
2512
+ "type": "error"
2513
+ }, { "inputs": [], "name": "InvalidInitialization", "type": "error" }, {
2514
+ "inputs": [],
2515
+ "name": "NotInitializing",
2516
+ "type": "error"
2517
+ }, {
2518
+ "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }],
2519
+ "name": "OwnableInvalidOwner",
2520
+ "type": "error"
2521
+ }, {
2522
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
2523
+ "name": "OwnableUnauthorizedAccount",
2524
+ "type": "error"
2525
+ }, {
2526
+ "inputs": [{ "internalType": "uint8", "name": "bits", "type": "uint8" }, {
2527
+ "internalType": "uint256",
2528
+ "name": "value",
2529
+ "type": "uint256"
2530
+ }],
2531
+ "name": "SafeCastOverflowedUintDowncast",
2532
+ "type": "error"
2533
+ }, { "inputs": [], "name": "UUPSUnauthorizedCallContext", "type": "error" }, {
2534
+ "inputs": [{
2535
+ "internalType": "bytes32",
2536
+ "name": "slot",
2537
+ "type": "bytes32"
2538
+ }],
2539
+ "name": "UUPSUnsupportedProxiableUUID",
2540
+ "type": "error"
2541
+ }, {
2542
+ "inputs": [{ "internalType": "uint256", "name": "expiry", "type": "uint256" }],
2543
+ "name": "VotesExpiredSignature",
2544
+ "type": "error"
2545
+ }, {
2546
+ "anonymous": false,
2547
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, {
2548
+ "indexed": true,
2549
+ "internalType": "address",
2550
+ "name": "spender",
2551
+ "type": "address"
2552
+ }, { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }],
2553
+ "name": "Approval",
2554
+ "type": "event"
2555
+ }, {
2556
+ "anonymous": false,
2557
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "delegator", "type": "address" }, {
2558
+ "indexed": true,
2559
+ "internalType": "address",
2560
+ "name": "fromDelegate",
2561
+ "type": "address"
2562
+ }, { "indexed": true, "internalType": "address", "name": "toDelegate", "type": "address" }],
2563
+ "name": "DelegateChanged",
2564
+ "type": "event"
2565
+ }, {
2566
+ "anonymous": false,
2567
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "delegate", "type": "address" }, {
2568
+ "indexed": false,
2569
+ "internalType": "uint256",
2570
+ "name": "previousVotes",
2571
+ "type": "uint256"
2572
+ }, { "indexed": false, "internalType": "uint256", "name": "newVotes", "type": "uint256" }],
2573
+ "name": "DelegateVotesChanged",
2574
+ "type": "event"
2575
+ }, { "anonymous": false, "inputs": [], "name": "EIP712DomainChanged", "type": "event" }, {
2576
+ "anonymous": false,
2577
+ "inputs": [{ "indexed": false, "internalType": "uint64", "name": "version", "type": "uint64" }],
2578
+ "name": "Initialized",
2579
+ "type": "event"
2580
+ }, {
2581
+ "anonymous": false,
2582
+ "inputs": [{
2583
+ "indexed": true,
2584
+ "internalType": "address",
2585
+ "name": "previousOwner",
2586
+ "type": "address"
2587
+ }, { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" }],
2588
+ "name": "OwnershipTransferred",
2589
+ "type": "event"
2590
+ }, {
2591
+ "anonymous": false,
2592
+ "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }],
2593
+ "name": "Paused",
2594
+ "type": "event"
2595
+ }, {
2596
+ "anonymous": false,
2597
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "from", "type": "address" }, {
2598
+ "indexed": true,
2599
+ "internalType": "address",
2600
+ "name": "to",
2601
+ "type": "address"
2602
+ }, { "indexed": false, "internalType": "uint256", "name": "value", "type": "uint256" }],
2603
+ "name": "Transfer",
2604
+ "type": "event"
2605
+ }, {
2606
+ "anonymous": false,
2607
+ "inputs": [{ "indexed": false, "internalType": "address", "name": "account", "type": "address" }],
2608
+ "name": "Unpaused",
2609
+ "type": "event"
2610
+ }, {
2611
+ "anonymous": false,
2612
+ "inputs": [{ "indexed": true, "internalType": "address", "name": "implementation", "type": "address" }],
2613
+ "name": "Upgraded",
2614
+ "type": "event"
2615
+ }, {
2616
+ "inputs": [],
2617
+ "name": "CLOCK_MODE",
2618
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
2619
+ "stateMutability": "view",
2620
+ "type": "function"
2621
+ }, {
2622
+ "inputs": [],
2623
+ "name": "DOMAIN_SEPARATOR",
2624
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
2625
+ "stateMutability": "view",
2626
+ "type": "function"
2627
+ }, {
2628
+ "inputs": [],
2629
+ "name": "UPGRADE_INTERFACE_VERSION",
2630
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
2631
+ "stateMutability": "view",
2632
+ "type": "function"
2633
+ }, {
2634
+ "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }, {
2635
+ "internalType": "address",
2636
+ "name": "spender",
2637
+ "type": "address"
2638
+ }],
2639
+ "name": "allowance",
2640
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2641
+ "stateMutability": "view",
2642
+ "type": "function"
2643
+ }, {
2644
+ "inputs": [{ "internalType": "address", "name": "spender", "type": "address" }, {
2645
+ "internalType": "uint256",
2646
+ "name": "value",
2647
+ "type": "uint256"
2648
+ }],
2649
+ "name": "approve",
2650
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
2651
+ "stateMutability": "nonpayable",
2652
+ "type": "function"
2653
+ }, {
2654
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
2655
+ "name": "balanceOf",
2656
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2657
+ "stateMutability": "view",
2658
+ "type": "function"
2659
+ }, {
2660
+ "inputs": [{ "internalType": "uint256", "name": "value", "type": "uint256" }],
2661
+ "name": "burn",
2662
+ "outputs": [],
2663
+ "stateMutability": "nonpayable",
2664
+ "type": "function"
2665
+ }, {
2666
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, {
2667
+ "internalType": "uint256",
2668
+ "name": "value",
2669
+ "type": "uint256"
2670
+ }],
2671
+ "name": "burnFrom",
2672
+ "outputs": [],
2673
+ "stateMutability": "nonpayable",
2674
+ "type": "function"
2675
+ }, {
2676
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, {
2677
+ "internalType": "uint32",
2678
+ "name": "pos",
2679
+ "type": "uint32"
2680
+ }],
2681
+ "name": "checkpoints",
2682
+ "outputs": [{
2683
+ "components": [{
2684
+ "internalType": "uint48",
2685
+ "name": "_key",
2686
+ "type": "uint48"
2687
+ }, { "internalType": "uint208", "name": "_value", "type": "uint208" }],
2688
+ "internalType": "struct Checkpoints.Checkpoint208",
2689
+ "name": "",
2690
+ "type": "tuple"
2691
+ }],
2692
+ "stateMutability": "view",
2693
+ "type": "function"
2694
+ }, {
2695
+ "inputs": [],
2696
+ "name": "clock",
2697
+ "outputs": [{ "internalType": "uint48", "name": "", "type": "uint48" }],
2698
+ "stateMutability": "view",
2699
+ "type": "function"
2700
+ }, {
2701
+ "inputs": [],
2702
+ "name": "decimals",
2703
+ "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }],
2704
+ "stateMutability": "view",
2705
+ "type": "function"
2706
+ }, {
2707
+ "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }],
2708
+ "name": "delegate",
2709
+ "outputs": [],
2710
+ "stateMutability": "nonpayable",
2711
+ "type": "function"
2712
+ }, {
2713
+ "inputs": [{ "internalType": "address", "name": "delegatee", "type": "address" }, {
2714
+ "internalType": "uint256",
2715
+ "name": "nonce",
2716
+ "type": "uint256"
2717
+ }, { "internalType": "uint256", "name": "expiry", "type": "uint256" }, {
2718
+ "internalType": "uint8",
2719
+ "name": "v",
2720
+ "type": "uint8"
2721
+ }, { "internalType": "bytes32", "name": "r", "type": "bytes32" }, {
2722
+ "internalType": "bytes32",
2723
+ "name": "s",
2724
+ "type": "bytes32"
2725
+ }],
2726
+ "name": "delegateBySig",
2727
+ "outputs": [],
2728
+ "stateMutability": "nonpayable",
2729
+ "type": "function"
2730
+ }, {
2731
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
2732
+ "name": "delegates",
2733
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
2734
+ "stateMutability": "view",
2735
+ "type": "function"
2736
+ }, {
2737
+ "inputs": [],
2738
+ "name": "eip712Domain",
2739
+ "outputs": [{ "internalType": "bytes1", "name": "fields", "type": "bytes1" }, {
2740
+ "internalType": "string",
2741
+ "name": "name",
2742
+ "type": "string"
2743
+ }, { "internalType": "string", "name": "version", "type": "string" }, {
2744
+ "internalType": "uint256",
2745
+ "name": "chainId",
2746
+ "type": "uint256"
2747
+ }, { "internalType": "address", "name": "verifyingContract", "type": "address" }, {
2748
+ "internalType": "bytes32",
2749
+ "name": "salt",
2750
+ "type": "bytes32"
2751
+ }, { "internalType": "uint256[]", "name": "extensions", "type": "uint256[]" }],
2752
+ "stateMutability": "view",
2753
+ "type": "function"
2754
+ }, {
2755
+ "inputs": [{ "internalType": "uint256", "name": "timepoint", "type": "uint256" }],
2756
+ "name": "getPastTotalSupply",
2757
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2758
+ "stateMutability": "view",
2759
+ "type": "function"
2760
+ }, {
2761
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }, {
2762
+ "internalType": "uint256",
2763
+ "name": "timepoint",
2764
+ "type": "uint256"
2765
+ }],
2766
+ "name": "getPastVotes",
2767
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2768
+ "stateMutability": "view",
2769
+ "type": "function"
2770
+ }, {
2771
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
2772
+ "name": "getVotes",
2773
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2774
+ "stateMutability": "view",
2775
+ "type": "function"
2776
+ }, {
2777
+ "inputs": [{ "internalType": "address", "name": "initialOwner", "type": "address" }],
2778
+ "name": "initialize",
2779
+ "outputs": [],
2780
+ "stateMutability": "nonpayable",
2781
+ "type": "function"
2782
+ }, {
2783
+ "inputs": [{ "internalType": "address", "name": "to", "type": "address" }, {
2784
+ "internalType": "uint256",
2785
+ "name": "amount",
2786
+ "type": "uint256"
2787
+ }],
2788
+ "name": "mint",
2789
+ "outputs": [],
2790
+ "stateMutability": "nonpayable",
2791
+ "type": "function"
2792
+ }, {
2793
+ "inputs": [],
2794
+ "name": "name",
2795
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
2796
+ "stateMutability": "view",
2797
+ "type": "function"
2798
+ }, {
2799
+ "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }],
2800
+ "name": "nonces",
2801
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2802
+ "stateMutability": "view",
2803
+ "type": "function"
2804
+ }, {
2805
+ "inputs": [{ "internalType": "address", "name": "account", "type": "address" }],
2806
+ "name": "numCheckpoints",
2807
+ "outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }],
2808
+ "stateMutability": "view",
2809
+ "type": "function"
2810
+ }, {
2811
+ "inputs": [],
2812
+ "name": "owner",
2813
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
2814
+ "stateMutability": "view",
2815
+ "type": "function"
2816
+ }, {
2817
+ "inputs": [],
2818
+ "name": "pause",
2819
+ "outputs": [],
2820
+ "stateMutability": "nonpayable",
2821
+ "type": "function"
2822
+ }, {
2823
+ "inputs": [],
2824
+ "name": "paused",
2825
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
2826
+ "stateMutability": "view",
2827
+ "type": "function"
2828
+ }, {
2829
+ "inputs": [{ "internalType": "address", "name": "owner", "type": "address" }, {
2830
+ "internalType": "address",
2831
+ "name": "spender",
2832
+ "type": "address"
2833
+ }, { "internalType": "uint256", "name": "value", "type": "uint256" }, {
2834
+ "internalType": "uint256",
2835
+ "name": "deadline",
2836
+ "type": "uint256"
2837
+ }, { "internalType": "uint8", "name": "v", "type": "uint8" }, {
2838
+ "internalType": "bytes32",
2839
+ "name": "r",
2840
+ "type": "bytes32"
2841
+ }, { "internalType": "bytes32", "name": "s", "type": "bytes32" }],
2842
+ "name": "permit",
2843
+ "outputs": [],
2844
+ "stateMutability": "nonpayable",
2845
+ "type": "function"
2846
+ }, {
2847
+ "inputs": [],
2848
+ "name": "proxiableUUID",
2849
+ "outputs": [{ "internalType": "bytes32", "name": "", "type": "bytes32" }],
2850
+ "stateMutability": "view",
2851
+ "type": "function"
2852
+ }, {
2853
+ "inputs": [],
2854
+ "name": "renounceOwnership",
2855
+ "outputs": [],
2856
+ "stateMutability": "nonpayable",
2857
+ "type": "function"
2858
+ }, {
2859
+ "inputs": [],
2860
+ "name": "symbol",
2861
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
2862
+ "stateMutability": "view",
2863
+ "type": "function"
2864
+ }, {
2865
+ "inputs": [],
2866
+ "name": "totalSupply",
2867
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
2868
+ "stateMutability": "view",
2869
+ "type": "function"
2870
+ }, {
2871
+ "inputs": [{ "internalType": "address", "name": "to", "type": "address" }, {
2872
+ "internalType": "uint256",
2873
+ "name": "value",
2874
+ "type": "uint256"
2875
+ }],
2876
+ "name": "transfer",
2877
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
2878
+ "stateMutability": "nonpayable",
2879
+ "type": "function"
2880
+ }, {
2881
+ "inputs": [{ "internalType": "address", "name": "from", "type": "address" }, {
2882
+ "internalType": "address",
2883
+ "name": "to",
2884
+ "type": "address"
2885
+ }, { "internalType": "uint256", "name": "value", "type": "uint256" }],
2886
+ "name": "transferFrom",
2887
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
2888
+ "stateMutability": "nonpayable",
2889
+ "type": "function"
2890
+ }, {
2891
+ "inputs": [{ "internalType": "address", "name": "newOwner", "type": "address" }],
2892
+ "name": "transferOwnership",
2893
+ "outputs": [],
2894
+ "stateMutability": "nonpayable",
2895
+ "type": "function"
2896
+ }, {
2897
+ "inputs": [],
2898
+ "name": "unpause",
2899
+ "outputs": [],
2900
+ "stateMutability": "nonpayable",
2901
+ "type": "function"
2902
+ }, {
2903
+ "inputs": [{
2904
+ "internalType": "address",
2905
+ "name": "newImplementation",
2906
+ "type": "address"
2907
+ }, { "internalType": "bytes", "name": "data", "type": "bytes" }],
2908
+ "name": "upgradeToAndCall",
2909
+ "outputs": [],
2910
+ "stateMutability": "payable",
2911
+ "type": "function"
2912
+ }];
1281
2913
  var LOCAL_ERRORS = [
1282
2914
  ...KIBBLE_TOKEN_ABI.filter((item) => item.type === "error"),
1283
2915
  ...ORGANIZATION_IMPL_ABI.filter((item) => item.type === "error"),
@@ -1293,8 +2925,42 @@ var OZ_ERROR_FRAGMENTS = [
1293
2925
  var ERROR_ABI = [...LOCAL_ERRORS, (0, import_viem.parseAbi)([...OZ_ERROR_FRAGMENTS])];
1294
2926
  var ORG_FUNCTION = "executeCall";
1295
2927
 
2928
+ // src/utils/coinbase/useCoinbaseMintAnymalNFT.ts
2929
+ var import_react11 = require("react");
2930
+ function useCoinbaseMintAnymalNFT() {
2931
+ const { sendOperationFn, status } = useSendCoinbaseUserOperation();
2932
+ return (0, import_react11.useCallback)(
2933
+ async (evmAddress, pid, nftId, anymalTxId, validationContractAddress) => {
2934
+ if (!nftId || !pid || !validationContractAddress) {
2935
+ return {
2936
+ success: false,
2937
+ message: "Missing authentication token OR NFT ID.",
2938
+ status: "error"
2939
+ };
2940
+ }
2941
+ const functionName = "submitMetadataByCampaignName";
2942
+ const args = [
2943
+ pid,
2944
+ nftId,
2945
+ `https://dev-nft.petastic.com/metadata/${nftId}`,
2946
+ "petastic-signup-campaign-1",
2947
+ anymalTxId
2948
+ ];
2949
+ const callData = (0, import_viem2.encodeFunctionData)({
2950
+ abi: PET_NFT_ABI,
2951
+ functionName,
2952
+ args
2953
+ });
2954
+ await sendOperationFn(evmAddress, callData, validationContractAddress);
2955
+ return { success: true, message: "Pet Passport Created", status };
2956
+ },
2957
+ []
2958
+ );
2959
+ }
2960
+
1296
2961
  // src/utils/anymals/useMintAnymalNFT.ts
1297
- var import_react10 = require("react");
2962
+ var import_viem4 = require("viem");
2963
+ var import_react12 = require("react");
1298
2964
 
1299
2965
  // src/helpers/GasEstimateHelper.tsx
1300
2966
  async function applyBundlerGasEstimator(account, bundlerClient, options) {
@@ -1338,18 +3004,18 @@ async function applyBundlerGasEstimator(account, bundlerClient, options) {
1338
3004
  }
1339
3005
 
1340
3006
  // src/helpers/HumanRevert.tsx
1341
- var import_viem2 = require("viem");
3007
+ var import_viem3 = require("viem");
1342
3008
  function humanRevert(raw, shortMessage) {
1343
3009
  if (!raw) return shortMessage ?? "Simulation reverted";
1344
3010
  try {
1345
- const { errorName, args } = (0, import_viem2.decodeErrorResult)({
3011
+ const { errorName, args } = (0, import_viem3.decodeErrorResult)({
1346
3012
  abi: ERROR_ABI,
1347
3013
  data: raw
1348
3014
  });
1349
3015
  return `${errorName}(${args.map(String).join(", ")})`;
1350
3016
  } catch {
1351
3017
  if (raw.startsWith("0x08c379a0") && raw.length >= 138) {
1352
- return (0, import_viem2.hexToString)(`0x${raw.slice(138)}`);
3018
+ return (0, import_viem3.hexToString)(`0x${raw.slice(138)}`);
1353
3019
  }
1354
3020
  return `${raw.slice(0, 10)}\u2026`;
1355
3021
  }
@@ -1375,7 +3041,7 @@ async function simulateCall(publicClient, target, abi, functionName, args, calle
1375
3041
 
1376
3042
  // src/utils/anymals/useMintAnymalNFT.ts
1377
3043
  function useMintAnymalNFT() {
1378
- return (0, import_react10.useCallback)(
3044
+ return (0, import_react12.useCallback)(
1379
3045
  async (pid, nftId, anymalTxId, dbAuthToken, validationContractAddress, smartAccount, bundlerClient) => {
1380
3046
  if (!dbAuthToken || !nftId || !bundlerClient || !smartAccount || !pid || !validationContractAddress) {
1381
3047
  return {
@@ -1391,7 +3057,7 @@ function useMintAnymalNFT() {
1391
3057
  "petastic-signup-campaign-1",
1392
3058
  anymalTxId
1393
3059
  ];
1394
- const callData = (0, import_viem3.encodeFunctionData)({
3060
+ const callData = (0, import_viem4.encodeFunctionData)({
1395
3061
  abi: PET_NFT_ABI,
1396
3062
  functionName,
1397
3063
  args
@@ -1426,126 +3092,11 @@ function useMintAnymalNFT() {
1426
3092
  );
1427
3093
  }
1428
3094
 
1429
- // src/utils/anymals/useAddAnymalToDatabase.ts
1430
- var import_react11 = require("react");
1431
- function useAddAnymalToDatabase() {
1432
- return (0, import_react11.useCallback)(
1433
- async (dbAuthToken, endpoint, anymalData) => {
1434
- if (!dbAuthToken) {
1435
- return {
1436
- success: false,
1437
- message: "Authentication token is missing.",
1438
- _docID: null,
1439
- dbCid: null
1440
- };
1441
- }
1442
- let anymalDocID = null;
1443
- let dbCid = null;
1444
- try {
1445
- const mutation = `
1446
- mutation Create_Anymal($input: [AnymalMutationInputArg!]) {
1447
- create_Anymal(input: $input) {
1448
- _docID
1449
- name
1450
- passportID
1451
- _version {
1452
- cid
1453
- }
1454
- }
1455
- }
1456
- `;
1457
- const response = await fetch(endpoint, {
1458
- method: "POST",
1459
- headers: {
1460
- "Content-Type": "application/json",
1461
- Authorization: `Bearer ${dbAuthToken}`
1462
- },
1463
- body: JSON.stringify({
1464
- query: mutation,
1465
- variables: { input: [anymalData] }
1466
- })
1467
- });
1468
- if (!response.ok) {
1469
- throw new Error(
1470
- `Failed to create pet. HTTP status ${response.status}`
1471
- );
1472
- }
1473
- const { data, errors } = await response.json();
1474
- if (errors) {
1475
- const errorMessage = JSON.stringify(errors);
1476
- if (errorMessage.includes("given ID already exists")) {
1477
- console.warn("Duplicate document ID detected.");
1478
- anymalDocID = data?.create_Anymal[0]?._docID || null;
1479
- throw new Error("Document with the given ID already exists.");
1480
- }
1481
- throw new Error(`GraphQL error: ${errorMessage}`);
1482
- }
1483
- anymalDocID = data.create_Anymal[0]._docID;
1484
- dbCid = data.create_Anymal[0]._version[0].cid;
1485
- return {
1486
- success: true,
1487
- _docID: anymalDocID,
1488
- dbCid,
1489
- message: "Anymal added to account"
1490
- };
1491
- } catch (error) {
1492
- return {
1493
- success: false,
1494
- _docID: null,
1495
- dbCid: null,
1496
- message: "Error adding anymal to account"
1497
- };
1498
- }
1499
- },
1500
- []
1501
- );
1502
- }
1503
-
1504
- // src/utils/anymals/useDeleteAnymalFromDatabase.ts
1505
- var import_react12 = require("react");
1506
- function useDeleteAnymalFromDatabase() {
1507
- return (0, import_react12.useCallback)(
1508
- async (dbAuthToken, endpoint, anymalDocID) => {
1509
- if (!dbAuthToken || !endpoint || !anymalDocID) return;
1510
- try {
1511
- const mutation = `
1512
- mutation Delete_Anymal($docId: [ID]) {
1513
- delete_Anymal(docID: $docId) {
1514
- _docID
1515
- }
1516
- }
1517
- `;
1518
- const response = await fetch(endpoint, {
1519
- method: "POST",
1520
- headers: {
1521
- "Content-Type": "application/json",
1522
- Authorization: `Bearer ${dbAuthToken}`
1523
- },
1524
- body: JSON.stringify({
1525
- query: mutation,
1526
- variables: { docID: [anymalDocID] }
1527
- })
1528
- });
1529
- if (!response.ok)
1530
- throw new Error(
1531
- `Failed to delete anymal. HTTP status ${response.status}`
1532
- );
1533
- const { errors } = await response.json();
1534
- if (errors) throw new Error(`GraphQL error: ${JSON.stringify(errors)}`);
1535
- } catch (error) {
1536
- console.error("Error deleting anymal from database:", error);
1537
- throw error;
1538
- }
1539
- },
1540
- []
1541
- );
1542
- }
1543
-
1544
3095
  // src/utils/anymals/useSaveAnymalMetadata.ts
1545
3096
  var import_react13 = require("react");
1546
3097
  function useSaveAnymalMetadata() {
1547
3098
  return (0, import_react13.useCallback)(
1548
- async (userPid, anymalTxId, idToken, publicKey, nftMetadataInput, authServiceBaseUrl) => {
3099
+ async (userPid, anymalTxId, idToken, nftMetadataInput, authServiceBaseUrl) => {
1549
3100
  const response = await fetch(`${authServiceBaseUrl}/process-nft`, {
1550
3101
  method: "POST",
1551
3102
  headers: {
@@ -1553,7 +3104,6 @@ function useSaveAnymalMetadata() {
1553
3104
  Authorization: "Bearer " + idToken
1554
3105
  },
1555
3106
  body: JSON.stringify({
1556
- appPubKey: publicKey,
1557
3107
  nftMetadataInput,
1558
3108
  pid: userPid,
1559
3109
  anymalTxId
@@ -1572,57 +3122,8 @@ function useSaveAnymalMetadata() {
1572
3122
  );
1573
3123
  }
1574
3124
 
1575
- // src/utils/anymals/useUpdateAnymalWithNFT.ts
1576
- var import_react14 = require("react");
1577
- function useUpdateAnymalWithNFT() {
1578
- return (0, import_react14.useCallback)(
1579
- async (anymalPassportId, anymalDocId, dbAuthToken, endpoint) => {
1580
- if (!dbAuthToken || !anymalPassportId || !anymalDocId || !endpoint) {
1581
- return {
1582
- success: false
1583
- };
1584
- }
1585
- try {
1586
- const mutation = `
1587
- mutation {
1588
- update_Anymal(
1589
- docID: [${JSON.stringify(anymalDocId)}],
1590
- input: {
1591
- passportID: "${anymalPassportId}"
1592
- }
1593
- ) {
1594
- passportID
1595
- }
1596
- }
1597
- `;
1598
- const response = await fetch(endpoint, {
1599
- method: "POST",
1600
- headers: {
1601
- "Content-Type": "application/json",
1602
- Authorization: `Bearer ${dbAuthToken}`
1603
- },
1604
- body: JSON.stringify({ query: mutation })
1605
- });
1606
- if (!response.ok) {
1607
- return { success: false };
1608
- }
1609
- const { errors } = await response.json();
1610
- if (errors) {
1611
- console.log(`GQL error: ${JSON.stringify(errors)}`);
1612
- return { success: false };
1613
- }
1614
- return { success: true };
1615
- } catch (error) {
1616
- console.error("Error updating Anymal with NFT ID:", error);
1617
- return { success: false };
1618
- }
1619
- },
1620
- []
1621
- );
1622
- }
1623
-
1624
3125
  // src/utils/anymals/useUploadAnymalImage.ts
1625
- var import_react15 = require("react");
3126
+ var import_react14 = require("react");
1626
3127
 
1627
3128
  // src/helpers/UploadImageHelper.tsx
1628
3129
  function resizeImage(file, maxWidth = 800, maxHeight = 800, quality = 0.7) {
@@ -1679,8 +3180,8 @@ function toBase64(file) {
1679
3180
 
1680
3181
  // src/utils/anymals/useUploadAnymalImage.ts
1681
3182
  function useUploadAnymalImage() {
1682
- return (0, import_react15.useCallback)(
1683
- async (imageFile, type, idToken, publicKey, authServiceBaseUrl, petType, breed, lifestage, anymalPid) => {
3183
+ return (0, import_react14.useCallback)(
3184
+ async (imageFile, type, idToken, authServiceBaseUrl, petType, breed, lifestage, anymalPid) => {
1684
3185
  if (!imageFile || !idToken) {
1685
3186
  return {
1686
3187
  success: false,
@@ -1692,7 +3193,6 @@ function useUploadAnymalImage() {
1692
3193
  try {
1693
3194
  const base64Image = await prepareImage(imageFile);
1694
3195
  const payload = {
1695
- appPubKey: publicKey,
1696
3196
  imageData: base64Image,
1697
3197
  imageName: imageFile.name.split(".")[0],
1698
3198
  petType,
@@ -1740,68 +3240,11 @@ function useUploadAnymalImage() {
1740
3240
  );
1741
3241
  }
1742
3242
 
1743
- // src/utils/anymals/useFetchAnymals.ts
1744
- var import_react16 = require("react");
1745
-
1746
- // src/utils/anymals/fetchAnymals.ts
1747
- async function fetchAnymals({
1748
- dbAuthToken,
1749
- endpoint,
1750
- userPid
1751
- }) {
1752
- const query = `
1753
- query Anymal($filter: AnymalFilterArg, $order: [AnymalOrderArg]) {
1754
- Anymal(filter: $filter, order: $order) {
1755
- _docID
1756
- name
1757
- breed
1758
- passportID
1759
- profileImageUrl
1760
- caregiverNearId
1761
- caregiverId
1762
- lifestage
1763
- gender
1764
- petType
1765
- products
1766
- timeAddedUtc
1767
- }
1768
- }
1769
- `;
1770
- const variables = {
1771
- filter: {
1772
- caregiverId: { _eq: userPid }
1773
- },
1774
- order: [
1775
- {
1776
- timeAddedUtc: "ASC"
1777
- }
1778
- ]
1779
- };
1780
- const response = await fetch(endpoint, {
1781
- method: "POST",
1782
- headers: {
1783
- "Content-Type": "application/json",
1784
- Authorization: `Bearer ${dbAuthToken}`
1785
- },
1786
- body: JSON.stringify({ query, variables })
1787
- });
1788
- if (!response.ok) {
1789
- throw new Error(`HTTP error! Status: ${response.status}`);
1790
- }
1791
- const data = await response.json();
1792
- return data?.data?.Anymal ?? [];
1793
- }
1794
-
1795
- // src/utils/anymals/useFetchAnymals.ts
1796
- function useFetchAnymals() {
1797
- return (0, import_react16.useCallback)(fetchAnymals, []);
1798
- }
1799
-
1800
3243
  // src/utils/marketplace/useProcessPartialKibblePayment.ts
1801
- var import_react17 = require("react");
3244
+ var import_react15 = require("react");
1802
3245
 
1803
3246
  // src/helpers/ProcessDirectPartialPayment.tsx
1804
- var import_viem4 = require("viem");
3247
+ var import_viem5 = require("viem");
1805
3248
 
1806
3249
  // src/helpers/SendUserOpWithRetries.tsx
1807
3250
  async function sendUserOpWithRetries(bundlerClient, params, retries = 3, delay = 1e3) {
@@ -1861,7 +3304,7 @@ async function processDirectPartialPayment(marketplaceContract, smartAccount, bu
1861
3304
  deadline,
1862
3305
  backendSignature
1863
3306
  ];
1864
- const partialPayCalldata = (0, import_viem4.encodeFunctionData)({
3307
+ const partialPayCalldata = (0, import_viem5.encodeFunctionData)({
1865
3308
  abi: MARKETPLACE_ABI,
1866
3309
  functionName,
1867
3310
  args
@@ -1898,7 +3341,7 @@ async function processDirectPartialPayment(marketplaceContract, smartAccount, bu
1898
3341
 
1899
3342
  // src/utils/marketplace/useProcessPartialKibblePayment.ts
1900
3343
  function useProcessPartialKibblePayment() {
1901
- return (0, import_react17.useCallback)(
3344
+ return (0, import_react15.useCallback)(
1902
3345
  async (pid, nftId, orderId, dbAuthToken, marketplaceContract, smartAccount, bundlerClient, amountInTokens, maxTokenPayment, nonce, deadline, backendSignature) => {
1903
3346
  if (!orderId || !dbAuthToken || !nftId || !bundlerClient || !smartAccount || !pid || !marketplaceContract || !amountInTokens || !maxTokenPayment || !nonce || !deadline) {
1904
3347
  return {
@@ -1954,23 +3397,23 @@ function useProcessPartialKibblePayment() {
1954
3397
  }
1955
3398
 
1956
3399
  // src/utils/marketplace/useApproveKibbleToken.ts
1957
- var import_react18 = require("react");
3400
+ var import_react16 = require("react");
1958
3401
 
1959
3402
  // src/helpers/ProcessDirectKibbleApproval.tsx
1960
- var import_viem5 = require("viem");
3403
+ var import_viem6 = require("viem");
1961
3404
  async function processDirectKibbleApproval(kibbleTokenAddress, spenderAddress, smartAccount, bundlerClient, approveAmount) {
1962
3405
  try {
1963
3406
  const functionName = "approve";
1964
3407
  const args = [spenderAddress, approveAmount];
1965
- const approveCalldata = (0, import_viem5.encodeFunctionData)({
1966
- abi: import_viem5.erc20Abi,
3408
+ const approveCalldata = (0, import_viem6.encodeFunctionData)({
3409
+ abi: import_viem6.erc20Abi,
1967
3410
  functionName,
1968
3411
  args
1969
3412
  });
1970
3413
  await simulateCall(
1971
3414
  bundlerClient.client,
1972
3415
  kibbleTokenAddress,
1973
- import_viem5.erc20Abi,
3416
+ import_viem6.erc20Abi,
1974
3417
  functionName,
1975
3418
  args,
1976
3419
  smartAccount.address
@@ -1999,7 +3442,7 @@ async function processDirectKibbleApproval(kibbleTokenAddress, spenderAddress, s
1999
3442
 
2000
3443
  // src/utils/marketplace/useApproveKibbleToken.ts
2001
3444
  function useApproveKibbleToken() {
2002
- return (0, import_react18.useCallback)(
3445
+ return (0, import_react16.useCallback)(
2003
3446
  async (kibbleTokenAddress, marketplaceContract, amount, smartAccount, bundlerClient) => {
2004
3447
  try {
2005
3448
  const result = await processDirectKibbleApproval(
@@ -2026,10 +3469,10 @@ function useApproveKibbleToken() {
2026
3469
  }
2027
3470
 
2028
3471
  // src/utils/organization/useCreateOrganizationBase.ts
2029
- var import_react19 = require("react");
2030
- var import_viem6 = require("viem");
3472
+ var import_react17 = require("react");
3473
+ var import_viem7 = require("viem");
2031
3474
  function useCreateOrganizationBase() {
2032
- return (0, import_react19.useCallback)(
3475
+ return (0, import_react17.useCallback)(
2033
3476
  /**
2034
3477
  * Creates a new organization on-chain.
2035
3478
  *
@@ -2051,7 +3494,7 @@ function useCreateOrganizationBase() {
2051
3494
  try {
2052
3495
  const functionName = "createOrganizationProxy";
2053
3496
  const args = [ownerAddress, orgName, orgPid];
2054
- const callData = (0, import_viem6.encodeFunctionData)({
3497
+ const callData = (0, import_viem7.encodeFunctionData)({
2055
3498
  abi: ORGANIZATION_BEACON_ABI,
2056
3499
  functionName,
2057
3500
  args
@@ -2089,7 +3532,7 @@ function useCreateOrganizationBase() {
2089
3532
  let proxyAddress;
2090
3533
  for (const log of txReceipt.logs) {
2091
3534
  try {
2092
- const decoded = (0, import_viem6.decodeEventLog)({
3535
+ const decoded = (0, import_viem7.decodeEventLog)({
2093
3536
  abi: ORGANIZATION_BEACON_ABI,
2094
3537
  data: log.data,
2095
3538
  topics: log.topics
@@ -2125,13 +3568,13 @@ function useCreateOrganizationBase() {
2125
3568
  }
2126
3569
 
2127
3570
  // src/utils/organization/useApproveOrgKibbleToken.ts
2128
- var import_react20 = require("react");
3571
+ var import_react18 = require("react");
2129
3572
 
2130
3573
  // src/helpers/ProcessOrgKibbleApproval.tsx
2131
- var import_viem8 = require("viem");
3574
+ var import_viem9 = require("viem");
2132
3575
 
2133
3576
  // src/helpers/WaitForAllowance.tsx
2134
- var import_viem7 = require("viem");
3577
+ var import_viem8 = require("viem");
2135
3578
  async function waitForAllowance(publicClient, tokenAddress, ownerAddress, spenderAddress, expectedAmount) {
2136
3579
  const MAX_RETRIES = 10;
2137
3580
  const RETRY_INTERVAL = 2e3;
@@ -2140,7 +3583,7 @@ async function waitForAllowance(publicClient, tokenAddress, ownerAddress, spende
2140
3583
  try {
2141
3584
  const currentAllowance = await publicClient.readContract({
2142
3585
  address: tokenAddress,
2143
- abi: import_viem7.erc20Abi,
3586
+ abi: import_viem8.erc20Abi,
2144
3587
  functionName: "allowance",
2145
3588
  args: [ownerAddress, spenderAddress]
2146
3589
  });
@@ -2165,13 +3608,13 @@ async function processOrgKibbleApproval(orgContractAddress, kibbleTokenAddress,
2165
3608
  if (approveAmount <= 0n) {
2166
3609
  return { success: false, message: "Approval amount must be greater than zero." };
2167
3610
  }
2168
- const approveCalldata = (0, import_viem8.encodeFunctionData)({
2169
- abi: import_viem8.erc20Abi,
3611
+ const approveCalldata = (0, import_viem9.encodeFunctionData)({
3612
+ abi: import_viem9.erc20Abi,
2170
3613
  functionName: "approve",
2171
3614
  args: [partialPaymentModuleAddress, approveAmount]
2172
3615
  });
2173
3616
  const args = [kibbleTokenAddress, approveCalldata];
2174
- const executeApproveCalldata = (0, import_viem8.encodeFunctionData)({
3617
+ const executeApproveCalldata = (0, import_viem9.encodeFunctionData)({
2175
3618
  abi: ORGANIZATION_IMPL_ABI,
2176
3619
  functionName: ORG_FUNCTION,
2177
3620
  args
@@ -2223,7 +3666,7 @@ async function processOrgKibbleApproval(orgContractAddress, kibbleTokenAddress,
2223
3666
 
2224
3667
  // src/utils/organization/useApproveOrgKibbleToken.ts
2225
3668
  function useApproveOrgPartialPayment() {
2226
- return (0, import_react20.useCallback)(
3669
+ return (0, import_react18.useCallback)(
2227
3670
  async (orgContractAddress, kibbleTokenAddress, partialPaymentModuleAddress, managerSmartAccount, bundlerClient, approveAmount) => {
2228
3671
  if (!orgContractAddress || !kibbleTokenAddress || !partialPaymentModuleAddress || !managerSmartAccount || !bundlerClient || !approveAmount) {
2229
3672
  return {
@@ -2255,13 +3698,13 @@ function useApproveOrgPartialPayment() {
2255
3698
  }
2256
3699
 
2257
3700
  // src/utils/organization/useProcessOrgPartialKibblePayment.ts
2258
- var import_react21 = require("react");
3701
+ var import_react19 = require("react");
2259
3702
 
2260
3703
  // src/helpers/ProcessOrgPartialPayment.tsx
2261
- var import_viem9 = require("viem");
3704
+ var import_viem10 = require("viem");
2262
3705
  async function processOrgPartialPayment(orgContractAddress, partialPaymentModuleAddress, managerSmartAccount, bundlerClient, orderId, anymalNftId, pid, amountInTokens, maxTokenPayment, nonce, deadline, backendSignature) {
2263
3706
  try {
2264
- const partialPayCalldata = (0, import_viem9.encodeFunctionData)({
3707
+ const partialPayCalldata = (0, import_viem10.encodeFunctionData)({
2265
3708
  abi: MARKETPLACE_ABI,
2266
3709
  functionName: "partialPay",
2267
3710
  args: [
@@ -2276,7 +3719,7 @@ async function processOrgPartialPayment(orgContractAddress, partialPaymentModule
2276
3719
  ]
2277
3720
  });
2278
3721
  const args = [partialPaymentModuleAddress, partialPayCalldata];
2279
- const executePartialPayCalldata = (0, import_viem9.encodeFunctionData)({
3722
+ const executePartialPayCalldata = (0, import_viem10.encodeFunctionData)({
2280
3723
  abi: ORGANIZATION_IMPL_ABI,
2281
3724
  functionName: ORG_FUNCTION,
2282
3725
  args
@@ -2313,7 +3756,7 @@ async function processOrgPartialPayment(orgContractAddress, partialPaymentModule
2313
3756
 
2314
3757
  // src/utils/organization/useProcessOrgPartialKibblePayment.ts
2315
3758
  function useProcessOrgPartialKibblePayment() {
2316
- return (0, import_react21.useCallback)(
3759
+ return (0, import_react19.useCallback)(
2317
3760
  async (orgContractAddress, partialPaymentModuleAddress, managerSmartAccount, bundlerClient, orderId, anymalNftId, pid, amountInTokens, maxTokenPayment, nonce, deadline, backendSignature) => {
2318
3761
  if (!orgContractAddress || !partialPaymentModuleAddress || !managerSmartAccount || !bundlerClient || !orderId || !pid || !nonce || !backendSignature) {
2319
3762
  return {
@@ -2351,9 +3794,9 @@ function useProcessOrgPartialKibblePayment() {
2351
3794
  }
2352
3795
 
2353
3796
  // src/utils/organization/useUpdateOrgWalletAddress.ts
2354
- var import_react22 = require("react");
3797
+ var import_react20 = require("react");
2355
3798
  function useUpdateOrgWalletAddress() {
2356
- return (0, import_react22.useCallback)(
3799
+ return (0, import_react20.useCallback)(
2357
3800
  async (dbAuthToken, docID, baseWalletAddress, endpoint) => {
2358
3801
  try {
2359
3802
  const mutation = `
@@ -2392,10 +3835,10 @@ function useUpdateOrgWalletAddress() {
2392
3835
  }
2393
3836
 
2394
3837
  // src/utils/organization/useMintOrgAnymalNFT.ts
2395
- var import_viem10 = require("viem");
2396
- var import_react23 = require("react");
3838
+ var import_viem11 = require("viem");
3839
+ var import_react21 = require("react");
2397
3840
  function useMintOrgAnymalNFT() {
2398
- return (0, import_react23.useCallback)(
3841
+ return (0, import_react21.useCallback)(
2399
3842
  async (orgContractAddress, pid, nftId, anymalTxId, dbAuthToken, validationContractAddress, managerSmartAccount, bundlerClient) => {
2400
3843
  if (!dbAuthToken || !nftId || !bundlerClient || !managerSmartAccount || !pid || !validationContractAddress || !orgContractAddress) {
2401
3844
  return {
@@ -2411,13 +3854,13 @@ function useMintOrgAnymalNFT() {
2411
3854
  "petastic-signup-campaign-1",
2412
3855
  anymalTxId
2413
3856
  ];
2414
- const callData = (0, import_viem10.encodeFunctionData)({
3857
+ const callData = (0, import_viem11.encodeFunctionData)({
2415
3858
  abi: PET_NFT_ABI,
2416
3859
  functionName,
2417
3860
  args
2418
3861
  });
2419
3862
  const executeArgs = [validationContractAddress, callData];
2420
- const executeSubmitMetaCalldata = (0, import_viem10.encodeFunctionData)({
3863
+ const executeSubmitMetaCalldata = (0, import_viem11.encodeFunctionData)({
2421
3864
  abi: ORGANIZATION_IMPL_ABI,
2422
3865
  functionName: ORG_FUNCTION,
2423
3866
  args: executeArgs
@@ -2445,10 +3888,10 @@ function useMintOrgAnymalNFT() {
2445
3888
 
2446
3889
  // src/helpers/NonceHelper.tsx
2447
3890
  var import_uuid = require("uuid");
2448
- var import_viem11 = require("viem");
3891
+ var import_viem12 = require("viem");
2449
3892
  var generateBytes32Nonce = () => {
2450
3893
  const uuid3 = (0, import_uuid.v4)().replace(/-/g, "");
2451
- return (0, import_viem11.padHex)(`0x${uuid3}`, { size: 32 });
3894
+ return (0, import_viem12.padHex)(`0x${uuid3}`, { size: 32 });
2452
3895
  };
2453
3896
 
2454
3897
  // src/helpers/CryptoUtils.tsx
@@ -2658,9 +4101,9 @@ async function submitAction(idToken, pid, sourceType, payload, endpointBaseUrl)
2658
4101
  }
2659
4102
 
2660
4103
  // src/utils/actions/useFetchActions.ts
2661
- var import_react24 = require("react");
4104
+ var import_react22 = require("react");
2662
4105
  function useFetchActions() {
2663
- return (0, import_react24.useCallback)(
4106
+ return (0, import_react22.useCallback)(
2664
4107
  async (idToken, actionsServiceBaseUrl, pid, status, limit, offset) => {
2665
4108
  const params = new URLSearchParams({ pid });
2666
4109
  if (status) params.set("status", status);
@@ -2689,9 +4132,9 @@ function useFetchActions() {
2689
4132
  }
2690
4133
 
2691
4134
  // src/utils/actions/useFetchActionDefinitions.ts
2692
- var import_react25 = require("react");
4135
+ var import_react23 = require("react");
2693
4136
  function useFetchActionDefinitions() {
2694
- return (0, import_react25.useCallback)(
4137
+ return (0, import_react23.useCallback)(
2695
4138
  async (idToken, actionsServiceBaseUrl) => {
2696
4139
  try {
2697
4140
  const response = await fetch(
@@ -2788,10 +4231,10 @@ var convertToMultipleActionRecords = (frs) => frs.map(convertToActionRecord);
2788
4231
  var convertToMultipleActionDefinitions = (frs) => frs.map(convertToActionDefinition);
2789
4232
 
2790
4233
  // src/utils/application/useCreateUserAppData.ts
2791
- var import_react26 = require("react");
4234
+ var import_react24 = require("react");
2792
4235
  var import_uuid2 = require("uuid");
2793
4236
  function useCreateUserAppData() {
2794
- return (0, import_react26.useCallback)(
4237
+ return (0, import_react24.useCallback)(
2795
4238
  async (appId, pid, dbAuthToken, endpoint) => {
2796
4239
  if (!dbAuthToken || !pid || !dbAuthToken || !endpoint) return;
2797
4240
  const appValues = {
@@ -2846,10 +4289,10 @@ function useCreateUserAppData() {
2846
4289
  }
2847
4290
 
2848
4291
  // src/utils/application/useCreateOrganizationAppData.ts
2849
- var import_react27 = require("react");
4292
+ var import_react25 = require("react");
2850
4293
  var import_uuid3 = require("uuid");
2851
4294
  function useCreateOrganizationAppData() {
2852
- return (0, import_react27.useCallback)(
4295
+ return (0, import_react25.useCallback)(
2853
4296
  async (appId, pid, dbAuthToken, endpoint) => {
2854
4297
  if (!dbAuthToken || !pid || !dbAuthToken || !endpoint) return;
2855
4298
  const appValues = {
@@ -2903,17 +4346,17 @@ function useCreateOrganizationAppData() {
2903
4346
  }
2904
4347
 
2905
4348
  // src/utils/balance/useFetchBalance.ts
2906
- var import_react28 = require("react");
2907
- var import_viem12 = require("viem");
4349
+ var import_react26 = require("react");
4350
+ var import_viem13 = require("viem");
2908
4351
  function useFetchBalance() {
2909
- return (0, import_react28.useCallback)(
4352
+ return (0, import_react26.useCallback)(
2910
4353
  async (publicClient, walletAddress, kibbleTokenAddress) => {
2911
4354
  try {
2912
4355
  const balance = await publicClient.readContract({
2913
- address: (0, import_viem12.getAddress)(kibbleTokenAddress),
2914
- abi: import_viem12.erc20Abi,
4356
+ address: (0, import_viem13.getAddress)(kibbleTokenAddress),
4357
+ abi: import_viem13.erc20Abi,
2915
4358
  functionName: "balanceOf",
2916
- args: [(0, import_viem12.getAddress)(walletAddress)]
4359
+ args: [(0, import_viem13.getAddress)(walletAddress)]
2917
4360
  });
2918
4361
  return Number(balance);
2919
4362
  } catch (error) {
@@ -2925,10 +4368,10 @@ function useFetchBalance() {
2925
4368
  }
2926
4369
 
2927
4370
  // src/utils/actions/useClaimActionReward.ts
2928
- var import_viem13 = require("viem");
2929
- var import_react29 = require("react");
4371
+ var import_viem14 = require("viem");
4372
+ var import_react27 = require("react");
2930
4373
  function useClaimActionReward() {
2931
- return (0, import_react29.useCallback)(
4374
+ return (0, import_react27.useCallback)(
2932
4375
  async (actionId, claimIndex, rewardableActionContractAddress, smartAccount, bundlerClient) => {
2933
4376
  if (!actionId || claimIndex === void 0 || !bundlerClient || !smartAccount || !rewardableActionContractAddress) {
2934
4377
  return {
@@ -2938,7 +4381,7 @@ function useClaimActionReward() {
2938
4381
  }
2939
4382
  const args = [actionId, claimIndex];
2940
4383
  const functionName = "claimByIndex";
2941
- const callData = (0, import_viem13.encodeFunctionData)({
4384
+ const callData = (0, import_viem14.encodeFunctionData)({
2942
4385
  abi: REWARDABLE_ACTIONS_ABI,
2943
4386
  functionName,
2944
4387
  args
@@ -2974,10 +4417,10 @@ function useClaimActionReward() {
2974
4417
  }
2975
4418
 
2976
4419
  // src/utils/actions/useClaimOrgActionReward.ts
2977
- var import_viem14 = require("viem");
2978
- var import_react30 = require("react");
4420
+ var import_viem15 = require("viem");
4421
+ var import_react28 = require("react");
2979
4422
  function useClaimOrgActionReward() {
2980
- return (0, import_react30.useCallback)(
4423
+ return (0, import_react28.useCallback)(
2981
4424
  async (orgContractAddress, rewardableActionContractAddress, actionId, claimIndex, smartAccount, bundlerClient) => {
2982
4425
  if (!orgContractAddress || !actionId || claimIndex === void 0 || !bundlerClient || !smartAccount) {
2983
4426
  return {
@@ -2985,13 +4428,13 @@ function useClaimOrgActionReward() {
2985
4428
  message: "Missing web3auth account info or contract address."
2986
4429
  };
2987
4430
  }
2988
- const claimCallData = (0, import_viem14.encodeFunctionData)({
4431
+ const claimCallData = (0, import_viem15.encodeFunctionData)({
2989
4432
  abi: REWARDABLE_ACTIONS_ABI,
2990
4433
  functionName: "claimByIndex",
2991
4434
  args: [actionId, claimIndex]
2992
4435
  });
2993
4436
  const args = [rewardableActionContractAddress, claimCallData];
2994
- const executeClaimCalldata = (0, import_viem14.encodeFunctionData)({
4437
+ const executeClaimCalldata = (0, import_viem15.encodeFunctionData)({
2995
4438
  abi: ORGANIZATION_IMPL_ABI,
2996
4439
  functionName: ORG_FUNCTION,
2997
4440
  args
@@ -3027,9 +4470,9 @@ function useClaimOrgActionReward() {
3027
4470
  }
3028
4471
 
3029
4472
  // src/utils/actions/useSubmitContractAction.ts
3030
- var import_react31 = require("react");
4473
+ var import_react29 = require("react");
3031
4474
  function useSubmitContractAction() {
3032
- return (0, import_react31.useCallback)(
4475
+ return (0, import_react29.useCallback)(
3033
4476
  (idToken, pid, source, endpoint, payload) => {
3034
4477
  if (!idToken || !pid || !source || !endpoint || !payload) return;
3035
4478
  let sourceTypePayload = {};
@@ -3150,18 +4593,25 @@ function isMarketplacePurchaseAction(payload) {
3150
4593
  ActionSourceType,
3151
4594
  ActionStatus,
3152
4595
  ActionType,
4596
+ ERROR_ABI,
3153
4597
  FIREBASE_WEB_API_KEYS,
3154
4598
  FIREBASE_WEB_AUTH_API_ENDPOINTS,
4599
+ KIBBLE_TOKEN_ABI,
4600
+ MARKETPLACE_ABI,
3155
4601
  MarketplacePaymentType,
3156
4602
  NETWORK_HOSTS,
3157
4603
  Network,
4604
+ ORGANIZATION_BEACON_ABI,
4605
+ ORGANIZATION_IMPL_ABI,
4606
+ ORG_FUNCTION,
4607
+ PET_NFT_ABI,
4608
+ REWARDABLE_ACTIONS_ABI,
3158
4609
  convertToActionDefinition,
3159
4610
  convertToActionRecord,
3160
4611
  convertToMultipleActionDefinitions,
3161
4612
  convertToMultipleActionRecords,
3162
4613
  createApp,
3163
4614
  createAuthEnvelope,
3164
- fetchAnymals,
3165
4615
  flattenFirestoreData,
3166
4616
  generateAppSignature,
3167
4617
  generateBytes32Nonce,
@@ -3176,19 +4626,17 @@ function isMarketplacePurchaseAction(payload) {
3176
4626
  sendUserOpWithRetries,
3177
4627
  serializePublicKeyCompressed,
3178
4628
  submitAction,
3179
- useAddAnymalToDatabase,
3180
4629
  useApproveKibbleToken,
3181
4630
  useApproveOrgPartialPayment,
3182
4631
  useClaimActionReward,
3183
4632
  useClaimOrgActionReward,
4633
+ useCoinbaseMintAnymalNFT,
3184
4634
  useCreateOrganizationAppData,
3185
4635
  useCreateOrganizationBase,
3186
4636
  useCreateUserAppData,
3187
4637
  useCreateWeb3Account,
3188
- useDeleteAnymalFromDatabase,
3189
4638
  useFetchActionDefinitions,
3190
4639
  useFetchActions,
3191
- useFetchAnymals,
3192
4640
  useFetchBalance,
3193
4641
  useFetchNotifications,
3194
4642
  useFetchUserData,
@@ -3197,8 +4645,8 @@ function isMarketplacePurchaseAction(payload) {
3197
4645
  useProcessOrgPartialKibblePayment,
3198
4646
  useProcessPartialKibblePayment,
3199
4647
  useSaveAnymalMetadata,
4648
+ useSendCoinbaseUserOperation,
3200
4649
  useSubmitContractAction,
3201
- useUpdateAnymalWithNFT,
3202
4650
  useUpdateOrgWalletAddress,
3203
4651
  useUpdateUserAsVerified,
3204
4652
  useUpdateUserEmail,