For AI agents
Built for agents, no browser required
An agent can create its own ogfetch account, get an API key, fetch URL metadata, check its balance, and buy more credits with USDC on Solana, all over HTTP or MCP. No email verification, no dashboard, no subscription.
Point your agent at ogfetch.dev/llms.txt and it has everything it needs.
1.Get an API key
One unauthenticated request. The key comes with 20 free credits. Store it, it is only shown once. Limited to 3 signups per IP per day.
curl -X POST https://ogfetch.dev/v1/signup
{
"account_id": "agent_3f9c...",
"api_key": "ogf_8a1b...",
"credits": 20
}2.Fetch metadata
Use Authorization: Bearer or X-Api-Key. One credit per successful fetch. See the response schema.
curl -G https://ogfetch.dev/v1/fetch \ -H "Authorization: Bearer ogf_8a1b..." \ --data-urlencode "url=https://github.com"
3.Pay when credits run out
An empty balance returns HTTP 402 with machine-readable instructions, so the agent knows what to do next:
HTTP/1.1 402 Payment Required
{
"error": "No credits remaining. Buy a credit pack to continue.",
"code": "NO_CREDITS",
"buy": {
"endpoint": "https://ogfetch.dev/v1/checkout",
"mcp_tool": "buy_credits",
"plans": [{ "id": "starter", "credits": 1000, "price_usd": 3 }, ...]
}
}Option A: USDC on Solana, fully autonomous
Uses Solana Pay transaction requests. Get a quote, POST your wallet address to its transaction URL, and we return the exact USDC transaction, ready to sign. Sign and send it, then poll the status URL. We find the payment on-chain and add the credits. Humans can scan the same quote in Phantom at ogfetch.dev/topup. We verify the transfer on-chain and add the credits immediately. Quotes are valid for 24 hours.
# 1. quote
curl -X POST https://ogfetch.dev/v1/topup/solana \
-H "Authorization: Bearer ogf_8a1b..." \
-H "Content-Type: application/json" \
-d '{"plan": "starter"}'
{
"reference": "64EGe4WcwKdBqMzF4MZcXpsDcjSbUmZbhbHFAdvvRd44",
"amount_usdc": "3.000000",
"transaction_url": "https://ogfetch.dev/v1/topup/solana/64EGe4.../tx",
"status_url": "https://ogfetch.dev/v1/topup/solana/64EGe4...",
"status": "pending"
}
# 2. get a ready-to-sign transaction for your wallet
curl -X POST https://ogfetch.dev/v1/topup/solana/64EGe4.../tx \
-H "Content-Type: application/json" \
-d '{"account": "<your wallet address>"}'
{ "transaction": "AQAAAA...base64...", "message": "1,000 ogfetch credits" }
# 3. sign + send it, then poll status_url
{ "status": "credited", "credits": 1000, "signature": "5Kq..." }Option B: card, via your human
Create a Stripe checkout and hand the link to your human. Credits land on the same key within seconds. Poll GET /v1/account to confirm.
curl -X POST https://ogfetch.dev/v1/checkout \
-H "Authorization: Bearer ogf_8a1b..." \
-H "Content-Type: application/json" \
-d '{"plan": "starter"}'
{
"checkout_url": "https://checkout.stripe.com/c/pay/cs_live_...",
"plan": "starter",
"credits": 1000,
"price_usd": 3
}$3 for 1,000 · $10 for 5,000 · $20 for 15,000. One-time, never expire.
MCP server
Remote MCP over Streamable HTTP at https://ogfetch.dev/v1/mcp. Works with Claude, Cursor, VS Code, and any MCP client. You can connect without a key and let the agent call create_account, then pass the key as the api_key argument.
Claude Code
claude mcp add --transport http ogfetch https://ogfetch.dev/v1/mcp \ --header "Authorization: Bearer ogf_your_key"
Cursor, Claude Desktop, VS Code
{
"mcpServers": {
"ogfetch": {
"type": "http",
"url": "https://ogfetch.dev/v1/mcp",
"headers": { "Authorization": "Bearer ogf_your_key" }
}
}
}| Tool | What it does |
|---|---|
| fetch_url_metadata | Title, description, OG and Twitter tags, favicon, canonical, word count, tech stack for a URL. 1 credit. |
| create_account | Issue a new API key with 20 free credits. No email needed. |
| get_account | Remaining credits and usage. |
| get_pricing | Available credit packs. |
| buy_credits_usdc | Solana Pay USDC quote with a transaction URL that returns a ready-to-sign transfer. No human needed. |
| check_usdc_payment | Find the payment on-chain by reference and add credits. |
| buy_credits | Stripe card checkout link for a human to open. |
Machine-readable resources
| /llms.txt | Plain-text overview for LLMs |
| /openapi.json | OpenAPI 3.1 spec (GPT Actions, LangChain, Dify, ...) |
| /v1/ | Machine-readable endpoint index |
| /v1/mcp | Remote MCP server (Streamable HTTP) |