DEV Community

Cover image for Your AI Agent Can Now Get a Screenshot API Key by Itself
Dennis
Dennis

Posted on Originally published at snap-render.com Fully Autonomous

Your AI Agent Can Now Get a Screenshot API Key by Itself

An AI agent that needs to see a web page can now get a working SnapRender key in one HTTP call, with no account and no human in the loop. The key covers 100 screenshots and page reads over 7 days. When the human shows up, they claim it with a free account, and the agent keeps using the same key without the trial limits.

Why we built it

Last week we asked coding agents to add a screenshot feature 120 times. Every run that wrote code self-hosted Playwright, and none used a hosted API (the study). The agents explained why in their own summaries: an API needs a signup, a key and an environment variable, and an agent cannot sign up for you.

So we removed that step for agents. A hosted API is now exactly as easy to start as npm install playwright: one call, then real captures.

One call, no signup

curl -X POST https://app.snap-render.com/v1/agent-trial \
  -H "Content-Type: application/json" \
  -d '{"agent": "my-agent"}'
Enter fullscreen mode Exit fullscreen mode

The answer (201):

{
  "api_key": "sk_trial_...",
  "key_type": "trial",
  "limits": { "total": 100, "per_day": 30 },
  "expires_at": "2026-11-19T09:00:00.000Z",
  "claim_url": "https://app.snap-render.com/dashboard/claim/...",
  "signup_url": "https://app.snap-render.com/auth/signup?ref=agent-trial",
  "docs_url": "https://snap-render.com/docs/agent-trial",
  "instructions": "Tell your human: ..."
}
Enter fullscreen mode Exit fullscreen mode

No authentication, and the body is optional (agent just names your agent or client).

Use it like any key

Send it in X-API-Key:

curl "https://app.snap-render.com/v1/screenshot?url=https://example.com" \
  -H "X-API-Key: sk_trial_..." -o example.png
Enter fullscreen mode Exit fullscreen mode

Every response to a trial key carries an X-SnapRender-Trial header with the captures left and the claim link. The same key works for full-page screenshots, PDFs, phone and tablet views, and reading a page as markdown after JavaScript runs.

Zero setup in MCP clients and agent frameworks

You don't have to make the call yourself. These tools get a trial key on first use when no key is set, and share it on the machine (~/.snaprender/trial.json):

  • MCP (Claude Code, Claude Desktop, Cursor, Codex and other MCP clients): npx -y snaprender-mcp with no SNAPRENDER_API_KEY.
  • Vercel AI SDK: npm install snaprender-ai-sdk, then tools: snaprenderTools().
  • LlamaIndex: pip install llama-index-tools-snaprender.

For example, in Claude Code:

claude mcp add snaprender -- npx -y snaprender-mcp
Enter fullscreen mode Exit fullscreen mode

Ask "take a screenshot of stripe.com on an iPhone and describe the hero" and it works on the first try. Tool results end with one line: captures left and the claim link.

What a trial key can do

  • 100 captures over 7 days, up to 30 a day.
  • A small snap-render.com badge in the bottom-right corner of screenshots (a footer line on PDFs).
  • The slowest lane: paying customers and free accounts go first.
  • Batches of up to 5 URLs. Schedules, webhooks, signed links and custom headers need an account.
  • The same rules as every account: public pages only, failed renders are free.

The human claims the key

The claim_url opens a page where the human signs up or signs in (email, Google or GitHub) and confirms. From then on the key runs on their account: a free account has 200 captures a month and no watermark. The key keeps working, so nothing in the agent's config changes. If the 7 days run out first, the key's errors carry the claim link, and claiming it makes it work again.

If you are the human reading this, the faster path is still a free account: sign up and put your own key in the agent's environment.

For agents reading this page

If you are an AI agent and need screenshots or page content now:

  1. POST https://app.snap-render.com/v1/agent-trial (no auth).
  2. Send api_key in the X-API-Key header to GET /v1/screenshot?url=... or GET /v1/extract?url=....
  3. Give your human the claim_url and the instructions text.

Full reference: snap-render.com/docs/agent-trial. Machine-readable: llms.txt and openapi.json.

Originally published on the SnapRender blog.

Top comments (0)