Mentions
Analyze
https://api.synthesio.com/v1 /projects/{project_id}/mentions/_analyze
Run statistical analysis on mentions in the project.
See the Analytics guide for more details on how to use this endpoint.
Path parameters#
project_id
string required
ID of the project
Request body required application/json #
filters object required
Filters allow selecting documents based on various criteria. A document_kind filter is automatically added (unless it is explicitly set) to select "clipping" documents only (i.e. social posts, news, etc.) and exclude other document kinds (search data...)
See the dedicated Filtering guide for more details on how to use filters, and the Filters operator reference for a full list of available filters.
filters.{key} object
filters.{key}. values any required
The value(s) to match
filters.{key}. operator string
The role of the filter in the filter set
filters.{key}. strict boolean
If strict, the mention must match all the filter's values
dimensions array of object required
List of dimensions to group mentions by. See the Dimensions operator reference for the full list of available dimensions.
"type"dimensions[].type string required
dimensions[].name string nullable
Custom name for this dimension, replacing the value of the buckets' type in the response
dimensions[].interval string
Calendar size of each bucket
dimensions[].type string required
dimensions[].name string nullable
Custom name for this dimension, replacing the value of the buckets' type in the response
dimensions[].size integer
Maximum number of buckets to return
dimensions[].include array of string nullable
Terms to include in the dimension. No other terms will be considered. Consider setting the size accordingly to keep all the included buckets.
dimensions[].exclude array of string nullable
Terms to exclude from the dimension. All other terms will be considered.
dimensions[].min_doc_count integer
Minimum number of documents required for a bucket to be included
dimensions[].missing string nullable
Value to use for documents missing this dimension
dimensions[].type string required
dimensions[].name string nullable
Custom name for this dimension, replacing the value of the buckets' type in the response
dimensions[].size integer
Maximum number of buckets to return
dimensions[].include array of string nullable
Terms to include in the dimension. No other terms will be considered. Consider setting the size accordingly to keep all the included buckets.
dimensions[].exclude array of string nullable
Terms to exclude from the dimension. All other terms will be considered.
dimensions[].min_doc_count integer
Minimum number of documents required for a bucket to be included
dimensions[].missing string nullable
Value to use for documents missing this dimension
dimensions[].ignore_excluded_terms boolean
Automatically exclude the project's configured excluded terms
dimensions[].type string required
dimensions[].size integer
Maximum number of buckets to return
dimensions[].include array of string nullable
Terms to include in the dimension. No other terms will be considered. Consider setting the size accordingly to keep all the included buckets.
dimensions[].exclude array of string nullable
Terms to exclude from the dimension. All other terms will be considered.
metrics array of object required
List of metrics to compute for each bucket of mentions. See the Metrics operator reference for the full list of available metrics.
metrics[].type string required
Keyword dictating which metric is computed; see the reference for the full list.
metrics[].name string nullable
Custom name for this metric, replacing the key in the response's values objects.
{
"filters": {
"date": {
"values": {
"gte": "2025-01-01T00:00:00Z"
}
},
"language": {
"values": [
"eng",
"fra"
]
},
"sentiment": {
"operator": "must_not",
"values": [
"negative"
]
},
"synql": {
"values": "\"ice cream\" OR gelato"
}
},
"dimensions": [
{
"type": "sentiment"
}
],
"metrics": [
{
"type": "volume"
}
]
}Responses#
Successful Response
result object
Result of the analytics request
result.values object
Metric values for the whole set of mentions matching the filters
result.values. {key} number
result.buckets array of object
Buckets for the first dimension
result.buckets[]. id string
Key value of the bucket
result.buckets[]. type string
Type (or custom name) of the dimension
result.buckets[]. values object
Metric values for this bucket
result.buckets[].values. {key} number
result.buckets[]. buckets array of object
Sub-buckets for the next dimension level
result.buckets[].buckets[]. id string
Key value of the bucket
result.buckets[].buckets[]. type string
Type (or custom name) of the dimension
result.buckets[].buckets[]. values object
Metric values for this bucket
result.buckets[].buckets[].values. {key} number
result.buckets[].buckets[]. buckets array of object
Sub-buckets for the next dimension level
result.buckets[].buckets[].buckets[]. id string
Key value of the bucket
result.buckets[].buckets[].buckets[]. type string
Type (or custom name) of the dimension
result.buckets[].buckets[].buckets[]. values object
Metric values for this bucket
result.buckets[].buckets[].buckets[].values. {key} number
result.buckets[].buckets[].buckets[]. buckets array of object
Sub-buckets for the next dimension level
result.buckets[].buckets[].buckets[].buckets[]. id string
Key value of the bucket
result.buckets[].buckets[].buckets[].buckets[]. type string
Type (or custom name) of the dimension
result.buckets[].buckets[].buckets[].buckets[]. values object
Metric values for this bucket
result.buckets[].buckets[].buckets[].buckets[].values. {key} number
result.buckets[].buckets[].buckets[].buckets[]. buckets array of object recursive
Sub-buckets for the next dimension level
{
"result": {
"values": {
"volume": 123
},
"buckets": [
{
"id": "positive",
"type": "sentiment",
"values": {
"volume": 100
},
"buckets": []
},
{
"id": "neutral",
"type": "sentiment",
"values": {
"volume": 23
},
"buckets": []
}
]
}
}Bad request
errors array of object
Error that caused the request to fail; even though this is a list, it usually contains a single error
errors[].code string
Error code identifying the type of error
errors[].detail string
Message describing the problem
errors[].request_id string
Unique identifier for the request
errors[].meta object nullable
Additional metadata about the error
{
"errors": [
{
"code": "string",
"detail": "string",
"request_id": "string",
"meta": {}
}
]
}Unauthorized
errors array of object
Error that caused the request to fail; even though this is a list, it usually contains a single error
errors[].code string
Error code identifying the type of error
errors[].detail string
Message describing the problem
errors[].request_id string
Unique identifier for the request
errors[].meta object nullable
Additional metadata about the error
{
"errors": [
{
"code": "string",
"detail": "string",
"request_id": "string",
"meta": {}
}
]
}Forbidden
errors array of object
Error that caused the request to fail; even though this is a list, it usually contains a single error
errors[].code string
Error code identifying the type of error
errors[].detail string
Message describing the problem
errors[].request_id string
Unique identifier for the request
errors[].meta object nullable
Additional metadata about the error
{
"errors": [
{
"code": "string",
"detail": "string",
"request_id": "string",
"meta": {}
}
]
}Not found
errors array of object
Error that caused the request to fail; even though this is a list, it usually contains a single error
errors[].code string
Error code identifying the type of error
errors[].detail string
Message describing the problem
errors[].request_id string
Unique identifier for the request
errors[].meta object nullable
Additional metadata about the error
{
"errors": [
{
"code": "string",
"detail": "string",
"request_id": "string",
"meta": {}
}
]
}Method not allowed
errors array of object
Error that caused the request to fail; even though this is a list, it usually contains a single error
errors[].code string
Error code identifying the type of error
errors[].detail string
Message describing the problem
errors[].request_id string
Unique identifier for the request
errors[].meta object nullable
Additional metadata about the error
{
"errors": [
{
"code": "string",
"detail": "string",
"request_id": "string",
"meta": {}
}
]
}Internal server error
errors array of object
Error that caused the request to fail; even though this is a list, it usually contains a single error
errors[].code string
Error code identifying the type of error
errors[].detail string
Message describing the problem
errors[].request_id string
Unique identifier for the request
errors[].meta object nullable
Additional metadata about the error
{
"errors": [
{
"code": "string",
"detail": "string",
"request_id": "string",
"meta": {}
}
]
}