HTTP · OAuth 2.0 · MCP

The Spytrend API,
live.

The same 20 tools, over plain HTTP. Self-register a machine client, grab a token, call tools. No SDK required — though the official MCP SDKs make it one import.

[ QUICKSTART ]

From zero to first 200.

Standard OAuth 2.0 client_credentials. Three calls and you're in.

01

Self-register a machine client

One POST to /oauth2/register — no human, no browser, no email. You get a client_id and client_secret back.

curl -X POST https://mcp.spytrend.com/oauth2/register \
  -H 'Content-Type: application/json' \
  -d '{"client_name":"my-agent","grant_types":["client_credentials"],
       "response_types":[],"token_endpoint_auth_method":"client_secret_basic",
       "scope":"mcp:read"}'
02

Exchange for a token

client_credentials grant with HTTP Basic auth. Tokens live ~1 hour; refresh by repeating the call.

curl -X POST https://mcp.spytrend.com/oauth2/token \
  -u "$CLIENT_ID:$CLIENT_SECRET" \
  -d 'grant_type=client_credentials&scope=mcp:read&audience=https://mcp.spytrend.com/mcp'
03

Call the tools

JSON-RPC tools/call against the MCP endpoint with your Bearer token. Every tool from the catalog above.

curl -X POST https://mcp.spytrend.com/mcp \
  -H "Authorization: Bearer $ACCESS_TOKEN" \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json, text/event-stream' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call",
       "params":{"name":"search_ads","arguments":{"country":"BR","limit":5}}}'

Machine clients start on a free trial — 500 tokens, lifetime, per agent: about 25 default searches. A human owner can claim an agent onto their plan anytime; claimed agents share the owner's balance (Pro: 40,000 tokens a month).

[ TOOLS THAT MATTER ]

Start with these.

The full catalog is on the connect page. These are the ones most teams wire up first.

01toolsearch_ads

Filtered ad search: geo, vertical, status, landing domain, dates. 1 token per returned ad (default page 20).

02toolget_trends

Rankings by geo, advertisers, webmasters, apps, timeline or scaling creatives.

03toolsearch_webmasters

Affiliate networks with per-geo volume and dominant-geo relevance.

04toolget_usage

Plan, used, remaining. Checking is free — poll it as often as you like.

← back to connectOAuth 2.0 · client_credentials · RFC 8707