Analytics Suite — API Reference

Analyze the behaviors of Profiles in no time.

82 endpoints across 11 tags.

Analytics: Aggregates

POST /analytics/analytics/definitions-manager/aggregates/{aggregateId}/client/{clientId}/calculate/histogram — Calculate aggregate for profile with period conditions

/api-reference/data-management#tag/Analytics:-Aggregates/operation/analytics-calculate-aggregate-for-profile-with-period-uuid

Calculate the results of an aggregate in context of a single profile. The results can be date-filtered and aggregated in time periods.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_AGGREGATE_HISTOGRAM_FOR_CLIENT_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
aggregateIdpathstringrequiredAggregate ID
clientIdpathintegerrequiredClient ID

Request body

application/json · analytics-AggregateHistogramRequest

FieldTypeRequiredDescription
variablesarray<analytics-Variable>requiredA list of variable values to use in this calculation
dateFilterrequiredDefinition of a date filter. Only data that meets the result of the filter will be included in the analysis. For no filter, leave this object empty. An absolute date filter lets you define static dates and times that always apply to the analysis. A relative date filter lets you create a date filter that goes back a certain time from the moment of calculating the analysis.
aggregateDataByobjectrequiredThe interval for grouping data

Responses

StatusDescription
200 application/jsonAggregate calculation result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/definitions-manager/aggregates/%7BaggregateId%7D/client/%7BclientId%7D/calculate/histogram \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"variables":[{"name":"string","value":"string"}],"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"aggregateDataBy":{"type":"YEARS","value":0}}'

POST /analytics/{namespace}/aggregates/preview/by/{identifierType} — Get aggregate preview

/api-reference/data-management#tag/Analytics:-Aggregates/operation/analytics2-aggregate-preview-v2

Retrieve aggregate preview value. Previews are only available for the AGGREGATE type (profile aggregate). This request doesn't save an aggregate to the database.


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_AGGREGATES_READ, ANALYTICS_BACKEND_AGGREGATE_READ

User role permission required: analytics_aggregates: read

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
identifierTypepathenum<"id", "uuid", "email", "custom_identify">requiredProfile identifier type

Request body

application/json · analytics-PreviewAggregateRequest

FieldTypeRequiredDescription
aggregaterequired
identifierValuestringrequiredValue of the selected identifier. Note that IDs must also be sent as strings.

Responses

StatusDescription
200 application/jsonAggregate preview
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/aggregates/preview/by/%7BidentifierType%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"aggregate":{"oldId":0,"aggregateType":"AGGREGATE","name":"string","description":"string","action":{"id":0,"name":"page.visit"},"attribute":{"type":"PARAM","param":"string","id":0},"type":"AVG","level":0.01,"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"size":0,"unique":false,"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]},"identifierValue":"string"}'

POST /analytics/{namespace}/aggregates/visible-for-client/by/{identifierType} — Get aggregates for profile card

/api-reference/data-management#tag/Analytics:-Aggregates/operation/analytics2-client-card-aggregates-get

Retrieve aggregates to display on a profile's card in the Profiles module ("isVisibleForClientProfile": true) in the expression config).


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_AGGREGATE_FOR_CLIENT_READ

User role permission required (at least one): analytics: read, client_analytics_preview: read

Parameters

NameInTypeRequiredDescription
identifierTypepathenum<"id", "uuid", "email", "custom_identify">requiredProfile identifier type
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · object

FieldTypeRequiredDescription
identifierValuestringrequiredValue of the selected identifier. Note that IDs must also be sent as strings.

Responses

StatusDescription
200 application/jsonList of calculated aggregates configured as visible on the profile card
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/aggregates/visible-for-client/by/%7BidentifierType%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"identifierValue":"string"}'

POST /analytics/{namespace}/aggregates/{aggregateId}/calculate/by/{identifierType} — Calculate aggregate for profile

/api-reference/data-management#tag/Analytics:-Aggregates/operation/analytics2-aggregate-calculate

Calculate the result of an existing aggregate in context of a single profile.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_AGGREGATE_FOR_CLIENT_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
aggregateIdpathstringrequiredAggregate ID
identifierTypepathenum<"id", "uuid", "email", "custom_identify">requiredProfile identifier type

Request body

application/json · object

FieldTypeRequiredDescription
identifierValuestringrequiredValue of the selected identifier. Note that IDs must also be sent as strings.

Responses

StatusDescription
200 application/jsonAggregate result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/aggregates/%7BaggregateId%7D/calculate/by/%7BidentifierType%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"identifierValue":"string"}'

GET /analytics/{namespace}/aggregates — List aggregates

/api-reference/data-management#tag/Analytics:-Aggregates/operation/analytics2-aggregates-list

Returns a paginated list of aggregates.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_AGGREGATES_LIST_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
pagequeryintegeroptionalThe number of the page to retrieve
limitqueryintegeroptionalLimit of items per page
searchquerystringoptionalA string to search for in analyses' titles
sortByqueryenum<"name:asc", "name:desc", "author:asc", "author:desc", …>optionalYou can sort the results. The sorting direction is selected by adding asc or desc, for example sortBy=name:desc.
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
directoryIdquerystringoptionalUnique ID of the directory to retrieve analyses from
idsquerystringoptionalComma-separated list of IDs (in UUID format) to filter results through
aggregateTypequeryenum<"AGGREGATE", "RUNNING_AGGREGATE">optionalFilter by aggregate type

Responses

StatusDescription
200 application/jsonList of aggregates
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url 'https://api.synerise.com/analytics/%7Bnamespace%7D/aggregates?page=SOME_INTEGER_VALUE&limit=SOME_INTEGER_VALUE&search=SOME_STRING_VALUE&sortBy=name%3Aasc&directoryId=SOME_STRING_VALUE&ids=SOME_STRING_VALUE&aggregateType=SOME_STRING_VALUE' \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/{namespace}/aggregates — Create aggregate

/api-reference/data-management#tag/Analytics:-Aggregates/operation/analytics2-aggregate-create

Create an aggregate analysis and save it to the database.


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_AGGREGATES_CREATE, ANALYTICS_BACKEND_AGGREGATE_CREATE

User role permission required: analytics_aggregates: create

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · analytics-AggregateRequest

FieldTypeRequiredDescription
analysisrequiredDefinition of the aggregate
isVisibleForClientProfilebooleanrequiredWhen set to true, information about this analysis is shown on a profile's card.
previewDefaultObjectIdnumberoptionalThe ID of the default profile for generating a preview of the results.

Responses

StatusDescription
201 application/jsonAggregate has been created
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/aggregates \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"aggregateType":"RUNNING_AGGREGATE","excludeCurrent":true,"timeWindow":{"type":"YEARS","value":0},"name":"string","description":"string","action":{"id":0,"name":"page.visit"},"attribute":{"type":"PARAM","param":"string","id":0},"type":"AVG","level":0.01,"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"size":0,"unique":false,"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]},"isVisibleForClientProfile":true,"previewDefaultObjectId":0}'

GET /analytics/{namespace}/aggregates/{aggregateId} — Get aggregate details

/api-reference/data-management#tag/Analytics:-Aggregates/operation/analytics2-aggregate-get

Retrieve all data about an aggregate definition.


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_AGGREGATES_READ, ANALYTICS_BACKEND_AGGREGATE_READ

User role permission required: analytics_aggregates: read

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
aggregateIdpathstringrequiredAggregate ID

Responses

StatusDescription
200 application/jsonDetails of the aggregate
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/aggregates/%7BaggregateId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

PUT /analytics/{namespace}/aggregates/{aggregateId} — Update aggregate

/api-reference/data-management#tag/Analytics:-Aggregates/operation/analytics2-aggregate-update

Update an aggregate.


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_AGGREGATES_UPDATE, ANALYTICS_BACKEND_AGGREGATE_UPDATE

User role permission required: analytics_aggregates: update

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
aggregateIdpathstringrequiredAggregate ID

Request body

application/json · analytics-AggregateUpdateRequest

FieldTypeRequiredDescription
analysisrequired
isVisibleForClientProfilebooleanrequiredWhen set to true, information about this analysis is shown on a profile's card.
previewDefaultObjectIdnumberoptionalThe ID of the default profile for generating a preview of the results.

Responses

