1
Create your account
Go to app.lightsage.com and sign up with your email. No credit card is required. Your account starts with 250 free credits — enough to run your first evaluations across multiple platforms.
The free plan includes 3 prompts per day across 1 AI platform. Upgrade to Pro ($100/month) to unlock all 17 platforms and 1,500 credits per month.
2
Add your API
After signing in, add your API by providing either:
- A documentation URL — Lightsage crawls your docs and detects endpoints, authentication patterns, and SDK information automatically
- A GitHub repository URL — Lightsage reads your README, OpenAPI spec, and code examples
3
Run your first evaluation
Once your API is added, run an evaluation from the dashboard. Lightsage sends implementation-style prompts to coding agents and answer engines — the kind of prompts developers actually use when building:
- “Add [your API] to my Next.js app”
- “Set up authentication with [your API]”
- “Connect [your API] with [common integration]”
4
Read your Visibility Score and API Performance results
After your evaluation completes, you’ll see two sets of results:Visibility Score — A 0–100 score reflecting how often AI platforms recommend your API for relevant prompts, weighted by platform reach and prompt intent. You’ll also see your share of voice against each competitor you added.API Performance — Endpoint-level scores across coding agents. For each endpoint, Lightsage reports:
- Eval score — Overall pass rate across all test runs
- Discovery score — Whether agents find the correct endpoint
- Tool call success rate — Whether generated code executes without errors
- Error recovery rate — Whether agents can fix failures when they occur
- Time to completion — How long agents take to finish a task using your endpoint
5
Install agent tracking middleware
Add one line of middleware to your Next.js app to detect which AI coding agents are visiting your docs and API endpoints in real time. This gives you live data on agent traffic without any performance impact.Install the package first:Then add your
middleware.ts
LIGHTSAGE_API_KEY to your environment variables. You can find your key in the Lightsage dashboard under Settings → API Keys.The middleware detects Claude Code, OpenCode, Cursor, Codex, and 6+ other coding agents visiting your site. Traffic appears in your dashboard under Agent Analytics within a few minutes.The
matcher pattern in the config excludes /api, /_next, and /admin routes by default. Adjust this to match your site structure.6
Set up prompt tracking
Prompt tracking runs your defined prompts across AI platforms on a schedule — daily or every other day — so you can monitor visibility trends over time instead of taking one-off snapshots.To set up prompt tracking:
- Go to Prompt Tracking in your dashboard
- Click Add prompt and enter an implementation-style prompt
- Select which AI platforms to run it on (answer engines cost 1 credit/run, coding agents cost 5 credits/run)
- Set a run frequency — daily for fast-moving competitive situations, alternate days for steady-state monitoring
- Save and Lightsage will run the prompt automatically on your schedule
Next steps
Understand your results
Learn what Visibility Score, Share of Voice, and API Performance metrics mean in detail.
Improve API Performance
Dig into endpoint-level scores and fix tool call failures.
Optimize for discovery
Add llms.txt, fix robots.txt, and improve error messages to boost agent recommendations.
Devtool Arena
See how your API ranks publicly against competitors on the free leaderboard.