@pushwoosh/rpc-v2-http-api-data 0.2.277 → 0.2.278
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/applications_configurations.d.ts +33 -1
- package/data.js +62 -1
- package/package.json +1 -1
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
import { RpcMethod } from './commonTypes';
|
|
2
2
|
export type ApplicationsConfigurationsService_Configure = RpcMethod<ConfigurationRequest, ConfigurationResponse>;
|
|
3
|
+
export type ApplicationsConfigurationsService_ListSmsProviders = RpcMethod<ListSmsProvidersRequest, ListSmsProvidersResponse>;
|
|
3
4
|
export type ApplicationsConfigurationsService_EnablePlatform = RpcMethod<EnablePlatformRequest, EnablePlatformResponse>;
|
|
4
5
|
export interface ApplicationsConfigurationsService {
|
|
5
6
|
/** 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. */
|
|
6
7
|
Configure: ApplicationsConfigurationsService_Configure;
|
|
8
|
+
/** Lists the SMS providers an application can be configured with: the built-in ones and every published provider template from the catalog. A template carries a JSON Schema of the credential form to render, so a provider added to the catalog shows up here without a release. */
|
|
9
|
+
ListSmsProviders: ApplicationsConfigurationsService_ListSmsProviders;
|
|
7
10
|
/** 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. */
|
|
8
11
|
EnablePlatform: ApplicationsConfigurationsService_EnablePlatform;
|
|
9
12
|
}
|
|
@@ -172,7 +175,11 @@ export type SmsConfiguration_provider_smsapiro = {
|
|
|
172
175
|
type: 'smsapiro';
|
|
173
176
|
data: SmsApiRoConfiguration;
|
|
174
177
|
};
|
|
175
|
-
export type
|
|
178
|
+
export type SmsConfiguration_provider_template = {
|
|
179
|
+
type: 'template';
|
|
180
|
+
data: SmsTemplateConfiguration;
|
|
181
|
+
};
|
|
182
|
+
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_provider_smsapiro | SmsConfiguration_provider_template;
|
|
176
183
|
/**
|
|
177
184
|
* SmsConfiguration carries per-application SMS provider credentials. Exactly
|
|
178
185
|
* one provider must be set; the chosen oneof field selects which gateway
|
|
@@ -183,6 +190,14 @@ export type SmsConfiguration_provider = SmsConfiguration_provider_twilio | SmsCo
|
|
|
183
190
|
export type SmsConfiguration = {
|
|
184
191
|
provider: SmsConfiguration_provider;
|
|
185
192
|
};
|
|
193
|
+
/**
|
|
194
|
+
* SmsTemplateConfiguration points an application at a published provider template and carries the
|
|
195
|
+
* values of its config_schema. A "format": "password" field left empty keeps the stored credential.
|
|
196
|
+
*/
|
|
197
|
+
export type SmsTemplateConfiguration = {
|
|
198
|
+
slug: string;
|
|
199
|
+
config: Record<string, string>;
|
|
200
|
+
};
|
|
186
201
|
export type SmsTwilioConfiguration = {
|
|
187
202
|
twilioSmsFromNumber: string;
|
|
188
203
|
twilioSid: string;
|
|
@@ -363,3 +378,20 @@ export type EnablePlatformRequest = {
|
|
|
363
378
|
enable?: boolean;
|
|
364
379
|
};
|
|
365
380
|
export type EnablePlatformResponse = {};
|
|
381
|
+
export type ListSmsProvidersRequest = {};
|
|
382
|
+
export type ListSmsProvidersResponse = {
|
|
383
|
+
providers: SmsProvider[];
|
|
384
|
+
};
|
|
385
|
+
/**
|
|
386
|
+
* SmsProvider is one entry of the provider picker. A built-in provider is identified by its value
|
|
387
|
+
* alone; a template also carries the schema of the form to render and the version in use.
|
|
388
|
+
*/
|
|
389
|
+
export type SmsProvider = {
|
|
390
|
+
value: string;
|
|
391
|
+
title: string;
|
|
392
|
+
isTemplate: boolean;
|
|
393
|
+
version: string;
|
|
394
|
+
configSchema: string;
|
|
395
|
+
icon: string;
|
|
396
|
+
description: string;
|
|
397
|
+
};
|
package/data.js
CHANGED
|
@@ -5980,6 +5980,12 @@ export const data = {
|
|
|
5980
5980
|
"method": "post",
|
|
5981
5981
|
"path": "/api/applications_configurations/{code}"
|
|
5982
5982
|
},
|
|
5983
|
+
"ListSmsProviders": {
|
|
5984
|
+
"request": "pushwoosh.rpc_v2.applications_configurations.ListSmsProvidersRequest",
|
|
5985
|
+
"response": "pushwoosh.rpc_v2.applications_configurations.ListSmsProvidersResponse",
|
|
5986
|
+
"method": "get",
|
|
5987
|
+
"path": "/api/applications_configurations:sms_providers"
|
|
5988
|
+
},
|
|
5983
5989
|
"EnablePlatform": {
|
|
5984
5990
|
"request": "pushwoosh.rpc_v2.applications_configurations.EnablePlatformRequest",
|
|
5985
5991
|
"response": "pushwoosh.rpc_v2.applications_configurations.EnablePlatformResponse",
|
|
@@ -6326,6 +6332,9 @@ export const data = {
|
|
|
6326
6332
|
},
|
|
6327
6333
|
"smsapiro": {
|
|
6328
6334
|
"type": "pushwoosh.rpc_v2.applications_configurations.SmsApiRoConfiguration"
|
|
6335
|
+
},
|
|
6336
|
+
"template": {
|
|
6337
|
+
"type": "pushwoosh.rpc_v2.applications_configurations.SmsTemplateConfiguration"
|
|
6329
6338
|
}
|
|
6330
6339
|
},
|
|
6331
6340
|
"oneofs": {
|
|
@@ -6342,11 +6351,24 @@ export const data = {
|
|
|
6342
6351
|
"textmecoil",
|
|
6343
6352
|
"ablemobile",
|
|
6344
6353
|
"mstat",
|
|
6345
|
-
"smsapiro"
|
|
6354
|
+
"smsapiro",
|
|
6355
|
+
"template"
|
|
6346
6356
|
]
|
|
6347
6357
|
}
|
|
6348
6358
|
}
|
|
6349
6359
|
},
|
|
6360
|
+
"pushwoosh.rpc_v2.applications_configurations.SmsTemplateConfiguration": {
|
|
6361
|
+
"type": "I",
|
|
6362
|
+
"fields": {
|
|
6363
|
+
"slug": {
|
|
6364
|
+
"type": "string"
|
|
6365
|
+
},
|
|
6366
|
+
"config": {
|
|
6367
|
+
"type": "string",
|
|
6368
|
+
"mapKeyType": "string"
|
|
6369
|
+
}
|
|
6370
|
+
}
|
|
6371
|
+
},
|
|
6350
6372
|
"pushwoosh.rpc_v2.applications_configurations.SmsTwilioConfiguration": {
|
|
6351
6373
|
"type": "I",
|
|
6352
6374
|
"fields": {
|
|
@@ -6652,6 +6674,45 @@ export const data = {
|
|
|
6652
6674
|
"type": "I",
|
|
6653
6675
|
"fields": {}
|
|
6654
6676
|
},
|
|
6677
|
+
"pushwoosh.rpc_v2.applications_configurations.ListSmsProvidersRequest": {
|
|
6678
|
+
"type": "I",
|
|
6679
|
+
"fields": {}
|
|
6680
|
+
},
|
|
6681
|
+
"pushwoosh.rpc_v2.applications_configurations.ListSmsProvidersResponse": {
|
|
6682
|
+
"type": "I",
|
|
6683
|
+
"fields": {
|
|
6684
|
+
"providers": {
|
|
6685
|
+
"type": "pushwoosh.rpc_v2.applications_configurations.SmsProvider",
|
|
6686
|
+
"array": true
|
|
6687
|
+
}
|
|
6688
|
+
}
|
|
6689
|
+
},
|
|
6690
|
+
"pushwoosh.rpc_v2.applications_configurations.SmsProvider": {
|
|
6691
|
+
"type": "I",
|
|
6692
|
+
"fields": {
|
|
6693
|
+
"value": {
|
|
6694
|
+
"type": "string"
|
|
6695
|
+
},
|
|
6696
|
+
"title": {
|
|
6697
|
+
"type": "string"
|
|
6698
|
+
},
|
|
6699
|
+
"isTemplate": {
|
|
6700
|
+
"type": "boolean"
|
|
6701
|
+
},
|
|
6702
|
+
"version": {
|
|
6703
|
+
"type": "string"
|
|
6704
|
+
},
|
|
6705
|
+
"configSchema": {
|
|
6706
|
+
"type": "string"
|
|
6707
|
+
},
|
|
6708
|
+
"icon": {
|
|
6709
|
+
"type": "string"
|
|
6710
|
+
},
|
|
6711
|
+
"description": {
|
|
6712
|
+
"type": "string"
|
|
6713
|
+
}
|
|
6714
|
+
}
|
|
6715
|
+
},
|
|
6655
6716
|
"pushwoosh.rpc_v2.applications_controlgroup.ApplicationsControlGroupService": {
|
|
6656
6717
|
"type": "S",
|
|
6657
6718
|
"key": "applicationsControlGroup",
|