StatusDescription
200Aggregate updated
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request PUT \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/aggregates/%7BaggregateId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"oldId":0,"aggregateType":"RUNNING_AGGREGATE","excludeCurrent":true,"timeWindow":{"type":"YEARS","value":0},"name":"string","description":"string","action":{"id":0,"name":"page.visit"},"attribute":{"type":"PARAM","param":"string","id":0},"type":"AVG","level":0.01,"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"size":0,"unique":false,"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]},"isVisibleForClientProfile":true,"previewDefaultObjectId":0}'

DELETE /analytics/{namespace}/aggregates/{aggregateId} — Delete aggregate

/api-reference/data-management#tag/Analytics:-Aggregates/operation/analytics2-aggregate-delete


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_AGGREGATES_DELETE, ANALYTICS_BACKEND_AGGREGATE_DELETE

User role permission required: analytics_aggregates: delete

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
aggregateIdpathstringrequiredAggregate ID

Responses

StatusDescription
204Aggregate deleted
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request DELETE \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/aggregates/%7BaggregateId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

Analytics: Expressions

POST /analytics/{namespace}/expressions/visible-for-client/by/{identifierType} — Get expressions for profile card

/api-reference/data-management#tag/Analytics:-Expressions/operation/analytics2-client-card-expressions-get

Retrieve expressions to display on a profile's card in the Profiles module ("isVisibleForClientProfile": true in the expression config).


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_EXPRESSION_FOR_CLIENT_READ

User role permission required (at least one): analytics: read, client_analytics_preview: read

Parameters

NameInTypeRequiredDescription
identifierTypepathenum<"id", "uuid", "email", "custom_identify">requiredProfile identifier type
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · object

FieldTypeRequiredDescription
identifierValuestringrequiredValue of the selected identifier. Note that IDs must also be sent as strings.

Responses

StatusDescription
200 application/jsonList of calculated expressions configured as visible on the profile card
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/expressions/visible-for-client/by/%7BidentifierType%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"identifierValue":"string"}'

POST /analytics/{namespace}/expressions/{expressionId}/calculate/by/{identifierType} — Calculate expression for profile

/api-reference/data-management#tag/Analytics:-Expressions/operation/analytics2-expression-calculate

Calculate the result of an expression in context of a single profile.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_EXPRESSION_FOR_CLIENT_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
expressionIdpathstringrequiredExpression ID
identifierTypepathenum<"id", "uuid", "email", "custom_identify">requiredProfile identifier type

Request body

application/json · object

FieldTypeRequiredDescription
identifierValuestringrequiredValue of the selected identifier. Note that IDs must also be sent as strings.

Responses

StatusDescription
200 application/jsonExpression result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/expressions/%7BexpressionId%7D/calculate/by/%7BidentifierType%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"identifierValue":"string"}'

GET /analytics/{namespace}/expressions — List expressions

/api-reference/data-management#tag/Analytics:-Expressions/operation/analytics2-expressions-list

Returns a paginated list of expressions.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_EXPRESSIONS_LIST_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
pagequeryintegeroptionalThe number of the page to retrieve
limitqueryintegeroptionalLimit of items per page
searchquerystringoptionalA string to search for in analyses' titles
sortByqueryenum<"name:asc", "name:desc", "author:asc", "author:desc", …>optionalYou can sort the results. The sorting direction is selected by adding asc or desc, for example sortBy=name:desc.
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
directoryIdquerystringoptionalUnique ID of the directory to retrieve analyses from
idsquerystringoptionalComma-separated list of IDs (in UUID format) to filter results through

Responses

StatusDescription
200 application/jsonList of expressions
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url 'https://api.synerise.com/analytics/%7Bnamespace%7D/expressions?page=SOME_INTEGER_VALUE&limit=SOME_INTEGER_VALUE&search=SOME_STRING_VALUE&sortBy=name%3Aasc&directoryId=SOME_STRING_VALUE&ids=SOME_STRING_VALUE' \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/{namespace}/expressions — Create expression

/api-reference/data-management#tag/Analytics:-Expressions/operation/analytics2-expressions-create

Create an expression that is saved in the database and can be used in other analyses.


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_EXPRESSIONS_CREATE, ANALYTICS_BACKEND_EXPRESSION_CREATE

User role permission required: analytics: create

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · analytics-expressionCreateRequestBody

FieldTypeRequiredDescription
isVisibleForClientProfilebooleanrequiredWhen set to true, information about this analysis is shown on a profile's card.
analysisrequiredDetails of an expression analysis

Responses

StatusDescription
201 application/jsonCreate expression
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/expressions \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"isVisibleForClientProfile":true,"analysis":{"type":"EVENT","action":{"id":0,"name":"page.visit"},"name":"string","description":"string","expression":{"type":"VALUE","title":"string","value":{"type":"EVENT","attribute":{"type":"PARAM","param":"string","id":0}}}}}'

GET /analytics/{namespace}/expressions/{expressionId} — Get expression details

/api-reference/data-management#tag/Analytics:-Expressions/operation/analytics2-expressions-get

Retrieve information about an expression analysis


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_EXPRESSIONS_READ, ANALYTICS_BACKEND_EXPRESSION_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
expressionIdpathstringrequiredExpression ID

Responses

StatusDescription
200 application/jsonGet expression details
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/expressions/%7BexpressionId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

PUT /analytics/{namespace}/expressions/{expressionId} — Update expression

/api-reference/data-management#tag/Analytics:-Expressions/operation/analytics2-expressions-update

Update an existing expression


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_EXPRESSIONS_UPDATE, ANALYTICS_BACKEND_EXPRESSION_UPDATE

User role permission required: analytics: update

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
expressionIdpathstringrequiredExpression ID

Request body

application/json · analytics-expressionCreateRequestBody

FieldTypeRequiredDescription
isVisibleForClientProfilebooleanrequiredWhen set to true, information about this analysis is shown on a profile's card.
analysisrequiredDetails of an expression analysis

Responses

StatusDescription
200Update expression
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request PUT \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/expressions/%7BexpressionId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"isVisibleForClientProfile":true,"analysis":{"type":"EVENT","action":{"id":0,"name":"page.visit"},"name":"string","description":"string","expression":{"type":"VALUE","title":"string","value":{"type":"EVENT","attribute":{"type":"PARAM","param":"string","id":0}}}}}'

DELETE /analytics/{namespace}/expressions/{expressionId} — Delete expression

/api-reference/data-management#tag/Analytics:-Expressions/operation/analytics2-expressions-delete


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_EXPRESSIONS_DELETE, ANALYTICS_BACKEND_EXPRESSION_DELETE

User role permission required: analytics: delete

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
expressionIdpathstringrequiredExpression ID

Responses

StatusDescription
204Delete expression
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request DELETE \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/expressions/%7BexpressionId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/{namespace}/expressions/preview/by/{identifierType} — Get expression preview

/api-reference/data-management#tag/Analytics:-Expressions/operation/analytics2-expression-preview-v2

Retrieve expression preview value. Previews are only available for CLIENT-type expressions. This request doesn't save the expression.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_EXPRESSION_FOR_CLIENT_READ

User role permission required (at least one): analytics: read, client_analytics_preview: read

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
identifierTypepathenum<"id", "uuid", "email", "custom_identify">requiredProfile identifier type

Request body

application/json · analytics-ExpressionPreviewRequestWithClient

FieldTypeRequiredDescription
identifierValuestringrequiredValue of the selected identifier. Note that IDs must also be sent as strings.
expressionobjectrequiredDetails of a profile expression. In the Synerise Portal, they are called attribute expressions.

Responses

StatusDescription
200 application/jsonExpression preview result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/expressions/preview/by/%7BidentifierType%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"identifierValue":"string","expression":{"type":"CLIENT","name":"string","description":"string","expression":{"type":"VALUE","title":"string","value":{"type":"CLIENT","attribute":{"type":"SEGMENTATION","id":"497f6eca-6276-4993-bfeb-53cbbbba6f08"}}}}}'

Analytics: Funnels

POST /analytics/analytics/v2/funnels/preview — Preview funnel calculation

/api-reference/analytics-suite#tag/Analytics:-Funnels/operation/analytics2-funnel-preview

Preview the results of a funnel. This request doesn't save the funnel.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_FUNNEL_READ

User role permission required: analytics: read

Request body (required)

application/json · analytics-FunnelRequest

FieldTypeRequiredDescription
analysisobjectoptionalDetails of the funnel

Responses

