Skip to main content
GET
Get Facebook Page insights

Request contract

  • Method and path: GET /apis/v1/social/analytics/facebook/page-insights
  • Availability: enabled
  • Request URL template: https://api.aisa.one/apis/v1/social/analytics/facebook/page-insights
  • accountId: query; required
  • metrics: query; optional
  • fromDate: query; optional
  • toDate: query; optional
  • since: query; optional
  • until: query; optional
  • metricType: query; optional
  • Runtime facts: 99acb5bddbedc8d3352e7c4fef86c3e6d8852c14772bcd18dbcf415237a642bd
Complete OpenAPI definition Effective request and pricing declaration (including authentication and referenced schemas):

Cost and request rules

A request reference price is not currently available; use a request quote where supported. Account-specific pricing and final settlement may differ. Published reference values are not an account-specific quote or a settled charge. For endpoints supporting X-AISA-Cost-Mode: quote, obtain a free quote for your exact request before execution; reconcile the settled cost with response metadata and Usage Logs. USD amounts use 1,000,000 integer micro-USD per dollar.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

accountId
string
required

One of your social accounts (acc_...).

Pattern: ^acc_[0-9A-Za-z]{22}$
metrics
string

Comma-separated list of metrics. Defaults to "page_media_view,page_post_engagements,page_follows,followers_gained,followers_lost".

Live Meta metrics (current names, post-Nov-2025):

  • page_media_view (replaces deprecated page_impressions)
  • page_views_total
  • page_post_engagements
  • page_video_views
  • page_video_view_time
  • page_follows (replaces deprecated page_fans)

AIsa-synthesized from daily follower snapshots (filling the Nov-2025 gap left by the page_fan_adds / page_fan_removes deprecation):

  • followers_gained
  • followers_lost

Monetization (opt-in, not in the defaults):

  • content_monetization_earnings: an object per day, always with unit "micro_amount" and an ISO 4217 "currency".
  • monetization_approximate_earnings: a bare number per day; unit is always "unspecified" and "currency" always null.

Each monetization metric costs its own Graph call, so requesting both adds two calls. Values are approximate and Meta restates them later. The two are on different scales and not comparable. Both keep daily "values" on every metricType and are never rescaled by AIsa.

Earnings are Page-level daily buckets and "total" is their sum. Meta does not document whether a bucket is that day's earnings or a running total, and every Page measured so far earned exactly 0.

Reconcile "total" against the Page's Meta export before relying on it (daily "values" are always returned for this).

Per-post lifetime earnings: GET /apis/v1/social/analytics/facebook/post-earnings.

A Page not enrolled in monetization, or that earned nothing, returns normal daily buckets of 0 in "metrics" (Meta does not distinguish them), so a 0 total does NOT mean the Page is enrolled.

"unavailableMetrics" covers the narrower case where Meta returned no bucket at all ("no_data") or rejected the request; the metric is then omitted from "metrics" rather than reported as 0.

fromDate
string<date>

Start date (YYYY-MM-DD). Defaults to 30 days ago.

toDate
string<date>

End date (YYYY-MM-DD). Defaults to today.

since
string<date>

Alias of fromDate, kept for existing callers

until
string<date>

Alias of toDate, kept for existing callers

metricType
enum<string>
default:total_value

"total_value" (default) returns aggregated totals only. "time_series" returns daily values in the "values" array.

Available options:
time_series,
total_value

Response

Page insights data

Shared account-insights response envelope used by every platform-level analytics endpoint (/apis/v1/social/analytics/{facebook|instagram|youtube|linkedin|tiktok}/*). The name is historical - the shape was first shipped for Instagram and every new platform endpoint reuses it for response-shape consistency. The platform field echoes back which platform served the response.

accountId
string

One of your social accounts (acc_...).

Pattern: ^acc_[0-9A-Za-z]{22}$
breakdown
string

Breakdown dimension used (only present when breakdown was requested)

dataDelay
string
dateRange
object
metricType
enum<string>
Available options:
time_series,
total_value
metrics
object

Object keyed by metric name.

  • For time_series: each metric has "total" (number) and "values" (array of {date, value}).
  • For total_value: each metric has "total" (number) and optionally "breakdowns" (array of {dimension, value}).

Monetary metrics also carry "unit" and "currency". AIsa never rescales money: "total" and every "values[].value" are the platform's raw numbers in the stated unit.

Monetary metrics keep "values" even on metricType=total_value, because their "total" is the sum of the daily buckets the platform returned over the range. Keep the series to reconcile that sum against the platform's own reporting before invoicing on it.

A metric that could not be served is absent from this object and listed in "unavailableMetrics" instead, so an unavailable metric is never reported as a zero.

platform
enum<string>

Platform that served this response.

Available options:
facebook,
instagram,
youtube,
linkedin,
tiktok
success
boolean
unavailableMetrics
object[]

Requested metrics that could not be served. Present only when at least one metric is unavailable, absent otherwise.

Each listed metric is OMITTED from "metrics" rather than reported as 0, which is how an unavailable metric is distinguished from a genuine zero. The request itself still succeeds with HTTP 200.