Docs / API reference
API reference
JSON over HTTPS for every seospark tool: the same tools, data and credits as the dashboard and the MCP server. Every endpoint below is generated from the API itself, so what you read is what it does.
- Base URL
- api.seospark.io/v2
- Format
- JSON
- Auth
- Bearer API key
- Spec
- OpenAPI 3.1
Authentication
Send an API key in the Authorization header of every request. Owners create keys in the dashboard under Settings › API keys; more about keys.
curl https://api.seospark.io/v2/account \ -H "Authorization: Bearer $SEOSPARK_KEY"
Responses and cost
Every success has the same envelope. data is what the endpoint returns; cost is the credits this call used, also in the x-credits-used header. Reading results is free; starting work is what costs.
{
"status": "success",
"data": { … },
"cost": 2480
}{
"status": "error",
"error_code": "bad_request",
"message": "keywords: Too small: expected array to have >=10 items",
"invalid_fields": ["keywords"]
}Runs that take a while
Clustering, metrics lookups, People Also Ask and other heavy work run in the background. Starting one returns a run with an id and status: "processing". Read it again until the status is succeeded (or failed; its credits stay spent, since the data was already requested), then read its results. Every run also shows up in the dashboard’s History.
Lists of results are paged the same way everywhere:
page_index(from 0) andpage_sizein the query;total_count,page_index,page_sizeanditemsin the answer.
Rate limits
A key may make 300 requests a minute, 60 of them POSTs. x-ratelimit-limit, x-ratelimit-remaining and x-ratelimit-reset say where you stand; over the limit you get 429 rate_limited with a retry-after header.
Errors
bad_requestA field is missing or invalid; invalid_fields names them.invalid_filterThe filter has more conditions than the live data source can apply (8 at most; a list of values counts once, except for contains_all).size_limit_exceededIt would grow past its size limit.invalid_api_keyNo key, or an unknown or revoked one.insufficient_creditsIt costs more than the credits left. Nothing is charged.paid_plan_requiredOnly available on a paid plan.insufficient_entitlementsYour plan doesn’t include it (the API itself, or this size); missing_entitlements says what.not_foundNo such id in your organisation.awaiting_mutationThe list is still busy with the last change; try again in a moment.job_not_readyThe run hasn’t succeeded yet.search_console_not_readyThe project reads no Search Console property yet, or its data is still loading.not_enough_resultsToo few keywords are left after cleaning up.rate_limitedOver the key’s rate limit; retry after the retry-after header.Endpoints
OpenAPI spec
The whole API as an OpenAPI 3.1 document, for client generators, Postman or your assistant: https://api.seospark.io/v2/openapi.json. No key needed.