StatusDescription
200 application/jsonPreview of the results
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v2/funnels/preview \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}}}}'

POST /analytics/analytics/v2/funnels/{funnelId}/recalculate/override — Recalculate funnel with parameter override

/api-reference/analytics-suite#tag/Analytics:-Funnels/operation/analytics2-funnel-preview-override

Recalculate a funnel with new parameters and/or variable (dynamic key) values.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_FUNNEL_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
funnelIdpathstringrequiredFunnel UUID

Request body (required)

application/json · analytics-OverrideQueryRequest

FieldTypeRequiredDescription
dateFilteroptionalDefinition of a date filter. Only data that meets the result of the filter will be included in the analysis. For no filter, leave this object empty. An absolute date filter lets you define static dates and times that always apply to the analysis. A relative date filter lets you create a date filter that goes back a certain time from the moment of calculating the analysis.
aggregateDataByoptional
filterobjectoptionalThis filter lets you limit the results to profiles that match it. For no filter, leave the object empty.
variablesarray<analytics-Variable>requiredA list of variable values to use in this calculation

Responses

StatusDescription
200 application/json;charset=UTF-8Funnel results
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v2/funnels/%7BfunnelId%7D/recalculate/override \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"aggregateDataBy":{"type":"YEARS","value":0},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"variables":[{"name":"string","value":"string"}]}'

GET /analytics/{namespace}/funnels — List funnels

/api-reference/analytics-suite#tag/Analytics:-Funnels/operation/analytics2-funnels-list

Returns a paginated list of funnels.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_FUNNELS_LIST_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
pagequeryintegeroptionalThe number of the page to retrieve
limitqueryintegeroptionalLimit of items per page
searchquerystringoptionalA string to search for in analyses' titles
sortByqueryenum<"name:asc", "name:desc", "author:asc", "author:desc", …>optionalYou can sort the results. The sorting direction is selected by adding asc or desc, for example sortBy=name:desc.
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
directoryIdquerystringoptionalUnique ID of the directory to retrieve analyses from
idsquerystringoptionalComma-separated list of IDs (in UUID format) to filter results through

Responses

StatusDescription
200 application/jsonList of funnels
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url 'https://api.synerise.com/analytics/%7Bnamespace%7D/funnels?page=SOME_INTEGER_VALUE&limit=SOME_INTEGER_VALUE&search=SOME_STRING_VALUE&sortBy=name%3Aasc&directoryId=SOME_STRING_VALUE&ids=SOME_STRING_VALUE' \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/{namespace}/funnels — Create a funnel

/api-reference/analytics-suite#tag/Analytics:-Funnels/operation/analytics2-funnels-create

Create a funnel.


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_FUNNELS_CREATE, ANALYTICS_BACKEND_FUNNEL_CREATE

User role permission required: analytics: create

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · analytics-FunnelRequest

FieldTypeRequiredDescription
analysisobjectoptionalDetails of the funnel

Responses

StatusDescription
201 application/jsonFunnel created
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/funnels \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}}}}'

GET /analytics/{namespace}/funnels/{funnelId} — Get funnel details

/api-reference/analytics-suite#tag/Analytics:-Funnels/operation/analytics2-funnels-get

Retrieve the definition of a single funnel


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_FUNNELS_READ, ANALYTICS_BACKEND_FUNNEL_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
funnelIdpathstringrequiredFunnel UUID

Responses

StatusDescription
200 application/jsonDetails of the funnel
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/funnels/%7BfunnelId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

PUT /analytics/{namespace}/funnels/{funnelId} — Update funnel

/api-reference/analytics-suite#tag/Analytics:-Funnels/operation/analytics2-funnels-update

Update a funnel definition


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_FUNNELS_UPDATE, ANALYTICS_BACKEND_FUNNEL_UPDATE

User role permission required: analytics: update

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
funnelIdpathstringrequiredFunnel UUID

Request body

application/json · analytics-FunnelRequest

FieldTypeRequiredDescription
analysisobjectoptionalDetails of the funnel

Responses

StatusDescription
200Funnel updated
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request PUT \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/funnels/%7BfunnelId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}}}}'

DELETE /analytics/{namespace}/funnels/{funnelId} — Delete funnel

/api-reference/analytics-suite#tag/Analytics:-Funnels/operation/analytics2-funnels-delete

Delete a funnel.


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_FUNNELS_DELETE, ANALYTICS_BACKEND_FUNNEL_DELETE

User role permission required: analytics: delete

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
funnelIdpathstringrequiredFunnel UUID

Responses

StatusDescription
204Funnel deleted
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request DELETE \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/funnels/%7BfunnelId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

Analytics: Histograms

GET /analytics/{namespace}/histograms — List histograms

/api-reference/analytics-suite#tag/Analytics:-Histograms/operation/analytics2-histograms-list

Returns a paginated list of histograms.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_HISTOGRAMS_LIST_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
pagequeryintegeroptionalThe number of the page to retrieve
limitqueryintegeroptionalLimit of items per page
searchquerystringoptionalA string to search for in analyses' titles
sortByqueryenum<"name:asc", "name:desc", "author:asc", "author:desc", …>optionalYou can sort the results. The sorting direction is selected by adding asc or desc, for example sortBy=name:desc.
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
directoryIdquerystringoptionalUnique ID of the directory to retrieve analyses from
idsquerystringoptionalComma-separated list of IDs (in UUID format) to filter results through

Responses

StatusDescription
200 application/jsonList of histograms
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url 'https://api.synerise.com/analytics/%7Bnamespace%7D/histograms?page=SOME_INTEGER_VALUE&limit=SOME_INTEGER_VALUE&search=SOME_STRING_VALUE&sortBy=name%3Aasc&directoryId=SOME_STRING_VALUE&ids=SOME_STRING_VALUE' \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/{namespace}/histograms — Create histogram

/api-reference/analytics-suite#tag/Analytics:-Histograms/operation/analytics2-histograms-create


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_HISTOGRAMS_CREATE, ANALYTICS_BACKEND_HISTOGRAM_CREATE

User role permission required: analytics: create

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · analytics-HistogramRequest

FieldTypeRequiredDescription
analysisobjectrequiredDetails of a histogram

Responses

StatusDescription
200 application/jsonHistogram created
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/histograms \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","histogram":{"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"period":{"type":"YEARS","value":0},"eventMetrics":[{"metricId":"c2cc9ad9-a69d-40a3-8e01-a95e09e71978","chartType":"COLUMN","title":"string"}]}}}'

GET /analytics/{namespace}/histograms/{histogramId} — Get histogram details

/api-reference/analytics-suite#tag/Analytics:-Histograms/operation/analytics2-histograms-get

Retrieve the details of an existing histogram definition


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_HISTOGRAMS_READ, ANALYTICS_BACKEND_HISTOGRAM_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
histogramIdpathstringrequiredHistogram ID

Responses

StatusDescription
200 application/jsonHistogram analysis details
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/histograms/%7BhistogramId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

PUT /analytics/{namespace}/histograms/{histogramId} — Update histogram analysis

/api-reference/analytics-suite#tag/Analytics:-Histograms/operation/analytics2-histograms-update

Update an existing histogram analysis


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_HISTOGRAMS_UPDATE, ANALYTICS_BACKEND_HISTOGRAM_UPDATE

User role permission required: analytics: update

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
histogramIdpathstringrequiredHistogram ID

Request body

application/json · analytics-HistogramRequest

FieldTypeRequiredDescription
analysisobjectrequiredDetails of a histogram

Responses

StatusDescription
200Histogram updated
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request PUT \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/histograms/%7BhistogramId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","histogram":{"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"period":{"type":"YEARS","value":0},"eventMetrics":[{"metricId":"c2cc9ad9-a69d-40a3-8e01-a95e09e71978","chartType":"COLUMN","title":"string"}]}}}'

DELETE /analytics/{namespace}/histograms/{histogramId} — Delete histogram

/api-reference/analytics-suite#tag/Analytics:-Histograms/operation/analytics2-histograms-delete


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_HISTOGRAMS_DELETE, ANALYTICS_BACKEND_HISTOGRAM_DELETE

User role permission required: analytics: delete

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
histogramIdpathstringrequiredHistogram ID

Responses

StatusDescription
204Histogram deleted
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request DELETE \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/histograms/%7BhistogramId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/analytics/v2/metrics/histograms/{histogramId}/recalculate/override — Calculate histogram with parameter override

