@fonoster/sdk 0.6.0 → 0.6.1

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.
Files changed (111) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +358 -2
  3. package/dist/node/Applications.d.ts +206 -0
  4. package/dist/node/Applications.js +267 -0
  5. package/dist/node/client/AbstractClient.d.ts +22 -0
  6. package/dist/node/client/AbstractClient.js +86 -0
  7. package/dist/node/client/Client.d.ts +15 -0
  8. package/dist/node/client/Client.js +61 -0
  9. package/dist/node/client/TokenRefresherNode.d.ts +8 -0
  10. package/dist/node/client/TokenRefresherNode.js +43 -0
  11. package/dist/node/client/TokenRefresherWeb.d.ts +13 -0
  12. package/dist/node/client/TokenRefresherWeb.js +44 -0
  13. package/dist/node/client/isJwtExpired.d.ts +2 -0
  14. package/dist/node/client/isJwtExpired.js +37 -0
  15. package/dist/node/client/jsonToObject.d.ts +8 -0
  16. package/dist/node/client/jsonToObject.js +31 -0
  17. package/dist/node/client/makeRpcRequest.d.ts +11 -0
  18. package/dist/node/client/makeRpcRequest.js +44 -0
  19. package/dist/node/client/objectToJson.d.ts +3 -0
  20. package/dist/node/client/objectToJson.js +32 -0
  21. package/dist/node/client/types.d.ts +26 -0
  22. package/dist/node/client/types.js +2 -0
  23. package/dist/node/client/utils.d.ts +5 -0
  24. package/dist/node/client/utils.js +17 -0
  25. package/dist/node/generated/node/acls.ts +1054 -0
  26. package/dist/node/generated/node/acls_grpc_pb.js +200 -0
  27. package/dist/node/generated/node/acls_pb.js +2063 -0
  28. package/dist/node/generated/node/agents.ts +1388 -0
  29. package/dist/node/generated/node/agents_grpc_pb.js +202 -0
  30. package/dist/node/generated/node/agents_pb.js +2403 -0
  31. package/dist/node/generated/node/applications.ts +1411 -0
  32. package/dist/node/generated/node/applications_grpc_pb.js +201 -0
  33. package/dist/node/generated/node/applications_pb.js +2651 -0
  34. package/dist/node/generated/node/calls.ts +1123 -0
  35. package/dist/node/generated/node/calls_grpc_pb.js +169 -0
  36. package/dist/node/generated/node/calls_pb.js +1916 -0
  37. package/dist/node/generated/node/credentials.ts +1054 -0
  38. package/dist/node/generated/node/credentials_grpc_pb.js +200 -0
  39. package/dist/node/generated/node/credentials_pb.js +1928 -0
  40. package/dist/node/generated/node/domains.ts +1144 -0
  41. package/dist/node/generated/node/domains_grpc_pb.js +200 -0
  42. package/dist/node/generated/node/domains_pb.js +2170 -0
  43. package/dist/node/generated/node/google/protobuf/empty.ts +48 -0
  44. package/dist/node/generated/node/google/protobuf/struct.ts +408 -0
  45. package/dist/node/generated/node/identity.ts +4267 -0
  46. package/dist/node/generated/node/identity_grpc_pb.js +761 -0
  47. package/dist/node/generated/node/identity_pb.js +8058 -0
  48. package/dist/node/generated/node/numbers.ts +1371 -0
  49. package/dist/node/generated/node/numbers_grpc_pb.js +201 -0
  50. package/dist/node/generated/node/numbers_pb.js +2470 -0
  51. package/dist/node/generated/node/secrets.ts +985 -0
  52. package/dist/node/generated/node/secrets_grpc_pb.js +200 -0
  53. package/dist/node/generated/node/secrets_pb.js +1838 -0
  54. package/dist/node/generated/node/trunks.ts +1546 -0
  55. package/dist/node/generated/node/trunks_grpc_pb.js +202 -0
  56. package/dist/node/generated/node/trunks_pb.js +2777 -0
  57. package/dist/node/generated/web/AclsServiceClientPb.ts +258 -0
  58. package/dist/node/generated/web/AgentsServiceClientPb.ts +258 -0
  59. package/dist/node/generated/web/ApplicationsServiceClientPb.ts +258 -0
  60. package/dist/node/generated/web/CallsServiceClientPb.ts +194 -0
  61. package/dist/node/generated/web/CredentialsServiceClientPb.ts +258 -0
  62. package/dist/node/generated/web/DomainsServiceClientPb.ts +258 -0
  63. package/dist/node/generated/web/IdentityServiceClientPb.ts +990 -0
  64. package/dist/node/generated/web/NumbersServiceClientPb.ts +258 -0
  65. package/dist/node/generated/web/SecretsServiceClientPb.ts +258 -0
  66. package/dist/node/generated/web/TrunksServiceClientPb.ts +258 -0
  67. package/dist/node/generated/web/acls.ts +1054 -0
  68. package/dist/node/generated/web/acls_pb.d.ts +246 -0
  69. package/dist/node/generated/web/acls_pb.js +2063 -0
  70. package/dist/node/generated/web/agents.ts +1388 -0
  71. package/dist/node/generated/web/agents_pb.d.ts +300 -0
  72. package/dist/node/generated/web/agents_pb.js +2403 -0
  73. package/dist/node/generated/web/applications.ts +1411 -0
  74. package/dist/node/generated/web/applications_pb.d.ts +322 -0
  75. package/dist/node/generated/web/applications_pb.js +2651 -0
  76. package/dist/node/generated/web/calls.ts +1123 -0
  77. package/dist/node/generated/web/calls_pb.d.ts +262 -0
  78. package/dist/node/generated/web/calls_pb.js +1916 -0
  79. package/dist/node/generated/web/credentials.ts +1054 -0
  80. package/dist/node/generated/web/credentials_pb.d.ts +234 -0
  81. package/dist/node/generated/web/credentials_pb.js +1928 -0
  82. package/dist/node/generated/web/domains.ts +1144 -0
  83. package/dist/node/generated/web/domains_pb.d.ts +260 -0
  84. package/dist/node/generated/web/domains_pb.js +2170 -0
  85. package/dist/node/generated/web/google/protobuf/empty.ts +48 -0
  86. package/dist/node/generated/web/google/protobuf/struct.ts +408 -0
  87. package/dist/node/generated/web/identity.ts +4267 -0
  88. package/dist/node/generated/web/identity_pb.d.ts +973 -0
  89. package/dist/node/generated/web/identity_pb.js +8058 -0
  90. package/dist/node/generated/web/numbers.ts +1371 -0
  91. package/dist/node/generated/web/numbers_pb.d.ts +305 -0
  92. package/dist/node/generated/web/numbers_pb.js +2470 -0
  93. package/dist/node/generated/web/secrets.ts +985 -0
  94. package/dist/node/generated/web/secrets_pb.d.ts +222 -0
  95. package/dist/node/generated/web/secrets_pb.js +1838 -0
  96. package/dist/node/generated/web/trunks.ts +1546 -0
  97. package/dist/node/generated/web/trunks_pb.d.ts +338 -0
  98. package/dist/node/generated/web/trunks_pb.js +2777 -0
  99. package/dist/node/node.d.ts +2 -0
  100. package/dist/node/node.js +36 -0
  101. package/dist/node/tsconfig.node.tsbuildinfo +1 -0
  102. package/dist/node/utils.d.ts +22 -0
  103. package/dist/node/utils.js +54 -0
  104. package/dist/web/fonoster.min.js +1 -0
  105. package/dist/web/index.esm.js +1 -0
  106. package/package.json +24 -12
  107. package/dist/fonoster.min.js +0 -1
  108. package/dist/index.d.ts +0 -6
  109. package/dist/index.esm.js +0 -1
  110. package/dist/index.js +0 -1
  111. package/dist/printHello.d.ts +0 -2
