@fonoster/sdk 0.27.0 → 0.31.0
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/README.md +12 -9
- package/dist/node/Agents.js +5 -20
- package/dist/node/Applications.d.ts +21 -85
- package/dist/node/Applications.js +64 -74
- package/dist/node/Billing.d.ts +50 -0
- package/dist/node/Billing.js +84 -0
- package/dist/node/CallRecords.d.ts +92 -0
- package/dist/node/CallRecords.js +127 -0
- package/dist/node/Calls.d.ts +3 -1
- package/dist/node/Calls.js +3 -1
- package/dist/node/Domains.js +4 -2
- package/dist/node/Numbers.js +2 -7
- package/dist/node/Providers.d.ts +49 -0
- package/dist/node/Providers.js +109 -0
- package/dist/node/Regions.d.ts +91 -0
- package/dist/node/Regions.js +127 -0
- package/dist/node/Usage.d.ts +44 -0
- package/dist/node/Usage.js +41 -0
- package/dist/node/Users.d.ts +4 -2
- package/dist/node/Users.js +4 -2
- package/dist/node/Webhooks.d.ts +56 -0
- package/dist/node/Webhooks.js +139 -0
- package/dist/node/Workspaces.d.ts +22 -3
- package/dist/node/Workspaces.js +29 -2
- package/dist/node/client/AbstractClient.d.ts +94 -3
- package/dist/node/client/AbstractClient.js +101 -1
- package/dist/node/client/Client.d.ts +9 -0
- package/dist/node/client/Client.js +34 -1
- package/dist/node/client/jsonToObject.js +17 -0
- package/dist/node/client/objectToJson.js +35 -0
- package/dist/node/client/types/ApplicationsClient.d.ts +2 -1
- package/dist/node/client/types/BillingClient.d.ts +28 -0
- package/dist/node/client/types/BillingClient.js +2 -0
- package/dist/node/client/types/CapabilitiesClient.d.ts +24 -0
- package/dist/node/client/types/CapabilitiesClient.js +2 -0
- package/dist/node/client/types/FonosterClient.d.ts +12 -0
- package/dist/node/client/types/IdentityClient.d.ts +3 -1
- package/dist/node/client/types/ProvidersClient.d.ts +28 -0
- package/dist/node/client/types/ProvidersClient.js +2 -0
- package/dist/node/client/types/UsageClient.d.ts +24 -0
- package/dist/node/client/types/UsageClient.js +2 -0
- package/dist/node/client/types/WebhooksClient.d.ts +31 -0
- package/dist/node/client/types/WebhooksClient.js +2 -0
- package/dist/node/client/types/index.d.ts +5 -0
- package/dist/node/client/types/index.js +5 -0
- package/dist/node/generated/node/applications_grpc_pb.js +34 -0
- package/dist/node/generated/node/applications_pb.js +2991 -178
- package/dist/node/generated/node/billing_grpc_pb.js +169 -0
- package/dist/node/generated/node/billing_pb.js +1720 -0
- package/dist/node/generated/node/calls_pb.js +62 -2
- package/dist/node/generated/node/capabilities_grpc_pb.js +66 -0
- package/dist/node/generated/node/capabilities_pb.js +2288 -0
- package/dist/node/generated/node/identity_grpc_pb.js +34 -0
- package/dist/node/generated/node/identity_pb.js +609 -5
- package/dist/node/generated/node/providers_grpc_pb.js +200 -0
- package/dist/node/generated/node/providers_pb.js +3094 -0
- package/dist/node/generated/node/usage_grpc_pb.js +64 -0
- package/dist/node/generated/node/usage_pb.js +866 -0
- package/dist/node/generated/node/webhooks_grpc_pb.js +302 -0
- package/dist/node/generated/node/webhooks_pb.js +3314 -0
- package/dist/node/generated/web/ApplicationsServiceClientPb.ts +43 -0
- package/dist/node/generated/web/BillingServiceClientPb.ts +258 -0
- package/dist/node/generated/web/CapabilitiesServiceClientPb.ts +87 -0
- package/dist/node/generated/web/IdentityServiceClientPb.ts +43 -0
- package/dist/node/generated/web/ProvidersServiceClientPb.ts +258 -0
- package/dist/node/generated/web/UsageServiceClientPb.ts +86 -0
- package/dist/node/generated/web/WebhooksServiceClientPb.ts +387 -0
- package/dist/node/generated/web/applications_pb.d.ts +343 -1
- package/dist/node/generated/web/applications_pb.js +2991 -178
- package/dist/node/generated/web/billing_pb.d.ts +210 -0
- package/dist/node/generated/web/billing_pb.js +1720 -0
- package/dist/node/generated/web/calls_pb.d.ts +8 -0
- package/dist/node/generated/web/calls_pb.js +62 -2
- package/dist/node/generated/web/capabilities_pb.d.ts +273 -0
- package/dist/node/generated/web/capabilities_pb.js +2288 -0
- package/dist/node/generated/web/identity_pb.d.ts +76 -0
- package/dist/node/generated/web/identity_pb.js +609 -5
- package/dist/node/generated/web/providers_pb.d.ts +372 -0
- package/dist/node/generated/web/providers_pb.js +3094 -0
- package/dist/node/generated/web/usage_pb.d.ts +106 -0
- package/dist/node/generated/web/usage_pb.js +866 -0
- package/dist/node/generated/web/webhooks_pb.d.ts +398 -0
- package/dist/node/generated/web/webhooks_pb.js +3314 -0
- package/dist/node/node.d.ts +7 -0
- package/dist/node/node.js +6 -0
- package/dist/node/tsconfig.tsbuildinfo +1 -1
- package/dist/node/utils.d.ts +7 -12
- package/dist/node/utils.js +18 -39
- package/dist/web/fonoster.min.js +1 -1
- package/dist/web/index.esm.js +1 -1
- package/package.json +8 -13
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (C) 2025 by Fonoster Inc (https://fonoster.com)
|
|
3
|
+
* http://github.com/fonoster/fonoster
|
|
4
|
+
*
|
|
5
|
+
* This file is part of Fonoster
|
|
6
|
+
*
|
|
7
|
+
* Licensed under the MIT License (the "License");
|
|
8
|
+
* you may not use this file except in compliance with
|
|
9
|
+
* the License. You may obtain a copy of the License at
|
|
10
|
+
*
|
|
11
|
+
* https://opensource.org/licenses/MIT
|
|
12
|
+
*
|
|
13
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
14
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
15
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
16
|
+
* See the License for the specific language governing permissions and
|
|
17
|
+
* limitations under the License.
|
|
18
|
+
*/
|
|
19
|
+
import { CreateWebhookRequest, CreateWebhookResponse, DeleteWebhookRequest, DeleteWebhookResponse, GetWebhookRequest, ListWebhookDeliveriesRequest, ListWebhookDeliveriesResponse, ListWebhooksRequest, ListWebhooksResponse, ResendWebhookDeliveryRequest, RotateWebhookSecretRequest, RotateWebhookSecretResponse, UpdateWebhookRequest, UpdateWebhookResponse, Webhook, WebhookDelivery } from "../../generated/web/webhooks_pb";
|
|
20
|
+
import { ClientFunction } from "./common";
|
|
21
|
+
type WebhooksClient = {
|
|
22
|
+
createWebhook: ClientFunction<CreateWebhookRequest, CreateWebhookResponse>;
|
|
23
|
+
listWebhooks: ClientFunction<ListWebhooksRequest, ListWebhooksResponse>;
|
|
24
|
+
getWebhook: ClientFunction<GetWebhookRequest, Webhook>;
|
|
25
|
+
updateWebhook: ClientFunction<UpdateWebhookRequest, UpdateWebhookResponse>;
|
|
26
|
+
deleteWebhook: ClientFunction<DeleteWebhookRequest, DeleteWebhookResponse>;
|
|
27
|
+
rotateWebhookSecret: ClientFunction<RotateWebhookSecretRequest, RotateWebhookSecretResponse>;
|
|
28
|
+
listWebhookDeliveries: ClientFunction<ListWebhookDeliveriesRequest, ListWebhookDeliveriesResponse>;
|
|
29
|
+
resendWebhookDelivery: ClientFunction<ResendWebhookDeliveryRequest, WebhookDelivery>;
|
|
30
|
+
};
|
|
31
|
+
export { WebhooksClient };
|
|
@@ -18,7 +18,12 @@
|
|
|
18
18
|
*/
|
|
19
19
|
export * from "./ApplicationsClient";
|
|
20
20
|
export * from "./CallsClient";
|
|
21
|
+
export * from "./CapabilitiesClient";
|
|
21
22
|
export * from "./FonosterClient";
|
|
22
23
|
export * from "./IdentityClient";
|
|
23
24
|
export * from "./SecretsClient";
|
|
24
25
|
export * from "./common";
|
|
26
|
+
export * from "./ProvidersClient";
|
|
27
|
+
export * from "./UsageClient";
|
|
28
|
+
export * from "./BillingClient";
|
|
29
|
+
export * from "./WebhooksClient";
|
|
@@ -34,7 +34,12 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
34
34
|
*/
|
|
35
35
|
__exportStar(require("./ApplicationsClient"), exports);
|
|
36
36
|
__exportStar(require("./CallsClient"), exports);
|
|
37
|
+
__exportStar(require("./CapabilitiesClient"), exports);
|
|
37
38
|
__exportStar(require("./FonosterClient"), exports);
|
|
38
39
|
__exportStar(require("./IdentityClient"), exports);
|
|
39
40
|
__exportStar(require("./SecretsClient"), exports);
|
|
40
41
|
__exportStar(require("./common"), exports);
|
|
42
|
+
__exportStar(require("./ProvidersClient"), exports);
|
|
43
|
+
__exportStar(require("./UsageClient"), exports);
|
|
44
|
+
__exportStar(require("./BillingClient"), exports);
|
|
45
|
+
__exportStar(require("./WebhooksClient"), exports);
|
|
@@ -134,6 +134,28 @@ function deserialize_fonoster_applications_v1beta2_ListApplicationsResponse(buff
|
|
|
134
134
|
return applications_pb.ListApplicationsResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
135
135
|
}
|
|
136
136
|
|
|
137
|
+
function serialize_fonoster_applications_v1beta2_RotateSigningSecretRequest(arg) {
|
|
138
|
+
if (!(arg instanceof applications_pb.RotateSigningSecretRequest)) {
|
|
139
|
+
throw new Error('Expected argument of type fonoster.applications.v1beta2.RotateSigningSecretRequest');
|
|
140
|
+
}
|
|
141
|
+
return Buffer.from(arg.serializeBinary());
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
function deserialize_fonoster_applications_v1beta2_RotateSigningSecretRequest(buffer_arg) {
|
|
145
|
+
return applications_pb.RotateSigningSecretRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
function serialize_fonoster_applications_v1beta2_RotateSigningSecretResponse(arg) {
|
|
149
|
+
if (!(arg instanceof applications_pb.RotateSigningSecretResponse)) {
|
|
150
|
+
throw new Error('Expected argument of type fonoster.applications.v1beta2.RotateSigningSecretResponse');
|
|
151
|
+
}
|
|
152
|
+
return Buffer.from(arg.serializeBinary());
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
function deserialize_fonoster_applications_v1beta2_RotateSigningSecretResponse(buffer_arg) {
|
|
156
|
+
return applications_pb.RotateSigningSecretResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
157
|
+
}
|
|
158
|
+
|
|
137
159
|
function serialize_fonoster_applications_v1beta2_TestTokenResponse(arg) {
|
|
138
160
|
if (!(arg instanceof applications_pb.TestTokenResponse)) {
|
|
139
161
|
throw new Error('Expected argument of type fonoster.applications.v1beta2.TestTokenResponse');
|
|
@@ -265,6 +287,18 @@ createTestToken: {
|
|
|
265
287
|
responseSerialize: serialize_fonoster_applications_v1beta2_TestTokenResponse,
|
|
266
288
|
responseDeserialize: deserialize_fonoster_applications_v1beta2_TestTokenResponse,
|
|
267
289
|
},
|
|
290
|
+
// Replace an application's signing secret; the old one stops working at once (no overlap)
|
|
291
|
+
rotateSigningSecret: {
|
|
292
|
+
path: '/fonoster.applications.v1beta2.Applications/RotateSigningSecret',
|
|
293
|
+
requestStream: false,
|
|
294
|
+
responseStream: false,
|
|
295
|
+
requestType: applications_pb.RotateSigningSecretRequest,
|
|
296
|
+
responseType: applications_pb.RotateSigningSecretResponse,
|
|
297
|
+
requestSerialize: serialize_fonoster_applications_v1beta2_RotateSigningSecretRequest,
|
|
298
|
+
requestDeserialize: deserialize_fonoster_applications_v1beta2_RotateSigningSecretRequest,
|
|
299
|
+
responseSerialize: serialize_fonoster_applications_v1beta2_RotateSigningSecretResponse,
|
|
300
|
+
responseDeserialize: deserialize_fonoster_applications_v1beta2_RotateSigningSecretResponse,
|
|
301
|
+
},
|
|
268
302
|
};
|
|
269
303
|
|
|
270
304
|
exports.ApplicationsClient = grpc.makeGenericClientConstructor(ApplicationsService, 'Applications');
|