/api-reference/analytics-suite#tag/Analytics:-Histograms/operation/analytics2-calculate-histogram-with-override

Calculate a histogram with new parameters and/or variable (dynamic key) values.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_HISTOGRAM_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
histogramIdpathstringrequiredHistogram ID

Request body

application/json · analytics-OverrideQueryRequest

FieldTypeRequiredDescription
dateFilteroptionalDefinition of a date filter. Only data that meets the result of the filter will be included in the analysis. For no filter, leave this object empty. An absolute date filter lets you define static dates and times that always apply to the analysis. A relative date filter lets you create a date filter that goes back a certain time from the moment of calculating the analysis.
aggregateDataByoptional
filterobjectoptionalThis filter lets you limit the results to profiles that match it. For no filter, leave the object empty.
variablesarray<analytics-Variable>requiredA list of variable values to use in this calculation

Responses

StatusDescription
200 application/jsonHistogram override calculation result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v2/metrics/histograms/%7BhistogramId%7D/recalculate/override \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"aggregateDataBy":{"type":"YEARS","value":0},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"variables":[{"name":"string","value":"string"}]}'

POST /analytics/analytics/v2/metrics/histograms/preview — Preview histogram

/api-reference/analytics-suite#tag/Analytics:-Histograms/operation/analytics2-histogram-preview-legacy

Preview the results of a histogram. This request doesn't save the histogram.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_HISTOGRAM_READ

User role permission required: analytics: read

Request body

application/json · analytics-HistogramLegacyPreviewRequest

FieldTypeRequiredDescription
analysisobjectoptionalDetails of a histogram

Responses

StatusDescription
200 application/jsonHistogram preview calculation result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v2/metrics/histograms/preview \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","histogram":{"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"period":{"type":"YEARS","value":0},"eventMetrics":[{"metricId":"c2cc9ad9-a69d-40a3-8e01-a95e09e71978","chartType":"COLUMN","title":"string"}]}}}'

Analytics: Metrics

GET /analytics/{namespace}/metrics — List metrics

/api-reference/analytics-suite#tag/Analytics:-Metrics/operation/analytics2-metrics-list

Returns a paginated list of metrics.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_METRICS_LIST_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
pagequeryintegeroptionalThe number of the page to retrieve
limitqueryintegeroptionalLimit of items per page
searchquerystringoptionalA string to search for in analyses' titles
sortByqueryenum<"name:asc", "name:desc", "author:asc", "author:desc", …>optionalYou can sort the results. The sorting direction is selected by adding asc or desc, for example sortBy=name:desc.
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
directoryIdquerystringoptionalUnique ID of the directory to retrieve analyses from
idsquerystringoptionalComma-separated list of IDs (in UUID format) to filter results through

Responses

StatusDescription
200 application/jsonList of metrics
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url 'https://api.synerise.com/analytics/%7Bnamespace%7D/metrics?page=SOME_INTEGER_VALUE&limit=SOME_INTEGER_VALUE&search=SOME_STRING_VALUE&sortBy=name%3Aasc&directoryId=SOME_STRING_VALUE&ids=SOME_STRING_VALUE' \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/{namespace}/metrics — Create metric analysis

/api-reference/analytics-suite#tag/Analytics:-Metrics/operation/analytics2-metrics-create


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_METRICS_CREATE, ANALYTICS_BACKEND_METRIC_CREATE

User role permission required: analytics: create

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · analytics-MetricRequest

FieldTypeRequiredDescription
analysisobjectoptionalStructure of the analytical query

Responses

StatusDescription
200 application/jsonID of the created analysis
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/metrics \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","format":{"compactNumbers":false,"currency":"EUR","dataFormat":"cash","fixedLength":0,"useSeparator":false},"comparison":{"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}}},"metricType":"SIMPLE","expression":{"type":"VALUE","value":{"type":"EVENT","title":"string","occurrenceType":"FIRST","aggregation":{"type":"COUNT","level":0.01,"attribute":{"type":"PARAM","param":"string","id":0}},"action":{"id":0,"name":"page.visit"},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}},"isVisibleForClientProfile":true}}'

GET /analytics/{namespace}/metrics/{metricId} — Get metric details

/api-reference/analytics-suite#tag/Analytics:-Metrics/operation/analytics2-metrics-get

Retrieve the details of a metric definition.


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_METRICS_READ, ANALYTICS_BACKEND_METRIC_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
metricIdpathstringrequiredMetric UUID
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Responses

StatusDescription
200 application/jsonMetric details
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/metrics/%7BmetricId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

PUT /analytics/{namespace}/metrics/{metricId} — Update metric

/api-reference/analytics-suite#tag/Analytics:-Metrics/operation/analytics2-metrics-update

Update an existing metric definition.


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_METRICS_UPDATE, ANALYTICS_BACKEND_METRIC_UPDATE

User role permission required: analytics: update

Parameters

NameInTypeRequiredDescription
metricIdpathstringrequiredMetric UUID
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · analytics-MetricRequest

FieldTypeRequiredDescription
analysisobjectoptionalStructure of the analytical query

Responses

StatusDescription
200 application/jsonMetric details
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request PUT \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/metrics/%7BmetricId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","format":{"compactNumbers":false,"currency":"EUR","dataFormat":"cash","fixedLength":0,"useSeparator":false},"comparison":{"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}}},"metricType":"SIMPLE","expression":{"type":"VALUE","value":{"type":"EVENT","title":"string","occurrenceType":"FIRST","aggregation":{"type":"COUNT","level":0.01,"attribute":{"type":"PARAM","param":"string","id":0}},"action":{"id":0,"name":"page.visit"},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}},"isVisibleForClientProfile":true}}'

DELETE /analytics/{namespace}/metrics/{metricId} — Delete metric analysis

/api-reference/analytics-suite#tag/Analytics:-Metrics/operation/analytics2-metrics-delete


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_METRICS_DELETE, ANALYTICS_BACKEND_METRIC_DELETE

User role permission required: analytics: delete

Parameters

NameInTypeRequiredDescription
metricIdpathstringrequiredMetric UUID
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Responses

StatusDescription
204Metric deleted
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request DELETE \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/metrics/%7BmetricId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/analytics/v3/metrics/preview — Preview metric

/api-reference/analytics-suite#tag/Analytics:-Metrics/operation/analytics2-preview-metric-legacy

Get the results of a metric. This request doesn't save the metric to the database.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_METRIC_READ

User role permission required: analytics: read

Request body

application/json · analytics-MetricLegacyPreview

FieldTypeRequiredDescription
analysisobjectrequiredStructure of the analytical query

Responses

StatusDescription
200 application/jsonMetric preview result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v3/metrics/preview \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","format":{"compactNumbers":false,"currency":"EUR","dataFormat":"cash","fixedLength":0,"useSeparator":false},"comparison":{"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}}},"metricType":"SIMPLE","expression":{"type":"VALUE","value":{"type":"EVENT","title":"string","occurrenceType":"FIRST","aggregation":{"type":"COUNT","level":0.01,"attribute":{"type":"PARAM","param":"string","id":0}},"action":{"id":0,"name":"page.visit"},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}},"isVisibleForClientProfile":true}}'

POST /analytics/analytics/v3/metrics/{metricId}/recalculate/override — Calculate metric with parameter override

/api-reference/analytics-suite#tag/Analytics:-Metrics/operation/analytics2-calculate-metric-with-override

Recalculate a metric with new parameters and/or variable (dynamic key) values.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_METRIC_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
metricIdpathstringrequiredMetric UUID

Request body

application/json · analytics-OverrideQueryRequest

FieldTypeRequiredDescription
dateFilteroptionalDefinition of a date filter. Only data that meets the result of the filter will be included in the analysis. For no filter, leave this object empty. An absolute date filter lets you define static dates and times that always apply to the analysis. A relative date filter lets you create a date filter that goes back a certain time from the moment of calculating the analysis.
aggregateDataByoptional
filterobjectoptionalThis filter lets you limit the results to profiles that match it. For no filter, leave the object empty.
variablesarray<analytics-Variable>requiredA list of variable values to use in this calculation

Responses

StatusDescription
200 application/jsonMetric calculation result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v3/metrics/%7BmetricId%7D/recalculate/override \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"aggregateDataBy":{"type":"YEARS","value":0},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"variables":[{"name":"string","value":"string"}]}'

