Skip to content

API reference

Read published Search Console data

POST
/v1/query/search-console

The query IR of POST /v1/query, restricted to the Search Console profiles (search-console.site_daily and search-console.page_daily), answered with the same result envelope (QueryResult) plus a freshness footer. The request, its bounds (10,000 rows, 5 MB, a 4 KiB body, a window of at most 28 days, no cursors) and its error vocabulary are those of POST /v1/query; a profile of another connector is 400 invalid_query and nothing is read.

Only published, finalized days are read. A day is read only if report_heads names a published run for it, and only if that head is finalized (settled); a day Google has not finalized has no head, so a window that contains one is 409 data_incomplete (or data_not_ready when no day is published) and names the missing dates. Nothing unpublished, and nothing from a run that did not finish loading, is ever returned.

Metrics. clicks and impressions are sums. ctr is the summed clicks divided by the summed impressions, never an average of row rates, and position is weighted by impressions; each is null, never 0, when there are no impressions. A day Google reported no rows for is not a zero: an empty page is dataState: no_reported_data. page_daily rows are Google’s limited per-page detail and do not sum to the property’s totals (provider_limited_detail in provenance.flags).

Source mode. sourceMode is the identity of the data path that served the result: search_analytics_api, the Search Analytics API, one value per profile. It is not dataState and not the window’s state. It is always present on this route.

Footer. freshness.label is Finalized daily data; checked daily. freshness.lastCheckedAt is when the latest completed check of this site and profile ended, and freshness.newestDate the newest date with a published, finalized head for it, whatever the window asked for. Search Console data is not faster on a higher plan.

No data yet. The live extraction has not run on staging, so until it does a site has no published day and every window is 409 data_not_ready, or 404 connection_unavailable for a workspace with no selected property. Nothing here calls Google.

This route reads one site, because its freshness footer is one site’s: a body that names sources, or account in dimensions, is 400 invalid_query (detail invalid_sources) before a connection is looked up or anything is read. POST /v1/query reads several sites with the same profiles.

Authorization is checked before the read and again before the response is released, so a key revoked while ClickHouse is in flight yields 401 and no data. Workspace headers are ignored: the workspace is the key’s own.

object
One of:
profile
Allowed values: search-console.site_daily search-console.page_daily
dimensions
Examples

Site totals by day

{
"profile": "search-console.site_daily",
"connectionId": "your_connection",
"accounts": [
"sc-domain:example.com"
],
"metrics": [
"clicks",
"impressions",
"ctr",
"position"
],
"dimensions": [
"date"
],
"dateRange": {
"start": "2026-08-31",
"end": "2026-09-04"
}
}

Every requested day has a published, finalized snapshot, and the page is whole (page.truncated is always false). The envelope is QueryResult, and sourceMode and freshness are always present.

object
requestId
required

The gateway-generated id of this request, the same value as the X-Request-Id response header.

string
/^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/
profile
required

The profile id the request named.

string
columns
required

The columns of every row, in order, the requested dimensions then the requested metrics.

Array<object>
>= 1 items
object
id
required

The dimension or metric id; the key of each row’s value.

string
role
required
string
Allowed values: dimension metric
alias
required

The column’s name in the stored result. Not meaningful to a caller.

string
type
required
string
Allowed values: date string integer decimal
rows
required

At most 10,000 rows, in the requested order. A key is a column id. A ratio or weighted average over a zero denominator is null, never 0. A date is YYYY-MM-DD; an integer is a JSON number within the safe range. A row of a <platform>.post_snapshot profile also has windowComplete (below), which is never a column id.

Array<object>
<= 10000 items
object
windowComplete

Present on the rows of the organic-social <platform>.post_snapshot profiles only. false when a post the row covers is older than the platform’s metric window, so its counters are not whole (the view’s window_complete is 0). Such a row is returned and flagged, never dropped; provenance.flags then carries post_window_incomplete. Do not read an incomplete row’s counters as whole.

boolean
key
additional properties
string | number | null
page
required
object
limit
required
integer
>= 1 <= 10000
truncated
required

Always false in a 200. A cut page is 413 result_too_large.

boolean
provenance
required
One of:
dataState
required

zero when there are rows and every metric is 0 or empty, no_reported_data when there are no rows, observed otherwise. Never how missing data is represented (409) or a refused read (4xx, 5xx).

string
Allowed values: observed zero no_reported_data
sourceAttribution

