โ† API reference

Developer ยท API reference

Visibility

How often your brand shows up in AI answers, versus competitors.

Visibility measures how often your brand appears in AI-search answers across the prompts you track. These endpoints return the scores, leaderboards and per-provider breakdowns behind the Results page.

Most take a POST body describing the company, date range and grouping (segment, offering, location, provider). The `-combined` variants return the leaderboard and the chart series in one call.

POST /analytics/visibility-metrics

Get Visibility Metrics

Get visibility metrics with flexible filtering and grouping

๐Ÿ”’ Requires Authorization: Bearer ll_โ€ฆ (or X-API-Key).

Request bodyยท VisibilityQuery

FieldTypeRequiredDescription
company_idstringYesโ€”
date_rangeany[]Yesโ€”
time_granularitystringNoโ€”
include_changebooleanNoโ€”
limitinteger | nullNoโ€”
rolling_daysinteger | nullNoโ€”
comparison_daysinteger | nullNoโ€”
entity_typestring | nullNoโ€”
entity_idstring | nullNoโ€”
filtersobjectNoโ€”
group_bystring[]Noโ€”

Example request

curl -X POST "https://api.lunalift.ai/analytics/visibility-metrics" \
  -H "Authorization: Bearer ll_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
  "company_id": "string",
  "date_range": []
}'

Response ยท 200 OK

Returns a JSON object on success.

POST /analytics/visibility-combined

Get Combined Visibility Metrics

Get combined visibility metrics: top 10 leaderboard + top 7 chart history in one query

๐Ÿ”’ Requires Authorization: Bearer ll_โ€ฆ (or X-API-Key).

Request bodyยท VisibilityQuery

FieldTypeRequiredDescription
company_idstringYesโ€”
date_rangeany[]Yesโ€”
time_granularitystringNoโ€”
include_changebooleanNoโ€”
limitinteger | nullNoโ€”
rolling_daysinteger | nullNoโ€”
comparison_daysinteger | nullNoโ€”
entity_typestring | nullNoโ€”
entity_idstring | nullNoโ€”
filtersobjectNoโ€”
group_bystring[]Noโ€”

Example request

curl -X POST "https://api.lunalift.ai/analytics/visibility-combined" \
  -H "Authorization: Bearer ll_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
  "company_id": "string",
  "date_range": []
}'

Response ยท 200 OK

FieldTypeNotes
successbooleanโ€”
messagestringโ€”
conversationIdstring | nullโ€”
dataobject | nullโ€”
POST /analytics/company-leaderboard

Get Company Leaderboard

Get company leaderboard for dashboard display

๐Ÿ”’ Requires Authorization: Bearer ll_โ€ฆ (or X-API-Key).

Request bodyยท VisibilityQuery

FieldTypeRequiredDescription
company_idstringYesโ€”
date_rangeany[]Yesโ€”
time_granularitystringNoโ€”
include_changebooleanNoโ€”
limitinteger | nullNoโ€”
rolling_daysinteger | nullNoโ€”
comparison_daysinteger | nullNoโ€”
entity_typestring | nullNoโ€”
entity_idstring | nullNoโ€”
filtersobjectNoโ€”
group_bystring[]Noโ€”

Example request

curl -X POST "https://api.lunalift.ai/analytics/company-leaderboard" \
  -H "Authorization: Bearer ll_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
  "company_id": "string",
  "date_range": []
}'

Response ยท 200 OK

Returns a JSON object on success.

POST /analytics/source-leaderboard

Get Source Leaderboard

Get source leaderboard for dashboard display

๐Ÿ”’ Requires Authorization: Bearer ll_โ€ฆ (or X-API-Key).

Request bodyยท VisibilityQuery

FieldTypeRequiredDescription
company_idstringYesโ€”
date_rangeany[]Yesโ€”
time_granularitystringNoโ€”
include_changebooleanNoโ€”
limitinteger | nullNoโ€”
rolling_daysinteger | nullNoโ€”
comparison_daysinteger | nullNoโ€”
entity_typestring | nullNoโ€”
entity_idstring | nullNoโ€”
filtersobjectNoโ€”
group_bystring[]Noโ€”

Example request

curl -X POST "https://api.lunalift.ai/analytics/source-leaderboard" \
  -H "Authorization: Bearer ll_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
  "company_id": "string",
  "date_range": []
}'

Response ยท 200 OK

Returns a JSON object on success.

POST /analytics/provider-performance

Get Provider Performance

Get AI provider performance metrics for dashboard display

๐Ÿ”’ Requires Authorization: Bearer ll_โ€ฆ (or X-API-Key).

Request bodyยท VisibilityQuery

FieldTypeRequiredDescription
company_idstringYesโ€”
date_rangeany[]Yesโ€”
time_granularitystringNoโ€”
include_changebooleanNoโ€”
limitinteger | nullNoโ€”
rolling_daysinteger | nullNoโ€”
comparison_daysinteger | nullNoโ€”
entity_typestring | nullNoโ€”
entity_idstring | nullNoโ€”
filtersobjectNoโ€”
group_bystring[]Noโ€”

Example request

curl -X POST "https://api.lunalift.ai/analytics/provider-performance" \
  -H "Authorization: Bearer ll_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
  "company_id": "string",
  "date_range": []
}'

Response ยท 200 OK

Returns a JSON object on success.

POST /analytics/competitor-domain-metrics

Get Competitor Domain Metrics

Fast per-domain visibility + sentiment for the /competitors page. Returns one row per domain (customer + competitors) straight off the daily CAGGs โ€” NOT a ranked top-N, so no domain the page renders gets squeezed out by a leaderboard `limit`. Optional filters.company_domain narrows the scan.

๐Ÿ”’ Requires Authorization: Bearer ll_โ€ฆ (or X-API-Key).

Request bodyยท VisibilityQuery

FieldTypeRequiredDescription
company_idstringYesโ€”
date_rangeany[]Yesโ€”
time_granularitystringNoโ€”
include_changebooleanNoโ€”
limitinteger | nullNoโ€”
rolling_daysinteger | nullNoโ€”
comparison_daysinteger | nullNoโ€”
entity_typestring | nullNoโ€”
entity_idstring | nullNoโ€”
filtersobjectNoโ€”
group_bystring[]Noโ€”

Example request

curl -X POST "https://api.lunalift.ai/analytics/competitor-domain-metrics" \
  -H "Authorization: Bearer ll_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
  "company_id": "string",
  "date_range": []
}'

Response ยท 200 OK

Returns a JSON object on success.