POST /analytics/analytics/v3/metrics/{metricId}/recalculate — Calculate metric

/api-reference/analytics-suite#tag/Analytics:-Metrics/operation/analytics2-calculate-metric

Calculate a metric that was created earlier.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_METRIC_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
metricIdpathstringrequiredMetric UUID

Responses

StatusDescription
200 application/jsonMetric calculation result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v3/metrics/%7BmetricId%7D/recalculate \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/analytics/v3/metrics/{metricId}/dynamic/value — Calculate dynamic metric

/api-reference/analytics-suite#tag/Analytics:-Metrics/operation/analytics2-calculate-metric-override-variables

Calculate a metric that includes variables (dynamic keys).


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_METRIC_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
metricIdpathstringrequiredMetric UUID

Request body

application/json · analytics-DynamicVariablesRequest

FieldTypeRequiredDescription
variablesarray<object>requiredDynamic keys used in this analysis

Responses

StatusDescription
200 application/jsonMetric calculation result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v3/metrics/%7BmetricId%7D/dynamic/value \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"variables":[{"name":"event.params.PARAMNAME","value":"string"}]}'

GET /analytics/analytics/v3/metrics/histogram-metrics — Get metrics usable in histograms

/api-reference/analytics-suite#tag/Analytics:-Metrics/operation/analytics2-get-histogram-metrics

Retrieve a list of metrics that can be used in histograms.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_METRIC_HISTOGRAM_READ

User role permission required: analytics: read

Responses

StatusDescription
200 application/json;charset=UTF-8List of metrics
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url https://api.synerise.com/analytics/analytics/v3/metrics/histogram-metrics \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

AI: Metrics

GET /metrics/v2/available — Check available metrics (recommendations)

/api-reference/analytics-suite#tag/AI:-Metrics/operation/ApiGetAvailableMetricsV2

Returns metrics available for the Workspace. The metrics can be used when defining boostMetric and sortMetric query parameters in recommendations and in metric-based recommendations.


API consumers: Workspace (Business Profile), Synerise User

API key permission required: METRICS_RECOMMENDATIONS_READ

User role permission required: campaigns_recommendations: read

Responses

StatusDescription
200 application/jsonAvailable metrics
500 application/jsonAn error occurred

Example request (cURL)

curl --request GET \
  --url https://api.synerise.com/metrics/v2/available \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

GET /metrics/v2/available-ids — Retrieve IDs of available metrics (recommendations)

/api-reference/analytics-suite#tag/AI:-Metrics/operation/ApiGetAvailableMetricsIdsV2

Returns IDs of metrics that are available for the Workspace. The metrics can be used when defining boostMetric and sortMetric query parameters in recommendations and in metric-based recommendations.


API consumers: Workspace (Business Profile), Synerise User

API key permission required: METRICS_RECOMMENDATIONS_READ

User role permission required: campaigns_recommendations: read

Responses

StatusDescription
200 application/jsonIDs of available metrics
500 application/jsonAn error occurred

Example request (cURL)

curl --request GET \
  --url https://api.synerise.com/metrics/v2/available-ids \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

Analytics: Reports

POST /analytics/analytics/v4/reports/{reportId}/recalculate/override — Calculate report with override

/api-reference/analytics-suite#tag/Analytics:-Reports/operation/analytics2-recalculate-report-override

Calculate a report with new parameters and/or variables (dynamic keys)


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_REPORT_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
reportIdpathstringrequiredReport ID

Request body

application/json · analytics-OverrideQueryRequest

FieldTypeRequiredDescription
dateFilteroptionalDefinition of a date filter. Only data that meets the result of the filter will be included in the analysis. For no filter, leave this object empty. An absolute date filter lets you define static dates and times that always apply to the analysis. A relative date filter lets you create a date filter that goes back a certain time from the moment of calculating the analysis.
aggregateDataByoptional
filterobjectoptionalThis filter lets you limit the results to profiles that match it. For no filter, leave the object empty.
variablesarray<analytics-Variable>requiredA list of variable values to use in this calculation

Responses

StatusDescription
200 application/jsonReport calculation result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v4/reports/%7BreportId%7D/recalculate/override \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"aggregateDataBy":{"type":"YEARS","value":0},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"variables":[{"name":"string","value":"string"}]}'

POST /analytics/analytics/v4/reports/{reportId}/recalculate — Recalculate report

/api-reference/analytics-suite#tag/Analytics:-Reports/operation/analytics2-recalculate-report

Retrieve the results of a previously-created report.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_REPORT_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
reportIdpathstringrequiredReport ID

Responses

StatusDescription
200 application/jsonReport calculation result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v4/reports/%7BreportId%7D/recalculate \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/analytics/v4/reports/preview — Preview report

/api-reference/analytics-suite#tag/Analytics:-Reports/operation/analytics2-preview-report

Retrieve the results of a report. This request doesn't save the report.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_REPORT_READ

User role permission required: analytics: read

Request body

application/json · analytics-ReportRequest

FieldTypeRequiredDescription
analysisobjectoptionalStructure of the report analysis
allowNullbooleanoptionalWhen true, null values can be included in the results.

Responses

