Radioplayer Developer Reference

Analytics

Technical reference for Radioplayer analytics and insights endpoints.

Version
1.3-stable
Document type
API reference
Audience
Data platform and insights API users

Link to the actual version of the API: Swagger Doc

Overview

CURRENT API VERSION: 1.3-stable

This API provides endpoints to retrieve values and analytical insights for radio stations, with the ability to specify various filters as explained below. To function, the user must be authenticated via an access_token, which can be obtained through an auth0 endpoint or by logging into the Insights platform and extracting it from sessionStorage.auth_token in the console.

The API is divided into three sections: Filters, Analytics, and Analytics Contents.

_Update from 1.1 version: you can use the equivalent version of the endpoints also with POST methods, where query params become body params of the requests._


Station Insights Endpoints

/dev/analytics/v2/aggregations/{metric_name}

GET /dev/analytics/v2/aggregations/{metric_name}

Tags : Analytics

Summary : Retrieve analytics aggregation (AQH, TTSL, Audience, Reach) over the current period specified and previous period of the same duration (e.g. 05/10 - 10/10 - previous period 01/10 - 05/10).

Parameters:

Responses:

#aggdata


/dev/analytics/v2/{metric_name}

GET /dev/analytics/v2/{metric_name}

Tags : Analytics

Summary : Retrieve analytics data with either rpuid or radio_name for different metrics. This version supports category filtering.

Parameters:

Responses:

#analyticscomplexdata


/dev/analytics/v2/date_part/{metric_name}

GET /dev/analytics/v2/date_part/{metric_name}

Tags : Analytics

Summary : Retrieve analytics data, aggregating on the datetime part of interest (DAY or HOUR), for different metrics.

Parameters:

Responses:

#analyticscomplexextractiondata


/dev/filters/v2/{table_name}/{column_name}

GET /dev/filters/v2/{table_name}/{column_name}

Tags : Filters

Summary : Retrieve distinct values for dashboards filters.

Parameters:

Responses:

#filter

GET/dev/on_demand/filters/v2/{table_name}/{column_name}


/dev/publisher_and_radio_info

GET /dev/publisher_and_radio_info

Tags : User Management

Summary : Get Publisher and RPUID Radio Information.

Responses:


Contents KPI Endpoints

/dev/analytics/programmes/{metric_name}

GET /dev/analytics/programmes/{metric_name}

Tags : Analytics Contents

Summary : Retrieve station programmes analytics.

Parameters:

Responses:

#analyticsprogrammesdata


/dev/analytics/music/{metric_name}

GET /dev/analytics/music/{metric_name}

Tags : Analytics Contents

Summary : Retrieve music analytics.

Parameters:

Responses:

#analyticsmusicdata


Migration Support Endpoints

/dev/old_insights/v2/{metric_name}

Summary : Retrieve analytics data with either rpuid or radio_name for different metrics. This version supports category filtering.

URL : /dev/old_insights/v2/{metric_name}

Method : GET

Tags : Migration

Path Parameters :

Query Parameters :

Response:

Returns analytics data based on the specified parameters, with the ability to filter by categories and metrics.

/dev/old_insights/v2/aggregations/{metric_name}

Summary : Retrieve old insights aggregation over specified periods.

URL : /dev/old_insights/v2/aggregations/{metric_name}

Method : GET

Tags : Migration

Path Parameters :

Query Parameters :

Response:

Returns aggregated insights data based on the specified parameters for the given metric over the specified period.

/dev/old_insights/v2/comparison/{metric_name}

Summary : Retrieve analytics data with either rpuid or radio_name for different metrics. This version supports category filtering. Comparison between New SourceBase and Old RP Insights Endpoint.

URL : /dev/old_insights/v2/comparison/{metric_name}

Method : GET

Tags : Migration

Path Parameters :

Query Parameters :

Response:

#migrationcomparisonmodel

On Demand Analytics Endpoints

/dev/analytics/v2/ondemand/{metric_name}

GET /dev/analytics/v2/ondemand/{metric_name}

Tags : On Demand Analytics Contents

Summary : Retrieve detailed on-demand analytics (sessions, visits, users, etc.) for podcasts or episodes with grouping, filtering and granularity support.


Parameters:Path Parameters:

Query Parameters:


Responses:

#analyticsondemanddata

Content-Type : application/json Returns an array of records with aggregated metric values, grouped by specified dimensions.

Content-Type : HTTPValidationError


/dev/analytics/v2/ondemand/aggregations/{metric_name}

GET /dev/analytics/v2/ondemand/aggregations/{metric_name}

Tags : On Demand Analytics Contents

Summary : Retrieve on-demand analytics aggregation (e.g., reach, sessions, visits, active_subscribers) for the current period and the previous equivalent period.


Parameters:Path Parameters:

Query Parameters:


Responses:

#analyticsondemanddata

Content-Type : application/json JSON object with:

{ "current_period_value": <number>, "previous_period_value": <number> }

Content-Type : HTTPValidationError

/dev/analytics/podcasts/{metric_name} (in future this will be deprecated)

GET /dev/analytics/podcasts/{metric_name}

Tags : On Demand Analytics Contents

Summary : Retrieve station podcast analytics.

Parameters:

Responses:

#analyticspodcastsdata

User Journey Endpoints

/dev/analytics/v2/user_journey/{metric_name}

GET /dev/analytics/v2/user_journey/{metric_name}

Tags : User Journey

Summary : Retrieve user journey analytics for specific metrics such as sleep_timer, share_request, and station_alarm_set. The response can be grouped by various fields.

Parameters:Path Parameters:

Query Parameters:


Responses:

#analyticsuserjourneydata

Content-Type : application/json Returns an array of records with aggregated metric values, grouped by specified dimensions.

Content-Type : HTTPValidationError

/dev/analytics/user_journey/aggregations/{metric_name}

/dev/analytics/v2/user_journey/aggregations/{metric_name}

GET /dev/analytics/v2/user_journey/aggregations/{metric_name}

Tags : User Journey

Summary : Retrieve user journey analytics aggregation for metrics like station active subscriptions, average number of favourite stations per user for both the current period and the previous period.


Parameters:Path Parameters:

Query Parameters:


Responses:

Content-Type : application/json JSON object with:

json

Copia

{ "current_period_value": <number>, "previous_period_value": <number> }

Content-Type : HTTPValidationError

Response Models

AnalyticsComplexExtractionData

AnalyticsComplexData


AnalyticsMusicData

AnalyticsProgrammesData

AnalyticsPodcastsData


AggData

Filter


OldInsightsData


OldInsightsDataHour


MigrationComparisonModel


AnalyticsOnDemandData


AnalyticsUserJourneyData