Open
Conversation
- Add @aastar/sdk, @aastar/core, viem to backend and frontend
- Add aastar/.env.example with Sepolia canonical addresses
- Add aastar-frontend/env.local.template with NEXT_PUBLIC_ vars
- Verified backend builds and starts on port 3000 (401 on /api/v1/auth/profile)
- Verified applyConfig({ chainId: CHAIN_SEPOLIA }) loads correct addresses
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add RegistryModule with service, controller, and DTOs - GET /api/v1/registry/info: chain role member counts from Sepolia - GET /api/v1/registry/role-ids: all role hash constants - GET /api/v1/registry/role?address=: role check for any address (JWT) - GET /api/v1/registry/members?roleId=: role member list - GET /api/v1/registry/community?name=: community contract lookup - Fix build: use tsc directly with noEmitOnError=false (ox type compat) - Add tsconfig.build.json with src-only include scope - Add contract address config keys to configuration.ts - Verified: 42 communities, 2 SPO, 40 V4 ops, 37 end users on Sepolia Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add GET /role page: shows role badges, GToken balance, chain stats - Add navigation cards to community/operator/admin/dashboard by role - Add "My Role" nav item to desktop sidebar and mobile bottom bar - Add registryAPI client (getInfo, getRoleIds, getRole, getMembers) - Frontend build verified with /role route generated Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- NestJS CommunityService: getCommunityAdmins, getCommunityMetadata (decode ABI-encoded registry metadata), getDeployedTokenAddress via xPNTsFactoryActions, getTokenInfo, getGTokenBalance, getAllCommunities - REST endpoints: GET /community/list, /community/info, /community/token, /community/dashboard (JWT), /community/gtoken-balance (JWT), /community/addresses (contract addrs for frontend tx encoding) - Frontend /community page: My Community Status card (GToken balance, metadata, xPNTs token info), address lookup, community list grid - Layout: Community nav item added to desktop + mobile bottom nav - api.ts: communityAPI client (list, info, token, dashboard, gtoken-balance) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- NestJS OperatorService: getOperatorRoles, getSPOStatus (reads SuperPaymaster operators mapping + getStakeInfo from GTokenStaking), getV4PaymasterStatus (paymasterFactory.getPaymasterByOperator + ETH balance), getAllSPOOperators, getAllV4Operators, getOperatorDashboard - REST endpoints: GET /operator/spo/list, /operator/v4/list, /operator/status, /operator/dashboard (JWT), /operator/gtoken-balance (JWT), /operator/addresses - Frontend /operator page: My Operator Status with SPO/V4 badges, metric cards (GToken balance, stake, SP balance, exchange rate, V4 paymaster ETH), step-by-step registration guides, operator list sections (SPO + V4) - Layout: Operator nav item added to desktop + mobile bottom nav - api.ts: operatorAPI client Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- NestJS AdminService: getAllRoleConfigs (Registry roleConfigs + memberCount for Community/SPO/V4/EndUser roles), getRegistryStats (owner, version, counts), getGTokenStats (totalSupply, stakingContractBalance), getProtocolDashboard - REST endpoints: GET /admin/protocol (public), /admin/roles (public), /admin/gtoken (public), /admin/dashboard (JWT, adds isAdmin flag) - Frontend /admin page: Registry overview stats, Role Configurations table (minStake, entryBurn, exitFeePercent, active status, member count), GToken stats, System Contract Addresses listing - Layout: Protocol nav item added to desktop nav - api.ts: adminAPI client (protocol, roles, gtoken, dashboard) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- NestJS SaleService: reads GTokenSaleContract (getCurrentPriceUSD, tokensSold, stage limits, ceiling price, soldPercent, currentStage) and APNTsSaleContract (priceUSD, totalSold, availableInventory, limits, getAPNTsForUSD quote); addresses from env GTOKEN_SALE_ADDRESS + APNTS_SALE_ADDRESS - REST endpoints: GET /sale/overview, /sale/gtoken/status, /sale/apnts/status, /sale/apnts/quote?usdAmount=, /sale/gtoken/events, /sale/gtoken/eligibility (JWT, checks hasBought), /sale/addresses - configuration.ts: added gTokenSaleAddress + aPNTsSaleAddress config keys - Frontend /sale page: GToken sale section (current price, tokens sold, 3-stage progress bar with stage markers, eligibility indicator), aPNTs sale section (fixed price, inventory, min/max limits, quote calculator) - Layout: Sale nav item added to desktop nav - api.ts: saleAPI client Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- jest.config.js: ts-jest config for aastar backend package - registry.service.spec.ts: 7 tests — getUserRoles, getRoleMembers, getRoleUserCount, getGTokenBalance, getCommunityByName, getRegistryInfo, getRoleIds - community.service.spec.ts: 5 tests — getCommunityAdmins, isCommunityAdmin, getCommunityMetadata (null for empty), getDeployedTokenAddress (null for zero), getContractAddresses - operator.service.spec.ts: 5 tests — getOperatorRoles, getAllSPOOperators, getAllV4Operators, getContractAddresses - admin.service.spec.ts: 5 tests — isProtocolAdmin, getAllRoleConfigs, getRegistryStats, getGTokenStats - sale.service.spec.ts: 12 tests — not-configured paths + configured paths (getGTokenSaleStatus with mocked readContract calls, getAPNTsSaleQuote) - All 5 service mock @aastar/core + viem to run without network access Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Complete acceptance report covering M0-M10: - 5 NestJS modules (registry, community, operator, admin, sale) - 5 frontend routes (/role, /community, /operator, /admin, /sale) - APNTsSaleContract (Solidity, 28 tests) - 34 unit tests (NestJS services) - 62 Foundry tests (GToken + GovernanceToken + APNTs) - Known issues & solutions documented - Live Sepolia data verification notes Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Documents the 5 new portal routes (/role /community /operator /admin /sale), startup commands, required env vars, API endpoints, and test results. References MANAGEMENT_PORTAL_ACCEPTANCE.md for full details. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Remove redundant ETH_RPC_URL entry (already configured in .env). Add aastar/env.sepolia.example: all Sepolia canonical contract addresses and deploy commands for the two sale contracts (not yet deployed). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Add all runtime, JWT, KMS, EntryPoint, and AAStar core contract fields. Separate deploy-inputs (PRIVATE_KEY_SUPPLIER, TREASURY_ADDRESS, USDC_ADDRESS) from deploy-outputs (GTOKEN_SALE_ADDRESS, APNTS_SALE_ADDRESS, both pending). Deploy outputs write here after forge broadcast, not into .env. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
GTokenSaleContract: 0xfb1D40C882aDe3402B41ACc3260FC59a3E18aA9b APNTsSaleContract: 0x7fcDab5970697B130eA87d0c500dC213f4ba499F Both verified on Sepolia Etherscan. USDC whitelisted on APNTs contract. Treasury: Safe multisig 0x51eDf11fDb0A4F66220eFb8efA54Eca77232E114 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Add three shell scripts for managing the development environment: - dev.sh: start/stop/restart both services together - backend.sh: manage NestJS backend (port 3000) - frontend.sh: manage Next.js frontend (port 5173) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Switch NestJS compiler from tsc to SWC (nest-cli.json builder: swc) to bypass ox library TypeScript type errors in node_modules - Fix circular dependency at runtime by using import type + string-based @manytoone references in account, passkey, transfer, user-nft, user-token entities (SWC lazy:false + CommonJS const exports exposed the circular require cycle that tsc hid) - Fix Swagger STABLECOIN/ERC721 circular dependency errors by adding type: 'string' to @apiquery decorators that use enum arrays, and replacing enum: EnumObject with enum: Object.values(EnumObj) in token and user-nft controllers - Move viewport/themeColor from metadata to generateViewport in frontend layout.tsx (Next.js 16 requirement) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Revert unnecessary SWC builder introduction. Fix ox library TS compilation errors by redirecting imports to declaration files via tsconfig.build.json paths override. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Replace `any` type with proper `PublicClient` import for viem clients. Add try/catch around key contract calls with sensible fallbacks. Remove hardcoded sepolia chain from createPublicClient. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Replace dynamic Tailwind class construction (bg-\${color}-100) with
static ROLE_COLOR_MAP lookup. Add string-based @manytoone refs and
import type to break circular dependency in entity files.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Move viewport/themeColor from metadata to separate generateViewport export per Next.js 16 requirements. Remove non-existent icon-192.png. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Pin viem to 2.43.3 across all workspaces to prevent ox@0.14.5 from entering dependency tree. Add root-level ox override. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add 🍄 mushroom emoji as app icon (192px, 512px, 180px apple-icon) - Revert PublicClient typing to any — viem 2.43.3 type system is incompatible with createPublicClient return type and readContract authorizationList requirements Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- startAuthentication/startRegistration now use { optionsJSON } format
required by @simplewebauthn/browser v13+
- Revert publicClient from PublicClient type to any — viem 2.43.3
type system incompatible with createPublicClient return type
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Update V7 factory address from old simpleAccountFactory (0x91E604...) to M4 AirAccount factory (0x914db0...) which supports getAddressWithDefaults. Also update validator to M4 validatorRouter address. Fixes account/create 500 error. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
JWT payload doesn't include walletAddress, so req.user.walletAddress is always undefined. Return default no-roles response instead of passing undefined to contract calls. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…lers Same pattern as registry fix - JWT payload lacks walletAddress, so controllers must return safe defaults instead of passing undefined to contract calls. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
All portal pages (role, community, operator, admin, sale) now use <Layout requireAuth> to prevent redirect-to-dashboard bug. Accent colors unified to slate/emerald theme. IPFS URLs proxied through Pinata gateway. Removed redundant auth checks handled by Layout. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
When database says deployed=false, getAccount now calls getCode to verify on-chain. If contract exists, auto-updates database. Prevents stale deployment status after successful first transaction. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…s pump icon Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Bundler estimates too-tight verificationGasLimit for M4 AirAccount validateUserOp, causing AA26 revert. First tx succeeded only because initCode triggered fallback 4M gas. Now all estimates get 3x buffer with 150k minimum. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Merges transfer history recipients into address book dropdown so users can quickly re-select previously used addresses. Recent addresses labeled separately from saved address book entries. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Basic account create and tx ok. Replace blind 3x gas multiplier with account-type-aware defaults (ECDSA vs BLS, deployment vs post-deploy). Add auto-retry on AA26 (up to 2 retries with escalating gas multiplier). Display actual gas used and cost on transfer result page. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Base defaults already include buffer, so 2x→4x was too aggressive. Changed to 2x on first retry, 3x on second. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
📝 What does this PR do?
Brief description of the changes.
🎯 Related Issue
Fixes #(issue) or Relates to #(issue)
🧪 Testing
✅ Checklist