StatusDescription
200 application/jsonReport calculation result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v4/reports/preview \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"reportMetrics":[{"metricId":"c2cc9ad9-a69d-40a3-8e01-a95e09e71978","dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"action":{"id":0,"name":"page.visit"},"format":{"compactNumbers":false,"currency":"EUR","dataFormat":"cash","fixedLength":0,"useSeparator":false},"columnName":"string","grouping":{"type":"TOP","top":0},"groups":[{"title":"string","format":{"compactNumbers":false,"currency":"EUR","dataFormat":"cash","fixedLength":0,"useSeparator":false},"type":"CLIENT","attribute":{"type":"SEGMENTATION","id":"497f6eca-6276-4993-bfeb-53cbbbba6f08"}}]}]},"allowNull":true}'

POST /analytics/analytics/v4/reports/preview-csv — Preview report as CSV

/api-reference/analytics-suite#tag/Analytics:-Reports/operation/analytics2-preview-csv-report

Retrieve the results of a report as CSV. This request doesn't save the report.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_REPORT_READ

User role permission required: analytics: read

Request body

application/json · analytics-ReportRequest

FieldTypeRequiredDescription
analysisobjectoptionalStructure of the report analysis
allowNullbooleanoptionalWhen true, null values can be included in the results.

Responses

StatusDescription
200 text/csvCSV data
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v4/reports/preview-csv \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"reportMetrics":[{"metricId":"c2cc9ad9-a69d-40a3-8e01-a95e09e71978","dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"action":{"id":0,"name":"page.visit"},"format":{"compactNumbers":false,"currency":"EUR","dataFormat":"cash","fixedLength":0,"useSeparator":false},"columnName":"string","grouping":{"type":"TOP","top":0},"groups":[{"title":"string","format":{"compactNumbers":false,"currency":"EUR","dataFormat":"cash","fixedLength":0,"useSeparator":false},"type":"CLIENT","attribute":{"type":"SEGMENTATION","id":"497f6eca-6276-4993-bfeb-53cbbbba6f08"}}]}]},"allowNull":true}'

GET /analytics/{namespace}/reports — List reports

/api-reference/analytics-suite#tag/Analytics:-Reports/operation/analytics2-reports-list

Returns a paginated list of reports.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_REPORTS_LIST_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
pagequeryintegeroptionalThe number of the page to retrieve
limitqueryintegeroptionalLimit of items per page
searchquerystringoptionalA string to search for in analyses' titles
sortByqueryenum<"name:asc", "name:desc", "author:asc", "author:desc", …>optionalYou can sort the results. The sorting direction is selected by adding asc or desc, for example sortBy=name:desc.
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
directoryIdquerystringoptionalUnique ID of the directory to retrieve analyses from
idsquerystringoptionalComma-separated list of IDs (in UUID format) to filter results through
isMultiMetricquerybooleanoptionalFilter reports by whether they have more than one metric.

Responses

StatusDescription
200 application/jsonList of reports
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url 'https://api.synerise.com/analytics/%7Bnamespace%7D/reports?page=SOME_INTEGER_VALUE&limit=SOME_INTEGER_VALUE&search=SOME_STRING_VALUE&sortBy=name%3Aasc&directoryId=SOME_STRING_VALUE&ids=SOME_STRING_VALUE&isMultiMetric=SOME_BOOLEAN_VALUE' \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/{namespace}/reports — Create report analysis

/api-reference/analytics-suite#tag/Analytics:-Reports/operation/analytics2-reports-create


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_REPORTS_CREATE, ANALYTICS_BACKEND_REPORT_CREATE

User role permission required: analytics: create

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · analytics-ReportRequest

FieldTypeRequiredDescription
analysisobjectoptionalStructure of the report analysis
allowNullbooleanoptionalWhen true, null values can be included in the results.

Responses

StatusDescription
200 application/jsonID of the created report
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/reports \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"reportMetrics":[{"metricId":"c2cc9ad9-a69d-40a3-8e01-a95e09e71978","dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"action":{"id":0,"name":"page.visit"},"format":{"compactNumbers":false,"currency":"EUR","dataFormat":"cash","fixedLength":0,"useSeparator":false},"columnName":"string","grouping":{"type":"TOP","top":0},"groups":[{"title":"string","format":{"compactNumbers":false,"currency":"EUR","dataFormat":"cash","fixedLength":0,"useSeparator":false},"type":"CLIENT","attribute":{"type":"SEGMENTATION","id":"497f6eca-6276-4993-bfeb-53cbbbba6f08"}}]}]},"allowNull":true}'

GET /analytics/{namespace}/reports/{reportId} — Get report analysis details

/api-reference/analytics-suite#tag/Analytics:-Reports/operation/analytics2-reports-get


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_REPORTS_READ, ANALYTICS_BACKEND_REPORT_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
reportIdpathstringrequiredReport ID
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Responses

StatusDescription
200 application/jsonGet report analysis details
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/reports/%7BreportId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

PUT /analytics/{namespace}/reports/{reportId} — Update report analysis

/api-reference/analytics-suite#tag/Analytics:-Reports/operation/analytics2-reports-update


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_REPORTS_UPDATE, ANALYTICS_BACKEND_REPORT_UPDATE

User role permission required: analytics: update

Parameters

NameInTypeRequiredDescription
reportIdpathstringrequiredReport ID
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · analytics-ReportRequest

FieldTypeRequiredDescription
analysisobjectoptionalStructure of the report analysis
allowNullbooleanoptionalWhen true, null values can be included in the results.

Responses

StatusDescription
200Report analysis updated
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request PUT \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/reports/%7BreportId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"reportMetrics":[{"metricId":"c2cc9ad9-a69d-40a3-8e01-a95e09e71978","dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"action":{"id":0,"name":"page.visit"},"format":{"compactNumbers":false,"currency":"EUR","dataFormat":"cash","fixedLength":0,"useSeparator":false},"columnName":"string","grouping":{"type":"TOP","top":0},"groups":[{"title":"string","format":{"compactNumbers":false,"currency":"EUR","dataFormat":"cash","fixedLength":0,"useSeparator":false},"type":"CLIENT","attribute":{"type":"SEGMENTATION","id":"497f6eca-6276-4993-bfeb-53cbbbba6f08"}}]}]},"allowNull":true}'

DELETE /analytics/{namespace}/reports/{reportId} — Delete report analysis

/api-reference/analytics-suite#tag/Analytics:-Reports/operation/analytics2-reports-delete


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_REPORTS_DELETE, ANALYTICS_BACKEND_REPORT_DELETE

User role permission required: analytics: delete

Parameters

NameInTypeRequiredDescription
reportIdpathstringrequiredReport ID
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Responses

StatusDescription
204Report analysis deleted
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request DELETE \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/reports/%7BreportId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

Analytics: Sankeys

POST /analytics/analytics/v2/sankeys/preview — Preview Sankey analysis

/api-reference/analytics-suite#tag/Analytics:-Sankeys/operation/analytics2-sankey-preview-override

Preview the results of a Sankey analysis. This request doesn't save the analysis.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_SANKEY_READ

User role permission required: analytics: read

Request body (required)

application/json · analytics-CreateRequestSankeyAnalysis

FieldTypeRequiredDescription
analysisobjectrequiredDetails of a Sankey analysis

Responses

StatusDescription
200 application/json;charset=UTF-8Calculation results
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v2/sankeys/preview \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","sourceEvent":{"action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]},"reverseOrder":true,"numberOfSteps":0,"numberOfPaths":0,"drillDown":[{"eventName":"page.visit","attribute":{"type":"PARAM","param":"string","id":0},"layer":0}],"drillDownCount":null,"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"eventFilters":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"excludeEvents":true,"firstOccurrenceOnly":true}}'

GET /analytics/{namespace}/sankeys — List Sankeys

/api-reference/analytics-suite#tag/Analytics:-Sankeys/operation/analytics2-sankeys-list

Returns a paginated list of Sankey analyses.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_SANKEYS_LIST_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
pagequeryintegeroptionalThe number of the page to retrieve
limitqueryintegeroptionalLimit of items per page
searchquerystringoptionalA string to search for in analyses' titles
sortByqueryenum<"name:asc", "name:desc", "author:asc", "author:desc", …>optionalYou can sort the results. The sorting direction is selected by adding asc or desc, for example sortBy=name:desc.
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
directoryIdquerystringoptionalUnique ID of the directory to retrieve analyses from
idsquerystringoptionalComma-separated list of IDs (in UUID format) to filter results through

Responses

StatusDescription
200 application/jsonList of sankeys
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url 'https://api.synerise.com/analytics/%7Bnamespace%7D/sankeys?page=SOME_INTEGER_VALUE&limit=SOME_INTEGER_VALUE&search=SOME_STRING_VALUE&sortBy=name%3Aasc&directoryId=SOME_STRING_VALUE&ids=SOME_STRING_VALUE' \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/{namespace}/sankeys — Create Sankey analysis

/api-reference/analytics-suite#tag/Analytics:-Sankeys/operation/analytics2-sankeys-create

Create sankey analysis


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_SANKEYS_CREATE, ANALYTICS_BACKEND_SANKEY_CREATE

User role permission required: analytics: create

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · analytics-SankeyRequest

FieldTypeRequiredDescription
analysisobjectrequiredDetails of a Sankey analysis

Responses

StatusDescription
200 application/jsonID of the created analysis
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/sankeys \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","sourceEvent":{"action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]},"reverseOrder":true,"numberOfSteps":0,"numberOfPaths":0,"drillDown":[{"eventName":"page.visit","attribute":{"type":"PARAM","param":"string","id":0},"layer":0}],"drillDownCount":null,"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"eventFilters":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"excludeEvents":true,"firstOccurrenceOnly":true}}'

GET /analytics/{namespace}/sankeys/{sankeyId} — Get Sankey details

/api-reference/analytics-suite#tag/Analytics:-Sankeys/operation/analytics2-sankeys-get

Retrieve the details of a Sankey analysis


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_SANKEYS_LIST_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
sankeyIdpathstringrequiredSankey UUID

Responses

StatusDescription
200 application/jsonSankey analysis details
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/sankeys/%7BsankeyId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

PUT /analytics/{namespace}/sankeys/{sankeyId} — Update Sankey

/api-reference/analytics-suite#tag/Analytics:-Sankeys/operation/analytics2-sankeys-update

Update an existing Sankey analysis


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_SANKEYS_UPDATE, ANALYTICS_BACKEND_SANKEY_UPDATE

User role permission required: analytics: update

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
sankeyIdpathstringrequiredSankey UUID

Request body

application/json · analytics-SankeyRequest

FieldTypeRequiredDescription
analysisobjectrequiredDetails of a Sankey analysis

Responses

StatusDescription
200Analysis updated
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request PUT \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/sankeys/%7BsankeyId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","sourceEvent":{"action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]},"reverseOrder":true,"numberOfSteps":0,"numberOfPaths":0,"drillDown":[{"eventName":"page.visit","attribute":{"type":"PARAM","param":"string","id":0},"layer":0}],"drillDownCount":null,"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}},"eventFilters":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"excludeEvents":true,"firstOccurrenceOnly":true}}'

DELETE /analytics/{namespace}/sankeys/{sankeyId} — Delete Sankey

/api-reference/analytics-suite#tag/Analytics:-Sankeys/operation/analytics2-sankeys-delete

Delete a Sankey analysis


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_SANKEYS_DELETE, ANALYTICS_BACKEND_SANKEY_DELETE

User role permission required: analytics: delete

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
sankeyIdpathstringrequiredSankey UUID

Responses

StatusDescription
204Deleted sankeys analysis
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request DELETE \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/sankeys/%7BsankeyId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

Analytics: Segmentations

POST /analytics/analytics/v2/segmentations/{segmentationId}/dynamic/value — Calculate dynamic segmentation

/api-reference/analytics-suite#tag/Analytics:-Segmentations/operation/analytics2-calculate-segmentations-with-variables

Calculate a segmentation that includes variables (dynamic keys).


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_SEGMENTATION_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
segmentationIdpathstringrequiredSegmentation UUID

Request body

application/json · analytics-DynamicVariablesRequest

FieldTypeRequiredDescription
variablesarray<object>requiredDynamic keys used in this analysis

Responses

StatusDescription
200 application/jsonSegmentation calculation results
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v2/segmentations/%7BsegmentationId%7D/dynamic/value \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"variables":[{"name":"event.params.PARAMNAME","value":"string"}]}'

POST /analytics/analytics/v2/segmentations/preview — Preview segmentation

/api-reference/analytics-suite#tag/Analytics:-Segmentations/operation/analytics2-segmentation-preview-legacy

Preview the results of a segmentation, with information about the results of each segment. This request does not save the analysis.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_SEGMENTATION_READ

User role permission required: analytics: read

Request body

application/json · analytics-SegmentationPreviewRequest

FieldTypeRequiredDescription
analysisobjectrequiredDefinition of the segmentation.
allowNullbooleanoptionalWhen true, null values can be included in the results.

Responses

StatusDescription
200 application/jsonCalculation result
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v2/segmentations/preview \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","segments":[{"title":"string","description":"string","filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}}}],"unique":true},"allowNull":true}'

