Semrush API
Research keywords, organic search rankings, and ad research for a chosen market through SpideyData's Semrush API (Beta).
On this page
Semrush API endpoints
6Find the task you need. Each endpoint includes its parameters, request example, and response reference.
Track organic search positions with Semrush
Read a domain's organic keyword positions for the selected market and paginate the results.
Find a domain’s top pages
Rank URLs by traffic and see their keywords, search sources and intent.
Research keyword metrics
Retrieve keyword overview data for a market, preserving missing metrics as unavailable.
Discover keyword ideas
Explore keyword suggestions for the supplied seed and selected market.
Inspect search engine results
Retrieve SERP research for a keyword in the selected market.
Research keyword content
Read keyword content research using the endpoint's supported inputs and response fields.
Quick start
Submit a domain or keyword and select its market. For primary Organic Positions queries, coverage after page 3 is not confirmed.
https://kieapi.comcurl -X POST "https://kieapi.com/v1/semrush/keyword-overview" \
-H "Authorization: Bearer $SPIDER_API_KEY" \
-H 'Idempotency-Key: seo-example-01' \
-H "Content-Type: application/json" \
-d '{
"phrase": "example keyword",
"database": "us",
"currency": "USD",
"device": 0
}'Authentication
Team administrators manage API keys in Team Settings. Each key keeps its Team and billing scope when its creator leaves or switches Teams. Keys cannot manage members, billing or other keys. Public /v1 requests use Authorization: Bearer $SPIDER_API_KEY only; the Key's fixed Team is the payer. An optional X-Spider-Team-Id must match that Team or the request is denied. Creating, listing, rotating or revoking Keys through the product console (and other non-identity console business routes) requires X-Spider-Team-Id when the Team model is enabled; omitting it returns HTTP 409 team_context_required.
Validated delivery
Top pages ranks URLs by traffic in the current daily domain report. Read modules.top_pages.data.rows and total. Set page (1–100, default 1) and page_size (1–100, default 100). Each successful page is billed once, including a valid empty page. Use a new request key for the next page. The tool field is always semrush. The task field matches the requested endpoint. Response examples are illustrative, not live provider results. Success, partial or failed, with validated business data for each child. An empty keyword overview is successful with keywords: [] and selected: null: no data, not zero metrics. It is billable, cacheable and does not trigger backup. Shared capacity supports automatic backup for organic positions and keyword overview. The response records the fallback reason and actual data dates; strict historical queries can disable latest fallback. Organic Positions pagination keeps one cached provider snapshot.
Requires a Team API key. Complete modules are billed; incomplete modules are not charged. If a response is lost, retry with the same request key to read the saved result without a second charge. Valid empty data is successful.
A dedicated API key uses only its assigned capacity and fresh snapshots. Exhaustion returns the corresponding error, including in automatic mode. Temporary provider issues are retried automatically within the same request, up to 60 seconds by default; retries are not charged. A keyword request can wait once for capacity if setup uses the minute quota before the query starts. Keep the request open during this wait. HTTP 429 `seo_local_rate_limited` includes a `Retry-After` header. Wait for that interval before retrying. After a completed failure, use a new key for a new attempt.
