@wildix/wms-api-client 1.1.1 → 1.1.3

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 (39) hide show
  1. package/dist-cjs/WmsApiClient.js +6 -3
  2. package/dist-cjs/commands/CreatePbxOAuth2ClientCommand.js +12 -32
  3. package/dist-cjs/commands/DeletePbxOAuth2ClientCommand.js +12 -32
  4. package/dist-cjs/commands/GetPbxAclGroupsPermissionsCommand.js +12 -32
  5. package/dist-cjs/commands/GetPbxCallGroupsCommand.js +12 -32
  6. package/dist-cjs/commands/GetPbxColleaguesCommand.js +12 -32
  7. package/dist-cjs/commands/GetPbxOAuth2ClientsCommand.js +12 -32
  8. package/dist-cjs/commands/UpdatePbxOAuth2ClientCommand.js +12 -32
  9. package/dist-cjs/protocols/Aws_restJson1.js +122 -237
  10. package/dist-cjs/runtimeConfig.browser.js +5 -1
  11. package/dist-cjs/runtimeConfig.js +5 -1
  12. package/dist-cjs/runtimeConfig.shared.js +13 -11
  13. package/dist-es/WmsApiClient.js +6 -3
  14. package/dist-es/commands/CreatePbxOAuth2ClientCommand.js +12 -32
  15. package/dist-es/commands/DeletePbxOAuth2ClientCommand.js +12 -32
  16. package/dist-es/commands/GetPbxAclGroupsPermissionsCommand.js +12 -32
  17. package/dist-es/commands/GetPbxCallGroupsCommand.js +12 -32
  18. package/dist-es/commands/GetPbxColleaguesCommand.js +12 -32
  19. package/dist-es/commands/GetPbxOAuth2ClientsCommand.js +12 -32
  20. package/dist-es/commands/UpdatePbxOAuth2ClientCommand.js +12 -32
  21. package/dist-es/protocols/Aws_restJson1.js +123 -238
  22. package/dist-es/runtimeConfig.browser.js +4 -1
  23. package/dist-es/runtimeConfig.js +4 -1
  24. package/dist-es/runtimeConfig.shared.js +13 -11
  25. package/dist-types/WmsApi.d.ts +4 -0
  26. package/dist-types/WmsApiClient.d.ts +13 -7
  27. package/dist-types/commands/CreatePbxOAuth2ClientCommand.d.ts +8 -20
  28. package/dist-types/commands/DeletePbxOAuth2ClientCommand.d.ts +8 -20
  29. package/dist-types/commands/GetPbxAclGroupsPermissionsCommand.d.ts +7 -19
  30. package/dist-types/commands/GetPbxCallGroupsCommand.d.ts +8 -20
  31. package/dist-types/commands/GetPbxColleaguesCommand.d.ts +7 -19
  32. package/dist-types/commands/GetPbxOAuth2ClientsCommand.d.ts +8 -20
  33. package/dist-types/commands/UpdatePbxOAuth2ClientCommand.d.ts +8 -20
  34. package/dist-types/index.d.ts +2 -0
  35. package/dist-types/models/models_0.d.ts +27 -27
  36. package/dist-types/runtimeConfig.browser.d.ts +3 -4
  37. package/dist-types/runtimeConfig.d.ts +3 -4
  38. package/dist-types/runtimeConfig.native.d.ts +3 -4
  39. package/package.json +30 -28
@@ -3,15 +3,17 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.WmsApiClient = exports.__Client = void 0;
4
4
  const runtimeConfig_1 = require("./runtimeConfig");
5
5
  const runtimeExtensions_1 = require("./runtimeExtensions");
6
+ const middleware_user_agent_1 = require("@aws-sdk/middleware-user-agent");
6
7
  const smithy_client_1 = require("@smithy/smithy-client");
7
8
  Object.defineProperty(exports, "__Client", { enumerable: true, get: function () { return smithy_client_1.Client; } });
8
9
  const smithy_utils_1 = require("@wildix/smithy-utils");