@@ -0,0 +1,322 @@
1
+ import * as jspb from 'google-protobuf'
2
+
3
+ import * as google_protobuf_struct_pb from 'google-protobuf/google/protobuf/struct_pb'; // proto import: "google/protobuf/struct.proto"
4
+
5
+
6
+ export class ProductContainer extends jspb.Message {
7
+ getProductRef(): string;
8
+ setProductRef(value: string): ProductContainer;
9
+
10
+ getConfig(): google_protobuf_struct_pb.Struct | undefined;
11
+ setConfig(value?: google_protobuf_struct_pb.Struct): ProductContainer;
12
+ hasConfig(): boolean;
13
+ clearConfig(): ProductContainer;
14
+
15
+ getCredentials(): google_protobuf_struct_pb.Struct | undefined;
16
+ setCredentials(value?: google_protobuf_struct_pb.Struct): ProductContainer;
17
+ hasCredentials(): boolean;
18
+ clearCredentials(): ProductContainer;
19
+
20
+ serializeBinary(): Uint8Array;
21
+ toObject(includeInstance?: boolean): ProductContainer.AsObject;
22
+ static toObject(includeInstance: boolean, msg: ProductContainer): ProductContainer.AsObject;
23
+ static serializeBinaryToWriter(message: ProductContainer, writer: jspb.BinaryWriter): void;
24
+ static deserializeBinary(bytes: Uint8Array): ProductContainer;
25
+ static deserializeBinaryFromReader(message: ProductContainer, reader: jspb.BinaryReader): ProductContainer;
26
+ }
27
+
28
+ export namespace ProductContainer {
29
+ export type AsObject = {
30
+ productRef: string,
31
+ config?: google_protobuf_struct_pb.Struct.AsObject,
32
+ credentials?: google_protobuf_struct_pb.Struct.AsObject,
33
+ }
34
+ }
35
+
36
+ export class Application extends jspb.Message {
37
+ getRef(): string;
38
+ setRef(value: string): Application;
39
+
40
+ getName(): string;
41
+ setName(value: string): Application;
42
+
43
+ getType(): ApplicationType;
44
+ setType(value: ApplicationType): Application;
45
+
46
+ getAppEndpoint(): string;
47
+ setAppEndpoint(value: string): Application;
48
+
49
+ getTextToSpeech(): ProductContainer | undefined;
50
+ setTextToSpeech(value?: ProductContainer): Application;
51
+ hasTextToSpeech(): boolean;
52
+ clearTextToSpeech(): Application;
53
+
54
+ getSpeechToText(): ProductContainer | undefined;
55
+ setSpeechToText(value?: ProductContainer): Application;
56
+ hasSpeechToText(): boolean;
57
+ clearSpeechToText(): Application;
58
+
59
+ getConversation(): ProductContainer | undefined;
60
+ setConversation(value?: ProductContainer): Application;
61
+ hasConversation(): boolean;
62
+ clearConversation(): Application;
63
+
64
+ getCreatedAt(): number;
65
+ setCreatedAt(value: number): Application;
66
+
67
+ getUpdatedAt(): number;
68
+ setUpdatedAt(value: number): Application;
69
+
70
+ serializeBinary(): Uint8Array;
71
+ toObject(includeInstance?: boolean): Application.AsObject;
72
+ static toObject(includeInstance: boolean, msg: Application): Application.AsObject;
73
+ static serializeBinaryToWriter(message: Application, writer: jspb.BinaryWriter): void;
74
+ static deserializeBinary(bytes: Uint8Array): Application;
75
+ static deserializeBinaryFromReader(message: Application, reader: jspb.BinaryReader): Application;
76
+ }
77
+
78
+ export namespace Application {
79
+ export type AsObject = {
80
+ ref: string,
81
+ name: string,
82
+ type: ApplicationType,
83
+ appEndpoint: string,
84
+ textToSpeech?: ProductContainer.AsObject,
85
+ speechToText?: ProductContainer.AsObject,
86
+ conversation?: ProductContainer.AsObject,
87
+ createdAt: number,
88
+ updatedAt: number,
89
+ }
90
+ }
91
+
92
+ export class CreateApplicationRequest extends jspb.Message {
93
+ getName(): string;
94
+ setName(value: string): CreateApplicationRequest;
95
+
96
+ getType(): ApplicationType;
97
+ setType(value: ApplicationType): CreateApplicationRequest;
98
+
99
+ getAppEndpoint(): string;
100
+ setAppEndpoint(value: string): CreateApplicationRequest;
101
+
102
+ getTextToSpeech(): ProductContainer | undefined;
103
+ setTextToSpeech(value?: ProductContainer): CreateApplicationRequest;
104
+ hasTextToSpeech(): boolean;
105
+ clearTextToSpeech(): CreateApplicationRequest;
106
+
107
+ getSpeechToText(): ProductContainer | undefined;
108
+ setSpeechToText(value?: ProductContainer): CreateApplicationRequest;
109
+ hasSpeechToText(): boolean;
110
+ clearSpeechToText(): CreateApplicationRequest;
111
+
112
+ getIntelligence(): ProductContainer | undefined;
113
+ setIntelligence(value?: ProductContainer): CreateApplicationRequest;
114
+ hasIntelligence(): boolean;
115
+ clearIntelligence(): CreateApplicationRequest;
116
+
117
+ serializeBinary(): Uint8Array;
118
+ toObject(includeInstance?: boolean): CreateApplicationRequest.AsObject;
119
+ static toObject(includeInstance: boolean, msg: CreateApplicationRequest): CreateApplicationRequest.AsObject;
120
+ static serializeBinaryToWriter(message: CreateApplicationRequest, writer: jspb.BinaryWriter): void;
121
+ static deserializeBinary(bytes: Uint8Array): CreateApplicationRequest;
122
+ static deserializeBinaryFromReader(message: CreateApplicationRequest, reader: jspb.BinaryReader): CreateApplicationRequest;
123
+ }
124
+
125
+ export namespace CreateApplicationRequest {
126
+ export type AsObject = {
127
+ name: string,
128
+ type: ApplicationType,
129
+ appEndpoint: string,
130
+ textToSpeech?: ProductContainer.AsObject,
131
+ speechToText?: ProductContainer.AsObject,
132
+ intelligence?: ProductContainer.AsObject,
133
+ }
134
+ }
135
+
136
+ export class CreateApplicationResponse extends jspb.Message {
137
+ getRef(): string;
138
+ setRef(value: string): CreateApplicationResponse;
139
+
140
+ serializeBinary(): Uint8Array;
141
+ toObject(includeInstance?: boolean): CreateApplicationResponse.AsObject;
142
+ static toObject(includeInstance: boolean, msg: CreateApplicationResponse): CreateApplicationResponse.AsObject;
143
+ static serializeBinaryToWriter(message: CreateApplicationResponse, writer: jspb.BinaryWriter): void;
144
+ static deserializeBinary(bytes: Uint8Array): CreateApplicationResponse;
145
+ static deserializeBinaryFromReader(message: CreateApplicationResponse, reader: jspb.BinaryReader): CreateApplicationResponse;
146
+ }
147
+
148
+ export namespace CreateApplicationResponse {
149
+ export type AsObject = {
150
+ ref: string,
151
+ }
152
+ }
153
+
154
+ export class GetApplicationRequest extends jspb.Message {
155
+ getRef(): string;
156
+ setRef(value: string): GetApplicationRequest;
157
+
158
+ serializeBinary(): Uint8Array;
159
+ toObject(includeInstance?: boolean): GetApplicationRequest.AsObject;
160
+ static toObject(includeInstance: boolean, msg: GetApplicationRequest): GetApplicationRequest.AsObject;
161
+ static serializeBinaryToWriter(message: GetApplicationRequest, writer: jspb.BinaryWriter): void;
162
+ static deserializeBinary(bytes: Uint8Array): GetApplicationRequest;
163
+ static deserializeBinaryFromReader(message: GetApplicationRequest, reader: jspb.BinaryReader): GetApplicationRequest;
164
+ }
165
+
166
+ export namespace GetApplicationRequest {
167
+ export type AsObject = {
168
+ ref: string,
169
+ }
170
+ }
171
+
172
+ export class ListApplicationsRequest extends jspb.Message {
173
+ getPageSize(): number;
174
+ setPageSize(value: number): ListApplicationsRequest;
175
+
176
+ getPageToken(): string;
177
+ setPageToken(value: string): ListApplicationsRequest;
178
+
179
+ serializeBinary(): Uint8Array;
180
+ toObject(includeInstance?: boolean): ListApplicationsRequest.AsObject;
181
+ static toObject(includeInstance: boolean, msg: ListApplicationsRequest): ListApplicationsRequest.AsObject;
182
+ static serializeBinaryToWriter(message: ListApplicationsRequest, writer: jspb.BinaryWriter): void;
183
+ static deserializeBinary(bytes: Uint8Array): ListApplicationsRequest;
184
+ static deserializeBinaryFromReader(message: ListApplicationsRequest, reader: jspb.BinaryReader): ListApplicationsRequest;
185
+ }
186
+
187
+ export namespace ListApplicationsRequest {
188
+ export type AsObject = {
189
+ pageSize: number,
190
+ pageToken: string,
191
+ }
192
+ }
193
+
194
+ export class ListApplicationsResponse extends jspb.Message {
195
+ getItemsList(): Array<Application>;
196
+ setItemsList(value: Array<Application>): ListApplicationsResponse;
197
+ clearItemsList(): ListApplicationsResponse;
198
+ addItems(value?: Application, index?: number): Application;
199
+
200
+ getNextPageToken(): string;
201
+ setNextPageToken(value: string): ListApplicationsResponse;
202
+
203
+ serializeBinary(): Uint8Array;
204
+ toObject(includeInstance?: boolean): ListApplicationsResponse.AsObject;
205
+ static toObject(includeInstance: boolean, msg: ListApplicationsResponse): ListApplicationsResponse.AsObject;
206
+ static serializeBinaryToWriter(message: ListApplicationsResponse, writer: jspb.BinaryWriter): void;
207
+ static deserializeBinary(bytes: Uint8Array): ListApplicationsResponse;
208
+ static deserializeBinaryFromReader(message: ListApplicationsResponse, reader: jspb.BinaryReader): ListApplicationsResponse;
209
+ }
210
+
211
+ export namespace ListApplicationsResponse {
212
+ export type AsObject = {
213
+ itemsList: Array<Application.AsObject>,
214
+ nextPageToken: string,
215
+ }
216
+ }
217
+
218
+ export class UpdateApplicationRequest extends jspb.Message {
219
+ getRef(): string;
220
+ setRef(value: string): UpdateApplicationRequest;
221
+
222
+ getName(): string;
223
+ setName(value: string): UpdateApplicationRequest;
224
+
225
+ getType(): ApplicationType;
226
+ setType(value: ApplicationType): UpdateApplicationRequest;
227
+
228
+ getAppEndpoint(): string;
229
+ setAppEndpoint(value: string): UpdateApplicationRequest;
230
+
231
+ getTextToSpeech(): ProductContainer | undefined;
232
+ setTextToSpeech(value?: ProductContainer): UpdateApplicationRequest;
233
+ hasTextToSpeech(): boolean;
234
+ clearTextToSpeech(): UpdateApplicationRequest;
235
+
236
+ getSpeechToText(): ProductContainer | undefined;
237
+ setSpeechToText(value?: ProductContainer): UpdateApplicationRequest;
238
+ hasSpeechToText(): boolean;
239
+ clearSpeechToText(): UpdateApplicationRequest;
240
+
241
+ getIntelligence(): ProductContainer | undefined;
242
+ setIntelligence(value?: ProductContainer): UpdateApplicationRequest;
243
+ hasIntelligence(): boolean;
244
+ clearIntelligence(): UpdateApplicationRequest;
245
+
246
+ serializeBinary(): Uint8Array;
247
+ toObject(includeInstance?: boolean): UpdateApplicationRequest.AsObject;
248
+ static toObject(includeInstance: boolean, msg: UpdateApplicationRequest): UpdateApplicationRequest.AsObject;
249
+ static serializeBinaryToWriter(message: UpdateApplicationRequest, writer: jspb.BinaryWriter): void;
250
+ static deserializeBinary(bytes: Uint8Array): UpdateApplicationRequest;
251
+ static deserializeBinaryFromReader(message: UpdateApplicationRequest, reader: jspb.BinaryReader): UpdateApplicationRequest;
252
+ }
253
+
254
+ export namespace UpdateApplicationRequest {
255
+ export type AsObject = {
256
+ ref: string,
257
+ name: string,
258
+ type: ApplicationType,
259
+ appEndpoint: string,
260
+ textToSpeech?: ProductContainer.AsObject,
261
+ speechToText?: ProductContainer.AsObject,
262
+ intelligence?: ProductContainer.AsObject,
263
+ }
264
+ }
265
+
266
+ export class UpdateApplicationResponse extends jspb.Message {
267
+ getRef(): string;
268
+ setRef(value: string): UpdateApplicationResponse;
269
+
270
+ serializeBinary(): Uint8Array;
271
+ toObject(includeInstance?: boolean): UpdateApplicationResponse.AsObject;
272
+ static toObject(includeInstance: boolean, msg: UpdateApplicationResponse): UpdateApplicationResponse.AsObject;
273
+ static serializeBinaryToWriter(message: UpdateApplicationResponse, writer: jspb.BinaryWriter): void;
274
+ static deserializeBinary(bytes: Uint8Array): UpdateApplicationResponse;
275
+ static deserializeBinaryFromReader(message: UpdateApplicationResponse, reader: jspb.BinaryReader): UpdateApplicationResponse;
276
+ }
277
+
278
+ export namespace UpdateApplicationResponse {
279
+ export type AsObject = {
280
+ ref: string,
281
+ }
282
+ }
283
+
284
+ export class DeleteApplicationRequest extends jspb.Message {
285
+ getRef(): string;
286
+ setRef(value: string): DeleteApplicationRequest;
287
+
288
+ serializeBinary(): Uint8Array;
289
+ toObject(includeInstance?: boolean): DeleteApplicationRequest.AsObject;
290
+ static toObject(includeInstance: boolean, msg: DeleteApplicationRequest): DeleteApplicationRequest.AsObject;
291
+ static serializeBinaryToWriter(message: DeleteApplicationRequest, writer: jspb.BinaryWriter): void;
292
+ static deserializeBinary(bytes: Uint8Array): DeleteApplicationRequest;
293
+ static deserializeBinaryFromReader(message: DeleteApplicationRequest, reader: jspb.BinaryReader): DeleteApplicationRequest;
294
+ }
295
+
296
+ export namespace DeleteApplicationRequest {
297
+ export type AsObject = {
298
+ ref: string,
299
+ }
300
+ }
301
+
302
+ export class DeleteApplicationResponse extends jspb.Message {
303
+ getRef(): string;
304
+ setRef(value: string): DeleteApplicationResponse;
305
+
306
+ serializeBinary(): Uint8Array;
307
+ toObject(includeInstance?: boolean): DeleteApplicationResponse.AsObject;
308
+ static toObject(includeInstance: boolean, msg: DeleteApplicationResponse): DeleteApplicationResponse.AsObject;
309
+ static serializeBinaryToWriter(message: DeleteApplicationResponse, writer: jspb.BinaryWriter): void;
310
+ static deserializeBinary(bytes: Uint8Array): DeleteApplicationResponse;
311
+ static deserializeBinaryFromReader(message: DeleteApplicationResponse, reader: jspb.BinaryReader): DeleteApplicationResponse;
312
+ }
313
+
314
+ export namespace DeleteApplicationResponse {
315
+ export type AsObject = {
316
+ ref: string,
317
+ }
318
+ }
319
+
320
+ export enum ApplicationType {
321
+ PROGRAMMABLE_VOICE = 0,
322
+ }