This file provides guidance to Codex (Codex.ai/code) when working with code in this repository.
This is the Stellar PH Bootcamp bootcamp repository — a participant-facing guide, not a production codebase. It packages:
README.md— 5-step walkthrough: install toolchain → complete assigned Soroban contract →cargo test(≥3 tests) → deploy to Stellar testnet → submit on Rise In.docs/reference/pre-workshop-setup-guide.pdf— participant install guide (Rust, Stellar CLI, WASM target, Freighter).docs/reference/freighter-integration.md— generalized Next.js + Soroban + Freighter integration recipe.frontend/— Next.js 16 (App Router) + React 19 dApp using@stellar/stellar-sdkand@stellar/freighter-api. Composition:app/(layout, page,/about,/app,/issuer,/issuer/register,/issuer/batch,/proof,/proof/[hash],/proof/[hash]/embed),components/(about/,actions/,activity/,app/,demo/,issuer/,landing/,layout/,milestones/,onboarding/,proof/,ui/,wallet/),hooks/,lib/(config, contract-client, contract-read-server, demo-data, errors, events, format, freighter, i18n, issuer-registry, motion, proof-metadata, types, utils, with-timeout, batch-issuance),styles/globals.css(Tailwind v4@themedesign tokens). Security: HTTP security headers + CSP innext.config.ts; dynamic proof routes cached withrevalidate=60and guarded with a hex-format check before any RPC call.docs/archive/bootcamp-setup-2026-04/setup-todo.md— archived local setup progress tracker (A–E sections: Environment, Manual pre-workshop, Contract deploy, Rise In, Phase 2 fullstack).docs/archive/bootcamp-setup-2026-04/fullstack-prompt-template.md— archived v3 prompt template for generating a Stellar dApp idea + Soroban contract files + frontend design brief. Used in Phase 2 after the Contract ID is deployed. Refined against thestellar-dev,ui-ux-pro-max, andsuperpowers/writing-skillsplugins.
The assigned Soroban contract itself is not in this repo — participants clone a separate facilitator-provided contract repo.
npm install
npm run dev # next dev
npm run build # next build
npm run start # next start (after build)
npm run lint # next lintDo not assume the local shell has Rust, Cargo, Stellar CLI, or a funded key on PATH. Verify the active runtime first.
Known project baseline from the original codespace was Rust 1.95, wasm32v1-none + wasm32-unknown-unknown targets, Stellar CLI 27.0.0 at ~/.local/bin/stellar, and a funded testnet key aliased my-key, but local Windows checkouts may differ.
export PATH="$PATH:$HOME/.local/bin" # if stellar is not on PATH
stellar --version
stellar keys address my-keycargo test
cargo build --target wasm32-unknown-unknown --release
stellar contract deploy \
--wasm target/wasm32-unknown-unknown/release/<crate>.wasm \
--source my-key \
--network testnet--globalflag is removed fromstellar keys generate— global is the default. Use--fundto auto-fund at creation:stellar keys generate my-key --network testnet --fund.- Prefer the prebuilt binary from GitHub releases over
cargo install --locked stellar-cliin constrained environments (the from-source build pulls hundreds of crates and can OOM in small containers).
The integration follows the flow documented in docs/reference/freighter-integration.md:
- Config layer reads
NEXT_PUBLIC_*env vars (RPC URL, network passphrase, contract ID, read address). Network passphrase must match the network the contract is deployed on. - Wallet layer (
lib/+hooks/) wraps@stellar/freighter-api— connection state, public key, network check, sign. - Contract client (
lib/) builds transactions with@stellar/stellar-sdk: read-only calls viasimulateTransactionusing the read address; writes sign via Freighter and submit via Soroban RPC. Handles ScVal arg serialization, return-value decoding, and error normalization. - UI components are marked
"use client"because Freighter is a browser-only API. - Security (
next.config.ts): CSP,X-Frame-Options,X-Content-Type-Options,Referrer-Policy,Permissions-Policy, and HSTS on every route./proof/[hash]pages validate the hash format before any RPC call and userevalidate=60for CDN caching.robots.tskeeps/proof/[hash]/embed,/talent/*,/opportunity/*, and/api/out of search; proof detail pages stay crawlable on purpose, for portfolio sharing.
When editing the frontend, treat the integration guide as the canonical spec.
- Don't commit
vs_buildtools.exe,install.cmd, or other Windows-only artifacts — this repo is consumed cross-platform and those belong in the PDF guide, not the tree. - Don't add a backend unless a participant's submission needs one (
backend/is explicitly optional per the README's repo structure). - Don't deploy to mainnet from examples — all flows target testnet.
- Don't add
Co-Authored-By: Codex(or any Codex co-author trailer) to commits, PRs, or otherghactions. Commits and PRs should be authored solely by the user. - Don't use the deprecated
soroban contract ...CLI in examples or docs — usestellar contract ...(Stellar CLI v21+).
Settled calls with reasons, so they are not re-litigated. Each was decided once and costs real time to reopen.
- The 62 testnet wallet accounts are 30 independent participants plus 32 QA accounts I operate. State that split beside the figure every time it appears, never the bare 62. A prior snapshot was 54 (30 independent plus 24 QA). The combined count is my decision and is not open for debate; what is required is that the split travels with it.
- Write in first person singular. This is a one-person build, so submission, pitch, and case-study copy says "I", never "we".
- Copy rules: no em dashes anywhere, "graduate" rather than "student", and every money reference qualified as Stellar testnet with no monetary value.
- Never modify seeded demo exhibit #1. A live demo surface reads it. Exhibit #0 is the released example; #1 must stay funded.
- Path-based i18n and hreflang routing were evaluated and rejected on 2026-07-20 as net-negative for a testnet demo. Do not re-propose international SEO.
/startis intentionally English-only, along with outreach copy pointing at it. Do not localize one without the other.- Community Stellar MCP repositories are not official. Only first-party dependencies belong in the MCP server.
See HANDOFF.md for repository state, branch invariants, and the traps that have already cost a debugging cycle.