MicroManus is an internet-connected deep-research workspace with GitHub authentication, a credit paywall, bring-your-own-model credentials, iterative search, cited answers, PDF reports, and transparent token-level costs.
- Install Node.js 20 or newer and run
npm install. - Copy
.env.exampleto.env.localand add the services you want to exercise. - Run
npm run devand openhttp://localhost:3000.
With no Supabase variables, the application automatically enables its isolated evaluation workspace. Redeem SID_DRDROID, then add a model API key under Providers. Evaluation keys live only in sessionStorage and disappear when the browser session closes. Tavily is preferred for search; without it, the agent uses Wikipedia's public API as a limited fallback.
The repository's OPENAI_API_KEY is deliberately ignored. Model credentials must come from the signed-in user.
- Create a Supabase project and run
supabase/migrations/001_initial_schema.sqlin its SQL editor or through the Supabase CLI. - Enable GitHub under Authentication > Providers and add the GitHub OAuth client credentials.
- Configure the callback URL as
https://YOUR_DOMAIN/auth/callbackin Supabase and add Supabase's callback URL to the GitHub OAuth app. - Set
NEXT_PUBLIC_SUPABASE_URL,NEXT_PUBLIC_SUPABASE_ANON_KEY, andSUPABASE_SERVICE_ROLE_KEY. - Set
CREDENTIAL_ENCRYPTION_KEYto 32 random bytes encoded as base64, for example withopenssl rand -base64 32.
The migration enables row-level security on all user-owned data and exposes atomic functions for coupon redemption, Stripe grants, and completed research runs.
- Set
STRIPE_SECRET_KEYandNEXT_PUBLIC_STRIPE_PUBLISHABLE_KEYfrom a Stripe test account. - Create a webhook pointing to
https://YOUR_DOMAIN/api/stripe/webhook. - Subscribe it to
checkout.session.completedand set the resulting signing secret asSTRIPE_WEBHOOK_SECRET. - Use Stripe's test card
4242 4242 4242 4242, any future expiry, and any CVC to exercise the $5 Checkout flow.
Checkout sessions are created server-side. Credit grants and event recording happen in one idempotent database transaction, so webhook retries cannot duplicate credits.
Set TAVILY_API_KEY for broad web research and NEXT_PUBLIC_APP_URL to the production origin. Disable the evaluation entry point in production with NEXT_PUBLIC_DEMO_MODE=false.
npm run lint
npm run typecheck
npm test
npm run build
npm run build:nextnpm run build runs the standard Next.js production build that Netlify should use through netlify.toml. npm run build:sites remains available only for the legacy local Sites packaging flow that was already verified in this workspace.
The repository now includes netlify.toml for a standard Netlify deployment. Use the Next.js build pipeline, then set the same runtime environment variables from the production setup section in Netlify's dashboard. The app remains fully server-rendered and keeps its route handlers, auth flows, and PDF generation intact.
Provider APIs report token usage differently. MicroManus normalizes OpenAI-compatible cached prompt tokens and Anthropic cache read/write tokens, then snapshots the selected model's rates with every completed run.