import { RpcMethod } from './commonTypes'; export type ApplicationsStatisticsService_GetUsersStatistics = RpcMethod; export type ApplicationsStatisticsService_GetMAUStatistics = RpcMethod; export type ApplicationsStatisticsService_GetDAUStatistics = RpcMethod; export type ApplicationsStatisticsService_GetPushApplicationStatistics = RpcMethod; export type ApplicationsStatisticsService_GetEmailApplicationStatistics = RpcMethod; export interface ApplicationsStatisticsService { /** Returns the total registered-users time series for an application (application code XXXXX-XXXXX). Use for the overall audience-size trend; use get_application_mau_statistics or get_application_dau_statistics for active-user counts. */ GetUsersStatistics: ApplicationsStatisticsService_GetUsersStatistics; /** Returns the monthly active users (MAU) time series for an application (application code XXXXX-XXXXX). Use for monthly engagement; use get_application_dau_statistics for daily active users. */ GetMAUStatistics: ApplicationsStatisticsService_GetMAUStatistics; /** Returns the daily active users (DAU) time series for an application (application code XXXXX-XXXXX). Use for daily engagement; use get_application_mau_statistics for monthly active users. */ GetDAUStatistics: ApplicationsStatisticsService_GetDAUStatistics; /** Returns per-platform push time series (total devices, sends, open rate) for an application (application code XXXXX-XXXXX). Use for the push channel dashboard; use get_application_email_statistics for the email channel. */ GetPushApplicationStatistics: ApplicationsStatisticsService_GetPushApplicationStatistics; /** Returns per-platform email time series (total devices, sends, open rate) for an application (application code XXXXX-XXXXX). Use for the email channel dashboard; use get_application_push_statistics for the push channel. */ GetEmailApplicationStatistics: ApplicationsStatisticsService_GetEmailApplicationStatistics; } export type TimeInterval = 'TIME_INTERVAL_UNSPECIFIED' | 'TIME_INTERVAL_HOUR' | 'TIME_INTERVAL_DAY' | 'TIME_INTERVAL_WEEK' | 'TIME_INTERVAL_MONTH'; export type GetUsersStatisticsRequest = { /** Application code (format XXXXX-XXXXX) to fetch statistics for. */ application?: string; }; export type GetUsersStatisticsResponse = { /** Time points for the series */ timestamps: Date[]; /** Total users for each timestamp */ usersCount: number[]; /** Time interval for grouping data */ interval: TimeInterval; }; export type GetMAUStatisticsRequest = { /** Application code (format XXXXX-XXXXX) to fetch statistics for. */ application?: string; }; export type GetMAUStatisticsResponse = { /** Time points for the series */ timestamps: Date[]; /** monthly active users for each timestamp */ usersCount: number[]; }; export type GetDAUStatisticsRequest = { /** Application code (format XXXXX-XXXXX) to fetch statistics for. */ application?: string; }; export type GetDAUStatisticsResponse = { /** Time points for the series */ timestamps: Date[]; /** daily active users for each timestamp */ usersCount: number[]; }; export type GetPushApplicationStatisticsRequest = { /** Application code (format XXXXX-XXXXX) to fetch statistics for. */ application?: string; }; export type PlatformStatistics = { /** Platform name */ platform: string; /** Values for each timestamp */ values: number[]; }; export type GetPushApplicationStatisticsResponse = { /** Time points for the series */ timestamps: Date[]; /** Total devices for each timestamp by platform */ totalDevices: PlatformStatistics[]; /** Total sends for each timestamp by platform */ sends: PlatformStatistics[]; /** Open rate for each timestamp by platform */ openRate: PlatformStatistics[]; /** Time interval for grouping data */ interval: TimeInterval; }; export type GetEmailApplicationStatisticsRequest = { /** Application code (format XXXXX-XXXXX) to fetch statistics for. */ application?: string; }; export type GetEmailApplicationStatisticsResponse = { /** Time points for the series */ timestamps: Date[]; /** Total devices for each timestamp by platform */ totalDevices: PlatformStatistics[]; /** Total sends for each timestamp by platform */ sends: PlatformStatistics[]; /** Open rate for each timestamp by platform */ openRate: PlatformStatistics[]; /** Time interval for grouping data */ interval: TimeInterval; };