Google Search Console
Query GSC search-analytics performance and run URL inspections for a MisarSEO project.
Both endpoints operate on a project that has connected a Google Search Console property. They are workspace-scoped via SSO and accept the connected property's metrics for the calling project.
Connect first
A project must complete the GSC OAuth connect flow before these endpoints return
data. When a project is not connected (or its token expired) the endpoints return
HTTP 200 with { "ok": false, ... } and a connectUrl — not an error status —
so clients can prompt the user to reconnect.
Performance
POST https://api.misar.io/seo/gsc/performance
Request body
| Field | Type | Notes |
|---|---|---|
projectId | string (uuid) | Required. |
startDate / endDate | string | YYYY-MM-DD. Use with explicit ranges. |
dateRange | string | Preset range; alternative to start/end. |
dimensions | string[] | e.g. ["query"], ["page","query"]. Defaults to ["query"]. |
filters | object[] | { dimension, operator, expression }; operator defaults to equals. |
searchType | string | e.g. web. |
rowLimit | number | 1–1000 (default 1000). |
startRow | number | Offset for pagination. |
Response
{
"ok": true,
"siteUrl": "sc-domain:example.com",
"startDate": "2026-05-01",
"endDate": "2026-05-28",
"dimensions": ["query"],
"rowCount": 1000,
"rows": [{ "keys": ["seo tools"], "clicks": 42, "impressions": 800, "ctr": 0.0525, "position": 7.1 }],
"hasMore": true,
"nextStartRow": 1000
}When not connected:
{
"ok": false,
"reason": "Search Console is not connected for this project.",
"connectUrl": "/api/seo/gsc/connect?projectId=...",
"setupDocsUrl": "https://docs.misar.io/seo/gsc"
}URL inspection
POST https://api.misar.io/seo/gsc/inspect-urls
Request body
| Field | Type | Notes |
|---|---|---|
projectId | string (uuid) | Required. |
urls | string[] | 1–50 non-empty URLs. |
languageCode | string | Optional BCP-47 language code. |
Response
{
"ok": true,
"siteUrl": "sc-domain:example.com",
"results": [
{ "url": "https://example.com/", "result": { "indexStatusResult": { "verdict": "PASS" } } },
{ "url": "https://example.com/404", "error": "Inspection failed" }
]
}