9
10
  class WmsApiClient extends smithy_client_1.Client {
10
11
  constructor(...[configuration]) {
11
12
  let _config_0 = (0, runtimeConfig_1.getRuntimeConfig)(configuration || {});
12
- let _config_1 = (0, runtimeExtensions_1.resolveRuntimeExtensions)(_config_0, configuration?.extensions || []);
13
+ let _config_1 = (0, middleware_user_agent_1.resolveUserAgentConfig)(_config_0);
14
+ let _config_2 = (0, runtimeExtensions_1.resolveRuntimeExtensions)(_config_1, configuration?.extensions || []);
15
+ const hostname = configuration.domain.endsWith("wildixin.com") ? configuration.domain : `${configuration.domain}.wildixin.com`;
13
16
  const endpoint = () => {
14
- const hostname = configuration.domain.endsWith("wildixin.com") ? configuration.domain : `${configuration.domain}.wildixin.com`;
15
17
  return {
16
18
  hostname,
17
19
  protocol: "https",
@@ -20,12 +22,13 @@ class WmsApiClient extends smithy_client_1.Client {
20
22
  };
21
23
  };
22
24
  const config = {
23
- ..._config_1,
25
+ ..._config_2,
24
26
  endpoint,
25
27
  };
26
28
  super(config);
27
29
  this.config = config;
28
30
  this.middlewareStack.add(smithy_utils_1.authorizationMiddleware.bind(this, configuration.token), { step: "build" });
31
+ this.middlewareStack.use((0, middleware_user_agent_1.getUserAgentPlugin)(this.config));
29
32
  }
30
33
  destroy() {
31
34
  super.destroy();
@@ -5,37 +5,17 @@ const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
5
5
  const middleware_serde_1 = require("@smithy/middleware-serde");
6
6
  const smithy_client_1 = require("@smithy/smithy-client");
7
7
  Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
- const types_1 = require("@smithy/types");
9
- class CreatePbxOAuth2ClientCommand extends smithy_client_1.Command {
10
- constructor(input) {
11
- super();
12
- this.input = input;
13
- }
14
- resolveMiddleware(clientStack, configuration, options) {
15
- this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
16
- const stack = clientStack.concat(this.middlewareStack);
17
- const { logger } = configuration;
18
- const clientName = "WmsApiClient";
19
- const commandName = "CreatePbxOAuth2ClientCommand";
20
- const handlerExecutionContext = {
21
- logger,
22
- clientName,
23
- commandName,
24
- inputFilterSensitiveLog: (_) => _,
25
- outputFilterSensitiveLog: (_) => _,
26
- [types_1.SMITHY_CONTEXT_KEY]: {
27
- service: "WmsApi",
28
- operation: "CreatePbxOAuth2Client",
29
- },
30
- };
31
- const { requestHandler } = configuration;
32
- return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
33
- }
34
- serialize(input, context) {
35
- return (0, Aws_restJson1_1.se_CreatePbxOAuth2ClientCommand)(input, context);
36
- }
37
- deserialize(output, context) {
38
- return (0, Aws_restJson1_1.de_CreatePbxOAuth2ClientCommand)(output, context);
39
- }
8
+ class CreatePbxOAuth2ClientCommand 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", "CreatePbxOAuth2Client", {})
15
+ .n("WmsApiClient", "CreatePbxOAuth2ClientCommand")
16
+ .f(void 0, void 0)
17
+ .ser(Aws_restJson1_1.se_CreatePbxOAuth2ClientCommand)
18
+ .de(Aws_restJson1_1.de_CreatePbxOAuth2ClientCommand)
19
+ .build() {
40
20
  }
41
21
  exports.CreatePbxOAuth2ClientCommand = CreatePbxOAuth2ClientCommand;
@@ -5,37 +5,17 @@ const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
5
5
  const middleware_serde_1 = require("@smithy/middleware-serde");
6
6
  const smithy_client_1 = require("@smithy/smithy-client");
7
7
  Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
- const types_1 = require("@smithy/types");
9
- class DeletePbxOAuth2ClientCommand extends smithy_client_1.Command {
10
- constructor(input) {
11
- super();
12
- this.input = input;
13
- }
14
- resolveMiddleware(clientStack, configuration, options) {
15
- this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
16
- const stack = clientStack.concat(this.middlewareStack);
17
- const { logger } = configuration;
18
- const clientName = "WmsApiClient";
19
- const commandName = "DeletePbxOAuth2ClientCommand";
20
- const handlerExecutionContext = {
21
- logger,
22
- clientName,
23
- commandName,
24
- inputFilterSensitiveLog: (_) => _,
25
- outputFilterSensitiveLog: (_) => _,
26
- [types_1.SMITHY_CONTEXT_KEY]: {
27
- service: "WmsApi",
28
- operation: "DeletePbxOAuth2Client",
29
- },
30
- };
31
- const { requestHandler } = configuration;
32
- return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
33
- }
34
- serialize(input, context) {
35
- return (0, Aws_restJson1_1.se_DeletePbxOAuth2ClientCommand)(input, context);
36
- }
37
- deserialize(output, context) {
38
- return (0, Aws_restJson1_1.de_DeletePbxOAuth2ClientCommand)(output, context);
39
- }
8
+ class DeletePbxOAuth2ClientCommand 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", "DeletePbxOAuth2Client", {})
15
+ .n("WmsApiClient", "DeletePbxOAuth2ClientCommand")
16
+ .f(void 0, void 0)
17
+ .ser(Aws_restJson1_1.se_DeletePbxOAuth2ClientCommand)
18
+ .de(Aws_restJson1_1.de_DeletePbxOAuth2ClientCommand)
19
+ .build() {
40
20
  }
41
21
  exports.DeletePbxOAuth2ClientCommand = DeletePbxOAuth2ClientCommand;
@@ -5,37 +5,17 @@ const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
5
5
  const middleware_serde_1 = require("@smithy/middleware-serde");
6
6
  const smithy_client_1 = require("@smithy/smithy-client");
7
7
  Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
- const types_1 = require("@smithy/types");
9
- class GetPbxAclGroupsPermissionsCommand extends smithy_client_1.Command {
10
- constructor(input) {
11
- super();
12
- this.input = input;
13
- }
14
- resolveMiddleware(clientStack, configuration, options) {
15
- this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
16
- const stack = clientStack.concat(this.middlewareStack);
17
- const { logger } = configuration;
18
- const clientName = "WmsApiClient";
19
- const commandName = "GetPbxAclGroupsPermissionsCommand";
20
- const handlerExecutionContext = {
21
- logger,
22
- clientName,
23
- commandName,
24
- inputFilterSensitiveLog: (_) => _,
25
- outputFilterSensitiveLog: (_) => _,
26
- [types_1.SMITHY_CONTEXT_KEY]: {
27
- service: "WmsApi",
28
- operation: "GetPbxAclGroupsPermissions",
29
- },
30
- };
31
- const { requestHandler } = configuration;
32
- return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
33
- }
34
- serialize(input, context) {
35
- return (0, Aws_restJson1_1.se_GetPbxAclGroupsPermissionsCommand)(input, context);
36
- }
37
- deserialize(output, context) {
38
- return (0, Aws_restJson1_1.de_GetPbxAclGroupsPermissionsCommand)(output, context);
39
- }
8
+ class GetPbxAclGroupsPermissionsCommand 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", "GetPbxAclGroupsPermissions", {})
15
+ .n("WmsApiClient", "GetPbxAclGroupsPermissionsCommand")
16
+ .f(void 0, void 0)
17
+ .ser(Aws_restJson1_1.se_GetPbxAclGroupsPermissionsCommand)
18
+ .de(Aws_restJson1_1.de_GetPbxAclGroupsPermissionsCommand)
19
+ .build() {
40
20
  }
41
21
  exports.GetPbxAclGroupsPermissionsCommand = GetPbxAclGroupsPermissionsCommand;
@@ -5,37 +5,17 @@ const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
5
5
  const middleware_serde_1 = require("@smithy/middleware-serde");
6
6
  const smithy_client_1 = require("@smithy/smithy-client");
7
7
  Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
- const types_1 = require("@smithy/types");
9
- class GetPbxCallGroupsCommand extends smithy_client_1.Command {
10
- constructor(input) {
11
- super();
12
- this.input = input;
13
- }
14
- resolveMiddleware(clientStack, configuration, options) {
15
- this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
16
- const stack = clientStack.concat(this.middlewareStack);
17
- const { logger } = configuration;
18
- const clientName = "WmsApiClient";
19
- const commandName = "GetPbxCallGroupsCommand";
20
- const handlerExecutionContext = {
21
- logger,
22
- clientName,
23
- commandName,
24
- inputFilterSensitiveLog: (_) => _,
25
- outputFilterSensitiveLog: (_) => _,
26
- [types_1.SMITHY_CONTEXT_KEY]: {
27
- service: "WmsApi",
28
- operation: "GetPbxCallGroups",
29
- },
30
- };
31
- const { requestHandler } = configuration;
32
- return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
33
- }
34
- serialize(input, context) {
35
- return (0, Aws_restJson1_1.se_GetPbxCallGroupsCommand)(input, context);
36
- }
37
- deserialize(output, context) {
38
- return (0, Aws_restJson1_1.de_GetPbxCallGroupsCommand)(output, context);
39
- }
8
+ class GetPbxCallGroupsCommand 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", "GetPbxCallGroups", {})
15
+ .n("WmsApiClient", "GetPbxCallGroupsCommand")
16
+ .f(void 0, void 0)
17
+ .ser(Aws_restJson1_1.se_GetPbxCallGroupsCommand)
18
+ .de(Aws_restJson1_1.de_GetPbxCallGroupsCommand)
19
+ .build() {
40
20
  }
41
21
  exports.GetPbxCallGroupsCommand = GetPbxCallGroupsCommand;
@@ -5,37 +5,17 @@ const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
5
5
  const middleware_serde_1 = require("@smithy/middleware-serde");
6
6
  const smithy_client_1 = require("@smithy/smithy-client");
7
7
  Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
- const types_1 = require("@smithy/types");
9
- class GetPbxColleaguesCommand extends smithy_client_1.Command {
10
- constructor(input) {
11
- super();
12
- this.input = input;
13
- }
14
- resolveMiddleware(clientStack, configuration, options) {
15
- this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
16
- const stack = clientStack.concat(this.middlewareStack);
17
- const { logger } = configuration;
18
- const clientName = "WmsApiClient";
19
- const commandName = "GetPbxColleaguesCommand";
20
- const handlerExecutionContext = {
21
- logger,
22
- clientName,
23
- commandName,
24
- inputFilterSensitiveLog: (_) => _,
25
- outputFilterSensitiveLog: (_) => _,
26
- [types_1.SMITHY_CONTEXT_KEY]: {
27
- service: "WmsApi",
28
- operation: "GetPbxColleagues",
29
- },
30
- };
31
- const { requestHandler } = configuration;
32
- return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
33
- }
34
- serialize(input, context) {
35
- return (0, Aws_restJson1_1.se_GetPbxColleaguesCommand)(input, context);
36
- }
37
- deserialize(output, context) {
38
- return (0, Aws_restJson1_1.de_GetPbxColleaguesCommand)(output, context);
39
- }
8
+ class GetPbxColleaguesCommand 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", "GetPbxColleagues", {})
15
+ .n("WmsApiClient", "GetPbxColleaguesCommand")
16
+ .f(void 0, void 0)
17
+ .ser(Aws_restJson1_1.se_GetPbxColleaguesCommand)
18
+ .de(Aws_restJson1_1.de_GetPbxColleaguesCommand)
19
+ .build() {
40
20
  }
41
21
  exports.GetPbxColleaguesCommand = GetPbxColleaguesCommand;
@@ -5,37 +5,17 @@ const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
5
5
  const middleware_serde_1 = require("@smithy/middleware-serde");
6
6
  const smithy_client_1 = require("@smithy/smithy-client");
7
7
  Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
- const types_1 = require("@smithy/types");
9
- class GetPbxOAuth2ClientsCommand extends smithy_client_1.Command {
10
- constructor(input) {
11
- super();
12
- this.input = input;
13
- }
14
- resolveMiddleware(clientStack, configuration, options) {
15
- this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
16
- const stack = clientStack.concat(this.middlewareStack);
17
- const { logger } = configuration;
18
- const clientName = "WmsApiClient";
19
- const commandName = "GetPbxOAuth2ClientsCommand";
20
- const handlerExecutionContext = {
21
- logger,
22
- clientName,
23
- commandName,
24
- inputFilterSensitiveLog: (_) => _,
25
- outputFilterSensitiveLog: (_) => _,
26
- [types_1.SMITHY_CONTEXT_KEY]: {
27
- service: "WmsApi",
28
- operation: "GetPbxOAuth2Clients",
29
- },
30
- };
31
- const { requestHandler } = configuration;
32
- return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
33
- }
34
- serialize(input, context) {
35
- return (0, Aws_restJson1_1.se_GetPbxOAuth2ClientsCommand)(input, context);
36
- }
37
- deserialize(output, context) {
38
- return (0, Aws_restJson1_1.de_GetPbxOAuth2ClientsCommand)(output, context);
39
- }
8
+ class GetPbxOAuth2ClientsCommand 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", "GetPbxOAuth2Clients", {})
15
+ .n("WmsApiClient", "GetPbxOAuth2ClientsCommand")
16
+ .f(void 0, void 0)
17
+ .ser(Aws_restJson1_1.se_GetPbxOAuth2ClientsCommand)
18
+ .de(Aws_restJson1_1.de_GetPbxOAuth2ClientsCommand)
19
+ .build() {
40
20
  }
41
21
  exports.GetPbxOAuth2ClientsCommand = GetPbxOAuth2ClientsCommand;
@@ -5,37 +5,17 @@ const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
5
5
  const middleware_serde_1 = require("@smithy/middleware-serde");
6
6
  const smithy_client_1 = require("@smithy/smithy-client");
7
7
  Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
- const types_1 = require("@smithy/types");
9
- class UpdatePbxOAuth2ClientCommand extends smithy_client_1.Command {
10
- constructor(input) {
11
- super();
12
- this.input = input;
13
- }
14
- resolveMiddleware(clientStack, configuration, options) {
15
- this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
16
- const stack = clientStack.concat(this.middlewareStack);
17
- const { logger } = configuration;
18
- const clientName = "WmsApiClient";
19
- const commandName = "UpdatePbxOAuth2ClientCommand";
20
- const handlerExecutionContext = {
21
- logger,
22
- clientName,
23
- commandName,
24
- inputFilterSensitiveLog: (_) => _,
25
- outputFilterSensitiveLog: (_) => _,
26
- [types_1.SMITHY_CONTEXT_KEY]: {
27
- service: "WmsApi",
28
- operation: "UpdatePbxOAuth2Client",
29
- },
30
- };
31
- const { requestHandler } = configuration;
32
- return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
33
- }
34
- serialize(input, context) {
35
- return (0, Aws_restJson1_1.se_UpdatePbxOAuth2ClientCommand)(input, context);
36
- }
37
- deserialize(output, context) {
38
- return (0, Aws_restJson1_1.de_UpdatePbxOAuth2ClientCommand)(output, context);
39
- }
8
+ class UpdatePbxOAuth2ClientCommand 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", "UpdatePbxOAuth2Client", {})
15
+ .n("WmsApiClient", "UpdatePbxOAuth2ClientCommand")
16
+ .f(void 0, void 0)
17
+ .ser(Aws_restJson1_1.se_UpdatePbxOAuth2ClientCommand)
18
+ .de(Aws_restJson1_1.de_UpdatePbxOAuth2ClientCommand)
19
+ .build() {
40
20
  }
41
21
  exports.UpdatePbxOAuth2ClientCommand = UpdatePbxOAuth2ClientCommand;