@wildix/wms-api-client 1.1.7 → 1.1.9
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/dist-cjs/WmsApi.js +4 -0
- package/dist-cjs/commands/OriginateCallCommand.js +21 -0
- package/dist-cjs/commands/OriginateCommand.js +21 -0
- package/dist-cjs/commands/index.js +2 -0
- package/dist-cjs/models/models_0.js +4 -1
- package/dist-cjs/protocols/Aws_restJson1.js +78 -1
- package/dist-es/WmsApi.js +4 -0
- package/dist-es/commands/OriginateCallCommand.js +17 -0
- package/dist-es/commands/OriginateCommand.js +17 -0
- package/dist-es/commands/index.js +2 -0
- package/dist-es/models/models_0.js +3 -0
- package/dist-es/protocols/Aws_restJson1.js +73 -0
- package/dist-types/WmsApi.d.ts +14 -0
- package/dist-types/WmsApiClient.d.ts +4 -2
- package/dist-types/commands/OriginateCallCommand.d.ts +65 -0
- package/dist-types/commands/OriginateCommand.d.ts +74 -0
- package/dist-types/commands/index.d.ts +2 -0
- package/dist-types/models/models_0.d.ts +62 -0
- package/dist-types/protocols/Aws_restJson1.d.ts +18 -0
- package/package.json +1 -1
package/dist-cjs/WmsApi.js
CHANGED
|
@@ -9,6 +9,8 @@ const GetPbxCallGroupsCommand_1 = require("./commands/GetPbxCallGroupsCommand");
|
|
|
9
9
|
const GetPbxColleaguesCommand_1 = require("./commands/GetPbxColleaguesCommand");
|
|
10
10
|
const GetPbxOAuth2ClientsCommand_1 = require("./commands/GetPbxOAuth2ClientsCommand");
|
|
11
11
|
const GetPbxesCommand_1 = require("./commands/GetPbxesCommand");
|
|
12
|
+
const OriginateCallCommand_1 = require("./commands/OriginateCallCommand");
|
|
13
|
+
const OriginateCommand_1 = require("./commands/OriginateCommand");
|
|
12
14
|
const UpdatePbxOAuth2ClientCommand_1 = require("./commands/UpdatePbxOAuth2ClientCommand");
|
|
13
15
|
const smithy_client_1 = require("@smithy/smithy-client");
|
|
14
16
|
const commands = {
|
|
@@ -19,6 +21,8 @@ const commands = {
|
|
|
19
21
|
GetPbxColleaguesCommand: GetPbxColleaguesCommand_1.GetPbxColleaguesCommand,
|
|
20
22
|
GetPbxesCommand: GetPbxesCommand_1.GetPbxesCommand,
|
|
21
23
|
GetPbxOAuth2ClientsCommand: GetPbxOAuth2ClientsCommand_1.GetPbxOAuth2ClientsCommand,
|
|
24
|
+
OriginateCommand: OriginateCommand_1.OriginateCommand,
|
|
25
|
+
OriginateCallCommand: OriginateCallCommand_1.OriginateCallCommand,
|
|
22
26
|
UpdatePbxOAuth2ClientCommand: UpdatePbxOAuth2ClientCommand_1.UpdatePbxOAuth2ClientCommand,
|
|
23
27
|
};
|
|
24
28
|
class WmsApi extends WmsApiClient_1.WmsApiClient {
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.OriginateCallCommand = exports.$Command = void 0;
|
|
4
|
+
const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
|
|
5
|
+
const middleware_serde_1 = require("@smithy/middleware-serde");
|
|
6
|
+
const smithy_client_1 = require("@smithy/smithy-client");
|
|
7
|
+
Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
|
|
8
|
+
class OriginateCallCommand extends smithy_client_1.Command.classBuilder()
|
|
9
|
+
.m(function (Command, cs, config, o) {
|
|
10
|
+
return [
|
|
11
|
+
(0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
|
|
12
|
+
];
|
|
13
|
+
})
|
|
14
|
+
.s("WmsApi", "OriginateCall", {})
|
|
15
|
+
.n("WmsApiClient", "OriginateCallCommand")
|
|
16
|
+
.f(void 0, void 0)
|
|
17
|
+
.ser(Aws_restJson1_1.se_OriginateCallCommand)
|
|
18
|
+
.de(Aws_restJson1_1.de_OriginateCallCommand)
|
|
19
|
+
.build() {
|
|
20
|
+
}
|
|
21
|
+
exports.OriginateCallCommand = OriginateCallCommand;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.OriginateCommand = exports.$Command = void 0;
|
|
4
|
+
const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
|
|
5
|
+
const middleware_serde_1 = require("@smithy/middleware-serde");
|
|
6
|
+
const smithy_client_1 = require("@smithy/smithy-client");
|
|
7
|
+
Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
|
|
8
|
+
class OriginateCommand extends smithy_client_1.Command.classBuilder()
|
|
9
|
+
.m(function (Command, cs, config, o) {
|
|
10
|
+
return [
|
|
11
|
+
(0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
|
|
12
|
+
];
|
|
13
|
+
})
|
|
14
|
+
.s("WmsApi", "Originate", {})
|
|
15
|
+
.n("WmsApiClient", "OriginateCommand")
|
|
16
|
+
.f(void 0, void 0)
|
|
17
|
+
.ser(Aws_restJson1_1.se_OriginateCommand)
|
|
18
|
+
.de(Aws_restJson1_1.de_OriginateCommand)
|
|
19
|
+
.build() {
|
|
20
|
+
}
|
|
21
|
+
exports.OriginateCommand = OriginateCommand;
|
|
@@ -8,4 +8,6 @@ tslib_1.__exportStar(require("./GetPbxCallGroupsCommand"), exports);
|
|
|
8
8
|
tslib_1.__exportStar(require("./GetPbxColleaguesCommand"), exports);
|
|
9
9
|
tslib_1.__exportStar(require("./GetPbxesCommand"), exports);
|
|
10
10
|
tslib_1.__exportStar(require("./GetPbxOAuth2ClientsCommand"), exports);
|
|
11
|
+
tslib_1.__exportStar(require("./OriginateCommand"), exports);
|
|
12
|
+
tslib_1.__exportStar(require("./OriginateCallCommand"), exports);
|
|
11
13
|
tslib_1.__exportStar(require("./UpdatePbxOAuth2ClientCommand"), exports);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.PbxColleagueRole = exports.PbxColleaguesSearchStrategy = exports.PbxColleaguesQueryField = exports.GetPbxColleaguesDir = exports.WmsNotFoundException = exports.WmsValidationException = exports.WmsUnauthorizedException = exports.ResponseType = exports.AclGroupPermissionAbility = exports.PbxLicenseType = void 0;
|
|
3
|
+
exports.ResponseResult = exports.PbxColleagueRole = exports.PbxColleaguesSearchStrategy = exports.PbxColleaguesQueryField = exports.GetPbxColleaguesDir = exports.WmsNotFoundException = exports.WmsValidationException = exports.WmsUnauthorizedException = exports.ResponseType = exports.AclGroupPermissionAbility = exports.PbxLicenseType = void 0;
|
|
4
4
|
const WmsApiServiceException_1 = require("./WmsApiServiceException");
|
|
5
5
|
exports.PbxLicenseType = {
|
|
6
6
|
BASIC: "basic",
|
|
@@ -99,3 +99,6 @@ exports.PbxColleagueRole = {
|
|
|
99
99
|
ROOM: "room",
|
|
100
100
|
USER: "user",
|
|
101
101
|
};
|
|
102
|
+
exports.ResponseResult = {
|
|
103
|
+
SUCCESS: "Success",
|
|
104
|
+
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.de_UpdatePbxOAuth2ClientCommand = exports.de_GetPbxOAuth2ClientsCommand = exports.de_GetPbxesCommand = exports.de_GetPbxColleaguesCommand = exports.de_GetPbxCallGroupsCommand = exports.de_GetPbxAclGroupsPermissionsCommand = exports.de_DeletePbxOAuth2ClientCommand = exports.de_CreatePbxOAuth2ClientCommand = exports.se_UpdatePbxOAuth2ClientCommand = exports.se_GetPbxOAuth2ClientsCommand = exports.se_GetPbxesCommand = exports.se_GetPbxColleaguesCommand = exports.se_GetPbxCallGroupsCommand = exports.se_GetPbxAclGroupsPermissionsCommand = exports.se_DeletePbxOAuth2ClientCommand = exports.se_CreatePbxOAuth2ClientCommand = void 0;
|
|
3
|
+
exports.de_UpdatePbxOAuth2ClientCommand = exports.de_OriginateCallCommand = exports.de_OriginateCommand = exports.de_GetPbxOAuth2ClientsCommand = exports.de_GetPbxesCommand = exports.de_GetPbxColleaguesCommand = exports.de_GetPbxCallGroupsCommand = exports.de_GetPbxAclGroupsPermissionsCommand = exports.de_DeletePbxOAuth2ClientCommand = exports.de_CreatePbxOAuth2ClientCommand = exports.se_UpdatePbxOAuth2ClientCommand = exports.se_OriginateCallCommand = exports.se_OriginateCommand = exports.se_GetPbxOAuth2ClientsCommand = exports.se_GetPbxesCommand = exports.se_GetPbxColleaguesCommand = exports.se_GetPbxCallGroupsCommand = exports.se_GetPbxAclGroupsPermissionsCommand = exports.se_DeletePbxOAuth2ClientCommand = exports.se_CreatePbxOAuth2ClientCommand = void 0;
|
|
4
4
|
const WmsApiServiceException_1 = require("../models/WmsApiServiceException");
|
|
5
5
|
const models_0_1 = require("../models/models_0");
|
|
6
6
|
const core_1 = require("@smithy/core");
|
|
@@ -128,6 +128,51 @@ const se_GetPbxOAuth2ClientsCommand = async (input, context) => {
|
|
|
128
128
|
return b.build();
|
|
129
129
|
};
|
|
130
130
|
exports.se_GetPbxOAuth2ClientsCommand = se_GetPbxOAuth2ClientsCommand;
|
|
131
|
+
const se_OriginateCommand = async (input, context) => {
|
|
132
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
133
|
+
const headers = {
|
|
134
|
+
'content-type': 'application/json',
|
|
135
|
+
};
|
|
136
|
+
b.bp("/api/v1/originate");
|
|
137
|
+
let body;
|
|
138
|
+
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
139
|
+
'account': [],
|
|
140
|
+
'actionid': [],
|
|
141
|
+
'application': [],
|
|
142
|
+
'async': [],
|
|
143
|
+
'callerid': [],
|
|
144
|
+
'channel': [],
|
|
145
|
+
'context': [],
|
|
146
|
+
'data': [],
|
|
147
|
+
'exten': [],
|
|
148
|
+
'priority': [],
|
|
149
|
+
'timeout': [],
|
|
150
|
+
'variable': [],
|
|
151
|
+
}));
|
|
152
|
+
b.m("POST")
|
|
153
|
+
.h(headers)
|
|
154
|
+
.b(body);
|
|
155
|
+
return b.build();
|
|
156
|
+
};
|
|
157
|
+
exports.se_OriginateCommand = se_OriginateCommand;
|
|
158
|
+
const se_OriginateCallCommand = async (input, context) => {
|
|
159
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
160
|
+
const headers = {
|
|
161
|
+
'content-type': 'application/json',
|
|
162
|
+
};
|
|
163
|
+
b.bp("/api/v1/originate/call");
|
|
164
|
+
let body;
|
|
165
|
+
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
166
|
+
'name': [],
|
|
167
|
+
'number': [],
|
|
168
|
+
'postpone': [],
|
|
169
|
+
}));
|
|
170
|
+
b.m("POST")
|
|
171
|
+
.h(headers)
|
|
172
|
+
.b(body);
|
|
173
|
+
return b.build();
|
|
174
|
+
};
|
|
175
|
+
exports.se_OriginateCallCommand = se_OriginateCallCommand;
|
|
131
176
|
const se_UpdatePbxOAuth2ClientCommand = async (input, context) => {
|
|
132
177
|
const b = (0, core_1.requestBuilder)(input, context);
|
|
133
178
|
const headers = {
|
|
@@ -258,6 +303,38 @@ const de_GetPbxOAuth2ClientsCommand = async (output, context) => {
|
|
|
258
303
|
return contents;
|
|
259
304
|
};
|
|
260
305
|
exports.de_GetPbxOAuth2ClientsCommand = de_GetPbxOAuth2ClientsCommand;
|
|
306
|
+
const de_OriginateCommand = async (output, context) => {
|
|
307
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
308
|
+
return de_CommandError(output, context);
|
|
309
|
+
}
|
|
310
|
+
const contents = (0, smithy_client_1.map)({
|
|
311
|
+
$metadata: deserializeMetadata(output),
|
|
312
|
+
});
|
|
313
|
+
const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await parseBody(output.body, context))), "body");
|
|
314
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
315
|
+
'result': smithy_client_1.expectString,
|
|
316
|
+
'type': smithy_client_1.expectString,
|
|
317
|
+
});
|
|
318
|
+
Object.assign(contents, doc);
|
|
319
|
+
return contents;
|
|
320
|
+
};
|
|
321
|
+
exports.de_OriginateCommand = de_OriginateCommand;
|
|
322
|
+
const de_OriginateCallCommand = async (output, context) => {
|
|
323
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
324
|
+
return de_CommandError(output, context);
|
|
325
|
+
}
|
|
326
|
+
const contents = (0, smithy_client_1.map)({
|
|
327
|
+
$metadata: deserializeMetadata(output),
|
|
328
|
+
});
|
|
329
|
+
const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await parseBody(output.body, context))), "body");
|
|
330
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
331
|
+
'result': smithy_client_1.expectString,
|
|
332
|
+
'type': smithy_client_1.expectString,
|
|
333
|
+
});
|
|
334
|
+
Object.assign(contents, doc);
|
|
335
|
+
return contents;
|
|
336
|
+
};
|
|
337
|
+
exports.de_OriginateCallCommand = de_OriginateCallCommand;
|
|
261
338
|
const de_UpdatePbxOAuth2ClientCommand = async (output, context) => {
|
|
262
339
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
263
340
|
return de_CommandError(output, context);
|
package/dist-es/WmsApi.js
CHANGED
|
@@ -6,6 +6,8 @@ import { GetPbxCallGroupsCommand, } from "./commands/GetPbxCallGroupsCommand";
|
|
|
6
6
|
import { GetPbxColleaguesCommand, } from "./commands/GetPbxColleaguesCommand";
|
|
7
7
|
import { GetPbxOAuth2ClientsCommand, } from "./commands/GetPbxOAuth2ClientsCommand";
|
|
8
8
|
import { GetPbxesCommand, } from "./commands/GetPbxesCommand";
|
|
9
|
+
import { OriginateCallCommand, } from "./commands/OriginateCallCommand";
|
|
10
|
+
import { OriginateCommand, } from "./commands/OriginateCommand";
|
|
9
11
|
import { UpdatePbxOAuth2ClientCommand, } from "./commands/UpdatePbxOAuth2ClientCommand";
|
|
10
12
|
import { createAggregatedClient } from "@smithy/smithy-client";
|
|
11
13
|
const commands = {
|
|
@@ -16,6 +18,8 @@ const commands = {
|
|
|
16
18
|
GetPbxColleaguesCommand,
|
|
17
19
|
GetPbxesCommand,
|
|
18
20
|
GetPbxOAuth2ClientsCommand,
|
|
21
|
+
OriginateCommand,
|
|
22
|
+
OriginateCallCommand,
|
|
19
23
|
UpdatePbxOAuth2ClientCommand,
|
|
20
24
|
};
|
|
21
25
|
export class WmsApi extends WmsApiClient {
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { de_OriginateCallCommand, se_OriginateCallCommand, } from "../protocols/Aws_restJson1";
|
|
2
|
+
import { getSerdePlugin } from "@smithy/middleware-serde";
|
|
3
|
+
import { Command as $Command } from "@smithy/smithy-client";
|
|
4
|
+
export { $Command };
|
|
5
|
+
export class OriginateCallCommand extends $Command.classBuilder()
|
|
6
|
+
.m(function (Command, cs, config, o) {
|
|
7
|
+
return [
|
|
8
|
+
getSerdePlugin(config, this.serialize, this.deserialize),
|
|
9
|
+
];
|
|
10
|
+
})
|
|
11
|
+
.s("WmsApi", "OriginateCall", {})
|
|
12
|
+
.n("WmsApiClient", "OriginateCallCommand")
|
|
13
|
+
.f(void 0, void 0)
|
|
14
|
+
.ser(se_OriginateCallCommand)
|
|
15
|
+
.de(de_OriginateCallCommand)
|
|
16
|
+
.build() {
|
|
17
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { de_OriginateCommand, se_OriginateCommand, } from "../protocols/Aws_restJson1";
|
|
2
|
+
import { getSerdePlugin } from "@smithy/middleware-serde";
|
|
3
|
+
import { Command as $Command } from "@smithy/smithy-client";
|
|
4
|
+
export { $Command };
|
|
5
|
+
export class OriginateCommand extends $Command.classBuilder()
|
|
6
|
+
.m(function (Command, cs, config, o) {
|
|
7
|
+
return [
|
|
8
|
+
getSerdePlugin(config, this.serialize, this.deserialize),
|
|
9
|
+
];
|
|
10
|
+
})
|
|
11
|
+
.s("WmsApi", "Originate", {})
|
|
12
|
+
.n("WmsApiClient", "OriginateCommand")
|
|
13
|
+
.f(void 0, void 0)
|
|
14
|
+
.ser(se_OriginateCommand)
|
|
15
|
+
.de(de_OriginateCommand)
|
|
16
|
+
.build() {
|
|
17
|
+
}
|
|
@@ -5,4 +5,6 @@ export * from "./GetPbxCallGroupsCommand";
|
|
|
5
5
|
export * from "./GetPbxColleaguesCommand";
|
|
6
6
|
export * from "./GetPbxesCommand";
|
|
7
7
|
export * from "./GetPbxOAuth2ClientsCommand";
|
|
8
|
+
export * from "./OriginateCommand";
|
|
9
|
+
export * from "./OriginateCallCommand";
|
|
8
10
|
export * from "./UpdatePbxOAuth2ClientCommand";
|
|
@@ -118,6 +118,49 @@ export const se_GetPbxOAuth2ClientsCommand = async (input, context) => {
|
|
|
118
118
|
.b(body);
|
|
119
119
|
return b.build();
|
|
120
120
|
};
|
|
121
|
+
export const se_OriginateCommand = async (input, context) => {
|
|
122
|
+
const b = rb(input, context);
|
|
123
|
+
const headers = {
|
|
124
|
+
'content-type': 'application/json',
|
|
125
|
+
};
|
|
126
|
+
b.bp("/api/v1/originate");
|
|
127
|
+
let body;
|
|
128
|
+
body = JSON.stringify(take(input, {
|
|
129
|
+
'account': [],
|
|
130
|
+
'actionid': [],
|
|
131
|
+
'application': [],
|
|
132
|
+
'async': [],
|
|
133
|
+
'callerid': [],
|
|
134
|
+
'channel': [],
|
|
135
|
+
'context': [],
|
|
136
|
+
'data': [],
|
|
137
|
+
'exten': [],
|
|
138
|
+
'priority': [],
|
|
139
|
+
'timeout': [],
|
|
140
|
+
'variable': [],
|
|
141
|
+
}));
|
|
142
|
+
b.m("POST")
|
|
143
|
+
.h(headers)
|
|
144
|
+
.b(body);
|
|
145
|
+
return b.build();
|
|
146
|
+
};
|
|
147
|
+
export const se_OriginateCallCommand = async (input, context) => {
|
|
148
|
+
const b = rb(input, context);
|
|
149
|
+
const headers = {
|
|
150
|
+
'content-type': 'application/json',
|
|
151
|
+
};
|
|
152
|
+
b.bp("/api/v1/originate/call");
|
|
153
|
+
let body;
|
|
154
|
+
body = JSON.stringify(take(input, {
|
|
155
|
+
'name': [],
|
|
156
|
+
'number': [],
|
|
157
|
+
'postpone': [],
|
|
158
|
+
}));
|
|
159
|
+
b.m("POST")
|
|
160
|
+
.h(headers)
|
|
161
|
+
.b(body);
|
|
162
|
+
return b.build();
|
|
163
|
+
};
|
|
121
164
|
export const se_UpdatePbxOAuth2ClientCommand = async (input, context) => {
|
|
122
165
|
const b = rb(input, context);
|
|
123
166
|
const headers = {
|
|
@@ -240,6 +283,36 @@ export const de_GetPbxOAuth2ClientsCommand = async (output, context) => {
|
|
|
240
283
|
Object.assign(contents, doc);
|
|
241
284
|
return contents;
|
|
242
285
|
};
|
|
286
|
+
export const de_OriginateCommand = async (output, context) => {
|
|
287
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
288
|
+
return de_CommandError(output, context);
|
|
289
|
+
}
|
|
290
|
+
const contents = map({
|
|
291
|
+
$metadata: deserializeMetadata(output),
|
|
292
|
+
});
|
|
293
|
+
const data = __expectNonNull((__expectObject(await parseBody(output.body, context))), "body");
|
|
294
|
+
const doc = take(data, {
|
|
295
|
+
'result': __expectString,
|
|
296
|
+
'type': __expectString,
|
|
297
|
+
});
|
|
298
|
+
Object.assign(contents, doc);
|
|
299
|
+
return contents;
|
|
300
|
+
};
|
|
301
|
+
export const de_OriginateCallCommand = async (output, context) => {
|
|
302
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
303
|
+
return de_CommandError(output, context);
|
|
304
|
+
}
|
|
305
|
+
const contents = map({
|
|
306
|
+
$metadata: deserializeMetadata(output),
|
|
307
|
+
});
|
|
308
|
+
const data = __expectNonNull((__expectObject(await parseBody(output.body, context))), "body");
|
|
309
|
+
const doc = take(data, {
|
|
310
|
+
'result': __expectString,
|
|
311
|
+
'type': __expectString,
|
|
312
|
+
});
|
|
313
|
+
Object.assign(contents, doc);
|
|
314
|
+
return contents;
|
|
315
|
+
};
|
|
243
316
|
export const de_UpdatePbxOAuth2ClientCommand = async (output, context) => {
|
|
244
317
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
245
318
|
return de_CommandError(output, context);
|
package/dist-types/WmsApi.d.ts
CHANGED
|
@@ -6,6 +6,8 @@ import { GetPbxCallGroupsCommandInput, GetPbxCallGroupsCommandOutput } from "./c
|
|
|
6
6
|
import { GetPbxColleaguesCommandInput, GetPbxColleaguesCommandOutput } from "./commands/GetPbxColleaguesCommand";
|
|
7
7
|
import { GetPbxOAuth2ClientsCommandInput, GetPbxOAuth2ClientsCommandOutput } from "./commands/GetPbxOAuth2ClientsCommand";
|
|
8
8
|
import { GetPbxesCommandInput, GetPbxesCommandOutput } from "./commands/GetPbxesCommand";
|
|
9
|
+
import { OriginateCallCommandInput, OriginateCallCommandOutput } from "./commands/OriginateCallCommand";
|
|
10
|
+
import { OriginateCommandInput, OriginateCommandOutput } from "./commands/OriginateCommand";
|
|
9
11
|
import { UpdatePbxOAuth2ClientCommandInput, UpdatePbxOAuth2ClientCommandOutput } from "./commands/UpdatePbxOAuth2ClientCommand";
|
|
10
12
|
import { HttpHandlerOptions as __HttpHandlerOptions } from "@smithy/types";
|
|
11
13
|
export interface WmsApi {
|
|
@@ -56,6 +58,18 @@ export interface WmsApi {
|
|
|
56
58
|
getPbxOAuth2Clients(args: GetPbxOAuth2ClientsCommandInput, options?: __HttpHandlerOptions): Promise<GetPbxOAuth2ClientsCommandOutput>;
|
|
57
59
|
getPbxOAuth2Clients(args: GetPbxOAuth2ClientsCommandInput, cb: (err: any, data?: GetPbxOAuth2ClientsCommandOutput) => void): void;
|
|
58
60
|
getPbxOAuth2Clients(args: GetPbxOAuth2ClientsCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetPbxOAuth2ClientsCommandOutput) => void): void;
|
|
61
|
+
/**
|
|
62
|
+
* @see {@link OriginateCommand}
|
|
63
|
+
*/
|
|
64
|
+
originate(args: OriginateCommandInput, options?: __HttpHandlerOptions): Promise<OriginateCommandOutput>;
|
|
65
|
+
originate(args: OriginateCommandInput, cb: (err: any, data?: OriginateCommandOutput) => void): void;
|
|
66
|
+
originate(args: OriginateCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: OriginateCommandOutput) => void): void;
|
|
67
|
+
/**
|
|
68
|
+
* @see {@link OriginateCallCommand}
|
|
69
|
+
*/
|
|
70
|
+
originateCall(args: OriginateCallCommandInput, options?: __HttpHandlerOptions): Promise<OriginateCallCommandOutput>;
|
|
71
|
+
originateCall(args: OriginateCallCommandInput, cb: (err: any, data?: OriginateCallCommandOutput) => void): void;
|
|
72
|
+
originateCall(args: OriginateCallCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: OriginateCallCommandOutput) => void): void;
|
|
59
73
|
/**
|
|
60
74
|
* @see {@link UpdatePbxOAuth2ClientCommand}
|
|
61
75
|
*/
|
|
@@ -5,6 +5,8 @@ import { GetPbxCallGroupsCommandInput, GetPbxCallGroupsCommandOutput } from "./c
|
|
|
5
5
|
import { GetPbxColleaguesCommandInput, GetPbxColleaguesCommandOutput } from "./commands/GetPbxColleaguesCommand";
|
|
6
6
|
import { GetPbxOAuth2ClientsCommandInput, GetPbxOAuth2ClientsCommandOutput } from "./commands/GetPbxOAuth2ClientsCommand";
|
|
7
7
|
import { GetPbxesCommandInput, GetPbxesCommandOutput } from "./commands/GetPbxesCommand";
|
|
8
|
+
import { OriginateCallCommandInput, OriginateCallCommandOutput } from "./commands/OriginateCallCommand";
|
|
9
|
+
import { OriginateCommandInput, OriginateCommandOutput } from "./commands/OriginateCommand";
|
|
8
10
|
import { UpdatePbxOAuth2ClientCommandInput, UpdatePbxOAuth2ClientCommandOutput } from "./commands/UpdatePbxOAuth2ClientCommand";
|
|
9
11
|
import { RuntimeExtension, RuntimeExtensionsConfig } from "./runtimeExtensions";
|
|
10
12
|
import { UserAgentInputConfig, UserAgentResolvedConfig } from "@aws-sdk/middleware-user-agent";
|
|
@@ -17,11 +19,11 @@ export { __Client };
|
|
|
17
19
|
/**
|
|
18
20
|
* @public
|
|
19
21
|
*/
|
|
20
|
-
export type ServiceInputTypes = CreatePbxOAuth2ClientCommandInput | DeletePbxOAuth2ClientCommandInput | GetPbxAclGroupsPermissionsCommandInput | GetPbxCallGroupsCommandInput | GetPbxColleaguesCommandInput | GetPbxOAuth2ClientsCommandInput | GetPbxesCommandInput | UpdatePbxOAuth2ClientCommandInput;
|
|
22
|
+
export type ServiceInputTypes = CreatePbxOAuth2ClientCommandInput | DeletePbxOAuth2ClientCommandInput | GetPbxAclGroupsPermissionsCommandInput | GetPbxCallGroupsCommandInput | GetPbxColleaguesCommandInput | GetPbxOAuth2ClientsCommandInput | GetPbxesCommandInput | OriginateCallCommandInput | OriginateCommandInput | UpdatePbxOAuth2ClientCommandInput;
|
|
21
23
|
/**
|
|
22
24
|
* @public
|
|
23
25
|
*/
|
|
24
|
-
export type ServiceOutputTypes = CreatePbxOAuth2ClientCommandOutput | DeletePbxOAuth2ClientCommandOutput | GetPbxAclGroupsPermissionsCommandOutput | GetPbxCallGroupsCommandOutput | GetPbxColleaguesCommandOutput | GetPbxOAuth2ClientsCommandOutput | GetPbxesCommandOutput | UpdatePbxOAuth2ClientCommandOutput;
|
|
26
|
+
export type ServiceOutputTypes = CreatePbxOAuth2ClientCommandOutput | DeletePbxOAuth2ClientCommandOutput | GetPbxAclGroupsPermissionsCommandOutput | GetPbxCallGroupsCommandOutput | GetPbxColleaguesCommandOutput | GetPbxOAuth2ClientsCommandOutput | GetPbxesCommandOutput | OriginateCallCommandOutput | OriginateCommandOutput | UpdatePbxOAuth2ClientCommandOutput;
|
|
25
27
|
/**
|
|
26
28
|
* @public
|
|
27
29
|
*/
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { ServiceInputTypes, ServiceOutputTypes, WmsApiClientResolvedConfig } from "../WmsApiClient";
|
|
2
|
+
import { OriginateCallInput, OriginateCallOutput } from "../models/models_0";
|
|
3
|
+
import { Command as $Command } from "@smithy/smithy-client";
|
|
4
|
+
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
5
|
+
/**
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export type { __MetadataBearer };
|
|
9
|
+
export { $Command };
|
|
10
|
+
/**
|
|
11
|
+
* @public
|
|
12
|
+
*
|
|
13
|
+
* The input for {@link OriginateCallCommand}.
|
|
14
|
+
*/
|
|
15
|
+
export interface OriginateCallCommandInput extends OriginateCallInput {
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* @public
|
|
19
|
+
*
|
|
20
|
+
* The output of {@link OriginateCallCommand}.
|
|
21
|
+
*/
|
|
22
|
+
export interface OriginateCallCommandOutput extends OriginateCallOutput, __MetadataBearer {
|
|
23
|
+
}
|
|
24
|
+
declare const OriginateCallCommand_base: {
|
|
25
|
+
new (input: OriginateCallCommandInput): import("@smithy/smithy-client").CommandImpl<OriginateCallCommandInput, OriginateCallCommandOutput, WmsApiClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
26
|
+
new (__0_0: OriginateCallCommandInput): import("@smithy/smithy-client").CommandImpl<OriginateCallCommandInput, OriginateCallCommandOutput, WmsApiClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
27
|
+
getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* Originate call
|
|
31
|
+
* @example
|
|
32
|
+
* Use a bare-bones client and the command you need to make an API call.
|
|
33
|
+
* ```javascript
|
|
34
|
+
* import { WmsApiClient, OriginateCallCommand } from "@wildix/wms-api-client"; // ES Modules import
|
|
35
|
+
* // const { WmsApiClient, OriginateCallCommand } = require("@wildix/wms-api-client"); // CommonJS import
|
|
36
|
+
* const client = new WmsApiClient(config);
|
|
37
|
+
* const input = { // OriginateCallInput
|
|
38
|
+
* number: "STRING_VALUE", // required
|
|
39
|
+
* name: "STRING_VALUE",
|
|
40
|
+
* postpone: "STRING_VALUE",
|
|
41
|
+
* };
|
|
42
|
+
* const command = new OriginateCallCommand(input);
|
|
43
|
+
* const response = await client.send(command);
|
|
44
|
+
* // { // OriginateCallOutput
|
|
45
|
+
* // type: "result" || "error", // required
|
|
46
|
+
* // result: "Success", // required
|
|
47
|
+
* // };
|
|
48
|
+
*
|
|
49
|
+
* ```
|
|
50
|
+
*
|
|
51
|
+
* @param OriginateCallCommandInput - {@link OriginateCallCommandInput}
|
|
52
|
+
* @returns {@link OriginateCallCommandOutput}
|
|
53
|
+
* @see {@link OriginateCallCommandInput} for command's `input` shape.
|
|
54
|
+
* @see {@link OriginateCallCommandOutput} for command's `response` shape.
|
|
55
|
+
* @see {@link WmsApiClientResolvedConfig | config} for WmsApiClient's `config` shape.
|
|
56
|
+
*
|
|
57
|
+
* @throws {@link WmsUnauthorizedException} (client fault)
|
|
58
|
+
*
|
|
59
|
+
* @throws {@link WmsApiServiceException}
|
|
60
|
+
* <p>Base exception class for all service exceptions from WmsApi service.</p>
|
|
61
|
+
*
|
|
62
|
+
* @public
|
|
63
|
+
*/
|
|
64
|
+
export declare class OriginateCallCommand extends OriginateCallCommand_base {
|
|
65
|
+
}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import { ServiceInputTypes, ServiceOutputTypes, WmsApiClientResolvedConfig } from "../WmsApiClient";
|
|
2
|
+
import { OriginateInput, OriginateOutput } from "../models/models_0";
|
|
3
|
+
import { Command as $Command } from "@smithy/smithy-client";
|
|
4
|
+
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
5
|
+
/**
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export type { __MetadataBearer };
|
|
9
|
+
export { $Command };
|
|
10
|
+
/**
|
|
11
|
+
* @public
|
|
12
|
+
*
|
|
13
|
+
* The input for {@link OriginateCommand}.
|
|
14
|
+
*/
|
|
15
|
+
export interface OriginateCommandInput extends OriginateInput {
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* @public
|
|
19
|
+
*
|
|
20
|
+
* The output of {@link OriginateCommand}.
|
|
21
|
+
*/
|
|
22
|
+
export interface OriginateCommandOutput extends OriginateOutput, __MetadataBearer {
|
|
23
|
+
}
|
|
24
|
+
declare const OriginateCommand_base: {
|
|
25
|
+
new (input: OriginateCommandInput): import("@smithy/smithy-client").CommandImpl<OriginateCommandInput, OriginateCommandOutput, WmsApiClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
26
|
+
new (__0_0: OriginateCommandInput): import("@smithy/smithy-client").CommandImpl<OriginateCommandInput, OriginateCommandOutput, WmsApiClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
27
|
+
getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* Originate
|
|
31
|
+
* @example
|
|
32
|
+
* Use a bare-bones client and the command you need to make an API call.
|
|
33
|
+
* ```javascript
|
|
34
|
+
* import { WmsApiClient, OriginateCommand } from "@wildix/wms-api-client"; // ES Modules import
|
|
35
|
+
* // const { WmsApiClient, OriginateCommand } = require("@wildix/wms-api-client"); // CommonJS import
|
|
36
|
+
* const client = new WmsApiClient(config);
|
|
37
|
+
* const input = { // OriginateInput
|
|
38
|
+
* channel: "STRING_VALUE", // required
|
|
39
|
+
* exten: "STRING_VALUE",
|
|
40
|
+
* context: "STRING_VALUE",
|
|
41
|
+
* priority: "STRING_VALUE",
|
|
42
|
+
* application: "STRING_VALUE",
|
|
43
|
+
* data: "STRING_VALUE",
|
|
44
|
+
* timeout: "STRING_VALUE",
|
|
45
|
+
* callerid: "STRING_VALUE",
|
|
46
|
+
* variable: "STRING_VALUE",
|
|
47
|
+
* account: "STRING_VALUE",
|
|
48
|
+
* async: "STRING_VALUE",
|
|
49
|
+
* actionid: "STRING_VALUE",
|
|
50
|
+
* };
|
|
51
|
+
* const command = new OriginateCommand(input);
|
|
52
|
+
* const response = await client.send(command);
|
|
53
|
+
* // { // OriginateOutput
|
|
54
|
+
* // type: "result" || "error", // required
|
|
55
|
+
* // result: "Success", // required
|
|
56
|
+
* // };
|
|
57
|
+
*
|
|
58
|
+
* ```
|
|
59
|
+
*
|
|
60
|
+
* @param OriginateCommandInput - {@link OriginateCommandInput}
|
|
61
|
+
* @returns {@link OriginateCommandOutput}
|
|
62
|
+
* @see {@link OriginateCommandInput} for command's `input` shape.
|
|
63
|
+
* @see {@link OriginateCommandOutput} for command's `response` shape.
|
|
64
|
+
* @see {@link WmsApiClientResolvedConfig | config} for WmsApiClient's `config` shape.
|
|
65
|
+
*
|
|
66
|
+
* @throws {@link WmsUnauthorizedException} (client fault)
|
|
67
|
+
*
|
|
68
|
+
* @throws {@link WmsApiServiceException}
|
|
69
|
+
* <p>Base exception class for all service exceptions from WmsApi service.</p>
|
|
70
|
+
*
|
|
71
|
+
* @public
|
|
72
|
+
*/
|
|
73
|
+
export declare class OriginateCommand extends OriginateCommand_base {
|
|
74
|
+
}
|
|
@@ -5,4 +5,6 @@ export * from "./GetPbxCallGroupsCommand";
|
|
|
5
5
|
export * from "./GetPbxColleaguesCommand";
|
|
6
6
|
export * from "./GetPbxesCommand";
|
|
7
7
|
export * from "./GetPbxOAuth2ClientsCommand";
|
|
8
|
+
export * from "./OriginateCommand";
|
|
9
|
+
export * from "./OriginateCallCommand";
|
|
8
10
|
export * from "./UpdatePbxOAuth2ClientCommand";
|
|
@@ -434,6 +434,68 @@ export interface GetPbxOAuth2ClientsOutput {
|
|
|
434
434
|
type: ResponseType;
|
|
435
435
|
result: GetPbxOAuth2ClientsResult;
|
|
436
436
|
}
|
|
437
|
+
/**
|
|
438
|
+
* @public
|
|
439
|
+
*/
|
|
440
|
+
export interface OriginateInput {
|
|
441
|
+
channel: string;
|
|
442
|
+
exten?: string;
|
|
443
|
+
context?: string;
|
|
444
|
+
priority?: string;
|
|
445
|
+
application?: string;
|
|
446
|
+
data?: string;
|
|
447
|
+
timeout?: string;
|
|
448
|
+
callerid?: string;
|
|
449
|
+
variable?: string;
|
|
450
|
+
account?: string;
|
|
451
|
+
async?: string;
|
|
452
|
+
actionid?: string;
|
|
453
|
+
}
|
|
454
|
+
/**
|
|
455
|
+
* @public
|
|
456
|
+
* @enum
|
|
457
|
+
*/
|
|
458
|
+
export declare const ResponseResult: {
|
|
459
|
+
readonly SUCCESS: "Success";
|
|
460
|
+
};
|
|
461
|
+
/**
|
|
462
|
+
* @public
|
|
463
|
+
*/
|
|
464
|
+
export type ResponseResult = typeof ResponseResult[keyof typeof ResponseResult];
|
|
465
|
+
/**
|
|
466
|
+
* @public
|
|
467
|
+
*/
|
|
468
|
+
export interface OriginateOutput {
|
|
469
|
+
type: ResponseType;
|
|
470
|
+
result: ResponseResult;
|
|
471
|
+
}
|
|
472
|
+
/**
|
|
473
|
+
* @public
|
|
474
|
+
*/
|
|
475
|
+
export interface OriginateCallInput {
|
|
476
|
+
/**
|
|
477
|
+
* The phone number.
|
|
478
|
+
* @public
|
|
479
|
+
*/
|
|
480
|
+
number: string;
|
|
481
|
+
/**
|
|
482
|
+
* The name
|
|
483
|
+
* @public
|
|
484
|
+
*/
|
|
485
|
+
name?: string;
|
|
486
|
+
/**
|
|
487
|
+
* Date of sending the delayed message. (14/07/2015 15:35)
|
|
488
|
+
* @public
|
|
489
|
+
*/
|
|
490
|
+
postpone?: string;
|
|
491
|
+
}
|
|
492
|
+
/**
|
|
493
|
+
* @public
|
|
494
|
+
*/
|
|
495
|
+
export interface OriginateCallOutput {
|
|
496
|
+
type: ResponseType;
|
|
497
|
+
result: ResponseResult;
|
|
498
|
+
}
|
|
437
499
|
/**
|
|
438
500
|
* @public
|
|
439
501
|
*/
|
|
@@ -5,6 +5,8 @@ import { GetPbxCallGroupsCommandInput, GetPbxCallGroupsCommandOutput } from "../
|
|
|
5
5
|
import { GetPbxColleaguesCommandInput, GetPbxColleaguesCommandOutput } from "../commands/GetPbxColleaguesCommand";
|
|
6
6
|
import { GetPbxOAuth2ClientsCommandInput, GetPbxOAuth2ClientsCommandOutput } from "../commands/GetPbxOAuth2ClientsCommand";
|
|
7
7
|
import { GetPbxesCommandInput, GetPbxesCommandOutput } from "../commands/GetPbxesCommand";
|
|
8
|
+
import { OriginateCallCommandInput, OriginateCallCommandOutput } from "../commands/OriginateCallCommand";
|
|
9
|
+
import { OriginateCommandInput, OriginateCommandOutput } from "../commands/OriginateCommand";
|
|
8
10
|
import { UpdatePbxOAuth2ClientCommandInput, UpdatePbxOAuth2ClientCommandOutput } from "../commands/UpdatePbxOAuth2ClientCommand";
|
|
9
11
|
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@smithy/protocol-http";
|
|
10
12
|
import { SerdeContext as __SerdeContext } from "@smithy/types";
|
|
@@ -36,6 +38,14 @@ export declare const se_GetPbxesCommand: (input: GetPbxesCommandInput, context:
|
|
|
36
38
|
* serializeAws_restJson1GetPbxOAuth2ClientsCommand
|
|
37
39
|
*/
|
|
38
40
|
export declare const se_GetPbxOAuth2ClientsCommand: (input: GetPbxOAuth2ClientsCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
41
|
+
/**
|
|
42
|
+
* serializeAws_restJson1OriginateCommand
|
|
43
|
+
*/
|
|
44
|
+
export declare const se_OriginateCommand: (input: OriginateCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
45
|
+
/**
|
|
46
|
+
* serializeAws_restJson1OriginateCallCommand
|
|
47
|
+
*/
|
|
48
|
+
export declare const se_OriginateCallCommand: (input: OriginateCallCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
39
49
|
/**
|
|
40
50
|
* serializeAws_restJson1UpdatePbxOAuth2ClientCommand
|
|
41
51
|
*/
|
|
@@ -68,6 +78,14 @@ export declare const de_GetPbxesCommand: (output: __HttpResponse, context: __Ser
|
|
|
68
78
|
* deserializeAws_restJson1GetPbxOAuth2ClientsCommand
|
|
69
79
|
*/
|
|
70
80
|
export declare const de_GetPbxOAuth2ClientsCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<GetPbxOAuth2ClientsCommandOutput>;
|
|
81
|
+
/**
|
|
82
|
+
* deserializeAws_restJson1OriginateCommand
|
|
83
|
+
*/
|
|
84
|
+
export declare const de_OriginateCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<OriginateCommandOutput>;
|
|
85
|
+
/**
|
|
86
|
+
* deserializeAws_restJson1OriginateCallCommand
|
|
87
|
+
*/
|
|
88
|
+
export declare const de_OriginateCallCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<OriginateCallCommandOutput>;
|
|
71
89
|
/**
|
|
72
90
|
* deserializeAws_restJson1UpdatePbxOAuth2ClientCommand
|
|
73
91
|
*/
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wildix/wms-api-client",
|
|
3
3
|
"description": "@wildix/wms-api-client client",
|
|
4
|
-
"version": "1.1.
|
|
4
|
+
"version": "1.1.9",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
|
|
7
7
|
"build:cjs": "tsc -p tsconfig.cjs.json",
|