@aastar/sdk 0.20.3 → 0.20.5
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/README.md +33 -25
- package/dist/UserClient-UYIHF6UJ.js +6 -0
- package/dist/{UserClient-JMNNZT4P.js.map → UserClient-UYIHF6UJ.js.map} +1 -1
- package/dist/account.js +3 -3
- package/dist/admin.js +3 -3
- package/dist/airaccount.js +1 -4497
- package/dist/airaccount.js.map +1 -1
- package/dist/channel.js +3 -3
- package/dist/{chunk-R2RATIK2.js → chunk-42KVVOOU.js} +9 -9
- package/dist/{chunk-R2RATIK2.js.map → chunk-42KVVOOU.js.map} +1 -1
- package/dist/{chunk-QNYP7RPI.js → chunk-6UHVUGDT.js} +3 -3
- package/dist/{chunk-QNYP7RPI.js.map → chunk-6UHVUGDT.js.map} +1 -1
- package/dist/{chunk-YSDWB6DO.js → chunk-FBDMID2J.js} +3 -3
- package/dist/{chunk-YSDWB6DO.js.map → chunk-FBDMID2J.js.map} +1 -1
- package/dist/{chunk-LNICTATJ.js → chunk-FIS3RUGL.js} +6 -6
- package/dist/{chunk-LNICTATJ.js.map → chunk-FIS3RUGL.js.map} +1 -1
- package/dist/{chunk-O454V5ML.js → chunk-HNTLDUL7.js} +3 -3
- package/dist/{chunk-O454V5ML.js.map → chunk-HNTLDUL7.js.map} +1 -1
- package/dist/{chunk-NAPMVAVJ.js → chunk-I3VRFZA4.js} +3 -3
- package/dist/{chunk-NAPMVAVJ.js.map → chunk-I3VRFZA4.js.map} +1 -1
- package/dist/{chunk-ZJLIKMCA.js → chunk-NRH56SAJ.js} +13 -3
- package/dist/chunk-NRH56SAJ.js.map +1 -0
- package/dist/{chunk-M5ORP2PM.js → chunk-QJT4IOIS.js} +8 -8
- package/dist/{chunk-M5ORP2PM.js.map → chunk-QJT4IOIS.js.map} +1 -1
- package/dist/{chunk-TBDMSJVL.js → chunk-TIH7D4FQ.js} +12 -12
- package/dist/{chunk-TBDMSJVL.js.map → chunk-TIH7D4FQ.js.map} +1 -1
- package/dist/{chunk-KL6SCEIU.js → chunk-VYU6P7HB.js} +4 -4
- package/dist/{chunk-KL6SCEIU.js.map → chunk-VYU6P7HB.js.map} +1 -1
- package/dist/chunk-WPSWFZKF.js +4499 -0
- package/dist/chunk-WPSWFZKF.js.map +1 -0
- package/dist/{chunk-5TDDS3T5.js → chunk-ZFIKBDBT.js} +3 -3
- package/dist/{chunk-5TDDS3T5.js.map → chunk-ZFIKBDBT.js.map} +1 -1
- package/dist/{chunk-Y3KP7R2Y.js → chunk-ZGOEADCO.js} +3 -3
- package/dist/{chunk-Y3KP7R2Y.js.map → chunk-ZGOEADCO.js.map} +1 -1
- package/dist/{contract-addresses-VLAHHXOO.js → contract-addresses-ADEWLDHE.js} +3 -3
- package/dist/{contract-addresses-VLAHHXOO.js.map → contract-addresses-ADEWLDHE.js.map} +1 -1
- package/dist/core.js +2 -2
- package/dist/dapp.js +3 -3
- package/dist/{dist-WMYQOYRO.js → dist-GVWCRI4F.js} +5 -5
- package/dist/{dist-WMYQOYRO.js.map → dist-GVWCRI4F.js.map} +1 -1
- package/dist/enduser.js +4 -4
- package/dist/identity.js +3 -3
- package/dist/index.d.ts +1 -0
- package/dist/index.js +22 -22
- package/dist/index.js.map +1 -1
- package/dist/{index.node-GNYPFVZQ.js → index.node-KIKM4EG6.js} +4 -4
- package/dist/{index.node-GNYPFVZQ.js.map → index.node-KIKM4EG6.js.map} +1 -1
- package/dist/kms.d.ts +2 -0
- package/dist/kms.js +5 -0
- package/dist/kms.js.map +1 -0
- package/dist/operator.js +3 -3
- package/dist/paymaster.js +3 -3
- package/dist/tokens.js +3 -3
- package/dist/x402.js +3 -3
- package/package.json +20 -16
- package/LICENSE +0 -180
- package/dist/UserClient-JMNNZT4P.js +0 -6
- package/dist/chunk-ZJLIKMCA.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BaseClient, registryActions } from './chunk-
|
|
1
|
+
import { BaseClient, registryActions } from './chunk-TIH7D4FQ.js';
|
|
2
2
|
|
|
3
3
|
// ../admin/dist/ProtocolGovernance.js
|
|
4
4
|
var ProtocolGovernance = class extends BaseClient {
|
|
@@ -102,5 +102,5 @@ var ProtocolGovernance = class extends BaseClient {
|
|
|
102
102
|
};
|
|
103
103
|
|
|
104
104
|
export { ProtocolGovernance };
|
|
105
|
-
//# sourceMappingURL=chunk-
|
|
106
|
-
//# sourceMappingURL=chunk-
|
|
105
|
+
//# sourceMappingURL=chunk-ZFIKBDBT.js.map
|
|
106
|
+
//# sourceMappingURL=chunk-ZFIKBDBT.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../admin/dist/ProtocolGovernance.js"],"names":[],"mappings":";;;AAUO,IAAM,kBAAA,GAAN,cAAiC,UAAA,CAAW;AAAA,EAC/C,eAAA;AAAA,EACA,iBAAA;AAAA,EACA,YAAY,MAAA,EAAQ;AAChB,IAAA,KAAA,CAAM,MAAM,CAAA;AACZ,IAAA,IAAA,CAAK,kBAAkB,MAAA,CAAO,eAAA;AAC9B,IAAA,IAAA,CAAK,oBAAoB,MAAA,CAAO,iBAAA;AAAA,EACpC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,MAAM,WAAA,CAAY,QAAA,EAAU,OAAA,EAAS;AASjC,IAAA,MAAM,IAAI,MAAM,2EAA2E,CAAA;AAAA,EAC/F;AAAA;AAAA;AAAA;AAAA,EAIA,MAAM,gBAAA,CAAiB,UAAA,EAAY,OAAA,EAAS;AAIxC,IAAA,MAAM,IAAI,MAAM,sCAAsC,CAAA;AAAA,EAC1D;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,MAAM,iBAAA,CAAkB,SAAA,EAAW,OAAA,EAAS;AACxC,IAAA,MAAM,QAAA,GAAW,eAAA,CAAgB,IAAA,CAAK,eAAe,CAAA;AACrD,IAAA,OAAO,MAAM,QAAA,CAAS,IAAA,CAAK,MAAM,EAAE,i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astar/core'; // L2/L1 Actions\n/**\n * ProtocolGovernance - L3 Pattern\n *\n * Responsibilities:\n * 1. Global Protocol Parameter Management (Registry, EntryPoint)\n * 2. High-level Governance Operations (DAO Transfer, Upgrades)\n * 3. SuperPaymaster & Module Approval\n */\nexport class ProtocolGovernance extends BaseClient {\n registryAddress;\n entryPointAddress;\n constructor(config) {\n super(config);\n this.registryAddress = config.registryAddress;\n this.entryPointAddress = config.entryPointAddress;\n }\n // ===========================================\n // 1. Global Parameter Management\n // ===========================================\n /**\n * Update the Global Treasury Address where protocol fees are collected\n */\n async setTreasury(treasury, options) {\n // Note: Registry might not have direct setTreasury if it relies on SuperPaymaster's config.\n // Assuming Registry has ownership pointers or config pointers.\n // If Logic resides in SuperPaymaster, we would use superPaymasterActions.\n // Based on provided ABI/Actions, Registry manages Role Configs mainly.\n // Let's assume we are updating a System Role or similar global config if available,\n // OR adhering to what registryActions provides.\n // Checking registryActions... it has 'transferOwnership' but maybe not direct 'setTreasury' depending on version.\n // If strictly following ABI, we might need to update a specific Role Parameter (e.g. AOA/Super config).\n throw new Error(\"Method not mapped to RegistryABI v1. Please verify contract capabilities.\");\n }\n /**\n * Update the supported EntryPoint address\n */\n async updateEntryPoint(entryPoint, options) {\n // Placeholder: Real implementation depends on if Registry stores EntryPoint\n // registryActions typically provides getters. Setters usually restricted to Owner.\n // If action not available, throw standard error.\n throw new Error(\"Method not mapped to RegistryABI v1.\");\n }\n // ===========================================\n // 2. Role & Module Governance\n // ===========================================\n /**\n * Approve a new SuperPaymaster contract address\n */\n async setSuperPaymaster(paymaster, options) {\n const registry = registryActions(this.registryAddress);\n return await registry(this.client).setSuperPaymaster({\n paymaster,\n account: options?.account\n });\n }\n /**\n * Set the Staking contract address\n */\n async setStaking(staking, options) {\n const registry = registryActions(this.registryAddress);\n return await registry(this.client).setStaking({\n staking,\n account: options?.account\n });\n }\n /**\n * Configure a Role's parameters (Admin only).\n * Reads the current on-chain config first, then merges the provided overrides\n * and writes back the full struct via configureRole.\n */\n async configureRole(params, options) {\n const registry = registryActions(this.registryAddress)(this.client);\n const current = await registry.getRoleConfig({ roleId: params.roleId });\n return await registry.configureRole({\n roleId: params.roleId,\n config: {\n ...current,\n ...(params.minStake !== undefined && { minStake: params.minStake }),\n ...(params.ticketPrice !== undefined && { ticketPrice: params.ticketPrice }),\n ...(params.exitFeePercent !== undefined && { exitFeePercent: params.exitFeePercent }),\n ...(params.minExitFee !== undefined && { minExitFee: params.minExitFee }),\n },\n account: options?.account,\n });\n }\n // ===========================================\n // 3. Transfer to DAO (Exit/Upgrade)\n // ===========================================\n /**\n * Transfer Protocol Ownership to a DAO (Multisig/Timelock)\n * This is the final step of \"Protocol Admin\" lifecycle.\n */\n async transferToDAO(daoAddress, options) {\n const registry = registryActions(this.registryAddress);\n return await registry(this.client).transferOwnership({\n newOwner: daoAddress,\n account: options?.account\n });\n }\n // ===========================================\n // 4. Query Capabilities\n // ===========================================\n async getProtocolParams() {\n const registry = registryActions(this.registryAddress)(this.client); // Read-only via Client\n // Parallel fetch\n const [sp, staking] = await Promise.all([\n registry.SUPER_PAYMASTER(),\n registry.GTOKEN_STAKING()\n ]);\n return {\n minStake: 0n, // Global default not directly exposed, usually per role\n treasury: await registry.owner(), // Approximation for now\n entryPoint: this.entryPointAddress,\n superPaymaster: sp\n };\n }\n}\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { channelActions } from './chunk-
|
|
1
|
+
import { channelActions } from './chunk-TIH7D4FQ.js';
|
|
2
2
|
|
|
3
3
|
// ../channel/dist/voucher.js
|
|
4
4
|
var VOUCHER_TYPES = {
|
|
@@ -109,5 +109,5 @@ var ChannelClient = class {
|
|
|
109
109
|
};
|
|
110
110
|
|
|
111
111
|
export { ChannelClient, VOUCHER_TYPES, getVoucherDomain, signVoucher };
|
|
112
|
-
//# sourceMappingURL=chunk-
|
|
113
|
-
//# sourceMappingURL=chunk-
|
|
112
|
+
//# sourceMappingURL=chunk-ZGOEADCO.js.map
|
|
113
|
+
//# sourceMappingURL=chunk-ZGOEADCO.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../channel/dist/voucher.js","../../channel/dist/ChannelClient.js"],"names":[],"mappings":";;;AAAO,IAAM,aAAA,GAAgB;AAAA,EACzB,OAAA,EAAS;AAAA,IACL,EAAE,IAAA,EAAM,WAAA,EAAa,IAAA,EAAM,SAAA,EAAU;AAAA,IACrC,EAAE,IAAA,EAAM,kBAAA,EAAoB,IAAA,EAAM,SAAA;AAAU;AAEpD;AACO,SAAS,gBAAA,CAAiB,SAAS,iBAAA,EAAmB;AACzD,EAAA,OAAO;AAAA,IACH,IAAA,EAAM,qBAAA;AAAA,IACN,OAAA,EAAS,OAAA;AAAA,IACT,OAAA;AAAA,IACA;AAAA,GACJ;AACJ;AACA,eAAsB,WAAA,CAAY,cAAc,MAAA,EAAQ;AACpD,EAAA,MAAM,MAAA,GAAS,gBAAA,CAAiB,MAAA,CAAO,OAAA,EAAS,OAAO,iBAAiB,CAAA;AACxE,EAAA,MAAM,UAAU,YAAA,CAAa,OAAA;AAC7B,EAAA,IAAI,CAAC,OAAA,EAAS;AACV,IAAA,MAAM,IAAI,MAAM,mCAAmC,CAAA;AAAA,EACvD;AACA,EAAA,OAAO,aAAa,aAAA,CAAc;AAAA,IAC9B,OAAA;AAAA,IACA,MAAA;AAAA,IACA,KAAA,EAAO,aAAA;AAAA,IACP,WAAA,EAAa,SAAA;AAAA,IACb,OAAA,EAAS;AAAA,MACL,WAAW,MAAA,CAAO,SAAA;AAAA,MAClB,kBAAkB,MAAA,CAAO;AAAA;AAC7B,GACH,CAAA;AACL;;;AC5BO,IAAM,gBAAN,MAAoB;AAAA,EACvB,WAAA;AAAA,EACA,YAAA;AAAA,EACA,MAAA;AAAA,EACA,YAAY,MAAA,EAAQ;AAChB,IAAA,IAAA,CAAK,MAAA,GAAS,MAAA;AAKd,IAAA,IAAA,CAAK,cAAc,cAAA,CAAe,MAAA,CAAO,cAAc,CA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;AAAA,EACL;AAAA,EACA,MAAM,YAAA,CAAa,SAAA,EAAW,MAAA,EAAQ;AAClC,IAAA,OAAO,IAAA,CAAK,aAAa,YAAA,CAAa;AAAA,MAClC,SAAA;AAAA,MACA,MAAA;AAAA,MACA,OAAA,EAAS,IAAA,CAAK,MAAA,CAAO,YAAA,CAAa;AAAA,KACrC,CAAA;AAAA,EACL;AAAA,EACA,MAAM,aAAa,SAAA,EAAW;AAC1B,IAAA,OAAO,IAAA,CAAK,aAAa,mBAAA,CAAoB;AAAA,MACzC,SAAA;AAAA,MACA,OAAA,EAAS,IAAA,CAAK,MAAA,CAAO,YAAA,CAAa;AAAA,KACrC,CAAA;AAAA,EACL;AAAA,EACA,MAAM,SAAS,SAAA,EAAW;AACtB,IAAA,OAAO,IAAA,CAAK,aAAa,eAAA,CAAgB;AAAA,MACrC,SAAA;AAAA,MACA,OAAA,EAAS,IAAA,CAAK,MAAA,CAAO,YAAA,CAAa;AAAA,KACrC,CAAA;AAAA,EACL;AAAA,EACA,MAAM,gBAAgB,SAAA,EAAW;AAC7B,IAAA,OAAO,IAAA,CAAK,WAAA,CAAY,UAAA,CAAW,EAAE,WAAW,CAAA;AAAA,EACpD;AAAA,EACA,MAAM,eAAA,GAAkB;AACpB,IAAA,OAAO,IAAA,CAAK,YAAY,aAAA,EAAc;AAAA,EAC1C;AAAA,EACA,MAAM,UAAA,GAAa;AACf,IAAA,OAAO,IAAA,CAAK,YAAY,OAAA,EAAQ;AAAA,EACpC;AACJ","file":"chunk-ZGOEADCO.js","sourcesContent":["export const VOUCHER_TYPES = {\n Voucher: [\n { name: 'channelId', type: 'bytes32' },\n { name: 'cumulativeAmount', type: 'uint128' },\n ],\n};\nexport function getVoucherDomain(chainId, verifyingContract) {\n return {\n name: 'MicroPaymentChannel',\n version: '1.0.0',\n chainId,\n verifyingContract,\n };\n}\nexport async function signVoucher(walletClient, params) {\n const domain = getVoucherDomain(params.chainId, params.verifyingContract);\n const account = walletClient.account;\n if (!account) {\n throw new Error('WalletClient must have an account');\n }\n return walletClient.signTypedData({\n account,\n domain,\n types: VOUCHER_TYPES,\n primaryType: 'Voucher',\n message: {\n channelId: params.channelId,\n cumulativeAmount: params.cumulativeAmount,\n },\n });\n}\n","import { channelActions } from '@aastar/core';\nimport { signVoucher } from './voucher.js';\nexport class ChannelClient {\n readActions;\n writeActions;\n config;\n constructor(config) {\n this.config = config;\n // Separate clients: publicClient for reads (no account required),\n // walletClient for writes. Unlike X402Client which is always write-first,\n // ChannelClient exposes read-heavy helpers (getChannel, verifyVoucher) that\n // callers may invoke without a wallet configured.\n this.readActions = channelActions(config.channelAddress)(config.publicClient);\n this.writeActions = channelActions(config.channelAddress)(config.walletClient);\n }\n async openChannel(channelConfig) {\n return this.writeActions.openChannel({\n payee: channelConfig.payee,\n token: channelConfig.token,\n deposit: channelConfig.deposit,\n salt: channelConfig.salt,\n authorizedSigner: channelConfig.authorizedSigner,\n account: this.config.walletClient.account,\n });\n }\n async signVoucherOffline(channelId, cumulativeAmount) {\n const signature = await signVoucher(this.config.walletClient, {\n channelId,\n cumulativeAmount,\n chainId: this.config.chainId,\n verifyingContract: this.config.channelAddress,\n });\n return { channelId, cumulativeAmount, signature };\n }\n async settleChannel(voucher) {\n return this.writeActions.settleChannel({\n channelId: voucher.channelId,\n cumulativeAmount: voucher.cumulativeAmount,\n signature: voucher.signature,\n account: this.config.walletClient.account,\n });\n }\n async closeChannel(voucher) {\n return this.writeActions.closeChannel({\n channelId: voucher.channelId,\n cumulativeAmount: voucher.cumulativeAmount,\n signature: voucher.signature,\n account: this.config.walletClient.account,\n });\n }\n async topUpChannel(channelId, amount) {\n return this.writeActions.topUpChannel({\n channelId,\n amount,\n account: this.config.walletClient.account,\n });\n }\n async requestClose(channelId) {\n return this.writeActions.requestCloseChannel({\n channelId,\n account: this.config.walletClient.account,\n });\n }\n async withdraw(channelId) {\n return this.writeActions.withdrawChannel({\n channelId,\n account: this.config.walletClient.account,\n });\n }\n async getChannelState(channelId) {\n return this.readActions.getChannel({ channelId });\n }\n async getCloseTimeout() {\n return this.readActions.CLOSE_TIMEOUT();\n }\n async getVersion() {\n return this.readActions.version();\n }\n}\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { ALL_ADDRESSES, COMMUNITY_OWNERS, CORE_ADDRESSES, MONITORING_ADDRESSES, OFFICIAL_ADDRESSES, PAYMASTER_ADDRESSES, TEST_ACCOUNT_ADDRESSES, TEST_COMMUNITIES, TEST_TOKEN_ADDRESSES, TOKEN_ADDRESSES } from './chunk-
|
|
1
|
+
export { ALL_ADDRESSES, COMMUNITY_OWNERS, CORE_ADDRESSES, MONITORING_ADDRESSES, OFFICIAL_ADDRESSES, PAYMASTER_ADDRESSES, TEST_ACCOUNT_ADDRESSES, TEST_COMMUNITIES, TEST_TOKEN_ADDRESSES, TOKEN_ADDRESSES } from './chunk-NRH56SAJ.js';
|
|
2
2
|
import './chunk-PZ5AY32C.js';
|
|
3
|
-
//# sourceMappingURL=contract-addresses-
|
|
4
|
-
//# sourceMappingURL=contract-addresses-
|
|
3
|
+
//# sourceMappingURL=contract-addresses-ADEWLDHE.js.map
|
|
4
|
+
//# sourceMappingURL=contract-addresses-ADEWLDHE.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","file":"contract-addresses-
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"contract-addresses-ADEWLDHE.js"}
|
package/dist/core.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { AASTAR_COMMUNITY, AAStarAirAccountFactoryV7ABI, AAStarAirAccountFactoryV7Artifact, AAStarAirAccountV7ABI, AAStarAirAccountV7Artifact, AAStarBLSAggregatorABI, AAStarBLSAggregatorArtifact, AAStarBLSAlgorithmABI, AAStarBLSAlgorithmArtifact, AAStarValidatorABI, AAStarValidatorArtifact, ALL_ROLES, AgentRegistryABI, AgentRegistryArtifact, AirAccountDelegateABI, AirAccountDelegateArtifact, AirAccountExtensionABI, AirAccountExtensionArtifact, AuthorizationState, BLSAggregatorABI, BLSAggregatorArtifact, BLSHelpers, BLSSigner, BLSValidatorABI, BLSValidatorArtifact, BLS_POP_DST, BRANDING, BREAD_COMMUNITY, BaseClient, BundlerClient, COMMUNITIES, CONTRACTS, CONTRACT_METADATA, CalldataParserRegistryABI, CalldataParserRegistryArtifact, ContractConfigManager, DEFAULT_ADMIN_ROLE, DVTValidatorABI, DVTValidatorArtifact, DVT_TIER_T2, DVT_TIER_T3, EntryPointABI, EntryPointArtifact, EntryPointVersion, ForceExitModuleABI, ForceExitModuleArtifact, GTokenABI, GTokenArtifact, GTokenAuthorizationABI, GTokenAuthorizationArtifact, GTokenStakingABI, GTokenStakingArtifact, INITIAL_ROLE_STAKES, LINKS, MicroPaymentChannelABI, MicroPaymentChannelArtifact, MySBTABI, MySBTArtifact, NETWORKS, NodeType, PaymasterABI, PaymasterArtifact, PaymasterFactoryABI, PaymasterFactoryArtifact, PolicyDecision, PolicyRegistryABI, PolicyRegistryArtifact, ROLE_ANODE, ROLE_COMMUNITY, ROLE_DVT, ROLE_ENDUSER, ROLE_KMS, ROLE_NAMES, ROLE_PAYMASTER_AOA, ROLE_PAYMASTER_SUPER, ROLE_PERMISSION_LEVELS, RegistryABI, RegistryArtifact, ReputationSystemABI, ReputationSystemArtifact, RequirementChecker, RolePermissionLevel, SEPOLIA_CONTRACTS, SEPOLIA_V2_VERSIONS, SepoliaFaucetAPI, SessionKeyValidatorABI, SessionKeyValidatorArtifact, SimpleAccountABI, SimpleAccountArtifact, SimpleAccountFactoryABI, SimpleAccountFactoryArtifact, StateValidator, SuperPaymasterABI, SuperPaymasterArtifact, V2_SUMMARY, X402FacilitatorABI, X402FacilitatorArtifact, accountActions, accountFactoryActions, agentActions, agentRegistryActions, aggregatorActions, airAccountActions, airAccountFactoryActions, blsAlgorithmActions, channelActions, createAAStarPublicClient, createHeliosTransport, dvtActions, encodeDVTAccountSignature, encodeDVTVerifierProof, encodeG2Point, entryPointActions, forceExitActions, gTokenActions, gTokenAuthorizationActions, getAddressUrl, getAllCommunityConfigs, getAllV2Contracts, getBlockExplorer, getChainId, getCommunities, getCommunity, getCommunityConfig, getContract, getContractNetworks, getContracts, getCoreContracts, getDeploymentDate, getEntryPoint, getNetwork, getPaymasterV4_1, getRoleName, getRpcUrl, getSimpleAccountFactory, getSuperPaymasterV2, getTestAccounts, getTestTokenContracts, getTokenContracts, getTxUrl, getV2ContractByAddress, getV2ContractByName, getV2ContractsByDate, hashToFieldU0U1, isContractNetworkSupported, isRegisteredCommunity, isV2Contract, lookupAddress, paymasterActions, paymasterFactoryActions, policyRegistryActions, registryActions, reputationActions, resolveEns, resolveEnsVerified, sbtActions, sessionKeyValidatorActions, stakingActions, superPaymasterActions, tokenActions, x402Actions, x402IsNonceUsed, x402NonceKey, xPNTsFactoryABI, xPNTsFactoryActions, xPNTsFactoryArtifact, xPNTsTokenABI, xPNTsTokenActions, xPNTsTokenArtifact } from './chunk-
|
|
2
|
-
export { AGENT_IDENTITY_REGISTRY_ADDRESS, AGENT_REPUTATION_REGISTRY_ADDRESS, ALL_ADDRESSES, APNTS_ADDRESS, BLS_AGGREGATOR_ADDRESS, BLS_VALIDATOR_ADDRESS, BPS_DENOMINATOR, CANONICAL_ADDRESSES, CHAIN_MAINNET, CHAIN_SEPOLIA, COMMUNITY_OWNERS, CONTRACT_SRC_HASH, CORE_ADDRESSES, DEFAULT_APNTS_PRICE_USD, DEFAULT_CALL_GAS_LIMIT, DEFAULT_GAS_TOKEN_MINT_AMOUNT, DEFAULT_PRE_VERIFICATION_GAS, DEFAULT_TIMEOUT_MS, DEFAULT_TOKEN_NAME, DEFAULT_TOKEN_SYMBOL, DEFAULT_USDT_MINT_AMOUNT, DEFAULT_VERIFICATION_GAS_LIMIT, DVT_VALIDATOR_ADDRESS, ENTRY_POINT_ADDRESS, FAUCET_API_URL, GTOKEN_ADDRESS, GTOKEN_STAKING_ADDRESS, MAX_SERVICE_FEE, MICRO_PAYMENT_CHANNEL_ADDRESS, MONITORING_ADDRESSES, NODE_STAKE_AMOUNTS, OFFICIAL_ADDRESSES, PAYMASTER_ADDRESSES, PAYMASTER_FACTORY_ADDRESS, PAYMASTER_V4_ADDRESS, PAYMASTER_V4_IMPL_ADDRESS, REGISTRY_ADDRESS, REPUTATION_SYSTEM_ADDRESS, SBT_ADDRESS, SERVICE_FEE_RATE, SUPER_PAYMASTER_ADDRESS, TEST_ACCOUNT_ADDRESSES, TEST_ACCOUNT_POOL_SIZE, TEST_COMMUNITIES, TEST_TOKEN_ADDRESSES, TOKEN_ADDRESSES, XPNTS_FACTORY_ADDRESS, applyConfig, getCanonicalAddresses, isSupportedChainId, listSupportedChainIds } from './chunk-
|
|
1
|
+
export { AASTAR_COMMUNITY, AAStarAirAccountFactoryV7ABI, AAStarAirAccountFactoryV7Artifact, AAStarAirAccountV7ABI, AAStarAirAccountV7Artifact, AAStarBLSAggregatorABI, AAStarBLSAggregatorArtifact, AAStarBLSAlgorithmABI, AAStarBLSAlgorithmArtifact, AAStarValidatorABI, AAStarValidatorArtifact, ALL_ROLES, AgentRegistryABI, AgentRegistryArtifact, AirAccountDelegateABI, AirAccountDelegateArtifact, AirAccountExtensionABI, AirAccountExtensionArtifact, AuthorizationState, BLSAggregatorABI, BLSAggregatorArtifact, BLSHelpers, BLSSigner, BLSValidatorABI, BLSValidatorArtifact, BLS_POP_DST, BRANDING, BREAD_COMMUNITY, BaseClient, BundlerClient, COMMUNITIES, CONTRACTS, CONTRACT_METADATA, CalldataParserRegistryABI, CalldataParserRegistryArtifact, ContractConfigManager, DEFAULT_ADMIN_ROLE, DVTValidatorABI, DVTValidatorArtifact, DVT_TIER_T2, DVT_TIER_T3, EntryPointABI, EntryPointArtifact, EntryPointVersion, ForceExitModuleABI, ForceExitModuleArtifact, GTokenABI, GTokenArtifact, GTokenAuthorizationABI, GTokenAuthorizationArtifact, GTokenStakingABI, GTokenStakingArtifact, INITIAL_ROLE_STAKES, LINKS, MicroPaymentChannelABI, MicroPaymentChannelArtifact, MySBTABI, MySBTArtifact, NETWORKS, NodeType, PaymasterABI, PaymasterArtifact, PaymasterFactoryABI, PaymasterFactoryArtifact, PolicyDecision, PolicyRegistryABI, PolicyRegistryArtifact, ROLE_ANODE, ROLE_COMMUNITY, ROLE_DVT, ROLE_ENDUSER, ROLE_KMS, ROLE_NAMES, ROLE_PAYMASTER_AOA, ROLE_PAYMASTER_SUPER, ROLE_PERMISSION_LEVELS, RegistryABI, RegistryArtifact, ReputationSystemABI, ReputationSystemArtifact, RequirementChecker, RolePermissionLevel, SEPOLIA_CONTRACTS, SEPOLIA_V2_VERSIONS, SepoliaFaucetAPI, SessionKeyValidatorABI, SessionKeyValidatorArtifact, SimpleAccountABI, SimpleAccountArtifact, SimpleAccountFactoryABI, SimpleAccountFactoryArtifact, StateValidator, SuperPaymasterABI, SuperPaymasterArtifact, V2_SUMMARY, X402FacilitatorABI, X402FacilitatorArtifact, accountActions, accountFactoryActions, agentActions, agentRegistryActions, aggregatorActions, airAccountActions, airAccountFactoryActions, blsAlgorithmActions, channelActions, createAAStarPublicClient, createHeliosTransport, dvtActions, encodeDVTAccountSignature, encodeDVTVerifierProof, encodeG2Point, entryPointActions, forceExitActions, gTokenActions, gTokenAuthorizationActions, getAddressUrl, getAllCommunityConfigs, getAllV2Contracts, getBlockExplorer, getChainId, getCommunities, getCommunity, getCommunityConfig, getContract, getContractNetworks, getContracts, getCoreContracts, getDeploymentDate, getEntryPoint, getNetwork, getPaymasterV4_1, getRoleName, getRpcUrl, getSimpleAccountFactory, getSuperPaymasterV2, getTestAccounts, getTestTokenContracts, getTokenContracts, getTxUrl, getV2ContractByAddress, getV2ContractByName, getV2ContractsByDate, hashToFieldU0U1, isContractNetworkSupported, isRegisteredCommunity, isV2Contract, lookupAddress, paymasterActions, paymasterFactoryActions, policyRegistryActions, registryActions, reputationActions, resolveEns, resolveEnsVerified, sbtActions, sessionKeyValidatorActions, stakingActions, superPaymasterActions, tokenActions, x402Actions, x402IsNonceUsed, x402NonceKey, xPNTsFactoryABI, xPNTsFactoryActions, xPNTsFactoryArtifact, xPNTsTokenABI, xPNTsTokenActions, xPNTsTokenArtifact } from './chunk-TIH7D4FQ.js';
|
|
2
|
+
export { AGENT_IDENTITY_REGISTRY_ADDRESS, AGENT_REPUTATION_REGISTRY_ADDRESS, ALL_ADDRESSES, APNTS_ADDRESS, BLS_AGGREGATOR_ADDRESS, BLS_VALIDATOR_ADDRESS, BPS_DENOMINATOR, CANONICAL_ADDRESSES, CHAIN_MAINNET, CHAIN_SEPOLIA, COMMUNITY_OWNERS, CONTRACT_SRC_HASH, CORE_ADDRESSES, DEFAULT_APNTS_PRICE_USD, DEFAULT_CALL_GAS_LIMIT, DEFAULT_GAS_TOKEN_MINT_AMOUNT, DEFAULT_PRE_VERIFICATION_GAS, DEFAULT_TIMEOUT_MS, DEFAULT_TOKEN_NAME, DEFAULT_TOKEN_SYMBOL, DEFAULT_USDT_MINT_AMOUNT, DEFAULT_VERIFICATION_GAS_LIMIT, DVT_VALIDATOR_ADDRESS, ENTRY_POINT_ADDRESS, FAUCET_API_URL, GTOKEN_ADDRESS, GTOKEN_STAKING_ADDRESS, MAX_SERVICE_FEE, MICRO_PAYMENT_CHANNEL_ADDRESS, MONITORING_ADDRESSES, NODE_STAKE_AMOUNTS, OFFICIAL_ADDRESSES, PAYMASTER_ADDRESSES, PAYMASTER_FACTORY_ADDRESS, PAYMASTER_V4_ADDRESS, PAYMASTER_V4_IMPL_ADDRESS, REGISTRY_ADDRESS, REPUTATION_SYSTEM_ADDRESS, SBT_ADDRESS, SERVICE_FEE_RATE, SUPER_PAYMASTER_ADDRESS, TEST_ACCOUNT_ADDRESSES, TEST_ACCOUNT_POOL_SIZE, TEST_COMMUNITIES, TEST_TOKEN_ADDRESSES, TOKEN_ADDRESSES, XPNTS_FACTORY_ADDRESS, applyConfig, describeSupportedChains, getCanonicalAddresses, isSupportedChainId, listSupportedChainIds } from './chunk-NRH56SAJ.js';
|
|
3
3
|
import './chunk-PZ5AY32C.js';
|
|
4
4
|
//# sourceMappingURL=core.js.map
|
|
5
5
|
//# sourceMappingURL=core.js.map
|
package/dist/dapp.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { getSuperPaymasterMiddleware } from './chunk-
|
|
2
|
-
import { createAAStarPublicClient, RegistryABI } from './chunk-
|
|
3
|
-
import './chunk-
|
|
1
|
+
import { getSuperPaymasterMiddleware } from './chunk-I3VRFZA4.js';
|
|
2
|
+
import { createAAStarPublicClient, RegistryABI } from './chunk-TIH7D4FQ.js';
|
|
3
|
+
import './chunk-NRH56SAJ.js';
|
|
4
4
|
import './chunk-PZ5AY32C.js';
|
|
5
5
|
import { parseAbi, createPublicClient, http, hashTypedData, hashMessage, hexToBytes, encodeFunctionData } from 'viem';
|
|
6
6
|
import { useState, useEffect, useCallback } from 'react';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { PaymasterClient, PaymasterManager, PaymasterOperator, SuperPaymasterAdminClient, SuperPaymasterClient, buildPaymasterData, buildSuperPaymasterData, checkEligibility, formatUserOpV07, getPaymasterV4Middleware, getSuperPaymasterMiddleware, getUserOpHashV07, tuneGasLimit } from './chunk-
|
|
2
|
-
import './chunk-
|
|
3
|
-
import './chunk-
|
|
1
|
+
export { PaymasterClient, PaymasterManager, PaymasterOperator, SuperPaymasterAdminClient, SuperPaymasterClient, buildPaymasterData, buildSuperPaymasterData, checkEligibility, formatUserOpV07, getPaymasterV4Middleware, getSuperPaymasterMiddleware, getUserOpHashV07, tuneGasLimit } from './chunk-I3VRFZA4.js';
|
|
2
|
+
import './chunk-TIH7D4FQ.js';
|
|
3
|
+
import './chunk-NRH56SAJ.js';
|
|
4
4
|
import './chunk-PZ5AY32C.js';
|
|
5
|
-
//# sourceMappingURL=dist-
|
|
6
|
-
//# sourceMappingURL=dist-
|
|
5
|
+
//# sourceMappingURL=dist-GVWCRI4F.js.map
|
|
6
|
+
//# sourceMappingURL=dist-GVWCRI4F.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","file":"dist-
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"dist-GVWCRI4F.js"}
|
package/dist/enduser.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { CommunityClient, UserLifecycle } from './chunk-
|
|
2
|
-
export { UserClient } from './chunk-
|
|
3
|
-
import './chunk-
|
|
4
|
-
import './chunk-
|
|
1
|
+
export { CommunityClient, UserLifecycle } from './chunk-42KVVOOU.js';
|
|
2
|
+
export { UserClient } from './chunk-FIS3RUGL.js';
|
|
3
|
+
import './chunk-TIH7D4FQ.js';
|
|
4
|
+
import './chunk-NRH56SAJ.js';
|
|
5
5
|
import './chunk-PZ5AY32C.js';
|
|
6
6
|
//# sourceMappingURL=enduser.js.map
|
|
7
7
|
//# sourceMappingURL=enduser.js.map
|
package/dist/identity.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { ReputationClient, checkMySBT, getMySBTId } from './chunk-
|
|
2
|
-
import './chunk-
|
|
3
|
-
import './chunk-
|
|
1
|
+
export { ReputationClient, checkMySBT, getMySBTId } from './chunk-HNTLDUL7.js';
|
|
2
|
+
import './chunk-TIH7D4FQ.js';
|
|
3
|
+
import './chunk-NRH56SAJ.js';
|
|
4
4
|
import './chunk-PZ5AY32C.js';
|
|
5
5
|
//# sourceMappingURL=identity.js.map
|
|
6
6
|
//# sourceMappingURL=identity.js.map
|
package/dist/index.d.ts
CHANGED
|
@@ -12,6 +12,7 @@ export * from '@aastar/operator';
|
|
|
12
12
|
export * from '@aastar/admin';
|
|
13
13
|
import * as airaccount from '@aastar/airaccount';
|
|
14
14
|
export { airaccount as AirAccount };
|
|
15
|
+
export { airaccount as KMS };
|
|
15
16
|
|
|
16
17
|
type EndUserClient = Client<Transport, Chain, Account | undefined> & PublicActions<Transport, Chain, Account | undefined> & WalletActions<Chain, Account | undefined> & RegistryActions & SBTActions & SuperPaymasterActions & PaymasterActions & {
|
|
17
18
|
/**
|
package/dist/index.js
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
export { ChannelClient, VOUCHER_TYPES, getVoucherDomain, signVoucher } from './chunk-
|
|
2
|
-
export { CommunityClient, UserLifecycle } from './chunk-
|
|
3
|
-
export { UserClient } from './chunk-
|
|
4
|
-
export { OperatorLifecycle, PaymasterOperatorClient, ProposalState, ProtocolClient } from './chunk-
|
|
5
|
-
export { ProtocolGovernance } from './chunk-
|
|
6
|
-
export { dist_exports as AirAccount } from './chunk-4KRQXOTI.js';
|
|
7
|
-
export { UserOpClient, createEOAWalletClient, getUserOpHash, packUserOpLimits, toSimpleSmartAccount } from './chunk-
|
|
8
|
-
export { ReputationClient, checkMySBT, getMySBTId } from './chunk-
|
|
9
|
-
export { FinanceClient } from './chunk-
|
|
10
|
-
export { PaymasterClient, PaymasterManager, PaymasterOperator, SuperPaymasterAdminClient, SuperPaymasterClient, buildPaymasterData, buildSuperPaymasterData, checkEligibility, formatUserOpV07, getPaymasterV4Middleware, getSuperPaymasterMiddleware, getUserOpHashV07, tuneGasLimit } from './chunk-
|
|
11
|
-
export { EIP3009_TYPES, FacilitatorClient, GTOKEN_EIP712_DOMAIN, HEADER_PAYMENT_REQUIRED, HEADER_PAYMENT_RESPONSE, HEADER_PAYMENT_SIGNATURE, HEADER_V1_PAYMENT, HEADER_V1_PAYMENT_RESPONSE, X402Client, decodePaymentPayload, decodePaymentRequired, decodeSettleResponse, encodePaymentPayload, encodePaymentRequired, encodeSettleResponse, extractPaymentRequired, extractSettleResponse, generateNonce, getEIP3009Domain, signCancelAuthorization, signGTokenTransferWithAuthorization, signReceiveWithAuthorization, signTransferWithAuthorization } from './chunk-
|
|
12
|
-
import { paymasterActions, superPaymasterActions, sbtActions, registryActions, RegistryABI, stakingActions, aggregatorActions, xPNTsFactoryActions, dvtActions, SuperPaymasterABI, xPNTsTokenABI, PaymasterFactoryABI } from './chunk-
|
|
13
|
-
export { AASTAR_COMMUNITY, AAStarAirAccountFactoryV7ABI, AAStarAirAccountFactoryV7Artifact, AAStarAirAccountV7ABI, AAStarAirAccountV7Artifact, AAStarBLSAggregatorABI, AAStarBLSAggregatorArtifact, AAStarBLSAlgorithmABI, AAStarBLSAlgorithmArtifact, AAStarValidatorABI, AAStarValidatorArtifact, ALL_ROLES, AgentRegistryABI, AgentRegistryArtifact, AirAccountDelegateABI, AirAccountDelegateArtifact, AirAccountExtensionABI, AirAccountExtensionArtifact, AuthorizationState, BLSAggregatorABI, BLSAggregatorArtifact, BLSHelpers, BLSSigner, BLSValidatorABI, BLSValidatorArtifact, BLS_POP_DST, BRANDING, BREAD_COMMUNITY, BaseClient, BundlerClient, COMMUNITIES, CONTRACTS, CONTRACT_METADATA, CalldataParserRegistryABI, CalldataParserRegistryArtifact, ContractConfigManager, DEFAULT_ADMIN_ROLE, DVTValidatorABI, DVTValidatorArtifact, DVT_TIER_T2, DVT_TIER_T3, EntryPointABI, EntryPointArtifact, EntryPointVersion, ForceExitModuleABI, ForceExitModuleArtifact, GTokenABI, GTokenArtifact, GTokenAuthorizationABI, GTokenAuthorizationArtifact, GTokenStakingABI, GTokenStakingArtifact, INITIAL_ROLE_STAKES, LINKS, MicroPaymentChannelABI, MicroPaymentChannelArtifact, MySBTABI, MySBTArtifact, NETWORKS, NodeType, PaymasterABI, PaymasterArtifact, PaymasterFactoryABI, PaymasterFactoryArtifact, PolicyDecision, PolicyRegistryABI, PolicyRegistryArtifact, ROLE_ANODE, ROLE_COMMUNITY, ROLE_DVT, ROLE_ENDUSER, ROLE_KMS, ROLE_NAMES, ROLE_PAYMASTER_AOA, ROLE_PAYMASTER_SUPER, ROLE_PERMISSION_LEVELS, RegistryABI, RegistryArtifact, ReputationSystemABI, ReputationSystemArtifact, RequirementChecker, RolePermissionLevel, SEPOLIA_CONTRACTS, SEPOLIA_V2_VERSIONS, SepoliaFaucetAPI, SessionKeyValidatorABI, SessionKeyValidatorArtifact, SimpleAccountABI, SimpleAccountArtifact, SimpleAccountFactoryABI, SimpleAccountFactoryArtifact, StateValidator, SuperPaymasterABI, SuperPaymasterArtifact, V2_SUMMARY, X402FacilitatorABI, X402FacilitatorArtifact, accountActions, accountFactoryActions, agentActions, agentRegistryActions, aggregatorActions, airAccountActions, airAccountFactoryActions, blsAlgorithmActions, channelActions, createAAStarPublicClient, createHeliosTransport, dvtActions, encodeDVTAccountSignature, encodeDVTVerifierProof, encodeG2Point, entryPointActions, forceExitActions, gTokenActions, gTokenAuthorizationActions, getAddressUrl, getAllCommunityConfigs, getAllV2Contracts, getBlockExplorer, getChainId, getCommunities, getCommunity, getCommunityConfig, getContract, getContractNetworks, getContracts, getCoreContracts, getDeploymentDate, getEntryPoint, getNetwork, getPaymasterV4_1, getRoleName, getRpcUrl, getSimpleAccountFactory, getSuperPaymasterV2, getTestAccounts, getTestTokenContracts, getTokenContracts, getTxUrl, getV2ContractByAddress, getV2ContractByName, getV2ContractsByDate, hashToFieldU0U1, isContractNetworkSupported, isRegisteredCommunity, isV2Contract, lookupAddress, paymasterActions, paymasterFactoryActions, policyRegistryActions, registryActions, reputationActions, resolveEns, resolveEnsVerified, sbtActions, sessionKeyValidatorActions, stakingActions, superPaymasterActions, tokenActions, x402Actions, x402IsNonceUsed, x402NonceKey, xPNTsFactoryABI, xPNTsFactoryActions, xPNTsFactoryArtifact, xPNTsTokenABI, xPNTsTokenActions, xPNTsTokenArtifact } from './chunk-
|
|
14
|
-
import { getCanonicalAddresses,
|
|
15
|
-
export { AGENT_IDENTITY_REGISTRY_ADDRESS, AGENT_REPUTATION_REGISTRY_ADDRESS, ALL_ADDRESSES, APNTS_ADDRESS, BLS_AGGREGATOR_ADDRESS, BLS_VALIDATOR_ADDRESS, BPS_DENOMINATOR, CANONICAL_ADDRESSES, CHAIN_MAINNET, CHAIN_SEPOLIA, COMMUNITY_OWNERS, CONTRACT_SRC_HASH, CORE_ADDRESSES, DEFAULT_APNTS_PRICE_USD, DEFAULT_CALL_GAS_LIMIT, DEFAULT_GAS_TOKEN_MINT_AMOUNT, DEFAULT_PRE_VERIFICATION_GAS, DEFAULT_TIMEOUT_MS, DEFAULT_TOKEN_NAME, DEFAULT_TOKEN_SYMBOL, DEFAULT_USDT_MINT_AMOUNT, DEFAULT_VERIFICATION_GAS_LIMIT, DVT_VALIDATOR_ADDRESS, ENTRY_POINT_ADDRESS, FAUCET_API_URL, GTOKEN_ADDRESS, GTOKEN_STAKING_ADDRESS, MAX_SERVICE_FEE, MICRO_PAYMENT_CHANNEL_ADDRESS, MONITORING_ADDRESSES, NODE_STAKE_AMOUNTS, OFFICIAL_ADDRESSES, PAYMASTER_ADDRESSES, PAYMASTER_FACTORY_ADDRESS, PAYMASTER_V4_ADDRESS, PAYMASTER_V4_IMPL_ADDRESS, REGISTRY_ADDRESS, REPUTATION_SYSTEM_ADDRESS, SBT_ADDRESS, SERVICE_FEE_RATE, SUPER_PAYMASTER_ADDRESS, TEST_ACCOUNT_ADDRESSES, TEST_ACCOUNT_POOL_SIZE, TEST_COMMUNITIES, TEST_TOKEN_ADDRESSES, TOKEN_ADDRESSES, XPNTS_FACTORY_ADDRESS, applyConfig, getCanonicalAddresses, isSupportedChainId, listSupportedChainIds } from './chunk-
|
|
1
|
+
export { ChannelClient, VOUCHER_TYPES, getVoucherDomain, signVoucher } from './chunk-ZGOEADCO.js';
|
|
2
|
+
export { CommunityClient, UserLifecycle } from './chunk-42KVVOOU.js';
|
|
3
|
+
export { UserClient } from './chunk-FIS3RUGL.js';
|
|
4
|
+
export { OperatorLifecycle, PaymasterOperatorClient, ProposalState, ProtocolClient } from './chunk-VYU6P7HB.js';
|
|
5
|
+
export { ProtocolGovernance } from './chunk-ZFIKBDBT.js';
|
|
6
|
+
export { dist_exports as AirAccount, dist_exports as KMS } from './chunk-4KRQXOTI.js';
|
|
7
|
+
export { UserOpClient, createEOAWalletClient, getUserOpHash, packUserOpLimits, toSimpleSmartAccount } from './chunk-FBDMID2J.js';
|
|
8
|
+
export { ReputationClient, checkMySBT, getMySBTId } from './chunk-HNTLDUL7.js';
|
|
9
|
+
export { FinanceClient } from './chunk-QJT4IOIS.js';
|
|
10
|
+
export { PaymasterClient, PaymasterManager, PaymasterOperator, SuperPaymasterAdminClient, SuperPaymasterClient, buildPaymasterData, buildSuperPaymasterData, checkEligibility, formatUserOpV07, getPaymasterV4Middleware, getSuperPaymasterMiddleware, getUserOpHashV07, tuneGasLimit } from './chunk-I3VRFZA4.js';
|
|
11
|
+
export { EIP3009_TYPES, FacilitatorClient, GTOKEN_EIP712_DOMAIN, HEADER_PAYMENT_REQUIRED, HEADER_PAYMENT_RESPONSE, HEADER_PAYMENT_SIGNATURE, HEADER_V1_PAYMENT, HEADER_V1_PAYMENT_RESPONSE, X402Client, decodePaymentPayload, decodePaymentRequired, decodeSettleResponse, encodePaymentPayload, encodePaymentRequired, encodeSettleResponse, extractPaymentRequired, extractSettleResponse, generateNonce, getEIP3009Domain, signCancelAuthorization, signGTokenTransferWithAuthorization, signReceiveWithAuthorization, signTransferWithAuthorization } from './chunk-6UHVUGDT.js';
|
|
12
|
+
import { paymasterActions, superPaymasterActions, sbtActions, registryActions, RegistryABI, stakingActions, aggregatorActions, xPNTsFactoryActions, dvtActions, SuperPaymasterABI, xPNTsTokenABI, PaymasterFactoryABI } from './chunk-TIH7D4FQ.js';
|
|
13
|
+
export { AASTAR_COMMUNITY, AAStarAirAccountFactoryV7ABI, AAStarAirAccountFactoryV7Artifact, AAStarAirAccountV7ABI, AAStarAirAccountV7Artifact, AAStarBLSAggregatorABI, AAStarBLSAggregatorArtifact, AAStarBLSAlgorithmABI, AAStarBLSAlgorithmArtifact, AAStarValidatorABI, AAStarValidatorArtifact, ALL_ROLES, AgentRegistryABI, AgentRegistryArtifact, AirAccountDelegateABI, AirAccountDelegateArtifact, AirAccountExtensionABI, AirAccountExtensionArtifact, AuthorizationState, BLSAggregatorABI, BLSAggregatorArtifact, BLSHelpers, BLSSigner, BLSValidatorABI, BLSValidatorArtifact, BLS_POP_DST, BRANDING, BREAD_COMMUNITY, BaseClient, BundlerClient, COMMUNITIES, CONTRACTS, CONTRACT_METADATA, CalldataParserRegistryABI, CalldataParserRegistryArtifact, ContractConfigManager, DEFAULT_ADMIN_ROLE, DVTValidatorABI, DVTValidatorArtifact, DVT_TIER_T2, DVT_TIER_T3, EntryPointABI, EntryPointArtifact, EntryPointVersion, ForceExitModuleABI, ForceExitModuleArtifact, GTokenABI, GTokenArtifact, GTokenAuthorizationABI, GTokenAuthorizationArtifact, GTokenStakingABI, GTokenStakingArtifact, INITIAL_ROLE_STAKES, LINKS, MicroPaymentChannelABI, MicroPaymentChannelArtifact, MySBTABI, MySBTArtifact, NETWORKS, NodeType, PaymasterABI, PaymasterArtifact, PaymasterFactoryABI, PaymasterFactoryArtifact, PolicyDecision, PolicyRegistryABI, PolicyRegistryArtifact, ROLE_ANODE, ROLE_COMMUNITY, ROLE_DVT, ROLE_ENDUSER, ROLE_KMS, ROLE_NAMES, ROLE_PAYMASTER_AOA, ROLE_PAYMASTER_SUPER, ROLE_PERMISSION_LEVELS, RegistryABI, RegistryArtifact, ReputationSystemABI, ReputationSystemArtifact, RequirementChecker, RolePermissionLevel, SEPOLIA_CONTRACTS, SEPOLIA_V2_VERSIONS, SepoliaFaucetAPI, SessionKeyValidatorABI, SessionKeyValidatorArtifact, SimpleAccountABI, SimpleAccountArtifact, SimpleAccountFactoryABI, SimpleAccountFactoryArtifact, StateValidator, SuperPaymasterABI, SuperPaymasterArtifact, V2_SUMMARY, X402FacilitatorABI, X402FacilitatorArtifact, accountActions, accountFactoryActions, agentActions, agentRegistryActions, aggregatorActions, airAccountActions, airAccountFactoryActions, blsAlgorithmActions, channelActions, createAAStarPublicClient, createHeliosTransport, dvtActions, encodeDVTAccountSignature, encodeDVTVerifierProof, encodeG2Point, entryPointActions, forceExitActions, gTokenActions, gTokenAuthorizationActions, getAddressUrl, getAllCommunityConfigs, getAllV2Contracts, getBlockExplorer, getChainId, getCommunities, getCommunity, getCommunityConfig, getContract, getContractNetworks, getContracts, getCoreContracts, getDeploymentDate, getEntryPoint, getNetwork, getPaymasterV4_1, getRoleName, getRpcUrl, getSimpleAccountFactory, getSuperPaymasterV2, getTestAccounts, getTestTokenContracts, getTokenContracts, getTxUrl, getV2ContractByAddress, getV2ContractByName, getV2ContractsByDate, hashToFieldU0U1, isContractNetworkSupported, isRegisteredCommunity, isV2Contract, lookupAddress, paymasterActions, paymasterFactoryActions, policyRegistryActions, registryActions, reputationActions, resolveEns, resolveEnsVerified, sbtActions, sessionKeyValidatorActions, stakingActions, superPaymasterActions, tokenActions, x402Actions, x402IsNonceUsed, x402NonceKey, xPNTsFactoryABI, xPNTsFactoryActions, xPNTsFactoryArtifact, xPNTsTokenABI, xPNTsTokenActions, xPNTsTokenArtifact } from './chunk-TIH7D4FQ.js';
|
|
14
|
+
import { getCanonicalAddresses, describeSupportedChains, TEST_ACCOUNT_ADDRESSES, TOKEN_ADDRESSES, CORE_ADDRESSES, TEST_TOKEN_ADDRESSES } from './chunk-NRH56SAJ.js';
|
|
15
|
+
export { AGENT_IDENTITY_REGISTRY_ADDRESS, AGENT_REPUTATION_REGISTRY_ADDRESS, ALL_ADDRESSES, APNTS_ADDRESS, BLS_AGGREGATOR_ADDRESS, BLS_VALIDATOR_ADDRESS, BPS_DENOMINATOR, CANONICAL_ADDRESSES, CHAIN_MAINNET, CHAIN_SEPOLIA, COMMUNITY_OWNERS, CONTRACT_SRC_HASH, CORE_ADDRESSES, DEFAULT_APNTS_PRICE_USD, DEFAULT_CALL_GAS_LIMIT, DEFAULT_GAS_TOKEN_MINT_AMOUNT, DEFAULT_PRE_VERIFICATION_GAS, DEFAULT_TIMEOUT_MS, DEFAULT_TOKEN_NAME, DEFAULT_TOKEN_SYMBOL, DEFAULT_USDT_MINT_AMOUNT, DEFAULT_VERIFICATION_GAS_LIMIT, DVT_VALIDATOR_ADDRESS, ENTRY_POINT_ADDRESS, FAUCET_API_URL, GTOKEN_ADDRESS, GTOKEN_STAKING_ADDRESS, MAX_SERVICE_FEE, MICRO_PAYMENT_CHANNEL_ADDRESS, MONITORING_ADDRESSES, NODE_STAKE_AMOUNTS, OFFICIAL_ADDRESSES, PAYMASTER_ADDRESSES, PAYMASTER_FACTORY_ADDRESS, PAYMASTER_V4_ADDRESS, PAYMASTER_V4_IMPL_ADDRESS, REGISTRY_ADDRESS, REPUTATION_SYSTEM_ADDRESS, SBT_ADDRESS, SERVICE_FEE_RATE, SUPER_PAYMASTER_ADDRESS, TEST_ACCOUNT_ADDRESSES, TEST_ACCOUNT_POOL_SIZE, TEST_COMMUNITIES, TEST_TOKEN_ADDRESSES, TOKEN_ADDRESSES, XPNTS_FACTORY_ADDRESS, applyConfig, describeSupportedChains, getCanonicalAddresses, isSupportedChainId, listSupportedChainIds } from './chunk-NRH56SAJ.js';
|
|
16
16
|
import './chunk-PZ5AY32C.js';
|
|
17
17
|
import { keccak256, stringToBytes, createClient, publicActions, walletActions, parseAbi, decodeAbiParameters, encodeAbiParameters, zeroAddress, decodeErrorResult, formatEther, http, createPublicClient, createWalletClient, parseEther, erc20Abi, concat, pad, parseAbiParameters, toBytes, encodeFunctionData } from 'viem';
|
|
18
18
|
import { generatePrivateKey, privateKeyToAccount } from 'viem/accounts';
|
|
@@ -32,7 +32,7 @@ function createEndUserClient({
|
|
|
32
32
|
const chainDefaults = getCanonicalAddresses(chain.id);
|
|
33
33
|
if (!chainDefaults && !addresses) {
|
|
34
34
|
throw new Error(
|
|
35
|
-
`[createEndUserClient] No canonical addresses for chainId ${chain.id}. Pass \`addresses\` explicitly, or use a supported chain: ${
|
|
35
|
+
`[createEndUserClient] No canonical addresses for chainId ${chain.id}. Pass \`addresses\` explicitly, or use a supported chain: ${describeSupportedChains()}.`
|
|
36
36
|
);
|
|
37
37
|
}
|
|
38
38
|
const usedAddresses = { ...CORE_ADDRESSES, ...TOKEN_ADDRESSES, ...TEST_ACCOUNT_ADDRESSES, ...chainDefaults, ...addresses };
|
|
@@ -232,7 +232,7 @@ function createEndUserClient({
|
|
|
232
232
|
async checkJoinRequirements(address) {
|
|
233
233
|
const accountToUse = address || account?.address;
|
|
234
234
|
if (!accountToUse) throw new Error("Account address required for requirement check");
|
|
235
|
-
const { RequirementChecker: RequirementChecker2 } = await import('./index.node-
|
|
235
|
+
const { RequirementChecker: RequirementChecker2 } = await import('./index.node-KIKM4EG6.js');
|
|
236
236
|
const checker = new RequirementChecker2(client, usedAddresses);
|
|
237
237
|
return await checker.checkRequirements({
|
|
238
238
|
address: accountToUse,
|
|
@@ -242,7 +242,7 @@ function createEndUserClient({
|
|
|
242
242
|
});
|
|
243
243
|
},
|
|
244
244
|
async createSmartAccount({ owner, salt = 0n }) {
|
|
245
|
-
const { SimpleAccountFactoryABI: SimpleAccountFactoryABI2 } = await import('./index.node-
|
|
245
|
+
const { SimpleAccountFactoryABI: SimpleAccountFactoryABI2 } = await import('./index.node-KIKM4EG6.js');
|
|
246
246
|
const { encodeFunctionData: encodeFunctionData2, concat: concat2 } = await import('viem');
|
|
247
247
|
let factoryAddress = usedAddresses.simpleAccountFactory;
|
|
248
248
|
console.log(` SDK: Using SimpleAccountFactory: ${factoryAddress} (Owner: ${owner}, Salt: ${salt})`);
|
|
@@ -273,7 +273,7 @@ function createEndUserClient({
|
|
|
273
273
|
if (isDeployed) {
|
|
274
274
|
console.log(` \u2139\uFE0F Account ${accountAddress} already deployed.`);
|
|
275
275
|
} else {
|
|
276
|
-
const { SimpleAccountFactoryABI: SimpleAccountFactoryABI2 } = await import('./index.node-
|
|
276
|
+
const { SimpleAccountFactoryABI: SimpleAccountFactoryABI2 } = await import('./index.node-KIKM4EG6.js');
|
|
277
277
|
let factoryAddress = usedAddresses.simpleAccountFactory;
|
|
278
278
|
if (!factoryAddress || factoryAddress === "0x0000000000000000000000000000000000000000") {
|
|
279
279
|
factoryAddress = "0x9406Cc6185a346906296840746125a0E44976454";
|
|
@@ -493,7 +493,7 @@ function createOperatorClient({
|
|
|
493
493
|
const chainDefaults = getCanonicalAddresses(chain.id);
|
|
494
494
|
if (!chainDefaults && !addresses) {
|
|
495
495
|
throw new Error(
|
|
496
|
-
`[createOperatorClient] No canonical addresses for chainId ${chain.id}. Pass \`addresses\` explicitly, or use a supported chain: ${
|
|
496
|
+
`[createOperatorClient] No canonical addresses for chainId ${chain.id}. Pass \`addresses\` explicitly, or use a supported chain: ${describeSupportedChains()}.`
|
|
497
497
|
);
|
|
498
498
|
}
|
|
499
499
|
const usedAddresses = { ...CORE_ADDRESSES, ...TEST_TOKEN_ADDRESSES, ...TEST_ACCOUNT_ADDRESSES, ...chainDefaults, ...addresses };
|
|
@@ -708,7 +708,7 @@ function createCommunityClient({
|
|
|
708
708
|
const chainDefaults = getCanonicalAddresses(chain.id);
|
|
709
709
|
if (!chainDefaults && !addresses) {
|
|
710
710
|
throw new Error(
|
|
711
|
-
`[createCommunityClient] No canonical addresses for chainId ${chain.id}. Pass \`addresses\` explicitly, or use a supported chain: ${
|
|
711
|
+
`[createCommunityClient] No canonical addresses for chainId ${chain.id}. Pass \`addresses\` explicitly, or use a supported chain: ${describeSupportedChains()}.`
|
|
712
712
|
);
|
|
713
713
|
}
|
|
714
714
|
const usedAddresses = { ...CORE_ADDRESSES, ...TEST_TOKEN_ADDRESSES, ...chainDefaults, ...addresses };
|
|
@@ -980,7 +980,7 @@ function createAdminClient({
|
|
|
980
980
|
const chainDefaults = getCanonicalAddresses(chain.id);
|
|
981
981
|
if (!chainDefaults && !addresses) {
|
|
982
982
|
throw new Error(
|
|
983
|
-
`[createAdminClient] No canonical addresses for chainId ${chain.id}. Pass \`addresses\` explicitly, or use a supported chain: ${
|
|
983
|
+
`[createAdminClient] No canonical addresses for chainId ${chain.id}. Pass \`addresses\` explicitly, or use a supported chain: ${describeSupportedChains()}.`
|
|
984
984
|
);
|
|
985
985
|
}
|
|
986
986
|
const usedAddresses = { ...CORE_ADDRESSES, ...TOKEN_ADDRESSES, ...chainDefaults, ...addresses };
|