Where the values of a YouTube result come from. Present on every 200 result of a YouTube profile (youtube.channel_daily, always one channel; YouTube is never read over several sources) and absent from every other result and from every error. Show label with the values wherever they are shown, and link a YouTube logo, if one is shown, to channelUrl or analyticsUrl. It is a statement of source only: SignalBraid is not affiliated with YouTube. Not the same field as a Klaviyo account’s attribution, which is a conversion-attribution fingerprint.

object
source
required
string
Allowed value: youtube
label
required
string
Allowed value: YouTube
notice
required
string
Allowed value: Data from YouTube. Values exactly as the YouTube Analytics API returned them.
channelId
required

The channel the values were read from (the request’s account).

string
/^UC[A-Za-z0-9_-]{22}$/
channelUrl
required

The channel’s public YouTube page.

string format: uri
/^https://www\.youtube\.com/channel/UC[A-Za-z0-9_-]{22}$/
analyticsUrl
required

The channel’s analytics page in YouTube Studio.

string format: uri
/^https://studio\.youtube\.com/channel/UC[A-Za-z0-9_-]{22}/analytics$/
sourceMode

The source mode: the identity of the data path that served the result, read from the query profile. Present only on POST /v1/query/search-console, where it is always present, and on the MCP tool query_metrics for one Search Console site; the IR route of POST /v1/query and a multi-source result never carry it.

string
Allowed values: search_analytics_api
freshness

Present only on POST /v1/query/search-console, where it is always present; the IR route of POST /v1/query never carries it. The footer for finalized daily data.

object
label
required
string
Allowed value: Finalized daily data; checked daily
lastCheckedAt
required

When the latest completed check of this site and profile ended.

string format: date-time
newestDate
required

The newest date with a published

string format: date

invalid_json — the body is absent, not valid JSON, or not valid UTF-8.

invalid_query — the body is not a supported query (unknown field, malformed date, a window outside the profile’s bounds, a metric, dimension or filter the profile does not offer, a limit outside 1–10,000, a workspaceId, a profile that is not a Search Console one), or the URL carried a query delimiter, including a bare ?.

non_additive_metric — the metric cannot be combined with the requested dimensions or window without summing what must not be summed.

window_too_large — the window needs more published snapshots than one query can pin; narrow it.

cursor_invalid — a cursor was sent. No cursor is issued yet.

A refusal the query validator raised (invalid_query, non_additive_metric, window_too_large, cursor_invalid) also carries detail: one member of a closed vocabulary that says which rule refused the request, such as unknown_metric, unknown_dimension_set, distinct_dimension_set, snapshot_over_time or mixed_attribution (a ratio or weighted average whose parts the profile attributes under different rules). A distinct_dimension_set refusal also carries suggestedDimensionSets: the dimension sets the metric is readable at, as lists of the profile’s dimension ids. Both are fixed vocabulary from the profile and never repeat the request; invalid_json and a refusal of another layer carry neither.

object
error
required
object
code
required
string
message
required
string
detail

Which rule refused the request. Closed vocabulary; one member.

string
Allowed values: body_not_object unknown_field profile_mismatch invalid_connection_id invalid_accounts invalid_sources invalid_metrics too_many_metrics unknown_metric duplicate_metric invalid_dimensions too_many_dimensions unknown_dimension duplicate_dimension unknown_dimension_set invalid_filters too_many_filters too_many_filter_values unknown_filter_dimension filter_not_allowed duplicate_filter_dimension bad_filter_op invalid_filter_value invalid_order_by unknown_order_field duplicate_order_field invalid_limit invalid_cursor as_of_not_supported unsupported_currency unsupported_timezone date_range_required invalid_date_range invalid_date window_out_of_range distinct_dimension_set snapshot_over_time mixed_attribution cross_source_non_additive identity_join_refused head_ranges_exceeded
suggestedDimensionSets

Only with detail: distinct_dimension_set: the dimension sets the refused metric is readable at, each a list of the profile’s dimension ids. Never empty.

Array<Array<string>>
>= 1 items <= 8 items unique items
error
object
code
Allowed values: invalid_json invalid_query non_additive_metric window_too_large cursor_invalid

unauthorized — missing, unknown, expired or revoked key.

object
error
required
object
code
required
string
message
required
string
error
object
code
Allowed value: unauthorized
WWW-Authenticate
required
string
Allowed value: Bearer

forbidden — the key lacks query:read. (serving_disabled, which the schema shares with POST /v1/query, is not raised on this route: Search Console has no serving switch.)

