Skip to main content
POST
/
api
/
analytics
/
sentiment
/
overview
Get overall sentiment for project brand
curl --request POST \
  --url https://api.mentionlab.io/api/analytics/sentiment/overview \
  --header 'Content-Type: application/json' \
  --header 'x-project-id: <x-project-id>' \
  --data '
{
  "startDate": "2025-01-01",
  "endDate": "2025-02-01",
  "country": "<string>",
  "language": "<string>",
  "models": [
    "<string>"
  ],
  "hasSources": true,
  "hasShopping": true,
  "queryTagIds": [
    "<string>"
  ],
  "execTagIds": [
    "<string>"
  ],
  "queryTagMode": "or",
  "execTagMode": "or",
  "entityIds": [
    "<string>"
  ]
}
'
{
  "sentimentScore": 72.3,
  "sentimentLabel": "positive",
  "mentionCount": 245,
  "positive": 165,
  "neutral": 52,
  "negative": 28
}

Headers

x-project-id
string
required

Project ID to specify the project context

Body

application/json
startDate
string

Start date (inclusive)

Example:

"2025-01-01"

endDate
string

End date (exclusive)

Example:

"2025-02-01"

country
string

Filter by country code

language
string

Filter by language code

models
string[]

Filter by AI models

hasSources
boolean

Filter by responses that have sources

hasShopping
boolean

Filter by responses that have shopping products

queryTagIds
string[]

Filter by query tag IDs

execTagIds
string[]

Filter by execution tag IDs

queryTagMode
enum<string>
default:or

Query tag matching mode: "or" matches ANY tag (default), "and" matches ALL tags.

Available options:
and,
or
execTagMode
enum<string>
default:or

Execution tag matching mode: "or" matches ANY tag (default), "and" matches ALL tags.

Available options:
and,
or
entityIds
string[]

Entity IDs to compute sentiment for. Defaults to project brand (primary non-blacklisted).

Response

200 - application/json
sentimentScore
number
required

Average sentiment score (0–100). 0 = most negative, 100 = most positive.

Example:

72.3

sentimentLabel
string
required

Derived sentiment label based on score: positive (>= 60), neutral (40–59), negative (< 40).

Example:

"positive"

mentionCount
number
required

Total mention count included in the aggregation.

Example:

245

positive
number
required

Count of mentions with positive sentiment.

Example:

165

neutral
number
required

Count of mentions with neutral sentiment.

Example:

52

negative
number
required

Count of mentions with negative sentiment.

Example:

28