POST /analytics/analytics/v2/segmentations/preview/clients — Preview profiles in segmentation

/api-reference/analytics-suite#tag/Analytics:-Segmentations/operation/analytics2-segmentation-preview-clients-legacy

Calculate a segmentation and get a list of profiles in each segment. This request doesn't save the segmentation in the database.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_SEGMENTATION_READ

User role permission required: analytics: read

Request body

application/json · analytics-SegmentationPreviewRequest

FieldTypeRequiredDescription
analysisobjectrequiredDefinition of the segmentation.
allowNullbooleanoptionalWhen true, null values can be included in the results.

Responses

StatusDescription
200 application/jsonArray of segments
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/v2/segmentations/preview/clients \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","segments":[{"title":"string","description":"string","filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}}}],"unique":true},"allowNull":true}'

POST /analytics/profiles/segmentations/firstMatch/by/{identifierType} — Get first matching segmentation for profile from provided list

/api-reference/analytics-suite#tag/Analytics:-Segmentations/operation/analytics2-segmentation-first-match-by

Check a number of segmentations and return the first one that matches the selected profile. Note that segmentations is a list of objects to check, and each object can also refer to multiple segmentations.


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_SEGMENTATIONS_READ, ANALYTICS_BACKEND_SEGMENTATION_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
identifierTypepathenum<"id", "uuid", "email", "custom_identify">requiredProfile identifier type

Request body (required)

application/json · analytics-AnalyticsFirstMatchRequest

FieldTypeRequiredDescription
identifierValuestringrequiredValue of the selected identifier. Note that IDs must also be sent as strings.
segmentationsarray<analytics-FirstMatchingSegmentation>requiredAn array of objects. The objects are checked in the order from the array, and when a segmentation from an object matches the profile, the value of that object's id is returned in the response. Note that each object can check multiple segmentations - in such cases, only one of those segmentation needs to match for the object to be considered a match.

Responses

StatusDescription
200 application/jsonIdentifier (id from the request body) of the matched entry
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/profiles/segmentations/firstMatch/by/%7BidentifierType%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"identifierValue":"string","segmentations":[{"id":"497f6eca-6276-4993-bfeb-53cbbbba6f08","segmentationIds":["497f6eca-6276-4993-bfeb-53cbbbba6f08"],"query":{"analysis":{"title":"string","description":"string","segments":[{"title":"string","description":"string","filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{}]}],"title":"string"}}],"expression":{}}}],"unique":true}}}]}'

GET /analytics/{namespace}/segmentations — List segmentations

/api-reference/analytics-suite#tag/Analytics:-Segmentations/operation/analytics2-segmentations-list

Returns a paginated list of segmentations.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_SEGMENTATIONS_LIST_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
pagequeryintegeroptionalThe number of the page to retrieve
limitqueryintegeroptionalLimit of items per page
searchquerystringoptionalA string to search for in analyses' titles
sortByqueryenum<"name:asc", "name:desc", "author:asc", "author:desc", …>optionalYou can sort the results. The sorting direction is selected by adding asc or desc, for example sortBy=name:desc.
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.
directoryIdquerystringoptionalUnique ID of the directory to retrieve analyses from
idsquerystringoptionalComma-separated list of IDs (in UUID format) to filter results through
shareTypequeryenum<"CROSSWORKSPACE", "INTERNAL">optionalType of sharing process

Responses

StatusDescription
200 application/jsonList of segmentations
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url 'https://api.synerise.com/analytics/%7Bnamespace%7D/segmentations?page=SOME_INTEGER_VALUE&limit=SOME_INTEGER_VALUE&search=SOME_STRING_VALUE&sortBy=name%3Aasc&directoryId=SOME_STRING_VALUE&ids=SOME_STRING_VALUE&shareType=SOME_STRING_VALUE' \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/{namespace}/segmentations — Create segmentation

/api-reference/analytics-suite#tag/Analytics:-Segmentations/operation/analytics2-segmentations-create

Create a new segmentation


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_SEGMENTATIONS_CREATE, ANALYTICS_BACKEND_SEGMENTATION_CREATE

User role permission required: analytics: create

Parameters

NameInTypeRequiredDescription
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · analytics-SegmentationRequest

FieldTypeRequiredDescription
analysisobjectrequiredDefinition of the segmentation.
isVisibleForClientProfilebooleanrequiredWhen set to true, information about this analysis is shown on a profile's card.

Responses

StatusDescription
200 application/jsonID of the created segmentation
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/segmentations \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","segments":[{"title":"string","description":"string","filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}}}],"unique":true},"isVisibleForClientProfile":true}'

GET /analytics/{namespace}/segmentations/{segmentationId} — Get segmentation details

/api-reference/analytics-suite#tag/Analytics:-Segmentations/operation/analytics2-segmentation-get

Retrieve the details of a segmentation analysis


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_SEGMENTATIONS_READ, ANALYTICS_BACKEND_SEGMENTATION_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
segmentationIdpathstringrequiredSegmentation UUID
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Responses

StatusDescription
200 application/jsonSegmentation details
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/segmentations/%7BsegmentationId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

PUT /analytics/{namespace}/segmentations/{segmentationId} — Update segmentation

/api-reference/analytics-suite#tag/Analytics:-Segmentations/operation/analytics2-segmentation-update

Update an existing segmentation analysis.


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_SEGMENTATIONS_UPDATE, ANALYTICS_BACKEND_SEGMENTATION_UPDATE

User role permission required: analytics: update

Parameters

NameInTypeRequiredDescription
segmentationIdpathstringrequiredSegmentation UUID
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · analytics-SegmentationRequest

FieldTypeRequiredDescription
analysisobjectrequiredDefinition of the segmentation.
isVisibleForClientProfilebooleanrequiredWhen set to true, information about this analysis is shown on a profile's card.

Responses

StatusDescription
200Segmentation updated
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request PUT \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/segmentations/%7BsegmentationId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"analysis":{"title":"string","description":"string","segments":[{"title":"string","description":"string","filter":{"matching":true,"expressions":[{"type":"FUNNEL","matching":true,"funnel":{"completedWithin":{"period":"YEARS","value":0},"dateFilter":{"type":"ABSOLUTE","from":"2019-08-24T14:15:22Z","to":"2019-08-24T14:15:22Z","filter":{"type":"DAILY","nestingType":"IN_PLACE","from":"string","to":"string","inverted":false}},"exact":false,"steps":[{"title":"string","action":{"id":0,"name":"page.visit"},"expressions":[{"attribute":{"type":"PARAM","param":"string","id":0},"constraint":{"type":"BOOL","logic":"IS_TRUE"}}]}],"title":"string"}}],"expression":{}}}],"unique":true},"isVisibleForClientProfile":true}'

