import { RpcMethod } from './commonTypes'; export type ApplicationsConfigurationsService_Configure = RpcMethod; export type ApplicationsConfigurationsService_EnablePlatform = RpcMethod; export interface ApplicationsConfigurationsService { /** Saves the provider credentials for one delivery platform or channel of an application (code XXXXX-XXXXX) — APNs/FCM push keys, an SMS provider, email sender, Telegram/Viber token, Google Wallet, etc. — then enables that platform. Pick the matching kind in the oneof; some providers (Telegram, Huawei) also call the external provider API to register a webhook or validate the token. */ Configure: ApplicationsConfigurationsService_Configure; /** Enables or disables a single delivery platform (by numeric platform id) for an application (code XXXXX-XXXXX) without touching its stored credentials. Use to toggle a channel on or off; update_platform_configuration already enables a platform after saving its credentials. */ EnablePlatform: ApplicationsConfigurationsService_EnablePlatform; } export type AndroidConfiguration = { androidFramework: string; androidFcmServiceAccount: string; }; export type ChromeConfiguration = { chromeFcmServiceAccount: string; chromeVapidKey: string; chromeVapidPrivateKey: string; }; export type EmailConfiguration = { emailFromName: string; emailFromEmail: string; emailReplyName: string; emailReplyEmail: string; }; export type HuaweiConfiguration = { huaweiAndroidFramework: string; huaweiAndroidAppId: string; huaweiAndroidAppSecret: string; }; export type SafariConfiguration = { safariWebsiteName: string; safariWebsiteIcon: string; safariAllowedDomains: string[]; safariUrlTemplate: string; safariKeyFile: string; safariCertPassword: string; }; export type WindowsConfiguration = { wnsPsid: string; wnsSecret: string; }; export type AmazonConfiguration = { admCid: string; admSecret: string; admFramework: string; }; export type OSXConfiguration = { macosGateway: number; macosKeyFile: string; macosCertPassword: string; }; export type OSXTokenConfiguration = { macosKeyId: string; macosTeamId: string; macosBundleId: string; macosAuthKey: string; macosGateway: number; }; export type IOSConfiguration = { iosGateway: number; iosKeyFile: string; iosCertPassword: string; }; export type IOSTokenConfiguration = { iosKeyId: string; iosTeamId: string; iosBundleId: string; iosAuthKey: string; iosGateway: number; }; export type IOSVoIPConfiguration = { iosVoipGateway: number; iosVoipKeyFile: string; iosVoipCertPassword: string; }; /** * IOSPassKitConfiguration intentionally has no gateway field: PassKit * certificates have no sandbox/production variants — all push updates go * to api.push.apple.com. */ export type IOSPassKitConfiguration = { iosPasskitKeyFile: string; iosPasskitCertPassword: string; }; export type FirefoxConfiguration = { firefoxVapidKey: string; firefoxVapidPrivateKey: string; firefoxFcmServiceAccount: string; }; export type BaiduConfiguration = { baiduAndroidApiKey: string; baiduAndroidFramework: string; baiduAndroidSecretKey: string; }; export type LineConfiguration = { lineChannelId: string; lineChannelSecret: string; }; export type KakaoConfiguration = { kakaoUserCode: string; kakaoSecretKey: string; }; export type TelegramConfiguration = { telegramApiToken: string; }; export type ViberConfiguration = { viberAuthToken: string; }; export type WebConfiguration = { webVapidPublicKey: string; webVapidPrivateKey: string; autogenerate: boolean; }; /** * GoogleWalletConfiguration carries per-application Google Wallet issuer * credentials: the GCP service account key (JSON) and the issuer id from the * Google Pay & Wallet Console. Consumed by apple-passkit-service. */ export type GoogleWalletConfiguration = { googleWalletServiceAccount: string; googleWalletIssuerId: string; }; export type SmsConfiguration_provider_twilio = { type: 'twilio'; data: SmsTwilioConfiguration; }; export type SmsConfiguration_provider_amazon = { type: 'amazon'; data: SmsAmazonConfiguration; }; export type SmsConfiguration_provider_smsGlobal = { type: 'smsGlobal'; data: SmsGlobalConfiguration; }; export type SmsConfiguration_provider_smsala = { type: 'smsala'; data: SmsAlaConfiguration; }; export type SmsConfiguration_provider_capitolemobile = { type: 'capitolemobile'; data: SmsCapitoleMobileConfiguration; }; export type SmsConfiguration_provider_mobipace = { type: 'mobipace'; data: SmsMobipaceConfiguration; }; export type SmsConfiguration_provider_smscenter = { type: 'smscenter'; data: SmsCenterConfiguration; }; export type SmsConfiguration_provider_smstraffic = { type: 'smstraffic'; data: SmsTrafficConfiguration; }; export type SmsConfiguration_provider_textmecoil = { type: 'textmecoil'; data: SmsTextMeCoIlConfiguration; }; export type SmsConfiguration_provider_ablemobile = { type: 'ablemobile'; data: SmsAbleMobileConfiguration; }; export type SmsConfiguration_provider_mstat = { type: 'mstat'; data: SmsMStatConfiguration; }; export type SmsConfiguration_provider = SmsConfiguration_provider_twilio | SmsConfiguration_provider_amazon | SmsConfiguration_provider_smsGlobal | SmsConfiguration_provider_smsala | SmsConfiguration_provider_capitolemobile | SmsConfiguration_provider_mobipace | SmsConfiguration_provider_smscenter | SmsConfiguration_provider_smstraffic | SmsConfiguration_provider_textmecoil | SmsConfiguration_provider_ablemobile | SmsConfiguration_provider_mstat; /** * SmsConfiguration carries per-application SMS provider credentials. Exactly * one provider must be set; the chosen oneof field selects which gateway * channels/sender routes to (via the sms_provider application property). * Secret fields (auth tokens, passwords, API keys) are write-only: leave them * empty to keep the currently stored value unchanged. */ export type SmsConfiguration = { provider: SmsConfiguration_provider; }; export type SmsTwilioConfiguration = { twilioSmsFromNumber: string; twilioSid: string; twilioAuthToken: string; twilioSmsFromAlphanumeric: string; twilioSmsMessagingServiceSid: string; }; export type SmsAmazonConfiguration = { amazonSmsKey: string; amazonSmsSecret: string; amazonSmsRegion: string; amazonSmsSenderId: string; }; export type SmsGlobalConfiguration = { smsGlobalApiKey: string; smsGlobalSecretKey: string; smsGlobalPhoneNumber: string; }; export type SmsAlaConfiguration = { smsalaApiId: string; smsalaSenderId: string; }; export type SmsCapitoleMobileConfiguration = { capitolemobileUsername: string; capitolemobilePassword: string; capitolemobileSenderId: string; capitolemobileRoute: string; }; export type SmsMobipaceConfiguration = { mobipaceUsername: string; mobipacePassword: string; mobipaceSenderId: string; }; export type SmsCenterConfiguration = { smsCenterLogin: string; smsCenterPassword: string; smsCenterSenderId: string; }; export type SmsTrafficConfiguration = { smsSmstrafficLogin: string; smsSmstrafficPassword: string; }; export type SmsTextMeCoIlConfiguration = { textmecoilUsername: string; textmecoilPassword: string; textmecoilPhoneNumber: string; }; export type SmsAbleMobileConfiguration = { ablemobileLogin: string; ablemobilePassword: string; ablemobileSenderId: string; }; /** * SmsMStatConfiguration carries MStat (Omni Messaging) credentials. Auth is the * API token, or HTTP Basic (username + password) as a fallback; account_id is * required and sender is optional. */ export type SmsMStatConfiguration = { mstatApiToken: string; mstatUsername: string; mstatPassword: string; mstatAccountId: string; mstatSender: string; }; export type ConfigurationRequest_kind_androidConfiguration = { type: 'androidConfiguration'; data: AndroidConfiguration; }; export type ConfigurationRequest_kind_chromeConfiguration = { type: 'chromeConfiguration'; data: ChromeConfiguration; }; export type ConfigurationRequest_kind_emailConfiguration = { type: 'emailConfiguration'; data: EmailConfiguration; }; export type ConfigurationRequest_kind_huaweiConfiguration = { type: 'huaweiConfiguration'; data: HuaweiConfiguration; }; export type ConfigurationRequest_kind_safariConfiguration = { type: 'safariConfiguration'; data: SafariConfiguration; }; export type ConfigurationRequest_kind_windowsConfiguration = { type: 'windowsConfiguration'; data: WindowsConfiguration; }; export type ConfigurationRequest_kind_amazonConfiguration = { type: 'amazonConfiguration'; data: AmazonConfiguration; }; export type ConfigurationRequest_kind_osxConfiguration = { type: 'osxConfiguration'; data: OSXConfiguration; }; export type ConfigurationRequest_kind_osxTokenConfiguration = { type: 'osxTokenConfiguration'; data: OSXTokenConfiguration; }; export type ConfigurationRequest_kind_iosConfiguration = { type: 'iosConfiguration'; data: IOSConfiguration; }; export type ConfigurationRequest_kind_iosTokenConfiguration = { type: 'iosTokenConfiguration'; data: IOSTokenConfiguration; }; export type ConfigurationRequest_kind_iosVoipConfiguration = { type: 'iosVoipConfiguration'; data: IOSVoIPConfiguration; }; export type ConfigurationRequest_kind_iosPasskitConfiguration = { type: 'iosPasskitConfiguration'; data: IOSPassKitConfiguration; }; export type ConfigurationRequest_kind_firefoxConfiguration = { type: 'firefoxConfiguration'; data: FirefoxConfiguration; }; export type ConfigurationRequest_kind_baiduConfiguration = { type: 'baiduConfiguration'; data: BaiduConfiguration; }; export type ConfigurationRequest_kind_lineConfiguration = { type: 'lineConfiguration'; data: LineConfiguration; }; export type ConfigurationRequest_kind_webConfiguration = { type: 'webConfiguration'; data: WebConfiguration; }; export type ConfigurationRequest_kind_kakaoConfiguration = { type: 'kakaoConfiguration'; data: KakaoConfiguration; }; export type ConfigurationRequest_kind_telegramConfiguration = { type: 'telegramConfiguration'; data: TelegramConfiguration; }; export type ConfigurationRequest_kind_googleWalletConfiguration = { type: 'googleWalletConfiguration'; data: GoogleWalletConfiguration; }; export type ConfigurationRequest_kind_smsConfiguration = { type: 'smsConfiguration'; data: SmsConfiguration; }; export type ConfigurationRequest_kind_viberConfiguration = { type: 'viberConfiguration'; data: ViberConfiguration; }; export type ConfigurationRequest_kind = ConfigurationRequest_kind_androidConfiguration | ConfigurationRequest_kind_chromeConfiguration | ConfigurationRequest_kind_emailConfiguration | ConfigurationRequest_kind_huaweiConfiguration | ConfigurationRequest_kind_safariConfiguration | ConfigurationRequest_kind_windowsConfiguration | ConfigurationRequest_kind_amazonConfiguration | ConfigurationRequest_kind_osxConfiguration | ConfigurationRequest_kind_osxTokenConfiguration | ConfigurationRequest_kind_iosConfiguration | ConfigurationRequest_kind_iosTokenConfiguration | ConfigurationRequest_kind_iosVoipConfiguration | ConfigurationRequest_kind_iosPasskitConfiguration | ConfigurationRequest_kind_firefoxConfiguration | ConfigurationRequest_kind_baiduConfiguration | ConfigurationRequest_kind_lineConfiguration | ConfigurationRequest_kind_webConfiguration | ConfigurationRequest_kind_kakaoConfiguration | ConfigurationRequest_kind_telegramConfiguration | ConfigurationRequest_kind_googleWalletConfiguration | ConfigurationRequest_kind_smsConfiguration | ConfigurationRequest_kind_viberConfiguration; export type ConfigurationRequest = { /** Application code (format XXXXX-XXXXX) whose platform/channel to configure. */ code?: string; kind: ConfigurationRequest_kind; }; export type ConfigurationResponse = {}; export type EnablePlatformRequest = { /** Application code (format XXXXX-XXXXX) whose platform to toggle. */ code?: string; /** Numeric platform id to enable or disable (e.g. iOS, Android, Web, Email, SMS). */ platform?: number; /** true to enable the platform, false to disable it. */ enable?: boolean; }; export type EnablePlatformResponse = {};