diff --git a/.circleci/config.yml b/.circleci/config.yml new file mode 100644 index 0000000..9f6498a --- /dev/null +++ b/.circleci/config.yml @@ -0,0 +1,31 @@ +# Use the latest 2.1 version of CircleCI pipeline process engine. +# See: https://circleci.com/docs/configuration-reference +version: 2.1 +# +# Define a job to be invoked later in a workflow. +# See: https://circleci.com/docs/jobs-steps/#jobs-overview & https://circleci.com/docs/configuration-reference/#jobs +jobs: + say-hello: + # Specify the execution environment. You can specify an image from Docker Hub or use one of our convenience images from CircleCI's Developer Hub. + # See: https://circleci.com/docs/executor-intro/ & https://circleci.com/docs/configuration-reference/#executor-job + docker: + # Specify the version you desire here + # See: https://circleci.com/developer/images/image/cimg/base + - image: cimg/base:current + + # Add steps to the job + # See: https://circleci.com/docs/jobs-steps/#steps-overview & https://circleci.com/docs/configuration-reference/#steps + steps: + # Checkout the code as the first step. + - checkout + - run: + name: "Say hello" + command: "echo Hello, World!" + +# Orchestrate jobs using workflows +# See: https://circleci.com/docs/workflows/ & https://circleci.com/docs/configuration-reference/#workflows +workflows: + say-hello-workflow: # This is the name of the workflow, feel free to change it to better match your workflow. + # Inside the workflow, you define the jobs you want to run. + jobs: + - say-hello diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS new file mode 100644 index 0000000..3d40a6a --- /dev/null +++ b/.github/CODEOWNERS @@ -0,0 +1 @@ +* @alchemyplatform/wallet-services diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000..4f9e7e4 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,39 @@ +--- +name: Bug report +about: Create a report to help us improve +title: '' +labels: '' +assignees: '' + +--- + +**Describe the bug** +A clear and concise description of what the bug is. + +**To Reproduce** +Steps to reproduce the behavior: +1. Go to '...' +2. Click on '....' +3. Scroll down to '....' +4. See error + +**Expected behavior** +A clear and concise description of what you expected to happen. + +**Screenshots** +If applicable, add screenshots to help explain your problem. + +**Desktop (please complete the following information):** + - OS: [e.g. iOS] + - Browser [e.g. Chrome, Safari] + - Browser [e.g. chrome, safari] + - Version [e.g. 22] + +**Smartphone (please complete the following information):** + - Device: [e.g. iPhone 6] + - OS: [e.g. iOS8.1] + - Browser [e.g. stock browser, safari] + - Version [e.g. 22] + +**Additional context** +Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/custom.md b/.github/ISSUE_TEMPLATE/custom.md new file mode 100644 index 0000000..48d5f81 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/custom.md @@ -0,0 +1,10 @@ +--- +name: Custom issue template +about: Describe this issue template's purpose here. +title: '' +labels: '' +assignees: '' + +--- + + diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000..72cc8d0 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,20 @@ +--- +name: Feature request +about: Suggest an idea for this project +title: '' +labels: '' +assignees: '' + +--- + +**Is your feature request related to a problem? Please describe.** +A clear and concise description of what the problem is. e.g., I'm always frustrated when [...] + +**Describe the solution you'd like** +A clear and concise description of what you want to happen. + +**Describe alternatives you've considered** +A clear and concise description of any alternative solutions or features you've considered. + +**Additional context** +Add any other context or screenshots about the feature request here. diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..79e54d6 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,27 @@ +# To get started with Dependabot version updates, you'll need to specify which +# package ecosystems to update and where the package manifests are located. +# Please see the documentation for all configuration options: +# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file + +version: 2 +updates: + - package-ecosystem: "npm" + directory: "/" + schedule: + interval: "weekly" + - package-ecosystem: "npm" + directory: "/accept-a-payment/" + schedule: + interval: "weekly" + - package-ecosystem: "npm" + directory: "/accept-a-payment/client/" + schedule: + interval: "weekly" + - package-ecosystem: "npm" + directory: "/accept-a-payment/server/" + schedule: + interval: "weekly" + - package-ecosystem: "npm" + directory: "/alchemy-demo/" + schedule: + interval: "weekly" diff --git a/.github/workflows/Vercel Preview Deployment.yml b/.github/workflows/Vercel Preview Deployment.yml new file mode 100644 index 0000000..ca7ca97 --- /dev/null +++ b/.github/workflows/Vercel Preview Deployment.yml @@ -0,0 +1,22 @@ +name: Playwright Tests + +on: + repository_dispatch: + types: + - 'vercel.deployment.success' +permissions: + contents: read +jobs: + run-e2es: + if: github.event_name == 'repository_dispatch' + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + with: + ref: ${{ github.event.client_payload.git.sha }} + - name: Install dependencies + run: npm ci && npx playwright install --with-deps + - name: Run tests + run: npx playwright test + env: + BASE_URL: ${{ github.event.client_payload.url }} diff --git a/.github/workflows/nextjs.yml b/.github/workflows/nextjs.yml new file mode 100644 index 0000000..eaac321 --- /dev/null +++ b/.github/workflows/nextjs.yml @@ -0,0 +1,93 @@ +# Sample workflow for building and deploying a Next.js site to GitHub Pages +# +# To get started with Next.js see: https://nextjs.org/docs/getting-started +# +name: Deploy Next.js site to Pages + +on: + # Runs on pushes targeting the default branch + push: + branches: ["main"] + + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages +permissions: + contents: read + pages: write + id-token: write + +# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued. +# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete. +concurrency: + group: "pages" + cancel-in-progress: false + +jobs: + # Build job + build: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Detect package manager + id: detect-package-manager + run: | + if [ -f "${{ github.workspace }}/yarn.lock" ]; then + echo "manager=yarn" >> $GITHUB_OUTPUT + echo "command=install" >> $GITHUB_OUTPUT + echo "runner=yarn" >> $GITHUB_OUTPUT + exit 0 + elif [ -f "${{ github.workspace }}/package.json" ]; then + echo "manager=npm" >> $GITHUB_OUTPUT + echo "command=ci" >> $GITHUB_OUTPUT + echo "runner=npx --no-install" >> $GITHUB_OUTPUT + exit 0 + else + echo "Unable to determine package manager" + exit 1 + fi + - name: Setup Node + uses: actions/setup-node@v4 + with: + node-version: "20" + cache: ${{ steps.detect-package-manager.outputs.manager }} + - name: Setup Pages + uses: actions/configure-pages@v5 + with: + # Automatically inject basePath in your Next.js configuration file and disable + # server side image optimization (https://nextjs.org/docs/api-reference/next/image#unoptimized). + # + # You may remove this line if you want to manage the configuration yourself. + static_site_generator: next + - name: Restore cache + uses: actions/cache@v4 + with: + path: | + .next/cache + # Generate a new cache whenever packages or source files change. + key: ${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json', '**/yarn.lock') }}-${{ hashFiles('**/*.[jt]s', '**/*.[jt]sx') }} + # If source files changed but packages didn't, rebuild from a prior cache. + restore-keys: | + ${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json', '**/yarn.lock') }}- + - name: Install dependencies + run: ${{ steps.detect-package-manager.outputs.manager }} ${{ steps.detect-package-manager.outputs.command }} + - name: Build with Next.js + run: ${{ steps.detect-package-manager.outputs.runner }} next build + - name: Upload artifact + uses: actions/upload-pages-artifact@v3 + with: + path: ./out + + # Deployment job + deploy: + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + runs-on: ubuntu-latest + needs: build + steps: + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v4 diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000..26d3352 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,3 @@ +# Default ignored files +/shelf/ +/workspace.xml diff --git a/.idea/accounts-ui-kit.iml b/.idea/accounts-ui-kit.iml new file mode 100644 index 0000000..d6ebd48 --- /dev/null +++ b/.idea/accounts-ui-kit.iml @@ -0,0 +1,9 @@ + + + + + + + + + \ No newline at end of file diff --git a/.idea/caches/deviceStreaming.xml b/.idea/caches/deviceStreaming.xml new file mode 100644 index 0000000..6063103 --- /dev/null +++ b/.idea/caches/deviceStreaming.xml @@ -0,0 +1,1918 @@ + + + + + + \ No newline at end of file diff --git a/.idea/markdown.xml b/.idea/markdown.xml new file mode 100644 index 0000000..c61ea33 --- /dev/null +++ b/.idea/markdown.xml @@ -0,0 +1,8 @@ + + + + + + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 0000000..862d09b --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000..518f2e3 --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..35eb1dd --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/.idea/workspace.xml b/.idea/workspace.xml new file mode 100644 index 0000000..34bd36a --- /dev/null +++ b/.idea/workspace.xml @@ -0,0 +1,82 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1773969373195 + + + + + + + \ No newline at end of file diff --git a/README.md b/README.md index 018c431..dc68a45 100644 --- a/README.md +++ b/README.md @@ -10,9 +10,340 @@ Use this template to get started with **embedded smart wallets** using [Alchemy - One‑click NFT mint (no ETH required) - Server‑side rendering ready – session persisted with cookies - TailwindCSS + shadcn/ui components, React Query, TypeScript +# Smart Wallets + +> Build zero-friction user onboarding and transactions end-to-end with one SDK. + +smart wallets overview + + + Send your first transaction using the SDK or API. + + +## Everything You Need for Onchain Applications + + + + Email, social, biometric, or EOA login. + + + Remove gas fees for users. + + + Multiple transactions in 1 click on EVM & Solana. + + + Pre-built UI components or fully whitelabel. + + + +## Frameworks + + + + Pre-built React components and hooks. + + + Native mobile wallet experiences. + + + Framework-agnostic implementation. + + + Server-side wallet management. + + + +## Common Starting Places + + + + Build an onchain app from scratch with wallets and transactions. + + + Upgrade to smart wallets using EIP-7702 or direct wagmi integration. + + + Add wallet and transaction functionality to existing web2 applications. + + + Server-side applications with signing and sending on your backend. + + + +## Resources + + + + Troubleshoot issues or get in touch. + + + End-to-end guides for common features. + + + Save costs as you scale. + + + +# Choose Your Starting Point + +> Overview of our product offerings + + + + Low-level JSON-RPC for reading & writing blockchain data. + + + + Structured, indexed data for balances, NFTs, prices, and more. + + + + Account abstraction infrastructure for smart wallets. + + + + Launch dedicated rollups with full control over your L2. + + + + + Build faster with production-ready APIs, smart wallets and rollup infrastructure across 70+ chains. Create your free Alchemy API key and + get started today. + + +*** + +## 1. Node API + +The [Node API](/docs/reference/node-api-overview) gives you low-level access to standard JSON-RPC methods for interacting with blockchains. + +Use it for sending transactions, querying blocks and logs, and accessing state. It supports multiple chains; see the [Chain APIs Overview](/docs/reference/chain-apis-overview) page for the full list. + + + + Read & write interface for all blockchains supported by us. + + + + Subscribe to pending transactions, log events, new blocks, and more. + + + + Get insights into transaction processing and onchain activity. + + + + Non-standard RPC methods for inspecting and debugging transactions. + + + + High-performance real-time Solana data streaming interface. + + + +*** + +## 2. Data APIs + +The [Data APIs](/docs/reference/data-overview) provide structured, indexed data that would be difficult to get via RPC alone. + +Use it for NFT metadata, token balances, transaction histories, enriched transfers, and analytics. Optimized for high-volume reads, dashboards, and data-heavy applications. + + + + Build a complete portfolio view of a user's wallet across tokens and NFTs. + + + + Get historical transactions for any address in a single request. + + + + Access real-time and historical token prices. + + + + Find, verify, and display NFTs across major blockchains. + + + + Subscribe to onchain events like transfers, transactions, and balance changes. + + + + Simulate transactions and see their effects before you send them. + + + +*** + +## 3. Wallet APIs / Account Abstraction Infrastructure + +Our [Smart Wallets](/docs/wallets) product gives you everything you need to build zero-friction user flows, from sign-up to checkout, using smart contract accounts. + +Use these APIs to handle user operations, sponsor gas, and implement smart accounts with account abstraction. + + + + Bundler API Quickstart for handling user operations. + + + + Gas Manager API Quickstart for sponsoring gas fees. + + + + Send transactions with smart accounts. + + + +*** + +## 4. Rollups + +Our [Rollups](/docs/reference/rollups-quickstart) product helps you run a dedicated rollup with full control over transaction speed, cost, and functionality. + +Launching a rollup can unlock new revenue streams, enable novel use cases, and provide a better user experience. + +# View the Stack rollup framework. + + + Send your first transaction using the SDK or API. + + +## Everything You Need for Onchain Applications + + + + Email, social, biometric, or EOA login. + + + Remove gas fees for users. + + + Multiple transactions in 1 click on EVM & Solana. + + + Pre-built UI components or fully whitelabel. + + + +## Frameworks + + + + Pre-built React components and hooks. + + + Native mobile wallet experiences. + + + Framework-agnostic implementation. + + + Server-side wallet management. + + ![Smart Wallet Quickstart](https://github.com/user-attachments/assets/2903fb78-e632-4aaa-befd-5775c60e1ca2) +# Feature Support By Chain + +> Alchemy's current feature availability for each of its supported chains + + + + ![[Chains](https://dashboard.alchemy.com/chains)](https://alchemyapi-res.cloudinary.com/image/upload/v1764179964/docs/api-reference/alchemy-transact/transaction-simulation/523fb8a9a9d899921ee1046d0ff1b389967a9976d1c6112ebbbe071ddd1ef374-image.png) + + + ## 📍 Network & Demo Contract This quickstart is configured to run on **Arbitrum Sepolia** testnet, by default. A free demo NFT contract has been deployed specifically for this quickstart, allowing you to mint NFTs without any setup or deployment steps. The contract is pre-configured and ready to use out of the box. diff --git a/package.json b/package.json index 2e4afb9..85fbce0 100644 --- a/package.json +++ b/package.json @@ -20,20 +20,20 @@ "class-variance-authority": "^0.7.1", "clsx": "^2.1.1", "lucide-react": "^0.511.0", - "next": "14.2.4", + "next": "16.1.7", "react": "^18", "react-dom": "^18", "tailwind-merge": "^3.3.0", "tailwindcss-animate": "^1.0.7", "viem": "2.30.0", - "wagmi": "2.15.4" + "wagmi": "2.19.4" }, "devDependencies": { "@types/node": "^20", "@types/react": "^18", "@types/react-dom": "^18", - "eslint": "^8.57.0", - "eslint-config-next": "14.2.4", + "eslint": "^9.0.0", + "eslint-config-next": "16.1.4", "postcss": "^8", "tailwindcss": "^3.4.4", "typescript": "^5"