Retrieve sentiment analysis metrics for your brand mentions in AI responses.
Analyze keyword occurrences and positive sentiment indicators to understand how AI models perceive and present your brand. Track sentiment trends across topics, markets, and models.
Use cases:
curl --request POST \
--url https://api.writesonic.com/v2/geo/reports/sentiments \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"project_id": "<string>",
"dimensions": [
"topic"
],
"start_date": "2023-11-07T05:31:56Z",
"end_date": "2023-11-07T05:31:56Z",
"order_by": [
{
"field": "<string>",
"order": "asc"
}
],
"pagination": {
"limit": 10,
"offset": 0
},
"measures": [
"total_keyword_occurrences"
],
"filters": {
"topics": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"prompts": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"tags": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"markets": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"intent": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"branded": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"platform": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"has_shopping_card": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"visibility": {
"condition": "AND",
"items": [
{
"operator": "eq",
"value": "<unknown>"
}
]
},
"rank": {
"condition": "AND",
"items": [
{
"operator": "eq",
"value": "<unknown>"
}
]
},
"website_mentioned_in_answer": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"cited_page_url": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"cited_domain": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"website_mentioned_in_citation": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"status": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
}
},
"date_aggregation_interval": "day",
"website_type": "SELF"
}
'{
"info": {
"total_rows": 123,
"query": {
"metrics": [
"<string>"
],
"start_date": "2023-11-07T05:31:56Z",
"end_date": "2023-11-07T05:31:56Z",
"order_by": {},
"pagination": {},
"filters": {}
}
},
"data": [
{
"topic_id": "<string>",
"topic_name": "<string>",
"tag_id": "<string>",
"tag_name": "<string>",
"market_id": "<string>",
"market_name": "<string>",
"model_id": "<string>",
"model_name": "<string>",
"query_id": "<string>",
"query_name": "<string>",
"date": "<string>",
"website_id": "<string>",
"website_name": "<string>",
"total_keyword_occurrences": 123,
"total_positive_keyword_occurrences": 123,
"unique_positive_keywords": 123,
"total_unique_keywords": 123
}
]
}Request parameters for the Sentiment Report API.
Unique identifier of the project to query
"550e8400-e29b-41d4-a716-446655440000"
Dimensions to group sentiment data by. At least one dimension is required.
1topic, tag, market, model, query, date, website ["topic", "model"]["market", "date"]Start date for filtering data (ISO 8601 format). If not provided but the metrics are provided then defaults to latest run date else defaults to all time for non report APIs
"2026-01-01T00:00:00Z"
End date for filtering data (ISO 8601 format). If not provided but the metrics are provided then defaults to latest run date else defaults to today for non report APIs
"2024-01-31T23:59:59Z"
List of fields to sort by with their sort direction.
Show child attributes
Pagination parameters. If not provided, returns all results.
Show child attributes
Sentiment metrics to include in the response.
total_keyword_occurrences, total_positive_keyword_occurrences, unique_positive_keywords, total_unique_keywords [
"total_keyword_occurrences",
"unique_positive_keywords"
]Optional filters to narrow down sentiment analysis results.
Show child attributes
Time interval for aggregating data when using 'date' dimension.
day, week, month "week"
Filter by website type. SELF for your brand only, SELF+COMPETITORS for all.
SELF, SELF+COMPETITORS Successful Response
curl --request POST \
--url https://api.writesonic.com/v2/geo/reports/sentiments \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"project_id": "<string>",
"dimensions": [
"topic"
],
"start_date": "2023-11-07T05:31:56Z",
"end_date": "2023-11-07T05:31:56Z",
"order_by": [
{
"field": "<string>",
"order": "asc"
}
],
"pagination": {
"limit": 10,
"offset": 0
},
"measures": [
"total_keyword_occurrences"
],
"filters": {
"topics": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"prompts": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"tags": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"markets": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"intent": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"branded": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"platform": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"has_shopping_card": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"visibility": {
"condition": "AND",
"items": [
{
"operator": "eq",
"value": "<unknown>"
}
]
},
"rank": {
"condition": "AND",
"items": [
{
"operator": "eq",
"value": "<unknown>"
}
]
},
"website_mentioned_in_answer": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"cited_page_url": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"cited_domain": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"website_mentioned_in_citation": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
},
"status": {
"condition": "AND",
"items": [
{
"operator": "is",
"value": "<unknown>"
}
]
}
},
"date_aggregation_interval": "day",
"website_type": "SELF"
}
'{
"info": {
"total_rows": 123,
"query": {
"metrics": [
"<string>"
],
"start_date": "2023-11-07T05:31:56Z",
"end_date": "2023-11-07T05:31:56Z",
"order_by": {},
"pagination": {},
"filters": {}
}
},
"data": [
{
"topic_id": "<string>",
"topic_name": "<string>",
"tag_id": "<string>",
"tag_name": "<string>",
"market_id": "<string>",
"market_name": "<string>",
"model_id": "<string>",
"model_name": "<string>",
"query_id": "<string>",
"query_name": "<string>",
"date": "<string>",
"website_id": "<string>",
"website_name": "<string>",
"total_keyword_occurrences": 123,
"total_positive_keyword_occurrences": 123,
"unique_positive_keywords": 123,
"total_unique_keywords": 123
}
]
}