|
17 | 17 | (function(root, factory) {
|
18 | 18 | if (typeof define === 'function' && define.amd) {
|
19 | 19 | // AMD. Register as an anonymous module.
|
20 |
| - define(['ApiClient', 'model/AddChildDomain', 'model/AddCredits', 'model/CreateChild', 'model/CreateReseller', 'model/ErrorModel', 'model/GetChildDomains', 'model/GetChildInfo', 'model/GetChildrenList', 'model/GetSsoToken', 'model/ManageIp', 'model/RemainingCreditModel', 'model/RemoveCredits', 'model/UpdateChild', 'model/UpdateChildDomain'], factory); |
| 20 | + define(['ApiClient', 'model/AddChildDomain', 'model/AddCredits', 'model/CreateChild', 'model/CreateReseller', 'model/ErrorModel', 'model/GetChildDomains', 'model/GetChildInfo', 'model/GetChildrenList', 'model/GetSsoToken', 'model/ManageIp', 'model/RemainingCreditModel', 'model/RemoveCredits', 'model/UpdateChild', 'model/UpdateChildAccountStatus', 'model/UpdateChildDomain'], factory); |
21 | 21 | } else if (typeof module === 'object' && module.exports) {
|
22 | 22 | // CommonJS-like environments that support module.exports, like Node.
|
23 |
| - module.exports = factory(require('../ApiClient'), require('../model/AddChildDomain'), require('../model/AddCredits'), require('../model/CreateChild'), require('../model/CreateReseller'), require('../model/ErrorModel'), require('../model/GetChildDomains'), require('../model/GetChildInfo'), require('../model/GetChildrenList'), require('../model/GetSsoToken'), require('../model/ManageIp'), require('../model/RemainingCreditModel'), require('../model/RemoveCredits'), require('../model/UpdateChild'), require('../model/UpdateChildDomain')); |
| 23 | + module.exports = factory(require('../ApiClient'), require('../model/AddChildDomain'), require('../model/AddCredits'), require('../model/CreateChild'), require('../model/CreateReseller'), require('../model/ErrorModel'), require('../model/GetChildDomains'), require('../model/GetChildInfo'), require('../model/GetChildrenList'), require('../model/GetSsoToken'), require('../model/ManageIp'), require('../model/RemainingCreditModel'), require('../model/RemoveCredits'), require('../model/UpdateChild'), require('../model/UpdateChildAccountStatus'), require('../model/UpdateChildDomain')); |
24 | 24 | } else {
|
25 | 25 | // Browser globals (root is window)
|
26 | 26 | if (!root.SibApiV3Sdk) {
|
27 | 27 | root.SibApiV3Sdk = {};
|
28 | 28 | }
|
29 |
| - root.SibApiV3Sdk.ResellerApi = factory(root.SibApiV3Sdk.ApiClient, root.SibApiV3Sdk.AddChildDomain, root.SibApiV3Sdk.AddCredits, root.SibApiV3Sdk.CreateChild, root.SibApiV3Sdk.CreateReseller, root.SibApiV3Sdk.ErrorModel, root.SibApiV3Sdk.GetChildDomains, root.SibApiV3Sdk.GetChildInfo, root.SibApiV3Sdk.GetChildrenList, root.SibApiV3Sdk.GetSsoToken, root.SibApiV3Sdk.ManageIp, root.SibApiV3Sdk.RemainingCreditModel, root.SibApiV3Sdk.RemoveCredits, root.SibApiV3Sdk.UpdateChild, root.SibApiV3Sdk.UpdateChildDomain); |
| 29 | + root.SibApiV3Sdk.ResellerApi = factory(root.SibApiV3Sdk.ApiClient, root.SibApiV3Sdk.AddChildDomain, root.SibApiV3Sdk.AddCredits, root.SibApiV3Sdk.CreateChild, root.SibApiV3Sdk.CreateReseller, root.SibApiV3Sdk.ErrorModel, root.SibApiV3Sdk.GetChildDomains, root.SibApiV3Sdk.GetChildInfo, root.SibApiV3Sdk.GetChildrenList, root.SibApiV3Sdk.GetSsoToken, root.SibApiV3Sdk.ManageIp, root.SibApiV3Sdk.RemainingCreditModel, root.SibApiV3Sdk.RemoveCredits, root.SibApiV3Sdk.UpdateChild, root.SibApiV3Sdk.UpdateChildAccountStatus, root.SibApiV3Sdk.UpdateChildDomain); |
30 | 30 | }
|
31 |
| -}(this, function(ApiClient, AddChildDomain, AddCredits, CreateChild, CreateReseller, ErrorModel, GetChildDomains, GetChildInfo, GetChildrenList, GetSsoToken, ManageIp, RemainingCreditModel, RemoveCredits, UpdateChild, UpdateChildDomain) { |
| 31 | +}(this, function(ApiClient, AddChildDomain, AddCredits, CreateChild, CreateReseller, ErrorModel, GetChildDomains, GetChildInfo, GetChildrenList, GetSsoToken, ManageIp, RemainingCreditModel, RemoveCredits, UpdateChild, UpdateChildAccountStatus, UpdateChildDomain) { |
32 | 32 | 'use strict';
|
33 | 33 |
|
34 | 34 | /**
|
|
585 | 585 |
|
586 | 586 |
|
587 | 587 | /**
|
588 |
| - * Generates a session token which will remain valid for a short period of time only. |
| 588 | + * Get session token to access Sendinblue (SSO) |
| 589 | + * It returns a session [token] which will remain valid for a short period of time. A child account will be able to access a white-labeled section by using the following url pattern => https:/email.mydomain.com/login/sso?token=[token] |
589 | 590 | * @param {String} childAuthKey auth key of reseller's child
|
590 | 591 | * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetSsoToken} and HTTP response
|
591 | 592 | */
|
|
623 | 624 | }
|
624 | 625 |
|
625 | 626 | /**
|
626 |
| - * Generates a session token which will remain valid for a short period of time only. |
| 627 | + * Get session token to access Sendinblue (SSO) |
| 628 | + * It returns a session [token] which will remain valid for a short period of time. A child account will be able to access a white-labeled section by using the following url pattern => https:/email.mydomain.com/login/sso?token=[token] |
627 | 629 | * @param {String} childAuthKey auth key of reseller's child
|
628 | 630 | * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetSsoToken}
|
629 | 631 | */
|
|
693 | 695 | }
|
694 | 696 |
|
695 | 697 |
|
| 698 | + /** |
| 699 | + * Updates infos of reseller's child account status based on the childAuthKey supplied |
| 700 | + * @param {String} childAuthKey auth key of reseller's child |
| 701 | + * @param {module:model/UpdateChildAccountStatus} updateChildAccountStatus values to update in child account status |
| 702 | + * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response |
| 703 | + */ |
| 704 | + this.updateChildAccountStatusWithHttpInfo = function(childAuthKey, updateChildAccountStatus) { |
| 705 | + var postBody = updateChildAccountStatus; |
| 706 | + |
| 707 | + // verify the required parameter 'childAuthKey' is set |
| 708 | + if (childAuthKey === undefined || childAuthKey === null) { |
| 709 | + throw new Error("Missing the required parameter 'childAuthKey' when calling updateChildAccountStatus"); |
| 710 | + } |
| 711 | + |
| 712 | + // verify the required parameter 'updateChildAccountStatus' is set |
| 713 | + if (updateChildAccountStatus === undefined || updateChildAccountStatus === null) { |
| 714 | + throw new Error("Missing the required parameter 'updateChildAccountStatus' when calling updateChildAccountStatus"); |
| 715 | + } |
| 716 | + |
| 717 | + |
| 718 | + var pathParams = { |
| 719 | + 'childAuthKey': childAuthKey |
| 720 | + }; |
| 721 | + var queryParams = { |
| 722 | + }; |
| 723 | + var collectionQueryParams = { |
| 724 | + }; |
| 725 | + var headerParams = { |
| 726 | + }; |
| 727 | + var formParams = { |
| 728 | + }; |
| 729 | + |
| 730 | + var authNames = ['api-key', 'partner-key']; |
| 731 | + var contentTypes = ['application/json']; |
| 732 | + var accepts = ['application/json']; |
| 733 | + var returnType = null; |
| 734 | + |
| 735 | + return this.apiClient.callApi( |
| 736 | + '/reseller/children/{childAuthKey}/accountStatus', 'PUT', |
| 737 | + pathParams, queryParams, collectionQueryParams, headerParams, formParams, postBody, |
| 738 | + authNames, contentTypes, accepts, returnType |
| 739 | + ); |
| 740 | + } |
| 741 | + |
| 742 | + /** |
| 743 | + * Updates infos of reseller's child account status based on the childAuthKey supplied |
| 744 | + * @param {String} childAuthKey auth key of reseller's child |
| 745 | + * @param {module:model/UpdateChildAccountStatus} updateChildAccountStatus values to update in child account status |
| 746 | + * @return {Promise} a {@link https://www.promisejs.org/|Promise} |
| 747 | + */ |
| 748 | + this.updateChildAccountStatus = function(childAuthKey, updateChildAccountStatus) { |
| 749 | + return this.updateChildAccountStatusWithHttpInfo(childAuthKey, updateChildAccountStatus) |
| 750 | + .then(function(response_and_data) { |
| 751 | + return response_and_data.data; |
| 752 | + }); |
| 753 | + } |
| 754 | + |
| 755 | + |
696 | 756 | /**
|
697 | 757 | * Updates the sender domain of reseller's child based on the childAuthKey and domainName passed
|
698 | 758 | * @param {String} childAuthKey auth key of reseller's child
|
|
0 commit comments