history_not_entitled — as on POST /v1/query: the window starts before the plan’s history. Nothing was read; earliestDate is the first day the plan includes.

One of:
object
error
required
object
code
required
string
message
required
string
error
object
code
Allowed values: forbidden serving_disabled

connection_unavailable — no active connection matches this workspace, connection and account, or it was disconnected mid-read.

object
error
required
object
code
required
string
message
required
string
error
object
code
Allowed value: connection_unavailable

method_not_allowed — Allow names the method this route accepts.

object
error
required
object
code
required
string
message
required
string
error
object
code
Allowed value: method_not_allowed
Allow
required
string
Allowed value: POST

data_not_ready when nothing in the window is published, data_incomplete when some days are; both name the missing dates, in ascending order, so a caller can narrow the window or wait. At most 31 dates are listed: if more are missing, the list is the earliest 31 and missingDatesTruncated is true. A list the gateway cannot vouch for is never released without its dates: the answer is a 503 with code query_unavailable instead. timezone_conflict means published dates use different property timezones: re-sync every requested date using the property’s current timezone. No analytics read occurs for that conflict, and it does not include missingDates. currency_conflict (query IR only) means a money metric spans more than one currency: group by the currency dimension. It is raised by the read itself, and carries no missingDates either. attribution_conflict (query IR only) means the published data of the window was attributed under more than one provider setting (the pinned report heads carry two attribution fingerprints), so one figure would follow two rules: narrow the window to dates published under one setting. It is raised before any analytics read, names no setting, and carries no missingDates.

One of:

The two missing-publication 409 forms; timezone_conflict, currency_conflict and attribution_conflict have no missingDates. This is a separate closed object because composing Error with allOf would reject missingDates under Error.properties.error.additionalProperties.

object
error
required
object
code
required
string
Allowed values: data_not_ready data_incomplete
message
required
string
missingDates
required

The dates with no published snapshot, in ascending order, so a truncated list is the earliest 31. Never empty: a list the gateway cannot vouch for is a 503.

Array<string>
>= 1 items <= 31 items unique items
missingDatesTruncated

Present, and true, only when more than 31 dates are missing and missingDates lists the earliest 31.

boolean
Examples
{
"error": {
"code": "data_incomplete",
"message": "Complete data is not available for every requested day.",
"missingDates": [
"2026-09-03",
"2026-09-04"
]
}
}

request_too_large — REST bodies are capped at 4 KiB.

result_too_large — the result does not fit one response: it has more than 10,000 rows, or the limit is smaller than the full result, or it is over 5 MB. The page is never cut and returned. The message says which when the service can tell (a refusal it cannot attribute gets the rows text): for rows it says “The result has more rows than the limit allows or one response can carry (at most 10,000)”, and to narrow the window or the filters or raise the limit; for size it says “The result is too large for one response (about 5 MB)”, and to narrow the window or the filters or ask for fewer metrics or dimensions. Both end by pointing to scheduled exports (today, a Google Sheets destination, with its own row limits) as the way to receive data regularly in bulk; that is not a promise to deliver the refused result. The text is fixed and never echoes the request.

One of:
object
error
required
object
code
required
string
message
required
string
error
object
code
Allowed value: request_too_large

unsupported_media_type unless the body is application/json, or unsupported_encoding for any Content-Encoding other than identity.

object
error
required
object
code
required
string
message
required
string
error
object
code
Allowed values: unsupported_media_type unsupported_encoding

rate_limited — the key’s or its workspace’s per-plan request allowance for this route’s class is used up. It is answered after authentication, on every API-key operation in this document and on MCP, and never on /health. A download link is limited the same way, after its lookup, by the key that issued it and the export’s workspace. Retry-After is the window in seconds and RateLimit-Limit is the limit of the bucket that refused. No remaining count is returned. The limits themselves are not published here.

object
error
required
object
code
required
string
message
required
string
error
object
code
Allowed value: rate_limited
Retry-After
required
string
/^[1-9][0-9]*$/
RateLimit-Limit
required
string
/^[1-9][0-9]*$/

query_unavailable — a backend is unreachable or timed out, or a stored row failed an integrity check. The boundary fails closed rather than returning a result it cannot vouch for, and never passes a database or provider message through.

auth_unavailable — the authorization store could not be reached. Pilot operations report this condition as automation_unavailable.

object
error
required
object
code
required
string
message
required
string
error
object
code
Allowed values: query_unavailable auth_unavailable