This is a Next.js project bootstrapped with v0.
This repository is linked to a v0 project. You can continue developing by visiting the link below -- start new chats to make changes, and v0 will push commits directly to this repo. Every merge to main will automatically deploy.
First, run the development server:
npm run dev
# or
yarn dev
# or
pnpm devOpen http://localhost:3000 with your browser to see the result.
You can start editing the page by modifying app/page.tsx. The page auto-updates as you edit the file.
Private payments use the following environment variables:
PAYMENTS_API_BASE_URL: base URL for the payments API.CLUSTER: cluster name passed to the payments API and used for Solana Explorer links. Supported values aredevnet,testnet, andmainnet-beta.PAYMENTS_CLUSTER: legacy fallback for the payments API cluster.CLUSTERtakes precedence if both are set. If this value is an RPC URL containingdevnet,testnet, ormainnet, the app infers the corresponding cluster name.NEXT_PUBLIC_PAYMENTS_TEST_USDC_MINT: overrides the default payment mint in the UI.
Example:
PAYMENTS_API_BASE_URL=http://localhost:8787 \
CLUSTER=devnet \
SOLANA_RPC_URL=https://rpc.magicblock.app/devnet \
NEXT_PUBLIC_SOLANA_RPC_URL=https://rpc.magicblock.app/devnet \
NEXT_PUBLIC_PAYMENTS_TEST_USDC_MINT=4zMMC9srt5Ri5X14GAgXhaHii3GnPAEERYPJgZJDncDU \
yarn dev -p 3002With CLUSTER=devnet, the app sends cluster=devnet to the payments API and opens transactions on https://explorer.solana.com with the devnet cluster selected.
To learn more, take a look at the following resources:
- Next.js Documentation - learn about Next.js features and API.
- Learn Next.js - an interactive Next.js tutorial.
- v0 Documentation - learn about v0 and how to use it.