DELETE /analytics/{namespace}/segmentations/{segmentationId} — Delete segmentation

/api-reference/analytics-suite#tag/Analytics:-Segmentations/operation/analytics2-segmentation-delete


API consumers: Synerise User, Workspace (Business Profile)

API key permissions required (at least one): ANALYTICS_BACKEND_SEGMENTATIONS_DELETE, ANALYTICS_BACKEND_SEGMENTATION_DELETE

User role permission required: analytics: delete

Parameters

NameInTypeRequiredDescription
segmentationIdpathstringrequiredSegmentation UUID
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Responses

StatusDescription
204Deleted segmentation analysis
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request DELETE \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/segmentations/%7BsegmentationId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/{namespace}/segmentations/visible-for-client/by/{identifierType} — Get segmentations for profile card

/api-reference/analytics-suite#tag/Analytics:-Segmentations/operation/analytics2-client-card-segmentations-get

Retrieve segmentations to display on a profile's card in the Profiles module ("isVisibleForClientProfile": true) in the segmentation config).


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_SEGMENTATIONS_FOR_CLIENT_READ

User role permission required (at least one): analytics: read, client_analytics_preview: read

Parameters

NameInTypeRequiredDescription
identifierTypepathenum<"id", "uuid", "email", "custom_identify">requiredProfile identifier type
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · object

FieldTypeRequiredDescription
identifierValuestringrequiredValue of the selected identifier. Note that IDs must also be sent as strings.

Responses

StatusDescription
200 application/jsonList of checked segmentations configured as visible on the profile card
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/segmentations/visible-for-client/by/%7BidentifierType%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"identifierValue":"string"}'

POST /analytics/{namespace}/segmentations/check/by/{identifierType} — Check if profile in segmentations

/api-reference/analytics-suite#tag/Analytics:-Segmentations/operation/analytics2-segmentation-check

Check if a profile is in a number of segmentations.

IMPORTANT: This endpoint is limited to:

  • 10 segmentations per request
  • 500 requests per second
  • 10 requests per second per profile

API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_BACKEND_SEGMENTATIONS_LIST_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
identifierTypepathenum<"id", "uuid", "email", "custom_identify">requiredProfile identifier type
namespacepathenum<"profiles">requiredNamespace. Currently, only profiles is available.

Request body

application/json · object

FieldTypeRequiredDescription
identifierValuestringrequiredValue of the selected identifier. Note that IDs must also be sent as strings.
segmentationIdsarray<analytics-analyticId>requiredUUIDs of the segmentations to check

Responses

StatusDescription
200 application/jsonCheck results
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/%7Bnamespace%7D/segmentations/check/by/%7BidentifierType%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"identifierValue":"string","segmentationIds":["5370bf3c-2dfa-4e89-98ff-07100cffee6c"]}'

Analytics: Management

POST /analytics/analytics/batch-delete — Delete multiple analyses

/api-reference/analytics-suite#tag/Analytics:-Management/operation/analytics2-analytics-batch-delete

Deletes many analytics in a single request


API consumer: Synerise User

User role permission required: analytics: delete

Request body (required)

application/json · analytics-AnalyticsBatchDeleteRequest

FieldTypeRequiredDescription
funnelIdsarray<string>requiredA list of funnels to delete
segmentationIdsarray<string>requiredA list of segmentations to delete
trendIdsarray<string>requiredA list of trends to delete
metricIdsarray<string>requiredA list of metrics to delete
histogramIdsarray<string>requiredA list of histograms to delete
reportIdsarray<string>requiredA list of reports to delete
aggregateIdsarray<string>requiredA list of aggregates to delete
expressionIdsarray<string>requiredA list of expressions to delete
sankeyIdsarray<string>requiredA list of sankey analyses to delete

Responses

StatusDescription
204Analytics deleted
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/analytics/batch-delete \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"funnelIds":["497f6eca-6276-4993-bfeb-53cbbbba6f08"],"segmentationIds":["497f6eca-6276-4993-bfeb-53cbbbba6f08"],"trendIds":["497f6eca-6276-4993-bfeb-53cbbbba6f08"],"metricIds":["497f6eca-6276-4993-bfeb-53cbbbba6f08"],"histogramIds":["497f6eca-6276-4993-bfeb-53cbbbba6f08"],"reportIds":["497f6eca-6276-4993-bfeb-53cbbbba6f08"],"aggregateIds":["497f6eca-6276-4993-bfeb-53cbbbba6f08"],"expressionIds":["497f6eca-6276-4993-bfeb-53cbbbba6f08"],"sankeyIds":["497f6eca-6276-4993-bfeb-53cbbbba6f08"]}'

GET /analytics/directories — List directories

/api-reference/analytics-suite#tag/Analytics:-Management/operation/analytics2-directories-list

Returns a list of directories for a given analytic type.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_DESCRIPTION_ANALYTICS_READ

User role permission required: analytics: read

Parameters

NameInTypeRequiredDescription
analyticTypequeryenum<"EXPRESSION", "AGGREGATE", "SEGMENTATION", "METRIC", …>requiredType of object

Responses

StatusDescription
200 application/jsonList of directories
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request GET \
  --url 'https://api.synerise.com/analytics/directories?analyticType=SOME_STRING_VALUE' \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

POST /analytics/directories — Create directory

/api-reference/analytics-suite#tag/Analytics:-Management/operation/analytics2-directories-create

Creates a new directory


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_DESCRIPTION_ANALYTICS_CREATE

User role permission required: analytics: create

Request body

application/json · analytics-DirectoryCreateRequest

FieldTypeRequiredDescription
namestringrequiredName of the resource
analyticTypeenum<"EXPRESSION", "AGGREGATE", "SEGMENTATION", "METRIC", …>required

Responses

StatusDescription
201 application/jsonID of the created directory
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request POST \
  --url https://api.synerise.com/analytics/directories \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"name":"string","analyticType":"EXPRESSION"}'

PATCH /analytics/directories/{directoryId} — Rename directory

/api-reference/analytics-suite#tag/Analytics:-Management/operation/analytics2-directories-rename

Renames a directory


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_DESCRIPTION_ANALYTICS_UPDATE

User role permission required: analytics: update

Parameters

NameInTypeRequiredDescription
directoryIdpathstringrequiredID of a directory

Request body

application/json · analytics-DirectoryRenameRequest

FieldTypeRequiredDescription
newNamestringrequiredNew name for the directory

Responses

StatusDescription
204Directory renamed
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request PATCH \
  --url https://api.synerise.com/analytics/directories/%7BdirectoryId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"newName":"string"}'

DELETE /analytics/directories/{directoryId} — Delete directory

/api-reference/analytics-suite#tag/Analytics:-Management/operation/analytics2-directories-delete

Deletes a directory. If the directory contains any analyses, they are moved to the default directory.


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_DESCRIPTION_ANALYTICS_DELETE

User role permission required: analytics: delete

Parameters

NameInTypeRequiredDescription
directoryIdpathstringrequiredID of a directory

Responses

StatusDescription
204Directory deleted

Example request (cURL)

curl --request DELETE \
  --url https://api.synerise.com/analytics/directories/%7BdirectoryId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

PATCH /analytics/directories/change/{analyticId} — Change Directory

/api-reference/analytics-suite#tag/Analytics:-Management/operation/analytics2-directories-change

Moves an analysis to another directory


API consumers: Synerise User, Workspace (Business Profile)

API key permission required: ANALYTICS_DESCRIPTION_ANALYTICS_UPDATE

User role permission required: analytics: update

Parameters

NameInTypeRequiredDescription
analyticIdpathstringrequiredID of the analysis

Request body

application/json · analytics-DirectoryChangeRequest

FieldTypeRequiredDescription
newDirstringrequiredID of the new directory
analyticTypeenum<"EXPRESSION", "AGGREGATE", "SEGMENTATION", "METRIC", …>required

Responses

StatusDescription
204Analysis moved
4XX application/jsonSee error message for details
5XX application/jsonSee error message for details

Example request (cURL)

curl --request PATCH \
  --url https://api.synerise.com/analytics/directories/change/%7BanalyticId%7D \
  --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{"newDir":"927cf82e-bfcc-4026-ba0d-96408cda03cb","analyticType":"EXPRESSION"}'

Back to all API categories